-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain-es2015.3de888d8a151f7e95432.js
1 lines (1 loc) · 302 KB
/
main-es2015.3de888d8a151f7e95432.js
1
(window.webpackJsonp=window.webpackJsonp||[]).push([[1],{0:function(e,t,n){e.exports=n("zUnb")},UDOl:function(e){e.exports=JSON.parse('{"a":[{"id":1,"title":"Best Salad in the World","description":"This is a recipe for the best tasting salad in the world. It has lots of carrots and lettuce!","serves":"2 people","imageUrl":"assets/salad.jpg","ingredients":[{"amount":"1 head","name":"lettuce"},{"amount":"10","name":"carrots"},{"amount":"2 tablespoons","name":"ranch dressing"}],"instructions":["remove lettuce leaves","add lettuce leaves to a large bowl","then add the carrots the bowl","add the ranch dressing","then mix ingredients together in the bowl"]},{"id":2,"title":"Chocolate Chip Cookies","description":"This was a recipe handed down to me by my grandmother Ruth who use to make the best chocolate chip cookies!","serves":"4 people","imageUrl":"assets/cookies.jpg","ingredients":[{"amount":"1 bag","name":"chocolate chips"},{"amount":"2","name":"eggs"},{"amount":"1 cup","name":"flour"},{"amount":"1 cup","name":"sugar"}],"instructions":["get a large bowl","crack eggs into the bowl","add the rest of the ingredients to the bowl","mix ingredients with a whisk","then evenly place small clumps of cookie dough on a baking sheet","place baking sheet in oven for 12 minutes at 350 degrees F"]},{"id":3,"title":"Cinco de Nachos","description":"I discovered this recipe when I went on a trip to Mexico. A nice lady taught me how to make world famous nachos.","serves":"2 adults or 4 kids","imageUrl":"assets/nachos.jpg","ingredients":[{"amount":"1 bag","name":"tortilla chips"},{"amount":"1 pound","name":"shredded cheese"},{"amount":"1 can","name":"refried beans"}],"instructions":["spread tortilla chips on a large plate","warm up beans in a pot on the stove","sprinkle the shredded cheese on top of the chips","place plate in the oven for 10 minutes at 350 degrees F","finally remove plate from oven and spread refried beans on top of the chips"]}]}')},zUnb:function(e,t,n){"use strict";function r(e){return"function"==typeof e}n.r(t);let s=!1;const l={Promise:void 0,set useDeprecatedSynchronousErrorHandling(e){if(e){const e=new Error;console.warn("DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \n"+e.stack)}else s&&console.log("RxJS: Back to a better error behavior. Thank you. <3");s=e},get useDeprecatedSynchronousErrorHandling(){return s}};function i(e){setTimeout(()=>{throw e})}const o={closed:!0,next(e){},error(e){if(l.useDeprecatedSynchronousErrorHandling)throw e;i(e)},complete(){}},a=Array.isArray||(e=>e&&"number"==typeof e.length);function u(e){return null!==e&&"object"==typeof e}function c(e){return Error.call(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((e,t)=>`${t+1}) ${e.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e,this}c.prototype=Object.create(Error.prototype);const h=c;let d=(()=>{class e{constructor(e){this.closed=!1,this._parent=null,this._parents=null,this._subscriptions=null,e&&(this._unsubscribe=e)}unsubscribe(){let e,t=!1;if(this.closed)return;let{_parent:n,_parents:s,_unsubscribe:l,_subscriptions:i}=this;this.closed=!0,this._parent=null,this._parents=null,this._subscriptions=null;let o=-1,c=s?s.length:0;for(;n;)n.remove(this),n=++o<c&&s[o]||null;if(r(l))try{l.call(this)}catch(d){t=!0,e=d instanceof h?p(d.errors):[d]}if(a(i))for(o=-1,c=i.length;++o<c;){const n=i[o];if(u(n))try{n.unsubscribe()}catch(d){t=!0,e=e||[],d instanceof h?e=e.concat(p(d.errors)):e.push(d)}}if(t)throw new h(e)}add(t){let n=t;switch(typeof t){case"function":n=new e(t);case"object":if(n===this||n.closed||"function"!=typeof n.unsubscribe)return n;if(this.closed)return n.unsubscribe(),n;if(!(n instanceof e)){const t=n;n=new e,n._subscriptions=[t]}break;default:if(!t)return e.EMPTY;throw new Error("unrecognized teardown "+t+" added to Subscription.")}if(n._addParent(this)){const e=this._subscriptions;e?e.push(n):this._subscriptions=[n]}return n}remove(e){const t=this._subscriptions;if(t){const n=t.indexOf(e);-1!==n&&t.splice(n,1)}}_addParent(e){let{_parent:t,_parents:n}=this;return t!==e&&(t?n?-1===n.indexOf(e)&&(n.push(e),!0):(this._parents=[e],!0):(this._parent=e,!0))}}return e.EMPTY=function(e){return e.closed=!0,e}(new e),e})();function p(e){return e.reduce((e,t)=>e.concat(t instanceof h?t.errors:t),[])}const g="function"==typeof Symbol?Symbol("rxSubscriber"):"@@rxSubscriber_"+Math.random();class f extends d{constructor(e,t,n){switch(super(),this.syncErrorValue=null,this.syncErrorThrown=!1,this.syncErrorThrowable=!1,this.isStopped=!1,arguments.length){case 0:this.destination=o;break;case 1:if(!e){this.destination=o;break}if("object"==typeof e){e instanceof f?(this.syncErrorThrowable=e.syncErrorThrowable,this.destination=e,e.add(this)):(this.syncErrorThrowable=!0,this.destination=new m(this,e));break}default:this.syncErrorThrowable=!0,this.destination=new m(this,e,t,n)}}[g](){return this}static create(e,t,n){const r=new f(e,t,n);return r.syncErrorThrowable=!1,r}next(e){this.isStopped||this._next(e)}error(e){this.isStopped||(this.isStopped=!0,this._error(e))}complete(){this.isStopped||(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe())}_next(e){this.destination.next(e)}_error(e){this.destination.error(e),this.unsubscribe()}_complete(){this.destination.complete(),this.unsubscribe()}_unsubscribeAndRecycle(){const{_parent:e,_parents:t}=this;return this._parent=null,this._parents=null,this.unsubscribe(),this.closed=!1,this.isStopped=!1,this._parent=e,this._parents=t,this}}class m extends f{constructor(e,t,n,s){let l;super(),this._parentSubscriber=e;let i=this;r(t)?l=t:t&&(l=t.next,n=t.error,s=t.complete,t!==o&&(i=Object.create(t),r(i.unsubscribe)&&this.add(i.unsubscribe.bind(i)),i.unsubscribe=this.unsubscribe.bind(this))),this._context=i,this._next=l,this._error=n,this._complete=s}next(e){if(!this.isStopped&&this._next){const{_parentSubscriber:t}=this;l.useDeprecatedSynchronousErrorHandling&&t.syncErrorThrowable?this.__tryOrSetError(t,this._next,e)&&this.unsubscribe():this.__tryOrUnsub(this._next,e)}}error(e){if(!this.isStopped){const{_parentSubscriber:t}=this,{useDeprecatedSynchronousErrorHandling:n}=l;if(this._error)n&&t.syncErrorThrowable?(this.__tryOrSetError(t,this._error,e),this.unsubscribe()):(this.__tryOrUnsub(this._error,e),this.unsubscribe());else if(t.syncErrorThrowable)n?(t.syncErrorValue=e,t.syncErrorThrown=!0):i(e),this.unsubscribe();else{if(this.unsubscribe(),n)throw e;i(e)}}}complete(){if(!this.isStopped){const{_parentSubscriber:e}=this;if(this._complete){const t=()=>this._complete.call(this._context);l.useDeprecatedSynchronousErrorHandling&&e.syncErrorThrowable?(this.__tryOrSetError(e,t),this.unsubscribe()):(this.__tryOrUnsub(t),this.unsubscribe())}else this.unsubscribe()}}__tryOrUnsub(e,t){try{e.call(this._context,t)}catch(n){if(this.unsubscribe(),l.useDeprecatedSynchronousErrorHandling)throw n;i(n)}}__tryOrSetError(e,t,n){if(!l.useDeprecatedSynchronousErrorHandling)throw new Error("bad call");try{t.call(this._context,n)}catch(r){return l.useDeprecatedSynchronousErrorHandling?(e.syncErrorValue=r,e.syncErrorThrown=!0,!0):(i(r),!0)}return!1}_unsubscribe(){const{_parentSubscriber:e}=this;this._context=null,this._parentSubscriber=null,e.unsubscribe()}}const v="function"==typeof Symbol&&Symbol.observable||"@@observable";function y(){}function _(...e){return w(e)}function w(e){return e?1===e.length?e[0]:function(t){return e.reduce((e,t)=>t(e),t)}:y}let b=(()=>{class e{constructor(e){this._isScalar=!1,e&&(this._subscribe=e)}lift(t){const n=new e;return n.source=this,n.operator=t,n}subscribe(e,t,n){const{operator:r}=this,s=function(e,t,n){if(e){if(e instanceof f)return e;if(e[g])return e[g]()}return e||t||n?new f(e,t,n):new f(o)}(e,t,n);if(s.add(r?r.call(s,this.source):this.source||l.useDeprecatedSynchronousErrorHandling&&!s.syncErrorThrowable?this._subscribe(s):this._trySubscribe(s)),l.useDeprecatedSynchronousErrorHandling&&s.syncErrorThrowable&&(s.syncErrorThrowable=!1,s.syncErrorThrown))throw s.syncErrorValue;return s}_trySubscribe(e){try{return this._subscribe(e)}catch(t){l.useDeprecatedSynchronousErrorHandling&&(e.syncErrorThrown=!0,e.syncErrorValue=t),function(e){for(;e;){const{closed:t,destination:n,isStopped:r}=e;if(t||r)return!1;e=n&&n instanceof f?n:null}return!0}(e)?e.error(t):console.warn(t)}}forEach(e,t){return new(t=C(t))((t,n)=>{let r;r=this.subscribe(t=>{try{e(t)}catch(s){n(s),r&&r.unsubscribe()}},n,t)})}_subscribe(e){const{source:t}=this;return t&&t.subscribe(e)}[v](){return this}pipe(...e){return 0===e.length?this:w(e)(this)}toPromise(e){return new(e=C(e))((e,t)=>{let n;this.subscribe(e=>n=e,e=>t(e),()=>e(n))})}}return e.create=t=>new e(t),e})();function C(e){if(e||(e=l.Promise||Promise),!e)throw new Error("no Promise impl found");return e}function x(){return Error.call(this),this.message="object unsubscribed",this.name="ObjectUnsubscribedError",this}x.prototype=Object.create(Error.prototype);const S=x;class E extends d{constructor(e,t){super(),this.subject=e,this.subscriber=t,this.closed=!1}unsubscribe(){if(this.closed)return;this.closed=!0;const e=this.subject,t=e.observers;if(this.subject=null,!t||0===t.length||e.isStopped||e.closed)return;const n=t.indexOf(this.subscriber);-1!==n&&t.splice(n,1)}}class T extends f{constructor(e){super(e),this.destination=e}}let k=(()=>{class e extends b{constructor(){super(),this.observers=[],this.closed=!1,this.isStopped=!1,this.hasError=!1,this.thrownError=null}[g](){return new T(this)}lift(e){const t=new A(this,this);return t.operator=e,t}next(e){if(this.closed)throw new S;if(!this.isStopped){const{observers:t}=this,n=t.length,r=t.slice();for(let s=0;s<n;s++)r[s].next(e)}}error(e){if(this.closed)throw new S;this.hasError=!0,this.thrownError=e,this.isStopped=!0;const{observers:t}=this,n=t.length,r=t.slice();for(let s=0;s<n;s++)r[s].error(e);this.observers.length=0}complete(){if(this.closed)throw new S;this.isStopped=!0;const{observers:e}=this,t=e.length,n=e.slice();for(let r=0;r<t;r++)n[r].complete();this.observers.length=0}unsubscribe(){this.isStopped=!0,this.closed=!0,this.observers=null}_trySubscribe(e){if(this.closed)throw new S;return super._trySubscribe(e)}_subscribe(e){if(this.closed)throw new S;return this.hasError?(e.error(this.thrownError),d.EMPTY):this.isStopped?(e.complete(),d.EMPTY):(this.observers.push(e),new E(this,e))}asObservable(){const e=new b;return e.source=this,e}}return e.create=(e,t)=>new A(e,t),e})();class A extends k{constructor(e,t){super(),this.destination=e,this.source=t}next(e){const{destination:t}=this;t&&t.next&&t.next(e)}error(e){const{destination:t}=this;t&&t.error&&this.destination.error(e)}complete(){const{destination:e}=this;e&&e.complete&&this.destination.complete()}_subscribe(e){const{source:t}=this;return t?this.source.subscribe(e):d.EMPTY}}function I(e){return e&&"function"==typeof e.schedule}class P extends f{constructor(e,t,n){super(),this.parent=e,this.outerValue=t,this.outerIndex=n,this.index=0}_next(e){this.parent.notifyNext(this.outerValue,e,this.outerIndex,this.index++,this)}_error(e){this.parent.notifyError(e,this),this.unsubscribe()}_complete(){this.parent.notifyComplete(this),this.unsubscribe()}}const O=e=>t=>{for(let n=0,r=e.length;n<r&&!t.closed;n++)t.next(e[n]);t.closed||t.complete()},R=e=>t=>(e.then(e=>{t.closed||(t.next(e),t.complete())},e=>t.error(e)).then(null,i),t);function N(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}const D=N(),V=e=>t=>{const n=e[D]();for(;;){const e=n.next();if(e.done){t.complete();break}if(t.next(e.value),t.closed)break}return"function"==typeof n.return&&t.add(()=>{n.return&&n.return()}),t},M=e=>t=>{const n=e[v]();if("function"!=typeof n.subscribe)throw new TypeError("Provided object does not correctly implement Symbol.observable");return n.subscribe(t)},U=e=>e&&"number"==typeof e.length&&"function"!=typeof e;function j(e){return!!e&&"function"!=typeof e.subscribe&&"function"==typeof e.then}const F=e=>{if(e instanceof b)return t=>e._isScalar?(t.next(e.value),void t.complete()):e.subscribe(t);if(e&&"function"==typeof e[v])return M(e);if(U(e))return O(e);if(j(e))return R(e);if(e&&"function"==typeof e[D])return V(e);{const t=u(e)?"an invalid object":`'${e}'`;throw new TypeError(`You provided ${t} where a stream was expected.`+" You can provide an Observable, Promise, Array, or Iterable.")}};function L(e,t,n,r,s=new P(e,n,r)){if(!s.closed)return F(t)(s)}class $ extends f{notifyNext(e,t,n,r,s){this.destination.next(t)}notifyError(e,t){this.destination.error(e)}notifyComplete(e){this.destination.complete()}}function H(e,t){return function(n){if("function"!=typeof e)throw new TypeError("argument is not a function. Are you looking for `mapTo()`?");return n.lift(new z(e,t))}}class z{constructor(e,t){this.project=e,this.thisArg=t}call(e,t){return t.subscribe(new B(e,this.project,this.thisArg))}}class B extends f{constructor(e,t,n){super(e),this.project=t,this.count=0,this.thisArg=n||this}_next(e){let t;try{t=this.project.call(this.thisArg,e,this.count++)}catch(n){return void this.destination.error(n)}this.destination.next(t)}}function q(e,t){return new b(t?n=>{const r=new d;let s=0;return r.add(t.schedule((function(){s!==e.length?(n.next(e[s++]),n.closed||r.add(this.schedule())):n.complete()}))),r}:O(e))}function G(e,t){if(!t)return e instanceof b?e:new b(F(e));if(null!=e){if(function(e){return e&&"function"==typeof e[v]}(e))return function(e,t){return new b(t?n=>{const r=new d;return r.add(t.schedule(()=>{const s=e[v]();r.add(s.subscribe({next(e){r.add(t.schedule(()=>n.next(e)))},error(e){r.add(t.schedule(()=>n.error(e)))},complete(){r.add(t.schedule(()=>n.complete()))}}))})),r}:M(e))}(e,t);if(j(e))return function(e,t){return new b(t?n=>{const r=new d;return r.add(t.schedule(()=>e.then(e=>{r.add(t.schedule(()=>{n.next(e),r.add(t.schedule(()=>n.complete()))}))},e=>{r.add(t.schedule(()=>n.error(e)))}))),r}:R(e))}(e,t);if(U(e))return q(e,t);if(function(e){return e&&"function"==typeof e[D]}(e)||"string"==typeof e)return function(e,t){if(!e)throw new Error("Iterable cannot be null");return new b(t?n=>{const r=new d;let s;return r.add(()=>{s&&"function"==typeof s.return&&s.return()}),r.add(t.schedule(()=>{s=e[D](),r.add(t.schedule((function(){if(n.closed)return;let e,t;try{const n=s.next();e=n.value,t=n.done}catch(r){return void n.error(r)}t?n.complete():(n.next(e),this.schedule())})))})),r}:V(e))}(e,t)}throw new TypeError((null!==e&&typeof e||e)+" is not observable")}function W(e,t,n=Number.POSITIVE_INFINITY){return"function"==typeof t?r=>r.pipe(W((n,r)=>G(e(n,r)).pipe(H((e,s)=>t(n,e,r,s))),n)):("number"==typeof t&&(n=t),t=>t.lift(new Z(e,n)))}class Z{constructor(e,t=Number.POSITIVE_INFINITY){this.project=e,this.concurrent=t}call(e,t){return t.subscribe(new Q(e,this.project,this.concurrent))}}class Q extends ${constructor(e,t,n=Number.POSITIVE_INFINITY){super(e),this.project=t,this.concurrent=n,this.hasCompleted=!1,this.buffer=[],this.active=0,this.index=0}_next(e){this.active<this.concurrent?this._tryNext(e):this.buffer.push(e)}_tryNext(e){let t;const n=this.index++;try{t=this.project(e,n)}catch(r){return void this.destination.error(r)}this.active++,this._innerSub(t,e,n)}_innerSub(e,t,n){const r=new P(this,void 0,void 0);this.destination.add(r),L(this,e,t,n,r)}_complete(){this.hasCompleted=!0,0===this.active&&0===this.buffer.length&&this.destination.complete(),this.unsubscribe()}notifyNext(e,t,n,r,s){this.destination.next(t)}notifyComplete(e){const t=this.buffer;this.remove(e),this.active--,t.length>0?this._next(t.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()}}function K(e){return e}function Y(e=Number.POSITIVE_INFINITY){return W(K,e)}function J(){return function(e){return e.lift(new X(e))}}class X{constructor(e){this.connectable=e}call(e,t){const{connectable:n}=this;n._refCount++;const r=new ee(e,n),s=t.subscribe(r);return r.closed||(r.connection=n.connect()),s}}class ee extends f{constructor(e,t){super(e),this.connectable=t}_unsubscribe(){const{connectable:e}=this;if(!e)return void(this.connection=null);this.connectable=null;const t=e._refCount;if(t<=0)return void(this.connection=null);if(e._refCount=t-1,t>1)return void(this.connection=null);const{connection:n}=this,r=e._connection;this.connection=null,!r||n&&r!==n||r.unsubscribe()}}const te=class extends b{constructor(e,t){super(),this.source=e,this.subjectFactory=t,this._refCount=0,this._isComplete=!1}_subscribe(e){return this.getSubject().subscribe(e)}getSubject(){const e=this._subject;return e&&!e.isStopped||(this._subject=this.subjectFactory()),this._subject}connect(){let e=this._connection;return e||(this._isComplete=!1,e=this._connection=new d,e.add(this.source.subscribe(new re(this.getSubject(),this))),e.closed?(this._connection=null,e=d.EMPTY):this._connection=e),e}refCount(){return J()(this)}}.prototype,ne={operator:{value:null},_refCount:{value:0,writable:!0},_subject:{value:null,writable:!0},_connection:{value:null,writable:!0},_subscribe:{value:te._subscribe},_isComplete:{value:te._isComplete,writable:!0},getSubject:{value:te.getSubject},connect:{value:te.connect},refCount:{value:te.refCount}};class re extends T{constructor(e,t){super(e),this.connectable=t}_error(e){this._unsubscribe(),super._error(e)}_complete(){this.connectable._isComplete=!0,this._unsubscribe(),super._complete()}_unsubscribe(){const e=this.connectable;if(e){this.connectable=null;const t=e._connection;e._refCount=0,e._subject=null,e._connection=null,t&&t.unsubscribe()}}}function se(){return new k}function le(e,t,n){const r=function(e){return function(...t){if(e){const n=e(...t);for(const e in n)this[e]=n[e]}}}(t);function s(...e){if(this instanceof s)return r.apply(this,e),this;const t=new s(...e);return n.annotation=t,n;function n(e,n,r){const s=e.hasOwnProperty("__parameters__")?e.__parameters__:Object.defineProperty(e,"__parameters__",{value:[]}).__parameters__;for(;s.length<=r;)s.push(null);return(s[r]=s[r]||[]).push(t),e}}return n&&(s.prototype=Object.create(n.prototype)),s.prototype.ngMetadataName=e,s.annotationCls=s,s}const ie=le("Inject",e=>({token:e})),oe=le("Optional"),ae=le("Self"),ue=le("SkipSelf");var ce=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}({});function he(e){for(let t in e)if(e[t]===he)return t;throw Error("Could not find renamed property on target object.")}function de(e){return{token:e.token,providedIn:e.providedIn||null,factory:e.factory,value:void 0}}function pe(e){const t=e[ge];return t&&t.token===e?t:null}const ge=he({ngInjectableDef:he});function fe(e){if("string"==typeof e)return e;if(e instanceof Array)return"["+e.map(fe).join(", ")+"]";if(null==e)return""+e;if(e.overriddenName)return`${e.overriddenName}`;if(e.name)return`${e.name}`;const t=e.toString();if(null==t)return""+t;const n=t.indexOf("\n");return-1===n?t:t.substring(0,n)}const me=he({__forward_ref__:he});function ve(e){return e.__forward_ref__=ve,e.toString=function(){return fe(this())},e}function ye(e){const t=e;return"function"==typeof t&&t.hasOwnProperty(me)&&t.__forward_ref__===ve?t():e}const _e="undefined"!=typeof globalThis&&globalThis,we="undefined"!=typeof window&&window,be="undefined"!=typeof self&&"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&self,Ce="undefined"!=typeof global&&global,xe=_e||Ce||we||be;class Se{constructor(e,t){this._desc=e,this.ngMetadataName="InjectionToken",this.ngInjectableDef=void 0,"number"==typeof t?this.__NG_ELEMENT_ID__=t:void 0!==t&&(this.ngInjectableDef=de({token:this,providedIn:t.providedIn||"root",factory:t.factory}))}toString(){return`InjectionToken ${this._desc}`}}const Ee=new Se("INJECTOR",-1),Te=new Object,ke=/\n/gm,Ae=he({provide:String,useValue:he});let Ie=void 0;function Pe(e){const t=Ie;return Ie=e,t}function Oe(e,t=ce.Default){return function(e,t=ce.Default){if(void 0===Ie)throw new Error("inject() must be called from an injection context");return null===Ie?function(e,t,n){const r=pe(e);if(r&&"root"==r.providedIn)return void 0===r.value?r.value=r.factory():r.value;if(n&ce.Optional)return null;throw new Error(`Injector: NOT_FOUND [${fe(e)}]`)}(e,0,t):Ie.get(e,t&ce.Optional?null:void 0,t)}(e,t)}class Re{get(e,t=Te){if(t===Te){const t=new Error(`NullInjectorError: No provider for ${fe(e)}!`);throw t.name="NullInjectorError",t}return t}}function Ne(e,t,n,r=null){e=e&&"\n"===e.charAt(0)&&"\u0275"==e.charAt(1)?e.substr(2):e;let s=fe(t);if(t instanceof Array)s=t.map(fe).join(" -> ");else if("object"==typeof t){let e=[];for(let n in t)if(t.hasOwnProperty(n)){let r=t[n];e.push(n+":"+("string"==typeof r?JSON.stringify(r):fe(r)))}s=`{${e.join(", ")}}`}return`${n}${r?"("+r+")":""}[${s}]: ${e.replace(ke,"\n ")}`}class De{}class Ve{}function Me(e,t,n){t>=e.length?e.push(n):e.splice(t,0,n)}function Ue(e,t){return t>=e.length-1?e.pop():e.splice(t,1)[0]}const je=function(){var e={Emulated:0,Native:1,None:2,ShadowDom:3};return e[e.Emulated]="Emulated",e[e.Native]="Native",e[e.None]="None",e[e.ShadowDom]="ShadowDom",e}(),Fe=(()=>("undefined"!=typeof requestAnimationFrame&&requestAnimationFrame||setTimeout).bind(xe))();function Le(e){return e.ngDebugContext}function $e(e){return e.ngOriginalError}function He(e,...t){e.error(...t)}class ze{constructor(){this._console=console}handleError(e){const t=this._findOriginalError(e),n=this._findContext(e),r=function(e){return e.ngErrorLogger||He}(e);r(this._console,"ERROR",e),t&&r(this._console,"ORIGINAL ERROR",t),n&&r(this._console,"ERROR CONTEXT",n)}_findContext(e){return e?Le(e)?Le(e):this._findContext($e(e)):null}_findOriginalError(e){let t=$e(e);for(;t&&$e(t);)t=$e(t);return t}}let Be=!0,qe=!1;function Ge(){return qe=!0,Be}class We{constructor(e){if(this.defaultDoc=e,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert"),this.inertBodyElement=this.inertDocument.body,null==this.inertBodyElement){const e=this.inertDocument.createElement("html");this.inertDocument.appendChild(e),this.inertBodyElement=this.inertDocument.createElement("body"),e.appendChild(this.inertBodyElement)}this.inertBodyElement.innerHTML='<svg><g onload="this.parentNode.remove()"></g></svg>',!this.inertBodyElement.querySelector||this.inertBodyElement.querySelector("svg")?(this.inertBodyElement.innerHTML='<svg><p><style><img src="</style><img src=x onerror=alert(1)//">',this.getInertBodyElement=this.inertBodyElement.querySelector&&this.inertBodyElement.querySelector("svg img")&&function(){try{return!!window.DOMParser}catch(e){return!1}}()?this.getInertBodyElement_DOMParser:this.getInertBodyElement_InertDocument):this.getInertBodyElement=this.getInertBodyElement_XHR}getInertBodyElement_XHR(e){e="<body><remove></remove>"+e+"</body>";try{e=encodeURI(e)}catch(r){return null}const t=new XMLHttpRequest;t.responseType="document",t.open("GET","data:text/html;charset=utf-8,"+e,!1),t.send(void 0);const n=t.response.body;return n.removeChild(n.firstChild),n}getInertBodyElement_DOMParser(e){e="<body><remove></remove>"+e+"</body>";try{const t=(new window.DOMParser).parseFromString(e,"text/html").body;return t.removeChild(t.firstChild),t}catch(t){return null}}getInertBodyElement_InertDocument(e){const t=this.inertDocument.createElement("template");return"content"in t?(t.innerHTML=e,t):(this.inertBodyElement.innerHTML=e,this.defaultDoc.documentMode&&this.stripCustomNsAttrs(this.inertBodyElement),this.inertBodyElement)}stripCustomNsAttrs(e){const t=e.attributes;for(let r=t.length-1;0<r;r--){const n=t.item(r).name;"xmlns:ns1"!==n&&0!==n.indexOf("ns1:")||e.removeAttribute(n)}let n=e.firstChild;for(;n;)n.nodeType===Node.ELEMENT_NODE&&this.stripCustomNsAttrs(n),n=n.nextSibling}}const Ze=/^(?:(?:https?|mailto|ftp|tel|file):|[^&:/?#]*(?:[/?#]|$))/gi,Qe=/^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+\/]+=*$/i;function Ke(e){return(e=String(e)).match(Ze)||e.match(Qe)?e:(Ge()&&console.warn(`WARNING: sanitizing unsafe URL value ${e} (see http://g.co/ng/security#xss)`),"unsafe:"+e)}function Ye(e){const t={};for(const n of e.split(","))t[n]=!0;return t}function Je(...e){const t={};for(const n of e)for(const e in n)n.hasOwnProperty(e)&&(t[e]=!0);return t}const Xe=Ye("area,br,col,hr,img,wbr"),et=Ye("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),tt=Ye("rp,rt"),nt=Je(tt,et),rt=Je(Xe,Je(et,Ye("address,article,aside,blockquote,caption,center,del,details,dialog,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,main,map,menu,nav,ol,pre,section,summary,table,ul")),Je(tt,Ye("a,abbr,acronym,audio,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,picture,q,ruby,rp,rt,s,samp,small,source,span,strike,strong,sub,sup,time,track,tt,u,var,video")),nt),st=Ye("background,cite,href,itemtype,longdesc,poster,src,xlink:href"),lt=Ye("srcset"),it=Je(st,lt,Ye("abbr,accesskey,align,alt,autoplay,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,controls,coords,datetime,default,dir,download,face,headers,height,hidden,hreflang,hspace,ismap,itemscope,itemprop,kind,label,lang,language,loop,media,muted,nohref,nowrap,open,preload,rel,rev,role,rows,rowspan,rules,scope,scrolling,shape,size,sizes,span,srclang,start,summary,tabindex,target,title,translate,type,usemap,valign,value,vspace,width"),Ye("aria-activedescendant,aria-atomic,aria-autocomplete,aria-busy,aria-checked,aria-colcount,aria-colindex,aria-colspan,aria-controls,aria-current,aria-describedby,aria-details,aria-disabled,aria-dropeffect,aria-errormessage,aria-expanded,aria-flowto,aria-grabbed,aria-haspopup,aria-hidden,aria-invalid,aria-keyshortcuts,aria-label,aria-labelledby,aria-level,aria-live,aria-modal,aria-multiline,aria-multiselectable,aria-orientation,aria-owns,aria-placeholder,aria-posinset,aria-pressed,aria-readonly,aria-relevant,aria-required,aria-roledescription,aria-rowcount,aria-rowindex,aria-rowspan,aria-selected,aria-setsize,aria-sort,aria-valuemax,aria-valuemin,aria-valuenow,aria-valuetext")),ot=Ye("script,style,template");class at{constructor(){this.sanitizedSomething=!1,this.buf=[]}sanitizeChildren(e){let t=e.firstChild,n=!0;for(;t;)if(t.nodeType===Node.ELEMENT_NODE?n=this.startElement(t):t.nodeType===Node.TEXT_NODE?this.chars(t.nodeValue):this.sanitizedSomething=!0,n&&t.firstChild)t=t.firstChild;else for(;t;){t.nodeType===Node.ELEMENT_NODE&&this.endElement(t);let e=this.checkClobberedElement(t,t.nextSibling);if(e){t=e;break}t=this.checkClobberedElement(t,t.parentNode)}return this.buf.join("")}startElement(e){const t=e.nodeName.toLowerCase();if(!rt.hasOwnProperty(t))return this.sanitizedSomething=!0,!ot.hasOwnProperty(t);this.buf.push("<"),this.buf.push(t);const n=e.attributes;for(let s=0;s<n.length;s++){const e=n.item(s),t=e.name,l=t.toLowerCase();if(!it.hasOwnProperty(l)){this.sanitizedSomething=!0;continue}let i=e.value;st[l]&&(i=Ke(i)),lt[l]&&(r=i,i=(r=String(r)).split(",").map(e=>Ke(e.trim())).join(", ")),this.buf.push(" ",t,'="',ht(i),'"')}var r;return this.buf.push(">"),!0}endElement(e){const t=e.nodeName.toLowerCase();rt.hasOwnProperty(t)&&!Xe.hasOwnProperty(t)&&(this.buf.push("</"),this.buf.push(t),this.buf.push(">"))}chars(e){this.buf.push(ht(e))}checkClobberedElement(e,t){if(t&&(e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY)===Node.DOCUMENT_POSITION_CONTAINED_BY)throw new Error(`Failed to sanitize html because the element is clobbered: ${e.outerHTML}`);return t}}const ut=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,ct=/([^\#-~ |!])/g;function ht(e){return e.replace(/&/g,"&").replace(ut,(function(e){return"&#"+(1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320)+65536)+";"})).replace(ct,(function(e){return"&#"+e.charCodeAt(0)+";"})).replace(/</g,"<").replace(/>/g,">")}let dt;function pt(e){return"content"in e&&function(e){return e.nodeType===Node.ELEMENT_NODE&&"TEMPLATE"===e.nodeName}(e)?e.content:null}const gt=function(){var e={NONE:0,HTML:1,STYLE:2,SCRIPT:3,URL:4,RESOURCE_URL:5};return e[e.NONE]="NONE",e[e.HTML]="HTML",e[e.STYLE]="STYLE",e[e.SCRIPT]="SCRIPT",e[e.URL]="URL",e[e.RESOURCE_URL]="RESOURCE_URL",e}();class ft{}const mt=new RegExp("^([-,.\"'%_!# a-zA-Z0-9]+|(?:(?:matrix|translate|scale|rotate|skew|perspective)(?:X|Y|Z|3d)?|(?:rgb|hsl)a?|(?:repeating-)?(?:linear|radial)-gradient|(?:calc|attr))\\([-0-9.%, #a-zA-Z]+\\))$","g"),vt=/^url\(([^)]+)\)$/,yt=/([A-Z])/g;function _t(e){try{return null!=e?e.toString().slice(0,30):e}catch(t){return"[ERROR] Exception while trying to serialize the value"}}let wt=(()=>{class e{}return e.__NG_ELEMENT_ID__=()=>bt(),e})();const bt=(...e)=>{},Ct=new Se("The presence of this token marks an injector as being the root injector."),xt=function(e,t,n){return new It(e,t,n)};let St=(()=>{class e{static create(e,t){return Array.isArray(e)?xt(e,t,""):xt(e.providers,e.parent,e.name||"")}}return e.THROW_IF_NOT_FOUND=Te,e.NULL=new Re,e.ngInjectableDef=de({token:e,providedIn:"any",factory:()=>Oe(Ee)}),e.__NG_ELEMENT_ID__=-1,e})();const Et=function(e){return e},Tt=[],kt=Et,At=function(){return Array.prototype.slice.call(arguments)};class It{constructor(e,t=St.NULL,n=null){this.parent=t,this.source=n;const r=this._records=new Map;r.set(St,{token:St,fn:Et,deps:Tt,value:this,useNew:!1}),r.set(Ee,{token:Ee,fn:Et,deps:Tt,value:this,useNew:!1}),function e(t,n){if(n)if((n=ye(n))instanceof Array)for(let r=0;r<n.length;r++)e(t,n[r]);else{if("function"==typeof n)throw Ot("Function/Class not supported",n);if(!n||"object"!=typeof n||!n.provide)throw Ot("Unexpected provider",n);{let e=ye(n.provide);const r=function(e){const t=function(e){let t=Tt;const n=e.deps;if(n&&n.length){t=[];for(let e=0;e<n.length;e++){let r=6,s=ye(n[e]);if(s instanceof Array)for(let e=0,t=s;e<t.length;e++){const n=t[e];n instanceof oe||n==oe?r|=1:n instanceof ue||n==ue?r&=-3:n instanceof ae||n==ae?r&=-5:s=n instanceof ie?n.token:ye(n)}t.push({token:s,options:r})}}else if(e.useExisting)t=[{token:ye(e.useExisting),options:6}];else if(!(n||Ae in e))throw Ot("'deps' required",e);return t}(e);let n=Et,r=Tt,s=!1,l=ye(e.provide);if(Ae in e)r=e.useValue;else if(e.useFactory)n=e.useFactory;else if(e.useExisting);else if(e.useClass)s=!0,n=ye(e.useClass);else{if("function"!=typeof l)throw Ot("StaticProvider does not have [useValue|useFactory|useExisting|useClass] or [provide] is not newable",e);s=!0,n=l}return{deps:t,fn:n,useNew:s,value:r}}(n);if(!0===n.multi){let r=t.get(e);if(r){if(r.fn!==At)throw Pt(e)}else t.set(e,r={token:n.provide,deps:[],useNew:!1,fn:At,value:Tt});e=n,r.deps.push({token:e,options:6})}const s=t.get(e);if(s&&s.fn==At)throw Pt(e);t.set(e,r)}}}(r,e)}get(e,t,n=ce.Default){const r=this._records.get(e);try{return function e(t,n,r,s,l,i){try{return function(t,n,r,s,l,i){let o;if(!n||i&ce.SkipSelf)i&ce.Self||(o=s.get(t,l,ce.Default));else{if(o=n.value,o==kt)throw Error("\u0275Circular dependency");if(o===Tt){n.value=kt;let t=void 0,l=n.useNew,i=n.fn,a=n.deps,u=Tt;if(a.length){u=[];for(let t=0;t<a.length;t++){const n=a[t],l=n.options,i=2&l?r.get(n.token):void 0;u.push(e(n.token,i,r,i||4&l?s:St.NULL,1&l?null:St.THROW_IF_NOT_FOUND,ce.Default))}}n.value=o=l?new i(...u):i.apply(t,u)}}return o}(t,n,r,s,l,i)}catch(o){throw o instanceof Error||(o=new Error(o)),(o.ngTempTokenPath=o.ngTempTokenPath||[]).unshift(t),n&&n.value==kt&&(n.value=Tt),o}}(e,r,this._records,this.parent,t,n)}catch(s){return function(e,t,n,r){const s=e.ngTempTokenPath;throw t.__source&&s.unshift(t.__source),e.message=Ne("\n"+e.message,s,"StaticInjectorError",r),e.ngTokenPath=s,e.ngTempTokenPath=null,e}(s,e,0,this.source)}}toString(){const e=[];return this._records.forEach((t,n)=>e.push(fe(n))),`StaticInjector[${e.join(", ")}]`}}function Pt(e){return Ot("Cannot mix multi providers and regular providers",e)}function Ot(e,t){return new Error(Ne(e,t,"StaticInjectorError"))}const Rt=new Se("AnalyzeForEntryComponents");let Nt=null;function Dt(){if(!Nt){const e=xe.Symbol;if(e&&e.iterator)Nt=e.iterator;else{const e=Object.getOwnPropertyNames(Map.prototype);for(let t=0;t<e.length;++t){const n=e[t];"entries"!==n&&"size"!==n&&Map.prototype[n]===Map.prototype.entries&&(Nt=n)}}}return Nt}function Vt(e,t){return e===t||"number"==typeof e&&"number"==typeof t&&isNaN(e)&&isNaN(t)}function Mt(e,t){const n=jt(e),r=jt(t);if(n&&r)return function(e,t,n){const r=e[Dt()](),s=t[Dt()]();for(;;){const e=r.next(),t=s.next();if(e.done&&t.done)return!0;if(e.done||t.done)return!1;if(!n(e.value,t.value))return!1}}(e,t,Mt);{const s=e&&("object"==typeof e||"function"==typeof e),l=t&&("object"==typeof t||"function"==typeof t);return!(n||!s||r||!l)||Vt(e,t)}}class Ut{constructor(e){this.wrapped=e}static wrap(e){return new Ut(e)}static unwrap(e){return Ut.isWrapped(e)?e.wrapped:e}static isWrapped(e){return e instanceof Ut}}function jt(e){return!!Ft(e)&&(Array.isArray(e)||!(e instanceof Map)&&Dt()in e)}function Ft(e){return null!==e&&("function"==typeof e||"object"==typeof e)}function Lt(e){return!!e&&"function"==typeof e.then}function $t(e){return!!e&&"function"==typeof e.subscribe}class Ht{constructor(e,t,n){this.previousValue=e,this.currentValue=t,this.firstChange=n}isFirstChange(){return this.firstChange}}class zt{}function Bt(e){const t=Error(`No component factory found for ${fe(e)}. Did you add it to @NgModule.entryComponents?`);return t[qt]=e,t}const qt="ngComponent";class Gt{resolveComponentFactory(e){throw Bt(e)}}let Wt=(()=>{class e{}return e.NULL=new Gt,e})();class Zt{constructor(e,t,n){this._parent=t,this._ngModule=n,this._factories=new Map;for(let r=0;r<e.length;r++){const t=e[r];this._factories.set(t.componentType,t)}}resolveComponentFactory(e){let t=this._factories.get(e);if(!t&&this._parent&&(t=this._parent.resolveComponentFactory(e)),!t)throw Bt(e);return new Qt(t,this._ngModule)}}class Qt extends zt{constructor(e,t){super(),this.factory=e,this.ngModule=t,this.selector=e.selector,this.componentType=e.componentType,this.ngContentSelectors=e.ngContentSelectors,this.inputs=e.inputs,this.outputs=e.outputs}create(e,t,n,r){return this.factory.create(e,t,n,r||this.ngModule)}}function Kt(...e){}let Yt=(()=>{class e{constructor(e){this.nativeElement=e}}return e.__NG_ELEMENT_ID__=()=>Jt(e),e})();const Jt=Kt;class Xt{}class en{}const tn=function(){var e={Important:1,DashCase:2};return e[e.Important]="Important",e[e.DashCase]="DashCase",e}();let nn=(()=>{class e{}return e.__NG_ELEMENT_ID__=()=>rn(),e})();const rn=Kt;class sn{constructor(e){this.full=e,this.major=e.split(".")[0],this.minor=e.split(".")[1],this.patch=e.split(".").slice(2).join(".")}}const ln=new sn("8.2.14");class on{constructor(){}supports(e){return jt(e)}create(e){return new un(e)}}const an=(e,t)=>t;class un{constructor(e){this.length=0,this._linkedRecords=null,this._unlinkedRecords=null,this._previousItHead=null,this._itHead=null,this._itTail=null,this._additionsHead=null,this._additionsTail=null,this._movesHead=null,this._movesTail=null,this._removalsHead=null,this._removalsTail=null,this._identityChangesHead=null,this._identityChangesTail=null,this._trackByFn=e||an}forEachItem(e){let t;for(t=this._itHead;null!==t;t=t._next)e(t)}forEachOperation(e){let t=this._itHead,n=this._removalsHead,r=0,s=null;for(;t||n;){const l=!n||t&&t.currentIndex<pn(n,r,s)?t:n,i=pn(l,r,s),o=l.currentIndex;if(l===n)r--,n=n._nextRemoved;else if(t=t._next,null==l.previousIndex)r++;else{s||(s=[]);const e=i-r,t=o-r;if(e!=t){for(let n=0;n<e;n++){const r=n<s.length?s[n]:s[n]=0,l=r+n;t<=l&&l<e&&(s[n]=r+1)}s[l.previousIndex]=t-e}}i!==o&&e(l,i,o)}}forEachPreviousItem(e){let t;for(t=this._previousItHead;null!==t;t=t._nextPrevious)e(t)}forEachAddedItem(e){let t;for(t=this._additionsHead;null!==t;t=t._nextAdded)e(t)}forEachMovedItem(e){let t;for(t=this._movesHead;null!==t;t=t._nextMoved)e(t)}forEachRemovedItem(e){let t;for(t=this._removalsHead;null!==t;t=t._nextRemoved)e(t)}forEachIdentityChange(e){let t;for(t=this._identityChangesHead;null!==t;t=t._nextIdentityChange)e(t)}diff(e){if(null==e&&(e=[]),!jt(e))throw new Error(`Error trying to diff '${fe(e)}'. Only arrays and iterables are allowed`);return this.check(e)?this:null}onDestroy(){}check(e){this._reset();let t,n,r,s=this._itHead,l=!1;if(Array.isArray(e)){this.length=e.length;for(let t=0;t<this.length;t++)n=e[t],r=this._trackByFn(t,n),null!==s&&Vt(s.trackById,r)?(l&&(s=this._verifyReinsertion(s,n,r,t)),Vt(s.item,n)||this._addIdentityChange(s,n)):(s=this._mismatch(s,n,r,t),l=!0),s=s._next}else t=0,function(e,t){if(Array.isArray(e))for(let n=0;n<e.length;n++)t(e[n]);else{const n=e[Dt()]();let r;for(;!(r=n.next()).done;)t(r.value)}}(e,e=>{r=this._trackByFn(t,e),null!==s&&Vt(s.trackById,r)?(l&&(s=this._verifyReinsertion(s,e,r,t)),Vt(s.item,e)||this._addIdentityChange(s,e)):(s=this._mismatch(s,e,r,t),l=!0),s=s._next,t++}),this.length=t;return this._truncate(s),this.collection=e,this.isDirty}get isDirty(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}_reset(){if(this.isDirty){let e,t;for(e=this._previousItHead=this._itHead;null!==e;e=e._next)e._nextPrevious=e._next;for(e=this._additionsHead;null!==e;e=e._nextAdded)e.previousIndex=e.currentIndex;for(this._additionsHead=this._additionsTail=null,e=this._movesHead;null!==e;e=t)e.previousIndex=e.currentIndex,t=e._nextMoved;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(e,t,n,r){let s;return null===e?s=this._itTail:(s=e._prev,this._remove(e)),null!==(e=null===this._linkedRecords?null:this._linkedRecords.get(n,r))?(Vt(e.item,t)||this._addIdentityChange(e,t),this._moveAfter(e,s,r)):null!==(e=null===this._unlinkedRecords?null:this._unlinkedRecords.get(n,null))?(Vt(e.item,t)||this._addIdentityChange(e,t),this._reinsertAfter(e,s,r)):e=this._addAfter(new cn(t,n),s,r),e}_verifyReinsertion(e,t,n,r){let s=null===this._unlinkedRecords?null:this._unlinkedRecords.get(n,null);return null!==s?e=this._reinsertAfter(s,e._prev,r):e.currentIndex!=r&&(e.currentIndex=r,this._addToMoves(e,r)),e}_truncate(e){for(;null!==e;){const t=e._next;this._addToRemovals(this._unlink(e)),e=t}null!==this._unlinkedRecords&&this._unlinkedRecords.clear(),null!==this._additionsTail&&(this._additionsTail._nextAdded=null),null!==this._movesTail&&(this._movesTail._nextMoved=null),null!==this._itTail&&(this._itTail._next=null),null!==this._removalsTail&&(this._removalsTail._nextRemoved=null),null!==this._identityChangesTail&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(e,t,n){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(e);const r=e._prevRemoved,s=e._nextRemoved;return null===r?this._removalsHead=s:r._nextRemoved=s,null===s?this._removalsTail=r:s._prevRemoved=r,this._insertAfter(e,t,n),this._addToMoves(e,n),e}_moveAfter(e,t,n){return this._unlink(e),this._insertAfter(e,t,n),this._addToMoves(e,n),e}_addAfter(e,t,n){return this._insertAfter(e,t,n),this._additionsTail=null===this._additionsTail?this._additionsHead=e:this._additionsTail._nextAdded=e,e}_insertAfter(e,t,n){const r=null===t?this._itHead:t._next;return e._next=r,e._prev=t,null===r?this._itTail=e:r._prev=e,null===t?this._itHead=e:t._next=e,null===this._linkedRecords&&(this._linkedRecords=new dn),this._linkedRecords.put(e),e.currentIndex=n,e}_remove(e){return this._addToRemovals(this._unlink(e))}_unlink(e){null!==this._linkedRecords&&this._linkedRecords.remove(e);const t=e._prev,n=e._next;return null===t?this._itHead=n:t._next=n,null===n?this._itTail=t:n._prev=t,e}_addToMoves(e,t){return e.previousIndex===t?e:(this._movesTail=null===this._movesTail?this._movesHead=e:this._movesTail._nextMoved=e,e)}_addToRemovals(e){return null===this._unlinkedRecords&&(this._unlinkedRecords=new dn),this._unlinkedRecords.put(e),e.currentIndex=null,e._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=e,e._prevRemoved=null):(e._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=e),e}_addIdentityChange(e,t){return e.item=t,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=e:this._identityChangesTail._nextIdentityChange=e,e}}class cn{constructor(e,t){this.item=e,this.trackById=t,this.currentIndex=null,this.previousIndex=null,this._nextPrevious=null,this._prev=null,this._next=null,this._prevDup=null,this._nextDup=null,this._prevRemoved=null,this._nextRemoved=null,this._nextAdded=null,this._nextMoved=null,this._nextIdentityChange=null}}class hn{constructor(){this._head=null,this._tail=null}add(e){null===this._head?(this._head=this._tail=e,e._nextDup=null,e._prevDup=null):(this._tail._nextDup=e,e._prevDup=this._tail,e._nextDup=null,this._tail=e)}get(e,t){let n;for(n=this._head;null!==n;n=n._nextDup)if((null===t||t<=n.currentIndex)&&Vt(n.trackById,e))return n;return null}remove(e){const t=e._prevDup,n=e._nextDup;return null===t?this._head=n:t._nextDup=n,null===n?this._tail=t:n._prevDup=t,null===this._head}}class dn{constructor(){this.map=new Map}put(e){const t=e.trackById;let n=this.map.get(t);n||(n=new hn,this.map.set(t,n)),n.add(e)}get(e,t){const n=this.map.get(e);return n?n.get(e,t):null}remove(e){const t=e.trackById;return this.map.get(t).remove(e)&&this.map.delete(t),e}get isEmpty(){return 0===this.map.size}clear(){this.map.clear()}}function pn(e,t,n){const r=e.previousIndex;if(null===r)return r;let s=0;return n&&r<n.length&&(s=n[r]),r+t+s}class gn{constructor(){}supports(e){return e instanceof Map||Ft(e)}create(){return new fn}}class fn{constructor(){this._records=new Map,this._mapHead=null,this._appendAfter=null,this._previousMapHead=null,this._changesHead=null,this._changesTail=null,this._additionsHead=null,this._additionsTail=null,this._removalsHead=null,this._removalsTail=null}get isDirty(){return null!==this._additionsHead||null!==this._changesHead||null!==this._removalsHead}forEachItem(e){let t;for(t=this._mapHead;null!==t;t=t._next)e(t)}forEachPreviousItem(e){let t;for(t=this._previousMapHead;null!==t;t=t._nextPrevious)e(t)}forEachChangedItem(e){let t;for(t=this._changesHead;null!==t;t=t._nextChanged)e(t)}forEachAddedItem(e){let t;for(t=this._additionsHead;null!==t;t=t._nextAdded)e(t)}forEachRemovedItem(e){let t;for(t=this._removalsHead;null!==t;t=t._nextRemoved)e(t)}diff(e){if(e){if(!(e instanceof Map||Ft(e)))throw new Error(`Error trying to diff '${fe(e)}'. Only maps and objects are allowed`)}else e=new Map;return this.check(e)?this:null}onDestroy(){}check(e){this._reset();let t=this._mapHead;if(this._appendAfter=null,this._forEach(e,(e,n)=>{if(t&&t.key===n)this._maybeAddToChanges(t,e),this._appendAfter=t,t=t._next;else{const r=this._getOrCreateRecordForKey(n,e);t=this._insertBeforeOrAppend(t,r)}}),t){t._prev&&(t._prev._next=null),this._removalsHead=t;for(let e=t;null!==e;e=e._nextRemoved)e===this._mapHead&&(this._mapHead=null),this._records.delete(e.key),e._nextRemoved=e._next,e.previousValue=e.currentValue,e.currentValue=null,e._prev=null,e._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(e,t){if(e){const n=e._prev;return t._next=e,t._prev=n,e._prev=t,n&&(n._next=t),e===this._mapHead&&(this._mapHead=t),this._appendAfter=e,e}return this._appendAfter?(this._appendAfter._next=t,t._prev=this._appendAfter):this._mapHead=t,this._appendAfter=t,null}_getOrCreateRecordForKey(e,t){if(this._records.has(e)){const n=this._records.get(e);this._maybeAddToChanges(n,t);const r=n._prev,s=n._next;return r&&(r._next=s),s&&(s._prev=r),n._next=null,n._prev=null,n}const n=new mn(e);return this._records.set(e,n),n.currentValue=t,this._addToAdditions(n),n}_reset(){if(this.isDirty){let e;for(this._previousMapHead=this._mapHead,e=this._previousMapHead;null!==e;e=e._next)e._nextPrevious=e._next;for(e=this._changesHead;null!==e;e=e._nextChanged)e.previousValue=e.currentValue;for(e=this._additionsHead;null!=e;e=e._nextAdded)e.previousValue=e.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(e,t){Vt(t,e.currentValue)||(e.previousValue=e.currentValue,e.currentValue=t,this._addToChanges(e))}_addToAdditions(e){null===this._additionsHead?this._additionsHead=this._additionsTail=e:(this._additionsTail._nextAdded=e,this._additionsTail=e)}_addToChanges(e){null===this._changesHead?this._changesHead=this._changesTail=e:(this._changesTail._nextChanged=e,this._changesTail=e)}_forEach(e,t){e instanceof Map?e.forEach(t):Object.keys(e).forEach(n=>t(e[n],n))}}class mn{constructor(e){this.key=e,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._prev=null,this._nextAdded=null,this._nextRemoved=null,this._nextChanged=null}}let vn=(()=>{class e{constructor(e){this.factories=e}static create(t,n){if(null!=n){const e=n.factories.slice();t=t.concat(e)}return new e(t)}static extend(t){return{provide:e,useFactory:n=>{if(!n)throw new Error("Cannot extend IterableDiffers without a parent injector");return e.create(t,n)},deps:[[e,new ue,new oe]]}}find(e){const t=this.factories.find(t=>t.supports(e));if(null!=t)return t;throw new Error(`Cannot find a differ supporting object '${e}' of type '${n=e,n.name||typeof n}'`);var n}}return e.ngInjectableDef=de({token:e,providedIn:"root",factory:()=>new e([new on])}),e})(),yn=(()=>{class e{constructor(e){this.factories=e}static create(t,n){if(n){const e=n.factories.slice();t=t.concat(e)}return new e(t)}static extend(t){return{provide:e,useFactory:n=>{if(!n)throw new Error("Cannot extend KeyValueDiffers without a parent injector");return e.create(t,n)},deps:[[e,new ue,new oe]]}}find(e){const t=this.factories.find(t=>t.supports(e));if(t)return t;throw new Error(`Cannot find a differ supporting object '${e}'`)}}return e.ngInjectableDef=de({token:e,providedIn:"root",factory:()=>new e([new gn])}),e})();const _n=[new gn],wn=new vn([new on]),bn=new yn(_n);let Cn=(()=>{class e{}return e.__NG_ELEMENT_ID__=()=>xn(e,Yt),e})();const xn=Kt;let Sn=(()=>{class e{}return e.__NG_ELEMENT_ID__=()=>En(e,Yt),e})();const En=Kt;function Tn(e,t,n,r){let s=`ExpressionChangedAfterItHasBeenCheckedError: Expression has changed after it was checked. Previous value: '${t}'. Current value: '${n}'.`;return r&&(s+=" It seems like the view has been created after its parent and its children have been dirty checked. Has it been created in a change detection hook ?"),function(e,t){const n=new Error(e);return kn(n,t),n}(s,e)}function kn(e,t){e.ngDebugContext=t,e.ngErrorLogger=t.logError.bind(t)}function An(e){return new Error(`ViewDestroyedError: Attempt to use a destroyed view: ${e}`)}function In(e,t,n){const r=e.state,s=1792&r;return s===t?(e.state=-1793&r|n,e.initIndex=-1,!0):s===n}function Pn(e,t,n){return(1792&e.state)===t&&e.initIndex<=n&&(e.initIndex=n+1,!0)}function On(e,t){return e.nodes[t]}function Rn(e,t){return e.nodes[t]}function Nn(e,t){return e.nodes[t]}function Dn(e,t){return e.nodes[t]}function Vn(e,t){return e.nodes[t]}const Mn={setCurrentNode:void 0,createRootView:void 0,createEmbeddedView:void 0,createComponentView:void 0,createNgModuleRef:void 0,overrideProvider:void 0,overrideComponentView:void 0,clearOverrides:void 0,checkAndUpdateView:void 0,checkNoChangesView:void 0,destroyView:void 0,resolveDep:void 0,createDebugContext:void 0,handleEvent:void 0,updateDirectives:void 0,updateRenderer:void 0,dirtyParentQueries:void 0},Un=()=>{},jn=new Map;function Fn(e){let t=jn.get(e);return t||(t=fe(e)+"_"+jn.size,jn.set(e,t)),t}function Ln(e){return{id:"$$undefined",styles:e.styles,encapsulation:e.encapsulation,data:e.data}}let $n=0;function Hn(e,t,n,r){return!(!(2&e.state)&&Vt(e.oldValues[t.bindingIndex+n],r))}function zn(e,t,n,r){return!!Hn(e,t,n,r)&&(e.oldValues[t.bindingIndex+n]=r,!0)}function Bn(e,t,n,r){const s=e.oldValues[t.bindingIndex+n];if(1&e.state||!Mt(s,r)){const l=t.bindings[n].name;throw Tn(Mn.createDebugContext(e,t.nodeIndex),`${l}: ${s}`,`${l}: ${r}`,0!=(1&e.state))}}function qn(e){let t=e;for(;t;)2&t.def.flags&&(t.state|=8),t=t.viewContainerParent||t.parent}function Gn(e,t){let n=e;for(;n&&n!==t;)n.state|=64,n=n.viewContainerParent||n.parent}function Wn(e,t,n,r){try{return qn(33554432&e.def.nodes[t].flags?Rn(e,t).componentView:e),Mn.handleEvent(e,t,n,r)}catch(s){e.root.errorHandler.handleError(s)}}function Zn(e){return e.parent?Rn(e.parent,e.parentNodeDef.nodeIndex):null}function Qn(e){return e.parent?e.parentNodeDef.parent:null}function Kn(e,t){switch(201347067&t.flags){case 1:return Rn(e,t.nodeIndex).renderElement;case 2:return On(e,t.nodeIndex).renderText}}function Yn(e){return!!e.parent&&!!(32768&e.parentNodeDef.flags)}function Jn(e){return!(!e.parent||32768&e.parentNodeDef.flags)}function Xn(e){const t={};let n=0;const r={};return e&&e.forEach(([e,s])=>{"number"==typeof e?(t[e]=s,n|=function(e){return 1<<e%32}(e)):r[e]=s}),{matchedQueries:t,references:r,matchedQueryIds:n}}function er(e,t){return e.map(e=>{let n,r;return Array.isArray(e)?[r,n]=e:(r=0,n=e),n&&("function"==typeof n||"object"==typeof n)&&t&&Object.defineProperty(n,"__source",{value:t,configurable:!0}),{flags:r,token:n,tokenKey:Fn(n)}})}function tr(e,t,n){let r=n.renderParent;return r?0==(1&r.flags)||0==(33554432&r.flags)||r.element.componentRendererType&&r.element.componentRendererType.encapsulation===je.Native?Rn(e,n.renderParent.nodeIndex).renderElement:void 0:t}const nr=new WeakMap;function rr(e){let t=nr.get(e);return t||(t=e(()=>Un),t.factory=e,nr.set(e,t)),t}function sr(e,t,n,r,s){3===t&&(n=e.renderer.parentNode(Kn(e,e.def.lastRenderRootNode))),lr(e,t,0,e.def.nodes.length-1,n,r,s)}function lr(e,t,n,r,s,l,i){for(let o=n;o<=r;o++){const n=e.def.nodes[o];11&n.flags&&or(e,n,t,s,l,i),o+=n.childCount}}function ir(e,t,n,r,s,l){let i=e;for(;i&&!Yn(i);)i=i.parent;const o=i.parent,a=Qn(i),u=a.nodeIndex+a.childCount;for(let c=a.nodeIndex+1;c<=u;c++){const e=o.def.nodes[c];e.ngContentIndex===t&&or(o,e,n,r,s,l),c+=e.childCount}if(!o.parent){const i=e.root.projectableNodes[t];if(i)for(let t=0;t<i.length;t++)ar(e,i[t],n,r,s,l)}}function or(e,t,n,r,s,l){if(8&t.flags)ir(e,t.ngContent.index,n,r,s,l);else{const i=Kn(e,t);if(3===n&&33554432&t.flags&&48&t.bindingFlags?(16&t.bindingFlags&&ar(e,i,n,r,s,l),32&t.bindingFlags&&ar(Rn(e,t.nodeIndex).componentView,i,n,r,s,l)):ar(e,i,n,r,s,l),16777216&t.flags){const i=Rn(e,t.nodeIndex).viewContainer._embeddedViews;for(let e=0;e<i.length;e++)sr(i[e],n,r,s,l)}1&t.flags&&!t.element.name&&lr(e,n,t.nodeIndex+1,t.nodeIndex+t.childCount,r,s,l)}}function ar(e,t,n,r,s,l){const i=e.renderer;switch(n){case 1:i.appendChild(r,t);break;case 2:i.insertBefore(r,t,s);break;case 3:i.removeChild(r,t);break;case 0:l.push(t)}}const ur=/^:([^:]+):(.+)$/;function cr(e){if(":"===e[0]){const t=e.match(ur);return[t[1],t[2]]}return["",e]}function hr(e){let t=0;for(let n=0;n<e.length;n++)t|=e[n].flags;return t}function dr(e,t,n,r,s,l,i,o,a,u,c,h,d,p,g,f,m,v,y,_){switch(e){case 1:return t+pr(n)+r;case 2:return t+pr(n)+r+pr(s)+l;case 3:return t+pr(n)+r+pr(s)+l+pr(i)+o;case 4:return t+pr(n)+r+pr(s)+l+pr(i)+o+pr(a)+u;case 5:return t+pr(n)+r+pr(s)+l+pr(i)+o+pr(a)+u+pr(c)+h;case 6:return t+pr(n)+r+pr(s)+l+pr(i)+o+pr(a)+u+pr(c)+h+pr(d)+p;case 7:return t+pr(n)+r+pr(s)+l+pr(i)+o+pr(a)+u+pr(c)+h+pr(d)+p+pr(g)+f;case 8:return t+pr(n)+r+pr(s)+l+pr(i)+o+pr(a)+u+pr(c)+h+pr(d)+p+pr(g)+f+pr(m)+v;case 9:return t+pr(n)+r+pr(s)+l+pr(i)+o+pr(a)+u+pr(c)+h+pr(d)+p+pr(g)+f+pr(m)+v+pr(y)+_;default:throw new Error("Does not support more than 9 expressions")}}function pr(e){return null!=e?e.toString():""}const gr=new Object,fr=Fn(St),mr=Fn(Ee),vr=Fn(De);function yr(e,t,n,r){return n=ye(n),{index:-1,deps:er(r,fe(t)),flags:e,token:t,value:n}}function _r(e,t,n=St.THROW_IF_NOT_FOUND){const r=Pe(e);try{if(8&t.flags)return t.token;if(2&t.flags&&(n=null),1&t.flags)return e._parent.get(t.token,n);const i=t.tokenKey;switch(i){case fr:case mr:case vr:return e}const o=e._def.providersByKey[i];let a;if(o){let t=e._providers[o.index];return void 0===t&&(t=e._providers[o.index]=wr(e,o)),t===gr?void 0:t}if((a=pe(t.token))&&(s=e,null!=(l=a).providedIn&&(function(e,t){return e._def.modules.indexOf(t)>-1}(s,l.providedIn)||"root"===l.providedIn&&s._def.isRoot))){const n=e._providers.length;return e._def.providers[n]=e._def.providersByKey[t.tokenKey]={flags:5120,value:a.factory,deps:[],index:n,token:t.token},e._providers[n]=gr,e._providers[n]=wr(e,e._def.providersByKey[t.tokenKey])}return 4&t.flags?n:e._parent.get(t.token,n)}finally{Pe(r)}var s,l}function wr(e,t){let n;switch(201347067&t.flags){case 512:n=function(e,t,n){const r=n.length;switch(r){case 0:return new t;case 1:return new t(_r(e,n[0]));case 2:return new t(_r(e,n[0]),_r(e,n[1]));case 3:return new t(_r(e,n[0]),_r(e,n[1]),_r(e,n[2]));default:const s=new Array(r);for(let t=0;t<r;t++)s[t]=_r(e,n[t]);return new t(...s)}}(e,t.value,t.deps);break;case 1024:n=function(e,t,n){const r=n.length;switch(r){case 0:return t();case 1:return t(_r(e,n[0]));case 2:return t(_r(e,n[0]),_r(e,n[1]));case 3:return t(_r(e,n[0]),_r(e,n[1]),_r(e,n[2]));default:const s=Array(r);for(let t=0;t<r;t++)s[t]=_r(e,n[t]);return t(...s)}}(e,t.value,t.deps);break;case 2048:n=_r(e,t.deps[0]);break;case 256:n=t.value}return n===gr||null===n||"object"!=typeof n||131072&t.flags||"function"!=typeof n.ngOnDestroy||(t.flags|=131072),void 0===n?gr:n}function br(e,t){const n=e.viewContainer._embeddedViews;if((null==t||t>=n.length)&&(t=n.length-1),t<0)return null;const r=n[t];return r.viewContainerParent=null,Ue(n,t),Mn.dirtyParentQueries(r),xr(r),r}function Cr(e,t,n){const r=t?Kn(t,t.def.lastRenderRootNode):e.renderElement,s=n.renderer.parentNode(r),l=n.renderer.nextSibling(r);sr(n,2,s,l,void 0)}function xr(e){sr(e,3,null,null,void 0)}const Sr=new Object;function Er(e,t,n,r,s,l){return new Tr(e,t,n,r,s,l)}class Tr extends zt{constructor(e,t,n,r,s,l){super(),this.selector=e,this.componentType=t,this._inputs=r,this._outputs=s,this.ngContentSelectors=l,this.viewDefFactory=n}get inputs(){const e=[],t=this._inputs;for(let n in t)e.push({propName:n,templateName:t[n]});return e}get outputs(){const e=[];for(let t in this._outputs)e.push({propName:t,templateName:this._outputs[t]});return e}create(e,t,n,r){if(!r)throw new Error("ngModule should be provided");const s=rr(this.viewDefFactory),l=s.nodes[0].element.componentProvider.nodeIndex,i=Mn.createRootView(e,t||[],n,s,r,Sr),o=Nn(i,l).instance;return n&&i.renderer.setAttribute(Rn(i,0).renderElement,"ng-version",ln.full),new kr(i,new Or(i),o)}}class kr extends class{}{constructor(e,t,n){super(),this._view=e,this._viewRef=t,this._component=n,this._elDef=this._view.def.nodes[0],this.hostView=t,this.changeDetectorRef=t,this.instance=n}get location(){return new Yt(Rn(this._view,this._elDef.nodeIndex).renderElement)}get injector(){return new Vr(this._view,this._elDef)}get componentType(){return this._component.constructor}destroy(){this._viewRef.destroy()}onDestroy(e){this._viewRef.onDestroy(e)}}function Ar(e,t,n){return new Ir(e,t,n)}class Ir{constructor(e,t,n){this._view=e,this._elDef=t,this._data=n,this._embeddedViews=[]}get element(){return new Yt(this._data.renderElement)}get injector(){return new Vr(this._view,this._elDef)}get parentInjector(){let e=this._view,t=this._elDef.parent;for(;!t&&e;)t=Qn(e),e=e.parent;return e?new Vr(e,t):new Vr(this._view,null)}clear(){for(let e=this._embeddedViews.length-1;e>=0;e--){const t=br(this._data,e);Mn.destroyView(t)}}get(e){const t=this._embeddedViews[e];if(t){const e=new Or(t);return e.attachToViewContainerRef(this),e}return null}get length(){return this._embeddedViews.length}createEmbeddedView(e,t,n){const r=e.createEmbeddedView(t||{});return this.insert(r,n),r}createComponent(e,t,n,r,s){const l=n||this.parentInjector;s||e instanceof Qt||(s=l.get(De));const i=e.create(l,r,void 0,s);return this.insert(i.hostView,t),i}insert(e,t){if(e.destroyed)throw new Error("Cannot insert a destroyed View in a ViewContainer!");const n=e;return function(e,t,n,r){let s=t.viewContainer._embeddedViews;null==n&&(n=s.length),r.viewContainerParent=e,Me(s,n,r),function(e,t){const n=Zn(t);if(!n||n===e||16&t.state)return;t.state|=16;let r=n.template._projectedViews;r||(r=n.template._projectedViews=[]),r.push(t),function(e,t){if(4&t.flags)return;e.nodeFlags|=4,t.flags|=4;let n=t.parent;for(;n;)n.childFlags|=4,n=n.parent}(t.parent.def,t.parentNodeDef)}(t,r),Mn.dirtyParentQueries(r),Cr(t,n>0?s[n-1]:null,r)}(this._view,this._data,t,n._view),n.attachToViewContainerRef(this),e}move(e,t){if(e.destroyed)throw new Error("Cannot move a destroyed View in a ViewContainer!");const n=this._embeddedViews.indexOf(e._view);return function(e,t,n){const r=e.viewContainer._embeddedViews,s=r[t];Ue(r,t),null==n&&(n=r.length),Me(r,n,s),Mn.dirtyParentQueries(s),xr(s),Cr(e,n>0?r[n-1]:null,s)}(this._data,n,t),e}indexOf(e){return this._embeddedViews.indexOf(e._view)}remove(e){const t=br(this._data,e);t&&Mn.destroyView(t)}detach(e){const t=br(this._data,e);return t?new Or(t):null}}function Pr(e){return new Or(e)}class Or{constructor(e){this._view=e,this._viewContainerRef=null,this._appRef=null}get rootNodes(){return function(e){const t=[];return sr(e,0,void 0,void 0,t),t}(this._view)}get context(){return this._view.context}get destroyed(){return 0!=(128&this._view.state)}markForCheck(){qn(this._view)}detach(){this._view.state&=-5}detectChanges(){const e=this._view.root.rendererFactory;e.begin&&e.begin();try{Mn.checkAndUpdateView(this._view)}finally{e.end&&e.end()}}checkNoChanges(){Mn.checkNoChangesView(this._view)}reattach(){this._view.state|=4}onDestroy(e){this._view.disposables||(this._view.disposables=[]),this._view.disposables.push(e)}destroy(){this._appRef?this._appRef.detachView(this):this._viewContainerRef&&this._viewContainerRef.detach(this._viewContainerRef.indexOf(this)),Mn.destroyView(this._view)}detachFromAppRef(){this._appRef=null,xr(this._view),Mn.dirtyParentQueries(this._view)}attachToAppRef(e){if(this._viewContainerRef)throw new Error("This view is already attached to a ViewContainer!");this._appRef=e}attachToViewContainerRef(e){if(this._appRef)throw new Error("This view is already attached directly to the ApplicationRef!");this._viewContainerRef=e}}function Rr(e,t){return new Nr(e,t)}class Nr extends Cn{constructor(e,t){super(),this._parentView=e,this._def=t}createEmbeddedView(e){return new Or(Mn.createEmbeddedView(this._parentView,this._def,this._def.element.template,e))}get elementRef(){return new Yt(Rn(this._parentView,this._def.nodeIndex).renderElement)}}function Dr(e,t){return new Vr(e,t)}class Vr{constructor(e,t){this.view=e,this.elDef=t}get(e,t=St.THROW_IF_NOT_FOUND){return Mn.resolveDep(this.view,this.elDef,!!this.elDef&&0!=(33554432&this.elDef.flags),{flags:0,token:e,tokenKey:Fn(e)},t)}}function Mr(e,t){const n=e.def.nodes[t];if(1&n.flags){const t=Rn(e,n.nodeIndex);return n.element.template?t.template:t.renderElement}if(2&n.flags)return On(e,n.nodeIndex).renderText;if(20240&n.flags)return Nn(e,n.nodeIndex).instance;throw new Error(`Illegal state: read nodeValue for node index ${t}`)}function Ur(e){return new jr(e.renderer)}class jr{constructor(e){this.delegate=e}selectRootElement(e){return this.delegate.selectRootElement(e)}createElement(e,t){const[n,r]=cr(t),s=this.delegate.createElement(r,n);return e&&this.delegate.appendChild(e,s),s}createViewRoot(e){return e}createTemplateAnchor(e){const t=this.delegate.createComment("");return e&&this.delegate.appendChild(e,t),t}createText(e,t){const n=this.delegate.createText(t);return e&&this.delegate.appendChild(e,n),n}projectNodes(e,t){for(let n=0;n<t.length;n++)this.delegate.appendChild(e,t[n])}attachViewAfter(e,t){const n=this.delegate.parentNode(e),r=this.delegate.nextSibling(e);for(let s=0;s<t.length;s++)this.delegate.insertBefore(n,t[s],r)}detachView(e){for(let t=0;t<e.length;t++){const n=e[t],r=this.delegate.parentNode(n);this.delegate.removeChild(r,n)}}destroyView(e,t){for(let n=0;n<t.length;n++)this.delegate.destroyNode(t[n])}listen(e,t,n){return this.delegate.listen(e,t,n)}listenGlobal(e,t,n){return this.delegate.listen(e,t,n)}setElementProperty(e,t,n){this.delegate.setProperty(e,t,n)}setElementAttribute(e,t,n){const[r,s]=cr(t);null!=n?this.delegate.setAttribute(e,s,n,r):this.delegate.removeAttribute(e,s,r)}setBindingDebugInfo(e,t,n){}setElementClass(e,t,n){n?this.delegate.addClass(e,t):this.delegate.removeClass(e,t)}setElementStyle(e,t,n){null!=n?this.delegate.setStyle(e,t,n):this.delegate.removeStyle(e,t)}invokeElementMethod(e,t,n){e[t].apply(e,n)}setText(e,t){this.delegate.setValue(e,t)}animate(){throw new Error("Renderer.animate is no longer supported!")}}function Fr(e,t,n,r){return new Lr(e,t,n,r)}class Lr{constructor(e,t,n,r){this._moduleType=e,this._parent=t,this._bootstrapComponents=n,this._def=r,this._destroyListeners=[],this._destroyed=!1,this.injector=this,function(e){const t=e._def,n=e._providers=new Array(t.providers.length);for(let r=0;r<t.providers.length;r++){const s=t.providers[r];4096&s.flags||void 0===n[r]&&(n[r]=wr(e,s))}}(this)}get(e,t=St.THROW_IF_NOT_FOUND,n=ce.Default){let r=0;return n&ce.SkipSelf?r|=1:n&ce.Self&&(r|=4),_r(this,{token:e,tokenKey:Fn(e),flags:r},t)}get instance(){return this.get(this._moduleType)}get componentFactoryResolver(){return this.get(Wt)}destroy(){if(this._destroyed)throw new Error(`The ng module ${fe(this.instance.constructor)} has already been destroyed.`);this._destroyed=!0,function(e,t){const n=e._def,r=new Set;for(let s=0;s<n.providers.length;s++)if(131072&n.providers[s].flags){const t=e._providers[s];if(t&&t!==gr){const e=t.ngOnDestroy;"function"!=typeof e||r.has(t)||(e.apply(t),r.add(t))}}}(this),this._destroyListeners.forEach(e=>e())}onDestroy(e){this._destroyListeners.push(e)}}const $r=Fn(Xt),Hr=Fn(nn),zr=Fn(Yt),Br=Fn(Sn),qr=Fn(Cn),Gr=Fn(wt),Wr=Fn(St),Zr=Fn(Ee);function Qr(e,t,n,r,s,l,i,o){const a=[];if(i)for(let c in i){const[e,t]=i[c];a[e]={flags:8,name:c,nonMinifiedName:t,ns:null,securityContext:null,suffix:null}}const u=[];if(o)for(let c in o)u.push({type:1,propName:c,target:null,eventName:o[c]});return Yr(e,t|=16384,n,r,s,s,l,a,u)}function Kr(e,t,n,r,s){return Yr(-1,e,t,0,n,r,s)}function Yr(e,t,n,r,s,l,i,o,a){const{matchedQueries:u,references:c,matchedQueryIds:h}=Xn(n);a||(a=[]),o||(o=[]),l=ye(l);const d=er(i,fe(s));return{nodeIndex:-1,parent:null,renderParent:null,bindingIndex:-1,outputIndex:-1,checkIndex:e,flags:t,childFlags:0,directChildFlags:0,childMatchedQueries:0,matchedQueries:u,matchedQueryIds:h,references:c,ngContentIndex:-1,childCount:r,bindings:o,bindingFlags:hr(o),outputs:a,element:null,provider:{token:s,value:l,deps:d},text:null,query:null,ngContent:null}}function Jr(e,t){return ns(e,t)}function Xr(e,t){let n=e;for(;n.parent&&!Yn(n);)n=n.parent;return rs(n.parent,Qn(n),!0,t.provider.value,t.provider.deps)}function es(e,t){const n=rs(e,t.parent,(32768&t.flags)>0,t.provider.value,t.provider.deps);if(t.outputs.length)for(let r=0;r<t.outputs.length;r++){const s=t.outputs[r],l=n[s.propName];if(!$t(l))throw new Error(`@Output ${s.propName} not initialized in '${n.constructor.name}'.`);{const n=l.subscribe(ts(e,t.parent.nodeIndex,s.eventName));e.disposables[t.outputIndex+r]=n.unsubscribe.bind(n)}}return n}function ts(e,t,n){return r=>Wn(e,t,n,r)}function ns(e,t){const n=(8192&t.flags)>0,r=t.provider;switch(201347067&t.flags){case 512:return rs(e,t.parent,n,r.value,r.deps);case 1024:return function(e,t,n,r,s){const l=s.length;switch(l){case 0:return r();case 1:return r(ls(e,t,n,s[0]));case 2:return r(ls(e,t,n,s[0]),ls(e,t,n,s[1]));case 3:return r(ls(e,t,n,s[0]),ls(e,t,n,s[1]),ls(e,t,n,s[2]));default:const i=Array(l);for(let r=0;r<l;r++)i[r]=ls(e,t,n,s[r]);return r(...i)}}(e,t.parent,n,r.value,r.deps);case 2048:return ls(e,t.parent,n,r.deps[0]);case 256:return r.value}}function rs(e,t,n,r,s){const l=s.length;switch(l){case 0:return new r;case 1:return new r(ls(e,t,n,s[0]));case 2:return new r(ls(e,t,n,s[0]),ls(e,t,n,s[1]));case 3:return new r(ls(e,t,n,s[0]),ls(e,t,n,s[1]),ls(e,t,n,s[2]));default:const i=new Array(l);for(let r=0;r<l;r++)i[r]=ls(e,t,n,s[r]);return new r(...i)}}const ss={};function ls(e,t,n,r,s=St.THROW_IF_NOT_FOUND){if(8&r.flags)return r.token;const l=e;2&r.flags&&(s=null);const i=r.tokenKey;i===Gr&&(n=!(!t||!t.element.componentView)),t&&1&r.flags&&(n=!1,t=t.parent);let o=e;for(;o;){if(t)switch(i){case $r:return Ur(is(o,t,n));case Hr:return is(o,t,n).renderer;case zr:return new Yt(Rn(o,t.nodeIndex).renderElement);case Br:return Rn(o,t.nodeIndex).viewContainer;case qr:if(t.element.template)return Rn(o,t.nodeIndex).template;break;case Gr:return Pr(is(o,t,n));case Wr:case Zr:return Dr(o,t);default:const e=(n?t.element.allProviders:t.element.publicProviders)[i];if(e){let t=Nn(o,e.nodeIndex);return t||(t={instance:ns(o,e)},o.nodes[e.nodeIndex]=t),t.instance}}n=Yn(o),t=Qn(o),o=o.parent,4&r.flags&&(o=null)}const a=l.root.injector.get(r.token,ss);return a!==ss||s===ss?a:l.root.ngModule.injector.get(r.token,s)}function is(e,t,n){let r;if(n)r=Rn(e,t.nodeIndex).componentView;else for(r=e;r.parent&&!Yn(r);)r=r.parent;return r}function os(e,t,n,r,s,l){if(32768&n.flags){const t=Rn(e,n.parent.nodeIndex).componentView;2&t.def.flags&&(t.state|=8)}if(t.instance[n.bindings[r].name]=s,524288&n.flags){l=l||{};const t=Ut.unwrap(e.oldValues[n.bindingIndex+r]);l[n.bindings[r].nonMinifiedName]=new Ht(t,s,0!=(2&e.state))}return e.oldValues[n.bindingIndex+r]=s,l}function as(e,t){if(!(e.def.nodeFlags&t))return;const n=e.def.nodes;let r=0;for(let s=0;s<n.length;s++){const l=n[s];let i=l.parent;for(!i&&l.flags&t&&cs(e,s,l.flags&t,r++),0==(l.childFlags&t)&&(s+=l.childCount);i&&1&i.flags&&s===i.nodeIndex+i.childCount;)i.directChildFlags&t&&(r=us(e,i,t,r)),i=i.parent}}function us(e,t,n,r){for(let s=t.nodeIndex+1;s<=t.nodeIndex+t.childCount;s++){const t=e.def.nodes[s];t.flags&n&&cs(e,s,t.flags&n,r++),s+=t.childCount}return r}function cs(e,t,n,r){const s=Nn(e,t);if(!s)return;const l=s.instance;l&&(Mn.setCurrentNode(e,t),1048576&n&&Pn(e,512,r)&&l.ngAfterContentInit(),2097152&n&&l.ngAfterContentChecked(),4194304&n&&Pn(e,768,r)&&l.ngAfterViewInit(),8388608&n&&l.ngAfterViewChecked(),131072&n&&l.ngOnDestroy())}const hs=new Se("SCHEDULER_TOKEN",{providedIn:"root",factory:()=>Fe}),ds={},ps=function(){var e={LocaleId:0,DayPeriodsFormat:1,DayPeriodsStandalone:2,DaysFormat:3,DaysStandalone:4,MonthsFormat:5,MonthsStandalone:6,Eras:7,FirstDayOfWeek:8,WeekendRange:9,DateFormat:10,TimeFormat:11,DateTimeFormat:12,NumberSymbols:13,NumberFormats:14,CurrencySymbol:15,CurrencyName:16,Currencies:17,PluralCase:18,ExtraData:19};return e[e.LocaleId]="LocaleId",e[e.DayPeriodsFormat]="DayPeriodsFormat",e[e.DayPeriodsStandalone]="DayPeriodsStandalone",e[e.DaysFormat]="DaysFormat",e[e.DaysStandalone]="DaysStandalone",e[e.MonthsFormat]="MonthsFormat",e[e.MonthsStandalone]="MonthsStandalone",e[e.Eras]="Eras",e[e.FirstDayOfWeek]="FirstDayOfWeek",e[e.WeekendRange]="WeekendRange",e[e.DateFormat]="DateFormat",e[e.TimeFormat]="TimeFormat",e[e.DateTimeFormat]="DateTimeFormat",e[e.NumberSymbols]="NumberSymbols",e[e.NumberFormats]="NumberFormats",e[e.CurrencySymbol]="CurrencySymbol",e[e.CurrencyName]="CurrencyName",e[e.Currencies]="Currencies",e[e.PluralCase]="PluralCase",e[e.ExtraData]="ExtraData",e}(),gs=void 0;var fs=["en",[["a","p"],["AM","PM"],gs],[["AM","PM"],gs,gs],[["S","M","T","W","T","F","S"],["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],["Su","Mo","Tu","We","Th","Fr","Sa"]],gs,[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],["January","February","March","April","May","June","July","August","September","October","November","December"]],gs,[["B","A"],["BC","AD"],["Before Christ","Anno Domini"]],0,[6,0],["M/d/yy","MMM d, y","MMMM d, y","EEEE, MMMM d, y"],["h:mm a","h:mm:ss a","h:mm:ss a z","h:mm:ss a zzzz"],["{1}, {0}",gs,"{1} 'at' {0}",gs],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"$","US Dollar",{},function(e){let t=Math.floor(Math.abs(e)),n=e.toString().replace(/^[^.]*\.?/,"").length;return 1===t&&0===n?1:5}];class ms extends k{constructor(e=!1){super(),this.__isAsync=e}emit(e){super.next(e)}subscribe(e,t,n){let r,s=e=>null,l=()=>null;e&&"object"==typeof e?(r=this.__isAsync?t=>{setTimeout(()=>e.next(t))}:t=>{e.next(t)},e.error&&(s=this.__isAsync?t=>{setTimeout(()=>e.error(t))}:t=>{e.error(t)}),e.complete&&(l=this.__isAsync?()=>{setTimeout(()=>e.complete())}:()=>{e.complete()})):(r=this.__isAsync?t=>{setTimeout(()=>e(t))}:t=>{e(t)},t&&(s=this.__isAsync?e=>{setTimeout(()=>t(e))}:e=>{t(e)}),n&&(l=this.__isAsync?()=>{setTimeout(()=>n())}:()=>{n()}));const i=super.subscribe(r,s,l);return e instanceof d&&e.add(i),i}}function vs(){return this._results[Dt()]()}class ys{constructor(){this.dirty=!0,this._results=[],this.changes=new ms,this.length=0;const e=Dt(),t=ys.prototype;t[e]||(t[e]=vs)}map(e){return this._results.map(e)}filter(e){return this._results.filter(e)}find(e){return this._results.find(e)}reduce(e,t){return this._results.reduce(e,t)}forEach(e){this._results.forEach(e)}some(e){return this._results.some(e)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(e){this._results=function e(t,n){void 0===n&&(n=t);for(let r=0;r<t.length;r++){let s=t[r];Array.isArray(s)?(n===t&&(n=t.slice(0,r)),e(s,n)):n!==t&&n.push(s)}return n}(e),this.dirty=!1,this.length=this._results.length,this.last=this._results[this.length-1],this.first=this._results[0]}notifyOnChanges(){this.changes.emit(this)}setDirty(){this.dirty=!0}destroy(){this.changes.complete(),this.changes.unsubscribe()}}const _s=new Se("Application Initializer");class ws{constructor(e){this.appInits=e,this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,t)=>{this.resolve=e,this.reject=t})}runInitializers(){if(this.initialized)return;const e=[],t=()=>{this.done=!0,this.resolve()};if(this.appInits)for(let n=0;n<this.appInits.length;n++){const t=this.appInits[n]();Lt(t)&&e.push(t)}Promise.all(e).then(()=>{t()}).catch(e=>{this.reject(e)}),0===e.length&&t(),this.initialized=!0}}const bs=new Se("AppId");function Cs(){return`${xs()}${xs()}${xs()}`}function xs(){return String.fromCharCode(97+Math.floor(25*Math.random()))}const Ss=new Se("Platform Initializer"),Es=new Se("Platform ID"),Ts=new Se("appBootstrapListener");class ks{log(e){console.log(e)}warn(e){console.warn(e)}}const As=new Se("LocaleId");function Is(){throw new Error("Runtime compiler is not loaded")}const Ps=Is,Os=Is,Rs=Is,Ns=Is;class Ds{constructor(){this.compileModuleSync=Ps,this.compileModuleAsync=Os,this.compileModuleAndAllComponentsSync=Rs,this.compileModuleAndAllComponentsAsync=Ns}clearCache(){}clearCacheFor(e){}getModuleId(e){}}class Vs{}let Ms,Us;function js(){const e=xe.wtf;return!(!e||(Ms=e.trace,!Ms)||(Us=Ms.events,0))}const Fs=js();function Ls(e,t){return null}const $s=Fs?function(e,t=null){return Us.createScope(e,t)}:(e,t)=>Ls,Hs=Fs?function(e,t){return Ms.leaveScope(e,t),t}:(e,t)=>t,zs=(()=>Promise.resolve(0))();function Bs(e){"undefined"==typeof Zone?zs.then(()=>{e&&e.apply(null,null)}):Zone.current.scheduleMicroTask("scheduleMicrotask",e)}class qs{constructor({enableLongStackTrace:e=!1}){if(this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new ms(!1),this.onMicrotaskEmpty=new ms(!1),this.onStable=new ms(!1),this.onError=new ms(!1),"undefined"==typeof Zone)throw new Error("In this configuration Angular requires Zone.js");var t;Zone.assertZonePatched(),this._nesting=0,this._outer=this._inner=Zone.current,Zone.wtfZoneSpec&&(this._inner=this._inner.fork(Zone.wtfZoneSpec)),Zone.TaskTrackingZoneSpec&&(this._inner=this._inner.fork(new Zone.TaskTrackingZoneSpec)),e&&Zone.longStackTraceZoneSpec&&(this._inner=this._inner.fork(Zone.longStackTraceZoneSpec)),(t=this)._inner=t._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,n,r,s,l,i)=>{try{return Qs(t),e.invokeTask(r,s,l,i)}finally{Ks(t)}},onInvoke:(e,n,r,s,l,i,o)=>{try{return Qs(t),e.invoke(r,s,l,i,o)}finally{Ks(t)}},onHasTask:(e,n,r,s)=>{e.hasTask(r,s),n===r&&("microTask"==s.change?(t.hasPendingMicrotasks=s.microTask,Zs(t)):"macroTask"==s.change&&(t.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,n,r,s)=>(e.handleError(r,s),t.runOutsideAngular(()=>t.onError.emit(s)),!1)})}static isInAngularZone(){return!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!qs.isInAngularZone())throw new Error("Expected to be in Angular Zone, but it is not!")}static assertNotInAngularZone(){if(qs.isInAngularZone())throw new Error("Expected to not be in Angular Zone, but it is!")}run(e,t,n){return this._inner.run(e,t,n)}runTask(e,t,n,r){const s=this._inner,l=s.scheduleEventTask("NgZoneEvent: "+r,e,Ws,Gs,Gs);try{return s.runTask(l,t,n)}finally{s.cancelTask(l)}}runGuarded(e,t,n){return this._inner.runGuarded(e,t,n)}runOutsideAngular(e){return this._outer.run(e)}}function Gs(){}const Ws={};function Zs(e){if(0==e._nesting&&!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 Qs(e){e._nesting++,e.isStable&&(e.isStable=!1,e.onUnstable.emit(null))}function Ks(e){e._nesting--,Zs(e)}class Ys{constructor(){this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new ms,this.onMicrotaskEmpty=new ms,this.onStable=new ms,this.onError=new ms}run(e){return e()}runGuarded(e){return e()}runOutsideAngular(e){return e()}runTask(e){return e()}}class Js{constructor(e){this._ngZone=e,this._pendingCount=0,this._isZoneStable=!0,this._didWork=!1,this._callbacks=[],this.taskTrackingZone=null,this._watchAngularEvents(),e.run(()=>{this.taskTrackingZone="undefined"==typeof Zone?null:Zone.current.get("TaskTrackingZone")})}_watchAngularEvents(){this._ngZone.onUnstable.subscribe({next:()=>{this._didWork=!0,this._isZoneStable=!1}}),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.subscribe({next:()=>{qs.assertNotInAngularZone(),Bs(()=>{this._isZoneStable=!0,this._runCallbacksIfReady()})}})})}increasePendingRequestCount(){return this._pendingCount+=1,this._didWork=!0,this._pendingCount}decreasePendingRequestCount(){if(this._pendingCount-=1,this._pendingCount<0)throw new Error("pending async requests below zero");return this._runCallbacksIfReady(),this._pendingCount}isStable(){return this._isZoneStable&&0===this._pendingCount&&!this._ngZone.hasPendingMacrotasks}_runCallbacksIfReady(){if(this.isStable())Bs(()=>{for(;0!==this._callbacks.length;){let e=this._callbacks.pop();clearTimeout(e.timeoutId),e.doneCb(this._didWork)}this._didWork=!1});else{let e=this.getPendingTasks();this._callbacks=this._callbacks.filter(t=>!t.updateCb||!t.updateCb(e)||(clearTimeout(t.timeoutId),!1)),this._didWork=!0}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(e=>({source:e.source,creationLocation:e.creationLocation,data:e.data})):[]}addCallback(e,t,n){let r=-1;t&&t>0&&(r=setTimeout(()=>{this._callbacks=this._callbacks.filter(e=>e.timeoutId!==r),e(this._didWork,this.getPendingTasks())},t)),this._callbacks.push({doneCb:e,timeoutId:r,updateCb:n})}whenStable(e,t,n){if(n&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/dist/task-tracking.js" loaded?');this.addCallback(e,t,n),this._runCallbacksIfReady()}getPendingRequestCount(){return this._pendingCount}findProviders(e,t,n){return[]}}class Xs{constructor(){this._applications=new Map,nl.addToWindow(this)}registerApplication(e,t){this._applications.set(e,t)}unregisterApplication(e){this._applications.delete(e)}unregisterAllApplications(){this._applications.clear()}getTestability(e){return this._applications.get(e)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(e,t=!0){return nl.findTestabilityInTree(this,e,t)}}class el{addToWindow(e){}findTestabilityInTree(e,t,n){return null}}let tl,nl=new el;const rl=new Se("AllowMultipleToken");class sl{constructor(e,t){this.name=e,this.token=t}}function ll(e,t,n=[]){const r=`Platform: ${t}`,s=new Se(r);return(t=[])=>{let l=il();if(!l||l.injector.get(rl,!1))if(e)e(n.concat(t).concat({provide:s,useValue:!0}));else{const e=n.concat(t).concat({provide:s,useValue:!0});!function(e){if(tl&&!tl.destroyed&&!tl.injector.get(rl,!1))throw new Error("There can be only one platform. Destroy the previous one to create a new one.");tl=e.get(ol);const t=e.get(Ss,null);t&&t.forEach(e=>e())}(St.create({providers:e,name:r}))}return function(e){const t=il();if(!t)throw new Error("No platform exists!");if(!t.injector.get(e,null))throw new Error("A platform with a different configuration has been created. Please destroy it first.");return t}(s)}}function il(){return tl&&!tl.destroyed?tl:null}class ol{constructor(e){this._injector=e,this._modules=[],this._destroyListeners=[],this._destroyed=!1}bootstrapModuleFactory(e,t){const n=function(e){let t;return t="noop"===e?new Ys:("zone.js"===e?void 0:e)||new qs({enableLongStackTrace:Ge()}),t}(t?t.ngZone:void 0),r=[{provide:qs,useValue:n}];return n.run(()=>{const t=St.create({providers:r,parent:this.injector,name:e.moduleType.name}),s=e.create(t),l=s.injector.get(ze,null);if(!l)throw new Error("No ErrorHandler. Is platform module (BrowserModule) included?");return s.onDestroy(()=>cl(this._modules,s)),n.runOutsideAngular(()=>n.onError.subscribe({next:e=>{l.handleError(e)}})),function(e,t,n){try{const r=n();return Lt(r)?r.catch(n=>{throw t.runOutsideAngular(()=>e.handleError(n)),n}):r}catch(r){throw t.runOutsideAngular(()=>e.handleError(r)),r}}(l,n,()=>{const e=s.injector.get(ws);return e.runInitializers(),e.donePromise.then(()=>(this._moduleDoBootstrap(s),s))})})}bootstrapModule(e,t=[]){const n=al({},t);return function(e,t,n){return e.get(Vs).createCompiler([t]).compileModuleAsync(n)}(this.injector,n,e).then(e=>this.bootstrapModuleFactory(e,n))}_moduleDoBootstrap(e){const t=e.injector.get(ul);if(e._bootstrapComponents.length>0)e._bootstrapComponents.forEach(e=>t.bootstrap(e));else{if(!e.instance.ngDoBootstrap)throw new Error(`The module ${fe(e.instance.constructor)} was bootstrapped, but it does not declare "@NgModule.bootstrap" components nor a "ngDoBootstrap" method. `+"Please define one of these.");e.instance.ngDoBootstrap(t)}this._modules.push(e)}onDestroy(e){this._destroyListeners.push(e)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new Error("The platform has already been destroyed!");this._modules.slice().forEach(e=>e.destroy()),this._destroyListeners.forEach(e=>e()),this._destroyed=!0}get destroyed(){return this._destroyed}}function al(e,t){return Array.isArray(t)?t.reduce(al,e):Object.assign({},e,t)}let ul=(()=>{class e{constructor(e,t,n,r,s,l){this._zone=e,this._console=t,this._injector=n,this._exceptionHandler=r,this._componentFactoryResolver=s,this._initStatus=l,this._bootstrapListeners=[],this._views=[],this._runningTick=!1,this._enforceNoNewChanges=!1,this._stable=!0,this.componentTypes=[],this.components=[],this._enforceNoNewChanges=Ge(),this._zone.onMicrotaskEmpty.subscribe({next:()=>{this._zone.run(()=>{this.tick()})}});const i=new b(e=>{this._stable=this._zone.isStable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks,this._zone.runOutsideAngular(()=>{e.next(this._stable),e.complete()})}),o=new b(e=>{let t;this._zone.runOutsideAngular(()=>{t=this._zone.onStable.subscribe(()=>{qs.assertNotInAngularZone(),Bs(()=>{this._stable||this._zone.hasPendingMacrotasks||this._zone.hasPendingMicrotasks||(this._stable=!0,e.next(!0))})})});const n=this._zone.onUnstable.subscribe(()=>{qs.assertInAngularZone(),this._stable&&(this._stable=!1,this._zone.runOutsideAngular(()=>{e.next(!1)}))});return()=>{t.unsubscribe(),n.unsubscribe()}});this.isStable=function(...e){let t=Number.POSITIVE_INFINITY,n=null,r=e[e.length-1];return I(r)?(n=e.pop(),e.length>1&&"number"==typeof e[e.length-1]&&(t=e.pop())):"number"==typeof r&&(t=e.pop()),null===n&&1===e.length&&e[0]instanceof b?e[0]:Y(t)(q(e,n))}(i,o.pipe(e=>{return J()((t=se,function(e){let n;n="function"==typeof t?t:function(){return t};const r=Object.create(e,ne);return r.source=e,r.subjectFactory=n,r})(e));var t}))}bootstrap(e,t){if(!this._initStatus.done)throw new Error("Cannot bootstrap as there are still asynchronous initializers running. Bootstrap components in the `ngDoBootstrap` method of the root module.");let n;n=e instanceof zt?e:this._componentFactoryResolver.resolveComponentFactory(e),this.componentTypes.push(n.componentType);const r=n instanceof Qt?null:this._injector.get(De),s=n.create(St.NULL,[],t||n.selector,r);s.onDestroy(()=>{this._unloadComponent(s)});const l=s.injector.get(Js,null);return l&&s.injector.get(Xs).registerApplication(s.location.nativeElement,l),this._loadComponent(s),Ge()&&this._console.log("Angular is running in the development mode. Call enableProdMode() to enable the production mode."),s}tick(){if(this._runningTick)throw new Error("ApplicationRef.tick is called recursively");const t=e._tickScope();try{this._runningTick=!0;for(let e of this._views)e.detectChanges();if(this._enforceNoNewChanges)for(let e of this._views)e.checkNoChanges()}catch(n){this._zone.runOutsideAngular(()=>this._exceptionHandler.handleError(n))}finally{this._runningTick=!1,Hs(t)}}attachView(e){const t=e;this._views.push(t),t.attachToAppRef(this)}detachView(e){const t=e;cl(this._views,t),t.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e),this._injector.get(Ts,[]).concat(this._bootstrapListeners).forEach(t=>t(e))}_unloadComponent(e){this.detachView(e.hostView),cl(this.components,e)}ngOnDestroy(){this._views.slice().forEach(e=>e.destroy())}get viewCount(){return this._views.length}}return e._tickScope=$s("ApplicationRef#tick()"),e})();function cl(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class hl{}class dl{}const pl={factoryPathPrefix:"",factoryPathSuffix:".ngfactory"};class gl{constructor(e,t){this._compiler=e,this._config=t||pl}load(e){return this._compiler instanceof Ds?this.loadFactory(e):this.loadAndCompile(e)}loadAndCompile(e){let[t,r]=e.split("#");return void 0===r&&(r="default"),n("zn8P")(t).then(e=>e[r]).then(e=>fl(e,t,r)).then(e=>this._compiler.compileModuleAsync(e))}loadFactory(e){let[t,r]=e.split("#"),s="NgFactory";return void 0===r&&(r="default",s=""),n("zn8P")(this._config.factoryPathPrefix+t+this._config.factoryPathSuffix).then(e=>e[r+s]).then(e=>fl(e,t,r))}}function fl(e,t,n){if(!e)throw new Error(`Cannot find '${n}' in '${t}'`);return e}class ml{constructor(e,t){this.name=e,this.callback=t}}class vl{constructor(e,t,n){this.listeners=[],this.parent=null,this._debugContext=n,this.nativeNode=e,t&&t instanceof yl&&t.addChild(this)}get injector(){return this._debugContext.injector}get componentInstance(){return this._debugContext.component}get context(){return this._debugContext.context}get references(){return this._debugContext.references}get providerTokens(){return this._debugContext.providerTokens}}class yl extends vl{constructor(e,t,n){super(e,t,n),this.properties={},this.attributes={},this.classes={},this.styles={},this.childNodes=[],this.nativeElement=e}addChild(e){e&&(this.childNodes.push(e),e.parent=this)}removeChild(e){const t=this.childNodes.indexOf(e);-1!==t&&(e.parent=null,this.childNodes.splice(t,1))}insertChildrenAfter(e,t){const n=this.childNodes.indexOf(e);-1!==n&&(this.childNodes.splice(n+1,0,...t),t.forEach(t=>{t.parent&&t.parent.removeChild(t),e.parent=this}))}insertBefore(e,t){const n=this.childNodes.indexOf(e);-1===n?this.addChild(t):(t.parent&&t.parent.removeChild(t),t.parent=this,this.childNodes.splice(n,0,t))}query(e){return this.queryAll(e)[0]||null}queryAll(e){const t=[];return function e(t,n,r){t.childNodes.forEach(t=>{t instanceof yl&&(n(t)&&r.push(t),e(t,n,r))})}(this,e,t),t}queryAllNodes(e){const t=[];return function e(t,n,r){t instanceof yl&&t.childNodes.forEach(t=>{n(t)&&r.push(t),t instanceof yl&&e(t,n,r)})}(this,e,t),t}get children(){return this.childNodes.filter(e=>e instanceof yl)}triggerEventHandler(e,t){this.listeners.forEach(n=>{n.name==e&&n.callback(t)})}}const _l=new Map,wl=function(e){return _l.get(e)||null};function bl(e){_l.set(e.nativeNode,e)}const Cl=ll(null,"core",[{provide:Es,useValue:"unknown"},{provide:ol,deps:[St]},{provide:Xs,deps:[]},{provide:ks,deps:[]}]);function xl(){return wn}function Sl(){return bn}function El(e){return e||"en-US"}function Tl(e){let t=[];return e.onStable.subscribe(()=>{for(;t.length;)t.pop()()}),function(e){t.push(e)}}class kl{constructor(e){}}function Al(e,t,n,r,s,l){e|=1;const{matchedQueries:i,references:o,matchedQueryIds:a}=Xn(t);return{nodeIndex:-1,parent:null,renderParent:null,bindingIndex:-1,outputIndex:-1,flags:e,checkIndex:-1,childFlags:0,directChildFlags:0,childMatchedQueries:0,matchedQueries:i,matchedQueryIds:a,references:o,ngContentIndex:n,childCount:r,bindings:[],bindingFlags:0,outputs:[],element:{ns:null,name:null,attrs:null,template:l?rr(l):null,componentProvider:null,componentView:null,componentRendererType:null,publicProviders:null,allProviders:null,handleEvent:s||Un},provider:null,text:null,query:null,ngContent:null}}function Il(e,t,n,r,s,l,i=[],o,a,u,c,h){u||(u=Un);const{matchedQueries:d,references:p,matchedQueryIds:g}=Xn(n);let f=null,m=null;l&&([f,m]=cr(l)),o=o||[];const v=new Array(o.length);for(let w=0;w<o.length;w++){const[e,t,n]=o[w],[r,s]=cr(t);let l=void 0,i=void 0;switch(15&e){case 4:i=n;break;case 1:case 8:l=n}v[w]={flags:e,ns:r,name:s,nonMinifiedName:s,securityContext:l,suffix:i}}a=a||[];const y=new Array(a.length);for(let w=0;w<a.length;w++){const[e,t]=a[w];y[w]={type:0,target:e,eventName:t,propName:null}}const _=(i=i||[]).map(([e,t])=>{const[n,r]=cr(e);return[n,r,t]});return h=function(e){if(e&&"$$undefined"===e.id){const t=null!=e.encapsulation&&e.encapsulation!==je.None||e.styles.length||Object.keys(e.data).length;e.id=t?`c${$n++}`:"$$empty"}return e&&"$$empty"===e.id&&(e=null),e||null}(h),c&&(t|=33554432),{nodeIndex:-1,parent:null,renderParent:null,bindingIndex:-1,outputIndex:-1,checkIndex:e,flags:t|=1,childFlags:0,directChildFlags:0,childMatchedQueries:0,matchedQueries:d,matchedQueryIds:g,references:p,ngContentIndex:r,childCount:s,bindings:v,bindingFlags:hr(v),outputs:y,element:{ns:f,name:m,attrs:_,template:null,componentProvider:null,componentView:c||null,componentRendererType:h,publicProviders:null,allProviders:null,handleEvent:u||Un},provider:null,text:null,query:null,ngContent:null}}function Pl(e,t,n){const r=n.element,s=e.root.selectorOrNode,l=e.renderer;let i;if(e.parent||!s){i=r.name?l.createElement(r.name,r.ns):l.createComment("");const s=tr(e,t,n);s&&l.appendChild(s,i)}else i=l.selectRootElement(s,!!r.componentRendererType&&r.componentRendererType.encapsulation===je.ShadowDom);if(r.attrs)for(let o=0;o<r.attrs.length;o++){const[e,t,n]=r.attrs[o];l.setAttribute(i,t,n,e)}return i}function Ol(e,t,n,r){for(let i=0;i<n.outputs.length;i++){const o=n.outputs[i],a=Rl(e,n.nodeIndex,(l=o.eventName,(s=o.target)?`${s}:${l}`:l));let u=o.target,c=e;"component"===o.target&&(u=null,c=t);const h=c.renderer.listen(u||r,o.eventName,a);e.disposables[n.outputIndex+i]=h}var s,l}function Rl(e,t,n){return r=>Wn(e,t,n,r)}function Nl(e,t,n,r){if(!zn(e,t,n,r))return!1;const s=t.bindings[n],l=Rn(e,t.nodeIndex),i=l.renderElement,o=s.name;switch(15&s.flags){case 1:!function(e,t,n,r,s,l){const i=t.securityContext;let o=i?e.root.sanitizer.sanitize(i,l):l;o=null!=o?o.toString():null;const a=e.renderer;null!=l?a.setAttribute(n,s,o,r):a.removeAttribute(n,s,r)}(e,s,i,s.ns,o,r);break;case 2:!function(e,t,n,r){const s=e.renderer;r?s.addClass(t,n):s.removeClass(t,n)}(e,i,o,r);break;case 4:!function(e,t,n,r,s){let l=e.root.sanitizer.sanitize(gt.STYLE,s);if(null!=l){l=l.toString();const e=t.suffix;null!=e&&(l+=e)}else l=null;const i=e.renderer;null!=l?i.setStyle(n,r,l):i.removeStyle(n,r)}(e,s,i,o,r);break;case 8:!function(e,t,n,r,s){const l=t.securityContext;let i=l?e.root.sanitizer.sanitize(l,s):s;e.renderer.setProperty(n,r,i)}(33554432&t.flags&&32&s.flags?l.componentView:e,s,i,o,r)}return!0}function Dl(e){const t=e.def.nodeMatchedQueries;for(;e.parent&&Jn(e);){let n=e.parentNodeDef;e=e.parent;const r=n.nodeIndex+n.childCount;for(let s=0;s<=r;s++){const r=e.def.nodes[s];67108864&r.flags&&536870912&r.flags&&(r.query.filterId&t)===r.query.filterId&&Vn(e,s).setDirty(),!(1&r.flags&&s+r.childCount<n.nodeIndex)&&67108864&r.childFlags&&536870912&r.childFlags||(s+=r.childCount)}}if(134217728&e.def.nodeFlags)for(let n=0;n<e.def.nodes.length;n++){const t=e.def.nodes[n];134217728&t.flags&&536870912&t.flags&&Vn(e,n).setDirty(),n+=t.childCount}}function Vl(e,t){const n=Vn(e,t.nodeIndex);if(!n.dirty)return;let r,s=void 0;if(67108864&t.flags){const n=t.parent.parent;s=Ml(e,n.nodeIndex,n.nodeIndex+n.childCount,t.query,[]),r=Nn(e,t.parent.nodeIndex).instance}else 134217728&t.flags&&(s=Ml(e,0,e.def.nodes.length-1,t.query,[]),r=e.component);n.reset(s);const l=t.query.bindings;let i=!1;for(let o=0;o<l.length;o++){const e=l[o];let t;switch(e.bindingType){case 0:t=n.first;break;case 1:t=n,i=!0}r[e.propName]=t}i&&n.notifyOnChanges()}function Ml(e,t,n,r,s){for(let l=t;l<=n;l++){const t=e.def.nodes[l],n=t.matchedQueries[r.id];if(null!=n&&s.push(Ul(e,t,n)),1&t.flags&&t.element.template&&(t.element.template.nodeMatchedQueries&r.filterId)===r.filterId){const n=Rn(e,l);if((t.childMatchedQueries&r.filterId)===r.filterId&&(Ml(e,l+1,l+t.childCount,r,s),l+=t.childCount),16777216&t.flags){const e=n.viewContainer._embeddedViews;for(let t=0;t<e.length;t++){const l=e[t],i=Zn(l);i&&i===n&&Ml(l,0,l.def.nodes.length-1,r,s)}}const i=n.template._projectedViews;if(i)for(let e=0;e<i.length;e++){const t=i[e];Ml(t,0,t.def.nodes.length-1,r,s)}}(t.childMatchedQueries&r.filterId)!==r.filterId&&(l+=t.childCount)}return s}function Ul(e,t,n){if(null!=n)switch(n){case 1:return Rn(e,t.nodeIndex).renderElement;case 0:return new Yt(Rn(e,t.nodeIndex).renderElement);case 2:return Rn(e,t.nodeIndex).template;case 3:return Rn(e,t.nodeIndex).viewContainer;case 4:return Nn(e,t.nodeIndex).instance}}function jl(e,t,n){const r=tr(e,t,n);r&&ir(e,n.ngContent.index,1,r,null,void 0)}function Fl(e,t,n){const r=new Array(n.length-1);for(let s=1;s<n.length;s++)r[s-1]={flags:8,name:null,ns:null,nonMinifiedName:null,securityContext:null,suffix:n[s]};return{nodeIndex:-1,parent:null,renderParent:null,bindingIndex:-1,outputIndex:-1,checkIndex:e,flags:2,childFlags:0,directChildFlags:0,childMatchedQueries:0,matchedQueries:{},matchedQueryIds:0,references:{},ngContentIndex:t,childCount:0,bindings:r,bindingFlags:8,outputs:[],element:null,provider:null,text:{prefix:n[0]},query:null,ngContent:null}}function Ll(e,t,n){let r;const s=e.renderer;r=s.createText(n.text.prefix);const l=tr(e,t,n);return l&&s.appendChild(l,r),{renderText:r}}function $l(e,t){return(null!=e?e.toString():"")+t.suffix}function Hl(e,t,n,r){let s=0,l=0,i=0,o=0,a=0,u=null,c=null,h=!1,d=!1,p=null;for(let g=0;g<t.length;g++){const e=t[g];if(e.nodeIndex=g,e.parent=u,e.bindingIndex=s,e.outputIndex=l,e.renderParent=c,i|=e.flags,a|=e.matchedQueryIds,e.element){const t=e.element;t.publicProviders=u?u.element.publicProviders:Object.create(null),t.allProviders=t.publicProviders,h=!1,d=!1,e.element.template&&(a|=e.element.template.nodeMatchedQueries)}if(Bl(u,e,t.length),s+=e.bindings.length,l+=e.outputs.length,!c&&3&e.flags&&(p=e),20224&e.flags){h||(h=!0,u.element.publicProviders=Object.create(u.element.publicProviders),u.element.allProviders=u.element.publicProviders);const t=0!=(32768&e.flags);0==(8192&e.flags)||t?u.element.publicProviders[Fn(e.provider.token)]=e:(d||(d=!0,u.element.allProviders=Object.create(u.element.publicProviders)),u.element.allProviders[Fn(e.provider.token)]=e),t&&(u.element.componentProvider=e)}if(u?(u.childFlags|=e.flags,u.directChildFlags|=e.flags,u.childMatchedQueries|=e.matchedQueryIds,e.element&&e.element.template&&(u.childMatchedQueries|=e.element.template.nodeMatchedQueries)):o|=e.flags,e.childCount>0)u=e,zl(e)||(c=e);else for(;u&&g===u.nodeIndex+u.childCount;){const e=u.parent;e&&(e.childFlags|=u.childFlags,e.childMatchedQueries|=u.childMatchedQueries),u=e,c=u&&zl(u)?u.renderParent:u}}return{factory:null,nodeFlags:i,rootNodeFlags:o,nodeMatchedQueries:a,flags:e,nodes:t,updateDirectives:n||Un,updateRenderer:r||Un,handleEvent:(e,n,r,s)=>t[n].element.handleEvent(e,r,s),bindingCount:s,outputCount:l,lastRenderRootNode:p}}function zl(e){return 0!=(1&e.flags)&&null===e.element.name}function Bl(e,t,n){const r=t.element&&t.element.template;if(r){if(!r.lastRenderRootNode)throw new Error("Illegal State: Embedded templates without nodes are not allowed!");if(r.lastRenderRootNode&&16777216&r.lastRenderRootNode.flags)throw new Error(`Illegal State: Last root node of a template can't have embedded views, at index ${t.nodeIndex}!`)}if(20224&t.flags&&0==(1&(e?e.flags:0)))throw new Error(`Illegal State: StaticProvider/Directive nodes need to be children of elements or anchors, at index ${t.nodeIndex}!`);if(t.query){if(67108864&t.flags&&(!e||0==(16384&e.flags)))throw new Error(`Illegal State: Content Query nodes need to be children of directives, at index ${t.nodeIndex}!`);if(134217728&t.flags&&e)throw new Error(`Illegal State: View Query nodes have to be top level nodes, at index ${t.nodeIndex}!`)}if(t.childCount){const r=e?e.nodeIndex+e.childCount:n-1;if(t.nodeIndex<=r&&t.nodeIndex+t.childCount>r)throw new Error(`Illegal State: childCount of node leads outside of parent, at index ${t.nodeIndex}!`)}}function ql(e,t,n,r){const s=Zl(e.root,e.renderer,e,t,n);return Ql(s,e.component,r),Kl(s),s}function Gl(e,t,n){const r=Zl(e,e.renderer,null,null,t);return Ql(r,n,n),Kl(r),r}function Wl(e,t,n,r){const s=t.element.componentRendererType;let l;return l=s?e.root.rendererFactory.createRenderer(r,s):e.root.renderer,Zl(e.root,l,e,t.element.componentProvider,n)}function Zl(e,t,n,r,s){const l=new Array(s.nodes.length),i=s.outputCount?new Array(s.outputCount):null;return{def:s,parent:n,viewContainerParent:null,parentNodeDef:r,context:null,component:null,nodes:l,state:13,root:e,renderer:t,oldValues:new Array(s.bindingCount),disposables:i,initIndex:-1}}function Ql(e,t,n){e.component=t,e.context=n}function Kl(e){let t;Yn(e)&&(t=Rn(e.parent,e.parentNodeDef.parent.nodeIndex).renderElement);const n=e.def,r=e.nodes;for(let s=0;s<n.nodes.length;s++){const l=n.nodes[s];let i;switch(Mn.setCurrentNode(e,s),201347067&l.flags){case 1:const n=Pl(e,t,l);let o=void 0;if(33554432&l.flags){const t=rr(l.element.componentView);o=Mn.createComponentView(e,l,t,n)}Ol(e,o,l,n),i={renderElement:n,componentView:o,viewContainer:null,template:l.element.template?Rr(e,l):void 0},16777216&l.flags&&(i.viewContainer=Ar(e,l,i));break;case 2:i=Ll(e,t,l);break;case 512:case 1024:case 2048:case 256:i=r[s],i||4096&l.flags||(i={instance:Jr(e,l)});break;case 16:i={instance:Xr(e,l)};break;case 16384:i=r[s],i||(i={instance:es(e,l)}),32768&l.flags&&Ql(Rn(e,l.parent.nodeIndex).componentView,i.instance,i.instance);break;case 32:case 64:case 128:i={value:void 0};break;case 67108864:case 134217728:i=new ys;break;case 8:jl(e,t,l),i=void 0}r[s]=i}li(e,si.CreateViewNodes),ui(e,201326592,268435456,0)}function Yl(e){ei(e),Mn.updateDirectives(e,1),ii(e,si.CheckNoChanges),Mn.updateRenderer(e,1),li(e,si.CheckNoChanges),e.state&=-97}function Jl(e){1&e.state?(e.state&=-2,e.state|=2):e.state&=-3,In(e,0,256),ei(e),Mn.updateDirectives(e,0),ii(e,si.CheckAndUpdate),ui(e,67108864,536870912,0);let t=In(e,256,512);as(e,2097152|(t?1048576:0)),Mn.updateRenderer(e,0),li(e,si.CheckAndUpdate),ui(e,134217728,536870912,0),t=In(e,512,768),as(e,8388608|(t?4194304:0)),2&e.def.flags&&(e.state&=-9),e.state&=-97,In(e,768,1024)}function Xl(e,t,n,r,s,l,i,o,a,u,c,h,d){return 0===n?function(e,t,n,r,s,l,i,o,a,u,c,h){switch(201347067&t.flags){case 1:return function(e,t,n,r,s,l,i,o,a,u,c,h){const d=t.bindings.length;let p=!1;return d>0&&Nl(e,t,0,n)&&(p=!0),d>1&&Nl(e,t,1,r)&&(p=!0),d>2&&Nl(e,t,2,s)&&(p=!0),d>3&&Nl(e,t,3,l)&&(p=!0),d>4&&Nl(e,t,4,i)&&(p=!0),d>5&&Nl(e,t,5,o)&&(p=!0),d>6&&Nl(e,t,6,a)&&(p=!0),d>7&&Nl(e,t,7,u)&&(p=!0),d>8&&Nl(e,t,8,c)&&(p=!0),d>9&&Nl(e,t,9,h)&&(p=!0),p}(e,t,n,r,s,l,i,o,a,u,c,h);case 2:return function(e,t,n,r,s,l,i,o,a,u,c,h){let d=!1;const p=t.bindings,g=p.length;if(g>0&&zn(e,t,0,n)&&(d=!0),g>1&&zn(e,t,1,r)&&(d=!0),g>2&&zn(e,t,2,s)&&(d=!0),g>3&&zn(e,t,3,l)&&(d=!0),g>4&&zn(e,t,4,i)&&(d=!0),g>5&&zn(e,t,5,o)&&(d=!0),g>6&&zn(e,t,6,a)&&(d=!0),g>7&&zn(e,t,7,u)&&(d=!0),g>8&&zn(e,t,8,c)&&(d=!0),g>9&&zn(e,t,9,h)&&(d=!0),d){let d=t.text.prefix;g>0&&(d+=$l(n,p[0])),g>1&&(d+=$l(r,p[1])),g>2&&(d+=$l(s,p[2])),g>3&&(d+=$l(l,p[3])),g>4&&(d+=$l(i,p[4])),g>5&&(d+=$l(o,p[5])),g>6&&(d+=$l(a,p[6])),g>7&&(d+=$l(u,p[7])),g>8&&(d+=$l(c,p[8])),g>9&&(d+=$l(h,p[9]));const f=On(e,t.nodeIndex).renderText;e.renderer.setValue(f,d)}return d}(e,t,n,r,s,l,i,o,a,u,c,h);case 16384:return function(e,t,n,r,s,l,i,o,a,u,c,h){const d=Nn(e,t.nodeIndex),p=d.instance;let g=!1,f=void 0;const m=t.bindings.length;return m>0&&Hn(e,t,0,n)&&(g=!0,f=os(e,d,t,0,n,f)),m>1&&Hn(e,t,1,r)&&(g=!0,f=os(e,d,t,1,r,f)),m>2&&Hn(e,t,2,s)&&(g=!0,f=os(e,d,t,2,s,f)),m>3&&Hn(e,t,3,l)&&(g=!0,f=os(e,d,t,3,l,f)),m>4&&Hn(e,t,4,i)&&(g=!0,f=os(e,d,t,4,i,f)),m>5&&Hn(e,t,5,o)&&(g=!0,f=os(e,d,t,5,o,f)),m>6&&Hn(e,t,6,a)&&(g=!0,f=os(e,d,t,6,a,f)),m>7&&Hn(e,t,7,u)&&(g=!0,f=os(e,d,t,7,u,f)),m>8&&Hn(e,t,8,c)&&(g=!0,f=os(e,d,t,8,c,f)),m>9&&Hn(e,t,9,h)&&(g=!0,f=os(e,d,t,9,h,f)),f&&p.ngOnChanges(f),65536&t.flags&&Pn(e,256,t.nodeIndex)&&p.ngOnInit(),262144&t.flags&&p.ngDoCheck(),g}(e,t,n,r,s,l,i,o,a,u,c,h);case 32:case 64:case 128:return function(e,t,n,r,s,l,i,o,a,u,c,h){const d=t.bindings;let p=!1;const g=d.length;if(g>0&&zn(e,t,0,n)&&(p=!0),g>1&&zn(e,t,1,r)&&(p=!0),g>2&&zn(e,t,2,s)&&(p=!0),g>3&&zn(e,t,3,l)&&(p=!0),g>4&&zn(e,t,4,i)&&(p=!0),g>5&&zn(e,t,5,o)&&(p=!0),g>6&&zn(e,t,6,a)&&(p=!0),g>7&&zn(e,t,7,u)&&(p=!0),g>8&&zn(e,t,8,c)&&(p=!0),g>9&&zn(e,t,9,h)&&(p=!0),p){const p=Dn(e,t.nodeIndex);let f;switch(201347067&t.flags){case 32:f=new Array(d.length),g>0&&(f[0]=n),g>1&&(f[1]=r),g>2&&(f[2]=s),g>3&&(f[3]=l),g>4&&(f[4]=i),g>5&&(f[5]=o),g>6&&(f[6]=a),g>7&&(f[7]=u),g>8&&(f[8]=c),g>9&&(f[9]=h);break;case 64:f={},g>0&&(f[d[0].name]=n),g>1&&(f[d[1].name]=r),g>2&&(f[d[2].name]=s),g>3&&(f[d[3].name]=l),g>4&&(f[d[4].name]=i),g>5&&(f[d[5].name]=o),g>6&&(f[d[6].name]=a),g>7&&(f[d[7].name]=u),g>8&&(f[d[8].name]=c),g>9&&(f[d[9].name]=h);break;case 128:const e=n;switch(g){case 1:f=e.transform(n);break;case 2:f=e.transform(r);break;case 3:f=e.transform(r,s);break;case 4:f=e.transform(r,s,l);break;case 5:f=e.transform(r,s,l,i);break;case 6:f=e.transform(r,s,l,i,o);break;case 7:f=e.transform(r,s,l,i,o,a);break;case 8:f=e.transform(r,s,l,i,o,a,u);break;case 9:f=e.transform(r,s,l,i,o,a,u,c);break;case 10:f=e.transform(r,s,l,i,o,a,u,c,h)}}p.value=f}return p}(e,t,n,r,s,l,i,o,a,u,c,h);default:throw"unreachable"}}(e,t,r,s,l,i,o,a,u,c,h,d):function(e,t,n){switch(201347067&t.flags){case 1:return function(e,t,n){let r=!1;for(let s=0;s<n.length;s++)Nl(e,t,s,n[s])&&(r=!0);return r}(e,t,n);case 2:return function(e,t,n){const r=t.bindings;let s=!1;for(let l=0;l<n.length;l++)zn(e,t,l,n[l])&&(s=!0);if(s){let s="";for(let e=0;e<n.length;e++)s+=$l(n[e],r[e]);s=t.text.prefix+s;const l=On(e,t.nodeIndex).renderText;e.renderer.setValue(l,s)}return s}(e,t,n);case 16384:return function(e,t,n){const r=Nn(e,t.nodeIndex),s=r.instance;let l=!1,i=void 0;for(let o=0;o<n.length;o++)Hn(e,t,o,n[o])&&(l=!0,i=os(e,r,t,o,n[o],i));return i&&s.ngOnChanges(i),65536&t.flags&&Pn(e,256,t.nodeIndex)&&s.ngOnInit(),262144&t.flags&&s.ngDoCheck(),l}(e,t,n);case 32:case 64:case 128:return function(e,t,n){const r=t.bindings;let s=!1;for(let l=0;l<n.length;l++)zn(e,t,l,n[l])&&(s=!0);if(s){const s=Dn(e,t.nodeIndex);let l;switch(201347067&t.flags){case 32:l=n;break;case 64:l={};for(let s=0;s<n.length;s++)l[r[s].name]=n[s];break;case 128:const e=n[0],t=n.slice(1);l=e.transform(...t)}s.value=l}return s}(e,t,n);default:throw"unreachable"}}(e,t,r)}function ei(e){const t=e.def;if(4&t.nodeFlags)for(let n=0;n<t.nodes.length;n++){const r=t.nodes[n];if(4&r.flags){const t=Rn(e,n).template._projectedViews;if(t)for(let n=0;n<t.length;n++){const r=t[n];r.state|=32,Gn(r,e)}}else 0==(4&r.childFlags)&&(n+=r.childCount)}}function ti(e,t,n,r,s,l,i,o,a,u,c,h,d){return 0===n?function(e,t,n,r,s,l,i,o,a,u,c,h){const d=t.bindings.length;d>0&&Bn(e,t,0,n),d>1&&Bn(e,t,1,r),d>2&&Bn(e,t,2,s),d>3&&Bn(e,t,3,l),d>4&&Bn(e,t,4,i),d>5&&Bn(e,t,5,o),d>6&&Bn(e,t,6,a),d>7&&Bn(e,t,7,u),d>8&&Bn(e,t,8,c),d>9&&Bn(e,t,9,h)}(e,t,r,s,l,i,o,a,u,c,h,d):function(e,t,n){for(let r=0;r<n.length;r++)Bn(e,t,r,n[r])}(e,t,r),!1}function ni(e,t){if(Vn(e,t.nodeIndex).dirty)throw Tn(Mn.createDebugContext(e,t.nodeIndex),`Query ${t.query.id} not dirty`,`Query ${t.query.id} dirty`,0!=(1&e.state))}function ri(e){if(!(128&e.state)){if(ii(e,si.Destroy),li(e,si.Destroy),as(e,131072),e.disposables)for(let t=0;t<e.disposables.length;t++)e.disposables[t]();!function(e){if(!(16&e.state))return;const t=Zn(e);if(t){const n=t.template._projectedViews;n&&(Ue(n,n.indexOf(e)),Mn.dirtyParentQueries(e))}}(e),e.renderer.destroyNode&&function(e){const t=e.def.nodes.length;for(let n=0;n<t;n++){const t=e.def.nodes[n];1&t.flags?e.renderer.destroyNode(Rn(e,n).renderElement):2&t.flags?e.renderer.destroyNode(On(e,n).renderText):(67108864&t.flags||134217728&t.flags)&&Vn(e,n).destroy()}}(e),Yn(e)&&e.renderer.destroy(),e.state|=128}}const si=function(){var e={CreateViewNodes:0,CheckNoChanges:1,CheckNoChangesProjectedViews:2,CheckAndUpdate:3,CheckAndUpdateProjectedViews:4,Destroy:5};return e[e.CreateViewNodes]="CreateViewNodes",e[e.CheckNoChanges]="CheckNoChanges",e[e.CheckNoChangesProjectedViews]="CheckNoChangesProjectedViews",e[e.CheckAndUpdate]="CheckAndUpdate",e[e.CheckAndUpdateProjectedViews]="CheckAndUpdateProjectedViews",e[e.Destroy]="Destroy",e}();function li(e,t){const n=e.def;if(33554432&n.nodeFlags)for(let r=0;r<n.nodes.length;r++){const s=n.nodes[r];33554432&s.flags?oi(Rn(e,r).componentView,t):0==(33554432&s.childFlags)&&(r+=s.childCount)}}function ii(e,t){const n=e.def;if(16777216&n.nodeFlags)for(let r=0;r<n.nodes.length;r++){const s=n.nodes[r];if(16777216&s.flags){const n=Rn(e,r).viewContainer._embeddedViews;for(let e=0;e<n.length;e++)oi(n[e],t)}else 0==(16777216&s.childFlags)&&(r+=s.childCount)}}function oi(e,t){const n=e.state;switch(t){case si.CheckNoChanges:0==(128&n)&&(12==(12&n)?Yl(e):64&n&&ai(e,si.CheckNoChangesProjectedViews));break;case si.CheckNoChangesProjectedViews:0==(128&n)&&(32&n?Yl(e):64&n&&ai(e,t));break;case si.CheckAndUpdate:0==(128&n)&&(12==(12&n)?Jl(e):64&n&&ai(e,si.CheckAndUpdateProjectedViews));break;case si.CheckAndUpdateProjectedViews:0==(128&n)&&(32&n?Jl(e):64&n&&ai(e,t));break;case si.Destroy:ri(e);break;case si.CreateViewNodes:Kl(e)}}function ai(e,t){ii(e,t),li(e,t)}function ui(e,t,n,r){if(!(e.def.nodeFlags&t&&e.def.nodeFlags&n))return;const s=e.def.nodes.length;for(let l=0;l<s;l++){const s=e.def.nodes[l];if(s.flags&t&&s.flags&n)switch(Mn.setCurrentNode(e,s.nodeIndex),r){case 0:Vl(e,s);break;case 1:ni(e,s)}s.childFlags&t&&s.childFlags&n||(l+=s.childCount)}}let ci=!1;function hi(e,t,n,r,s,l){const i=s.injector.get(en);return Gl(pi(e,s,i,t,n),r,l)}function di(e,t,n,r,s,l){const i=s.injector.get(en),o=pi(e,s,new qi(i),t,n),a=xi(r);return zi(Ii.create,Gl,null,[o,a,l])}function pi(e,t,n,r,s){const l=t.injector.get(ft),i=t.injector.get(ze),o=n.createRenderer(null,null);return{ngModule:t,injector:e,projectableNodes:r,selectorOrNode:s,sanitizer:l,rendererFactory:n,renderer:o,errorHandler:i}}function gi(e,t,n,r){const s=xi(n);return zi(Ii.create,ql,null,[e,t,s,r])}function fi(e,t,n,r){return n=_i.get(t.element.componentProvider.provider.token)||xi(n),zi(Ii.create,Wl,null,[e,t,n,r])}function mi(e,t,n,r){return Fr(e,t,n,function(e){const{hasOverrides:t,hasDeprecatedOverrides:n}=function(e){let t=!1,n=!1;return 0===vi.size?{hasOverrides:t,hasDeprecatedOverrides:n}:(e.providers.forEach(e=>{const r=vi.get(e.token);3840&e.flags&&r&&(t=!0,n=n||r.deprecatedBehavior)}),e.modules.forEach(e=>{yi.forEach((r,s)=>{pe(s).providedIn===e&&(t=!0,n=n||r.deprecatedBehavior)})}),{hasOverrides:t,hasDeprecatedOverrides:n})}(e);return t?(function(e){for(let t=0;t<e.providers.length;t++){const r=e.providers[t];n&&(r.flags|=4096);const s=vi.get(r.token);s&&(r.flags=-3841&r.flags|s.flags,r.deps=er(s.deps),r.value=s.value)}if(yi.size>0){let t=new Set(e.modules);yi.forEach((r,s)=>{if(t.has(pe(s).providedIn)){let t={token:s,flags:r.flags|(n?4096:0),deps:er(r.deps),value:r.value,index:e.providers.length};e.providers.push(t),e.providersByKey[Fn(s)]=t}})}}(e=e.factory(()=>Un)),e):e}(r))}const vi=new Map,yi=new Map,_i=new Map;function wi(e){let t;vi.set(e.token,e),"function"==typeof e.token&&(t=pe(e.token))&&"function"==typeof t.providedIn&&yi.set(e.token,e)}function bi(e,t){const n=rr(t.viewDefFactory),r=rr(n.nodes[0].element.componentView);_i.set(e,r)}function Ci(){vi.clear(),yi.clear(),_i.clear()}function xi(e){if(0===vi.size)return e;const t=function(e){const t=[];let n=null;for(let r=0;r<e.nodes.length;r++){const s=e.nodes[r];1&s.flags&&(n=s),n&&3840&s.flags&&vi.has(s.provider.token)&&(t.push(n.nodeIndex),n=null)}return t}(e);if(0===t.length)return e;e=e.factory(()=>Un);for(let r=0;r<t.length;r++)n(e,t[r]);return e;function n(e,t){for(let n=t+1;n<e.nodes.length;n++){const t=e.nodes[n];if(1&t.flags)return;if(3840&t.flags){const e=t.provider,n=vi.get(e.token);n&&(t.flags=-3841&t.flags|n.flags,e.deps=er(n.deps),e.value=n.value)}}}}function Si(e,t,n,r,s,l,i,o,a,u,c,h,d){const p=e.def.nodes[t];return Xl(e,p,n,r,s,l,i,o,a,u,c,h,d),224&p.flags?Dn(e,t).value:void 0}function Ei(e,t,n,r,s,l,i,o,a,u,c,h,d){const p=e.def.nodes[t];return ti(e,p,n,r,s,l,i,o,a,u,c,h,d),224&p.flags?Dn(e,t).value:void 0}function Ti(e){return zi(Ii.detectChanges,Jl,null,[e])}function ki(e){return zi(Ii.checkNoChanges,Yl,null,[e])}function Ai(e){return zi(Ii.destroy,ri,null,[e])}const Ii=function(){var e={create:0,detectChanges:1,checkNoChanges:2,destroy:3,handleEvent:4};return e[e.create]="create",e[e.detectChanges]="detectChanges",e[e.checkNoChanges]="checkNoChanges",e[e.destroy]="destroy",e[e.handleEvent]="handleEvent",e}();let Pi,Oi,Ri;function Ni(e,t){Oi=e,Ri=t}function Di(e,t,n,r){return Ni(e,t),zi(Ii.handleEvent,e.def.handleEvent,null,[e,t,n,r])}function Vi(e,t){if(128&e.state)throw An(Ii[Pi]);return Ni(e,Fi(e,0)),e.def.updateDirectives((function(e,n,r,...s){const l=e.def.nodes[n];return 0===t?Ui(e,l,r,s):ji(e,l,r,s),16384&l.flags&&Ni(e,Fi(e,n)),224&l.flags?Dn(e,l.nodeIndex).value:void 0}),e)}function Mi(e,t){if(128&e.state)throw An(Ii[Pi]);return Ni(e,Li(e,0)),e.def.updateRenderer((function(e,n,r,...s){const l=e.def.nodes[n];return 0===t?Ui(e,l,r,s):ji(e,l,r,s),3&l.flags&&Ni(e,Li(e,n)),224&l.flags?Dn(e,l.nodeIndex).value:void 0}),e)}function Ui(e,t,n,r){if(Xl(e,t,n,...r)){const i=1===n?r[0]:r;if(16384&t.flags){const n={};for(let e=0;e<t.bindings.length;e++){const r=t.bindings[e],o=i[e];8&r.flags&&(n[(s=r.nonMinifiedName,l=void 0,l=s.replace(/[$@]/g,"_"),`ng-reflect-${s=l.replace(yt,(...e)=>"-"+e[1].toLowerCase())}`)]=_t(o))}const r=t.parent,o=Rn(e,r.nodeIndex).renderElement;if(r.element.name)for(let t in n){const r=n[t];null!=r?e.renderer.setAttribute(o,t,r):e.renderer.removeAttribute(o,t)}else e.renderer.setValue(o,`bindings=${JSON.stringify(n,null,2)}`)}}var s,l}function ji(e,t,n,r){ti(e,t,n,...r)}function Fi(e,t){for(let n=t;n<e.def.nodes.length;n++){const t=e.def.nodes[n];if(16384&t.flags&&t.bindings&&t.bindings.length)return n}return null}function Li(e,t){for(let n=t;n<e.def.nodes.length;n++){const t=e.def.nodes[n];if(3&t.flags&&t.bindings&&t.bindings.length)return n}return null}class $i{constructor(e,t){this.view=e,this.nodeIndex=t,null==t&&(this.nodeIndex=t=0),this.nodeDef=e.def.nodes[t];let n=this.nodeDef,r=e;for(;n&&0==(1&n.flags);)n=n.parent;if(!n)for(;!n&&r;)n=Qn(r),r=r.parent;this.elDef=n,this.elView=r}get elOrCompView(){return Rn(this.elView,this.elDef.nodeIndex).componentView||this.view}get injector(){return Dr(this.elView,this.elDef)}get component(){return this.elOrCompView.component}get context(){return this.elOrCompView.context}get providerTokens(){const e=[];if(this.elDef)for(let t=this.elDef.nodeIndex+1;t<=this.elDef.nodeIndex+this.elDef.childCount;t++){const n=this.elView.def.nodes[t];20224&n.flags&&e.push(n.provider.token),t+=n.childCount}return e}get references(){const e={};if(this.elDef){Hi(this.elView,this.elDef,e);for(let t=this.elDef.nodeIndex+1;t<=this.elDef.nodeIndex+this.elDef.childCount;t++){const n=this.elView.def.nodes[t];20224&n.flags&&Hi(this.elView,n,e),t+=n.childCount}}return e}get componentRenderElement(){const e=function(e){for(;e&&!Yn(e);)e=e.parent;return e.parent?Rn(e.parent,Qn(e).nodeIndex):null}(this.elOrCompView);return e?e.renderElement:void 0}get renderNode(){return 2&this.nodeDef.flags?Kn(this.view,this.nodeDef):Kn(this.elView,this.elDef)}logError(e,...t){let n,r;2&this.nodeDef.flags?(n=this.view.def,r=this.nodeDef.nodeIndex):(n=this.elView.def,r=this.elDef.nodeIndex);const s=function(e,t){let n=-1;for(let r=0;r<=t;r++)3&e.nodes[r].flags&&n++;return n}(n,r);let l=-1;n.factory(()=>(l++,l===s?e.error.bind(e,...t):Un)),l<s&&(e.error("Illegal state: the ViewDefinitionFactory did not call the logger!"),e.error(...t))}}function Hi(e,t,n){for(let r in t.references)n[r]=Ul(e,t,t.references[r])}function zi(e,t,n,r){const s=Pi,l=Oi,i=Ri;try{Pi=e;const o=t.apply(n,r);return Oi=l,Ri=i,Pi=s,o}catch(o){if(Le(o)||!Oi)throw o;throw function(e,t){return e instanceof Error||(e=new Error(e.toString())),kn(e,t),e}(o,Bi())}}function Bi(){return Oi?new $i(Oi,Ri):null}class qi{constructor(e){this.delegate=e}createRenderer(e,t){return new Gi(this.delegate.createRenderer(e,t))}begin(){this.delegate.begin&&this.delegate.begin()}end(){this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.delegate.whenRenderingDone?this.delegate.whenRenderingDone():Promise.resolve(null)}}class Gi{constructor(e){this.delegate=e,this.debugContextFactory=Bi,this.data=this.delegate.data}createDebugContext(e){return this.debugContextFactory(e)}destroyNode(e){const t=wl(e);!function(e){_l.delete(e.nativeNode)}(t),t instanceof vl&&(t.listeners.length=0),this.delegate.destroyNode&&this.delegate.destroyNode(e)}destroy(){this.delegate.destroy()}createElement(e,t){const n=this.delegate.createElement(e,t),r=this.createDebugContext(n);if(r){const t=new yl(n,null,r);t.name=e,bl(t)}return n}createComment(e){const t=this.delegate.createComment(e),n=this.createDebugContext(t);return n&&bl(new vl(t,null,n)),t}createText(e){const t=this.delegate.createText(e),n=this.createDebugContext(t);return n&&bl(new vl(t,null,n)),t}appendChild(e,t){const n=wl(e),r=wl(t);n&&r&&n instanceof yl&&n.addChild(r),this.delegate.appendChild(e,t)}insertBefore(e,t,n){const r=wl(e),s=wl(t),l=wl(n);r&&s&&r instanceof yl&&r.insertBefore(l,s),this.delegate.insertBefore(e,t,n)}removeChild(e,t){const n=wl(e),r=wl(t);n&&r&&n instanceof yl&&n.removeChild(r),this.delegate.removeChild(e,t)}selectRootElement(e,t){const n=this.delegate.selectRootElement(e,t),r=Bi();return r&&bl(new yl(n,null,r)),n}setAttribute(e,t,n,r){const s=wl(e);s&&s instanceof yl&&(s.attributes[r?r+":"+t:t]=n),this.delegate.setAttribute(e,t,n,r)}removeAttribute(e,t,n){const r=wl(e);r&&r instanceof yl&&(r.attributes[n?n+":"+t:t]=null),this.delegate.removeAttribute(e,t,n)}addClass(e,t){const n=wl(e);n&&n instanceof yl&&(n.classes[t]=!0),this.delegate.addClass(e,t)}removeClass(e,t){const n=wl(e);n&&n instanceof yl&&(n.classes[t]=!1),this.delegate.removeClass(e,t)}setStyle(e,t,n,r){const s=wl(e);s&&s instanceof yl&&(s.styles[t]=n),this.delegate.setStyle(e,t,n,r)}removeStyle(e,t,n){const r=wl(e);r&&r instanceof yl&&(r.styles[t]=null),this.delegate.removeStyle(e,t,n)}setProperty(e,t,n){const r=wl(e);r&&r instanceof yl&&(r.properties[t]=n),this.delegate.setProperty(e,t,n)}listen(e,t,n){if("string"!=typeof e){const r=wl(e);r&&r.listeners.push(new ml(t,n))}return this.delegate.listen(e,t,n)}parentNode(e){return this.delegate.parentNode(e)}nextSibling(e){return this.delegate.nextSibling(e)}setValue(e,t){return this.delegate.setValue(e,t)}}function Wi(e,t,n){return new Zi(e,t,n)}class Zi extends Ve{constructor(e,t,n){super(),this.moduleType=e,this._bootstrapComponents=t,this._ngModuleDefFactory=n}create(e){!function(){if(ci)return;ci=!0;const e=Ge()?{setCurrentNode:Ni,createRootView:di,createEmbeddedView:gi,createComponentView:fi,createNgModuleRef:mi,overrideProvider:wi,overrideComponentView:bi,clearOverrides:Ci,checkAndUpdateView:Ti,checkNoChangesView:ki,destroyView:Ai,createDebugContext:(e,t)=>new $i(e,t),handleEvent:Di,updateDirectives:Vi,updateRenderer:Mi}:{setCurrentNode:()=>{},createRootView:hi,createEmbeddedView:ql,createComponentView:Wl,createNgModuleRef:Fr,overrideProvider:Un,overrideComponentView:Un,clearOverrides:Un,checkAndUpdateView:Jl,checkNoChangesView:Yl,destroyView:ri,createDebugContext:(e,t)=>new $i(e,t),handleEvent:(e,t,n,r)=>e.def.handleEvent(e,t,n,r),updateDirectives:(e,t)=>e.def.updateDirectives(0===t?Si:Ei,e),updateRenderer:(e,t)=>e.def.updateRenderer(0===t?Si:Ei,e)};Mn.setCurrentNode=e.setCurrentNode,Mn.createRootView=e.createRootView,Mn.createEmbeddedView=e.createEmbeddedView,Mn.createComponentView=e.createComponentView,Mn.createNgModuleRef=e.createNgModuleRef,Mn.overrideProvider=e.overrideProvider,Mn.overrideComponentView=e.overrideComponentView,Mn.clearOverrides=e.clearOverrides,Mn.checkAndUpdateView=e.checkAndUpdateView,Mn.checkNoChangesView=e.checkNoChangesView,Mn.destroyView=e.destroyView,Mn.resolveDep=ls,Mn.createDebugContext=e.createDebugContext,Mn.handleEvent=e.handleEvent,Mn.updateDirectives=e.updateDirectives,Mn.updateRenderer=e.updateRenderer,Mn.dirtyParentQueries=Dl}();const t=function(e){const t=Array.from(e.providers),n=Array.from(e.modules),r={};for(const s in e.providersByKey)r[s]=e.providersByKey[s];return{factory:e.factory,isRoot:e.isRoot,providers:t,modules:n,providersByKey:r}}(rr(this._ngModuleDefFactory));return Mn.createNgModuleRef(this.moduleType,e||St.NULL,this._bootstrapComponents,t)}}class Qi{}class Ki{}class Yi{}const Ji=new Se("Location Initialized");class Xi{}const eo=new Se("appBaseHref");class to{constructor(e,t){this._subject=new ms,this._urlChangeListeners=[],this._platformStrategy=e;const n=this._platformStrategy.getBaseHref();this._platformLocation=t,this._baseHref=to.stripTrailingSlash(no(n)),this._platformStrategy.onPopState(e=>{this._subject.emit({url:this.path(!0),pop:!0,state:e.state,type:e.type})})}path(e=!1){return this.normalize(this._platformStrategy.path(e))}getState(){return this._platformLocation.getState()}isCurrentPathEqualTo(e,t=""){return this.path()==this.normalize(e+to.normalizeQueryParams(t))}normalize(e){return to.stripTrailingSlash(function(e,t){return e&&t.startsWith(e)?t.substring(e.length):t}(this._baseHref,no(e)))}prepareExternalUrl(e){return e&&"/"!==e[0]&&(e="/"+e),this._platformStrategy.prepareExternalUrl(e)}go(e,t="",n=null){this._platformStrategy.pushState(n,"",e,t),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+to.normalizeQueryParams(t)),n)}replaceState(e,t="",n=null){this._platformStrategy.replaceState(n,"",e,t),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+to.normalizeQueryParams(t)),n)}forward(){this._platformStrategy.forward()}back(){this._platformStrategy.back()}onUrlChange(e){this._urlChangeListeners.push(e),this.subscribe(e=>{this._notifyUrlChangeListeners(e.url,e.state)})}_notifyUrlChangeListeners(e="",t){this._urlChangeListeners.forEach(n=>n(e,t))}subscribe(e,t,n){return this._subject.subscribe({next:e,error:t,complete:n})}static normalizeQueryParams(e){return e&&"?"!==e[0]?"?"+e:e}static joinWithSlash(e,t){if(0==e.length)return t;if(0==t.length)return e;let n=0;return e.endsWith("/")&&n++,t.startsWith("/")&&n++,2==n?e+t.substring(1):1==n?e+t:e+"/"+t}static stripTrailingSlash(e){const t=e.match(/#|\?|$/),n=t&&t.index||e.length;return e.slice(0,n-("/"===e[n-1]?1:0))+e.slice(n)}}function no(e){return e.replace(/\/index.html$/,"")}class ro extends Xi{constructor(e,t){super(),this._platformLocation=e,this._baseHref="",null!=t&&(this._baseHref=t)}onPopState(e){this._platformLocation.onPopState(e),this._platformLocation.onHashChange(e)}getBaseHref(){return this._baseHref}path(e=!1){let t=this._platformLocation.hash;return null==t&&(t="#"),t.length>0?t.substring(1):t}prepareExternalUrl(e){const t=to.joinWithSlash(this._baseHref,e);return t.length>0?"#"+t:t}pushState(e,t,n,r){let s=this.prepareExternalUrl(n+to.normalizeQueryParams(r));0==s.length&&(s=this._platformLocation.pathname),this._platformLocation.pushState(e,t,s)}replaceState(e,t,n,r){let s=this.prepareExternalUrl(n+to.normalizeQueryParams(r));0==s.length&&(s=this._platformLocation.pathname),this._platformLocation.replaceState(e,t,s)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}}class so extends Xi{constructor(e,t){if(super(),this._platformLocation=e,null==t&&(t=this._platformLocation.getBaseHrefFromDOM()),null==t)throw new Error("No base href set. Please provide a value for the APP_BASE_HREF token or add a base element to the document.");this._baseHref=t}onPopState(e){this._platformLocation.onPopState(e),this._platformLocation.onHashChange(e)}getBaseHref(){return this._baseHref}prepareExternalUrl(e){return to.joinWithSlash(this._baseHref,e)}path(e=!1){const t=this._platformLocation.pathname+to.normalizeQueryParams(this._platformLocation.search),n=this._platformLocation.hash;return n&&e?`${t}${n}`:t}pushState(e,t,n,r){const s=this.prepareExternalUrl(n+to.normalizeQueryParams(r));this._platformLocation.pushState(e,t,s)}replaceState(e,t,n,r){const s=this.prepareExternalUrl(n+to.normalizeQueryParams(r));this._platformLocation.replaceState(e,t,s)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}}const lo=function(){var e={Zero:0,One:1,Two:2,Few:3,Many:4,Other:5};return e[e.Zero]="Zero",e[e.One]="One",e[e.Two]="Two",e[e.Few]="Few",e[e.Many]="Many",e[e.Other]="Other",e}(),io=new Se("UseV4Plurals");class oo{}class ao extends oo{constructor(e,t){super(),this.locale=e,this.deprecatedPluralFn=t}getPluralCategory(e,t){switch(this.deprecatedPluralFn?this.deprecatedPluralFn(t||this.locale,e):function(e){return function(e){const t=e.toLowerCase().replace(/_/g,"-");let n=ds[t];if(n)return n;const r=t.split("-")[0];if(n=ds[r],n)return n;if("en"===r)return fs;throw new Error(`Missing locale data for the locale "${e}".`)}(e)[ps.PluralCase]}(t||this.locale)(e)){case lo.Zero:return"zero";case lo.One:return"one";case lo.Two:return"two";case lo.Few:return"few";case lo.Many:return"many";default:return"other"}}}class uo{constructor(e,t,n,r){this.$implicit=e,this.ngForOf=t,this.index=n,this.count=r}get first(){return 0===this.index}get last(){return this.index===this.count-1}get even(){return this.index%2==0}get odd(){return!this.even}}class co{constructor(e,t,n){this._viewContainer=e,this._template=t,this._differs=n,this._ngForOfDirty=!0,this._differ=null}set ngForOf(e){this._ngForOf=e,this._ngForOfDirty=!0}set ngForTrackBy(e){Ge()&&null!=e&&"function"!=typeof e&&console&&console.warn&&console.warn(`trackBy must be a function, but received ${JSON.stringify(e)}. `+"See https://angular.io/docs/ts/latest/api/common/index/NgFor-directive.html#!#change-propagation for more information."),this._trackByFn=e}get ngForTrackBy(){return this._trackByFn}set ngForTemplate(e){e&&(this._template=e)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;const n=this._ngForOf;if(!this._differ&&n)try{this._differ=this._differs.find(n).create(this.ngForTrackBy)}catch(t){throw new Error(`Cannot find a differ supporting object '${n}' of type '${e=n,e.name||typeof e}'. NgFor only supports binding to Iterables such as Arrays.`)}}var e;if(this._differ){const e=this._differ.diff(this._ngForOf);e&&this._applyChanges(e)}}_applyChanges(e){const t=[];e.forEachOperation((e,n,r)=>{if(null==e.previousIndex){const n=this._viewContainer.createEmbeddedView(this._template,new uo(null,this._ngForOf,-1,-1),null===r?void 0:r),s=new ho(e,n);t.push(s)}else if(null==r)this._viewContainer.remove(null===n?void 0:n);else if(null!==n){const s=this._viewContainer.get(n);this._viewContainer.move(s,r);const l=new ho(e,s);t.push(l)}});for(let n=0;n<t.length;n++)this._perViewChange(t[n].view,t[n].record);for(let n=0,r=this._viewContainer.length;n<r;n++){const e=this._viewContainer.get(n);e.context.index=n,e.context.count=r,e.context.ngForOf=this._ngForOf}e.forEachIdentityChange(e=>{this._viewContainer.get(e.currentIndex).context.$implicit=e.item})}_perViewChange(e,t){e.context.$implicit=t.item}static ngTemplateContextGuard(e,t){return!0}}class ho{constructor(e,t){this.record=e,this.view=t}}class po{}const go=new Se("DocumentToken");let fo=(()=>{class e{}return e.ngInjectableDef=de({token:e,providedIn:"root",factory:()=>new mo(Oe(go),window,Oe(ze))}),e})();class mo{constructor(e,t,n){this.document=e,this.window=t,this.errorHandler=n,this.offset=()=>[0,0]}setOffset(e){this.offset=Array.isArray(e)?()=>e:e}getScrollPosition(){return this.supportScrollRestoration()?[this.window.scrollX,this.window.scrollY]:[0,0]}scrollToPosition(e){this.supportScrollRestoration()&&this.window.scrollTo(e[0],e[1])}scrollToAnchor(e){if(this.supportScrollRestoration()){e=this.window.CSS&&this.window.CSS.escape?this.window.CSS.escape(e):e.replace(/(\"|\'\ |:|\.|\[|\]|,|=)/g,"\\$1");try{const t=this.document.querySelector(`#${e}`);if(t)return void this.scrollToElement(t);const n=this.document.querySelector(`[name='${e}']`);if(n)return void this.scrollToElement(n)}catch(t){this.errorHandler.handleError(t)}}}setHistoryScrollRestoration(e){if(this.supportScrollRestoration()){const t=this.window.history;t&&t.scrollRestoration&&(t.scrollRestoration=e)}}scrollToElement(e){const t=e.getBoundingClientRect(),n=t.left+this.window.pageXOffset,r=t.top+this.window.pageYOffset,s=this.offset();this.window.scrollTo(n-s[0],r-s[1])}supportScrollRestoration(){try{return!!this.window&&!!this.window.scrollTo}catch(e){return!1}}}const vo=new b(e=>e.complete());function yo(e){return e?function(e){return new b(t=>e.schedule(()=>t.complete()))}(e):vo}function _o(e){const t=new b(t=>{t.next(e),t.complete()});return t._isScalar=!0,t.value=e,t}function wo(...e){let t=e[e.length-1];switch(I(t)?e.pop():t=void 0,e.length){case 0:return yo(t);case 1:return t?q(e,t):_o(e[0]);default:return q(e,t)}}class bo extends k{constructor(e){super(),this._value=e}get value(){return this.getValue()}_subscribe(e){const t=super._subscribe(e);return t&&!t.closed&&e.next(this._value),t}getValue(){if(this.hasError)throw this.thrownError;if(this.closed)throw new S;return this._value}next(e){super.next(this._value=e)}}function Co(){return Error.call(this),this.message="no elements in sequence",this.name="EmptyError",this}Co.prototype=Object.create(Error.prototype);const xo=Co,So={};class Eo{constructor(e){this.resultSelector=e}call(e,t){return t.subscribe(new To(e,this.resultSelector))}}class To extends ${constructor(e,t){super(e),this.resultSelector=t,this.active=0,this.values=[],this.observables=[]}_next(e){this.values.push(So),this.observables.push(e)}_complete(){const e=this.observables,t=e.length;if(0===t)this.destination.complete();else{this.active=t,this.toRespond=t;for(let n=0;n<t;n++){const t=e[n];this.add(L(this,t,t,n))}}}notifyComplete(e){0==(this.active-=1)&&this.destination.complete()}notifyNext(e,t,n,r,s){const l=this.values,i=this.toRespond?l[n]===So?--this.toRespond:this.toRespond:0;l[n]=t,0===i&&(this.resultSelector?this._tryResultSelector(l):this.destination.next(l.slice()))}_tryResultSelector(e){let t;try{t=this.resultSelector.apply(this,e)}catch(n){return void this.destination.error(n)}this.destination.next(t)}}function ko(e){return new b(t=>{let n;try{n=e()}catch(r){return void t.error(r)}return(n?G(n):yo()).subscribe(t)})}function Ao(){return Y(1)}function Io(e,t){return function(n){return n.lift(new Po(e,t))}}class Po{constructor(e,t){this.predicate=e,this.thisArg=t}call(e,t){return t.subscribe(new Oo(e,this.predicate,this.thisArg))}}class Oo extends f{constructor(e,t,n){super(e),this.predicate=t,this.thisArg=n,this.count=0}_next(e){let t;try{t=this.predicate.call(this.thisArg,e,this.count++)}catch(n){return void this.destination.error(n)}t&&this.destination.next(e)}}function Ro(){return Error.call(this),this.message="argument out of range",this.name="ArgumentOutOfRangeError",this}Ro.prototype=Object.create(Error.prototype);const No=Ro;function Do(e){return function(t){return 0===e?yo():t.lift(new Vo(e))}}class Vo{constructor(e){if(this.total=e,this.total<0)throw new No}call(e,t){return t.subscribe(new Mo(e,this.total))}}class Mo extends f{constructor(e,t){super(e),this.total=t,this.ring=new Array,this.count=0}_next(e){const t=this.ring,n=this.total,r=this.count++;t.length<n?t.push(e):t[r%n]=e}_complete(){const e=this.destination;let t=this.count;if(t>0){const n=this.count>=this.total?this.total:this.count,r=this.ring;for(let s=0;s<n;s++){const s=t++%n;e.next(r[s])}}e.complete()}}function Uo(e,t,n){return function(r){return r.lift(new jo(e,t,n))}}class jo{constructor(e,t,n){this.nextOrObserver=e,this.error=t,this.complete=n}call(e,t){return t.subscribe(new Fo(e,this.nextOrObserver,this.error,this.complete))}}class Fo extends f{constructor(e,t,n,s){super(e),this._tapNext=y,this._tapError=y,this._tapComplete=y,this._tapError=n||y,this._tapComplete=s||y,r(t)?(this._context=this,this._tapNext=t):t&&(this._context=t,this._tapNext=t.next||y,this._tapError=t.error||y,this._tapComplete=t.complete||y)}_next(e){try{this._tapNext.call(this._context,e)}catch(t){return void this.destination.error(t)}this.destination.next(e)}_error(e){try{this._tapError.call(this._context,e)}catch(e){return void this.destination.error(e)}this.destination.error(e)}_complete(){try{this._tapComplete.call(this._context)}catch(e){return void this.destination.error(e)}return this.destination.complete()}}const Lo=(e=$o)=>Uo({hasValue:!1,next(){this.hasValue=!0},complete(){if(!this.hasValue)throw e()}});function $o(){return new xo}function Ho(e=null){return t=>t.lift(new zo(e))}class zo{constructor(e){this.defaultValue=e}call(e,t){return t.subscribe(new Bo(e,this.defaultValue))}}class Bo extends f{constructor(e,t){super(e),this.defaultValue=t,this.isEmpty=!0}_next(e){this.isEmpty=!1,this.destination.next(e)}_complete(){this.isEmpty&&this.destination.next(this.defaultValue),this.destination.complete()}}function qo(e,t){const n=arguments.length>=2;return r=>r.pipe(e?Io((t,n)=>e(t,n,r)):K,Do(1),n?Ho(t):Lo(()=>new xo))}function Go(e){return function(t){const n=new Wo(e),r=t.lift(n);return n.caught=r}}class Wo{constructor(e){this.selector=e}call(e,t){return t.subscribe(new Zo(e,this.selector,this.caught))}}class Zo extends ${constructor(e,t,n){super(e),this.selector=t,this.caught=n}error(e){if(!this.isStopped){let n;try{n=this.selector(e,this.caught)}catch(t){return void super.error(t)}this._unsubscribeAndRecycle();const r=new P(this,void 0,void 0);this.add(r),L(this,n,void 0,void 0,r)}}}function Qo(e){return t=>0===e?yo():t.lift(new Ko(e))}class Ko{constructor(e){if(this.total=e,this.total<0)throw new No}call(e,t){return t.subscribe(new Yo(e,this.total))}}class Yo extends f{constructor(e,t){super(e),this.total=t,this.count=0}_next(e){const t=this.total,n=++this.count;n<=t&&(this.destination.next(e),n===t&&(this.destination.complete(),this.unsubscribe()))}}function Jo(e,t){const n=arguments.length>=2;return r=>r.pipe(e?Io((t,n)=>e(t,n,r)):K,Qo(1),n?Ho(t):Lo(()=>new xo))}class Xo{constructor(e,t,n){this.predicate=e,this.thisArg=t,this.source=n}call(e,t){return t.subscribe(new ea(e,this.predicate,this.thisArg,this.source))}}class ea extends f{constructor(e,t,n,r){super(e),this.predicate=t,this.thisArg=n,this.source=r,this.index=0,this.thisArg=n||this}notifyComplete(e){this.destination.next(e),this.destination.complete()}_next(e){let t=!1;try{t=this.predicate.call(this.thisArg,e,this.index++,this.source)}catch(n){return void this.destination.error(n)}t||this.notifyComplete(!1)}_complete(){this.notifyComplete(!0)}}function ta(e,t){return"function"==typeof t?n=>n.pipe(ta((n,r)=>G(e(n,r)).pipe(H((e,s)=>t(n,e,r,s))))):t=>t.lift(new na(e))}class na{constructor(e){this.project=e}call(e,t){return t.subscribe(new ra(e,this.project))}}class ra extends ${constructor(e,t){super(e),this.project=t,this.index=0}_next(e){let t;const n=this.index++;try{t=this.project(e,n)}catch(r){return void this.destination.error(r)}this._innerSub(t,e,n)}_innerSub(e,t,n){const r=this.innerSubscription;r&&r.unsubscribe();const s=new P(this,void 0,void 0);this.destination.add(s),this.innerSubscription=L(this,e,t,n,s)}_complete(){const{innerSubscription:e}=this;e&&!e.closed||super._complete(),this.unsubscribe()}_unsubscribe(){this.innerSubscription=null}notifyComplete(e){this.destination.remove(e),this.innerSubscription=null,this.isStopped&&super._complete()}notifyNext(e,t,n,r,s){this.destination.next(t)}}function sa(e,t){let n=!1;return arguments.length>=2&&(n=!0),function(r){return r.lift(new la(e,t,n))}}class la{constructor(e,t,n=!1){this.accumulator=e,this.seed=t,this.hasSeed=n}call(e,t){return t.subscribe(new ia(e,this.accumulator,this.seed,this.hasSeed))}}class ia extends f{constructor(e,t,n,r){super(e),this.accumulator=t,this._seed=n,this.hasSeed=r,this.index=0}get seed(){return this._seed}set seed(e){this.hasSeed=!0,this._seed=e}_next(e){if(this.hasSeed)return this._tryNext(e);this.seed=e,this.destination.next(e)}_tryNext(e){const t=this.index++;let n;try{n=this.accumulator(this.seed,e,t)}catch(r){this.destination.error(r)}this.seed=n,this.destination.next(n)}}function oa(e,t){return W(e,t,1)}class aa{constructor(e){this.callback=e}call(e,t){return t.subscribe(new ua(e,this.callback))}}class ua extends f{constructor(e,t){super(e),this.add(new d(t))}}let ca=null;function ha(){return ca}const da={class:"className",innerHtml:"innerHTML",readonly:"readOnly",tabindex:"tabIndex"},pa={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},ga={A:"1",B:"2",C:"3",D:"4",E:"5",F:"6",G:"7",H:"8",I:"9",J:"*",K:"+",M:"-",N:".",O:"/","`":"0","\x90":"NumLock"},fa=(()=>{if(xe.Node)return xe.Node.prototype.contains||function(e){return!!(16&this.compareDocumentPosition(e))}})();class ma extends class extends class{constructor(){this.resourceLoaderType=null}get attrToPropMap(){return this._attrToPropMap}set attrToPropMap(e){this._attrToPropMap=e}}{constructor(){super(),this._animationPrefix=null,this._transitionEnd=null;try{const e=this.createElement("div",document);if(null!=this.getStyle(e,"animationName"))this._animationPrefix="";else{const t=["Webkit","Moz","O","ms"];for(let n=0;n<t.length;n++)if(null!=this.getStyle(e,t[n]+"AnimationName")){this._animationPrefix="-"+t[n].toLowerCase()+"-";break}}const t={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};Object.keys(t).forEach(n=>{null!=this.getStyle(e,n)&&(this._transitionEnd=t[n])})}catch(e){this._animationPrefix=null,this._transitionEnd=null}}getDistributedNodes(e){return e.getDistributedNodes()}resolveAndSetHref(e,t,n){e.href=null==n?t:t+"/../"+n}supportsDOMEvents(){return!0}supportsNativeShadowDOM(){return"function"==typeof document.body.createShadowRoot}getAnimationPrefix(){return this._animationPrefix?this._animationPrefix:""}getTransitionEnd(){return this._transitionEnd?this._transitionEnd:""}supportsAnimation(){return null!=this._animationPrefix&&null!=this._transitionEnd}}{parse(e){throw new Error("parse not implemented")}static makeCurrent(){var e;e=new ma,ca||(ca=e)}hasProperty(e,t){return t in e}setProperty(e,t,n){e[t]=n}getProperty(e,t){return e[t]}invoke(e,t,n){e[t](...n)}logError(e){window.console&&(console.error?console.error(e):console.log(e))}log(e){window.console&&window.console.log&&window.console.log(e)}logGroup(e){window.console&&window.console.group&&window.console.group(e)}logGroupEnd(){window.console&&window.console.groupEnd&&window.console.groupEnd()}get attrToPropMap(){return da}contains(e,t){return fa.call(e,t)}querySelector(e,t){return e.querySelector(t)}querySelectorAll(e,t){return e.querySelectorAll(t)}on(e,t,n){e.addEventListener(t,n,!1)}onAndCancel(e,t,n){return e.addEventListener(t,n,!1),()=>{e.removeEventListener(t,n,!1)}}dispatchEvent(e,t){e.dispatchEvent(t)}createMouseEvent(e){const t=this.getDefaultDocument().createEvent("MouseEvent");return t.initEvent(e,!0,!0),t}createEvent(e){const t=this.getDefaultDocument().createEvent("Event");return t.initEvent(e,!0,!0),t}preventDefault(e){e.preventDefault(),e.returnValue=!1}isPrevented(e){return e.defaultPrevented||null!=e.returnValue&&!e.returnValue}getInnerHTML(e){return e.innerHTML}getTemplateContent(e){return"content"in e&&this.isTemplateElement(e)?e.content:null}getOuterHTML(e){return e.outerHTML}nodeName(e){return e.nodeName}nodeValue(e){return e.nodeValue}type(e){return e.type}content(e){return this.hasProperty(e,"content")?e.content:e}firstChild(e){return e.firstChild}nextSibling(e){return e.nextSibling}parentElement(e){return e.parentNode}childNodes(e){return e.childNodes}childNodesAsList(e){const t=e.childNodes,n=new Array(t.length);for(let r=0;r<t.length;r++)n[r]=t[r];return n}clearNodes(e){for(;e.firstChild;)e.removeChild(e.firstChild)}appendChild(e,t){e.appendChild(t)}removeChild(e,t){e.removeChild(t)}replaceChild(e,t,n){e.replaceChild(t,n)}remove(e){return e.parentNode&&e.parentNode.removeChild(e),e}insertBefore(e,t,n){e.insertBefore(n,t)}insertAllBefore(e,t,n){n.forEach(n=>e.insertBefore(n,t))}insertAfter(e,t,n){e.insertBefore(n,t.nextSibling)}setInnerHTML(e,t){e.innerHTML=t}getText(e){return e.textContent}setText(e,t){e.textContent=t}getValue(e){return e.value}setValue(e,t){e.value=t}getChecked(e){return e.checked}setChecked(e,t){e.checked=t}createComment(e){return this.getDefaultDocument().createComment(e)}createTemplate(e){const t=this.getDefaultDocument().createElement("template");return t.innerHTML=e,t}createElement(e,t){return(t=t||this.getDefaultDocument()).createElement(e)}createElementNS(e,t,n){return(n=n||this.getDefaultDocument()).createElementNS(e,t)}createTextNode(e,t){return(t=t||this.getDefaultDocument()).createTextNode(e)}createScriptTag(e,t,n){const r=(n=n||this.getDefaultDocument()).createElement("SCRIPT");return r.setAttribute(e,t),r}createStyleElement(e,t){const n=(t=t||this.getDefaultDocument()).createElement("style");return this.appendChild(n,this.createTextNode(e,t)),n}createShadowRoot(e){return e.createShadowRoot()}getShadowRoot(e){return e.shadowRoot}getHost(e){return e.host}clone(e){return e.cloneNode(!0)}getElementsByClassName(e,t){return e.getElementsByClassName(t)}getElementsByTagName(e,t){return e.getElementsByTagName(t)}classList(e){return Array.prototype.slice.call(e.classList,0)}addClass(e,t){e.classList.add(t)}removeClass(e,t){e.classList.remove(t)}hasClass(e,t){return e.classList.contains(t)}setStyle(e,t,n){e.style[t]=n}removeStyle(e,t){e.style[t]=""}getStyle(e,t){return e.style[t]}hasStyle(e,t,n){const r=this.getStyle(e,t)||"";return n?r==n:r.length>0}tagName(e){return e.tagName}attributeMap(e){const t=new Map,n=e.attributes;for(let r=0;r<n.length;r++){const e=n.item(r);t.set(e.name,e.value)}return t}hasAttribute(e,t){return e.hasAttribute(t)}hasAttributeNS(e,t,n){return e.hasAttributeNS(t,n)}getAttribute(e,t){return e.getAttribute(t)}getAttributeNS(e,t,n){return e.getAttributeNS(t,n)}setAttribute(e,t,n){e.setAttribute(t,n)}setAttributeNS(e,t,n,r){e.setAttributeNS(t,n,r)}removeAttribute(e,t){e.removeAttribute(t)}removeAttributeNS(e,t,n){e.removeAttributeNS(t,n)}templateAwareRoot(e){return this.isTemplateElement(e)?this.content(e):e}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}getBoundingClientRect(e){try{return e.getBoundingClientRect()}catch(t){return{top:0,bottom:0,left:0,right:0,width:0,height:0}}}getTitle(e){return e.title}setTitle(e,t){e.title=t||""}elementMatches(e,t){return!!this.isElementNode(e)&&(e.matches&&e.matches(t)||e.msMatchesSelector&&e.msMatchesSelector(t)||e.webkitMatchesSelector&&e.webkitMatchesSelector(t))}isTemplateElement(e){return this.isElementNode(e)&&"TEMPLATE"===e.nodeName}isTextNode(e){return e.nodeType===Node.TEXT_NODE}isCommentNode(e){return e.nodeType===Node.COMMENT_NODE}isElementNode(e){return e.nodeType===Node.ELEMENT_NODE}hasShadowRoot(e){return null!=e.shadowRoot&&e instanceof HTMLElement}isShadowRoot(e){return e instanceof DocumentFragment}importIntoDoc(e){return document.importNode(this.templateAwareRoot(e),!0)}adoptNode(e){return document.adoptNode(e)}getHref(e){return e.getAttribute("href")}getEventKey(e){let t=e.key;if(null==t){if(t=e.keyIdentifier,null==t)return"Unidentified";t.startsWith("U+")&&(t=String.fromCharCode(parseInt(t.substring(2),16)),3===e.location&&ga.hasOwnProperty(t)&&(t=ga[t]))}return pa[t]||t}getGlobalEventTarget(e,t){return"window"===t?window:"document"===t?e:"body"===t?e.body:null}getHistory(){return window.history}getLocation(){return window.location}getBaseHref(e){const t=ya||(ya=document.querySelector("base"),ya)?ya.getAttribute("href"):null;return null==t?null:(n=t,va||(va=document.createElement("a")),va.setAttribute("href",n),"/"===va.pathname.charAt(0)?va.pathname:"/"+va.pathname);var n}resetBaseElement(){ya=null}getUserAgent(){return window.navigator.userAgent}setData(e,t,n){this.setAttribute(e,"data-"+t,n)}getData(e,t){return this.getAttribute(e,"data-"+t)}getComputedStyle(e){return getComputedStyle(e)}supportsWebAnimation(){return"function"==typeof Element.prototype.animate}performanceNow(){return window.performance&&window.performance.now?window.performance.now():(new Date).getTime()}supportsCookies(){return!0}getCookie(e){return function(e,t){t=encodeURIComponent(t);for(const n of e.split(";")){const e=n.indexOf("="),[r,s]=-1==e?[n,""]:[n.slice(0,e),n.slice(e+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,e)}setCookie(e,t){document.cookie=encodeURIComponent(e)+"="+encodeURIComponent(t)}}let va,ya=null;function _a(){return!!window.history.pushState}const wa=new Se("TRANSITION_ID"),ba=[{provide:_s,useFactory:function(e,t,n){return()=>{n.get(ws).donePromise.then(()=>{const n=ha();Array.prototype.slice.apply(n.querySelectorAll(t,"style[ng-transition]")).filter(t=>n.getAttribute(t,"ng-transition")===e).forEach(e=>n.remove(e))})}},deps:[wa,go,St],multi:!0}];class Ca{static init(){var e;e=new Ca,nl=e}addToWindow(e){xe.getAngularTestability=(t,n=!0)=>{const r=e.findTestabilityInTree(t,n);if(null==r)throw new Error("Could not find testability for element.");return r},xe.getAllAngularTestabilities=()=>e.getAllTestabilities(),xe.getAllAngularRootElements=()=>e.getAllRootElements(),xe.frameworkStabilizers||(xe.frameworkStabilizers=[]),xe.frameworkStabilizers.push(e=>{const t=xe.getAllAngularTestabilities();let n=t.length,r=!1;const s=function(t){r=r||t,n--,0==n&&e(r)};t.forEach((function(e){e.whenStable(s)}))})}findTestabilityInTree(e,t,n){if(null==t)return null;const r=e.getTestability(t);return null!=r?r:n?ha().isShadowRoot(t)?this.findTestabilityInTree(e,ha().getHost(t),!0):this.findTestabilityInTree(e,ha().parentElement(t),!0):null}}function xa(e,t){"undefined"!=typeof COMPILED&&COMPILED||((xe.ng=xe.ng||{})[e]=t)}const Sa=(()=>({ApplicationRef:ul,NgZone:qs}))();function Ea(e){return wl(e)}const Ta=new Se("EventManagerPlugins");class ka{constructor(e,t){this._zone=t,this._eventNameToPlugin=new Map,e.forEach(e=>e.manager=this),this._plugins=e.slice().reverse()}addEventListener(e,t,n){return this._findPluginFor(t).addEventListener(e,t,n)}addGlobalEventListener(e,t,n){return this._findPluginFor(t).addGlobalEventListener(e,t,n)}getZone(){return this._zone}_findPluginFor(e){const t=this._eventNameToPlugin.get(e);if(t)return t;const n=this._plugins;for(let r=0;r<n.length;r++){const t=n[r];if(t.supports(e))return this._eventNameToPlugin.set(e,t),t}throw new Error(`No event manager plugin found for event ${e}`)}}class Aa{constructor(e){this._doc=e}addGlobalEventListener(e,t,n){const r=ha().getGlobalEventTarget(this._doc,e);if(!r)throw new Error(`Unsupported event target ${r} for event ${t}`);return this.addEventListener(r,t,n)}}class Ia{constructor(){this._stylesSet=new Set}addStyles(e){const t=new Set;e.forEach(e=>{this._stylesSet.has(e)||(this._stylesSet.add(e),t.add(e))}),this.onStylesAdded(t)}onStylesAdded(e){}getAllStyles(){return Array.from(this._stylesSet)}}class Pa extends Ia{constructor(e){super(),this._doc=e,this._hostNodes=new Set,this._styleNodes=new Set,this._hostNodes.add(e.head)}_addStylesToHost(e,t){e.forEach(e=>{const n=this._doc.createElement("style");n.textContent=e,this._styleNodes.add(t.appendChild(n))})}addHost(e){this._addStylesToHost(this._stylesSet,e),this._hostNodes.add(e)}removeHost(e){this._hostNodes.delete(e)}onStylesAdded(e){this._hostNodes.forEach(t=>this._addStylesToHost(e,t))}ngOnDestroy(){this._styleNodes.forEach(e=>ha().remove(e))}}const Oa={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/"},Ra=/%COMP%/g;function Na(e,t,n){for(let r=0;r<t.length;r++){let s=t[r];Array.isArray(s)?Na(e,s,n):(s=s.replace(Ra,e),n.push(s))}return n}function Da(e){return t=>{!1===e(t)&&(t.preventDefault(),t.returnValue=!1)}}class Va{constructor(e,t,n){this.eventManager=e,this.sharedStylesHost=t,this.appId=n,this.rendererByCompId=new Map,this.defaultRenderer=new Ma(e)}createRenderer(e,t){if(!e||!t)return this.defaultRenderer;switch(t.encapsulation){case je.Emulated:{let n=this.rendererByCompId.get(t.id);return n||(n=new Fa(this.eventManager,this.sharedStylesHost,t,this.appId),this.rendererByCompId.set(t.id,n)),n.applyToHost(e),n}case je.Native:case je.ShadowDom:return new La(this.eventManager,this.sharedStylesHost,e,t);default:if(!this.rendererByCompId.has(t.id)){const e=Na(t.id,t.styles,[]);this.sharedStylesHost.addStyles(e),this.rendererByCompId.set(t.id,this.defaultRenderer)}return this.defaultRenderer}}begin(){}end(){}}class Ma{constructor(e){this.eventManager=e,this.data=Object.create(null)}destroy(){}createElement(e,t){return t?document.createElementNS(Oa[t]||t,e):document.createElement(e)}createComment(e){return document.createComment(e)}createText(e){return document.createTextNode(e)}appendChild(e,t){e.appendChild(t)}insertBefore(e,t,n){e&&e.insertBefore(t,n)}removeChild(e,t){e&&e.removeChild(t)}selectRootElement(e,t){let n="string"==typeof e?document.querySelector(e):e;if(!n)throw new Error(`The selector "${e}" did not match any elements`);return t||(n.textContent=""),n}parentNode(e){return e.parentNode}nextSibling(e){return e.nextSibling}setAttribute(e,t,n,r){if(r){t=r+":"+t;const s=Oa[r];s?e.setAttributeNS(s,t,n):e.setAttribute(t,n)}else e.setAttribute(t,n)}removeAttribute(e,t,n){if(n){const r=Oa[n];r?e.removeAttributeNS(r,t):e.removeAttribute(`${n}:${t}`)}else e.removeAttribute(t)}addClass(e,t){e.classList.add(t)}removeClass(e,t){e.classList.remove(t)}setStyle(e,t,n,r){r&tn.DashCase?e.style.setProperty(t,n,r&tn.Important?"important":""):e.style[t]=n}removeStyle(e,t,n){n&tn.DashCase?e.style.removeProperty(t):e.style[t]=""}setProperty(e,t,n){ja(t,"property"),e[t]=n}setValue(e,t){e.nodeValue=t}listen(e,t,n){return ja(t,"listener"),"string"==typeof e?this.eventManager.addGlobalEventListener(e,t,Da(n)):this.eventManager.addEventListener(e,t,Da(n))}}const Ua=(()=>"@".charCodeAt(0))();function ja(e,t){if(e.charCodeAt(0)===Ua)throw new Error(`Found the synthetic ${t} ${e}. Please include either "BrowserAnimationsModule" or "NoopAnimationsModule" in your application.`)}class Fa extends Ma{constructor(e,t,n,r){super(e),this.component=n;const s=Na(r+"-"+n.id,n.styles,[]);t.addStyles(s),this.contentAttr="_ngcontent-%COMP%".replace(Ra,r+"-"+n.id),this.hostAttr=function(e){return"_nghost-%COMP%".replace(Ra,e)}(r+"-"+n.id)}applyToHost(e){super.setAttribute(e,this.hostAttr,"")}createElement(e,t){const n=super.createElement(e,t);return super.setAttribute(n,this.contentAttr,""),n}}class La extends Ma{constructor(e,t,n,r){super(e),this.sharedStylesHost=t,this.hostEl=n,this.component=r,this.shadowRoot=r.encapsulation===je.ShadowDom?n.attachShadow({mode:"open"}):n.createShadowRoot(),this.sharedStylesHost.addHost(this.shadowRoot);const s=Na(r.id,r.styles,[]);for(let l=0;l<s.length;l++){const e=document.createElement("style");e.textContent=s[l],this.shadowRoot.appendChild(e)}}nodeOrShadowRoot(e){return e===this.hostEl?this.shadowRoot:e}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}appendChild(e,t){return super.appendChild(this.nodeOrShadowRoot(e),t)}insertBefore(e,t,n){return super.insertBefore(this.nodeOrShadowRoot(e),t,n)}removeChild(e,t){return super.removeChild(this.nodeOrShadowRoot(e),t)}parentNode(e){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(e)))}}const $a=(()=>"undefined"!=typeof Zone&&Zone.__symbol__||function(e){return"__zone_symbol__"+e})(),Ha=$a("addEventListener"),za=$a("removeEventListener"),Ba={},qa="__zone_symbol__propagationStopped",Ga=(()=>{const e="undefined"!=typeof Zone&&Zone[$a("BLACK_LISTED_EVENTS")];if(e){const t={};return e.forEach(e=>{t[e]=e}),t}})(),Wa=function(e){return!!Ga&&Ga.hasOwnProperty(e)},Za=function(e){const t=Ba[e.type];if(!t)return;const n=this[t];if(!n)return;const r=[e];if(1===n.length){const e=n[0];return e.zone!==Zone.current?e.zone.run(e.handler,this,r):e.handler.apply(this,r)}{const t=n.slice();for(let n=0;n<t.length&&!0!==e[qa];n++){const e=t[n];e.zone!==Zone.current?e.zone.run(e.handler,this,r):e.handler.apply(this,r)}}};class Qa extends Aa{constructor(e,t,n){super(e),this.ngZone=t,n&&function(e){return"server"===e}(n)||this.patchEvent()}patchEvent(){if("undefined"==typeof Event||!Event||!Event.prototype)return;if(Event.prototype.__zone_symbol__stopImmediatePropagation)return;const e=Event.prototype.__zone_symbol__stopImmediatePropagation=Event.prototype.stopImmediatePropagation;Event.prototype.stopImmediatePropagation=function(){this&&(this[qa]=!0),e&&e.apply(this,arguments)}}supports(e){return!0}addEventListener(e,t,n){let r=n;if(!e[Ha]||qs.isInAngularZone()&&!Wa(t))e.addEventListener(t,r,!1);else{let n=Ba[t];n||(n=Ba[t]=$a("ANGULAR"+t+"FALSE"));let s=e[n];const l=s&&s.length>0;s||(s=e[n]=[]);const i=Wa(t)?Zone.root:Zone.current;if(0===s.length)s.push({zone:i,handler:r});else{let e=!1;for(let t=0;t<s.length;t++)if(s[t].handler===r){e=!0;break}e||s.push({zone:i,handler:r})}l||e[Ha](t,Za,!1)}return()=>this.removeEventListener(e,t,r)}removeEventListener(e,t,n){let r=e[za];if(!r)return e.removeEventListener.apply(e,[t,n,!1]);let s=Ba[t],l=s&&e[s];if(!l)return e.removeEventListener.apply(e,[t,n,!1]);let i=!1;for(let o=0;o<l.length;o++)if(l[o].handler===n){i=!0,l.splice(o,1);break}i?0===l.length&&r.apply(e,[t,Za,!1]):e.removeEventListener.apply(e,[t,n,!1])}}const Ka={pan:!0,panstart:!0,panmove:!0,panend:!0,pancancel:!0,panleft:!0,panright:!0,panup:!0,pandown:!0,pinch:!0,pinchstart:!0,pinchmove:!0,pinchend:!0,pinchcancel:!0,pinchin:!0,pinchout:!0,press:!0,pressup:!0,rotate:!0,rotatestart:!0,rotatemove:!0,rotateend:!0,rotatecancel:!0,swipe:!0,swipeleft:!0,swiperight:!0,swipeup:!0,swipedown:!0,tap:!0},Ya=new Se("HammerGestureConfig"),Ja=new Se("HammerLoader");class Xa{constructor(){this.events=[],this.overrides={}}buildHammer(e){const t=new Hammer(e,this.options);t.get("pinch").set({enable:!0}),t.get("rotate").set({enable:!0});for(const n in this.overrides)t.get(n).set(this.overrides[n]);return t}}class eu extends Aa{constructor(e,t,n,r){super(e),this._config=t,this.console=n,this.loader=r}supports(e){return!(!Ka.hasOwnProperty(e.toLowerCase())&&!this.isCustomEvent(e)||!window.Hammer&&!this.loader&&(this.console.warn(`The "${e}" event cannot be bound because Hammer.JS is not `+"loaded and no custom loader has been specified."),1))}addEventListener(e,t,n){const r=this.manager.getZone();if(t=t.toLowerCase(),!window.Hammer&&this.loader){let r=!1,s=()=>{r=!0};return this.loader().then(()=>{if(!window.Hammer)return this.console.warn("The custom HAMMER_LOADER completed, but Hammer.JS is not present."),void(s=()=>{});r||(s=this.addEventListener(e,t,n))}).catch(()=>{this.console.warn(`The "${t}" event cannot be bound because the custom `+"Hammer.JS loader failed."),s=()=>{}}),()=>{s()}}return r.runOutsideAngular(()=>{const s=this._config.buildHammer(e),l=function(e){r.runGuarded((function(){n(e)}))};return s.on(t,l),()=>{s.off(t,l),"function"==typeof s.destroy&&s.destroy()}})}isCustomEvent(e){return this._config.events.indexOf(e)>-1}}const tu=["alt","control","meta","shift"],nu={alt:e=>e.altKey,control:e=>e.ctrlKey,meta:e=>e.metaKey,shift:e=>e.shiftKey};class ru extends Aa{constructor(e){super(e)}supports(e){return null!=ru.parseEventName(e)}addEventListener(e,t,n){const r=ru.parseEventName(t),s=ru.eventCallback(r.fullKey,n,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>ha().onAndCancel(e,r.domEventName,s))}static parseEventName(e){const t=e.toLowerCase().split("."),n=t.shift();if(0===t.length||"keydown"!==n&&"keyup"!==n)return null;const r=ru._normalizeKey(t.pop());let s="";if(tu.forEach(e=>{const n=t.indexOf(e);n>-1&&(t.splice(n,1),s+=e+".")}),s+=r,0!=t.length||0===r.length)return null;const l={};return l.domEventName=n,l.fullKey=s,l}static getEventFullKey(e){let t="",n=ha().getEventKey(e);return n=n.toLowerCase()," "===n?n="space":"."===n&&(n="dot"),tu.forEach(r=>{r!=n&&(0,nu[r])(e)&&(t+=r+".")}),t+=n,t}static eventCallback(e,t,n){return r=>{ru.getEventFullKey(r)===e&&n.runGuarded(()=>t(r))}}static _normalizeKey(e){switch(e){case"esc":return"escape";default:return e}}}class su{}class lu extends su{constructor(e){super(),this._doc=e}sanitize(e,t){if(null==t)return null;switch(e){case gt.NONE:return t;case gt.HTML:return t instanceof ou?t.changingThisBreaksApplicationSecurity:(this.checkNotSafeValue(t,"HTML"),function(e,t){let n=null;try{dt=dt||new We(e);let r=t?String(t):"";n=dt.getInertBodyElement(r);let s=5,l=r;do{if(0===s)throw new Error("Failed to sanitize html because the input is unstable");s--,r=l,l=n.innerHTML,n=dt.getInertBodyElement(r)}while(r!==l);const i=new at,o=i.sanitizeChildren(pt(n)||n);return Ge()&&i.sanitizedSomething&&console.warn("WARNING: sanitizing HTML stripped some content, see http://g.co/ng/security#xss"),o}finally{if(n){const e=pt(n)||n;for(;e.firstChild;)e.removeChild(e.firstChild)}}}(this._doc,String(t)));case gt.STYLE:return t instanceof au?t.changingThisBreaksApplicationSecurity:(this.checkNotSafeValue(t,"Style"),function(e){if(!(e=String(e).trim()))return"";const t=e.match(vt);return t&&Ke(t[1])===t[1]||e.match(mt)&&function(e){let t=!0,n=!0;for(let r=0;r<e.length;r++){const s=e.charAt(r);"'"===s&&n?t=!t:'"'===s&&t&&(n=!n)}return t&&n}(e)?e:(Ge()&&console.warn(`WARNING: sanitizing unsafe style value ${e} (see http://g.co/ng/security#xss).`),"unsafe")}(t));case gt.SCRIPT:if(t instanceof uu)return t.changingThisBreaksApplicationSecurity;throw this.checkNotSafeValue(t,"Script"),new Error("unsafe value used in a script context");case gt.URL:return t instanceof hu||t instanceof cu?t.changingThisBreaksApplicationSecurity:(this.checkNotSafeValue(t,"URL"),Ke(String(t)));case gt.RESOURCE_URL:if(t instanceof hu)return t.changingThisBreaksApplicationSecurity;throw this.checkNotSafeValue(t,"ResourceURL"),new Error("unsafe value used in a resource URL context (see http://g.co/ng/security#xss)");default:throw new Error(`Unexpected SecurityContext ${e} (see http://g.co/ng/security#xss)`)}}checkNotSafeValue(e,t){if(e instanceof iu)throw new Error(`Required a safe ${t}, got a ${e.getTypeName()} `+"(see http://g.co/ng/security#xss)")}bypassSecurityTrustHtml(e){return new ou(e)}bypassSecurityTrustStyle(e){return new au(e)}bypassSecurityTrustScript(e){return new uu(e)}bypassSecurityTrustUrl(e){return new cu(e)}bypassSecurityTrustResourceUrl(e){return new hu(e)}}class iu{constructor(e){this.changingThisBreaksApplicationSecurity=e}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity}`+" (see http://g.co/ng/security#xss)"}}class ou extends iu{getTypeName(){return"HTML"}}class au extends iu{getTypeName(){return"Style"}}class uu extends iu{getTypeName(){return"Script"}}class cu extends iu{getTypeName(){return"URL"}}class hu extends iu{getTypeName(){return"ResourceURL"}}const du=ll(Cl,"browser",[{provide:Es,useValue:"browser"},{provide:Ss,useValue:function(){ma.makeCurrent(),Ca.init()},multi:!0},{provide:Yi,useClass:class extends Yi{constructor(e){super(),this._doc=e,this._init()}_init(){this.location=ha().getLocation(),this._history=ha().getHistory()}getBaseHrefFromDOM(){return ha().getBaseHref(this._doc)}onPopState(e){ha().getGlobalEventTarget(this._doc,"window").addEventListener("popstate",e,!1)}onHashChange(e){ha().getGlobalEventTarget(this._doc,"window").addEventListener("hashchange",e,!1)}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(e){this.location.pathname=e}pushState(e,t,n){_a()?this._history.pushState(e,t,n):this.location.hash=n}replaceState(e,t,n){_a()?this._history.replaceState(e,t,n):this.location.hash=n}forward(){this._history.forward()}back(){this._history.back()}getState(){return this._history.state}},deps:[go]},{provide:go,useFactory:function(){return document},deps:[]}]);function pu(){return new ze}class gu{constructor(e){if(e)throw new Error("BrowserModule has already been loaded. If you need access to common directives such as NgIf and NgFor from a lazy loaded module, import CommonModule instead.")}static withServerTransition(e){return{ngModule:gu,providers:[{provide:bs,useValue:e.appId},{provide:wa,useExisting:bs},ba]}}}"undefined"!=typeof window&&window;class fu{constructor(e,t){this.id=e,this.url=t}}class mu extends fu{constructor(e,t,n="imperative",r=null){super(e,t),this.navigationTrigger=n,this.restoredState=r}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}}class vu extends fu{constructor(e,t,n){super(e,t),this.urlAfterRedirects=n}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}}class yu extends fu{constructor(e,t,n){super(e,t),this.reason=n}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}}class _u extends fu{constructor(e,t,n){super(e,t),this.error=n}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}}class wu extends fu{constructor(e,t,n,r){super(e,t),this.urlAfterRedirects=n,this.state=r}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class bu extends fu{constructor(e,t,n,r){super(e,t),this.urlAfterRedirects=n,this.state=r}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Cu extends fu{constructor(e,t,n,r,s){super(e,t),this.urlAfterRedirects=n,this.state=r,this.shouldActivate=s}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}}class xu extends fu{constructor(e,t,n,r){super(e,t),this.urlAfterRedirects=n,this.state=r}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Su extends fu{constructor(e,t,n,r){super(e,t),this.urlAfterRedirects=n,this.state=r}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Eu{constructor(e){this.route=e}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}}class Tu{constructor(e){this.route=e}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}}class ku{constructor(e){this.snapshot=e}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class Au{constructor(e){this.snapshot=e}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class Iu{constructor(e){this.snapshot=e}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class Pu{constructor(e){this.snapshot=e}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class Ou{constructor(e,t,n){this.routerEvent=e,this.position=t,this.anchor=n}toString(){return`Scroll(anchor: '${this.anchor}', position: '${this.position?`${this.position[0]}, ${this.position[1]}`:null}')`}}class Ru{}class Nu{constructor(e){this.params=e||{}}has(e){return this.params.hasOwnProperty(e)}get(e){if(this.has(e)){const t=this.params[e];return Array.isArray(t)?t[0]:t}return null}getAll(e){if(this.has(e)){const t=this.params[e];return Array.isArray(t)?t:[t]}return[]}get keys(){return Object.keys(this.params)}}function Du(e){return new Nu(e)}function Vu(e){const t=Error("NavigationCancelingError: "+e);return t.ngNavigationCancelingError=!0,t}function Mu(e,t,n){const r=n.path.split("/");if(r.length>e.length)return null;if("full"===n.pathMatch&&(t.hasChildren()||r.length<e.length))return null;const s={};for(let l=0;l<r.length;l++){const t=r[l],n=e[l];if(t.startsWith(":"))s[t.substring(1)]=n;else if(t!==n.path)return null}return{consumed:e.slice(0,r.length),posParams:s}}class Uu{constructor(e,t){this.routes=e,this.module=t}}function ju(e,t=""){for(let n=0;n<e.length;n++){const r=e[n];Fu(r,Lu(t,r))}}function Fu(e,t){if(!e)throw new Error(`\n Invalid configuration of route '${t}': Encountered undefined route.\n The reason might be an extra comma.\n\n Example:\n const routes: Routes = [\n { path: '', redirectTo: '/dashboard', pathMatch: 'full' },\n { path: 'dashboard', component: DashboardComponent },, << two commas\n { path: 'detail/:id', component: HeroDetailComponent }\n ];\n `);if(Array.isArray(e))throw new Error(`Invalid configuration of route '${t}': Array cannot be specified`);if(!e.component&&!e.children&&!e.loadChildren&&e.outlet&&"primary"!==e.outlet)throw new Error(`Invalid configuration of route '${t}': a componentless route without children or loadChildren cannot have a named outlet set`);if(e.redirectTo&&e.children)throw new Error(`Invalid configuration of route '${t}': redirectTo and children cannot be used together`);if(e.redirectTo&&e.loadChildren)throw new Error(`Invalid configuration of route '${t}': redirectTo and loadChildren cannot be used together`);if(e.children&&e.loadChildren)throw new Error(`Invalid configuration of route '${t}': children and loadChildren cannot be used together`);if(e.redirectTo&&e.component)throw new Error(`Invalid configuration of route '${t}': redirectTo and component cannot be used together`);if(e.path&&e.matcher)throw new Error(`Invalid configuration of route '${t}': path and matcher cannot be used together`);if(void 0===e.redirectTo&&!e.component&&!e.children&&!e.loadChildren)throw new Error(`Invalid configuration of route '${t}'. One of the following must be provided: component, redirectTo, children or loadChildren`);if(void 0===e.path&&void 0===e.matcher)throw new Error(`Invalid configuration of route '${t}': routes must have either a path or a matcher specified`);if("string"==typeof e.path&&"/"===e.path.charAt(0))throw new Error(`Invalid configuration of route '${t}': path cannot start with a slash`);if(""===e.path&&void 0!==e.redirectTo&&void 0===e.pathMatch)throw new Error(`Invalid configuration of route '{path: "${t}", redirectTo: "${e.redirectTo}"}': please provide 'pathMatch'. The default value of 'pathMatch' is 'prefix', but often the intent is to use 'full'.`);if(void 0!==e.pathMatch&&"full"!==e.pathMatch&&"prefix"!==e.pathMatch)throw new Error(`Invalid configuration of route '${t}': pathMatch can only be set to 'prefix' or 'full'`);e.children&&ju(e.children,t)}function Lu(e,t){return t?e||t.path?e&&!t.path?`${e}/`:!e&&t.path?t.path:`${e}/${t.path}`:"":e}function $u(e){const t=e.children&&e.children.map($u),n=t?Object.assign({},e,{children:t}):Object.assign({},e);return!n.component&&(t||n.loadChildren)&&n.outlet&&"primary"!==n.outlet&&(n.component=Ru),n}function Hu(e,t){const n=Object.keys(e),r=Object.keys(t);if(!n||!r||n.length!=r.length)return!1;let s;for(let l=0;l<n.length;l++)if(s=n[l],e[s]!==t[s])return!1;return!0}function zu(e){return Array.prototype.concat.apply([],e)}function Bu(e){return e.length>0?e[e.length-1]:null}function qu(e,t){for(const n in e)e.hasOwnProperty(n)&&t(e[n],n)}function Gu(e){return $t(e)?e:Lt(e)?G(Promise.resolve(e)):wo(e)}function Wu(e,t,n){return n?function(e,t){return Hu(e,t)}(e.queryParams,t.queryParams)&&function e(t,n){if(!Yu(t.segments,n.segments))return!1;if(t.numberOfChildren!==n.numberOfChildren)return!1;for(const r in n.children){if(!t.children[r])return!1;if(!e(t.children[r],n.children[r]))return!1}return!0}(e.root,t.root):function(e,t){return Object.keys(t).length<=Object.keys(e).length&&Object.keys(t).every(n=>t[n]===e[n])}(e.queryParams,t.queryParams)&&function e(t,n){return function t(n,r,s){if(n.segments.length>s.length)return!!Yu(n.segments.slice(0,s.length),s)&&!r.hasChildren();if(n.segments.length===s.length){if(!Yu(n.segments,s))return!1;for(const t in r.children){if(!n.children[t])return!1;if(!e(n.children[t],r.children[t]))return!1}return!0}{const e=s.slice(0,n.segments.length),l=s.slice(n.segments.length);return!!Yu(n.segments,e)&&!!n.children.primary&&t(n.children.primary,r,l)}}(t,n,n.segments)}(e.root,t.root)}class Zu{constructor(e,t,n){this.root=e,this.queryParams=t,this.fragment=n}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=Du(this.queryParams)),this._queryParamMap}toString(){return tc.serialize(this)}}class Qu{constructor(e,t){this.segments=e,this.children=t,this.parent=null,qu(t,(e,t)=>e.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return nc(this)}}class Ku{constructor(e,t){this.path=e,this.parameters=t}get parameterMap(){return this._parameterMap||(this._parameterMap=Du(this.parameters)),this._parameterMap}toString(){return ac(this)}}function Yu(e,t){return e.length===t.length&&e.every((e,n)=>e.path===t[n].path)}function Ju(e,t){let n=[];return qu(e.children,(e,r)=>{"primary"===r&&(n=n.concat(t(e,r)))}),qu(e.children,(e,r)=>{"primary"!==r&&(n=n.concat(t(e,r)))}),n}class Xu{}class ec{parse(e){const t=new pc(e);return new Zu(t.parseRootSegment(),t.parseQueryParams(),t.parseFragment())}serialize(e){var t;return`${`/${function e(t,n){if(!t.hasChildren())return nc(t);if(n){const n=t.children.primary?e(t.children.primary,!1):"",r=[];return qu(t.children,(t,n)=>{"primary"!==n&&r.push(`${n}:${e(t,!1)}`)}),r.length>0?`${n}(${r.join("//")})`:n}{const n=Ju(t,(n,r)=>"primary"===r?[e(t.children.primary,!1)]:[`${r}:${e(n,!1)}`]);return`${nc(t)}/(${n.join("//")})`}}(e.root,!0)}`}${function(e){const t=Object.keys(e).map(t=>{const n=e[t];return Array.isArray(n)?n.map(e=>`${sc(t)}=${sc(e)}`).join("&"):`${sc(t)}=${sc(n)}`});return t.length?`?${t.join("&")}`:""}(e.queryParams)}${"string"==typeof e.fragment?`#${t=e.fragment,encodeURI(t)}`:""}`}}const tc=new ec;function nc(e){return e.segments.map(e=>ac(e)).join("/")}function rc(e){return encodeURIComponent(e).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function sc(e){return rc(e).replace(/%3B/gi,";")}function lc(e){return rc(e).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function ic(e){return decodeURIComponent(e)}function oc(e){return ic(e.replace(/\+/g,"%20"))}function ac(e){return`${lc(e.path)}${t=e.parameters,Object.keys(t).map(e=>`;${lc(e)}=${lc(t[e])}`).join("")}`;var t}const uc=/^[^\/()?;=#]+/;function cc(e){const t=e.match(uc);return t?t[0]:""}const hc=/^[^=?&#]+/,dc=/^[^?&#]+/;class pc{constructor(e){this.url=e,this.remaining=e}parseRootSegment(){return this.consumeOptional("/"),""===this.remaining||this.peekStartsWith("?")||this.peekStartsWith("#")?new Qu([],{}):new Qu([],this.parseChildren())}parseQueryParams(){const e={};if(this.consumeOptional("?"))do{this.parseQueryParam(e)}while(this.consumeOptional("&"));return e}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(""===this.remaining)return{};this.consumeOptional("/");const e=[];for(this.peekStartsWith("(")||e.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),e.push(this.parseSegment());let t={};this.peekStartsWith("/(")&&(this.capture("/"),t=this.parseParens(!0));let n={};return this.peekStartsWith("(")&&(n=this.parseParens(!1)),(e.length>0||Object.keys(t).length>0)&&(n.primary=new Qu(e,t)),n}parseSegment(){const e=cc(this.remaining);if(""===e&&this.peekStartsWith(";"))throw new Error(`Empty path url segment cannot have parameters: '${this.remaining}'.`);return this.capture(e),new Ku(ic(e),this.parseMatrixParams())}parseMatrixParams(){const e={};for(;this.consumeOptional(";");)this.parseParam(e);return e}parseParam(e){const t=cc(this.remaining);if(!t)return;this.capture(t);let n="";if(this.consumeOptional("=")){const e=cc(this.remaining);e&&(n=e,this.capture(n))}e[ic(t)]=ic(n)}parseQueryParam(e){const t=function(e){const t=e.match(hc);return t?t[0]:""}(this.remaining);if(!t)return;this.capture(t);let n="";if(this.consumeOptional("=")){const e=function(e){const t=e.match(dc);return t?t[0]:""}(this.remaining);e&&(n=e,this.capture(n))}const r=oc(t),s=oc(n);if(e.hasOwnProperty(r)){let t=e[r];Array.isArray(t)||(t=[t],e[r]=t),t.push(s)}else e[r]=s}parseParens(e){const t={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){const n=cc(this.remaining),r=this.remaining[n.length];if("/"!==r&&")"!==r&&";"!==r)throw new Error(`Cannot parse url '${this.url}'`);let s=void 0;n.indexOf(":")>-1?(s=n.substr(0,n.indexOf(":")),this.capture(s),this.capture(":")):e&&(s="primary");const l=this.parseChildren();t[s]=1===Object.keys(l).length?l.primary:new Qu([],l),this.consumeOptional("//")}return t}peekStartsWith(e){return this.remaining.startsWith(e)}consumeOptional(e){return!!this.peekStartsWith(e)&&(this.remaining=this.remaining.substring(e.length),!0)}capture(e){if(!this.consumeOptional(e))throw new Error(`Expected "${e}".`)}}class gc{constructor(e){this._root=e}get root(){return this._root.value}parent(e){const t=this.pathFromRoot(e);return t.length>1?t[t.length-2]:null}children(e){const t=fc(e,this._root);return t?t.children.map(e=>e.value):[]}firstChild(e){const t=fc(e,this._root);return t&&t.children.length>0?t.children[0].value:null}siblings(e){const t=mc(e,this._root);return t.length<2?[]:t[t.length-2].children.map(e=>e.value).filter(t=>t!==e)}pathFromRoot(e){return mc(e,this._root).map(e=>e.value)}}function fc(e,t){if(e===t.value)return t;for(const n of t.children){const t=fc(e,n);if(t)return t}return null}function mc(e,t){if(e===t.value)return[t];for(const n of t.children){const r=mc(e,n);if(r.length)return r.unshift(t),r}return[]}class vc{constructor(e,t){this.value=e,this.children=t}toString(){return`TreeNode(${this.value})`}}function yc(e){const t={};return e&&e.children.forEach(e=>t[e.value.outlet]=e),t}class _c extends gc{constructor(e,t){super(e),this.snapshot=t,Ec(this,e)}toString(){return this.snapshot.toString()}}function wc(e,t){const n=function(e,t){const n=new xc([],{},{},"",{},"primary",t,null,e.root,-1,{});return new Sc("",new vc(n,[]))}(e,t),r=new bo([new Ku("",{})]),s=new bo({}),l=new bo({}),i=new bo({}),o=new bo(""),a=new bc(r,s,i,o,l,"primary",t,n.root);return a.snapshot=n.root,new _c(new vc(a,[]),n)}class bc{constructor(e,t,n,r,s,l,i,o){this.url=e,this.params=t,this.queryParams=n,this.fragment=r,this.data=s,this.outlet=l,this.component=i,this._futureSnapshot=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._paramMap=this.params.pipe(H(e=>Du(e)))),this._paramMap}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=this.queryParams.pipe(H(e=>Du(e)))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}}function Cc(e,t="emptyOnly"){const n=e.pathFromRoot;let r=0;if("always"!==t)for(r=n.length-1;r>=1;){const e=n[r],t=n[r-1];if(e.routeConfig&&""===e.routeConfig.path)r--;else{if(t.component)break;r--}}return function(e){return e.reduce((e,t)=>({params:Object.assign({},e.params,t.params),data:Object.assign({},e.data,t.data),resolve:Object.assign({},e.resolve,t._resolvedData)}),{params:{},data:{},resolve:{}})}(n.slice(r))}class xc{constructor(e,t,n,r,s,l,i,o,a,u,c){this.url=e,this.params=t,this.queryParams=n,this.fragment=r,this.data=s,this.outlet=l,this.component=i,this.routeConfig=o,this._urlSegment=a,this._lastPathIndex=u,this._resolve=c}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._paramMap=Du(this.params)),this._paramMap}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=Du(this.queryParams)),this._queryParamMap}toString(){return`Route(url:'${this.url.map(e=>e.toString()).join("/")}', path:'${this.routeConfig?this.routeConfig.path:""}')`}}class Sc extends gc{constructor(e,t){super(t),this.url=e,Ec(this,t)}toString(){return Tc(this._root)}}function Ec(e,t){t.value._routerState=e,t.children.forEach(t=>Ec(e,t))}function Tc(e){const t=e.children.length>0?` { ${e.children.map(Tc).join(", ")} } `:"";return`${e.value}${t}`}function kc(e){if(e.snapshot){const t=e.snapshot,n=e._futureSnapshot;e.snapshot=n,Hu(t.queryParams,n.queryParams)||e.queryParams.next(n.queryParams),t.fragment!==n.fragment&&e.fragment.next(n.fragment),Hu(t.params,n.params)||e.params.next(n.params),function(e,t){if(e.length!==t.length)return!1;for(let n=0;n<e.length;++n)if(!Hu(e[n],t[n]))return!1;return!0}(t.url,n.url)||e.url.next(n.url),Hu(t.data,n.data)||e.data.next(n.data)}else e.snapshot=e._futureSnapshot,e.data.next(e._futureSnapshot.data)}function Ac(e,t){var n,r;return Hu(e.params,t.params)&&Yu(n=e.url,r=t.url)&&n.every((e,t)=>Hu(e.parameters,r[t].parameters))&&!(!e.parent!=!t.parent)&&(!e.parent||Ac(e.parent,t.parent))}function Ic(e){return"object"==typeof e&&null!=e&&!e.outlets&&!e.segmentPath}function Pc(e,t,n,r,s){let l={};return r&&qu(r,(e,t)=>{l[t]=Array.isArray(e)?e.map(e=>`${e}`):`${e}`}),new Zu(n.root===e?t:function e(t,n,r){const s={};return qu(t.children,(t,l)=>{s[l]=t===n?r:e(t,n,r)}),new Qu(t.segments,s)}(n.root,e,t),l,s)}class Oc{constructor(e,t,n){if(this.isAbsolute=e,this.numberOfDoubleDots=t,this.commands=n,e&&n.length>0&&Ic(n[0]))throw new Error("Root segment cannot have matrix parameters");const r=n.find(e=>"object"==typeof e&&null!=e&&e.outlets);if(r&&r!==Bu(n))throw new Error("{outlets:{}} has to be the last command")}toRoot(){return this.isAbsolute&&1===this.commands.length&&"/"==this.commands[0]}}class Rc{constructor(e,t,n){this.segmentGroup=e,this.processChildren=t,this.index=n}}function Nc(e){return"object"==typeof e&&null!=e&&e.outlets?e.outlets.primary:`${e}`}function Dc(e,t,n){if(e||(e=new Qu([],{})),0===e.segments.length&&e.hasChildren())return Vc(e,t,n);const r=function(e,t,n){let r=0,s=t;const l={match:!1,pathIndex:0,commandIndex:0};for(;s<e.segments.length;){if(r>=n.length)return l;const t=e.segments[s],i=Nc(n[r]),o=r<n.length-1?n[r+1]:null;if(s>0&&void 0===i)break;if(i&&o&&"object"==typeof o&&void 0===o.outlets){if(!Fc(i,o,t))return l;r+=2}else{if(!Fc(i,{},t))return l;r++}s++}return{match:!0,pathIndex:s,commandIndex:r}}(e,t,n),s=n.slice(r.commandIndex);if(r.match&&r.pathIndex<e.segments.length){const t=new Qu(e.segments.slice(0,r.pathIndex),{});return t.children.primary=new Qu(e.segments.slice(r.pathIndex),e.children),Vc(t,0,s)}return r.match&&0===s.length?new Qu(e.segments,{}):r.match&&!e.hasChildren()?Mc(e,t,n):r.match?Vc(e,0,s):Mc(e,t,n)}function Vc(e,t,n){if(0===n.length)return new Qu(e.segments,{});{const r=function(e){return"object"!=typeof e[0]?{primary:e}:void 0===e[0].outlets?{primary:e}:e[0].outlets}(n),s={};return qu(r,(n,r)=>{null!==n&&(s[r]=Dc(e.children[r],t,n))}),qu(e.children,(e,t)=>{void 0===r[t]&&(s[t]=e)}),new Qu(e.segments,s)}}function Mc(e,t,n){const r=e.segments.slice(0,t);let s=0;for(;s<n.length;){if("object"==typeof n[s]&&void 0!==n[s].outlets){const e=Uc(n[s].outlets);return new Qu(r,e)}if(0===s&&Ic(n[0])){r.push(new Ku(e.segments[t].path,n[0])),s++;continue}const l=Nc(n[s]),i=s<n.length-1?n[s+1]:null;l&&i&&Ic(i)?(r.push(new Ku(l,jc(i))),s+=2):(r.push(new Ku(l,{})),s++)}return new Qu(r,{})}function Uc(e){const t={};return qu(e,(e,n)=>{null!==e&&(t[n]=Mc(new Qu([],{}),0,e))}),t}function jc(e){const t={};return qu(e,(e,n)=>t[n]=`${e}`),t}function Fc(e,t,n){return e==n.path&&Hu(t,n.parameters)}class Lc{constructor(e,t,n,r){this.routeReuseStrategy=e,this.futureState=t,this.currState=n,this.forwardEvent=r}activate(e){const t=this.futureState._root,n=this.currState?this.currState._root:null;this.deactivateChildRoutes(t,n,e),kc(this.futureState.root),this.activateChildRoutes(t,n,e)}deactivateChildRoutes(e,t,n){const r=yc(t);e.children.forEach(e=>{const t=e.value.outlet;this.deactivateRoutes(e,r[t],n),delete r[t]}),qu(r,(e,t)=>{this.deactivateRouteAndItsChildren(e,n)})}deactivateRoutes(e,t,n){const r=e.value,s=t?t.value:null;if(r===s)if(r.component){const s=n.getContext(r.outlet);s&&this.deactivateChildRoutes(e,t,s.children)}else this.deactivateChildRoutes(e,t,n);else s&&this.deactivateRouteAndItsChildren(t,n)}deactivateRouteAndItsChildren(e,t){this.routeReuseStrategy.shouldDetach(e.value.snapshot)?this.detachAndStoreRouteSubtree(e,t):this.deactivateRouteAndOutlet(e,t)}detachAndStoreRouteSubtree(e,t){const n=t.getContext(e.value.outlet);if(n&&n.outlet){const t=n.outlet.detach(),r=n.children.onOutletDeactivated();this.routeReuseStrategy.store(e.value.snapshot,{componentRef:t,route:e,contexts:r})}}deactivateRouteAndOutlet(e,t){const n=t.getContext(e.value.outlet);if(n){const r=yc(e),s=e.value.component?n.children:t;qu(r,(e,t)=>this.deactivateRouteAndItsChildren(e,s)),n.outlet&&(n.outlet.deactivate(),n.children.onOutletDeactivated())}}activateChildRoutes(e,t,n){const r=yc(t);e.children.forEach(e=>{this.activateRoutes(e,r[e.value.outlet],n),this.forwardEvent(new Pu(e.value.snapshot))}),e.children.length&&this.forwardEvent(new Au(e.value.snapshot))}activateRoutes(e,t,n){const r=e.value,s=t?t.value:null;if(kc(r),r===s)if(r.component){const s=n.getOrCreateContext(r.outlet);this.activateChildRoutes(e,t,s.children)}else this.activateChildRoutes(e,t,n);else if(r.component){const t=n.getOrCreateContext(r.outlet);if(this.routeReuseStrategy.shouldAttach(r.snapshot)){const e=this.routeReuseStrategy.retrieve(r.snapshot);this.routeReuseStrategy.store(r.snapshot,null),t.children.onOutletReAttached(e.contexts),t.attachRef=e.componentRef,t.route=e.route.value,t.outlet&&t.outlet.attach(e.componentRef,e.route.value),$c(e.route)}else{const n=function(e){for(let t=e.parent;t;t=t.parent){const e=t.routeConfig;if(e&&e._loadedConfig)return e._loadedConfig;if(e&&e.component)return null}return null}(r.snapshot),s=n?n.module.componentFactoryResolver:null;t.attachRef=null,t.route=r,t.resolver=s,t.outlet&&t.outlet.activateWith(r,s),this.activateChildRoutes(e,null,t.children)}}else this.activateChildRoutes(e,null,n)}}function $c(e){kc(e.value),e.children.forEach($c)}function Hc(e){return"function"==typeof e}function zc(e){return e instanceof Zu}class Bc{constructor(e){this.segmentGroup=e||null}}class qc{constructor(e){this.urlTree=e}}function Gc(e){return new b(t=>t.error(new Bc(e)))}function Wc(e){return new b(t=>t.error(new qc(e)))}function Zc(e){return new b(t=>t.error(new Error(`Only absolute redirects can have named outlets. redirectTo: '${e}'`)))}class Qc{constructor(e,t,n,r,s){this.configLoader=t,this.urlSerializer=n,this.urlTree=r,this.config=s,this.allowRedirects=!0,this.ngModule=e.get(De)}apply(){return this.expandSegmentGroup(this.ngModule,this.config,this.urlTree.root,"primary").pipe(H(e=>this.createUrlTree(e,this.urlTree.queryParams,this.urlTree.fragment))).pipe(Go(e=>{if(e instanceof qc)return this.allowRedirects=!1,this.match(e.urlTree);if(e instanceof Bc)throw this.noMatchError(e);throw e}))}match(e){return this.expandSegmentGroup(this.ngModule,this.config,e.root,"primary").pipe(H(t=>this.createUrlTree(t,e.queryParams,e.fragment))).pipe(Go(e=>{if(e instanceof Bc)throw this.noMatchError(e);throw e}))}noMatchError(e){return new Error(`Cannot match any routes. URL Segment: '${e.segmentGroup}'`)}createUrlTree(e,t,n){const r=e.segments.length>0?new Qu([],{primary:e}):e;return new Zu(r,t,n)}expandSegmentGroup(e,t,n,r){return 0===n.segments.length&&n.hasChildren()?this.expandChildren(e,t,n).pipe(H(e=>new Qu([],e))):this.expandSegment(e,n,t,n.segments,r,!0)}expandChildren(e,t,n){return function(e,t){if(0===Object.keys(e).length)return wo({});const n=[],r=[],s={};return qu(e,(e,l)=>{const i=t(l,e).pipe(H(e=>s[l]=e));"primary"===l?n.push(i):r.push(i)}),wo.apply(null,n.concat(r)).pipe(Ao(),qo(),H(()=>s))}(n.children,(n,r)=>this.expandSegmentGroup(e,t,r,n))}expandSegment(e,t,n,r,s,l){return wo(...n).pipe(H(i=>this.expandSegmentAgainstRoute(e,t,n,i,r,s,l).pipe(Go(e=>{if(e instanceof Bc)return wo(null);throw e}))),Ao(),Jo(e=>!!e),Go((e,n)=>{if(e instanceof xo||"EmptyError"===e.name){if(this.noLeftoversInUrl(t,r,s))return wo(new Qu([],{}));throw new Bc(t)}throw e}))}noLeftoversInUrl(e,t,n){return 0===t.length&&!e.children[n]}expandSegmentAgainstRoute(e,t,n,r,s,l,i){return Xc(r)!==l?Gc(t):void 0===r.redirectTo?this.matchSegmentAgainstRoute(e,t,r,s):i&&this.allowRedirects?this.expandSegmentAgainstRouteUsingRedirect(e,t,n,r,s,l):Gc(t)}expandSegmentAgainstRouteUsingRedirect(e,t,n,r,s,l){return"**"===r.path?this.expandWildCardWithParamsAgainstRouteUsingRedirect(e,n,r,l):this.expandRegularSegmentAgainstRouteUsingRedirect(e,t,n,r,s,l)}expandWildCardWithParamsAgainstRouteUsingRedirect(e,t,n,r){const s=this.applyRedirectCommands([],n.redirectTo,{});return n.redirectTo.startsWith("/")?Wc(s):this.lineralizeSegments(n,s).pipe(W(n=>{const s=new Qu(n,{});return this.expandSegment(e,s,t,n,r,!1)}))}expandRegularSegmentAgainstRouteUsingRedirect(e,t,n,r,s,l){const{matched:i,consumedSegments:o,lastChild:a,positionalParamSegments:u}=Kc(t,r,s);if(!i)return Gc(t);const c=this.applyRedirectCommands(o,r.redirectTo,u);return r.redirectTo.startsWith("/")?Wc(c):this.lineralizeSegments(r,c).pipe(W(r=>this.expandSegment(e,t,n,r.concat(s.slice(a)),l,!1)))}matchSegmentAgainstRoute(e,t,n,r){if("**"===n.path)return n.loadChildren?this.configLoader.load(e.injector,n).pipe(H(e=>(n._loadedConfig=e,new Qu(r,{})))):wo(new Qu(r,{}));const{matched:s,consumedSegments:l,lastChild:i}=Kc(t,n,r);if(!s)return Gc(t);const o=r.slice(i);return this.getChildConfig(e,n,r).pipe(W(e=>{const n=e.module,r=e.routes,{segmentGroup:s,slicedSegments:i}=function(e,t,n,r){return n.length>0&&function(e,t,n){return n.some(n=>Jc(e,t,n)&&"primary"!==Xc(n))}(e,n,r)?{segmentGroup:Yc(new Qu(t,function(e,t){const n={};n.primary=t;for(const r of e)""===r.path&&"primary"!==Xc(r)&&(n[Xc(r)]=new Qu([],{}));return n}(r,new Qu(n,e.children)))),slicedSegments:[]}:0===n.length&&function(e,t,n){return n.some(n=>Jc(e,t,n))}(e,n,r)?{segmentGroup:Yc(new Qu(e.segments,function(e,t,n,r){const s={};for(const l of n)Jc(e,t,l)&&!r[Xc(l)]&&(s[Xc(l)]=new Qu([],{}));return Object.assign({},r,s)}(e,n,r,e.children))),slicedSegments:n}:{segmentGroup:e,slicedSegments:n}}(t,l,o,r);return 0===i.length&&s.hasChildren()?this.expandChildren(n,r,s).pipe(H(e=>new Qu(l,e))):0===r.length&&0===i.length?wo(new Qu(l,{})):this.expandSegment(n,s,r,i,"primary",!0).pipe(H(e=>new Qu(l.concat(e.segments),e.children)))}))}getChildConfig(e,t,n){return t.children?wo(new Uu(t.children,e)):t.loadChildren?void 0!==t._loadedConfig?wo(t._loadedConfig):function(e,t,n){const r=t.canLoad;return r&&0!==r.length?G(r).pipe(H(r=>{const s=e.get(r);let l;if(function(e){return e&&Hc(e.canLoad)}(s))l=s.canLoad(t,n);else{if(!Hc(s))throw new Error("Invalid CanLoad guard");l=s(t,n)}return Gu(l)})).pipe(Ao(),(s=e=>!0===e,e=>e.lift(new Xo(s,void 0,e)))):wo(!0);var s}(e.injector,t,n).pipe(W(n=>n?this.configLoader.load(e.injector,t).pipe(H(e=>(t._loadedConfig=e,e))):function(e){return new b(t=>t.error(Vu(`Cannot load children because the guard of the route "path: '${e.path}'" returned false`)))}(t))):wo(new Uu([],e))}lineralizeSegments(e,t){let n=[],r=t.root;for(;;){if(n=n.concat(r.segments),0===r.numberOfChildren)return wo(n);if(r.numberOfChildren>1||!r.children.primary)return Zc(e.redirectTo);r=r.children.primary}}applyRedirectCommands(e,t,n){return this.applyRedirectCreatreUrlTree(t,this.urlSerializer.parse(t),e,n)}applyRedirectCreatreUrlTree(e,t,n,r){const s=this.createSegmentGroup(e,t.root,n,r);return new Zu(s,this.createQueryParams(t.queryParams,this.urlTree.queryParams),t.fragment)}createQueryParams(e,t){const n={};return qu(e,(e,r)=>{if("string"==typeof e&&e.startsWith(":")){const s=e.substring(1);n[r]=t[s]}else n[r]=e}),n}createSegmentGroup(e,t,n,r){const s=this.createSegments(e,t.segments,n,r);let l={};return qu(t.children,(t,s)=>{l[s]=this.createSegmentGroup(e,t,n,r)}),new Qu(s,l)}createSegments(e,t,n,r){return t.map(t=>t.path.startsWith(":")?this.findPosParam(e,t,r):this.findOrReturn(t,n))}findPosParam(e,t,n){const r=n[t.path.substring(1)];if(!r)throw new Error(`Cannot redirect to '${e}'. Cannot find '${t.path}'.`);return r}findOrReturn(e,t){let n=0;for(const r of t){if(r.path===e.path)return t.splice(n),r;n++}return e}}function Kc(e,t,n){if(""===t.path)return"full"===t.pathMatch&&(e.hasChildren()||n.length>0)?{matched:!1,consumedSegments:[],lastChild:0,positionalParamSegments:{}}:{matched:!0,consumedSegments:[],lastChild:0,positionalParamSegments:{}};const r=(t.matcher||Mu)(n,e,t);return r?{matched:!0,consumedSegments:r.consumed,lastChild:r.consumed.length,positionalParamSegments:r.posParams}:{matched:!1,consumedSegments:[],lastChild:0,positionalParamSegments:{}}}function Yc(e){if(1===e.numberOfChildren&&e.children.primary){const t=e.children.primary;return new Qu(e.segments.concat(t.segments),t.children)}return e}function Jc(e,t,n){return(!(e.hasChildren()||t.length>0)||"full"!==n.pathMatch)&&""===n.path&&void 0!==n.redirectTo}function Xc(e){return e.outlet||"primary"}class eh{constructor(e){this.path=e,this.route=this.path[this.path.length-1]}}class th{constructor(e,t){this.component=e,this.route=t}}function nh(e,t,n){const r=e._root;return function e(t,n,r,s,l={canDeactivateChecks:[],canActivateChecks:[]}){const i=yc(n);return t.children.forEach(t=>{!function(t,n,r,s,l={canDeactivateChecks:[],canActivateChecks:[]}){const i=t.value,o=n?n.value:null,a=r?r.getContext(t.value.outlet):null;if(o&&i.routeConfig===o.routeConfig){const u=function(e,t,n){if("function"==typeof n)return n(e,t);switch(n){case"pathParamsChange":return!Yu(e.url,t.url);case"pathParamsOrQueryParamsChange":return!Yu(e.url,t.url)||!Hu(e.queryParams,t.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!Ac(e,t)||!Hu(e.queryParams,t.queryParams);case"paramsChange":default:return!Ac(e,t)}}(o,i,i.routeConfig.runGuardsAndResolvers);u?l.canActivateChecks.push(new eh(s)):(i.data=o.data,i._resolvedData=o._resolvedData),e(t,n,i.component?a?a.children:null:r,s,l),u&&l.canDeactivateChecks.push(new th(a&&a.outlet&&a.outlet.component||null,o))}else o&&sh(n,a,l),l.canActivateChecks.push(new eh(s)),e(t,null,i.component?a?a.children:null:r,s,l)}(t,i[t.value.outlet],r,s.concat([t.value]),l),delete i[t.value.outlet]}),qu(i,(e,t)=>sh(e,r.getContext(t),l)),l}(r,t?t._root:null,n,[r.value])}function rh(e,t,n){const r=function(e){if(!e)return null;for(let t=e.parent;t;t=t.parent){const e=t.routeConfig;if(e&&e._loadedConfig)return e._loadedConfig}return null}(t);return(r?r.module.injector:n).get(e)}function sh(e,t,n){const r=yc(e),s=e.value;qu(r,(e,r)=>{sh(e,s.component?t?t.children.getContext(r):null:t,n)}),n.canDeactivateChecks.push(new th(s.component&&t&&t.outlet&&t.outlet.isActivated?t.outlet.component:null,s))}const lh=Symbol("INITIAL_VALUE");function ih(){return ta(e=>function(...e){let t=null,n=null;return I(e[e.length-1])&&(n=e.pop()),"function"==typeof e[e.length-1]&&(t=e.pop()),1===e.length&&a(e[0])&&(e=e[0]),q(e,n).lift(new Eo(t))}(...e.map(e=>e.pipe(Qo(1),function(...e){return t=>{let n=e[e.length-1];I(n)?e.pop():n=null;const r=e.length;return function(...e){return Ao()(wo(...e))}(1!==r||n?r>0?q(e,n):yo(n):_o(e[0]),t)}}(lh)))).pipe(sa((e,t)=>{let n=!1;return t.reduce((e,r,s)=>{if(e!==lh)return e;if(r===lh&&(n=!0),!n){if(!1===r)return r;if(s===t.length-1||zc(r))return r}return e},e)},lh),Io(e=>e!==lh),H(e=>zc(e)?e:!0===e),Qo(1)))}function oh(e,t){return null!==e&&t&&t(new Iu(e)),wo(!0)}function ah(e,t){return null!==e&&t&&t(new ku(e)),wo(!0)}function uh(e,t,n){const r=t.routeConfig?t.routeConfig.canActivate:null;return r&&0!==r.length?wo(r.map(r=>ko(()=>{const s=rh(r,t,n);let l;if(function(e){return e&&Hc(e.canActivate)}(s))l=Gu(s.canActivate(t,e));else{if(!Hc(s))throw new Error("Invalid CanActivate guard");l=Gu(s(t,e))}return l.pipe(Jo())}))).pipe(ih()):wo(!0)}function ch(e,t,n){const r=t[t.length-1],s=t.slice(0,t.length-1).reverse().map(e=>function(e){const t=e.routeConfig?e.routeConfig.canActivateChild:null;return t&&0!==t.length?{node:e,guards:t}:null}(e)).filter(e=>null!==e).map(t=>ko(()=>wo(t.guards.map(s=>{const l=rh(s,t.node,n);let i;if(function(e){return e&&Hc(e.canActivateChild)}(l))i=Gu(l.canActivateChild(r,e));else{if(!Hc(l))throw new Error("Invalid CanActivateChild guard");i=Gu(l(r,e))}return i.pipe(Jo())})).pipe(ih())));return wo(s).pipe(ih())}class hh{}class dh{constructor(e,t,n,r,s,l){this.rootComponentType=e,this.config=t,this.urlTree=n,this.url=r,this.paramsInheritanceStrategy=s,this.relativeLinkResolution=l}recognize(){try{const e=fh(this.urlTree.root,[],[],this.config,this.relativeLinkResolution).segmentGroup,t=this.processSegmentGroup(this.config,e,"primary"),n=new xc([],Object.freeze({}),Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,{},"primary",this.rootComponentType,null,this.urlTree.root,-1,{}),r=new vc(n,t),s=new Sc(this.url,r);return this.inheritParamsAndData(s._root),wo(s)}catch(e){return new b(t=>t.error(e))}}inheritParamsAndData(e){const t=e.value,n=Cc(t,this.paramsInheritanceStrategy);t.params=Object.freeze(n.params),t.data=Object.freeze(n.data),e.children.forEach(e=>this.inheritParamsAndData(e))}processSegmentGroup(e,t,n){return 0===t.segments.length&&t.hasChildren()?this.processChildren(e,t):this.processSegment(e,t,t.segments,n)}processChildren(e,t){const n=Ju(t,(t,n)=>this.processSegmentGroup(e,t,n));return function(e){const t={};e.forEach(e=>{const n=t[e.value.outlet];if(n){const t=n.url.map(e=>e.toString()).join("/"),r=e.value.url.map(e=>e.toString()).join("/");throw new Error(`Two segments cannot have the same outlet name: '${t}' and '${r}'.`)}t[e.value.outlet]=e.value})}(n),n.sort((e,t)=>"primary"===e.value.outlet?-1:"primary"===t.value.outlet?1:e.value.outlet.localeCompare(t.value.outlet)),n}processSegment(e,t,n,r){for(const l of e)try{return this.processSegmentAgainstRoute(l,t,n,r)}catch(s){if(!(s instanceof hh))throw s}if(this.noLeftoversInUrl(t,n,r))return[];throw new hh}noLeftoversInUrl(e,t,n){return 0===t.length&&!e.children[n]}processSegmentAgainstRoute(e,t,n,r){if(e.redirectTo)throw new hh;if((e.outlet||"primary")!==r)throw new hh;let s,l=[],i=[];if("**"===e.path){const l=n.length>0?Bu(n).parameters:{};s=new xc(n,l,Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,yh(e),r,e.component,e,ph(t),gh(t)+n.length,_h(e))}else{const o=function(e,t,n){if(""===t.path){if("full"===t.pathMatch&&(e.hasChildren()||n.length>0))throw new hh;return{consumedSegments:[],lastChild:0,parameters:{}}}const r=(t.matcher||Mu)(n,e,t);if(!r)throw new hh;const s={};qu(r.posParams,(e,t)=>{s[t]=e.path});const l=r.consumed.length>0?Object.assign({},s,r.consumed[r.consumed.length-1].parameters):s;return{consumedSegments:r.consumed,lastChild:r.consumed.length,parameters:l}}(t,e,n);l=o.consumedSegments,i=n.slice(o.lastChild),s=new xc(l,o.parameters,Object.freeze(Object.assign({},this.urlTree.queryParams)),this.urlTree.fragment,yh(e),r,e.component,e,ph(t),gh(t)+l.length,_h(e))}const o=function(e){return e.children?e.children:e.loadChildren?e._loadedConfig.routes:[]}(e),{segmentGroup:a,slicedSegments:u}=fh(t,l,i,o,this.relativeLinkResolution);if(0===u.length&&a.hasChildren()){const e=this.processChildren(o,a);return[new vc(s,e)]}if(0===o.length&&0===u.length)return[new vc(s,[])];const c=this.processSegment(o,a,u,"primary");return[new vc(s,c)]}}function ph(e){let t=e;for(;t._sourceSegment;)t=t._sourceSegment;return t}function gh(e){let t=e,n=t._segmentIndexShift?t._segmentIndexShift:0;for(;t._sourceSegment;)t=t._sourceSegment,n+=t._segmentIndexShift?t._segmentIndexShift:0;return n-1}function fh(e,t,n,r,s){if(n.length>0&&function(e,t,n){return n.some(n=>mh(e,t,n)&&"primary"!==vh(n))}(e,n,r)){const s=new Qu(t,function(e,t,n,r){const s={};s.primary=r,r._sourceSegment=e,r._segmentIndexShift=t.length;for(const l of n)if(""===l.path&&"primary"!==vh(l)){const n=new Qu([],{});n._sourceSegment=e,n._segmentIndexShift=t.length,s[vh(l)]=n}return s}(e,t,r,new Qu(n,e.children)));return s._sourceSegment=e,s._segmentIndexShift=t.length,{segmentGroup:s,slicedSegments:[]}}if(0===n.length&&function(e,t,n){return n.some(n=>mh(e,t,n))}(e,n,r)){const l=new Qu(e.segments,function(e,t,n,r,s,l){const i={};for(const o of r)if(mh(e,n,o)&&!s[vh(o)]){const n=new Qu([],{});n._sourceSegment=e,n._segmentIndexShift="legacy"===l?e.segments.length:t.length,i[vh(o)]=n}return Object.assign({},s,i)}(e,t,n,r,e.children,s));return l._sourceSegment=e,l._segmentIndexShift=t.length,{segmentGroup:l,slicedSegments:n}}const l=new Qu(e.segments,e.children);return l._sourceSegment=e,l._segmentIndexShift=t.length,{segmentGroup:l,slicedSegments:n}}function mh(e,t,n){return(!(e.hasChildren()||t.length>0)||"full"!==n.pathMatch)&&""===n.path&&void 0===n.redirectTo}function vh(e){return e.outlet||"primary"}function yh(e){return e.data||{}}function _h(e){return e.resolve||{}}function wh(e,t,n,r){const s=rh(e,t,r);return Gu(s.resolve?s.resolve(t,n):s(t,n))}function bh(e){return function(t){return t.pipe(ta(t=>{const n=e(t);return n?G(n).pipe(H(()=>t)):G([t])}))}}class Ch{}class xh{shouldDetach(e){return!1}store(e,t){}shouldAttach(e){return!1}retrieve(e){return null}shouldReuseRoute(e,t){return e.routeConfig===t.routeConfig}}const Sh=new Se("ROUTES");class Eh{constructor(e,t,n,r){this.loader=e,this.compiler=t,this.onLoadStartListener=n,this.onLoadEndListener=r}load(e,t){return this.onLoadStartListener&&this.onLoadStartListener(t),this.loadModuleFactory(t.loadChildren).pipe(H(n=>{this.onLoadEndListener&&this.onLoadEndListener(t);const r=n.create(e);return new Uu(zu(r.injector.get(Sh)).map($u),r)}))}loadModuleFactory(e){return"string"==typeof e?G(this.loader.load(e)):Gu(e()).pipe(W(e=>e instanceof Ve?wo(e):G(this.compiler.compileModuleAsync(e))))}}class Th{}class kh{shouldProcessUrl(e){return!0}extract(e){return e}merge(e,t){return e}}function Ah(e){throw e}function Ih(e,t,n){return t.parse("/")}function Ph(e,t){return wo(null)}class Oh{constructor(e,t,n,r,s,l,i,o){this.rootComponentType=e,this.urlSerializer=t,this.rootContexts=n,this.location=r,this.config=o,this.lastSuccessfulNavigation=null,this.currentNavigation=null,this.navigationId=0,this.isNgZoneEnabled=!1,this.events=new k,this.errorHandler=Ah,this.malformedUriErrorHandler=Ih,this.navigated=!1,this.lastSuccessfulId=-1,this.hooks={beforePreactivation:Ph,afterPreactivation:Ph},this.urlHandlingStrategy=new kh,this.routeReuseStrategy=new xh,this.onSameUrlNavigation="ignore",this.paramsInheritanceStrategy="emptyOnly",this.urlUpdateStrategy="deferred",this.relativeLinkResolution="legacy",this.ngModule=s.get(De),this.console=s.get(ks);const a=s.get(qs);this.isNgZoneEnabled=a instanceof qs,this.resetConfig(o),this.currentUrlTree=new Zu(new Qu([],{}),{},null),this.rawUrlTree=this.currentUrlTree,this.browserUrlTree=this.currentUrlTree,this.configLoader=new Eh(l,i,e=>this.triggerEvent(new Eu(e)),e=>this.triggerEvent(new Tu(e))),this.routerState=wc(this.currentUrlTree,this.rootComponentType),this.transitions=new bo({id:0,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,extractedUrl:this.urlHandlingStrategy.extract(this.currentUrlTree),urlAfterRedirects:this.urlHandlingStrategy.extract(this.currentUrlTree),rawUrl:this.currentUrlTree,extras:{},resolve:null,reject:null,promise:Promise.resolve(!0),source:"imperative",restoredState:null,currentSnapshot:this.routerState.snapshot,targetSnapshot:null,currentRouterState:this.routerState,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.navigations=this.setupNavigations(this.transitions),this.processNavigations()}setupNavigations(e){const t=this.events;return e.pipe(Io(e=>0!==e.id),H(e=>Object.assign({},e,{extractedUrl:this.urlHandlingStrategy.extract(e.rawUrl)})),ta(e=>{let n=!1,r=!1;return wo(e).pipe(Uo(e=>{this.currentNavigation={id:e.id,initialUrl:e.currentRawUrl,extractedUrl:e.extractedUrl,trigger:e.source,extras:e.extras,previousNavigation:this.lastSuccessfulNavigation?Object.assign({},this.lastSuccessfulNavigation,{previousNavigation:null}):null}}),ta(e=>{const n=!this.navigated||e.extractedUrl.toString()!==this.browserUrlTree.toString();if(("reload"===this.onSameUrlNavigation||n)&&this.urlHandlingStrategy.shouldProcessUrl(e.rawUrl))return wo(e).pipe(ta(e=>{const n=this.transitions.getValue();return t.next(new mu(e.id,this.serializeUrl(e.extractedUrl),e.source,e.restoredState)),n!==this.transitions.getValue()?vo:[e]}),ta(e=>Promise.resolve(e)),(r=this.ngModule.injector,s=this.configLoader,l=this.urlSerializer,i=this.config,function(e){return e.pipe(ta(e=>function(e,t,n,r,s){return new Qc(e,t,n,r,s).apply()}(r,s,l,e.extractedUrl,i).pipe(H(t=>Object.assign({},e,{urlAfterRedirects:t})))))}),Uo(e=>{this.currentNavigation=Object.assign({},this.currentNavigation,{finalUrl:e.urlAfterRedirects})}),function(e,t,n,r,s){return function(l){return l.pipe(W(l=>function(e,t,n,r,s="emptyOnly",l="legacy"){return new dh(e,t,n,r,s,l).recognize()}(e,t,l.urlAfterRedirects,n(l.urlAfterRedirects),r,s).pipe(H(e=>Object.assign({},l,{targetSnapshot:e})))))}}(this.rootComponentType,this.config,e=>this.serializeUrl(e),this.paramsInheritanceStrategy,this.relativeLinkResolution),Uo(e=>{"eager"===this.urlUpdateStrategy&&(e.extras.skipLocationChange||this.setBrowserUrl(e.urlAfterRedirects,!!e.extras.replaceUrl,e.id,e.extras.state),this.browserUrlTree=e.urlAfterRedirects)}),Uo(e=>{const n=new wu(e.id,this.serializeUrl(e.extractedUrl),this.serializeUrl(e.urlAfterRedirects),e.targetSnapshot);t.next(n)}));var r,s,l,i;if(n&&this.rawUrlTree&&this.urlHandlingStrategy.shouldProcessUrl(this.rawUrlTree)){const{id:n,extractedUrl:r,source:s,restoredState:l,extras:i}=e,o=new mu(n,this.serializeUrl(r),s,l);t.next(o);const a=wc(r,this.rootComponentType).snapshot;return wo(Object.assign({},e,{targetSnapshot:a,urlAfterRedirects:r,extras:Object.assign({},i,{skipLocationChange:!1,replaceUrl:!1})}))}return this.rawUrlTree=e.rawUrl,this.browserUrlTree=e.urlAfterRedirects,e.resolve(null),vo}),bh(e=>{const{targetSnapshot:t,id:n,extractedUrl:r,rawUrl:s,extras:{skipLocationChange:l,replaceUrl:i}}=e;return this.hooks.beforePreactivation(t,{navigationId:n,appliedUrlTree:r,rawUrlTree:s,skipLocationChange:!!l,replaceUrl:!!i})}),Uo(e=>{const t=new bu(e.id,this.serializeUrl(e.extractedUrl),this.serializeUrl(e.urlAfterRedirects),e.targetSnapshot);this.triggerEvent(t)}),H(e=>Object.assign({},e,{guards:nh(e.targetSnapshot,e.currentSnapshot,this.rootContexts)})),function(e,t){return function(n){return n.pipe(W(n=>{const{targetSnapshot:r,currentSnapshot:s,guards:{canActivateChecks:l,canDeactivateChecks:i}}=n;return 0===i.length&&0===l.length?wo(Object.assign({},n,{guardsResult:!0})):function(e,t,n,r){return G(e).pipe(W(e=>function(e,t,n,r,s){const l=t&&t.routeConfig?t.routeConfig.canDeactivate:null;return l&&0!==l.length?wo(l.map(l=>{const i=rh(l,t,s);let o;if(function(e){return e&&Hc(e.canDeactivate)}(i))o=Gu(i.canDeactivate(e,t,n,r));else{if(!Hc(i))throw new Error("Invalid CanDeactivate guard");o=Gu(i(e,t,n,r))}return o.pipe(Jo())})).pipe(ih()):wo(!0)}(e.component,e.route,n,t,r)),Jo(e=>!0!==e,!0))}(i,r,s,e).pipe(W(n=>n&&"boolean"==typeof n?function(e,t,n,r){return G(t).pipe(oa(t=>G([ah(t.route.parent,r),oh(t.route,r),ch(e,t.path,n),uh(e,t.route,n)]).pipe(Ao(),Jo(e=>!0!==e,!0))),Jo(e=>!0!==e,!0))}(r,l,e,t):wo(n)),H(e=>Object.assign({},n,{guardsResult:e})))}))}}(this.ngModule.injector,e=>this.triggerEvent(e)),Uo(e=>{if(zc(e.guardsResult)){const t=Vu(`Redirecting to "${this.serializeUrl(e.guardsResult)}"`);throw t.url=e.guardsResult,t}}),Uo(e=>{const t=new Cu(e.id,this.serializeUrl(e.extractedUrl),this.serializeUrl(e.urlAfterRedirects),e.targetSnapshot,!!e.guardsResult);this.triggerEvent(t)}),Io(e=>{if(!e.guardsResult){this.resetUrlToCurrentUrlTree();const n=new yu(e.id,this.serializeUrl(e.extractedUrl),"");return t.next(n),e.resolve(!1),!1}return!0}),bh(e=>{if(e.guards.canActivateChecks.length)return wo(e).pipe(Uo(e=>{const t=new xu(e.id,this.serializeUrl(e.extractedUrl),this.serializeUrl(e.urlAfterRedirects),e.targetSnapshot);this.triggerEvent(t)}),(t=this.paramsInheritanceStrategy,n=this.ngModule.injector,function(e){return e.pipe(W(e=>{const{targetSnapshot:r,guards:{canActivateChecks:s}}=e;return s.length?G(s).pipe(oa(e=>function(e,t,n,r){return function(e,t,n,r){const s=Object.keys(e);if(0===s.length)return wo({});if(1===s.length){const l=s[0];return wh(e[l],t,n,r).pipe(H(e=>({[l]:e})))}const l={};return G(s).pipe(W(s=>wh(e[s],t,n,r).pipe(H(e=>(l[s]=e,e))))).pipe(qo(),H(()=>l))}(e._resolve,e,t,r).pipe(H(t=>(e._resolvedData=t,e.data=Object.assign({},e.data,Cc(e,n).resolve),null)))}(e.route,r,t,n)),function(e,t){return arguments.length>=2?function(n){return _(sa(e,t),Do(1),Ho(t))(n)}:function(t){return _(sa((t,n,r)=>e(t,n,r+1)),Do(1))(t)}}((e,t)=>e),H(t=>e)):wo(e)}))}),Uo(e=>{const t=new Su(e.id,this.serializeUrl(e.extractedUrl),this.serializeUrl(e.urlAfterRedirects),e.targetSnapshot);this.triggerEvent(t)}));var t,n}),bh(e=>{const{targetSnapshot:t,id:n,extractedUrl:r,rawUrl:s,extras:{skipLocationChange:l,replaceUrl:i}}=e;return this.hooks.afterPreactivation(t,{navigationId:n,appliedUrlTree:r,rawUrlTree:s,skipLocationChange:!!l,replaceUrl:!!i})}),H(e=>{const t=function(e,t,n){const r=function e(t,n,r){if(r&&t.shouldReuseRoute(n.value,r.value.snapshot)){const s=r.value;s._futureSnapshot=n.value;const l=function(t,n,r){return n.children.map(n=>{for(const s of r.children)if(t.shouldReuseRoute(s.value.snapshot,n.value))return e(t,n,s);return e(t,n)})}(t,n,r);return new vc(s,l)}{const r=t.retrieve(n.value);if(r){const e=r.route;return function e(t,n){if(t.value.routeConfig!==n.value.routeConfig)throw new Error("Cannot reattach ActivatedRouteSnapshot created from a different route");if(t.children.length!==n.children.length)throw new Error("Cannot reattach ActivatedRouteSnapshot with a different number of children");n.value._futureSnapshot=t.value;for(let r=0;r<t.children.length;++r)e(t.children[r],n.children[r])}(n,e),e}{const r=new bc(new bo((s=n.value).url),new bo(s.params),new bo(s.queryParams),new bo(s.fragment),new bo(s.data),s.outlet,s.component,s),l=n.children.map(n=>e(t,n));return new vc(r,l)}}var s}(e,t._root,n?n._root:void 0);return new _c(r,t)}(this.routeReuseStrategy,e.targetSnapshot,e.currentRouterState);return Object.assign({},e,{targetRouterState:t})}),Uo(e=>{this.currentUrlTree=e.urlAfterRedirects,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,e.rawUrl),this.routerState=e.targetRouterState,"deferred"===this.urlUpdateStrategy&&(e.extras.skipLocationChange||this.setBrowserUrl(this.rawUrlTree,!!e.extras.replaceUrl,e.id,e.extras.state),this.browserUrlTree=e.urlAfterRedirects)}),(l=this.rootContexts,i=this.routeReuseStrategy,o=e=>this.triggerEvent(e),H(e=>(new Lc(i,e.targetRouterState,e.currentRouterState,o).activate(l),e))),Uo({next(){n=!0},complete(){n=!0}}),(s=()=>{if(!n&&!r){this.resetUrlToCurrentUrlTree();const n=new yu(e.id,this.serializeUrl(e.extractedUrl),`Navigation ID ${e.id} is not equal to the current navigation id ${this.navigationId}`);t.next(n),e.resolve(!1)}this.currentNavigation=null},e=>e.lift(new aa(s))),Go(n=>{if(r=!0,(s=n)&&s.ngNavigationCancelingError){const r=zc(n.url);r||(this.navigated=!0,this.resetStateAndUrl(e.currentRouterState,e.currentUrlTree,e.rawUrl));const s=new yu(e.id,this.serializeUrl(e.extractedUrl),n.message);t.next(s),e.resolve(!1),r&&this.navigateByUrl(n.url)}else{this.resetStateAndUrl(e.currentRouterState,e.currentUrlTree,e.rawUrl);const r=new _u(e.id,this.serializeUrl(e.extractedUrl),n);t.next(r);try{e.resolve(this.errorHandler(n))}catch(l){e.reject(l)}}var s;return vo}));var s,l,i,o}))}resetRootComponentType(e){this.rootComponentType=e,this.routerState.root.component=this.rootComponentType}getTransition(){const e=this.transitions.value;return e.urlAfterRedirects=this.browserUrlTree,e}setTransition(e){this.transitions.next(Object.assign({},this.getTransition(),e))}initialNavigation(){this.setUpLocationChangeListener(),0===this.navigationId&&this.navigateByUrl(this.location.path(!0),{replaceUrl:!0})}setUpLocationChangeListener(){this.locationSubscription||(this.locationSubscription=this.location.subscribe(e=>{let t=this.parseUrl(e.url);const n="popstate"===e.type?"popstate":"hashchange",r=e.state&&e.state.navigationId?e.state:null;setTimeout(()=>{this.scheduleNavigation(t,n,r,{replaceUrl:!0})},0)}))}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.currentNavigation}triggerEvent(e){this.events.next(e)}resetConfig(e){ju(e),this.config=e.map($u),this.navigated=!1,this.lastSuccessfulId=-1}ngOnDestroy(){this.dispose()}dispose(){this.locationSubscription&&(this.locationSubscription.unsubscribe(),this.locationSubscription=null)}createUrlTree(e,t={}){const{relativeTo:n,queryParams:r,fragment:s,preserveQueryParams:l,queryParamsHandling:i,preserveFragment:o}=t;Ge()&&l&&console&&console.warn&&console.warn("preserveQueryParams is deprecated, use queryParamsHandling instead.");const a=n||this.routerState.root,u=o?this.currentUrlTree.fragment:s;let c=null;if(i)switch(i){case"merge":c=Object.assign({},this.currentUrlTree.queryParams,r);break;case"preserve":c=this.currentUrlTree.queryParams;break;default:c=r||null}else c=l?this.currentUrlTree.queryParams:r||null;return null!==c&&(c=this.removeEmptyProps(c)),function(e,t,n,r,s){if(0===n.length)return Pc(t.root,t.root,t,r,s);const l=function(e){if("string"==typeof e[0]&&1===e.length&&"/"===e[0])return new Oc(!0,0,e);let t=0,n=!1;const r=e.reduce((e,r,s)=>{if("object"==typeof r&&null!=r){if(r.outlets){const t={};return qu(r.outlets,(e,n)=>{t[n]="string"==typeof e?e.split("/"):e}),[...e,{outlets:t}]}if(r.segmentPath)return[...e,r.segmentPath]}return"string"!=typeof r?[...e,r]:0===s?(r.split("/").forEach((r,s)=>{0==s&&"."===r||(0==s&&""===r?n=!0:".."===r?t++:""!=r&&e.push(r))}),e):[...e,r]},[]);return new Oc(n,t,r)}(n);if(l.toRoot())return Pc(t.root,new Qu([],{}),t,r,s);const i=function(e,t,n){if(e.isAbsolute)return new Rc(t.root,!0,0);if(-1===n.snapshot._lastPathIndex)return new Rc(n.snapshot._urlSegment,!0,0);const r=Ic(e.commands[0])?0:1;return function(e,t,n){let r=e,s=t,l=n;for(;l>s;){if(l-=s,r=r.parent,!r)throw new Error("Invalid number of '../'");s=r.segments.length}return new Rc(r,!1,s-l)}(n.snapshot._urlSegment,n.snapshot._lastPathIndex+r,e.numberOfDoubleDots)}(l,t,e),o=i.processChildren?Vc(i.segmentGroup,i.index,l.commands):Dc(i.segmentGroup,i.index,l.commands);return Pc(i.segmentGroup,o,t,r,s)}(a,this.currentUrlTree,e,c,u)}navigateByUrl(e,t={skipLocationChange:!1}){Ge()&&this.isNgZoneEnabled&&!qs.isInAngularZone()&&this.console.warn("Navigation triggered outside Angular zone, did you forget to call 'ngZone.run()'?");const n=zc(e)?e:this.parseUrl(e),r=this.urlHandlingStrategy.merge(n,this.rawUrlTree);return this.scheduleNavigation(r,"imperative",null,t)}navigate(e,t={skipLocationChange:!1}){return function(e){for(let t=0;t<e.length;t++){const n=e[t];if(null==n)throw new Error(`The requested path contains ${n} segment at index ${t}`)}}(e),this.navigateByUrl(this.createUrlTree(e,t),t)}serializeUrl(e){return this.urlSerializer.serialize(e)}parseUrl(e){let t;try{t=this.urlSerializer.parse(e)}catch(n){t=this.malformedUriErrorHandler(n,this.urlSerializer,e)}return t}isActive(e,t){if(zc(e))return Wu(this.currentUrlTree,e,t);const n=this.parseUrl(e);return Wu(this.currentUrlTree,n,t)}removeEmptyProps(e){return Object.keys(e).reduce((t,n)=>{const r=e[n];return null!=r&&(t[n]=r),t},{})}processNavigations(){this.navigations.subscribe(e=>{this.navigated=!0,this.lastSuccessfulId=e.id,this.events.next(new vu(e.id,this.serializeUrl(e.extractedUrl),this.serializeUrl(this.currentUrlTree))),this.lastSuccessfulNavigation=this.currentNavigation,this.currentNavigation=null,e.resolve(!0)},e=>{this.console.warn("Unhandled Navigation Error: ")})}scheduleNavigation(e,t,n,r){const s=this.getTransition();if(s&&"imperative"!==t&&"imperative"===s.source&&s.rawUrl.toString()===e.toString())return Promise.resolve(!0);if(s&&"hashchange"==t&&"popstate"===s.source&&s.rawUrl.toString()===e.toString())return Promise.resolve(!0);if(s&&"popstate"==t&&"hashchange"===s.source&&s.rawUrl.toString()===e.toString())return Promise.resolve(!0);let l=null,i=null;const o=new Promise((e,t)=>{l=e,i=t}),a=++this.navigationId;return this.setTransition({id:a,source:t,restoredState:n,currentUrlTree:this.currentUrlTree,currentRawUrl:this.rawUrlTree,rawUrl:e,extras:r,resolve:l,reject:i,promise:o,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),o.catch(e=>Promise.reject(e))}setBrowserUrl(e,t,n,r){const s=this.urlSerializer.serialize(e);r=r||{},this.location.isCurrentPathEqualTo(s)||t?this.location.replaceState(s,"",Object.assign({},r,{navigationId:n})):this.location.go(s,"",Object.assign({},r,{navigationId:n}))}resetStateAndUrl(e,t,n){this.routerState=e,this.currentUrlTree=t,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,n),this.resetUrlToCurrentUrlTree()}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",{navigationId:this.lastSuccessfulId})}}class Rh{constructor(e,t,n,r,s){this.router=e,this.route=t,this.commands=[],null==n&&r.setAttribute(s.nativeElement,"tabindex","0")}set routerLink(e){this.commands=null!=e?Array.isArray(e)?e:[e]:[]}set preserveQueryParams(e){Ge()&&console&&console.warn&&console.warn("preserveQueryParams is deprecated!, use queryParamsHandling instead."),this.preserve=e}onClick(){const e={skipLocationChange:Dh(this.skipLocationChange),replaceUrl:Dh(this.replaceUrl)};return this.router.navigateByUrl(this.urlTree,e),!0}get urlTree(){return this.router.createUrlTree(this.commands,{relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,preserveQueryParams:Dh(this.preserve),queryParamsHandling:this.queryParamsHandling,preserveFragment:Dh(this.preserveFragment)})}}class Nh{constructor(e,t,n){this.router=e,this.route=t,this.locationStrategy=n,this.commands=[],this.subscription=e.events.subscribe(e=>{e instanceof vu&&this.updateTargetUrlAndHref()})}set routerLink(e){this.commands=null!=e?Array.isArray(e)?e:[e]:[]}set preserveQueryParams(e){Ge()&&console&&console.warn&&console.warn("preserveQueryParams is deprecated, use queryParamsHandling instead."),this.preserve=e}ngOnChanges(e){this.updateTargetUrlAndHref()}ngOnDestroy(){this.subscription.unsubscribe()}onClick(e,t,n,r){if(0!==e||t||n||r)return!0;if("string"==typeof this.target&&"_self"!=this.target)return!0;const s={skipLocationChange:Dh(this.skipLocationChange),replaceUrl:Dh(this.replaceUrl),state:this.state};return this.router.navigateByUrl(this.urlTree,s),!1}updateTargetUrlAndHref(){this.href=this.locationStrategy.prepareExternalUrl(this.router.serializeUrl(this.urlTree))}get urlTree(){return this.router.createUrlTree(this.commands,{relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,preserveQueryParams:Dh(this.preserve),queryParamsHandling:this.queryParamsHandling,preserveFragment:Dh(this.preserveFragment)})}}function Dh(e){return""===e||!!e}class Vh{constructor(){this.outlet=null,this.route=null,this.resolver=null,this.children=new Mh,this.attachRef=null}}class Mh{constructor(){this.contexts=new Map}onChildOutletCreated(e,t){const n=this.getOrCreateContext(e);n.outlet=t,this.contexts.set(e,n)}onChildOutletDestroyed(e){const t=this.getContext(e);t&&(t.outlet=null)}onOutletDeactivated(){const e=this.contexts;return this.contexts=new Map,e}onOutletReAttached(e){this.contexts=e}getOrCreateContext(e){let t=this.getContext(e);return t||(t=new Vh,this.contexts.set(e,t)),t}getContext(e){return this.contexts.get(e)||null}}class Uh{constructor(e,t,n,r,s){this.parentContexts=e,this.location=t,this.resolver=n,this.changeDetector=s,this.activated=null,this._activatedRoute=null,this.activateEvents=new ms,this.deactivateEvents=new ms,this.name=r||"primary",e.onChildOutletCreated(this.name,this)}ngOnDestroy(){this.parentContexts.onChildOutletDestroyed(this.name)}ngOnInit(){if(!this.activated){const e=this.parentContexts.getContext(this.name);e&&e.route&&(e.attachRef?this.attach(e.attachRef,e.route):this.activateWith(e.route,e.resolver||null))}}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new Error("Outlet is not activated");return this.activated.instance}get activatedRoute(){if(!this.activated)throw new Error("Outlet is not activated");return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new Error("Outlet is not activated");this.location.detach();const e=this.activated;return this.activated=null,this._activatedRoute=null,e}attach(e,t){this.activated=e,this._activatedRoute=t,this.location.insert(e.hostView)}deactivate(){if(this.activated){const e=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(e)}}activateWith(e,t){if(this.isActivated)throw new Error("Cannot activate an already activated outlet");this._activatedRoute=e;const n=(t=t||this.resolver).resolveComponentFactory(e._futureSnapshot.routeConfig.component),r=this.parentContexts.getOrCreateContext(this.name).children,s=new jh(e,r,this.location.injector);this.activated=this.location.createComponent(n,this.location.length,s),this.changeDetector.markForCheck(),this.activateEvents.emit(this.activated.instance)}}class jh{constructor(e,t,n){this.route=e,this.childContexts=t,this.parent=n}get(e,t){return e===bc?this.route:e===Mh?this.childContexts:this.parent.get(e,t)}}class Fh{}class Lh{preload(e,t){return t().pipe(Go(()=>wo(null)))}}class $h{preload(e,t){return wo(null)}}class Hh{constructor(e,t,n,r,s){this.router=e,this.injector=r,this.preloadingStrategy=s,this.loader=new Eh(t,n,t=>e.triggerEvent(new Eu(t)),t=>e.triggerEvent(new Tu(t)))}setUpPreloading(){this.subscription=this.router.events.pipe(Io(e=>e instanceof vu),oa(()=>this.preload())).subscribe(()=>{})}preload(){const e=this.injector.get(De);return this.processRoutes(e,this.router.config)}ngOnDestroy(){this.subscription.unsubscribe()}processRoutes(e,t){const n=[];for(const r of t)if(r.loadChildren&&!r.canLoad&&r._loadedConfig){const e=r._loadedConfig;n.push(this.processRoutes(e.module,e.routes))}else r.loadChildren&&!r.canLoad?n.push(this.preloadConfig(e,r)):r.children&&n.push(this.processRoutes(e,r.children));return G(n).pipe(Y(),H(e=>{}))}preloadConfig(e,t){return this.preloadingStrategy.preload(t,()=>this.loader.load(e.injector,t).pipe(W(e=>(t._loadedConfig=e,this.processRoutes(e.module,e.routes)))))}}class zh{constructor(e,t,n={}){this.router=e,this.viewportScroller=t,this.options=n,this.lastId=0,this.lastSource="imperative",this.restoredId=0,this.store={},n.scrollPositionRestoration=n.scrollPositionRestoration||"disabled",n.anchorScrolling=n.anchorScrolling||"disabled"}init(){"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.router.events.subscribe(e=>{e instanceof mu?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=e.navigationTrigger,this.restoredId=e.restoredState?e.restoredState.navigationId:0):e instanceof vu&&(this.lastId=e.id,this.scheduleScrollEvent(e,this.router.parseUrl(e.urlAfterRedirects).fragment))})}consumeScrollEvents(){return this.router.events.subscribe(e=>{e instanceof Ou&&(e.position?"top"===this.options.scrollPositionRestoration?this.viewportScroller.scrollToPosition([0,0]):"enabled"===this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition(e.position):e.anchor&&"enabled"===this.options.anchorScrolling?this.viewportScroller.scrollToAnchor(e.anchor):"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(e,t){this.router.triggerEvent(new Ou(e,"popstate"===this.lastSource?this.store[this.restoredId]:null,t))}ngOnDestroy(){this.routerEventsSubscription&&this.routerEventsSubscription.unsubscribe(),this.scrollEventsSubscription&&this.scrollEventsSubscription.unsubscribe()}}const Bh=new Se("ROUTER_CONFIGURATION"),qh=new Se("ROUTER_FORROOT_GUARD"),Gh=[to,{provide:Xu,useClass:ec},{provide:Oh,useFactory:Xh,deps:[ul,Xu,Mh,to,St,hl,Ds,Sh,Bh,[Th,new oe],[Ch,new oe]]},Mh,{provide:bc,useFactory:ed,deps:[Oh]},{provide:hl,useClass:gl},Hh,$h,Lh,{provide:Bh,useValue:{enableTracing:!1}}];function Wh(){return new sl("Router",Oh)}class Zh{constructor(e,t){}static forRoot(e,t){return{ngModule:Zh,providers:[Gh,Jh(e),{provide:qh,useFactory:Yh,deps:[[Oh,new oe,new ue]]},{provide:Bh,useValue:t||{}},{provide:Xi,useFactory:Kh,deps:[Yi,[new ie(eo),new oe],Bh]},{provide:zh,useFactory:Qh,deps:[Oh,fo,Bh]},{provide:Fh,useExisting:t&&t.preloadingStrategy?t.preloadingStrategy:$h},{provide:sl,multi:!0,useFactory:Wh},[td,{provide:_s,multi:!0,useFactory:nd,deps:[td]},{provide:sd,useFactory:rd,deps:[td]},{provide:Ts,multi:!0,useExisting:sd}]]}}static forChild(e){return{ngModule:Zh,providers:[Jh(e)]}}}function Qh(e,t,n){return n.scrollOffset&&t.setOffset(n.scrollOffset),new zh(e,t,n)}function Kh(e,t,n={}){return n.useHash?new ro(e,t):new so(e,t)}function Yh(e){if(e)throw new Error("RouterModule.forRoot() called twice. Lazy loaded modules should use RouterModule.forChild() instead.");return"guarded"}function Jh(e){return[{provide:Rt,multi:!0,useValue:e},{provide:Sh,multi:!0,useValue:e}]}function Xh(e,t,n,r,s,l,i,o,a={},u,c){const h=new Oh(null,t,n,r,s,l,i,zu(o));if(u&&(h.urlHandlingStrategy=u),c&&(h.routeReuseStrategy=c),a.errorHandler&&(h.errorHandler=a.errorHandler),a.malformedUriErrorHandler&&(h.malformedUriErrorHandler=a.malformedUriErrorHandler),a.enableTracing){const e=ha();h.events.subscribe(t=>{e.logGroup(`Router Event: ${t.constructor.name}`),e.log(t.toString()),e.log(t),e.logGroupEnd()})}return a.onSameUrlNavigation&&(h.onSameUrlNavigation=a.onSameUrlNavigation),a.paramsInheritanceStrategy&&(h.paramsInheritanceStrategy=a.paramsInheritanceStrategy),a.urlUpdateStrategy&&(h.urlUpdateStrategy=a.urlUpdateStrategy),a.relativeLinkResolution&&(h.relativeLinkResolution=a.relativeLinkResolution),h}function ed(e){return e.routerState.root}class td{constructor(e){this.injector=e,this.initNavigation=!1,this.resultOfPreactivationDone=new k}appInitializer(){return this.injector.get(Ji,Promise.resolve(null)).then(()=>{let e=null;const t=new Promise(t=>e=t),n=this.injector.get(Oh),r=this.injector.get(Bh);if(this.isLegacyDisabled(r)||this.isLegacyEnabled(r))e(!0);else if("disabled"===r.initialNavigation)n.setUpLocationChangeListener(),e(!0);else{if("enabled"!==r.initialNavigation)throw new Error(`Invalid initialNavigation options: '${r.initialNavigation}'`);n.hooks.afterPreactivation=()=>this.initNavigation?wo(null):(this.initNavigation=!0,e(!0),this.resultOfPreactivationDone),n.initialNavigation()}return t})}bootstrapListener(e){const t=this.injector.get(Bh),n=this.injector.get(Hh),r=this.injector.get(zh),s=this.injector.get(Oh),l=this.injector.get(ul);e===l.components[0]&&(this.isLegacyEnabled(t)?s.initialNavigation():this.isLegacyDisabled(t)&&s.setUpLocationChangeListener(),n.setUpPreloading(),r.init(),s.resetRootComponentType(l.componentTypes[0]),this.resultOfPreactivationDone.next(null),this.resultOfPreactivationDone.complete())}isLegacyEnabled(e){return"legacy_enabled"===e.initialNavigation||!0===e.initialNavigation||void 0===e.initialNavigation}isLegacyDisabled(e){return"legacy_disabled"===e.initialNavigation||!1===e.initialNavigation}}function nd(e){return e.appInitializer.bind(e)}function rd(e){return e.bootstrapListener.bind(e)}const sd=new Se("Router Initializer");var ld=Ln({encapsulation:2,styles:[],data:{}});function id(e){return Hl(0,[(e()(),Il(0,16777216,null,null,1,"router-outlet",[],null,null,null,null,null)),Qr(1,212992,null,0,Uh,[Mh,Sn,Wt,[8,null],wt],null,null)],(function(e,t){e(t,1,0)}),null)}function od(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"ng-component",[],null,null,null,id,ld)),Qr(1,49152,null,0,Ru,[],null,null)],null,null)}var ad=Er("ng-component",Ru,od,{},{},[]);class ud{constructor(){}ngOnInit(){}}var cd=Ln({encapsulation:0,styles:[[""]],data:{}});function hd(e){return Hl(0,[(e()(),Il(0,0,null,null,9,"nav",[["class","navbar navbar-expand-lg navbar-dark bg-primary"]],null,null,null,null,null)),(e()(),Il(1,0,null,null,2,"a",[["class","navbar-brand"],["routerLink","/"]],[[1,"target",0],[8,"href",4]],[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==Mr(e,2).onClick(n.button,n.ctrlKey,n.metaKey,n.shiftKey)&&r),r}),null,null)),Qr(2,671744,null,0,Nh,[Oh,bc,Xi],{routerLink:[0,"routerLink"]},null),(e()(),Fl(-1,null,["Tacos & More"])),(e()(),Il(4,0,null,null,5,"div",[["class","collapse navbar-collapse"]],null,null,null,null,null)),(e()(),Il(5,0,null,null,4,"ul",[["class","navbar-nav ml-auto mt-2"]],null,null,null,null,null)),(e()(),Il(6,0,null,null,3,"li",[["class","nav-item active"]],null,null,null,null,null)),(e()(),Il(7,0,null,null,2,"a",[["class","nav-link"],["routerLink","/recipes/new"]],[[1,"target",0],[8,"href",4]],[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==Mr(e,8).onClick(n.button,n.ctrlKey,n.metaKey,n.shiftKey)&&r),r}),null,null)),Qr(8,671744,null,0,Nh,[Oh,bc,Xi],{routerLink:[0,"routerLink"]},null),(e()(),Fl(-1,null,["Add Recipe"]))],(function(e,t){e(t,2,0,"/"),e(t,8,0,"/recipes/new")}),(function(e,t){e(t,1,0,Mr(t,2).target,Mr(t,2).href),e(t,7,0,Mr(t,8).target,Mr(t,8).href)}))}class dd{constructor(e){this.recipeService=e}}var pd=n("UDOl");class gd{constructor(){this.recipes=[],pd.a.forEach(e=>{this.recipes.push(Object.assign({},e))})}getRecipes(){return this.recipes}getRecipeById(e){return this.recipes.find(t=>t.id===e)}createRecipe(e,t,n,r,s,l){const i={id:this.getNextId(),title:e,description:t,serves:n,imageUrl:r,ingredients:[...s],instructions:[...l]};return this.recipes.push(Object.assign({},i)),i}updateRecipe(e){const t=this.recipes.findIndex(t=>t.id===e.id);return this.recipes[t]=e,e}deleteRecipe(e){const t=this.recipes.findIndex(t=>t.id===e);-1!==t&&this.recipes.splice(t,1)}getNextId(){return Math.max.apply(null,this.recipes.map(e=>e.id))+1}}var fd=Ln({encapsulation:0,styles:[[".jumbotron[_ngcontent-%COMP%]{background:url(https://yisus82.github.io/zenva-angular/assets/food-background.jpg) 0 0/cover;border-radius:0}.jumbotron-heading[_ngcontent-%COMP%], p.lead[_ngcontent-%COMP%]{color:#fff;text-shadow:2px 2px 5px #000}.card[_ngcontent-%COMP%]{margin-bottom:2em;width:18em}"]],data:{}});function md(e){return Hl(0,[(e()(),Il(0,0,null,null,11,null,null,null,null,null,null,null)),(e()(),Il(1,0,null,null,10,"div",[["class","col d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(2,0,null,null,9,"div",[["class","card"]],null,null,null,null,null)),(e()(),Il(3,0,null,null,0,"img",[["class","card-img-top"]],[[8,"src",4],[8,"alt",0]],null,null,null,null)),(e()(),Il(4,0,null,null,7,"div",[["class","card-body"]],null,null,null,null,null)),(e()(),Il(5,0,null,null,1,"h5",[["class","card-title"]],null,null,null,null,null)),(e()(),Fl(6,null,["",""])),(e()(),Il(7,0,null,null,1,"p",[["class","card-text"]],null,null,null,null,null)),(e()(),Fl(8,null,["",""])),(e()(),Il(9,0,null,null,2,"a",[["class","btn btn-primary"]],[[1,"target",0],[8,"href",4]],[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==Mr(e,10).onClick(n.button,n.ctrlKey,n.metaKey,n.shiftKey)&&r),r}),null,null)),Qr(10,671744,null,0,Nh,[Oh,bc,Xi],{routerLink:[0,"routerLink"]},null),(e()(),Fl(-1,null,["View"]))],(function(e,t){e(t,10,0,dr(1,"/recipes/",t.context.$implicit.id,""))}),(function(e,t){e(t,3,0,t.context.$implicit.imageUrl,t.context.$implicit.title),e(t,6,0,t.context.$implicit.title),e(t,8,0,t.context.$implicit.description),e(t,9,0,Mr(t,10).target,Mr(t,10).href)}))}function vd(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"app-navbar",[],null,null,null,hd,cd)),Qr(1,114688,null,0,ud,[],null,null),(e()(),Il(2,0,null,null,10,"section",[["class","jumbotron text-center"]],null,null,null,null,null)),(e()(),Il(3,0,null,null,9,"div",[["class","container"]],null,null,null,null,null)),(e()(),Il(4,0,null,null,1,"h1",[["class","jumbotron-heading"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Tacos & More"])),(e()(),Il(6,0,null,null,2,"div",[["class","d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(7,0,null,null,1,"p",[["class","lead w-50"]],null,null,null,null,null)),(e()(),Fl(-1,null,[" A collection of our favorite taco recipes and more! "])),(e()(),Il(9,0,null,null,3,"p",[],null,null,null,null,null)),(e()(),Il(10,0,null,null,2,"a",[["class","btn btn-primary"],["routerLink","/recipes/new"]],[[1,"target",0],[8,"href",4]],[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==Mr(e,11).onClick(n.button,n.ctrlKey,n.metaKey,n.shiftKey)&&r),r}),null,null)),Qr(11,671744,null,0,Nh,[Oh,bc,Xi],{routerLink:[0,"routerLink"]},null),(e()(),Fl(-1,null,["Add New Recipe"])),(e()(),Il(13,0,null,null,3,"section",[["class","container"]],null,null,null,null,null)),(e()(),Il(14,0,null,null,2,"div",[["class","row"]],null,null,null,null,null)),(e()(),Al(16777216,null,null,1,null,md)),Qr(16,278528,null,0,co,[Sn,Cn,vn],{ngForOf:[0,"ngForOf"]},null)],(function(e,t){var n=t.component;e(t,1,0),e(t,11,0,"/recipes/new"),e(t,16,0,n.recipeService.getRecipes())}),(function(e,t){e(t,10,0,Mr(t,11).target,Mr(t,11).href)}))}function yd(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"app-home",[],null,null,null,vd,fd)),Qr(1,49152,null,0,dd,[gd],null,null)],null,null)}var _d=Er("app-home",dd,yd,{},{},[]);class wd extends ${constructor(e,t){super(e),this.sources=t,this.completed=0,this.haveValues=0;const n=t.length;this.values=new Array(n);for(let r=0;r<n;r++){const e=L(this,t[r],null,r);e&&this.add(e)}}notifyNext(e,t,n,r,s){this.values[n]=t,s._hasValue||(s._hasValue=!0,this.haveValues++)}notifyComplete(e){const{destination:t,haveValues:n,values:r}=this,s=r.length;e._hasValue?(this.completed++,this.completed===s&&(n===s&&t.next(r),t.complete())):t.complete()}}const bd=new Se("NgValueAccessor"),Cd=new Se("CompositionEventMode");class xd{constructor(e,t,n){this._renderer=e,this._elementRef=t,this._compositionMode=n,this.onChange=e=>{},this.onTouched=()=>{},this._composing=!1,null==this._compositionMode&&(this._compositionMode=!function(){const e=ha()?ha().getUserAgent():"";return/android (\d+)/.test(e.toLowerCase())}())}writeValue(e){this._renderer.setProperty(this._elementRef.nativeElement,"value",null==e?"":e)}registerOnChange(e){this.onChange=e}registerOnTouched(e){this.onTouched=e}setDisabledState(e){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",e)}_handleInput(e){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(e)}_compositionStart(){this._composing=!0}_compositionEnd(e){this._composing=!1,this._compositionMode&&this.onChange(e)}}class Sd{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}reset(e){this.control&&this.control.reset(e)}hasError(e,t){return!!this.control&&this.control.hasError(e,t)}getError(e,t){return this.control?this.control.getError(e,t):null}}class Ed extends Sd{get formDirective(){return null}get path(){return null}}function Td(){throw new Error("unimplemented")}class kd extends Sd{constructor(){super(...arguments),this._parent=null,this.name=null,this.valueAccessor=null,this._rawValidators=[],this._rawAsyncValidators=[]}get validator(){return Td()}get asyncValidator(){return Td()}}class Ad{constructor(e){this._cd=e}get ngClassUntouched(){return!!this._cd.control&&this._cd.control.untouched}get ngClassTouched(){return!!this._cd.control&&this._cd.control.touched}get ngClassPristine(){return!!this._cd.control&&this._cd.control.pristine}get ngClassDirty(){return!!this._cd.control&&this._cd.control.dirty}get ngClassValid(){return!!this._cd.control&&this._cd.control.valid}get ngClassInvalid(){return!!this._cd.control&&this._cd.control.invalid}get ngClassPending(){return!!this._cd.control&&this._cd.control.pending}}class Id extends Ad{constructor(e){super(e)}}class Pd extends Ad{constructor(e){super(e)}}function Od(e){return null==e||0===e.length}const Rd=/^(?=.{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])?)*$/;class Nd{static min(e){return t=>{if(Od(t.value)||Od(e))return null;const n=parseFloat(t.value);return!isNaN(n)&&n<e?{min:{min:e,actual:t.value}}:null}}static max(e){return t=>{if(Od(t.value)||Od(e))return null;const n=parseFloat(t.value);return!isNaN(n)&&n>e?{max:{max:e,actual:t.value}}:null}}static required(e){return Od(e.value)?{required:!0}:null}static requiredTrue(e){return!0===e.value?null:{required:!0}}static email(e){return Od(e.value)?null:Rd.test(e.value)?null:{email:!0}}static minLength(e){return t=>{if(Od(t.value))return null;const n=t.value?t.value.length:0;return n<e?{minlength:{requiredLength:e,actualLength:n}}:null}}static maxLength(e){return t=>{const n=t.value?t.value.length:0;return n>e?{maxlength:{requiredLength:e,actualLength:n}}:null}}static pattern(e){if(!e)return Nd.nullValidator;let t,n;return"string"==typeof e?(n="","^"!==e.charAt(0)&&(n+="^"),n+=e,"$"!==e.charAt(e.length-1)&&(n+="$"),t=new RegExp(n)):(n=e.toString(),t=e),e=>{if(Od(e.value))return null;const r=e.value;return t.test(r)?null:{pattern:{requiredPattern:n,actualValue:r}}}}static nullValidator(e){return null}static compose(e){if(!e)return null;const t=e.filter(Dd);return 0==t.length?null:function(e){return Md(function(e,t){return t.map(t=>t(e))}(e,t))}}static composeAsync(e){if(!e)return null;const t=e.filter(Dd);return 0==t.length?null:function(e){return function e(...t){let n;return"function"==typeof t[t.length-1]&&(n=t.pop()),1===t.length&&a(t[0])&&(t=t[0]),0===t.length?vo:n?e(t).pipe(H(e=>n(...e))):new b(e=>new wd(e,t))}(function(e,t){return t.map(t=>t(e))}(e,t).map(Vd)).pipe(H(Md))}}}function Dd(e){return null!=e}function Vd(e){const t=Lt(e)?G(e):e;if(!$t(t))throw new Error("Expected validator to return Promise or Observable.");return t}function Md(e){const t=e.reduce((e,t)=>null!=t?Object.assign({},e,t):e,{});return 0===Object.keys(t).length?null:t}function Ud(e){return e.validate?t=>e.validate(t):e}function jd(e){return e.validate?t=>e.validate(t):e}class Fd{constructor(){this._accessors=[]}add(e,t){this._accessors.push([e,t])}remove(e){for(let t=this._accessors.length-1;t>=0;--t)if(this._accessors[t][1]===e)return void this._accessors.splice(t,1)}select(e){this._accessors.forEach(t=>{this._isSameGroup(t,e)&&t[1]!==e&&t[1].fireUncheck(e.value)})}_isSameGroup(e,t){return!!e[0].control&&e[0]._parent===t._control._parent&&e[1].name===t.name}}const Ld='\n <div [formGroup]="myGroup">\n <input formControlName="firstName">\n </div>\n\n In your class:\n\n this.myGroup = new FormGroup({\n firstName: new FormControl()\n });',$d='\n <div [formGroup]="myGroup">\n <div formGroupName="person">\n <input formControlName="firstName">\n </div>\n </div>\n\n In your class:\n\n this.myGroup = new FormGroup({\n person: new FormGroup({ firstName: new FormControl() })\n });';class Hd{static controlParentException(){throw new Error(`formControlName must be used with a parent formGroup directive. You'll want to add a formGroup\n directive and pass it an existing FormGroup instance (you can create one in your class).\n\n Example:\n\n ${Ld}`)}static ngModelGroupException(){throw new Error(`formControlName cannot be used with an ngModelGroup parent. It is only compatible with parents\n that also have a "form" prefix: formGroupName, formArrayName, or formGroup.\n\n Option 1: Update the parent to be formGroupName (reactive form strategy)\n\n ${$d}\n\n Option 2: Use ngModel instead of formControlName (template-driven strategy)\n\n \n <form>\n <div ngModelGroup="person">\n <input [(ngModel)]="person.name" name="firstName">\n </div>\n </form>`)}static missingFormException(){throw new Error(`formGroup expects a FormGroup instance. Please pass one in.\n\n Example:\n\n ${Ld}`)}static groupParentException(){throw new Error(`formGroupName must be used with a parent formGroup directive. You'll want to add a formGroup\n directive and pass it an existing FormGroup instance (you can create one in your class).\n\n Example:\n\n ${$d}`)}static arrayParentException(){throw new Error('formArrayName must be used with a parent formGroup directive. You\'ll want to add a formGroup\n directive and pass it an existing FormGroup instance (you can create one in your class).\n\n Example:\n\n \n <div [formGroup]="myGroup">\n <div formArrayName="cities">\n <div *ngFor="let city of cityArray.controls; index as i">\n <input [formControlName]="i">\n </div>\n </div>\n </div>\n\n In your class:\n\n this.cityArray = new FormArray([new FormControl(\'SF\')]);\n this.myGroup = new FormGroup({\n cities: this.cityArray\n });')}static disabledAttrWarning(){console.warn("\n It looks like you're using the disabled attribute with a reactive form directive. If you set disabled to true\n when you set up this control in your component class, the disabled attribute will actually be set in the DOM for\n you. We recommend using this approach to avoid 'changed after checked' errors.\n \n Example: \n form = new FormGroup({\n first: new FormControl({value: 'Nancy', disabled: true}, Validators.required),\n last: new FormControl('Drew', Validators.required)\n });\n ")}static ngModelWarning(e){console.warn(`\n It looks like you're using ngModel on the same form field as ${e}. \n Support for using the ngModel input property and ngModelChange event with \n reactive form directives has been deprecated in Angular v6 and will be removed \n in Angular v7.\n \n For more information on this, see our API docs here:\n https://angular.io/api/forms/${"formControl"===e?"FormControlDirective":"FormControlName"}#use-with-ngmodel\n `)}}function zd(e,t){return[...t.path,e]}function Bd(e,t){e||Zd(t,"Cannot find control with"),t.valueAccessor||Zd(t,"No value accessor for form control with"),e.validator=Nd.compose([e.validator,t.validator]),e.asyncValidator=Nd.composeAsync([e.asyncValidator,t.asyncValidator]),t.valueAccessor.writeValue(e.value),function(e,t){t.valueAccessor.registerOnChange(n=>{e._pendingValue=n,e._pendingChange=!0,e._pendingDirty=!0,"change"===e.updateOn&&qd(e,t)})}(e,t),function(e,t){e.registerOnChange((e,n)=>{t.valueAccessor.writeValue(e),n&&t.viewToModelUpdate(e)})}(e,t),function(e,t){t.valueAccessor.registerOnTouched(()=>{e._pendingTouched=!0,"blur"===e.updateOn&&e._pendingChange&&qd(e,t),"submit"!==e.updateOn&&e.markAsTouched()})}(e,t),t.valueAccessor.setDisabledState&&e.registerOnDisabledChange(e=>{t.valueAccessor.setDisabledState(e)}),t._rawValidators.forEach(t=>{t.registerOnValidatorChange&&t.registerOnValidatorChange(()=>e.updateValueAndValidity())}),t._rawAsyncValidators.forEach(t=>{t.registerOnValidatorChange&&t.registerOnValidatorChange(()=>e.updateValueAndValidity())})}function qd(e,t){e._pendingDirty&&e.markAsDirty(),e.setValue(e._pendingValue,{emitModelToViewChange:!1}),t.viewToModelUpdate(e._pendingValue),e._pendingChange=!1}function Gd(e,t){null==e&&Zd(t,"Cannot find control with"),e.validator=Nd.compose([e.validator,t.validator]),e.asyncValidator=Nd.composeAsync([e.asyncValidator,t.asyncValidator])}function Wd(e){return Zd(e,"There is no FormControl instance attached to form control element with")}function Zd(e,t){let n;throw n=e.path.length>1?`path: '${e.path.join(" -> ")}'`:e.path[0]?`name: '${e.path}'`:"unspecified name attribute",new Error(`${t} ${n}`)}function Qd(e){return null!=e?Nd.compose(e.map(Ud)):null}function Kd(e){return null!=e?Nd.composeAsync(e.map(jd)):null}const Yd=[class{constructor(e,t){this._renderer=e,this._elementRef=t,this.onChange=e=>{},this.onTouched=()=>{}}writeValue(e){this._renderer.setProperty(this._elementRef.nativeElement,"checked",e)}registerOnChange(e){this.onChange=e}registerOnTouched(e){this.onTouched=e}setDisabledState(e){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",e)}},class{constructor(e,t){this._renderer=e,this._elementRef=t,this.onChange=e=>{},this.onTouched=()=>{}}writeValue(e){this._renderer.setProperty(this._elementRef.nativeElement,"value",parseFloat(e))}registerOnChange(e){this.onChange=t=>{e(""==t?null:parseFloat(t))}}registerOnTouched(e){this.onTouched=e}setDisabledState(e){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",e)}},class{constructor(e,t){this._renderer=e,this._elementRef=t,this.onChange=e=>{},this.onTouched=()=>{}}writeValue(e){this._renderer.setProperty(this._elementRef.nativeElement,"value",null==e?"":e)}registerOnChange(e){this.onChange=t=>{e(""==t?null:parseFloat(t))}}registerOnTouched(e){this.onTouched=e}setDisabledState(e){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",e)}},class{constructor(e,t){this._renderer=e,this._elementRef=t,this._optionMap=new Map,this._idCounter=0,this.onChange=e=>{},this.onTouched=()=>{},this._compareWith=Vt}set compareWith(e){if("function"!=typeof e)throw new Error(`compareWith must be a function, but received ${JSON.stringify(e)}`);this._compareWith=e}writeValue(e){this.value=e;const t=this._getOptionId(e);null==t&&this._renderer.setProperty(this._elementRef.nativeElement,"selectedIndex",-1);const n=function(e,t){return null==e?`${t}`:(t&&"object"==typeof t&&(t="Object"),`${e}: ${t}`.slice(0,50))}(t,e);this._renderer.setProperty(this._elementRef.nativeElement,"value",n)}registerOnChange(e){this.onChange=t=>{this.value=this._getOptionValue(t),e(this.value)}}registerOnTouched(e){this.onTouched=e}setDisabledState(e){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",e)}_registerOption(){return(this._idCounter++).toString()}_getOptionId(e){for(const t of Array.from(this._optionMap.keys()))if(this._compareWith(this._optionMap.get(t),e))return t;return null}_getOptionValue(e){const t=function(e){return e.split(":")[0]}(e);return this._optionMap.has(t)?this._optionMap.get(t):e}},class{constructor(e,t){this._renderer=e,this._elementRef=t,this._optionMap=new Map,this._idCounter=0,this.onChange=e=>{},this.onTouched=()=>{},this._compareWith=Vt}set compareWith(e){if("function"!=typeof e)throw new Error(`compareWith must be a function, but received ${JSON.stringify(e)}`);this._compareWith=e}writeValue(e){let t;if(this.value=e,Array.isArray(e)){const n=e.map(e=>this._getOptionId(e));t=(e,t)=>{e._setSelected(n.indexOf(t.toString())>-1)}}else t=(e,t)=>{e._setSelected(!1)};this._optionMap.forEach(t)}registerOnChange(e){this.onChange=t=>{const n=[];if(t.hasOwnProperty("selectedOptions")){const e=t.selectedOptions;for(let t=0;t<e.length;t++){const r=e.item(t),s=this._getOptionValue(r.value);n.push(s)}}else{const e=t.options;for(let t=0;t<e.length;t++){const r=e.item(t);if(r.selected){const e=this._getOptionValue(r.value);n.push(e)}}}this.value=n,e(n)}}registerOnTouched(e){this.onTouched=e}setDisabledState(e){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",e)}_registerOption(e){const t=(this._idCounter++).toString();return this._optionMap.set(t,e),t}_getOptionId(e){for(const t of Array.from(this._optionMap.keys()))if(this._compareWith(this._optionMap.get(t)._value,e))return t;return null}_getOptionValue(e){const t=function(e){return e.split(":")[0]}(e);return this._optionMap.has(t)?this._optionMap.get(t)._value:e}},class{constructor(e,t,n,r){this._renderer=e,this._elementRef=t,this._registry=n,this._injector=r,this.onChange=()=>{},this.onTouched=()=>{}}ngOnInit(){this._control=this._injector.get(kd),this._checkName(),this._registry.add(this._control,this)}ngOnDestroy(){this._registry.remove(this)}writeValue(e){this._state=e===this.value,this._renderer.setProperty(this._elementRef.nativeElement,"checked",this._state)}registerOnChange(e){this._fn=e,this.onChange=()=>{e(this.value),this._registry.select(this)}}fireUncheck(e){this.writeValue(e)}registerOnTouched(e){this.onTouched=e}setDisabledState(e){this._renderer.setProperty(this._elementRef.nativeElement,"disabled",e)}_checkName(){this.name&&this.formControlName&&this.name!==this.formControlName&&this._throwNameError(),!this.name&&this.formControlName&&(this.name=this.formControlName)}_throwNameError(){throw new Error('\n If you define both a name and a formControlName attribute on your radio button, their values\n must match. Ex: <input type="radio" formControlName="food" name="food">\n ')}}];function Jd(e){const t=ep(e)?e.validators:e;return Array.isArray(t)?Qd(t):t||null}function Xd(e,t){const n=ep(t)?t.asyncValidators:e;return Array.isArray(n)?Kd(n):n||null}function ep(e){return null!=e&&!Array.isArray(e)&&"object"==typeof e}class tp{constructor(e,t){this.validator=e,this.asyncValidator=t,this._onCollectionChange=()=>{},this.pristine=!0,this.touched=!1,this._onDisabledChange=[]}get parent(){return this._parent}get valid(){return"VALID"===this.status}get invalid(){return"INVALID"===this.status}get pending(){return"PENDING"==this.status}get disabled(){return"DISABLED"===this.status}get enabled(){return"DISABLED"!==this.status}get dirty(){return!this.pristine}get untouched(){return!this.touched}get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(e){this.validator=Jd(e)}setAsyncValidators(e){this.asyncValidator=Xd(e)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(e={}){this.touched=!0,this._parent&&!e.onlySelf&&this._parent.markAsTouched(e)}markAllAsTouched(){this.markAsTouched({onlySelf:!0}),this._forEachChild(e=>e.markAllAsTouched())}markAsUntouched(e={}){this.touched=!1,this._pendingTouched=!1,this._forEachChild(e=>{e.markAsUntouched({onlySelf:!0})}),this._parent&&!e.onlySelf&&this._parent._updateTouched(e)}markAsDirty(e={}){this.pristine=!1,this._parent&&!e.onlySelf&&this._parent.markAsDirty(e)}markAsPristine(e={}){this.pristine=!0,this._pendingDirty=!1,this._forEachChild(e=>{e.markAsPristine({onlySelf:!0})}),this._parent&&!e.onlySelf&&this._parent._updatePristine(e)}markAsPending(e={}){this.status="PENDING",!1!==e.emitEvent&&this.statusChanges.emit(this.status),this._parent&&!e.onlySelf&&this._parent.markAsPending(e)}disable(e={}){const t=this._parentMarkedDirty(e.onlySelf);this.status="DISABLED",this.errors=null,this._forEachChild(t=>{t.disable(Object.assign({},e,{onlySelf:!0}))}),this._updateValue(),!1!==e.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(Object.assign({},e,{skipPristineCheck:t})),this._onDisabledChange.forEach(e=>e(!0))}enable(e={}){const t=this._parentMarkedDirty(e.onlySelf);this.status="VALID",this._forEachChild(t=>{t.enable(Object.assign({},e,{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent}),this._updateAncestors(Object.assign({},e,{skipPristineCheck:t})),this._onDisabledChange.forEach(e=>e(!1))}_updateAncestors(e){this._parent&&!e.onlySelf&&(this._parent.updateValueAndValidity(e),e.skipPristineCheck||this._parent._updatePristine(),this._parent._updateTouched())}setParent(e){this._parent=e}updateValueAndValidity(e={}){this._setInitialStatus(),this._updateValue(),this.enabled&&(this._cancelExistingSubscription(),this.errors=this._runValidator(),this.status=this._calculateStatus(),"VALID"!==this.status&&"PENDING"!==this.status||this._runAsyncValidator(e.emitEvent)),!1!==e.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!e.onlySelf&&this._parent.updateValueAndValidity(e)}_updateTreeValidity(e={emitEvent:!0}){this._forEachChild(t=>t._updateTreeValidity(e)),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?"DISABLED":"VALID"}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(e){if(this.asyncValidator){this.status="PENDING";const t=Vd(this.asyncValidator(this));this._asyncValidationSubscription=t.subscribe(t=>this.setErrors(t,{emitEvent:e}))}}_cancelExistingSubscription(){this._asyncValidationSubscription&&this._asyncValidationSubscription.unsubscribe()}setErrors(e,t={}){this.errors=e,this._updateControlsErrors(!1!==t.emitEvent)}get(e){return function(e,t,n){return null==t?null:(t instanceof Array||(t=t.split(".")),t instanceof Array&&0===t.length?null:t.reduce((e,t)=>e instanceof rp?e.controls.hasOwnProperty(t)?e.controls[t]:null:e instanceof sp&&e.at(t)||null,e))}(this,e)}getError(e,t){const n=t?this.get(t):this;return n&&n.errors?n.errors[e]:null}hasError(e,t){return!!this.getError(e,t)}get root(){let e=this;for(;e._parent;)e=e._parent;return e}_updateControlsErrors(e){this.status=this._calculateStatus(),e&&this.statusChanges.emit(this.status),this._parent&&this._parent._updateControlsErrors(e)}_initObservables(){this.valueChanges=new ms,this.statusChanges=new ms}_calculateStatus(){return this._allControlsDisabled()?"DISABLED":this.errors?"INVALID":this._anyControlsHaveStatus("PENDING")?"PENDING":this._anyControlsHaveStatus("INVALID")?"INVALID":"VALID"}_anyControlsHaveStatus(e){return this._anyControls(t=>t.status===e)}_anyControlsDirty(){return this._anyControls(e=>e.dirty)}_anyControlsTouched(){return this._anyControls(e=>e.touched)}_updatePristine(e={}){this.pristine=!this._anyControlsDirty(),this._parent&&!e.onlySelf&&this._parent._updatePristine(e)}_updateTouched(e={}){this.touched=this._anyControlsTouched(),this._parent&&!e.onlySelf&&this._parent._updateTouched(e)}_isBoxedValue(e){return"object"==typeof e&&null!==e&&2===Object.keys(e).length&&"value"in e&&"disabled"in e}_registerOnCollectionChange(e){this._onCollectionChange=e}_setUpdateStrategy(e){ep(e)&&null!=e.updateOn&&(this._updateOn=e.updateOn)}_parentMarkedDirty(e){return!e&&this._parent&&this._parent.dirty&&!this._parent._anyControlsDirty()}}class np extends tp{constructor(e=null,t,n){super(Jd(t),Xd(n,t)),this._onChange=[],this._applyFormState(e),this._setUpdateStrategy(t),this.updateValueAndValidity({onlySelf:!0,emitEvent:!1}),this._initObservables()}setValue(e,t={}){this.value=this._pendingValue=e,this._onChange.length&&!1!==t.emitModelToViewChange&&this._onChange.forEach(e=>e(this.value,!1!==t.emitViewToModelChange)),this.updateValueAndValidity(t)}patchValue(e,t={}){this.setValue(e,t)}reset(e=null,t={}){this._applyFormState(e),this.markAsPristine(t),this.markAsUntouched(t),this.setValue(this.value,t),this._pendingChange=!1}_updateValue(){}_anyControls(e){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(e){this._onChange.push(e)}_clearChangeFns(){this._onChange=[],this._onDisabledChange=[],this._onCollectionChange=()=>{}}registerOnDisabledChange(e){this._onDisabledChange.push(e)}_forEachChild(e){}_syncPendingControls(){return!("submit"!==this.updateOn||(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),!this._pendingChange)||(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),0))}_applyFormState(e){this._isBoxedValue(e)?(this.value=this._pendingValue=e.value,e.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=e}}class rp extends tp{constructor(e,t,n){super(Jd(t),Xd(n,t)),this.controls=e,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!1})}registerControl(e,t){return this.controls[e]?this.controls[e]:(this.controls[e]=t,t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange),t)}addControl(e,t){this.registerControl(e,t),this.updateValueAndValidity(),this._onCollectionChange()}removeControl(e){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],this.updateValueAndValidity(),this._onCollectionChange()}setControl(e,t){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],t&&this.registerControl(e,t),this.updateValueAndValidity(),this._onCollectionChange()}contains(e){return this.controls.hasOwnProperty(e)&&this.controls[e].enabled}setValue(e,t={}){this._checkAllValuesPresent(e),Object.keys(e).forEach(n=>{this._throwIfControlMissing(n),this.controls[n].setValue(e[n],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(e,t={}){Object.keys(e).forEach(n=>{this.controls[n]&&this.controls[n].patchValue(e[n],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}reset(e={},t={}){this._forEachChild((n,r)=>{n.reset(e[r],{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t),this._updateTouched(t),this.updateValueAndValidity(t)}getRawValue(){return this._reduceChildren({},(e,t,n)=>(e[n]=t instanceof np?t.value:t.getRawValue(),e))}_syncPendingControls(){let e=this._reduceChildren(!1,(e,t)=>!!t._syncPendingControls()||e);return e&&this.updateValueAndValidity({onlySelf:!0}),e}_throwIfControlMissing(e){if(!Object.keys(this.controls).length)throw new Error("\n There are no form controls registered with this group yet. If you're using ngModel,\n you may want to check next tick (e.g. use setTimeout).\n ");if(!this.controls[e])throw new Error(`Cannot find form control with name: ${e}.`)}_forEachChild(e){Object.keys(this.controls).forEach(t=>e(this.controls[t],t))}_setUpControls(){this._forEachChild(e=>{e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(e){let t=!1;return this._forEachChild((n,r)=>{t=t||this.contains(r)&&e(n)}),t}_reduceValue(){return this._reduceChildren({},(e,t,n)=>((t.enabled||this.disabled)&&(e[n]=t.value),e))}_reduceChildren(e,t){let n=e;return this._forEachChild((e,r)=>{n=t(n,e,r)}),n}_allControlsDisabled(){for(const e of Object.keys(this.controls))if(this.controls[e].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_checkAllValuesPresent(e){this._forEachChild((t,n)=>{if(void 0===e[n])throw new Error(`Must supply a value for form control with name: '${n}'.`)})}}class sp extends tp{constructor(e,t,n){super(Jd(t),Xd(n,t)),this.controls=e,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!1})}at(e){return this.controls[e]}push(e){this.controls.push(e),this._registerControl(e),this.updateValueAndValidity(),this._onCollectionChange()}insert(e,t){this.controls.splice(e,0,t),this._registerControl(t),this.updateValueAndValidity()}removeAt(e){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),this.controls.splice(e,1),this.updateValueAndValidity()}setControl(e,t){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),this.controls.splice(e,1),t&&(this.controls.splice(e,0,t),this._registerControl(t)),this.updateValueAndValidity(),this._onCollectionChange()}get length(){return this.controls.length}setValue(e,t={}){this._checkAllValuesPresent(e),e.forEach((e,n)=>{this._throwIfControlMissing(n),this.at(n).setValue(e,{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(e,t={}){e.forEach((e,n)=>{this.at(n)&&this.at(n).patchValue(e,{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}reset(e=[],t={}){this._forEachChild((n,r)=>{n.reset(e[r],{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t),this._updateTouched(t),this.updateValueAndValidity(t)}getRawValue(){return this.controls.map(e=>e instanceof np?e.value:e.getRawValue())}clear(){this.controls.length<1||(this._forEachChild(e=>e._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity())}_syncPendingControls(){let e=this.controls.reduce((e,t)=>!!t._syncPendingControls()||e,!1);return e&&this.updateValueAndValidity({onlySelf:!0}),e}_throwIfControlMissing(e){if(!this.controls.length)throw new Error("\n There are no form controls registered with this array yet. If you're using ngModel,\n you may want to check next tick (e.g. use setTimeout).\n ");if(!this.at(e))throw new Error(`Cannot find form control at index ${e}`)}_forEachChild(e){this.controls.forEach((t,n)=>{e(t,n)})}_updateValue(){this.value=this.controls.filter(e=>e.enabled||this.disabled).map(e=>e.value)}_anyControls(e){return this.controls.some(t=>t.enabled&&e(t))}_setUpControls(){this._forEachChild(e=>this._registerControl(e))}_checkAllValuesPresent(e){this._forEachChild((t,n)=>{if(void 0===e[n])throw new Error(`Must supply a value for form control at index: ${n}.`)})}_allControlsDisabled(){for(const e of this.controls)if(e.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(e){e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange)}}class lp extends Ed{ngOnInit(){this._checkParentType(),this.formDirective.addFormGroup(this)}ngOnDestroy(){this.formDirective&&this.formDirective.removeFormGroup(this)}get control(){return this.formDirective.getFormGroup(this)}get path(){return zd(this.name,this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}get validator(){return Qd(this._validators)}get asyncValidator(){return Kd(this._asyncValidators)}_checkParentType(){}}class ip{}const op=new Se("NgModelWithFormControlWarning");class ap extends Ed{constructor(e,t){super(),this._validators=e,this._asyncValidators=t,this.submitted=!1,this.directives=[],this.form=null,this.ngSubmit=new ms}ngOnChanges(e){this._checkFormPresent(),e.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations())}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(e){const t=this.form.get(e.path);return Bd(t,e),t.updateValueAndValidity({emitEvent:!1}),this.directives.push(e),t}getControl(e){return this.form.get(e.path)}removeControl(e){!function(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}(this.directives,e)}addFormGroup(e){const t=this.form.get(e.path);Gd(t,e),t.updateValueAndValidity({emitEvent:!1})}removeFormGroup(e){}getFormGroup(e){return this.form.get(e.path)}addFormArray(e){const t=this.form.get(e.path);Gd(t,e),t.updateValueAndValidity({emitEvent:!1})}removeFormArray(e){}getFormArray(e){return this.form.get(e.path)}updateModel(e,t){this.form.get(e.path).setValue(t)}onSubmit(e){return this.submitted=!0,t=this.directives,this.form._syncPendingControls(),t.forEach(e=>{const t=e.control;"submit"===t.updateOn&&t._pendingChange&&(e.viewToModelUpdate(t._pendingValue),t._pendingChange=!1)}),this.ngSubmit.emit(e),!1;var t}onReset(){this.resetForm()}resetForm(e){this.form.reset(e),this.submitted=!1}_updateDomValue(){this.directives.forEach(e=>{const t=this.form.get(e.path);e.control!==t&&(function(e,t){t.valueAccessor.registerOnChange(()=>Wd(t)),t.valueAccessor.registerOnTouched(()=>Wd(t)),t._rawValidators.forEach(e=>{e.registerOnValidatorChange&&e.registerOnValidatorChange(null)}),t._rawAsyncValidators.forEach(e=>{e.registerOnValidatorChange&&e.registerOnValidatorChange(null)}),e&&e._clearChangeFns()}(e.control,e),t&&Bd(t,e),e.control=t)}),this.form._updateTreeValidity({emitEvent:!1})}_updateRegistrations(){this.form._registerOnCollectionChange(()=>this._updateDomValue()),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{}),this._oldForm=this.form}_updateValidators(){const e=Qd(this._validators);this.form.validator=Nd.compose([this.form.validator,e]);const t=Kd(this._asyncValidators);this.form.asyncValidator=Nd.composeAsync([this.form.asyncValidator,t])}_checkFormPresent(){this.form||Hd.missingFormException()}}class up extends lp{constructor(e,t,n){super(),this._parent=e,this._validators=t,this._asyncValidators=n}_checkParentType(){hp(this._parent)&&Hd.groupParentException()}}class cp extends Ed{constructor(e,t,n){super(),this._parent=e,this._validators=t,this._asyncValidators=n}ngOnInit(){this._checkParentType(),this.formDirective.addFormArray(this)}ngOnDestroy(){this.formDirective&&this.formDirective.removeFormArray(this)}get control(){return this.formDirective.getFormArray(this)}get formDirective(){return this._parent?this._parent.formDirective:null}get path(){return zd(this.name,this._parent)}get validator(){return Qd(this._validators)}get asyncValidator(){return Kd(this._asyncValidators)}_checkParentType(){hp(this._parent)&&Hd.arrayParentException()}}function hp(e){return!(e instanceof up||e instanceof ap||e instanceof cp)}let dp=(()=>{class e extends kd{constructor(e,t,n,r,s){super(),this._ngModelWarningConfig=s,this._added=!1,this.update=new ms,this._ngModelWarningSent=!1,this._parent=e,this._rawValidators=t||[],this._rawAsyncValidators=n||[],this.valueAccessor=function(e,t){if(!t)return null;Array.isArray(t)||Zd(e,"Value accessor was not provided as an array for form control with");let n=void 0,r=void 0,s=void 0;return t.forEach(t=>{var l;t.constructor===xd?n=t:(l=t,Yd.some(e=>l.constructor===e)?(r&&Zd(e,"More than one built-in value accessor matches form control with"),r=t):(s&&Zd(e,"More than one custom value accessor matches form control with"),s=t))}),s||r||n||(Zd(e,"No valid value accessor for form control with"),null)}(this,r)}set isDisabled(e){Hd.disabledAttrWarning()}ngOnChanges(t){var n,r;this._added||this._setUpControl(),function(e,t){if(!e.hasOwnProperty("model"))return!1;const n=e.model;return!!n.isFirstChange()||!Vt(t,n.currentValue)}(t,this.viewModel)&&("formControlName",n=e,this,r=this._ngModelWarningConfig,Ge()&&"never"!==r&&((null!==r&&"once"!==r||n._ngModelWarningSentOnce)&&("always"!==r||this._ngModelWarningSent)||(Hd.ngModelWarning("formControlName"),n._ngModelWarningSentOnce=!0,this._ngModelWarningSent=!0)),this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}get path(){return zd(this.name,this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}get validator(){return Qd(this._rawValidators)}get asyncValidator(){return Kd(this._rawAsyncValidators)}_checkParentType(){!(this._parent instanceof up)&&this._parent instanceof lp?Hd.ngModelGroupException():this._parent instanceof up||this._parent instanceof ap||this._parent instanceof cp||Hd.controlParentException()}_setUpControl(){this._checkParentType(),this.control=this.formDirective.addControl(this),this.control.disabled&&this.valueAccessor.setDisabledState&&this.valueAccessor.setDisabledState(!0),this._added=!0}}return e._ngModelWarningSentOnce=!1,e})();class pp{}class gp{group(e,t=null){const n=this._reduceControls(e);let r=null,s=null,l=void 0;return null!=t&&(function(e){return void 0!==e.asyncValidators||void 0!==e.validators||void 0!==e.updateOn}(t)?(r=null!=t.validators?t.validators:null,s=null!=t.asyncValidators?t.asyncValidators:null,l=null!=t.updateOn?t.updateOn:void 0):(r=null!=t.validator?t.validator:null,s=null!=t.asyncValidator?t.asyncValidator:null)),new rp(n,{asyncValidators:s,updateOn:l,validators:r})}control(e,t,n){return new np(e,t,n)}array(e,t,n){const r=e.map(e=>this._createControl(e));return new sp(r,t,n)}_reduceControls(e){const t={};return Object.keys(e).forEach(n=>{t[n]=this._createControl(e[n])}),t}_createControl(e){return e instanceof np||e instanceof rp||e instanceof sp?e:Array.isArray(e)?this.control(e[0],e.length>1?e[1]:null,e.length>2?e[2]:null):this.control(e)}}class fp{static withConfig(e){return{ngModule:fp,providers:[{provide:op,useValue:e.warnOnNgModelWithFormControl}]}}}class mp{constructor(e,t,n,r,s){this.route=e,this.recipeService=t,this.location=n,this.fb=r,this.router=s,this.subscriptions=[]}ngOnInit(){this.createForm()}createForm(){this.recipeForm=this.fb.group({title:["",[Nd.required]],description:["",[Nd.required]],serves:["",[Nd.required]],imageUrl:["",[Nd.required]],instructions:this.fb.array([]),ingredients:this.fb.array([])}),this.instructions=this.recipeForm.get("instructions"),this.ingredients=this.recipeForm.get("ingredients")}createInstruction(e){return this.fb.group({step:[e,[Nd.required]]})}createIngredient(e,t){return this.fb.group({amount:[e,[Nd.required]],name:[t,[Nd.required]]})}addInstruction(){this.instructions.push(this.createInstruction(""))}addIngredient(){this.ingredients.push(this.createIngredient("",""))}deleteInstruction(e){this.recipeForm.controls.instructions.removeAt(e)}deleteIngredient(e){this.recipeForm.controls.ingredients.removeAt(e)}submitForm(){if(this.recipeForm.valid){const{title:e,description:t,serves:n,imageUrl:r,ingredients:s,instructions:l}=this.recipeForm.value,i=l.map(e=>e.step);this.recipeService.createRecipe(e,t,n,r,s,i),this.router.navigate([""])}}back(){this.location.back()}ngOnDestroy(){this.subscriptions.forEach(e=>e.unsubscribe())}}var vp=Ln({encapsulation:0,styles:[["h1[_ngcontent-%COMP%]{margin-top:1em;text-decoration:underline}h2[_ngcontent-%COMP%]{margin-top:2em;margin-bottom:1em}.main[_ngcontent-%COMP%]{background-color:#ececec;padding:1em;margin-top:2em}button[_ngcontent-%COMP%]{margin-right:1em;min-width:100px}button[_ngcontent-%COMP%]:last-child{margin-right:0}form[_ngcontent-%COMP%]{margin-top:1em}.back-and-save[_ngcontent-%COMP%]{margin-top:2em;margin-bottom:2em}input.ng-invalid[_ngcontent-%COMP%]{border:5px solid #a94442}"]],data:{}});function yp(e){return Hl(0,[(e()(),Il(0,0,null,null,18,"div",[],null,null,null,null,null)),(e()(),Il(1,0,null,null,17,"div",[["class","form-group w-100 title d-flex justify-content-center"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],null,null,null,null)),Qr(2,212992,null,0,up,[[3,Ed],[8,null],[8,null]],{name:[0,"name"]},null),Kr(2048,null,Ed,null,[up]),Qr(4,16384,null,0,Pd,[[4,Ed]],null,null),(e()(),Il(5,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(6,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(7,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(8,null,["",":"])),(e()(),Il(9,0,null,null,6,"div",[["class","col-6 d-flex align-items-center"]],null,null,null,null,null)),(e()(),Il(10,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","step"],["placeholder","Add an instruction..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,11)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,11).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,11)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,11)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(11,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(13,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(15,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(16,0,null,null,2,"div",[["class","col-1 d-flex align-items-center"]],null,null,null,null,null)),(e()(),Il(17,0,null,null,1,"button",[["class","btn btn-danger"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.deleteInstruction(e.context.index)&&r),r}),null,null)),(e()(),Fl(-1,null,[" Delete "]))],(function(e,t){e(t,2,0,t.context.index),e(t,13,0,"step")}),(function(e,t){e(t,1,0,Mr(t,4).ngClassUntouched,Mr(t,4).ngClassTouched,Mr(t,4).ngClassPristine,Mr(t,4).ngClassDirty,Mr(t,4).ngClassValid,Mr(t,4).ngClassInvalid,Mr(t,4).ngClassPending),e(t,8,0,t.context.index+1),e(t,10,0,Mr(t,15).ngClassUntouched,Mr(t,15).ngClassTouched,Mr(t,15).ngClassPristine,Mr(t,15).ngClassDirty,Mr(t,15).ngClassValid,Mr(t,15).ngClassInvalid,Mr(t,15).ngClassPending)}))}function _p(e){return Hl(0,[(e()(),Il(0,0,null,null,25,"div",[],null,null,null,null,null)),(e()(),Il(1,0,null,null,24,"div",[["class","form-group w-100 title d-flex justify-content-center"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],null,null,null,null)),Qr(2,212992,null,0,up,[[3,Ed],[8,null],[8,null]],{name:[0,"name"]},null),Kr(2048,null,Ed,null,[up]),Qr(4,16384,null,0,Pd,[[4,Ed]],null,null),(e()(),Il(5,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(6,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(7,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(8,null,["",":"])),(e()(),Il(9,0,null,null,6,"div",[["class","col-3"]],null,null,null,null,null)),(e()(),Il(10,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","amount"],["placeholder","Amount..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,11)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,11).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,11)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,11)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(11,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(13,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(15,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(16,0,null,null,6,"div",[["class","col-3"]],null,null,null,null,null)),(e()(),Il(17,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","name"],["placeholder","Name..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,18)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,18).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,18)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,18)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(18,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(20,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(22,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(23,0,null,null,2,"div",[["class","col-1 d-flex align-items-center"]],null,null,null,null,null)),(e()(),Il(24,0,null,null,1,"button",[["class","btn btn-danger"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.deleteIngredient(e.context.index)&&r),r}),null,null)),(e()(),Fl(-1,null,[" Delete "]))],(function(e,t){e(t,2,0,t.context.index),e(t,13,0,"amount"),e(t,20,0,"name")}),(function(e,t){e(t,1,0,Mr(t,4).ngClassUntouched,Mr(t,4).ngClassTouched,Mr(t,4).ngClassPristine,Mr(t,4).ngClassDirty,Mr(t,4).ngClassValid,Mr(t,4).ngClassInvalid,Mr(t,4).ngClassPending),e(t,8,0,t.context.index+1),e(t,10,0,Mr(t,15).ngClassUntouched,Mr(t,15).ngClassTouched,Mr(t,15).ngClassPristine,Mr(t,15).ngClassDirty,Mr(t,15).ngClassValid,Mr(t,15).ngClassInvalid,Mr(t,15).ngClassPending),e(t,17,0,Mr(t,22).ngClassUntouched,Mr(t,22).ngClassTouched,Mr(t,22).ngClassPristine,Mr(t,22).ngClassDirty,Mr(t,22).ngClassValid,Mr(t,22).ngClassInvalid,Mr(t,22).ngClassPending)}))}function wp(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"app-navbar",[],null,null,null,hd,cd)),Qr(1,114688,null,0,ud,[],null,null),(e()(),Il(2,0,null,null,101,"div",[["class","container"]],null,null,null,null,null)),(e()(),Il(3,0,null,null,4,"div",[["class","row d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(4,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(5,0,null,null,2,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(6,0,null,null,1,"h1",[["class","text-center"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Create Recipe"])),(e()(),Il(8,0,null,null,95,"form",[["novalidate",""]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"submit"],[null,"reset"]],(function(e,t,n){var r=!0;return"submit"===t&&(r=!1!==Mr(e,10).onSubmit(n)&&r),"reset"===t&&(r=!1!==Mr(e,10).onReset()&&r),r}),null,null)),Qr(9,16384,null,0,ip,[],null,null),Qr(10,540672,null,0,ap,[[8,null],[8,null]],{form:[0,"form"]},null),Kr(2048,null,Ed,null,[ap]),Qr(12,16384,null,0,Pd,[[4,Ed]],null,null),(e()(),Il(13,0,null,null,12,"div",[["class","form-group w-100 title d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(14,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(15,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(16,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Title:"])),(e()(),Il(18,0,null,null,6,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(19,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","title"],["placeholder","Title..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,20)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,20).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,20)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,20)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(20,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(22,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(24,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(25,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(26,0,null,null,12,"div",[["class","form-group w-100 title d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(27,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(28,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(29,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Description:"])),(e()(),Il(31,0,null,null,6,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(32,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","description"],["placeholder","Description..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,33)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,33).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,33)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,33)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(33,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(35,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(37,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(38,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(39,0,null,null,12,"div",[["class","form-group w-100 title d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(40,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(41,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(42,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Serves:"])),(e()(),Il(44,0,null,null,6,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(45,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","serves"],["placeholder","Serves..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,46)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,46).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,46)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,46)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(46,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(48,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(50,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(51,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(52,0,null,null,12,"div",[["class","form-group w-100 title d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(53,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(54,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(55,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Image Url:"])),(e()(),Il(57,0,null,null,6,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(58,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","imageUrl"],["placeholder","Image Url..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,59)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,59).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,59)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,59)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(59,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(61,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(63,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(64,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(65,0,null,null,15,"div",[["formArrayName","instructions"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],null,null,null,null)),Qr(66,212992,null,0,cp,[[3,Ed],[8,null],[8,null]],{name:[0,"name"]},null),Kr(2048,null,Ed,null,[cp]),Qr(68,16384,null,0,Pd,[[4,Ed]],null,null),(e()(),Il(69,0,null,null,4,"div",[["class","row d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(70,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(71,0,null,null,2,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(72,0,null,null,1,"h2",[["class","text-center"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Instructions"])),(e()(),Al(16777216,null,null,1,null,yp)),Qr(75,278528,null,0,co,[Sn,Cn,vn],{ngForOf:[0,"ngForOf"]},null),(e()(),Il(76,0,null,null,4,"div",[["class","w-100 d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(77,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(78,0,null,null,2,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(79,0,null,null,1,"button",[["class","btn btn-success w-100"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.addInstruction()&&r),r}),null,null)),(e()(),Fl(-1,null,[" Add "])),(e()(),Il(81,0,null,null,15,"div",[["formArrayName","ingredients"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],null,null,null,null)),Qr(82,212992,null,0,cp,[[3,Ed],[8,null],[8,null]],{name:[0,"name"]},null),Kr(2048,null,Ed,null,[cp]),Qr(84,16384,null,0,Pd,[[4,Ed]],null,null),(e()(),Il(85,0,null,null,4,"div",[["class","row d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(86,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(87,0,null,null,2,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(88,0,null,null,1,"h2",[["class","text-center"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Ingredients"])),(e()(),Al(16777216,null,null,1,null,_p)),Qr(91,278528,null,0,co,[Sn,Cn,vn],{ngForOf:[0,"ngForOf"]},null),(e()(),Il(92,0,null,null,4,"div",[["class","w-100 d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(93,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(94,0,null,null,2,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(95,0,null,null,1,"button",[["class","btn btn-success w-100"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.addIngredient()&&r),r}),null,null)),(e()(),Fl(-1,null,[" Add "])),(e()(),Il(97,0,null,null,6,"div",[["class","row d-flex justify-content-center back-and-save"]],null,null,null,null,null)),(e()(),Il(98,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(99,0,null,null,4,"div",[["class","col-6 d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(100,0,null,null,1,"button",[["class","btn btn-primary"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.back()&&r),r}),null,null)),(e()(),Fl(-1,null,[" Back "])),(e()(),Il(102,0,null,null,1,"button",[["class","btn btn-primary"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.submitForm()&&r),r}),null,null)),(e()(),Fl(-1,null,[" Save "]))],(function(e,t){var n=t.component;e(t,1,0),e(t,10,0,n.recipeForm),e(t,22,0,"title"),e(t,35,0,"description"),e(t,48,0,"serves"),e(t,61,0,"imageUrl"),e(t,66,0,"instructions"),e(t,75,0,n.recipeForm.get("instructions").controls),e(t,82,0,"ingredients"),e(t,91,0,n.recipeForm.get("ingredients").controls)}),(function(e,t){e(t,8,0,Mr(t,12).ngClassUntouched,Mr(t,12).ngClassTouched,Mr(t,12).ngClassPristine,Mr(t,12).ngClassDirty,Mr(t,12).ngClassValid,Mr(t,12).ngClassInvalid,Mr(t,12).ngClassPending),e(t,19,0,Mr(t,24).ngClassUntouched,Mr(t,24).ngClassTouched,Mr(t,24).ngClassPristine,Mr(t,24).ngClassDirty,Mr(t,24).ngClassValid,Mr(t,24).ngClassInvalid,Mr(t,24).ngClassPending),e(t,32,0,Mr(t,37).ngClassUntouched,Mr(t,37).ngClassTouched,Mr(t,37).ngClassPristine,Mr(t,37).ngClassDirty,Mr(t,37).ngClassValid,Mr(t,37).ngClassInvalid,Mr(t,37).ngClassPending),e(t,45,0,Mr(t,50).ngClassUntouched,Mr(t,50).ngClassTouched,Mr(t,50).ngClassPristine,Mr(t,50).ngClassDirty,Mr(t,50).ngClassValid,Mr(t,50).ngClassInvalid,Mr(t,50).ngClassPending),e(t,58,0,Mr(t,63).ngClassUntouched,Mr(t,63).ngClassTouched,Mr(t,63).ngClassPristine,Mr(t,63).ngClassDirty,Mr(t,63).ngClassValid,Mr(t,63).ngClassInvalid,Mr(t,63).ngClassPending),e(t,65,0,Mr(t,68).ngClassUntouched,Mr(t,68).ngClassTouched,Mr(t,68).ngClassPristine,Mr(t,68).ngClassDirty,Mr(t,68).ngClassValid,Mr(t,68).ngClassInvalid,Mr(t,68).ngClassPending),e(t,81,0,Mr(t,84).ngClassUntouched,Mr(t,84).ngClassTouched,Mr(t,84).ngClassPristine,Mr(t,84).ngClassDirty,Mr(t,84).ngClassValid,Mr(t,84).ngClassInvalid,Mr(t,84).ngClassPending)}))}function bp(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"app-new-recipe",[],null,null,null,wp,vp)),Qr(1,245760,null,0,mp,[bc,gd,to,gp,Oh],null,null)],(function(e,t){e(t,1,0)}),null)}var Cp=Er("app-new-recipe",mp,bp,{},{},[]);class xp{constructor(e,t,n,r,s){this.route=e,this.recipeService=t,this.location=n,this.fb=r,this.router=s,this.subscriptions=[]}ngOnInit(){this.subscriptions.push(this.route.paramMap.subscribe(e=>{const t=e.get("id");this.recipe=this.recipeService.getRecipeById(parseInt(t,10)),this.createForm()}))}createForm(){this.recipeForm=this.fb.group({title:[this.recipe.title,[Nd.required]],description:[this.recipe.description,[Nd.required]],serves:[this.recipe.serves,[Nd.required]],imageUrl:[this.recipe.imageUrl,[Nd.required]],instructions:this.fb.array([]),ingredients:this.fb.array([])}),this.instructions=this.recipeForm.get("instructions"),this.ingredients=this.recipeForm.get("ingredients"),this.recipe.instructions.forEach(e=>{this.instructions.push(this.createInstruction(e))}),this.recipe.ingredients.forEach(e=>{this.ingredients.push(this.createIngredient(e.amount,e.name))})}createInstruction(e){return this.fb.group({step:[e,[Nd.required]]})}createIngredient(e,t){return this.fb.group({amount:[e,[Nd.required]],name:[t,[Nd.required]]})}addInstruction(){this.instructions.push(this.createInstruction(""))}addIngredient(){this.ingredients.push(this.createIngredient("",""))}deleteInstruction(e){this.recipeForm.controls.instructions.removeAt(e)}deleteIngredient(e){this.recipeForm.controls.ingredients.removeAt(e)}submitForm(){if(this.recipeForm.valid){const{title:e,description:t,serves:n,imageUrl:r,ingredients:s,instructions:l}=this.recipeForm.value,i=l.map(e=>e.step);this.recipeService.updateRecipe({id:this.recipe.id,title:e,description:t,serves:n,imageUrl:r,ingredients:s,instructions:i}),this.router.navigate([`/recipes/${this.recipe.id}`])}}back(){this.location.back()}ngOnDestroy(){this.subscriptions.forEach(e=>e.unsubscribe())}}var Sp=Ln({encapsulation:0,styles:[[".header-image[_ngcontent-%COMP%]{width:100%;height:300px;-o-object-fit:cover;object-fit:cover}h1[_ngcontent-%COMP%]{margin-top:1em;text-decoration:underline}h2[_ngcontent-%COMP%]{margin-top:2em;margin-bottom:1em}.main[_ngcontent-%COMP%]{background-color:#ececec;padding:1em;margin-top:2em}button[_ngcontent-%COMP%]{margin-right:1em;min-width:100px}button[_ngcontent-%COMP%]:last-child{margin-right:0}form[_ngcontent-%COMP%]{margin-top:1em}.back-and-save[_ngcontent-%COMP%]{margin-top:2em;margin-bottom:2em}input.ng-invalid[_ngcontent-%COMP%]{border:5px solid #a94442}"]],data:{}});function Ep(e){return Hl(0,[(e()(),Il(0,0,null,null,18,"div",[],null,null,null,null,null)),(e()(),Il(1,0,null,null,17,"div",[["class","form-group w-100 title d-flex justify-content-center"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],null,null,null,null)),Qr(2,212992,null,0,up,[[3,Ed],[8,null],[8,null]],{name:[0,"name"]},null),Kr(2048,null,Ed,null,[up]),Qr(4,16384,null,0,Pd,[[4,Ed]],null,null),(e()(),Il(5,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(6,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(7,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(8,null,["",":"])),(e()(),Il(9,0,null,null,6,"div",[["class","col-6 d-flex align-items-center"]],null,null,null,null,null)),(e()(),Il(10,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","step"],["placeholder","Add an instruction..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,11)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,11).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,11)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,11)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(11,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(13,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(15,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(16,0,null,null,2,"div",[["class","col-1 d-flex align-items-center"]],null,null,null,null,null)),(e()(),Il(17,0,null,null,1,"button",[["class","btn btn-danger"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.deleteInstruction(e.context.index)&&r),r}),null,null)),(e()(),Fl(-1,null,[" Delete "]))],(function(e,t){e(t,2,0,t.context.index),e(t,13,0,"step")}),(function(e,t){e(t,1,0,Mr(t,4).ngClassUntouched,Mr(t,4).ngClassTouched,Mr(t,4).ngClassPristine,Mr(t,4).ngClassDirty,Mr(t,4).ngClassValid,Mr(t,4).ngClassInvalid,Mr(t,4).ngClassPending),e(t,8,0,t.context.index+1),e(t,10,0,Mr(t,15).ngClassUntouched,Mr(t,15).ngClassTouched,Mr(t,15).ngClassPristine,Mr(t,15).ngClassDirty,Mr(t,15).ngClassValid,Mr(t,15).ngClassInvalid,Mr(t,15).ngClassPending)}))}function Tp(e){return Hl(0,[(e()(),Il(0,0,null,null,25,"div",[],null,null,null,null,null)),(e()(),Il(1,0,null,null,24,"div",[["class","form-group w-100 title d-flex justify-content-center"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],null,null,null,null)),Qr(2,212992,null,0,up,[[3,Ed],[8,null],[8,null]],{name:[0,"name"]},null),Kr(2048,null,Ed,null,[up]),Qr(4,16384,null,0,Pd,[[4,Ed]],null,null),(e()(),Il(5,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(6,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(7,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(8,null,["",":"])),(e()(),Il(9,0,null,null,6,"div",[["class","col-3"]],null,null,null,null,null)),(e()(),Il(10,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","amount"],["placeholder","Amount..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,11)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,11).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,11)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,11)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(11,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(13,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(15,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(16,0,null,null,6,"div",[["class","col-3"]],null,null,null,null,null)),(e()(),Il(17,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","name"],["placeholder","Name..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,18)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,18).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,18)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,18)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(18,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(20,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(22,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(23,0,null,null,2,"div",[["class","col-1 d-flex align-items-center"]],null,null,null,null,null)),(e()(),Il(24,0,null,null,1,"button",[["class","btn btn-danger"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.deleteIngredient(e.context.index)&&r),r}),null,null)),(e()(),Fl(-1,null,[" Delete "]))],(function(e,t){e(t,2,0,t.context.index),e(t,13,0,"amount"),e(t,20,0,"name")}),(function(e,t){e(t,1,0,Mr(t,4).ngClassUntouched,Mr(t,4).ngClassTouched,Mr(t,4).ngClassPristine,Mr(t,4).ngClassDirty,Mr(t,4).ngClassValid,Mr(t,4).ngClassInvalid,Mr(t,4).ngClassPending),e(t,8,0,t.context.index+1),e(t,10,0,Mr(t,15).ngClassUntouched,Mr(t,15).ngClassTouched,Mr(t,15).ngClassPristine,Mr(t,15).ngClassDirty,Mr(t,15).ngClassValid,Mr(t,15).ngClassInvalid,Mr(t,15).ngClassPending),e(t,17,0,Mr(t,22).ngClassUntouched,Mr(t,22).ngClassTouched,Mr(t,22).ngClassPristine,Mr(t,22).ngClassDirty,Mr(t,22).ngClassValid,Mr(t,22).ngClassInvalid,Mr(t,22).ngClassPending)}))}function kp(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"app-navbar",[],null,null,null,hd,cd)),Qr(1,114688,null,0,ud,[],null,null),(e()(),Il(2,0,null,null,0,"img",[["class","header-image"]],[[8,"src",4],[8,"alt",0]],null,null,null,null)),(e()(),Il(3,0,null,null,101,"div",[["class","container"]],null,null,null,null,null)),(e()(),Il(4,0,null,null,4,"div",[["class","row d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(5,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(6,0,null,null,2,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(7,0,null,null,1,"h1",[["class","text-center"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Edit Recipe"])),(e()(),Il(9,0,null,null,95,"form",[["novalidate",""]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"submit"],[null,"reset"]],(function(e,t,n){var r=!0;return"submit"===t&&(r=!1!==Mr(e,11).onSubmit(n)&&r),"reset"===t&&(r=!1!==Mr(e,11).onReset()&&r),r}),null,null)),Qr(10,16384,null,0,ip,[],null,null),Qr(11,540672,null,0,ap,[[8,null],[8,null]],{form:[0,"form"]},null),Kr(2048,null,Ed,null,[ap]),Qr(13,16384,null,0,Pd,[[4,Ed]],null,null),(e()(),Il(14,0,null,null,12,"div",[["class","form-group w-100 title d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(15,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(16,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(17,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Title:"])),(e()(),Il(19,0,null,null,6,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(20,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","title"],["placeholder","Title..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,21)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,21).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,21)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,21)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(21,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(23,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(25,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(26,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(27,0,null,null,12,"div",[["class","form-group w-100 title d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(28,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(29,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(30,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Description:"])),(e()(),Il(32,0,null,null,6,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(33,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","description"],["placeholder","Description..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,34)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,34).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,34)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,34)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(34,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(36,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(38,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(39,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(40,0,null,null,12,"div",[["class","form-group w-100 title d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(41,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(42,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(43,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Serves:"])),(e()(),Il(45,0,null,null,6,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(46,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","serves"],["placeholder","Serves..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,47)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,47).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,47)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,47)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(47,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(49,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(51,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(52,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(53,0,null,null,12,"div",[["class","form-group w-100 title d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(54,0,null,null,3,"div",[["class","col-2 d-flex justify-content-end align-items-center"]],null,null,null,null,null)),(e()(),Il(55,0,null,null,2,"label",[["class","mb-0"]],null,null,null,null,null)),(e()(),Il(56,0,null,null,1,"h4",[["class","mb-0"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Image Url:"])),(e()(),Il(58,0,null,null,6,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(59,0,null,null,5,"input",[["class","form-control w-100"],["formControlName","imageUrl"],["placeholder","Image Url..."],["type","text"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],[[null,"input"],[null,"blur"],[null,"compositionstart"],[null,"compositionend"]],(function(e,t,n){var r=!0;return"input"===t&&(r=!1!==Mr(e,60)._handleInput(n.target.value)&&r),"blur"===t&&(r=!1!==Mr(e,60).onTouched()&&r),"compositionstart"===t&&(r=!1!==Mr(e,60)._compositionStart()&&r),"compositionend"===t&&(r=!1!==Mr(e,60)._compositionEnd(n.target.value)&&r),r}),null,null)),Qr(60,16384,null,0,xd,[nn,Yt,[2,Cd]],null,null),Kr(1024,null,bd,(function(e){return[e]}),[xd]),Qr(62,671744,null,0,dp,[[3,Ed],[8,null],[8,null],[6,bd],[2,op]],{name:[0,"name"]},null),Kr(2048,null,kd,null,[dp]),Qr(64,16384,null,0,Id,[[4,kd]],null,null),(e()(),Il(65,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(66,0,null,null,15,"div",[["formArrayName","instructions"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],null,null,null,null)),Qr(67,212992,null,0,cp,[[3,Ed],[8,null],[8,null]],{name:[0,"name"]},null),Kr(2048,null,Ed,null,[cp]),Qr(69,16384,null,0,Pd,[[4,Ed]],null,null),(e()(),Il(70,0,null,null,4,"div",[["class","row d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(71,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(72,0,null,null,2,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(73,0,null,null,1,"h2",[["class","text-center"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Instructions"])),(e()(),Al(16777216,null,null,1,null,Ep)),Qr(76,278528,null,0,co,[Sn,Cn,vn],{ngForOf:[0,"ngForOf"]},null),(e()(),Il(77,0,null,null,4,"div",[["class","w-100 d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(78,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(79,0,null,null,2,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(80,0,null,null,1,"button",[["class","btn btn-success w-100"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.addInstruction()&&r),r}),null,null)),(e()(),Fl(-1,null,[" Add "])),(e()(),Il(82,0,null,null,15,"div",[["formArrayName","ingredients"]],[[2,"ng-untouched",null],[2,"ng-touched",null],[2,"ng-pristine",null],[2,"ng-dirty",null],[2,"ng-valid",null],[2,"ng-invalid",null],[2,"ng-pending",null]],null,null,null,null)),Qr(83,212992,null,0,cp,[[3,Ed],[8,null],[8,null]],{name:[0,"name"]},null),Kr(2048,null,Ed,null,[cp]),Qr(85,16384,null,0,Pd,[[4,Ed]],null,null),(e()(),Il(86,0,null,null,4,"div",[["class","row d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(87,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(88,0,null,null,2,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(89,0,null,null,1,"h2",[["class","text-center"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Ingredients"])),(e()(),Al(16777216,null,null,1,null,Tp)),Qr(92,278528,null,0,co,[Sn,Cn,vn],{ngForOf:[0,"ngForOf"]},null),(e()(),Il(93,0,null,null,4,"div",[["class","w-100 d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(94,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(95,0,null,null,2,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(96,0,null,null,1,"button",[["class","btn btn-success w-100"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.addIngredient()&&r),r}),null,null)),(e()(),Fl(-1,null,[" Add "])),(e()(),Il(98,0,null,null,6,"div",[["class","row d-flex justify-content-center back-and-save"]],null,null,null,null,null)),(e()(),Il(99,0,null,null,0,"div",[["class","col-1"]],null,null,null,null,null)),(e()(),Il(100,0,null,null,4,"div",[["class","col-6 d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(101,0,null,null,1,"button",[["class","btn btn-primary"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.back()&&r),r}),null,null)),(e()(),Fl(-1,null,[" Back "])),(e()(),Il(103,0,null,null,1,"button",[["class","btn btn-primary"],["type","button"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.submitForm()&&r),r}),null,null)),(e()(),Fl(-1,null,[" Save "]))],(function(e,t){var n=t.component;e(t,1,0),e(t,11,0,n.recipeForm),e(t,23,0,"title"),e(t,36,0,"description"),e(t,49,0,"serves"),e(t,62,0,"imageUrl"),e(t,67,0,"instructions"),e(t,76,0,n.recipeForm.get("instructions").controls),e(t,83,0,"ingredients"),e(t,92,0,n.recipeForm.get("ingredients").controls)}),(function(e,t){var n=t.component;e(t,2,0,n.recipe.imageUrl,n.recipe.title),e(t,9,0,Mr(t,13).ngClassUntouched,Mr(t,13).ngClassTouched,Mr(t,13).ngClassPristine,Mr(t,13).ngClassDirty,Mr(t,13).ngClassValid,Mr(t,13).ngClassInvalid,Mr(t,13).ngClassPending),e(t,20,0,Mr(t,25).ngClassUntouched,Mr(t,25).ngClassTouched,Mr(t,25).ngClassPristine,Mr(t,25).ngClassDirty,Mr(t,25).ngClassValid,Mr(t,25).ngClassInvalid,Mr(t,25).ngClassPending),e(t,33,0,Mr(t,38).ngClassUntouched,Mr(t,38).ngClassTouched,Mr(t,38).ngClassPristine,Mr(t,38).ngClassDirty,Mr(t,38).ngClassValid,Mr(t,38).ngClassInvalid,Mr(t,38).ngClassPending),e(t,46,0,Mr(t,51).ngClassUntouched,Mr(t,51).ngClassTouched,Mr(t,51).ngClassPristine,Mr(t,51).ngClassDirty,Mr(t,51).ngClassValid,Mr(t,51).ngClassInvalid,Mr(t,51).ngClassPending),e(t,59,0,Mr(t,64).ngClassUntouched,Mr(t,64).ngClassTouched,Mr(t,64).ngClassPristine,Mr(t,64).ngClassDirty,Mr(t,64).ngClassValid,Mr(t,64).ngClassInvalid,Mr(t,64).ngClassPending),e(t,66,0,Mr(t,69).ngClassUntouched,Mr(t,69).ngClassTouched,Mr(t,69).ngClassPristine,Mr(t,69).ngClassDirty,Mr(t,69).ngClassValid,Mr(t,69).ngClassInvalid,Mr(t,69).ngClassPending),e(t,82,0,Mr(t,85).ngClassUntouched,Mr(t,85).ngClassTouched,Mr(t,85).ngClassPristine,Mr(t,85).ngClassDirty,Mr(t,85).ngClassValid,Mr(t,85).ngClassInvalid,Mr(t,85).ngClassPending)}))}function Ap(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"app-edit-recipe",[],null,null,null,kp,Sp)),Qr(1,245760,null,0,xp,[bc,gd,to,gp,Oh],null,null)],(function(e,t){e(t,1,0)}),null)}var Ip=Er("app-edit-recipe",xp,Ap,{},{},[]);class Pp{constructor(e,t,n,r){this.route=e,this.router=t,this.recipeService=n,this.location=r,this.subscriptions=[]}ngOnInit(){this.subscriptions.push(this.route.paramMap.subscribe(e=>{const t=e.get("id");this.recipe=this.recipeService.getRecipeById(parseInt(t,10))}))}ngOnDestroy(){this.subscriptions.forEach(e=>e.unsubscribe())}back(){this.location.back()}deleteRecipe(){this.recipeService.deleteRecipe(this.recipe.id),this.router.navigate([""])}}var Op=Ln({encapsulation:0,styles:[[".header-image[_ngcontent-%COMP%]{width:100%;height:300px;-o-object-fit:cover;object-fit:cover}h1[_ngcontent-%COMP%]{margin-top:1em;text-decoration:underline}h2[_ngcontent-%COMP%]{margin-bottom:1em}.main[_ngcontent-%COMP%]{background-color:#ececec;padding:1em;margin-top:2em}button[_ngcontent-%COMP%]{margin-top:1em;margin-right:1em;min-width:100px}.back-and-edit[_ngcontent-%COMP%], .container[_ngcontent-%COMP%]{margin-bottom:2em}"]],data:{}});function Rp(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"div",[],null,null,null,null,null)),(e()(),Fl(1,null,[" "," - "," "]))],null,(function(e,t){e(t,1,0,t.context.$implicit.amount,t.context.$implicit.name)}))}function Np(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"li",[],null,null,null,null,null)),(e()(),Fl(1,null,[" "," "]))],null,(function(e,t){e(t,1,0,t.context.$implicit)}))}function Dp(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"app-navbar",[],null,null,null,hd,cd)),Qr(1,114688,null,0,ud,[],null,null),(e()(),Il(2,0,null,null,0,"img",[["class","header-image"]],[[8,"src",4],[8,"alt",0]],null,null,null,null)),(e()(),Il(3,0,null,null,35,"div",[["class","container"]],null,null,null,null,null)),(e()(),Il(4,0,null,null,2,"div",[["class","row w-100 d-flex justify-content-end"]],null,null,null,null,null)),(e()(),Il(5,0,null,null,1,"button",[["class","btn btn-danger"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.deleteRecipe()&&r),r}),null,null)),(e()(),Fl(-1,null,["Delete"])),(e()(),Il(7,0,null,null,5,"div",[["class","row d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(8,0,null,null,4,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(9,0,null,null,1,"h1",[["class","text-center"]],null,null,null,null,null)),(e()(),Fl(10,null,["",""])),(e()(),Il(11,0,null,null,1,"p",[["class","text-center"]],null,null,null,null,null)),(e()(),Fl(12,null,["",""])),(e()(),Il(13,0,null,null,25,"div",[["class","main"]],null,null,null,null,null)),(e()(),Il(14,0,null,null,6,"div",[["class","row d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(15,0,null,null,5,"div",[["class","col-12 text-center"]],null,null,null,null,null)),(e()(),Il(16,0,null,null,3,"h3",[],null,null,null,null,null)),(e()(),Fl(-1,null,[" Serves: "])),(e()(),Il(18,0,null,null,1,"span",[["class","serves"]],null,null,null,null,null)),(e()(),Fl(19,null,["",""])),(e()(),Il(20,0,null,null,0,"hr",[],null,null,null,null,null)),(e()(),Il(21,0,null,null,11,"div",[["class","row d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(22,0,null,null,4,"div",[["class","col-4 text-center"]],null,null,null,null,null)),(e()(),Il(23,0,null,null,1,"h3",[],null,null,null,null,null)),(e()(),Fl(-1,null,["Ingredients"])),(e()(),Al(16777216,null,null,1,null,Rp)),Qr(26,278528,null,0,co,[Sn,Cn,vn],{ngForOf:[0,"ngForOf"]},null),(e()(),Il(27,0,null,null,5,"div",[["class","col-6"]],null,null,null,null,null)),(e()(),Il(28,0,null,null,1,"h3",[["class","text-center"]],null,null,null,null,null)),(e()(),Fl(-1,null,["Instructions"])),(e()(),Il(30,0,null,null,2,"ol",[],null,null,null,null,null)),(e()(),Al(16777216,null,null,1,null,Np)),Qr(32,278528,null,0,co,[Sn,Cn,vn],{ngForOf:[0,"ngForOf"]},null),(e()(),Il(33,0,null,null,5,"div",[["class","row back-and-edit d-flex justify-content-center"]],null,null,null,null,null)),(e()(),Il(34,0,null,null,1,"button",[["class","btn btn-primary"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==e.component.back()&&r),r}),null,null)),(e()(),Fl(-1,null,["Back"])),(e()(),Il(36,0,null,null,2,"button",[["class","btn btn-primary"]],null,[[null,"click"]],(function(e,t,n){var r=!0;return"click"===t&&(r=!1!==Mr(e,37).onClick()&&r),r}),null,null)),Qr(37,16384,null,0,Rh,[Oh,bc,[8,null],nn,Yt],{routerLink:[0,"routerLink"]},null),(e()(),Fl(-1,null,[" Edit "]))],(function(e,t){var n=t.component;e(t,1,0),e(t,26,0,n.recipe.ingredients),e(t,32,0,n.recipe.instructions),e(t,37,0,dr(1,"/recipes/edit/",n.recipe.id,""))}),(function(e,t){var n=t.component;e(t,2,0,n.recipe.imageUrl,n.recipe.title),e(t,10,0,n.recipe.title),e(t,12,0,n.recipe.description),e(t,19,0,n.recipe.serves)}))}function Vp(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"app-show-recipe",[],null,null,null,Dp,Op)),Qr(1,245760,null,0,Pp,[bc,Oh,gd,to],null,null)],(function(e,t){e(t,1,0)}),null)}var Mp=Er("app-show-recipe",Pp,Vp,{},{},[]),Up=Ln({encapsulation:0,styles:[[""]],data:{}});function jp(e){return Hl(0,[(e()(),Il(0,16777216,null,null,1,"router-outlet",[],null,null,null,null,null)),Qr(1,212992,null,0,Uh,[Mh,Sn,Wt,[8,null],wt],null,null)],(function(e,t){e(t,1,0)}),null)}function Fp(e){return Hl(0,[(e()(),Il(0,0,null,null,1,"app-root",[],null,null,null,jp,Up)),Qr(1,49152,null,0,Ki,[],null,null)],null,null)}var Lp=Er("app-root",Ki,Fp,{},{},[]);class $p{}var Hp=Wi(Qi,[Ki],(function(e){return function(e){const t={},n=[];let r=!1;for(let s=0;s<e.length;s++){const l=e[s];l.token===Ct&&!0===l.value&&(r=!0),1073741824&l.flags&&n.push(l.token),l.index=s,t[Fn(l.token)]=l}return{factory:null,providersByKey:t,providers:e,modules:n,isRoot:r}}([yr(512,Wt,Zt,[[8,[ad,_d,Cp,Ip,Mp,Lp]],[3,Wt],De]),yr(5120,As,El,[[3,As]]),yr(4608,oo,ao,[As,[2,io]]),yr(5120,hs,Tl,[qs]),yr(5120,bs,Cs,[]),yr(5120,vn,xl,[]),yr(5120,yn,Sl,[]),yr(4608,su,lu,[go]),yr(6144,ft,null,[su]),yr(4608,Ya,Xa,[]),yr(5120,Ta,(function(e,t,n,r,s,l,i,o){return[new Qa(e,t,n),new ru(r),new eu(s,l,i,o)]}),[go,qs,Es,go,go,Ya,ks,[2,Ja]]),yr(4608,ka,ka,[Ta,qs]),yr(135680,Pa,Pa,[go]),yr(4608,Va,Va,[ka,Pa,bs]),yr(6144,en,null,[Va]),yr(6144,Ia,null,[Pa]),yr(4608,Js,Js,[qs]),yr(5120,bc,ed,[Oh]),yr(4608,$h,$h,[]),yr(6144,Fh,null,[$h]),yr(135680,Hh,Hh,[Oh,hl,Ds,St,Fh]),yr(4608,Lh,Lh,[]),yr(5120,zh,Qh,[Oh,fo,Bh]),yr(5120,sd,rd,[td]),yr(5120,Ts,(function(e){return[e]}),[sd]),yr(4608,gp,gp,[]),yr(4608,Fd,Fd,[]),yr(4608,gd,gd,[]),yr(1073742336,po,po,[]),yr(1024,ze,pu,[]),yr(1024,sl,(function(){return[Wh()]}),[]),yr(512,td,td,[St]),yr(1024,_s,(function(e,t){return[(n=e,xa("probe",Ea),xa("coreTokens",Object.assign({},Sa,(n||[]).reduce((e,t)=>(e[t.name]=t.token,e),{}))),()=>Ea),nd(t)];var n}),[[2,sl],td]),yr(512,ws,ws,[[2,_s]]),yr(131584,ul,ul,[qs,ks,St,ze,Wt,ws]),yr(1073742336,kl,kl,[ul]),yr(1073742336,gu,gu,[[3,gu]]),yr(1024,qh,Yh,[[3,Oh]]),yr(512,Xu,ec,[]),yr(512,Mh,Mh,[]),yr(256,Bh,{},[]),yr(1024,Xi,Kh,[Yi,[2,eo],Bh]),yr(512,to,to,[Xi,Yi]),yr(512,Ds,Ds,[]),yr(512,hl,gl,[Ds,[2,dl]]),yr(1024,Sh,(function(){return[[{path:"",component:dd},{path:"recipes",component:dd},{path:"recipes/new",component:mp},{path:"recipes/edit/:id",component:xp},{path:"recipes/:id",component:Pp},{path:"**",component:dd}]]}),[]),yr(1024,Oh,Xh,[ul,Xu,Mh,to,St,hl,Ds,Sh,Bh,[2,Th],[2,Ch]]),yr(1073742336,Zh,Zh,[[2,qh],[2,Oh]]),yr(1073742336,$p,$p,[]),yr(1073742336,pp,pp,[]),yr(1073742336,fp,fp,[]),yr(1073742336,Qi,Qi,[]),yr(256,Ct,!0,[])])}));(function(){if(qe)throw new Error("Cannot enable prod mode after platform setup.");Be=!1})(),du().bootstrapModuleFactory(Hp).catch(e=>console.error(e))},zn8P:function(e,t){function n(e){return Promise.resolve().then((function(){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}))}n.keys=function(){return[]},n.resolve=n,e.exports=n,n.id="zn8P"}},[[0,0]]]);