UNPKG

homebridge-gsh

Version:
1 lines 210 kB
"use strict";(self.webpackChunkpublic=self.webpackChunkpublic||[]).push([[179],{450:(Do,ls,vo)=>{function le(e){return"function"==typeof e}function Uu(e){const n=e(r=>{Error.call(r),r.stack=(new Error).stack});return n.prototype=Object.create(Error.prototype),n.prototype.constructor=n,n}const us=Uu(e=>function(n){e(this),this.message=n?`${n.length} errors occurred during unsubscription:\n${n.map((r,o)=>`${o+1}) ${r.toString()}`).join("\n  ")}`:"",this.name="UnsubscriptionError",this.errors=n});function cs(e,t){if(e){const n=e.indexOf(t);0<=n&&e.splice(n,1)}}class wt{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:n}=this;if(n)if(this._parentage=null,Array.isArray(n))for(const i of n)i.remove(this);else n.remove(this);const{initialTeardown:r}=this;if(le(r))try{r()}catch(i){t=i instanceof us?i.errors:[i]}const{_finalizers:o}=this;if(o){this._finalizers=null;for(const i of o)try{qu(i)}catch(s){t=t??[],s instanceof us?t=[...t,...s.errors]:t.push(s)}}if(t)throw new us(t)}}add(t){var n;if(t&&t!==this)if(this.closed)qu(t);else{if(t instanceof wt){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(n=this._finalizers)&&void 0!==n?n:[]).push(t)}}_hasParent(t){const{_parentage:n}=this;return n===t||Array.isArray(n)&&n.includes(t)}_addParent(t){const{_parentage:n}=this;this._parentage=Array.isArray(n)?(n.push(t),n):n?[n,t]:t}_removeParent(t){const{_parentage:n}=this;n===t?this._parentage=null:Array.isArray(n)&&cs(n,t)}remove(t){const{_finalizers:n}=this;n&&cs(n,t),t instanceof wt&&t._removeParent(this)}}wt.EMPTY=(()=>{const e=new wt;return e.closed=!0,e})();const zu=wt.EMPTY;function Gu(e){return e instanceof wt||e&&"closed"in e&&le(e.remove)&&le(e.add)&&le(e.unsubscribe)}function qu(e){le(e)?e():e.unsubscribe()}const un={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},wo={setTimeout(e,t,...n){const{delegate:r}=wo;return r?.setTimeout?r.setTimeout(e,t,...n):setTimeout(e,t,...n)},clearTimeout(e){const{delegate:t}=wo;return(t?.clearTimeout||clearTimeout)(e)},delegate:void 0};function Wu(e){wo.setTimeout(()=>{const{onUnhandledError:t}=un;if(!t)throw e;t(e)})}function Zu(){}const Iy=ds("C",void 0,void 0);function ds(e,t,n){return{kind:e,value:t,error:n}}let cn=null;function _o(e){if(un.useDeprecatedSynchronousErrorHandling){const t=!cn;if(t&&(cn={errorThrown:!1,error:null}),e(),t){const{errorThrown:n,error:r}=cn;if(cn=null,n)throw r}}else e()}class fs extends wt{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Gu(t)&&t.add(this)):this.destination=Py}static create(t,n,r){return new yr(t,n,r)}next(t){this.isStopped?hs(function Ty(e){return ds("N",e,void 0)}(t),this):this._next(t)}error(t){this.isStopped?hs(function Sy(e){return ds("E",void 0,e)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?hs(Iy,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const xy=Function.prototype.bind;function ps(e,t){return xy.call(e,t)}class ky{constructor(t){this.partialObserver=t}next(t){const{partialObserver:n}=this;if(n.next)try{n.next(t)}catch(r){bo(r)}}error(t){const{partialObserver:n}=this;if(n.error)try{n.error(t)}catch(r){bo(r)}else bo(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(n){bo(n)}}}class yr extends fs{constructor(t,n,r){let o;if(super(),le(t)||!t)o={next:t??void 0,error:n??void 0,complete:r??void 0};else{let i;this&&un.useDeprecatedNextContext?(i=Object.create(t),i.unsubscribe=()=>this.unsubscribe(),o={next:t.next&&ps(t.next,i),error:t.error&&ps(t.error,i),complete:t.complete&&ps(t.complete,i)}):o=t}this.destination=new ky(o)}}function bo(e){un.useDeprecatedSynchronousErrorHandling?function My(e){un.useDeprecatedSynchronousErrorHandling&&cn&&(cn.errorThrown=!0,cn.error=e)}(e):Wu(e)}function hs(e,t){const{onStoppedNotification:n}=un;n&&wo.setTimeout(()=>n(e,t))}const Py={closed:!0,next:Zu,error:function Ay(e){throw e},complete:Zu},gs="function"==typeof Symbol&&Symbol.observable||"@@observable";function Ju(e){return e}let Ie=(()=>{class e{constructor(n){n&&(this._subscribe=n)}lift(n){const r=new e;return r.source=this,r.operator=n,r}subscribe(n,r,o){const i=function Ry(e){return e&&e instanceof fs||function Ny(e){return e&&le(e.next)&&le(e.error)&&le(e.complete)}(e)&&Gu(e)}(n)?n:new yr(n,r,o);return _o(()=>{const{operator:s,source:a}=this;i.add(s?s.call(i,a):a?this._subscribe(i):this._trySubscribe(i))}),i}_trySubscribe(n){try{return this._subscribe(n)}catch(r){n.error(r)}}forEach(n,r){return new(r=Qu(r))((o,i)=>{const s=new yr({next:a=>{try{n(a)}catch(l){i(l),s.unsubscribe()}},error:i,complete:o});this.subscribe(s)})}_subscribe(n){var r;return null===(r=this.source)||void 0===r?void 0:r.subscribe(n)}[gs](){return this}pipe(...n){return function Ku(e){return 0===e.length?Ju:1===e.length?e[0]:function(n){return e.reduce((r,o)=>o(r),n)}}(n)(this)}toPromise(n){return new(n=Qu(n))((r,o)=>{let i;this.subscribe(s=>i=s,s=>o(s),()=>r(i))})}}return e.create=t=>new e(t),e})();function Qu(e){var t;return null!==(t=e??un.Promise)&&void 0!==t?t:Promise}const Fy=Uu(e=>function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let ms=(()=>{class e extends Ie{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(n){const r=new Yu(this,this);return r.operator=n,r}_throwIfClosed(){if(this.closed)throw new Fy}next(n){_o(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const r of this.currentObservers)r.next(n)}})}error(n){_o(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=n;const{observers:r}=this;for(;r.length;)r.shift().error(n)}})}complete(){_o(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:n}=this;for(;n.length;)n.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var n;return(null===(n=this.observers)||void 0===n?void 0:n.length)>0}_trySubscribe(n){return this._throwIfClosed(),super._trySubscribe(n)}_subscribe(n){return this._throwIfClosed(),this._checkFinalizedStatuses(n),this._innerSubscribe(n)}_innerSubscribe(n){const{hasError:r,isStopped:o,observers:i}=this;return r||o?zu:(this.currentObservers=null,i.push(n),new wt(()=>{this.currentObservers=null,cs(i,n)}))}_checkFinalizedStatuses(n){const{hasError:r,thrownError:o,isStopped:i}=this;r?n.error(o):i&&n.complete()}asObservable(){const n=new Ie;return n.source=this,n}}return e.create=(t,n)=>new Yu(t,n),e})();class Yu extends ms{constructor(t,n){super(),this.destination=t,this.source=n}next(t){var n,r;null===(r=null===(n=this.destination)||void 0===n?void 0:n.next)||void 0===r||r.call(n,t)}error(t){var n,r;null===(r=null===(n=this.destination)||void 0===n?void 0:n.error)||void 0===r||r.call(n,t)}complete(){var t,n;null===(n=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===n||n.call(t)}_subscribe(t){var n,r;return null!==(r=null===(n=this.source)||void 0===n?void 0:n.subscribe(t))&&void 0!==r?r:zu}}function Mn(e){return t=>{if(function Oy(e){return le(e?.lift)}(t))return t.lift(function(n){try{return e(n,this)}catch(r){this.error(r)}});throw new TypeError("Unable to lift unknown Observable type")}}function Dr(e,t,n,r,o){return new Ly(e,t,n,r,o)}class Ly extends fs{constructor(t,n,r,o,i,s){super(t),this.onFinalize=i,this.shouldUnsubscribe=s,this._next=n?function(a){try{n(a)}catch(l){t.error(l)}}:super._next,this._error=o?function(a){try{o(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=r?function(){try{r()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:n}=this;super.unsubscribe(),!n&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function xn(e,t){return Mn((n,r)=>{let o=0;n.subscribe(Dr(r,i=>{r.next(e.call(t,i,o++))}))})}function Kt(e){return this instanceof Kt?(this.v=e,this):new Kt(e)}function nc(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n,t=e[Symbol.asyncIterator];return t?t.call(e):(e=function ws(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(i){n[i]=e[i]&&function(s){return new Promise(function(a,l){!function o(i,s,a,l){Promise.resolve(l).then(function(u){i({value:u,done:a})},s)}(a,l,(s=e[i](s)).done,s.value)})}}}"function"==typeof SuppressedError&&SuppressedError;const rc=e=>e&&"number"==typeof e.length&&"function"!=typeof e;function oc(e){return le(e?.then)}function ic(e){return le(e[gs])}function sc(e){return Symbol.asyncIterator&&le(e?.[Symbol.asyncIterator])}function ac(e){return new TypeError(`You provided ${null!==e&&"object"==typeof e?"an invalid object":`'${e}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}const lc=function cD(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}();function uc(e){return le(e?.[lc])}function cc(e){return function tc(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var o,r=n.apply(e,t||[]),i=[];return o=Object.create(("function"==typeof AsyncIterator?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",function s(f){return function(h){return Promise.resolve(h).then(f,d)}}),o[Symbol.asyncIterator]=function(){return this},o;function a(f,h){r[f]&&(o[f]=function(g){return new Promise(function(m,D){i.push([f,g,m,D])>1||l(f,g)})},h&&(o[f]=h(o[f])))}function l(f,h){try{!function u(f){f.value instanceof Kt?Promise.resolve(f.value.v).then(c,d):p(i[0][2],f)}(r[f](h))}catch(g){p(i[0][3],g)}}function c(f){l("next",f)}function d(f){l("throw",f)}function p(f,h){f(h),i.shift(),i.length&&l(i[0][0],i[0][1])}}(this,arguments,function*(){const n=e.getReader();try{for(;;){const{value:r,done:o}=yield Kt(n.read());if(o)return yield Kt(void 0);yield yield Kt(r)}}finally{n.releaseLock()}})}function dc(e){return le(e?.getReader)}function Qt(e){if(e instanceof Ie)return e;if(null!=e){if(ic(e))return function dD(e){return new Ie(t=>{const n=e[gs]();if(le(n.subscribe))return n.subscribe(t);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}(e);if(rc(e))return function fD(e){return new Ie(t=>{for(let n=0;n<e.length&&!t.closed;n++)t.next(e[n]);t.complete()})}(e);if(oc(e))return function pD(e){return new Ie(t=>{e.then(n=>{t.closed||(t.next(n),t.complete())},n=>t.error(n)).then(null,Wu)})}(e);if(sc(e))return fc(e);if(uc(e))return function hD(e){return new Ie(t=>{for(const n of e)if(t.next(n),t.closed)return;t.complete()})}(e);if(dc(e))return function gD(e){return fc(cc(e))}(e)}throw ac(e)}function fc(e){return new Ie(t=>{(function mD(e,t){var n,r,o,i;return function Xu(e,t,n,r){return new(n||(n=Promise))(function(i,s){function a(c){try{u(r.next(c))}catch(d){s(d)}}function l(c){try{u(r.throw(c))}catch(d){s(d)}}function u(c){c.done?i(c.value):function o(i){return i instanceof n?i:new n(function(s){s(i)})}(c.value).then(a,l)}u((r=r.apply(e,t||[])).next())})}(this,void 0,void 0,function*(){try{for(n=nc(e);!(r=yield n.next()).done;)if(t.next(r.value),t.closed)return}catch(s){o={error:s}}finally{try{r&&!r.done&&(i=n.return)&&(yield i.call(n))}finally{if(o)throw o.error}}t.complete()})})(e,t).catch(n=>t.error(n))})}function Yt(e,t,n,r=0,o=!1){const i=t.schedule(function(){n(),o?e.add(this.schedule(null,r)):this.unsubscribe()},r);if(e.add(i),!o)return i}function Eo(e,t,n=1/0){return le(t)?Eo((r,o)=>xn((i,s)=>t(r,i,o,s))(Qt(e(r,o))),n):("number"==typeof t&&(n=t),Mn((r,o)=>function yD(e,t,n,r,o,i,s,a){const l=[];let u=0,c=0,d=!1;const p=()=>{d&&!l.length&&!u&&t.complete()},f=g=>u<r?h(g):l.push(g),h=g=>{i&&t.next(g),u++;let m=!1;Qt(n(g,c++)).subscribe(Dr(t,D=>{o?.(D),i?f(D):t.next(D)},()=>{m=!0},void 0,()=>{if(m)try{for(u--;l.length&&u<r;){const D=l.shift();s?Yt(t,s,()=>h(D)):h(D)}p()}catch(D){t.error(D)}}))};return e.subscribe(Dr(t,f,()=>{d=!0,p()})),()=>{a?.()}}(r,o,e,n)))}const pc=new Ie(e=>e.complete());function _s(e){return e[e.length-1]}function hc(e){return function wD(e){return e&&le(e.schedule)}(_s(e))?e.pop():void 0}function gc(e,t=0){return Mn((n,r)=>{n.subscribe(Dr(r,o=>Yt(r,e,()=>r.next(o),t),()=>Yt(r,e,()=>r.complete(),t),o=>Yt(r,e,()=>r.error(o),t)))})}function mc(e,t=0){return Mn((n,r)=>{r.add(e.schedule(()=>n.subscribe(r),t))})}function yc(e,t){if(!e)throw new Error("Iterable cannot be null");return new Ie(n=>{Yt(n,t,()=>{const r=e[Symbol.asyncIterator]();Yt(n,t,()=>{r.next().then(o=>{o.done?n.complete():n.next(o.value)})},0,!0)})})}function Dc(e,t){return t?function TD(e,t){if(null!=e){if(ic(e))return function bD(e,t){return Qt(e).pipe(mc(t),gc(t))}(e,t);if(rc(e))return function CD(e,t){return new Ie(n=>{let r=0;return t.schedule(function(){r===e.length?n.complete():(n.next(e[r++]),n.closed||this.schedule())})})}(e,t);if(oc(e))return function ED(e,t){return Qt(e).pipe(mc(t),gc(t))}(e,t);if(sc(e))return yc(e,t);if(uc(e))return function ID(e,t){return new Ie(n=>{let r;return Yt(n,t,()=>{r=e[lc](),Yt(n,t,()=>{let o,i;try{({value:o,done:i}=r.next())}catch(s){return void n.error(s)}i?n.complete():n.next(o)},0,!0)}),()=>le(r?.return)&&r.return()})}(e,t);if(dc(e))return function SD(e,t){return yc(cc(e),t)}(e,t)}throw ac(e)}(e,t):Qt(e)}function bs(e,t,...n){if(!0===t)return void e();if(!1===t)return;const r=new yr({next:()=>{r.unsubscribe(),e()}});return Qt(t(...n)).subscribe(r)}function X(e){for(let t in e)if(e[t]===X)return t;throw Error("Could not find renamed property on target object.")}function ee(e){if("string"==typeof e)return e;if(Array.isArray(e))return"["+e.map(ee).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)}function Cs(e,t){return null==e||""===e?null===t?"":t:null==t||""===t?e:e+" "+t}const kD=X({__forward_ref__:X});function Is(e){return e.__forward_ref__=Is,e.toString=function(){return ee(this())},e}function x(e){return function Ss(e){return"function"==typeof e&&e.hasOwnProperty(kD)&&e.__forward_ref__===Is}(e)?e():e}function Ts(e){return e&&!!e.\u0275providers}const vc="https://g.co/ng/security#xss";class C extends Error{constructor(t,n){super(Co(t,n)),this.code=t}}function Co(e,t){return`NG0${Math.abs(e)}${t?": "+t.trim():""}`}function R(e){return"string"==typeof e?e:null==e?"":String(e)}function Io(e,t){throw new C(-201,!1)}function Ye(e,t){null==e&&function J(e,t,n,r){throw new Error(`ASSERTION ERROR: ${e}`+(null==r?"":` [Expected=> ${n} ${r} ${t} <=Actual]`))}(t,e,null,"!=")}function q(e){return{token:e.token,providedIn:e.providedIn||null,factory:e.factory,value:void 0}}function dn(e){return{providers:e.providers||[],imports:e.imports||[]}}function So(e){return wc(e,To)||wc(e,bc)}function wc(e,t){return e.hasOwnProperty(t)?e[t]:null}function _c(e){return e&&(e.hasOwnProperty(Ms)||e.hasOwnProperty(LD))?e[Ms]:null}const To=X({\u0275prov:X}),Ms=X({\u0275inj:X}),bc=X({ngInjectableDef:X}),LD=X({ngInjectorDef:X});var P=(()=>((P=P||{})[P.Default=0]="Default",P[P.Host=1]="Host",P[P.Self=2]="Self",P[P.SkipSelf=4]="SkipSelf",P[P.Optional=8]="Optional",P))();let xs;function Xe(e){const t=xs;return xs=e,t}function Ec(e,t,n){const r=So(e);return r&&"root"==r.providedIn?void 0===r.value?r.value=r.factory():r.value:n&P.Optional?null:void 0!==t?t:void Io(ee(e))}const ne=(()=>typeof globalThis<"u"&&globalThis||typeof global<"u"&&global||typeof window<"u"&&window||typeof self<"u"&&typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&self)(),vr={},ks="__NG_DI_FLAG__",Mo="ngTempTokenPath",BD="ngTokenPath",HD=/\n/gm,$D="\u0275",Cc="__source";let wr;function kn(e){const t=wr;return wr=e,t}function VD(e,t=P.Default){if(void 0===wr)throw new C(-203,!1);return null===wr?Ec(e,void 0,t):wr.get(e,t&P.Optional?null:void 0,t)}function H(e,t=P.Default){return(function jD(){return xs}()||VD)(x(e),t)}function _r(e,t=P.Default){return H(e,xo(t))}function xo(e){return typeof e>"u"||"number"==typeof e?e:0|(e.optional&&8)|(e.host&&1)|(e.self&&2)|(e.skipSelf&&4)}function As(e){const t=[];for(let n=0;n<e.length;n++){const r=x(e[n]);if(Array.isArray(r)){if(0===r.length)throw new C(900,!1);let o,i=P.Default;for(let s=0;s<r.length;s++){const a=r[s],l=UD(a);"number"==typeof l?-1===l?o=a.token:i|=l:o=a}t.push(H(o,i))}else t.push(H(r))}return t}function br(e,t){return e[ks]=t,e.prototype[ks]=t,e}function UD(e){return e[ks]}function Ft(e){return{toString:e}.toString()}var _t=(()=>((_t=_t||{})[_t.OnPush=0]="OnPush",_t[_t.Default=1]="Default",_t))(),bt=(()=>{return(e=bt||(bt={}))[e.Emulated=0]="Emulated",e[e.None=2]="None",e[e.ShadowDom=3]="ShadowDom",bt;var e})();const Ot={},W=[],ko=X({\u0275cmp:X}),Ps=X({\u0275dir:X}),Ns=X({\u0275pipe:X}),Sc=X({\u0275mod:X}),Lt=X({\u0275fac:X}),Er=X({__NG_ELEMENT_ID__:X});let qD=0;function Ao(e){return Ft(()=>{const t=Mc(e),n={...t,decls:e.decls,vars:e.vars,template:e.template,consts:e.consts||null,ngContentSelectors:e.ngContentSelectors,onPush:e.changeDetection===_t.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&e.dependencies||null,getStandaloneInjector:null,data:e.data||{},encapsulation:e.encapsulation||bt.Emulated,id:"c"+qD++,styles:e.styles||W,_:null,schemas:e.schemas||null,tView:null};xc(n);const r=e.dependencies;return n.directiveDefs=Po(r,!1),n.pipeDefs=Po(r,!0),n})}function ZD(e){return K(e)||Te(e)}function JD(e){return null!==e}function An(e){return Ft(()=>({type:e.type,bootstrap:e.bootstrap||W,declarations:e.declarations||W,imports:e.imports||W,exports:e.exports||W,transitiveCompileScopes:null,schemas:e.schemas||null,id:e.id||null}))}function Tc(e,t){if(null==e)return Ot;const n={};for(const r in e)if(e.hasOwnProperty(r)){let o=e[r],i=o;Array.isArray(o)&&(i=o[1],o=o[0]),n[o]=r,t&&(t[o]=i)}return n}function et(e){return Ft(()=>{const t=Mc(e);return xc(t),t})}function Se(e){return{type:e.type,name:e.name,factory:null,pure:!1!==e.pure,standalone:!0===e.standalone,onDestroy:e.type.prototype.ngOnDestroy||null}}function K(e){return e[ko]||null}function Te(e){return e[Ps]||null}function Be(e){return e[Ns]||null}function Mc(e){const t={};return{type:e.type,providersResolver:null,factory:null,hostBindings:e.hostBindings||null,hostVars:e.hostVars||0,hostAttrs:e.hostAttrs||null,contentQueries:e.contentQueries||null,declaredInputs:t,exportAs:e.exportAs||null,standalone:!0===e.standalone,selectors:e.selectors||W,viewQuery:e.viewQuery||null,features:e.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:Tc(e.inputs,t),outputs:Tc(e.outputs)}}function xc(e){e.features?.forEach(t=>t(e))}function Po(e,t){if(!e)return null;const n=t?Be:ZD;return()=>("function"==typeof e?e():e).map(r=>n(r)).filter(JD)}const jt=0,b=1,j=2,ue=3,ct=4,fn=5,Me=6,Pn=7,de=8,No=9,Ro=10,$=11,Rs=12,Ir=13,kc=14,Nn=15,xe=16,Sr=17,Rn=18,Et=19,Tr=20,Ac=21,re=22,Fs=1,Pc=2,Fo=7,Oo=8,Fn=9,Ne=10;function qe(e){return Array.isArray(e)&&"object"==typeof e[Fs]}function dt(e){return Array.isArray(e)&&!0===e[Fs]}function Os(e){return 0!=(4&e.flags)}function Mr(e){return e.componentOffset>-1}function Lo(e){return 1==(1&e.flags)}function ft(e){return!!e.template}function QD(e){return 0!=(256&e[j])}function pn(e,t){return e.hasOwnProperty(Lt)?e[Lt]:null}class ev{constructor(t,n,r){this.previousValue=t,this.currentValue=n,this.firstChange=r}isFirstChange(){return this.firstChange}}function xr(){return Fc}function Fc(e){return e.type.prototype.ngOnChanges&&(e.setInput=nv),tv}function tv(){const e=Lc(this),t=e?.current;if(t){const n=e.previous;if(n===Ot)e.previous=t;else for(let r in t)n[r]=t[r];e.current=null,this.ngOnChanges(t)}}function nv(e,t,n,r){const o=this.declaredInputs[n],i=Lc(e)||function rv(e,t){return e[Oc]=t}(e,{previous:Ot,current:null}),s=i.current||(i.current={}),a=i.previous,l=a[o];s[o]=new ev(l&&l.currentValue,t,a===Ot),e[r]=t}xr.ngInherit=!0;const Oc="__ngSimpleChanges__";function Lc(e){return e[Oc]||null}const tt=function(e,t,n){};function Ee(e){for(;Array.isArray(e);)e=e[jt];return e}function We(e,t){return Ee(t[e.index])}function Hc(e,t){return e.data[t]}function He(e,t){const n=t[e];return qe(n)?n:n[jt]}function Bo(e){return 64==(64&e[j])}function en(e,t){return null==t?null:e[t]}function $c(e){e[Rn]=0}function js(e,t){e[fn]+=t;let n=e,r=e[ue];for(;null!==r&&(1===t&&1===n[fn]||-1===t&&0===n[fn]);)r[fn]+=t,n=r,r=r[ue]}const F={lFrame:Qc(null),bindingsEnabled:!0};function Uc(){return F.bindingsEnabled}function v(){return F.lFrame.lView}function z(){return F.lFrame.tView}function tn(e){return F.lFrame.contextLView=e,e[de]}function nn(e){return F.lFrame.contextLView=null,e}function Ce(){let e=zc();for(;null!==e&&64===e.type;)e=e.parent;return e}function zc(){return F.lFrame.currentTNode}function Ct(e,t){const n=F.lFrame;n.currentTNode=e,n.isParent=t}function Bs(){return F.lFrame.isParent}function Re(){const e=F.lFrame;let t=e.bindingRootIndex;return-1===t&&(t=e.bindingRootIndex=e.tView.bindingStartIndex),t}function Ln(){return F.lFrame.bindingIndex++}function mv(e,t){const n=F.lFrame;n.bindingIndex=n.bindingRootIndex=e,$s(t)}function $s(e){F.lFrame.currentDirectiveIndex=e}function Us(e){F.lFrame.currentQueryIndex=e}function Dv(e){const t=e[b];return 2===t.type?t.declTNode:1===t.type?e[Me]:null}function Jc(e,t,n){if(n&P.SkipSelf){let o=t,i=e;for(;!(o=o.parent,null!==o||n&P.Host||(o=Dv(i),null===o||(i=i[Nn],10&o.type))););if(null===o)return!1;t=o,e=i}const r=F.lFrame=Kc();return r.currentTNode=t,r.lView=e,!0}function zs(e){const t=Kc(),n=e[b];F.lFrame=t,t.currentTNode=n.firstChild,t.lView=e,t.tView=n,t.contextLView=e,t.bindingIndex=n.bindingStartIndex,t.inI18n=!1}function Kc(){const e=F.lFrame,t=null===e?null:e.child;return null===t?Qc(e):t}function Qc(e){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:e,child:null,inI18n:!1};return null!==e&&(e.child=t),t}function Yc(){const e=F.lFrame;return F.lFrame=e.parent,e.currentTNode=null,e.lView=null,e}const Xc=Yc;function Gs(){const e=Yc();e.isParent=!0,e.tView=null,e.selectedIndex=-1,e.contextLView=null,e.elementDepthCount=0,e.currentDirectiveIndex=-1,e.currentNamespace=null,e.bindingRootIndex=-1,e.bindingIndex=-1,e.currentQueryIndex=0}function Fe(){return F.lFrame.selectedIndex}function hn(e){F.lFrame.selectedIndex=e}function ie(){const e=F.lFrame;return Hc(e.tView,e.selectedIndex)}function Ho(e,t){for(let n=t.directiveStart,r=t.directiveEnd;n<r;n++){const i=e.data[n].type.prototype,{ngAfterContentInit:s,ngAfterContentChecked:a,ngAfterViewInit:l,ngAfterViewChecked:u,ngOnDestroy:c}=i;s&&(e.contentHooks??(e.contentHooks=[])).push(-n,s),a&&((e.contentHooks??(e.contentHooks=[])).push(n,a),(e.contentCheckHooks??(e.contentCheckHooks=[])).push(n,a)),l&&(e.viewHooks??(e.viewHooks=[])).push(-n,l),u&&((e.viewHooks??(e.viewHooks=[])).push(n,u),(e.viewCheckHooks??(e.viewCheckHooks=[])).push(n,u)),null!=c&&(e.destroyHooks??(e.destroyHooks=[])).push(n,c)}}function $o(e,t,n){ed(e,t,3,n)}function Vo(e,t,n,r){(3&e[j])===n&&ed(e,t,n,r)}function qs(e,t){let n=e[j];(3&n)===t&&(n&=2047,n+=1,e[j]=n)}function ed(e,t,n,r){const i=r??-1,s=t.length-1;let a=0;for(let l=void 0!==r?65535&e[Rn]:0;l<s;l++)if("number"==typeof t[l+1]){if(a=t[l],null!=r&&a>=r)break}else t[l]<0&&(e[Rn]+=65536),(a<i||-1==i)&&(Tv(e,n,t,l),e[Rn]=(4294901760&e[Rn])+l+2),l++}function Tv(e,t,n,r){const o=n[r]<0,i=n[r+1],a=e[o?-n[r]:n[r]];if(o){if(e[j]>>11<e[Rn]>>16&&(3&e[j])===t){e[j]+=2048,tt(4,a,i);try{i.call(a)}finally{tt(5,a,i)}}}else{tt(4,a,i);try{i.call(a)}finally{tt(5,a,i)}}}const jn=-1;class Ar{constructor(t,n,r){this.factory=t,this.resolving=!1,this.canSeeViewProviders=n,this.injectImpl=r}}function Zs(e,t,n){let r=0;for(;r<n.length;){const o=n[r];if("number"==typeof o){if(0!==o)break;r++;const i=n[r++],s=n[r++],a=n[r++];e.setAttribute(t,s,a,i)}else{const i=o,s=n[++r];nd(i)?e.setProperty(t,i,s):e.setAttribute(t,i,s),r++}}return r}function td(e){return 3===e||4===e||6===e}function nd(e){return 64===e.charCodeAt(0)}function Pr(e,t){if(null!==t&&0!==t.length)if(null===e||0===e.length)e=t.slice();else{let n=-1;for(let r=0;r<t.length;r++){const o=t[r];"number"==typeof o?n=o:0===n||rd(e,n,o,null,-1===n||2===n?t[++r]:null)}}return e}function rd(e,t,n,r,o){let i=0,s=e.length;if(-1===t)s=-1;else for(;i<e.length;){const a=e[i++];if("number"==typeof a){if(a===t){s=-1;break}if(a>t){s=i-1;break}}}for(;i<e.length;){const a=e[i];if("number"==typeof a)break;if(a===n){if(null===r)return void(null!==o&&(e[i+1]=o));if(r===e[i+1])return void(e[i+2]=o)}i++,null!==r&&i++,null!==o&&i++}-1!==s&&(e.splice(s,0,t),i=s+1),e.splice(i++,0,n),null!==r&&e.splice(i++,0,r),null!==o&&e.splice(i++,0,o)}function od(e){return e!==jn}function Uo(e){return 32767&e}function zo(e,t){let n=function Av(e){return e>>16}(e),r=t;for(;n>0;)r=r[Nn],n--;return r}let Js=!0;function Go(e){const t=Js;return Js=e,t}const id=255,sd=5;let Pv=0;const It={};function qo(e,t){const n=ad(e,t);if(-1!==n)return n;const r=t[b];r.firstCreatePass&&(e.injectorIndex=t.length,Ks(r.data,e),Ks(t,null),Ks(r.blueprint,null));const o=Qs(e,t),i=e.injectorIndex;if(od(o)){const s=Uo(o),a=zo(o,t),l=a[b].data;for(let u=0;u<8;u++)t[i+u]=a[s+u]|l[s+u]}return t[i+8]=o,i}function Ks(e,t){e.push(0,0,0,0,0,0,0,0,t)}function ad(e,t){return-1===e.injectorIndex||e.parent&&e.parent.injectorIndex===e.injectorIndex||null===t[e.injectorIndex+8]?-1:e.injectorIndex}function Qs(e,t){if(e.parent&&-1!==e.parent.injectorIndex)return e.parent.injectorIndex;let n=0,r=null,o=t;for(;null!==o;){if(r=hd(o),null===r)return jn;if(n++,o=o[Nn],-1!==r.injectorIndex)return r.injectorIndex|n<<16}return jn}function Ys(e,t,n){!function Nv(e,t,n){let r;"string"==typeof n?r=n.charCodeAt(0)||0:n.hasOwnProperty(Er)&&(r=n[Er]),null==r&&(r=n[Er]=Pv++);const o=r&id;t.data[e+(o>>sd)]|=1<<o}(e,t,n)}function ld(e,t,n){if(n&P.Optional||void 0!==e)return e;Io()}function ud(e,t,n,r){if(n&P.Optional&&void 0===r&&(r=null),!(n&(P.Self|P.Host))){const o=e[No],i=Xe(void 0);try{return o?o.get(t,r,n&P.Optional):Ec(t,r,n&P.Optional)}finally{Xe(i)}}return ld(r,0,n)}function cd(e,t,n,r=P.Default,o){if(null!==e){if(1024&t[j]){const s=function Bv(e,t,n,r,o){let i=e,s=t;for(;null!==i&&null!==s&&1024&s[j]&&!(256&s[j]);){const a=dd(i,s,n,r|P.Self,It);if(a!==It)return a;let l=i.parent;if(!l){const u=s[Ac];if(u){const c=u.get(n,It,r);if(c!==It)return c}l=hd(s),s=s[Nn]}i=l}return o}(e,t,n,r,It);if(s!==It)return s}const i=dd(e,t,n,r,It);if(i!==It)return i}return ud(t,n,r,o)}function dd(e,t,n,r,o){const i=function Ov(e){if("string"==typeof e)return e.charCodeAt(0)||0;const t=e.hasOwnProperty(Er)?e[Er]:void 0;return"number"==typeof t?t>=0?t&id:Lv:t}(n);if("function"==typeof i){if(!Jc(t,e,r))return r&P.Host?ld(o,0,r):ud(t,n,r,o);try{const s=i(r);if(null!=s||r&P.Optional)return s;Io()}finally{Xc()}}else if("number"==typeof i){let s=null,a=ad(e,t),l=jn,u=r&P.Host?t[xe][Me]:null;for((-1===a||r&P.SkipSelf)&&(l=-1===a?Qs(e,t):t[a+8],l!==jn&&pd(r,!1)?(s=t[b],a=Uo(l),t=zo(l,t)):a=-1);-1!==a;){const c=t[b];if(fd(i,a,c.data)){const d=Fv(a,t,n,s,r,u);if(d!==It)return d}l=t[a+8],l!==jn&&pd(r,t[b].data[a+8]===u)&&fd(i,a,t)?(s=c,a=Uo(l),t=zo(l,t)):a=-1}}return o}function Fv(e,t,n,r,o,i){const s=t[b],a=s.data[e+8],c=function Wo(e,t,n,r,o){const i=e.providerIndexes,s=t.data,a=1048575&i,l=e.directiveStart,c=i>>20,p=o?a+c:e.directiveEnd;for(let f=r?a:a+c;f<p;f++){const h=s[f];if(f<l&&n===h||f>=l&&h.type===n)return f}if(o){const f=s[l];if(f&&ft(f)&&f.type===n)return l}return null}(a,s,n,null==r?Mr(a)&&Js:r!=s&&0!=(3&a.type),o&P.Host&&i===a);return null!==c?gn(t,s,c,a):It}function gn(e,t,n,r){let o=e[n];const i=t.data;if(function Mv(e){return e instanceof Ar}(o)){const s=o;s.resolving&&function AD(e,t){const n=t?`. Dependency path: ${t.join(" > ")} > ${e}`:"";throw new C(-200,`Circular dependency in DI detected for ${e}${n}`)}(function Z(e){return"function"==typeof e?e.name||e.toString():"object"==typeof e&&null!=e&&"function"==typeof e.type?e.type.name||e.type.toString():R(e)}(i[n]));const a=Go(s.canSeeViewProviders);s.resolving=!0;const l=s.injectImpl?Xe(s.injectImpl):null;Jc(e,r,P.Default);try{o=e[n]=s.factory(void 0,i,e,r),t.firstCreatePass&&n>=r.directiveStart&&function Sv(e,t,n){const{ngOnChanges:r,ngOnInit:o,ngDoCheck:i}=t.type.prototype;if(r){const s=Fc(t);(n.preOrderHooks??(n.preOrderHooks=[])).push(e,s),(n.preOrderCheckHooks??(n.preOrderCheckHooks=[])).push(e,s)}o&&(n.preOrderHooks??(n.preOrderHooks=[])).push(0-e,o),i&&((n.preOrderHooks??(n.preOrderHooks=[])).push(e,i),(n.preOrderCheckHooks??(n.preOrderCheckHooks=[])).push(e,i))}(n,i[n],t)}finally{null!==l&&Xe(l),Go(a),s.resolving=!1,Xc()}}return o}function fd(e,t,n){return!!(n[t+(e>>sd)]&1<<e)}function pd(e,t){return!(e&P.Self||e&P.Host&&t)}class Bn{constructor(t,n){this._tNode=t,this._lView=n}get(t,n,r){return cd(this._tNode,this._lView,t,xo(r),n)}}function Lv(){return new Bn(Ce(),v())}function hd(e){const t=e[b],n=t.type;return 2===n?t.declTNode:1===n?e[Me]:null}const $n="__parameters__";function Un(e,t,n){return Ft(()=>{const r=function ta(e){return function(...n){if(e){const r=e(...n);for(const o in r)this[o]=r[o]}}}(t);function o(...i){if(this instanceof o)return r.apply(this,i),this;const s=new o(...i);return a.annotation=s,a;function a(l,u,c){const d=l.hasOwnProperty($n)?l[$n]:Object.defineProperty(l,$n,{value:[]})[$n];for(;d.length<=c;)d.push(null);return(d[c]=d[c]||[]).push(s),l}}return n&&(o.prototype=Object.create(n.prototype)),o.prototype.ngMetadataName=e,o.annotationCls=o,o})}class A{constructor(t,n){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof n?this.__NG_ELEMENT_ID__=n:void 0!==n&&(this.\u0275prov=q({token:this,providedIn:n.providedIn||"root",factory:n.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}function mn(e,t){e.forEach(n=>Array.isArray(n)?mn(n,t):t(n))}function md(e,t,n){t>=e.length?e.push(n):e.splice(t,0,n)}function Zo(e,t){return t>=e.length-1?e.pop():e.splice(t,1)[0]}const Ko=br(Un("Optional"),8),Qo=br(Un("SkipSelf"),4);var $e=(()=>(($e=$e||{})[$e.Important=1]="Important",$e[$e.DashCase=2]="DashCase",$e))();const ua=new Map;let dw=0;const da="__ngContext__";function ke(e,t){qe(t)?(e[da]=t[Tr],function pw(e){ua.set(e[Tr],e)}(t)):e[da]=t}let fa;function pa(e,t){return fa(e,t)}function Br(e){const t=e[ue];return dt(t)?t[ue]:t}function ha(e){return Ld(e[Ir])}function ga(e){return Ld(e[ct])}function Ld(e){for(;null!==e&&!dt(e);)e=e[ct];return e}function qn(e,t,n,r,o){if(null!=r){let i,s=!1;dt(r)?i=r:qe(r)&&(s=!0,r=r[jt]);const a=Ee(r);0===e&&null!==n?null==o?Ud(t,n,a):yn(t,n,a,o||null,!0):1===e&&null!==n?yn(t,n,a,o||null,!0):2===e?function ba(e,t,n){const r=ei(e,t);r&&function Nw(e,t,n,r){e.removeChild(t,n,r)}(e,r,t,n)}(t,a,s):3===e&&t.destroyNode(a),null!=i&&function Ow(e,t,n,r,o){const i=n[Fo];i!==Ee(n)&&qn(t,e,r,i,o);for(let a=Ne;a<n.length;a++){const l=n[a];Hr(l[b],l,e,t,r,i)}}(t,e,i,n,o)}}function ya(e,t,n){return e.createElement(t,n)}function Bd(e,t){const n=e[Fn],r=n.indexOf(t),o=t[ue];512&t[j]&&(t[j]&=-513,js(o,-1)),n.splice(r,1)}function Da(e,t){if(e.length<=Ne)return;const n=Ne+t,r=e[n];if(r){const o=r[Sr];null!==o&&o!==e&&Bd(o,r),t>0&&(e[n-1][ct]=r[ct]);const i=Zo(e,Ne+t);!function Iw(e,t){Hr(e,t,t[$],2,null,null),t[jt]=null,t[Me]=null}(r[b],r);const s=i[Et];null!==s&&s.detachView(i[b]),r[ue]=null,r[ct]=null,r[j]&=-65}return r}function Hd(e,t){if(!(128&t[j])){const n=t[$];n.destroyNode&&Hr(e,t,n,3,null,null),function Mw(e){let t=e[Ir];if(!t)return va(e[b],e);for(;t;){let n=null;if(qe(t))n=t[Ir];else{const r=t[Ne];r&&(n=r)}if(!n){for(;t&&!t[ct]&&t!==e;)qe(t)&&va(t[b],t),t=t[ue];null===t&&(t=e),qe(t)&&va(t[b],t),n=t&&t[ct]}t=n}}(t)}}function va(e,t){if(!(128&t[j])){t[j]&=-65,t[j]|=128,function Pw(e,t){let n;if(null!=e&&null!=(n=e.destroyHooks))for(let r=0;r<n.length;r+=2){const o=t[n[r]];if(!(o instanceof Ar)){const i=n[r+1];if(Array.isArray(i))for(let s=0;s<i.length;s+=2){const a=o[i[s]],l=i[s+1];tt(4,a,l);try{l.call(a)}finally{tt(5,a,l)}}else{tt(4,o,i);try{i.call(o)}finally{tt(5,o,i)}}}}}(e,t),function Aw(e,t){const n=e.cleanup,r=t[Pn];let o=-1;if(null!==n)for(let i=0;i<n.length-1;i+=2)if("string"==typeof n[i]){const s=n[i+3];s>=0?r[o=s]():r[o=-s].unsubscribe(),i+=2}else{const s=r[o=n[i+1]];n[i].call(s)}if(null!==r){for(let i=o+1;i<r.length;i++)(0,r[i])();t[Pn]=null}}(e,t),1===t[b].type&&t[$].destroy();const n=t[Sr];if(null!==n&&dt(t[ue])){n!==t[ue]&&Bd(n,t);const r=t[Et];null!==r&&r.detachView(e)}!function hw(e){ua.delete(e[Tr])}(t)}}function $d(e,t,n){return function Vd(e,t,n){let r=t;for(;null!==r&&40&r.type;)r=(t=r).parent;if(null===r)return n[jt];{const{componentOffset:o}=r;if(o>-1){const{encapsulation:i}=e.data[r.directiveStart+o];if(i===bt.None||i===bt.Emulated)return null}return We(r,n)}}(e,t.parent,n)}function yn(e,t,n,r,o){e.insertBefore(t,n,r,o)}function Ud(e,t,n){e.appendChild(t,n)}function zd(e,t,n,r,o){null!==r?yn(e,t,n,r,o):Ud(e,t,n)}function ei(e,t){return e.parentNode(t)}let wa,ri,Ia,oi,Wd=function qd(e,t,n){return 40&e.type?We(e,n):null};function ti(e,t,n,r){const o=$d(e,r,t),i=t[$],a=function Gd(e,t,n){return Wd(e,t,n)}(r.parent||t[Me],r,t);if(null!=o)if(Array.isArray(n))for(let l=0;l<n.length;l++)zd(i,o,n[l],a,!1);else zd(i,o,n,a,!1);void 0!==wa&&wa(i,r,t,n,o)}function ni(e,t){if(null!==t){const n=t.type;if(3&n)return We(t,e);if(4&n)return _a(-1,e[t.index]);if(8&n){const r=t.child;if(null!==r)return ni(e,r);{const o=e[t.index];return dt(o)?_a(-1,o):Ee(o)}}if(32&n)return pa(t,e)()||Ee(e[t.index]);{const r=Jd(e,t);return null!==r?Array.isArray(r)?r[0]:ni(Br(e[xe]),r):ni(e,t.next)}}return null}function Jd(e,t){return null!==t?e[xe][Me].projection[t.projection]:null}function _a(e,t){const n=Ne+e+1;if(n<t.length){const r=t[n],o=r[b].firstChild;if(null!==o)return ni(r,o)}return t[Fo]}function Ea(e,t,n,r,o,i,s){for(;null!=n;){const a=r[n.index],l=n.type;if(s&&0===t&&(a&&ke(Ee(a),r),n.flags|=2),32!=(32&n.flags))if(8&l)Ea(e,t,n.child,r,o,i,!1),qn(t,e,o,a,i);else if(32&l){const u=pa(n,r);let c;for(;c=u();)qn(t,e,o,c,i);qn(t,e,o,a,i)}else 16&l?Kd(e,t,r,n,o,i):qn(t,e,o,a,i);n=s?n.projectionNext:n.next}}function Hr(e,t,n,r,o,i){Ea(n,r,e.firstChild,t,o,i,!1)}function Kd(e,t,n,r,o,i){const s=n[xe],l=s[Me].projection[r.projection];if(Array.isArray(l))for(let u=0;u<l.length;u++)qn(t,e,o,l[u],i);else Ea(e,t,l,s[ue],o,i,!0)}function Qd(e,t,n){""===n?e.removeAttribute(t,"class"):e.setAttribute(t,"class",n)}function Yd(e,t,n){const{mergedAttrs:r,classes:o,styles:i}=n;null!==r&&Zs(e,t,r),null!==o&&Qd(e,t,o),null!==i&&function jw(e,t,n){e.setAttribute(t,"style",n)}(e,t,i)}function Wn(e){return function Ca(){if(void 0===ri&&(ri=null,ne.trustedTypes))try{ri=ne.trustedTypes.createPolicy("angular",{createHTML:e=>e,createScript:e=>e,createScriptURL:e=>e})}catch{}return ri}()?.createHTML(e)||e}function ef(e){return function Sa(){if(void 0===oi&&(oi=null,ne.trustedTypes))try{oi=ne.trustedTypes.createPolicy("angular#unsafe-bypass",{createHTML:e=>e,createScript:e=>e,createScriptURL:e=>e})}catch{}return oi}()?.createHTML(e)||e}class rf{constructor(t){this.changingThisBreaksApplicationSecurity=t}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${vc})`}}function rn(e){return e instanceof rf?e.changingThisBreaksApplicationSecurity:e}function $r(e,t){const n=function Zw(e){return e instanceof rf&&e.getTypeName()||null}(e);if(null!=n&&n!==t){if("ResourceURL"===n&&"URL"===t)return!0;throw new Error(`Required a safe ${t}, got a ${n} (see ${vc})`)}return n===t}class Jw{constructor(t){this.inertDocumentHelper=t}getInertBodyElement(t){t="<body><remove></remove>"+t;try{const n=(new window.DOMParser).parseFromString(Wn(t),"text/html").body;return null===n?this.inertDocumentHelper.getInertBodyElement(t):(n.removeChild(n.firstChild),n)}catch{return null}}}class Kw{constructor(t){this.defaultDoc=t,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert")}getInertBodyElement(t){const n=this.inertDocument.createElement("template");return n.innerHTML=Wn(t),n}}const Yw=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\/?#]*(?:[\/?#]|$))/i;function Ta(e){return(e=String(e)).match(Yw)?e:"unsafe:"+e}function $t(e){const t={};for(const n of e.split(","))t[n]=!0;return t}function Vr(...e){const t={};for(const n of e)for(const r in n)n.hasOwnProperty(r)&&(t[r]=!0);return t}const af=$t("area,br,col,hr,img,wbr"),lf=$t("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),uf=$t("rp,rt"),Ma=Vr(af,Vr(lf,$t("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")),Vr(uf,$t("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")),Vr(uf,lf)),xa=$t("background,cite,href,itemtype,longdesc,poster,src,xlink:href"),cf=Vr(xa,$t("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,srcset,start,summary,tabindex,target,title,translate,type,usemap,valign,value,vspace,width"),$t("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")),Xw=$t("script,style,template");class e_{constructor(){this.sanitizedSomething=!1,this.buf=[]}sanitizeChildren(t){let n=t.firstChild,r=!0;for(;n;)if(n.nodeType===Node.ELEMENT_NODE?r=this.startElement(n):n.nodeType===Node.TEXT_NODE?this.chars(n.nodeValue):this.sanitizedSomething=!0,r&&n.firstChild)n=n.firstChild;else for(;n;){n.nodeType===Node.ELEMENT_NODE&&this.endElement(n);let o=this.checkClobberedElement(n,n.nextSibling);if(o){n=o;break}n=this.checkClobberedElement(n,n.parentNode)}return this.buf.join("")}startElement(t){const n=t.nodeName.toLowerCase();if(!Ma.hasOwnProperty(n))return this.sanitizedSomething=!0,!Xw.hasOwnProperty(n);this.buf.push("<"),this.buf.push(n);const r=t.attributes;for(let o=0;o<r.length;o++){const i=r.item(o),s=i.name,a=s.toLowerCase();if(!cf.hasOwnProperty(a)){this.sanitizedSomething=!0;continue}let l=i.value;xa[a]&&(l=Ta(l)),this.buf.push(" ",s,'="',df(l),'"')}return this.buf.push(">"),!0}endElement(t){const n=t.nodeName.toLowerCase();Ma.hasOwnProperty(n)&&!af.hasOwnProperty(n)&&(this.buf.push("</"),this.buf.push(n),this.buf.push(">"))}chars(t){this.buf.push(df(t))}checkClobberedElement(t,n){if(n&&(t.compareDocumentPosition(n)&Node.DOCUMENT_POSITION_CONTAINED_BY)===Node.DOCUMENT_POSITION_CONTAINED_BY)throw new Error(`Failed to sanitize html because the element is clobbered: ${t.outerHTML}`);return n}}const t_=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,n_=/([^\#-~ |!])/g;function df(e){return e.replace(/&/g,"&amp;").replace(t_,function(t){return"&#"+(1024*(t.charCodeAt(0)-55296)+(t.charCodeAt(1)-56320)+65536)+";"}).replace(n_,function(t){return"&#"+t.charCodeAt(0)+";"}).replace(/</g,"&lt;").replace(/>/g,"&gt;")}let ii;function ka(e){return"content"in e&&function o_(e){return e.nodeType===Node.ELEMENT_NODE&&"TEMPLATE"===e.nodeName}(e)?e.content:null}var ge=(()=>((ge=ge||{})[ge.NONE=0]="NONE",ge[ge.HTML=1]="HTML",ge[ge.STYLE=2]="STYLE",ge[ge.SCRIPT=3]="SCRIPT",ge[ge.URL=4]="URL",ge[ge.RESOURCE_URL=5]="RESOURCE_URL",ge))();function si(e){const t=Ur();return t?ef(t.sanitize(ge.HTML,e)||""):$r(e,"HTML")?ef(rn(e)):function r_(e,t){let n=null;try{ii=ii||function sf(e){const t=new Kw(e);return function Qw(){try{return!!(new window.DOMParser).parseFromString(Wn(""),"text/html")}catch{return!1}}()?new Jw(t):t}(e);let r=t?String(t):"";n=ii.getInertBodyElement(r);let o=5,i=r;do{if(0===o)throw new Error("Failed to sanitize html because the input is unstable");o--,r=i,i=n.innerHTML,n=ii.getInertBodyElement(r)}while(r!==i);return Wn((new e_).sanitizeChildren(ka(n)||n))}finally{if(n){const r=ka(n)||n;for(;r.firstChild;)r.removeChild(r.firstChild)}}}(function Xd(){return void 0!==Ia?Ia:typeof document<"u"?document:void 0}(),R(e))}function Aa(e){const t=Ur();return t?t.sanitize(ge.URL,e)||"":$r(e,"URL")?rn(e):Ta(R(e))}function Ur(){const e=v();return e&&e[Rs]}const pf=new A("ENVIRONMENT_INITIALIZER"),hf=new A("INJECTOR",-1),gf=new A("INJECTOR_DEF_TYPES");class mf{get(t,n=vr){if(n===vr){const r=new Error(`NullInjectorError: No provider for ${ee(t)}!`);throw r.name="NullInjectorError",r}return n}}function f_(...e){return{\u0275providers:yf(0,e),\u0275fromNgModule:!0}}function yf(e,...t){const n=[],r=new Set;let o;return mn(t,i=>{const s=i;Pa(s,n,[],r)&&(o||(o=[]),o.push(s))}),void 0!==o&&Df(o,n),n}function Df(e,t){for(let n=0;n<e.length;n++){const{providers:o}=e[n];Na(o,i=>{t.push(i)})}}function Pa(e,t,n,r){if(!(e=x(e)))return!1;let o=null,i=_c(e);const s=!i&&K(e);if(i||s){if(s&&!s.standalone)return!1;o=e}else{const l=e.ngModule;if(i=_c(l),!i)return!1;o=l}const a=r.has(o);if(s){if(a)return!1;if(r.add(o),s.dependencies){const l="function"==typeof s.dependencies?s.dependencies():s.dependencies;for(const u of l)Pa(u,t,n,r)}}else{if(!i)return!1;{if(null!=i.imports&&!a){let u;r.add(o);try{mn(i.imports,c=>{Pa(c,t,n,r)&&(u||(u=[]),u.push(c))})}finally{}void 0!==u&&Df(u,t)}if(!a){const u=pn(o)||(()=>new o);t.push({provide:o,useFactory:u,deps:W},{provide:gf,useValue:o,multi:!0},{provide:pf,useValue:()=>H(o),multi:!0})}const l=i.providers;null==l||a||Na(l,c=>{t.push(c)})}}return o!==e&&void 0!==e.providers}function Na(e,t){for(let n of e)Ts(n)&&(n=n.\u0275providers),Array.isArray(n)?Na(n,t):t(n)}const p_=X({provide:String,useValue:X});function Ra(e){return null!==e&&"object"==typeof e&&p_ in e}function Dn(e){return"function"==typeof e}const Fa=new A("Set Injector scope."),ai={},g_={};let Oa;function li(){return void 0===Oa&&(Oa=new mf),Oa}class vn{}class _f extends vn{get destroyed(){return this._destroyed}constructor(t,n,r,o){super(),this.parent=n,this.source=r,this.scopes=o,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,ja(t,s=>this.processProvider(s)),this.records.set(hf,Zn(void 0,this)),o.has("environment")&&this.records.set(vn,Zn(void 0,this));const i=this.records.get(Fa);null!=i&&"string"==typeof i.value&&this.scopes.add(i.value),this.injectorDefTypes=new Set(this.get(gf.multi,W,P.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const t of this._ngOnDestroyHooks)t.ngOnDestroy();for(const t of this._onDestroyHooks)t()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),this._onDestroyHooks.length=0}}onDestroy(t){this._onDestroyHooks.push(t)}runInContext(t){this.assertNotDestroyed();const n=kn(this),r=Xe(void 0);try{return t()}finally{kn(n),Xe(r)}}get(t,n=vr,r=P.Default){this.assertNotDestroyed(),r=xo(r);const o=kn(this),i=Xe(void 0);try{if(!(r&P.SkipSelf)){let a=this.records.get(t);if(void 0===a){const l=function w_(e){return"function"==typeof e||"object"==typeof e&&e instanceof A}(t)&&So(t);a=l&&this.injectableDefInScope(l)?Zn(La(t),ai):null,this.records.set(t,a)}if(null!=a)return this.hydrate(t,a)}return(r&P.Self?li():this.parent).get(t,n=r&P.Optional&&n===vr?null:n)}catch(s){if("NullInjectorError"===s.name){if((s[Mo]=s[Mo]||[]).unshift(ee(t)),o)throw s;return function zD(e,t,n,r){const o=e[Mo];throw t[Cc]&&o.unshift(t[Cc]),e.message=function GD(e,t,n,r=null){e=e&&"\n"===e.charAt(0)&&e.charAt(1)==$D?e.slice(2):e;let o=ee(t);if(Array.isArray(t))o=t.map(ee).join(" -> ");else if("object"==typeof t){let i=[];for(let s in t)if(t.hasOwnProperty(s)){let a=t[s];i.push(s+":"+("string"==typeof a?JSON.stringify(a):ee(a)))}o=`{${i.join(", ")}}`}return`${n}${r?"("+r+")":""}[${o}]: ${e.replace(HD,"\n  ")}`}("\n"+e.message,o,n,r),e[BD]=o,e[Mo]=null,e}(s,t,"R3InjectorError",this.source)}throw s}finally{Xe(i),kn(o)}}resolveInjectorInitializers(){const t=kn(this),n=Xe(void 0);try{const r=this.get(pf.multi,W,P.Self);for(const o of r)o()}finally{kn(t),Xe(n)}}toString(){const t=[],n=this.records;for(const r of n.keys())t.push(ee(r));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new C(205,!1)}processProvider(t){let n=Dn(t=x(t))?t:x(t&&t.provide);const r=function y_(e){return Ra(e)?Zn(void 0,e.useValue):Zn(function bf(e,t,n){let r;if(Dn(e)){const o=x(e);return pn(o)||La(o)}if(Ra(e))r=()=>x(e.useValue);else if(function wf(e){return!(!e||!e.useFactory)}(e))r=()=>e.useFactory(...As(e.deps||[]));else if(function vf(e){return!(!e||!e.useExisting)}(e))r=()=>H(x(e.useExisting));else{const o=x(e&&(e.useClass||e.provide));if(!function D_(e){return!!e.deps}(e))return pn(o)||La(o);r=()=>new o(...As(e.deps))}return r}(e),ai)}(t);if(Dn(t)||!0!==t.multi)this.records.get(n);else{let o=this.records.get(n);o||(o=Zn(void 0,ai,!0),o.factory=()=>As(o.multi),this.records.set(n,o)),n=t,o.multi.push(t)}this.records.set(n,r)}hydrate(t,n){return n.value===ai&&(n.value=g_,n.value=n.factory()),"object"==typeof n.value&&n.value&&function v_(e){return null!==e&&"object"==typeof e&&"function"==typeof e.ngOnDestroy}(n.value)&&this._ngOnDestroyHooks.add(n.value),n.value}injectableDefInScope(t){if(!t.providedIn)return!1;const n=x(t.providedIn);return"string"==typeof n?"any"===n||this.scopes.has(n):this.injectorDefTypes.has(n)}}function La(e){const t=So(e),n=null!==t?t.factory:pn(e);if(null!==n)return n;if(e instanceof A)throw new C(204,!1);if(e instanceof Function)return function m_(e){const t=e.length;if(t>0)throw function Fr(e,t){const n=[];for(let r=0;r<e;r++)n.push(t);return n}(t,"?"),new C(204,!1);const n=function OD(e){return e&&(e[To]||e[bc])||null}(e);return null!==n?()=>n.factory(e):()=>new e}(e);throw new C(204,!1)}function Zn(e,t,n=!1){return{factory:e,value:t,multi:n?[]:void 0}}function ja(e,t){for(const n of e)Array.isArray(n)?ja(n,t):n&&Ts(n)?ja(n.\u0275providers,t):t(n)}class __{}class Ef{}class E_{resolveComponentFactory(t){throw function b_(e){const t=Error(`No component factory found for ${ee(e)}. Did you add it to @NgModule.entryComponents?`);return t.ngComponent=e,t}(t)}}let ui=(()=>{class e{}return e.NULL=new E_,e})();function C_(){return Jn(Ce(),v())}function Jn(e,t){return new Kn(We(e,t))}let Kn=(()=>{class e{constructor(n){this.nativeElement=n}}return e.__NG_ELEMENT_ID__=C_,e})();class If{}let Sf=(()=>{class e{}return e.__NG_ELEMENT_ID__=()=>function S_(){const e=v(),n=He(Ce().index,e);return(qe(n)?n:e)[$]}(),e})(),T_=(()=>{class e{}return e.\u0275prov=q({token:e,providedIn:"root",factory:()=>null}),e})();class Ba{constructor(t){this.full=t,this.major=t.split(".")[0],this.minor=t.split(".")[1],this.patch=t.split(".").slice(2).join(".")}}const M_=new Ba("15.2.10"),Ha={},$a="ngOriginalError";function Va(e){return e[$a]}class Qn{constructor(){this._console=console}handleError(t){const n=this._findOriginalError(t);this._console.error("ERROR",t),n&&this._console.error("ORIGINAL ERROR",n)}_findOriginalError(t){let n=t&&Va(t);for(;n&&Va(n);)n=Va(n);return n||null}}function Mf(e,t,n){let r=e.length;for(;;){const o=e.indexOf(t,n);if(-1===o)return o;if(0===o||e.charCodeAt(o-1)<=32){const i=t.length;if(o+i===r||e.charCodeAt(o+i)<=32)return o}n=o+1}}const xf="ng-template";function B_(e,t,n){let r=0,o=!0;for(;r<e.length;){let i=e[r++];if("string"==typeof i&&o){const s=e[r++];if(n&&"class"===i&&-1!==Mf(s.toLowerCase(),t,0))return!0}else{if(1===i){for(;r<e.length&&"string"==typeof(i=e[r++]);)if(i.toLowerCase()===t)return!0;return!1}"number"==typeof i&&(o=!1)}}return!1}function kf(e){return 4===e.type&&e.value!==xf}function H_(e,t,n){return t===(4!==e.type||n?e.value:xf)}function $_(e,t,n){let r=4;const o=e.attrs||[],i=function z_(e){for(let t=0;t<e.length;t++)if(td(e[t]))return t;return e.length}(o);let s=!1;for(let a=0;a<t.length;a++){const l=t[a];if("number"!=typeof l){if(!s)if(4&r){if(r=2|1&r,""!==l&&!H_(e,l,n)||""===l&&1===t.length){if(pt(r))return!1;s=!0}}else{const u=8&r?l:t[++a];if(8&r&&null!==e.attrs){if(!B_(e.attrs,u,n)){if(pt(r))return!1;s=!0}continue}const d=V_(8&r?"class":l,o,kf(e),n);if(-1===d){if(pt(r))return!1;s=!0;continue}if(""!==u){let p;p=d>i?"":o[d+1].toLowerCase();const f=8&r?p:null;if(f&&-1!==Mf(f,u,0)||2&r&&u!==p){if(pt(r))return!1;s=!0}}}}else{if(!s&&!pt(r)&&!pt(l))return!1;if(s&&pt(l))continue;s=!1,r=l|1&r}}return pt(r)||s}function pt(e){return 0==(1&e)}function V_(e,t,n,r){if(null===t)return-1;let o=0;if(r||!n){let i=!1;for(;o<t.length;){const s=t[o];if(s===e)return o;if(3===s||6===s)i=!0;else{if(1===s||2===s){let a=t[++o];for(;"string"==typeof a;)a=t[++o];continue}if(4===s)break;if(0===s){o+=4;continue}}o+=i?1:2}return-1}return function G_(e,t){let n=e.indexOf(4);if(n>-1)for(n++;n<e.length;){const r=e[n];if("number"==typeof r)return-1;if(r===t)return n;n++}return-1}(t,e)}function Af(e,t,n=!1){for(let r=0;r<t.length;r++)if($_(e,t[r],n))return!0;return!1}function Pf(e,t){return e?":not("+t.trim()+")":t}function W_(e){let t=e[0],n=1,r=2,o="",i=!1;for(;n<e.length;){let s=e[n];if("string"==typeof s)if(2&r){const a=e[++n];o+="["+s+(a.length>0?'="'+a+'"':"")+"]"}else 8&r?o+="."+s:4&r&&(o+=" "+s);else""!==o&&!pt(s)&&(t+=Pf(i,o),o=""),r=s,i=i||!pt(r);n++}return""!==o&&(t+=Pf(i,o)),t}const O={};function T(e){Nf(z(),v(),Fe()+e,!1)}function Nf(e,t,n,r){if(!r)if(3==(3&t[j])){const i=e.preOrderCheckHooks;null!==i&&$o(t,i,n)}else{const i=e.preOrderHooks;null!==i&&Vo(t,i,0,n)}hn(n)}function Lf(e,t=null,n=null,r){const o=jf(e,t,n,r);return o.resolveInjectorInitializers(),o}function jf(e,t=null,n=null,r,o=new Set){const i=[n||W,f_(e)];return r=r||("object"==typeof e?void 0:ee(e)),new _f(i,t||li(),r||null,o)}let wn=(()=>{class e{static create(n,r){if(Array.isArray(n))return Lf({name:""},r,n,"");{const o=n.name??"";return Lf({name:o},n.parent,n.providers,o)}}}return e.THROW_IF_NOT_FOUND=vr,e.NULL=new mf,e.\u0275prov=q({token:e,providedIn:"any",factory:()=>H(hf)}),e.__NG_ELEMENT_ID__=-1,e})();function L(e,t=P.Default){const n=v();return null===n?H(e,t):cd(Ce(),n,x(e),t)}function Gf(e,t){const n=e.contentQueries;if(null!==n)for(let r=0;r<n.length;r+=2){const i=n[r+1];if(-1!==i){const s=e.data[i];Us(n[r]),s.contentQueries(2,t[i],i)}}}function di(e,t,n,r,o,i,s,a,l,u,c){const d=t.blueprint.slice();return d[jt]=o,d[j]=76|r,(null!==c||e&&1024&e[j])&&(d[j]|=1024),$c(d),d[ue]=d[Nn]=e,d[de]=n,d[Ro]=s||e&&e[Ro],d[$]=a||e&&e[$],d[Rs]=l||e&&e[Rs]||null,d[No]=u||e&&e[No]||null,d[Me]=i,d[Tr]=function fw(){return dw++}(),d[Ac]=c,d[xe]=2==t.type?e[xe]:d,d}function er(e,t,n,r,o){let i=e.data[t];if(null===i)i=function Wa(e,t,n,r,o){const i=zc(),s=Bs(),l=e.data[t]=function wb(e,t,n,r,o,i){return{type:n,index:r,insertBeforeIndex:null,injectorIndex:t?t.injectorIndex:-1,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:0,providerIndexes:0,value:o,attrs:i,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,s?i:i&&i.parent,n,t,r,o);return null===e.firstChild&&(e.firstChild=l),null!==i&&(s?null==i.child&&null!==l.parent&&(i.child=l):null===i.next&&(i.next=l,l.prev=i)),l}(e,t,n,r,o),function gv(){return F.lFrame.inI18n}()&&(i.flags|=32);else if(64&i.type){i.type=n,i.value=r,i.attrs=o;const s=function kr(){const e=F.lFrame,t=e.currentTNode;return e.isParent?t:t.parent}();i.injectorIndex=null===s?-1:s.injectorIndex}return Ct(i,!0),i}function zr(e,t,n,r){if(0===n)return-1;const o=t.length;for(let i=0;i<n;i++)t.push(r),e.blueprint.push(r),e.data.push(null);return o}function Za(e,t,n){zs(t);try{const r=e.viewQuery;null!==r&&rl(1,r,n);const o=e.template;null!==o&&qf(e,t,o,1,n),e.firstCreatePass&&(e.firstCreatePass=!1),e.staticContentQueries&&Gf(e,t),e.staticViewQueries&&rl(2,e.viewQuery,n);const i=e.components;null!==i&&function yb(e,t){for(let n=0;n<t.length;n++)Hb(e,t[n])}(t,i)}catch(r){throw e.firstCreatePass&&(e.incompleteFirstPass=!0,e.firstCreatePass=!1),r}finally{t[j]&=-5,Gs()}}function fi(e,t,n,r){const o=t[j];if(128!=(128&o)){zs(t);try{$c(t),function qc(e){return F.lFrame.bindingIndex=e}(e.bindingStartIndex),null!==n&&qf(e,t,n,2,r);const s=3==(3&o);if(s){const u=e.preOrderCheckHooks;null!==u&&$o(t,u,null)}else{const u=e.preOrderHooks;null!==u&&Vo(t,u,0,null),qs(t,0)}if(function jb(e){for(let t=ha(e);null!==t;t=ga(t)){if(!t[Pc])continue;const n=t[Fn];for(let r=0;r<n.length;r++){const o=n[r];512&o[j]||js(o[ue],1),o[j]|=512}}}(t),function Lb(e){for(let t=ha(e);null!==t;t=ga(t))for(let n=Ne;n<t.length;n++){const r=t[n],o=r[b];Bo(r)&&fi(o,r,o.template,r[de])}}(t),null!==e.contentQueries&&Gf(e,t),s){const u=e.contentCheckHooks;null!==u&&$o(t,u)}else{const u=e.contentHooks;null!==u&&Vo(t,u,1),qs(t,1)}!function gb(e,t){const n=e.hostBindingOpCodes;if(null!==n)try{for(let r=0;r<n.length;r++){const o=n[r];if(o<0)hn(~o);else{const i=o,s=n[++r],a=n[++r];mv(s,i),a(2,t[i])}}}finally{hn(-1)}}(e,t);const a=e.components;null!==a&&function mb(e,t){for(let n=0;n<t.length;n++)Bb(e,t[n])}(t,a);const l=e.viewQuery;if(null!==l&&rl(2,l,r),s){const u=e.viewCheckHooks;null!==u&&$o(t,u)}else{const u=e.viewHooks;null!==u&&Vo(t,u,2),qs(t,2)}!0===e.firstUpdatePass&&(e.firstUpdatePass=!1),t[j]&=-41,512&t[j]&&(t[j]&=-513,js(t[ue],-1))}finally{Gs()}}}function qf(e,t,n,r,o){const i=Fe(),s=2&r;try{hn(-1),s&&t.length>re&&Nf(e,t,re,!1),tt(s?2:0,o),n(r,o)}finally{hn(i),tt(s?3:1,o)}}function Ja(e,t,n){if(Os(t)){const o=t.directiveEnd;for(let i=t.directiveStart;i<o;i++){const s=e.data[i];s.contentQueries&&s.contentQueries(1,n[i],i)}}}function Ka(e,t,n){Uc()&&(function Tb(e,t,n,r){const o=n.directiveStart,i=n.directiveEnd;Mr(n)&&function Rb(e,t,n){const r=We(t,e),o=Wf(n),i=e[Ro],s=pi(e,di(e,o,null,n.onPush?32:16,r,t,i,i.createRenderer(r,n),null,null,null));e[t.index]=s}(t,n,e.data[o+n.componentOffset]),e.firstCreatePass||qo(n,t),ke(r,t);const s=n.initialInputs;for(let a=o;a<i;a++){const l=e.data[a],u=gn(t,e,a,n);ke(u,t),null!==s&&Fb(0,a-o,u,l,0,s),ft(l)&&(He(n.index,t)[de]=gn(t,e,a,n))}}(e,t,n,We(n,t)),64==(64&n.flags)&&Yf(e,t,n))}function Qa(e,t,n=We){const r=t.localNames;if(null!==r){let o=t.index+1;for(let i=0;i<r.length;i+=2){const s=r[i+1],a=-1===s?n(t,e):e[s];e[o++]=a}}}function Wf(e){const t=e.tView;return null===t||t.incompleteFirstPass?e.tView=Ya(1,null,e.template,e.decls,e.vars,e.directiveDefs,e.pipeDefs,e.viewQuery,e.schemas,e.consts):t}function Ya(e,t,n,r,o,i,s,a,l,u){const c=re+r,d=c+o,p=function Db(e,t){const n=[];for(let r=0;r<t;r++)n.push(r<e?null:O);return n}(c,d),f="function"==typeof u?u():u;return p[b]={type:e,blueprint:p,template:n,queries:null,viewQuery:a,declTNode:t,data:p.slice().fill(null,c),bindingStartIndex:c,expandoStartIndex:d,hostBindingOpCodes:null,firstCreatePass:!0,firstUpdatePass:!0,staticViewQueries:!1,staticContentQueries:!1,preOrderHooks:null,preOrderCheckHooks:null,contentHooks:null,contentCheckHooks:null,viewHooks:null,viewCheckHooks:null,destroyHooks:null,cleanup:null,contentQueries:null,components:null,directiveRegistry:"function"==typeof i?i():i,pipeRegistry:"function"==typeof s?s():s,firstChild:null,schemas:l,consts:f,incompleteFirstPass:!1}}function Jf(e,t,n,r){for(let o in e)if(e.hasOwnProperty(o)){n=null===n?{}:n;const i=e[o];null===r?Kf(n,t,o,i):r.hasOwnProperty(o)&&Kf(n,t,r[o],i)}return n}function Kf(e,t,n,r){e.hasOwnProperty(n)?e[n].push(t,r):e[n]=[t,r]}function Je(e,t,n,r,o,i,s,a){const l=We(t,n);let c,u=t.inputs;!a&&null!=u&&(c=u[r])?(ol(e,n,c,r,o),Mr(t)&&function Eb(e,t){const n=He(t,e);16&n[j]||(n[j]|=32)}(n,t.index)):3&t.type&&(r=function bb(e){return"class"===e?"className":"for"===e?"htmlFor":"formaction"===e?"formAction":"innerHtml"===e?"innerHTML":"readonly"===e?"readOnly":"tabindex"===e?"tabIndex":e}(r),o=null!=s?s(o,t.value||"",r):o,i.setProperty(l,r,o))}function Xa(e,t,n,r){if(Uc()){const o=null===r?null:{"":-1},i=function xb(e,t){const n=e.directiveRegistry;let r=null,o=null;if(n)for(let i=0;i<n.length;i++){const s=n[i];if(Af(t,s.selectors,!1))if(r||(r=[]),ft(s))if(null!==s.findHostDirectiveDefs){const a=[];o=o||new Map,s.findHostDirectiveDefs(s,a,o),r.unshift(...a,s),el(e,t,a.length)}else r.unshift(s),el(e,t,0);else o=o||new Map,s.findHostDirectiveDefs?.(s,r,o),r.push(s)}return null===r?null:[r,o]}(e,n);let s,a;null===i?s=a=null:[s,a]=i,null!==s&&Qf(e,t,n,s,o,a),o&&function kb(e,t,n){if(t){const r=e.localNames=[];for(let o=0;o<t.length;o+=2){const i=n[t[o+1]];if(null==i)throw new C(-301,!1);r.push(t[o],i)}}}(n,r,o)}n.mergedAttrs=Pr(n.mergedAttrs,n.attrs)}function Qf(e,t,n,r,o,i){for(let u=0;u<r.length;u++)Ys(qo(n,t),e,r[u].type);!function Pb(e,t,n){e.flags|=1,e.directiveStart=t,e.directiveEnd=t+n,e.providerIndexes=t}(n,e.data.length,r.length);for(let u=0;u<r.length;u++){const c=r[u];c.providersResolver&&c.providersResolver(c)}let s=!1,a=!1,l=zr(e,t,r.length,null);for(let u=0;u<r.length;u++){const c=r[u];n.mergedAttrs=Pr(n.mergedAttrs,c.hostAttrs),Nb(e,n,t,l,c),Ab(l,c,o),null!==c.contentQueries&&(n.flags|=4),(null!==c.hostBindings||null!==c.hostAttrs||0!==c.hostVars)&&(n.flags|=64);const d=c.type.prototype;!s&&(d.ngOnChanges||d.ngOnInit||d.ngDoCheck)&&((e.preOrderHooks??(e.preOrderHooks=[])).push(n.index),s=!0),!a&&(d.ngOnChanges||d.ngDoCheck)&&((e.preOrderCheckHooks??(e.preOrderCheckHooks=[])).push(n.index),a=!0),l++}!function _b(e,t,n){const o=t.directiveEnd,i=e.data,s=t.attrs,a=[];let l=null,u=null;for(let c=t.directiveStart;c<o;c++){const d=i[c],p=n?n.get(d):null,h=p?p.outputs:null;l=Jf(d.inputs,c,l,p?p.inputs:null),u=Jf(d.outputs,c,u,h);const g=null===l||null===s||kf(t)?null:Ob(l,c,s);a.push(g)}null!==l&&(l.hasOwnProperty("class")&&(t.flags|=8),l.hasOwnProperty("style")&&(t.flags|=16)),t.initialInputs=a,t.inputs=l,t.outputs=u}(e,n,i)}function Yf(e,t,n){const r=n.directiveStart,o=n.directiveEnd,i=n.index,s=function yv(){return F.lFrame.currentDirectiveIndex}();try{hn(i);for(let a=r;a<o;a++){const l=e.data[a],u=t[a];$s(a),(null!==l.hostBindings||0!==l.hostVars||null!==l.hostAttrs)&&Mb(l,u)}}finally{hn(-1),$s(s)}}function Mb(e,t){null!==e.hostBindings&&e.hostBindings(1,t)}function el(e,t,n){t.componentOffset=n,(e.components??(e.components=[])).push(t.index)}function Ab(e,t,n){if(n){if(t.exportAs)for(let r=0;r<t.exportAs.length;r++)n[t.exportAs[r]]=e;ft(t)&&(n[""]=e)}}function Nb(e,t,n,r,o){e.data[r]=o;const i=o.factory||(o.factory=pn(o.type)),s=new Ar(i,ft(o),L);e.blueprint[r]=s,n[r]=s,function Ib(e,t,n,r,o){const i=o.hostBindings;if(i){let s=e.hostBindingOpCodes;null===s&&(s=e.hostBindingOpCodes=[]);const a=~t.index;(function Sb(e){let t=e.length;for(;t>0;){const n=e[--t];if("number"==typeof n&&n<0)return n}return 0})(s)!=a&&s.push(a),s.push(n,r,i)}}(e,t,r,zr(e,n,o.hostVars,O),o)}function Fb(e,t,n,r,o,i){const s=i[t];if(null!==s){const a=r.setInput;for(let l=0;l<s.length;){const u=s[l++],c=s[l++],d=s[l++];null!==a?r.setInput(n,d,u,c):n[c]=d}}}function Ob(e,t,n){let r=null,o=0;for(;o<n.length;){const i=n[o];if(0!==i)if(5!==i){if("number"==typeof i)break;if(e.hasOwnProperty(i)){null===r&&(r=[]);const s=e[i];for(let a=0;a<s.length;a+=2)if(s[a]===t){r.push(i,s[a+1],n[o+1]);break}}o+=2}else o+=2;else o+=4}return r}function Xf(e,t,n,r){return[e,!0,!1,t,null,0,r,n,null,null]}function Bb(e,t){const n=He(t,e);if(Bo(n)){const r=n[b];48&n[j]?fi(r,n,r.template,n[de]):n[fn]>0&&nl(n)}}function nl(e){for(let r=ha(e);null!==r;r=ga(r))for(let o=Ne;o<r.length;o++){const i=r[o];if(Bo(i))if(512&i[j]){const s=i[b];fi(s,i,s.template,i[de])}else i[fn]>0&&nl(i)}const n=e[b].components;if(null!==n)for(let r=0;r<n.length;r++){const o=He(n[r],e);Bo(o)&&o[fn]>0&&nl(o)}}function Hb(e,t){const n=He(t,e),r=n[b];(function $b(e,t){for(let n=t.length;n<e.blueprint.length;n++)t.push(e.blueprint[n])})(r,n),Za(r,n,n[de])}function pi(e,t){return e[Ir]?e[kc][ct]=t:e[Ir]=t,e[kc]=t,t}function hi(e){for(;e;){e[j]|=32;const t=Br(e);if(QD(e)&&!t)return e;e=t}return null}function gi(e,t,n,r=!0){const o=t[Ro];o.begin&&o.begin();try{fi(e,t,e.template,n)}catch(s){throw r&&rp(t,s),s}finally{o.end&&o.end()}}function rl(e,t,n){Us(0),t(e,n)}function ep(e){return e[Pn]||(e[Pn]=[])}function tp(e){return e.cleanup||(e.cleanup=[])}function rp(e,t){const n=e[No],r=n?n.get(Qn,null):null;r&&r.handleError(t)}function ol(e,t,n,r,o){for(let i=0;i<n.length;){const s=n[i++],a=n[i++],l=t[s],u=e.data[s];null!==u.setInput?u.setInput(l,o,r,a):l[a]=o}}function Ut(e,t,n){const r=function jo(e,t){return Ee(t[e])}(t,e);!function jd(e,t,n){e.setValue(t,n)}(e[$],r,n)}function mi(e,t,n){let r=n?e.styles:null,o=n?e.classes:null,i=0;if(null!==t)for(let s=0;s<t.length;s++){const a=t[s];"number"==typeof a?i=a:1==i?o=Cs(o,a):2==i&&(r=Cs(r,a+": "+t[++s]+";"))}n?e.styles=r:e.stylesWithoutHost=r,n?e.classes=o:e.classesWithoutHost=o}function yi(e,t,n,r,o=!1){for(;null!==n;){const i=t[n.index];if(null!==i&&r.push(Ee(i)),dt(i))for(let a=Ne;a<i.length;a++){const l=i[a],u=l[b].firstChild;null!==u&&yi(l[b],l,u,r)}const s=n.type;if(8&s)yi(e,t,n.child,r);else if(32&s){const a=pa(n,t);let l;for(;l=a();)r.push(l)}else if(16&s){const a=Jd(t,n);if(Array.isArray(a))r.push(...a);else{const l=Br(t[xe]);yi(l[b],l,a,r,!0)}}n=o?n.projectionNext:n.next}return r}class Gr{get rootNodes(){const t=this._lView,n=t[b];return yi(n,t,n.firstChild,[])}constructor(t,n){this._lView=t,this._cdRefInjectingView=n,this._appRef=null,this._attachedToViewContainer=!1}get context(){return this._lView[de]}set context(t){this._lView[de]=t}get destroyed(){return 128==(128&this._lView[j])}destroy(){if(this._appRef)this._appRef.detachView(this);else if(this._attachedToViewContainer){const t=this._lView[ue];if(dt(t)){const n=t[Oo],r=n?n.indexOf(this):-1;r>-1&&(Da(t,r),Zo(n,r))}this._attachedToViewContainer=!1}Hd(this._lView[b],this._lView)}onDestroy(t){!function Zf(e,t,n,r){const o=ep(t);null===n?o.push(r):(o.push(n),e.firstCreatePass&&tp(e).push(r,o.length-1))}(this._lView[b],this._lView,null,t)}markForCheck(){hi(this._cdRefInjectingView||this._lView)}detach(){this._lView[j]&=-65}reattach(){this._lView[j]|=64}detectChanges(){gi(this._lView[b],this._lView,this.context)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new C(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,function Tw(e,t){Hr(e,t,t[$],2,null,null)}(this._lView[b],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new C(902,!1);this._appRef=t}}class Vb extends Gr{constructor(t){super(t),this._view=t}detectChanges(){const t=this._view;gi(t[b],t,t[de],!1)}checkNoChanges(){}get context(){return null}}class op extends ui{constructor(t){super(),this.ngModule=t}resolveComponentFactory(t){const n=K(t);return new qr(n,this.ngModule)}}function ip(e){const t=[];for(let n in e)e.hasOwnProperty(n)&&t.push({propName:e[n],templateName:n});return t}class zb{constructor(t,n){this.injector=t,this.parentInjector=n}get(t,n,r){r=xo(r);const o=this.injector.get(t,Ha,r);return o!==Ha||n===Ha?o:this.parentInjector.get(t,n,r)}}class qr extends Ef{get inputs(){return ip(this.componentDef.inputs)}get outputs(){return ip(this.componentDef.outputs)}constructor(t,n){super(),this.componentDef=t,this.ngModule=n,this.componentType=t.type,this.selector=function Z_(e){return e.map(W_).join(",")}(t.selectors),this.ngContentSelectors=t.ngContentSelectors?t.ngContentSelectors:[],this.isBoundToModule=!!n}create(t,n,r,o){let i=(o=o||this.ngModule)instanceof vn?o:o?.injector;i&&null!==this.componentDef.getStandaloneInjector&&(i=this.componentDef.getStandaloneInjector(i)||i);const s=i?new zb(t,i):t,a=s.get(If,null);if(null===a)throw new C(407,!1);const l=s.get(T_,null),u=a.createRenderer(null,this.componentDef),c=this.componentDef.selectors[0][0]||"div",d=r?function vb(e,t,n){return e.selectRootElement(t,n===bt.ShadowDom)}(u,r,this.componentDef.encapsulation):ya(u,c,function Ub(e){const t=e.toLowerCase();return"svg"===t?"svg":"math"===t?"math":null}(c)),p=this.componentDef.onPush?288:272,f=Ya(0,null,null,1,0,null,null,null,null,null),h=di(null,f,null,p,null,null,a,u,l,s,null);let g,m;zs(h);try{const D=this.componentDef;let w,y=null;D.findHostDirectiveDefs?(w=[],y=new Map,D.findHostDirectiveDefs(D,w,y),w.push(D)):w=[D];const E=function qb(e,t){const n=e[b],r=re;return e[r]=t,er(n,r,2,"#host",null)}(h,d),G=function Wb(e,t,n,r,o,i,s,a){const l=o[b];!function Zb(e,t,n,r){for(const o of e)t.mergedAttrs=Pr(t.mergedAttrs,o.hostAttrs);null!==t.mergedAttrs&&(mi(t,t.mergedAttrs,!0),null!==n&&Yd(r,n,t))}(r,e,t,s);const u=i.createRenderer(t,n),c=di(o,Wf(n),null,n.onPush?32:16,o[e.index],e,i,u,a||null,null,null);return l.firstCreatePass&&el(l,e,r.length-1),pi(o,c),o[e.index]=c}(E,d,D,w,h,a,u);m=Hc(f,re),d&&function Kb(e,t,n,r){if(r)Zs(e,n,["ng-version",M_.full]);else{const{attrs:o,classes:i}=function J_(e){const t=[],n=[];let r=1,o=2;for(;r<e.length;){let i=e[r];if("string"==typeof i)2===o?""!==i&&t.push(i,e[++r]):8===o&&n.push(i);else{if(!pt(o))break;o=i}r++}return{attrs:t,classes:n}}(t.selectors[0]);o&&Zs(e,n,o),i&&i.length>0&&Qd(e,n,i.join(" "))}}(u,D,d,r),void 0!==n&&function Qb(e,t,n){const r=e.projection=[];for(let o=0;o<t.length;o++){const i=n[o];r.push(null!=i?Array.from(i):null)}}(m,this.ngContentSelectors,n),g=function Jb(e,t,n,r,o,i){const s=Ce(),a=o[b],l=We(s,o);Qf(a,o,s,n,null,r);for(let c=0;c<n.length;c++)ke(gn(o,a,s.directiveStart+c,s),o);Yf(a,o,s),l&&ke(l,o);const u=gn(o,a,s.directiveStart+s.componentOffset,s);if(e[de]=o[de]=u,null!==i)for(const c of i)c(u,t);return Ja(a,s,e),u}(G,D,w,y,h,[Yb]),Za(f,h,null)}finally{Gs()}return new Gb(this.componentType,g,Jn(m,h),h,m)}}class Gb extends __{constructor(t,n,r,o,i){super(),this.location=r,this._rootLView=o,this._tNode=i,this.instance=n,this.hostView=this.changeDetectorRef=new Vb(o),this.componentType=t}setInput(t,n){const r=this._tNode.inputs;let o;if(null!==r&&(o=r[t])){const i=this._rootLView;ol(i[b],i,o,t,n),hi(He(this._tNode.index,i))}}get injector(){return new Bn(this._tNode,this._rootLView)}destroy(){this.hostView.destroy()}onDestroy(t){this.hostView.onDestroy(t)}}function Yb(){const e=Ce();Ho(v()[b],e)}function Di(e){return!!sl(e)&&(Array.isArray(e)||!(e instanceof Map)&&Symbol.iterator in e)}function sl(e){return null!==e&&("function"==typeof e||"object"==typeof e)}function Tt(e,t,n){return e[t]=n}function Ae(e,t,n){return!Object.is(e[t],n)&&(e[t]=n,!0)}function _n(e,t,n,r){const o=Ae(e,t,n);return Ae(e,t+1,r)||o}function nr(e,t,n,r){return Ae(e,Ln(),n)?t+R(n)+r:O}function rr(e,t,n,r,o,i){const a=_n(e,function Bt(){return F.lFrame.bindingIndex}(),n,o);return function Ht(e){const t=F.lFrame,n=t.bindingIndex;return t.bindingIndex=t.bindingIndex+e,n}(2),a?t+R(n)+r+R(o)+i:O}function oe(e,t,n,r,o,i,s,a){const l=v(),u=z(),c=e+re,d=u.firstCreatePass?function fE(e,t,n,r,o,i,s,a,l){const u=t.consts,c=er(t,e,4,s||null,en(u,a));Xa(t,n,c,en(u,l)),Ho(t,c);const d=c.tView=Ya(2,c,r,o,i,t.directiveRegistry,t.pipeRegistry,null,t.schemas,u);return null!==t.queries&&(t.queries.template(t,c),d.queries=t.queries.embeddedTView(c)),c}(c,u,l,t,n,r,o,i,s):u.data[c];Ct(d,!1);const p=l[$].createComment("");ti(u,l,p,d),ke(p,l),pi(l,l[c]=Xf(p,l,p,d)),Lo(d)&&Ka(u,l,d),null!=s&&Qa(l,d,a)}function V(e,t,n){const r=v();return Ae(r,Ln(),t)&&Je(z(),ie(),r,e,t,r[$],n,!1),V}function al(e,t,n,r,o){const s=o?"class":"style";ol(e,n,t.inputs[s],s,r)}function I(e,t,n,r){const o=v(),i=z(),s=re+e,a=o[$],l=i.firstCreatePass?function gE(e,t,n,r,o,i){const s=t.consts,l=er(t,e,2,r,en(s,o));return Xa(t,n,l,en(s,i)),null!==l.attrs&&mi(l,l.attrs,!1),null!==l.mergedAttrs&&mi(l,l.mergedAttrs,!0),null!==t.queries&&t.queries.elementStart(t,l),l}(s,i,o,t,n,r):i.data[s],u=o[s]=ya(a,t,function Iv(){return F.lFrame.currentNamespace}()),c=Lo(l);return Ct(l,!0),Yd(a,u,l),32!=(32&l.flags)&&ti(i,o,u,l),0===function uv(){return F.lFrame.elementDepthCount}()&&ke(u,o),function cv(){F.lFrame.elementDepthCount++}(),c&&(Ka(i,o,l),Ja(i,l,o)),null!==r&&Qa(o,l),I}function S(){let e=Ce();Bs()?function Hs(){F.lFrame.isParent=!1}():(e=e.parent,Ct(e,!1));const t=e;!function dv(){F.lFrame.elementDepthCount--}();const n=z();return n.firstCreatePass&&(Ho(n,e),Os(e)&&n.queries.elementEnd(e)),null!=t.classesWithoutHost&&function xv(e){return 0!=(8&e.flags)}(t)&&al(n,t,v(),t.classesWithoutHost,!0),null!=t.stylesWithoutHost&&function kv(e){return 0!=(16&e.flags)}(t)&&al(n,t,v(),t.stylesWithoutHost,!1),S}function Ke(e,t,n,r){return I(e,t,n,r),S(),Ke}function bn(){return v()}function cl(e){return!!e&&"function"==typeof e.then}const yE=function bp(e){return!!e&&"function"==typeof e.subscribe};function zt(e,t,n,r){const o=v(),i=z(),s=Ce();return function Cp(e,t,n,r,o,i,s){const a=Lo(r),u=e.firstCreatePass&&tp(e),c=t[de],d=ep(t);let p=!0;if(3&r.type||s){const g=We(r,t),m=s?s(g):g,D=d.length,w=s?E=>s(Ee(E[r.index])):r.index;let y=null;if(!s&&a&&(y=function DE(e,t,n,r){const o=e.cleanup;if(null!=o)for(let i=0;i<o.length-1;i+=2){const s=o[i];if(s===n&&o[i+1]===r){const a=t[Pn],l=o[i+2];return a.length>l?a[l]:null}"string"==typeof s&&(i+=2)}return null}(e,t,o,r.index)),null!==y)(y.__ngLastListenerFn__||y).__ngNextListenerFn__=i,y.__ngLastListenerFn__=i,p=!1;else{i=Sp(r,t,c,i,!1);const E=n.listen(m,o,i);d.push(i,E),u&&u.push(o,w,D,D+1)}}else i=Sp(r,t,c,i,!1);const f=r.outputs;let h;if(p&&null!==f&&(h=f[o])){const g=h.length;if(g)for(let m=0;m<g;m+=2){const G=t[h[m]][h[m+1]].subscribe(i),ae=d.length;d.push(i,G),u&&u.push(o,r.index,ae,-(ae+1))}}}(i,o,o[$],s,e,t,r),zt}function Ip(e,t,n,r){try{return tt(6,t,n),!1!==n(r)}catch(o){return rp(e,o),!1}finally{tt(7,t,n)}}function Sp(e,t,n,r,o){return function i(s){if(s===Function)return r;hi(e.componentOffset>-1?He(e.index,t):t);let l=Ip(t,n,r,s),u=i.__ngNextListenerFn__;for(;u;)l=Ip(t,n,u,s)&&l,u=u.__ngNextListenerFn__;return o&&!1===l&&(s.preventDefault(),s.returnValue=!1),l}}function me(e=1){return function vv(e){return(F.lFrame.contextLView=function wv(e,t){for(;e>0;)t=t[Nn],e--;return t}(e,F.lFrame.contextLView))[de]}(e)}function dl(e,t,n){return fl(e,"",t,"",n),dl}function fl(e,t,n,r,o){const i=v(),s=nr(i,t,n,r);return s!==O&&Je(z(),ie(),i,e,s,i[$],o,!1),fl}function N(e,t=""){const n=v(),r=z(),o=e+re,i=r.firstCreatePass?er(r,o,1,t,null):r.data[o],s=n[o]=function ma(e,t){return e.createText(t)}(n[$],t);ti(r,n,s,i),Ct(i,!1)}function Qe(e){return Gt("",e,""),Qe}function Gt(e,t,n){const r=v(),o=nr(r,e,t,n);return o!==O&&Ut(r,Fe(),o),Gt}function yl(e,t,n,r,o){const i=v(),s=rr(i,e,t,n,r,o);return s!==O&&Ut(i,Fe(),s),yl}const fr="en-US";let mh=fr;class pr{}class c0{}class Vh extends pr{constructor(t,n){super(),this._parent=n,this._bootstrapComponents=[],this.destroyCbs=[],this.componentFactoryResolver=new op(this);const r=function Ge(e,t){const n=e[Sc]||null;if(!n&&!0===t)throw new Error(`Type ${ee(e)} does not have '\u0275mod' property.`);return n}(t);this._bootstrapComponents=function Vt(e){return e instanceof Function?e():e}(r.bootstrap),this._r3Injector=jf(t,n,[{provide:pr,useValue:this},{provide:ui,useValue:this.componentFactoryResolver}],ee(t),new Set(["environment"])),this._r3Injector.resolveInjectorInitializers(),this.instance=this._r3Injector.get(t)}get injector(){return this._r3Injector}destroy(){const t=this._r3Injector;!t.destroyed&&t.destroy(),this.destroyCbs.forEach(n=>n()),this.destroyCbs=null}onDestroy(t){this.destroyCbs.push(t)}}class Cl extends c0{constructor(t){super(),this.moduleType=t}create(t){return new Vh(this.moduleType,t)}}function Sl(e,t,n,r,o){return function Qh(e,t,n,r,o,i,s){const a=t+n;return _n(e,a,o,i)?Tt(e,a+2,s?r.call(s,o,i):r(o,i)):eo(e,a+2)}(v(),Re(),e,t,n,r,o)}function eo(e,t){const n=e[t];return n===O?void 0:n}function ot(e,t){const n=z();let r;const o=e+re;n.firstCreatePass?(r=function P0(e,t){if(t)for(let n=t.length-1;n>=0;n--){const r=t[n];if(e===r.name)return r}}(t,n.pipeRegistry),n.data[o]=r,r.onDestroy&&(n.destroyHooks??(n.destroyHooks=[])).push(o,r.onDestroy)):r=n.data[o];const i=r.factory||(r.factory=pn(r.type)),s=Xe(L);try{const a=Go(!1),l=i();return Go(a),function pE(e,t,n,r){n>=e.data.length&&(e.data[n]=null,e.blueprint[n]=null),t[n]=r}(n,v(),o,l),l}finally{Xe(s)}}function it(e,t,n){const r=e+re,o=v(),i=function On(e,t){return e[t]}(o,r);return function to(e,t){return e[b].data[t].pure}(o,r)?function Kh(e,t,n,r,o,i){const s=t+n;return Ae(e,s,o)?Tt(e,s+1,i?r.call(i,o):r(o)):eo(e,s+1)}(o,Re(),t,i.transform,n,i):i.transform(n)}function Tl(e){return t=>{setTimeout(e,void 0,t)}}const kt=class L0 extends ms{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,n,r){let o=t,i=n||(()=>null),s=r;if(t&&"object"==typeof t){const l=t;o=l.next?.bind(l),i=l.error?.bind(l),s=l.complete?.bind(l)}this.__isAsync&&(i=Tl(i),o&&(o=Tl(o)),s&&(s=Tl(s)));const a=super.subscribe({next:o,error:i,complete:s});return t instanceof wt&&t.add(a),a}};let qt=(()=>{class e{}return e.__NG_ELEMENT_ID__=$0,e})();const B0=qt,H0=class extends B0{constructor(t,n,r){super(),this._declarationLView=t,this._declarationTContainer=n,this.elementRef=r}createEmbeddedView(t,n){const r=this._declarationTContainer.tView,o=di(this._declarationLView,r,t,16,null,r.declTNode,null,null,null,null,n||null);o[Sr]=this._declarationLView[this._declarationTContainer.index];const s=this._declarationLView[Et];return null!==s&&(o[Et]=s.createEmbeddedView(r)),Za(r,o,t),new Gr(o)}};function $0(){return function Si(e,t){return 4&e.type?new H0(t,e,Jn(e,t)):null}(Ce(),v())}let At=(()=>{class e{}return e.__NG_ELEMENT_ID__=V0,e})();function V0(){return function rg(e,t){let n;const r=t[e.index];if(dt(r))n=r;else{let o;if(8&e.type)o=Ee(r);else{const i=t[$];o=i.createComment("");const s=We(e,t);yn(i,ei(i,s),o,function Rw(e,t){return e.nextSibling(t)}(i,s),!1)}t[e.index]=n=Xf(r,t,o,e),pi(t,n)}return new tg(n,e,t)}(Ce(),v())}const U0=At,tg=class extends U0{constructor(t,n,r){super(),this._lContainer=t,this._hostTNode=n,this._hostLView=r}get element(){return Jn(this._hostTNode,this._hostLView)}get injector(){return new Bn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Qs(this._hostTNode,this._hostLView);if(od(t)){const n=zo(t,this._hostLView),r=Uo(t);return new Bn(n[b].data[r+8],n)}return new Bn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const n=ng(this._lContainer);return null!==n&&n[t]||null}get length(){return this._lContainer.length-Ne}createEmbeddedView(t,n,r){let o,i;"number"==typeof r?o=r:null!=r&&(o=r.index,i=r.injector);const s=t.createEmbeddedView(n||{},i);return this.insert(s,o),s}createComponent(t,n,r,o,i){const s=t&&!function Rr(e){return"function"==typeof e}(t);let a;if(s)a=n;else{const d=n||{};a=d.index,r=d.injector,o=d.projectableNodes,i=d.environmentInjector||d.ngModuleRef}const l=s?t:new qr(K(t)),u=r||this.parentInjector;if(!i&&null==l.ngModule){const p=(s?u:this.parentInjector).get(vn,null);p&&(i=p)}const c=l.create(u,o,void 0,i);return this.insert(c.hostView,a),c}insert(t,n){const r=t._lView,o=r[b];if(function lv(e){return dt(e[ue])}(r)){const c=this.indexOf(t);if(-1!==c)this.detach(c);else{const d=r[ue],p=new tg(d,d[Me],d[ue]);p.detach(p.indexOf(t))}}const i=this._adjustIndex(n),s=this._lContainer;!function xw(e,t,n,r){const o=Ne+r,i=n.length;r>0&&(n[o-1][ct]=t),r<i-Ne?(t[ct]=n[o],md(n,Ne+r,t)):(n.push(t),t[ct]=null),t[ue]=n;const s=t[Sr];null!==s&&n!==s&&function kw(e,t){const n=e[Fn];t[xe]!==t[ue][ue][xe]&&(e[Pc]=!0),null===n?e[Fn]=[t]:n.push(t)}(s,t);const a=t[Et];null!==a&&a.insertView(e),t[j]|=64}(o,r,s,i);const a=_a(i,s),l=r[$],u=ei(l,s[Fo]);return null!==u&&function Sw(e,t,n,r,o,i){r[jt]=o,r[Me]=t,Hr(e,r,n,1,o,i)}(o,s[Me],l,r,u,a),t.attachToViewContainerRef(),md(xl(s),i,t),t}move(t,n){return this.insert(t,n)}indexOf(t){const n=ng(this._lContainer);return null!==n?n.indexOf(t):-1}remove(t){const n=this._adjustIndex(t,-1),r=Da(this._lContainer,n);r&&(Zo(xl(this._lContainer),n),Hd(r[b],r))}detach(t){const n=this._adjustIndex(t,-1),r=Da(this._lContainer,n);return r&&null!=Zo(xl(this._lContainer),n)?new Gr(r):null}_adjustIndex(t,n=0){return t??this.length+n}};function ng(e){return e[Oo]}function xl(e){return e[Oo]||(e[Oo]=[])}function Mi(...e){}const Tg=new A("Application Initializer");let xi=(()=>{class e{constructor(n){this.appInits=n,this.resolve=Mi,this.reject=Mi,this.initialized=!1,this.done=!1,this.donePromise=new Promise((r,o)=>{this.resolve=r,this.reject=o})}runInitializers(){if(this.initialized)return;const n=[],r=()=>{this.done=!0,this.resolve()};if(this.appInits)for(let o=0;o<this.appInits.length;o++){const i=this.appInits[o]();if(cl(i))n.push(i);else if(yE(i)){const s=new Promise((a,l)=>{i.subscribe({complete:a,error:l})});n.push(s)}}Promise.all(n).then(()=>{r()}).catch(o=>{this.reject(o)}),0===n.length&&r(),this.initialized=!0}}return e.\u0275fac=function(n){return new(n||e)(H(Tg,8))},e.\u0275prov=q({token:e,factory:e.\u0275fac,providedIn:"root"}),e})();const ro=new A("AppId",{providedIn:"root",factory:function Mg(){return`${Bl()}${Bl()}${Bl()}`}});function Bl(){return String.fromCharCode(97+Math.floor(25*Math.random()))}const xg=new A("Platform Initializer"),Hl=new A("Platform ID",{providedIn:"platform",factory:()=>"unknown"}),Wt=new A("LocaleId",{providedIn:"root",factory:()=>_r(Wt,P.Optional|P.SkipSelf)||function wI(){return typeof $localize<"u"&&$localize.locale||fr}()}),II=(()=>Promise.resolve(0))();function $l(e){typeof Zone>"u"?II.then(()=>{e&&e.apply(null,null)}):Zone.current.scheduleMicroTask("scheduleMicrotask",e)}class Pe{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:n=!1,shouldCoalesceRunChangeDetection:r=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new kt(!1),this.onMicrotaskEmpty=new kt(!1),this.onStable=new kt(!1),this.onError=new kt(!1),typeof Zone>"u")throw new C(908,!1);Zone.assertZonePatched();const o=this;o._nesting=0,o._outer=o._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(o._inner=o._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(o._inner=o._inner.fork(Zone.longStackTraceZoneSpec)),o.shouldCoalesceEventChangeDetection=!r&&n,o.shouldCoalesceRunChangeDetection=r,o.lastRequestAnimationFrameId=-1,o.nativeRequestAnimationFrame=function SI(){let e=ne.requestAnimationFrame,t=ne.cancelAnimationFrame;if(typeof Zone<"u"&&e&&t){const n=e[Zone.__symbol__("OriginalDelegate")];n&&(e=n);const r=t[Zone.__symbol__("OriginalDelegate")];r&&(t=r)}return{nativeRequestAnimationFrame:e,nativeCancelAnimationFrame:t}}().nativeRequestAnimationFrame,function xI(e){const t=()=>{!function MI(e){e.isCheckStableRunning||-1!==e.lastRequestAnimationFrameId||(e.lastRequestAnimationFrameId=e.nativeRequestAnimationFrame.call(ne,()=>{e.fakeTopEventTask||(e.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{e.lastRequestAnimationFrameId=-1,Ul(e),e.isCheckStableRunning=!0,Vl(e),e.isCheckStableRunning=!1},void 0,()=>{},()=>{})),e.fakeTopEventTask.invoke()}),Ul(e))}(e)};e._inner=e._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(n,r,o,i,s,a)=>{try{return Pg(e),n.invokeTask(o,i,s,a)}finally{(e.shouldCoalesceEventChangeDetection&&"eventTask"===i.type||e.shouldCoalesceRunChangeDetection)&&t(),Ng(e)}},onInvoke:(n,r,o,i,s,a,l)=>{try{return Pg(e),n.invoke(o,i,s,a,l)}finally{e.shouldCoalesceRunChangeDetection&&t(),Ng(e)}},onHasTask:(n,r,o,i)=>{n.hasTask(o,i),r===o&&("microTask"==i.change?(e._hasPendingMicrotasks=i.microTask,Ul(e),Vl(e)):"macroTask"==i.change&&(e.hasPendingMacrotasks=i.macroTask))},onHandleError:(n,r,o,i)=>(n.handleError(o,i),e.runOutsideAngular(()=>e.onError.emit(i)),!1)})}(o)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Pe.isInAngularZone())throw new C(909,!1)}static assertNotInAngularZone(){if(Pe.isInAngularZone())throw new C(909,!1)}run(t,n,r){return this._inner.run(t,n,r)}runTask(t,n,r,o){const i=this._inner,s=i.scheduleEventTask("NgZoneEvent: "+o,t,TI,Mi,Mi);try{return i.runTask(s,n,r)}finally{i.cancelTask(s)}}runGuarded(t,n,r){return this._inner.runGuarded(t,n,r)}runOutsideAngular(t){return this._outer.run(t)}}const TI={};function Vl(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 Ul(e){e.hasPendingMicrotasks=!!(e._hasPendingMicrotasks||(e.shouldCoalesceEventChangeDetection||e.shouldCoalesceRunChangeDetection)&&-1!==e.lastRequestAnimationFrameId)}function Pg(e){e._nesting++,e.isStable&&(e.isStable=!1,e.onUnstable.emit(null))}function Ng(e){e._nesting--,Vl(e)}class kI{constructor(){this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new kt,this.onMicrotaskEmpty=new kt,this.onStable=new kt,this.onError=new kt}run(t,n,r){return t.apply(n,r)}runGuarded(t,n,r){return t.apply(n,r)}runOutsideAngular(t){return t()}runTask(t,n,r,o){return t.apply(n,r)}}const Rg=new A(""),ki=new A("");let ql,zl=(()=>{class e{constructor(n,r,o){this._ngZone=n,this.registry=r,this._pendingCount=0,this._isZoneStable=!0,this._didWork=!1,this._callbacks=[],this.taskTrackingZone=null,ql||(function AI(e){ql=e}(o),o.addToWindow(r)),this._watchAngularEvents(),n.run(()=>{this.taskTrackingZone=typeof Zone>"u"?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:()=>{Pe.assertNotInAngularZone(),$l(()=>{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())$l(()=>{for(;0!==this._callbacks.length;){let n=this._callbacks.pop();clearTimeout(n.timeoutId),n.doneCb(this._didWork)}this._didWork=!1});else{let n=this.getPendingTasks();this._callbacks=this._callbacks.filter(r=>!r.updateCb||!r.updateCb(n)||(clearTimeout(r.timeoutId),!1)),this._didWork=!0}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(n=>({source:n.source,creationLocation:n.creationLocation,data:n.data})):[]}addCallback(n,r,o){let i=-1;r&&r>0&&(i=setTimeout(()=>{this._callbacks=this._callbacks.filter(s=>s.timeoutId!==i),n(this._didWork,this.getPendingTasks())},r)),this._callbacks.push({doneCb:n,timeoutId:i,updateCb:o})}whenStable(n,r,o){if(o&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/plugins/task-tracking" loaded?');this.addCallback(n,r,o),this._runCallbacksIfReady()}getPendingRequestCount(){return this._pendingCount}registerApplication(n){this.registry.registerApplication(n,this)}unregisterApplication(n){this.registry.unregisterApplication(n)}findProviders(n,r,o){return[]}}return e.\u0275fac=function(n){return new(n||e)(H(Pe),H(Gl),H(ki))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})(),Gl=(()=>{class e{constructor(){this._applications=new Map}registerApplication(n,r){this._applications.set(n,r)}unregisterApplication(n){this._applications.delete(n)}unregisterAllApplications(){this._applications.clear()}getTestability(n){return this._applications.get(n)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(n,r=!0){return ql?.findTestabilityInTree(this,n,r)??null}}return e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=q({token:e,factory:e.\u0275fac,providedIn:"platform"}),e})();const Zt=!1;let sn=null;const Fg=new A("AllowMultipleToken"),Wl=new A("PlatformDestroyListeners"),PI=new A("appBootstrapListener");function Lg(e,t,n=[]){const r=`Platform: ${t}`,o=new A(r);return(i=[])=>{let s=Zl();if(!s||s.injector.get(Fg,!1)){const a=[...n,...i,{provide:o,useValue:!0}];e?e(a):function FI(e){if(sn&&!sn.get(Fg,!1))throw new C(400,!1);sn=e;const t=e.get(Bg);(function Og(e){const t=e.get(xg,null);t&&t.forEach(n=>n())})(e)}(function jg(e=[],t){return wn.create({name:t,providers:[{provide:Fa,useValue:"platform"},{provide:Wl,useValue:new Set([()=>sn=null])},...e]})}(a,r))}return function LI(e){const t=Zl();if(!t)throw new C(401,!1);return t}()}}function Zl(){return sn?.get(Bg)??null}let Bg=(()=>{class e{constructor(n){this._injector=n,this._modules=[],this._destroyListeners=[],this._destroyed=!1}bootstrapModuleFactory(n,r){const o=function $g(e,t){let n;return n="noop"===e?new kI:("zone.js"===e?void 0:e)||new Pe(t),n}(r?.ngZone,function Hg(e){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:!(!e||!e.ngZoneEventCoalescing)||!1,shouldCoalesceRunChangeDetection:!(!e||!e.ngZoneRunCoalescing)||!1}}(r)),i=[{provide:Pe,useValue:o}];return o.run(()=>{const s=wn.create({providers:i,parent:this.injector,name:n.moduleType.name}),a=n.create(s),l=a.injector.get(Qn,null);if(!l)throw new C(402,!1);return o.runOutsideAngular(()=>{const u=o.onError.subscribe({next:c=>{l.handleError(c)}});a.onDestroy(()=>{Ai(this._modules,a),u.unsubscribe()})}),function Vg(e,t,n){try{const r=n();return cl(r)?r.catch(o=>{throw t.runOutsideAngular(()=>e.handleError(o)),o}):r}catch(r){throw t.runOutsideAngular(()=>e.handleError(r)),r}}(l,o,()=>{const u=a.injector.get(xi);return u.runInitializers(),u.donePromise.then(()=>(function yh(e){Ye(e,"Expected localeId to be defined"),"string"==typeof e&&(mh=e.toLowerCase().replace(/_/g,"-"))}(a.injector.get(Wt,fr)||fr),this._moduleDoBootstrap(a),a))})})}bootstrapModule(n,r=[]){const o=Ug({},r);return function NI(e,t,n){const r=new Cl(n);return Promise.resolve(r)}(0,0,n).then(i=>this.bootstrapModuleFactory(i,o))}_moduleDoBootstrap(n){const r=n.injector.get(Jl);if(n._bootstrapComponents.length>0)n._bootstrapComponents.forEach(o=>r.bootstrap(o));else{if(!n.instance.ngDoBootstrap)throw new C(-403,!1);n.instance.ngDoBootstrap(r)}this._modules.push(n)}onDestroy(n){this._destroyListeners.push(n)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new C(404,!1);this._modules.slice().forEach(r=>r.destroy()),this._destroyListeners.forEach(r=>r());const n=this._injector.get(Wl,null);n&&(n.forEach(r=>r()),n.clear()),this._destroyed=!0}get destroyed(){return this._destroyed}}return e.\u0275fac=function(n){return new(n||e)(H(wn))},e.\u0275prov=q({token:e,factory:e.\u0275fac,providedIn:"platform"}),e})();function Ug(e,t){return Array.isArray(t)?t.reduce(Ug,e):{...e,...t}}let Jl=(()=>{class e{get destroyed(){return this._destroyed}get injector(){return this._injector}constructor(n,r,o){this._zone=n,this._injector=r,this._exceptionHandler=o,this._bootstrapListeners=[],this._views=[],this._runningTick=!1,this._stable=!0,this._destroyed=!1,this._destroyListeners=[],this.componentTypes=[],this.components=[],this._onMicrotaskEmptySubscription=this._zone.onMicrotaskEmpty.subscribe({next:()=>{this._zone.run(()=>{this.tick()})}});const i=new Ie(a=>{this._stable=this._zone.isStable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks,this._zone.runOutsideAngular(()=>{a.next(this._stable),a.complete()})}),s=new Ie(a=>{let l;this._zone.runOutsideAngular(()=>{l=this._zone.onStable.subscribe(()=>{Pe.assertNotInAngularZone(),$l(()=>{!this._stable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks&&(this._stable=!0,a.next(!0))})})});const u=this._zone.onUnstable.subscribe(()=>{Pe.assertInAngularZone(),this._stable&&(this._stable=!1,this._zone.runOutsideAngular(()=>{a.next(!1)}))});return()=>{l.unsubscribe(),u.unsubscribe()}});this.isStable=function MD(...e){const t=hc(e),n=function _D(e,t){return"number"==typeof _s(e)?e.pop():t}(e,1/0),r=e;return r.length?1===r.length?Qt(r[0]):function DD(e=1/0){return Eo(Ju,e)}(n)(Dc(r,t)):pc}(i,s.pipe(function xD(e={}){const{connector:t=(()=>new ms),resetOnError:n=!0,resetOnComplete:r=!0,resetOnRefCountZero:o=!0}=e;return i=>{let s,a,l,u=0,c=!1,d=!1;const p=()=>{a?.unsubscribe(),a=void 0},f=()=>{p(),s=l=void 0,c=d=!1},h=()=>{const g=s;f(),g?.unsubscribe()};return Mn((g,m)=>{u++,!d&&!c&&p();const D=l=l??t();m.add(()=>{u--,0===u&&!d&&!c&&(a=bs(h,o))}),D.subscribe(m),!s&&u>0&&(s=new yr({next:w=>D.next(w),error:w=>{d=!0,p(),a=bs(f,n,w),D.error(w)},complete:()=>{c=!0,p(),a=bs(f,r),D.complete()}}),Qt(g).subscribe(s))})(i)}}()))}bootstrap(n,r){const o=n instanceof Ef;if(!this._injector.get(xi).done){!o&&function Cr(e){const t=K(e)||Te(e)||Be(e);return null!==t&&t.standalone}(n);throw new C(405,Zt)}let s;s=o?n:this._injector.get(ui).resolveComponentFactory(n),this.componentTypes.push(s.componentType);const a=function RI(e){return e.isBoundToModule}(s)?void 0:this._injector.get(pr),u=s.create(wn.NULL,[],r||s.selector,a),c=u.location.nativeElement,d=u.injector.get(Rg,null);return d?.registerApplication(c),u.onDestroy(()=>{this.detachView(u.hostView),Ai(this.components,u),d?.unregisterApplication(c)}),this._loadComponent(u),u}tick(){if(this._runningTick)throw new C(101,!1);try{this._runningTick=!0;for(let n of this._views)n.detectChanges()}catch(n){this._zone.runOutsideAngular(()=>this._exceptionHandler.handleError(n))}finally{this._runningTick=!1}}attachView(n){const r=n;this._views.push(r),r.attachToAppRef(this)}detachView(n){const r=n;Ai(this._views,r),r.detachFromAppRef()}_loadComponent(n){this.attachView(n.hostView),this.tick(),this.components.push(n);const r=this._injector.get(PI,[]);r.push(...this._bootstrapListeners),r.forEach(o=>o(n))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(n=>n()),this._views.slice().forEach(n=>n.destroy()),this._onMicrotaskEmptySubscription.unsubscribe()}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(n){return this._destroyListeners.push(n),()=>Ai(this._destroyListeners,n)}destroy(){if(this._destroyed)throw new C(406,!1);const n=this._injector;n.destroy&&!n.destroyed&&n.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}}return e.\u0275fac=function(n){return new(n||e)(H(Pe),H(vn),H(Qn))},e.\u0275prov=q({token:e,factory:e.\u0275fac,providedIn:"root"}),e})();function Ai(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class Zg{constructor(){}supports(t){return Di(t)}create(t){return new WI(t)}}const qI=(e,t)=>t;class WI{constructor(t){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=t||qI}forEachItem(t){let n;for(n=this._itHead;null!==n;n=n._next)t(n)}forEachOperation(t){let n=this._itHead,r=this._removalsHead,o=0,i=null;for(;n||r;){const s=!r||n&&n.currentIndex<Kg(r,o,i)?n:r,a=Kg(s,o,i),l=s.currentIndex;if(s===r)o--,r=r._nextRemoved;else if(n=n._next,null==s.previousIndex)o++;else{i||(i=[]);const u=a-o,c=l-o;if(u!=c){for(let p=0;p<u;p++){const f=p<i.length?i[p]:i[p]=0,h=f+p;c<=h&&h<u&&(i[p]=f+1)}i[s.previousIndex]=c-u}}a!==l&&t(s,a,l)}}forEachPreviousItem(t){let n;for(n=this._previousItHead;null!==n;n=n._nextPrevious)t(n)}forEachAddedItem(t){let n;for(n=this._additionsHead;null!==n;n=n._nextAdded)t(n)}forEachMovedItem(t){let n;for(n=this._movesHead;null!==n;n=n._nextMoved)t(n)}forEachRemovedItem(t){let n;for(n=this._removalsHead;null!==n;n=n._nextRemoved)t(n)}forEachIdentityChange(t){let n;for(n=this._identityChangesHead;null!==n;n=n._nextIdentityChange)t(n)}diff(t){if(null==t&&(t=[]),!Di(t))throw new C(900,!1);return this.check(t)?this:null}onDestroy(){}check(t){this._reset();let o,i,s,n=this._itHead,r=!1;if(Array.isArray(t)){this.length=t.length;for(let a=0;a<this.length;a++)i=t[a],s=this._trackByFn(a,i),null!==n&&Object.is(n.trackById,s)?(r&&(n=this._verifyReinsertion(n,i,s,a)),Object.is(n.item,i)||this._addIdentityChange(n,i)):(n=this._mismatch(n,i,s,a),r=!0),n=n._next}else o=0,function uE(e,t){if(Array.isArray(e))for(let n=0;n<e.length;n++)t(e[n]);else{const n=e[Symbol.iterator]();let r;for(;!(r=n.next()).done;)t(r.value)}}(t,a=>{s=this._trackByFn(o,a),null!==n&&Object.is(n.trackById,s)?(r&&(n=this._verifyReinsertion(n,a,s,o)),Object.is(n.item,a)||this._addIdentityChange(n,a)):(n=this._mismatch(n,a,s,o),r=!0),n=n._next,o++}),this.length=o;return this._truncate(n),this.collection=t,this.isDirty}get isDirty(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}_reset(){if(this.isDirty){let t;for(t=this._previousItHead=this._itHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._additionsHead;null!==t;t=t._nextAdded)t.previousIndex=t.currentIndex;for(this._additionsHead=this._additionsTail=null,t=this._movesHead;null!==t;t=t._nextMoved)t.previousIndex=t.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(t,n,r,o){let i;return null===t?i=this._itTail:(i=t._prev,this._remove(t)),null!==(t=null===this._unlinkedRecords?null:this._unlinkedRecords.get(r,null))?(Object.is(t.item,n)||this._addIdentityChange(t,n),this._reinsertAfter(t,i,o)):null!==(t=null===this._linkedRecords?null:this._linkedRecords.get(r,o))?(Object.is(t.item,n)||this._addIdentityChange(t,n),this._moveAfter(t,i,o)):t=this._addAfter(new ZI(n,r),i,o),t}_verifyReinsertion(t,n,r,o){let i=null===this._unlinkedRecords?null:this._unlinkedRecords.get(r,null);return null!==i?t=this._reinsertAfter(i,t._prev,o):t.currentIndex!=o&&(t.currentIndex=o,this._addToMoves(t,o)),t}_truncate(t){for(;null!==t;){const n=t._next;this._addToRemovals(this._unlink(t)),t=n}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(t,n,r){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(t);const o=t._prevRemoved,i=t._nextRemoved;return null===o?this._removalsHead=i:o._nextRemoved=i,null===i?this._removalsTail=o:i._prevRemoved=o,this._insertAfter(t,n,r),this._addToMoves(t,r),t}_moveAfter(t,n,r){return this._unlink(t),this._insertAfter(t,n,r),this._addToMoves(t,r),t}_addAfter(t,n,r){return this._insertAfter(t,n,r),this._additionsTail=null===this._additionsTail?this._additionsHead=t:this._additionsTail._nextAdded=t,t}_insertAfter(t,n,r){const o=null===n?this._itHead:n._next;return t._next=o,t._prev=n,null===o?this._itTail=t:o._prev=t,null===n?this._itHead=t:n._next=t,null===this._linkedRecords&&(this._linkedRecords=new Jg),this._linkedRecords.put(t),t.currentIndex=r,t}_remove(t){return this._addToRemovals(this._unlink(t))}_unlink(t){null!==this._linkedRecords&&this._linkedRecords.remove(t);const n=t._prev,r=t._next;return null===n?this._itHead=r:n._next=r,null===r?this._itTail=n:r._prev=n,t}_addToMoves(t,n){return t.previousIndex===n||(this._movesTail=null===this._movesTail?this._movesHead=t:this._movesTail._nextMoved=t),t}_addToRemovals(t){return null===this._unlinkedRecords&&(this._unlinkedRecords=new Jg),this._unlinkedRecords.put(t),t.currentIndex=null,t._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=t,t._prevRemoved=null):(t._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=t),t}_addIdentityChange(t,n){return t.item=n,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=t:this._identityChangesTail._nextIdentityChange=t,t}}class ZI{constructor(t,n){this.item=t,this.trackById=n,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 JI{constructor(){this._head=null,this._tail=null}add(t){null===this._head?(this._head=this._tail=t,t._nextDup=null,t._prevDup=null):(this._tail._nextDup=t,t._prevDup=this._tail,t._nextDup=null,this._tail=t)}get(t,n){let r;for(r=this._head;null!==r;r=r._nextDup)if((null===n||n<=r.currentIndex)&&Object.is(r.trackById,t))return r;return null}remove(t){const n=t._prevDup,r=t._nextDup;return null===n?this._head=r:n._nextDup=r,null===r?this._tail=n:r._prevDup=n,null===this._head}}class Jg{constructor(){this.map=new Map}put(t){const n=t.trackById;let r=this.map.get(n);r||(r=new JI,this.map.set(n,r)),r.add(t)}get(t,n){const o=this.map.get(t);return o?o.get(t,n):null}remove(t){const n=t.trackById;return this.map.get(n).remove(t)&&this.map.delete(n),t}get isEmpty(){return 0===this.map.size}clear(){this.map.clear()}}function Kg(e,t,n){const r=e.previousIndex;if(null===r)return r;let o=0;return n&&r<n.length&&(o=n[r]),r+t+o}class Qg{constructor(){}supports(t){return t instanceof Map||sl(t)}create(){return new KI}}class KI{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(t){let n;for(n=this._mapHead;null!==n;n=n._next)t(n)}forEachPreviousItem(t){let n;for(n=this._previousMapHead;null!==n;n=n._nextPrevious)t(n)}forEachChangedItem(t){let n;for(n=this._changesHead;null!==n;n=n._nextChanged)t(n)}forEachAddedItem(t){let n;for(n=this._additionsHead;null!==n;n=n._nextAdded)t(n)}forEachRemovedItem(t){let n;for(n=this._removalsHead;null!==n;n=n._nextRemoved)t(n)}diff(t){if(t){if(!(t instanceof Map||sl(t)))throw new C(900,!1)}else t=new Map;return this.check(t)?this:null}onDestroy(){}check(t){this._reset();let n=this._mapHead;if(this._appendAfter=null,this._forEach(t,(r,o)=>{if(n&&n.key===o)this._maybeAddToChanges(n,r),this._appendAfter=n,n=n._next;else{const i=this._getOrCreateRecordForKey(o,r);n=this._insertBeforeOrAppend(n,i)}}),n){n._prev&&(n._prev._next=null),this._removalsHead=n;for(let r=n;null!==r;r=r._nextRemoved)r===this._mapHead&&(this._mapHead=null),this._records.delete(r.key),r._nextRemoved=r._next,r.previousValue=r.currentValue,r.currentValue=null,r._prev=null,r._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(t,n){if(t){const r=t._prev;return n._next=t,n._prev=r,t._prev=n,r&&(r._next=n),t===this._mapHead&&(this._mapHead=n),this._appendAfter=t,t}return this._appendAfter?(this._appendAfter._next=n,n._prev=this._appendAfter):this._mapHead=n,this._appendAfter=n,null}_getOrCreateRecordForKey(t,n){if(this._records.has(t)){const o=this._records.get(t);this._maybeAddToChanges(o,n);const i=o._prev,s=o._next;return i&&(i._next=s),s&&(s._prev=i),o._next=null,o._prev=null,o}const r=new QI(t);return this._records.set(t,r),r.currentValue=n,this._addToAdditions(r),r}_reset(){if(this.isDirty){let t;for(this._previousMapHead=this._mapHead,t=this._previousMapHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._changesHead;null!==t;t=t._nextChanged)t.previousValue=t.currentValue;for(t=this._additionsHead;null!=t;t=t._nextAdded)t.previousValue=t.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(t,n){Object.is(n,t.currentValue)||(t.previousValue=t.currentValue,t.currentValue=n,this._addToChanges(t))}_addToAdditions(t){null===this._additionsHead?this._additionsHead=this._additionsTail=t:(this._additionsTail._nextAdded=t,this._additionsTail=t)}_addToChanges(t){null===this._changesHead?this._changesHead=this._changesTail=t:(this._changesTail._nextChanged=t,this._changesTail=t)}_forEach(t,n){t instanceof Map?t.forEach(n):Object.keys(t).forEach(r=>n(t[r],r))}}class QI{constructor(t){this.key=t,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._prev=null,this._nextAdded=null,this._nextRemoved=null,this._nextChanged=null}}function Yg(){return new Ri([new Zg])}let Ri=(()=>{class e{constructor(n){this.factories=n}static create(n,r){if(null!=r){const o=r.factories.slice();n=n.concat(o)}return new e(n)}static extend(n){return{provide:e,useFactory:r=>e.create(n,r||Yg()),deps:[[e,new Qo,new Ko]]}}find(n){const r=this.factories.find(o=>o.supports(n));if(null!=r)return r;throw new C(901,!1)}}return e.\u0275prov=q({token:e,providedIn:"root",factory:Yg}),e})();function Xg(){return new oo([new Qg])}let oo=(()=>{class e{constructor(n){this.factories=n}static create(n,r){if(r){const o=r.factories.slice();n=n.concat(o)}return new e(n)}static extend(n){return{provide:e,useFactory:r=>e.create(n,r||Xg()),deps:[[e,new Qo,new Ko]]}}find(n){const r=this.factories.find(o=>o.supports(n));if(r)return r;throw new C(901,!1)}}return e.\u0275prov=q({token:e,providedIn:"root",factory:Xg}),e})();const eS=Lg(null,"core",[]);let tS=(()=>{class e{constructor(n){}}return e.\u0275fac=function(n){return new(n||e)(H(Jl))},e.\u0275mod=An({type:e}),e.\u0275inj=dn({}),e})(),eu=null;function Fi(){return eu}class oS{}const Pt=new A("DocumentToken");function um(e,t){t=encodeURIComponent(t);for(const n of e.split(";")){const r=n.indexOf("="),[o,i]=-1==r?[n,""]:[n.slice(0,r),n.slice(r+1)];if(o.trim()===t)return decodeURIComponent(i)}return null}const cu=/\s+/,cm=[];let du=(()=>{class e{constructor(n,r,o,i){this._iterableDiffers=n,this._keyValueDiffers=r,this._ngEl=o,this._renderer=i,this.initialClasses=cm,this.stateMap=new Map}set klass(n){this.initialClasses=null!=n?n.trim().split(cu):cm}set ngClass(n){this.rawClass="string"==typeof n?n.trim().split(cu):n}ngDoCheck(){for(const r of this.initialClasses)this._updateState(r,!0);const n=this.rawClass;if(Array.isArray(n)||n instanceof Set)for(const r of n)this._updateState(r,!0);else if(null!=n)for(const r of Object.keys(n))this._updateState(r,Boolean(n[r]));this._applyStateDiff()}_updateState(n,r){const o=this.stateMap.get(n);void 0!==o?(o.enabled!==r&&(o.changed=!0,o.enabled=r),o.touched=!0):this.stateMap.set(n,{enabled:r,changed:!0,touched:!0})}_applyStateDiff(){for(const n of this.stateMap){const r=n[0],o=n[1];o.changed?(this._toggleClass(r,o.enabled),o.changed=!1):o.touched||(o.enabled&&this._toggleClass(r,!1),this.stateMap.delete(r)),o.touched=!1}}_toggleClass(n,r){(n=n.trim()).length>0&&n.split(cu).forEach(o=>{r?this._renderer.addClass(this._ngEl.nativeElement,o):this._renderer.removeClass(this._ngEl.nativeElement,o)})}}return e.\u0275fac=function(n){return new(n||e)(L(Ri),L(oo),L(Kn),L(Sf))},e.\u0275dir=et({type:e,selectors:[["","ngClass",""]],inputs:{klass:["class","klass"],ngClass:"ngClass"},standalone:!0}),e})();class zS{constructor(t,n,r,o){this.$implicit=t,this.ngForOf=n,this.index=r,this.count=o}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}}let pm=(()=>{class e{set ngForOf(n){this._ngForOf=n,this._ngForOfDirty=!0}set ngForTrackBy(n){this._trackByFn=n}get ngForTrackBy(){return this._trackByFn}constructor(n,r,o){this._viewContainer=n,this._template=r,this._differs=o,this._ngForOf=null,this._ngForOfDirty=!0,this._differ=null}set ngForTemplate(n){n&&(this._template=n)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;const n=this._ngForOf;!this._differ&&n&&(this._differ=this._differs.find(n).create(this.ngForTrackBy))}if(this._differ){const n=this._differ.diff(this._ngForOf);n&&this._applyChanges(n)}}_applyChanges(n){const r=this._viewContainer;n.forEachOperation((o,i,s)=>{if(null==o.previousIndex)r.createEmbeddedView(this._template,new zS(o.item,this._ngForOf,-1,-1),null===s?void 0:s);else if(null==s)r.remove(null===i?void 0:i);else if(null!==i){const a=r.get(i);r.move(a,s),hm(a,o)}});for(let o=0,i=r.length;o<i;o++){const a=r.get(o).context;a.index=o,a.count=i,a.ngForOf=this._ngForOf}n.forEachIdentityChange(o=>{hm(r.get(o.currentIndex),o)})}static ngTemplateContextGuard(n,r){return!0}}return e.\u0275fac=function(n){return new(n||e)(L(At),L(qt),L(Ri))},e.\u0275dir=et({type:e,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"},standalone:!0}),e})();function hm(e,t){e.context.$implicit=t.item}let Gi=(()=>{class e{constructor(n,r){this._viewContainer=n,this._context=new qS,this._thenTemplateRef=null,this._elseTemplateRef=null,this._thenViewRef=null,this._elseViewRef=null,this._thenTemplateRef=r}set ngIf(n){this._context.$implicit=this._context.ngIf=n,this._updateView()}set ngIfThen(n){gm("ngIfThen",n),this._thenTemplateRef=n,this._thenViewRef=null,this._updateView()}set ngIfElse(n){gm("ngIfElse",n),this._elseTemplateRef=n,this._elseViewRef=null,this._updateView()}_updateView(){this._context.$implicit?this._thenViewRef||(this._viewContainer.clear(),this._elseViewRef=null,this._thenTemplateRef&&(this._thenViewRef=this._viewContainer.createEmbeddedView(this._thenTemplateRef,this._context))):this._elseViewRef||(this._viewContainer.clear(),this._thenViewRef=null,this._elseTemplateRef&&(this._elseViewRef=this._viewContainer.createEmbeddedView(this._elseTemplateRef,this._context)))}static ngTemplateContextGuard(n,r){return!0}}return e.\u0275fac=function(n){return new(n||e)(L(At),L(qt))},e.\u0275dir=et({type:e,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"},standalone:!0}),e})();class qS{constructor(){this.$implicit=null,this.ngIf=null}}function gm(e,t){if(t&&!t.createEmbeddedView)throw new Error(`${e} must be a TemplateRef, but received '${ee(t)}'.`)}const tT=/(?:[0-9A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF40\uDF42-\uDF49\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDD70-\uDD7A\uDD7C-\uDD8A\uDD8C-\uDD92\uDD94\uDD95\uDD97-\uDDA1\uDDA3-\uDDB1\uDDB3-\uDDB9\uDDBB\uDDBC\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE35\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2\uDD00-\uDD23\uDE80-\uDEA9\uDEB0\uDEB1\uDF00-\uDF1C\uDF27\uDF30-\uDF45\uDF70-\uDF81\uDFB0-\uDFC4\uDFE0-\uDFF6]|\uD804[\uDC03-\uDC37\uDC71\uDC72\uDC75\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD44\uDD47\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC5F-\uDC61\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDEB8\uDF00-\uDF1A\uDF40-\uDF46]|\uD806[\uDC00-\uDC2B\uDCA0-\uDCDF\uDCFF-\uDD06\uDD09\uDD0C-\uDD13\uDD15\uDD16\uDD18-\uDD2F\uDD3F\uDD41\uDDA0-\uDDA7\uDDAA-\uDDD0\uDDE1\uDDE3\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE89\uDE9D\uDEB0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46\uDD60-\uDD65\uDD67\uDD68\uDD6A-\uDD89\uDD98\uDEE0-\uDEF2\uDFB0]|\uD808[\uDC00-\uDF99]|\uD809[\uDC80-\uDD43]|\uD80B[\uDF90-\uDFF0]|[\uD80C\uD81C-\uD820\uD822\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE70-\uDEBE\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDE40-\uDE7F\uDF00-\uDF4A\uDF50\uDF93-\uDF9F\uDFE0\uDFE1\uDFE3]|\uD821[\uDC00-\uDFF7]|\uD823[\uDC00-\uDCD5\uDD00-\uDD08]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD50-\uDD52\uDD64-\uDD67\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD837[\uDF00-\uDF1E]|\uD838[\uDD00-\uDD2C\uDD37-\uDD3D\uDD4E\uDE90-\uDEAD\uDEC0-\uDEEB]|\uD839[\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43\uDD4B]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF38\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A])\S*/g;let ym=(()=>{class e{transform(n){if(null==n)return null;if("string"!=typeof n)throw function Dt(e,t){return new C(2100,!1)}();return n.replace(tT,r=>r[0].toUpperCase()+r.slice(1).toLowerCase())}}return e.\u0275fac=function(n){return new(n||e)},e.\u0275pipe=Se({name:"titlecase",type:e,pure:!0,standalone:!0}),e})(),mT=(()=>{class e{}return e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=An({type:e}),e.\u0275inj=dn({}),e})();class _m{}class WT extends oS{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class Du extends WT{static makeCurrent(){!function rS(e){eu||(eu=e)}(new Du)}onAndCancel(t,n,r){return t.addEventListener(n,r,!1),()=>{t.removeEventListener(n,r,!1)}}dispatchEvent(t,n){t.dispatchEvent(n)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,n){return(n=n||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,n){return"window"===n?window:"document"===n?t:"body"===n?t.body:null}getBaseHref(t){const n=function ZT(){return lo=lo||document.querySelector("base"),lo?lo.getAttribute("href"):null}();return null==n?null:function JT(e){Zi=Zi||document.createElement("a"),Zi.setAttribute("href",e);const t=Zi.pathname;return"/"===t.charAt(0)?t:`/${t}`}(n)}resetBaseElement(){lo=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return um(document.cookie,t)}}let Zi,lo=null;const Sm=new A("TRANSITION_ID"),QT=[{provide:Tg,useFactory:function KT(e,t,n){return()=>{n.get(xi).donePromise.then(()=>{const r=Fi(),o=t.querySelectorAll(`style[ng-transition="${e}"]`);for(let i=0;i<o.length;i++)r.remove(o[i])})}},deps:[Sm,Pt,wn],multi:!0}];let XT=(()=>{class e{build(){return new XMLHttpRequest}}return e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();const Ji=new A("EventManagerPlugins");let Ki=(()=>{class e{constructor(n,r){this._zone=r,this._eventNameToPlugin=new Map,n.forEach(o=>{o.manager=this}),this._plugins=n.slice().reverse()}addEventListener(n,r,o){return this._findPluginFor(r).addEventListener(n,r,o)}addGlobalEventListener(n,r,o){return this._findPluginFor(r).addGlobalEventListener(n,r,o)}getZone(){return this._zone}_findPluginFor(n){const r=this._eventNameToPlugin.get(n);if(r)return r;const o=this._plugins;for(let i=0;i<o.length;i++){const s=o[i];if(s.supports(n))return this._eventNameToPlugin.set(n,s),s}throw new Error(`No event manager plugin found for event ${n}`)}}return e.\u0275fac=function(n){return new(n||e)(H(Ji),H(Pe))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();class Tm{constructor(t){this._doc=t}addGlobalEventListener(t,n,r){const o=Fi().getGlobalEventTarget(this._doc,t);if(!o)throw new Error(`Unsupported event target ${o} for event ${n}`);return this.addEventListener(o,n,r)}}let Mm=(()=>{class e{constructor(){this.usageCount=new Map}addStyles(n){for(const r of n)1===this.changeUsageCount(r,1)&&this.onStyleAdded(r)}removeStyles(n){for(const r of n)0===this.changeUsageCount(r,-1)&&this.onStyleRemoved(r)}onStyleRemoved(n){}onStyleAdded(n){}getAllStyles(){return this.usageCount.keys()}changeUsageCount(n,r){const o=this.usageCount;let i=o.get(n)??0;return i+=r,i>0?o.set(n,i):o.delete(n),i}ngOnDestroy(){for(const n of this.getAllStyles())this.onStyleRemoved(n);this.usageCount.clear()}}return e.\u0275fac=function(n){return new(n||e)},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})(),uo=(()=>{class e extends Mm{constructor(n){super(),this.doc=n,this.styleRef=new Map,this.hostNodes=new Set,this.resetHostNodes()}onStyleAdded(n){for(const r of this.hostNodes)this.addStyleToHost(r,n)}onStyleRemoved(n){const r=this.styleRef;r.get(n)?.forEach(i=>i.remove()),r.delete(n)}ngOnDestroy(){super.ngOnDestroy(),this.styleRef.clear(),this.resetHostNodes()}addHost(n){this.hostNodes.add(n);for(const r of this.getAllStyles())this.addStyleToHost(n,r)}removeHost(n){this.hostNodes.delete(n)}addStyleToHost(n,r){const o=this.doc.createElement("style");o.textContent=r,n.appendChild(o);const i=this.styleRef.get(r);i?i.push(o):this.styleRef.set(r,[o])}resetHostNodes(){const n=this.hostNodes;n.clear(),n.add(this.doc.head)}}return e.\u0275fac=function(n){return new(n||e)(H(Pt))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();const vu={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},wu=/%COMP%/g,Am=new A("RemoveStylesOnCompDestory",{providedIn:"root",factory:()=>!1});function Pm(e,t){return t.flat(100).map(n=>n.replace(wu,e))}function Nm(e){return t=>{if("__ngUnwrap__"===t)return e;!1===e(t)&&(t.preventDefault(),t.returnValue=!1)}}let _u=(()=>{class e{constructor(n,r,o,i){this.eventManager=n,this.sharedStylesHost=r,this.appId=o,this.removeStylesOnCompDestory=i,this.rendererByCompId=new Map,this.defaultRenderer=new bu(n)}createRenderer(n,r){if(!n||!r)return this.defaultRenderer;const o=this.getOrCreateRenderer(n,r);return o instanceof Om?o.applyToHost(n):o instanceof Eu&&o.applyStyles(),o}getOrCreateRenderer(n,r){const o=this.rendererByCompId;let i=o.get(r.id);if(!i){const s=this.eventManager,a=this.sharedStylesHost,l=this.removeStylesOnCompDestory;switch(r.encapsulation){case bt.Emulated:i=new Om(s,a,r,this.appId,l);break;case bt.ShadowDom:return new sM(s,a,n,r);default:i=new Eu(s,a,r,l)}i.onDestroy=()=>o.delete(r.id),o.set(r.id,i)}return i}ngOnDestroy(){this.rendererByCompId.clear()}begin(){}end(){}}return e.\u0275fac=function(n){return new(n||e)(H(Ki),H(uo),H(ro),H(Am))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();class bu{constructor(t){this.eventManager=t,this.data=Object.create(null),this.destroyNode=null}destroy(){}createElement(t,n){return n?document.createElementNS(vu[n]||n,t):document.createElement(t)}createComment(t){return document.createComment(t)}createText(t){return document.createTextNode(t)}appendChild(t,n){(Fm(t)?t.content:t).appendChild(n)}insertBefore(t,n,r){t&&(Fm(t)?t.content:t).insertBefore(n,r)}removeChild(t,n){t&&t.removeChild(n)}selectRootElement(t,n){let r="string"==typeof t?document.querySelector(t):t;if(!r)throw new Error(`The selector "${t}" did not match any elements`);return n||(r.textContent=""),r}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,n,r,o){if(o){n=o+":"+n;const i=vu[o];i?t.setAttributeNS(i,n,r):t.setAttribute(n,r)}else t.setAttribute(n,r)}removeAttribute(t,n,r){if(r){const o=vu[r];o?t.removeAttributeNS(o,n):t.removeAttribute(`${r}:${n}`)}else t.removeAttribute(n)}addClass(t,n){t.classList.add(n)}removeClass(t,n){t.classList.remove(n)}setStyle(t,n,r,o){o&($e.DashCase|$e.Important)?t.style.setProperty(n,r,o&$e.Important?"important":""):t.style[n]=r}removeStyle(t,n,r){r&$e.DashCase?t.style.removeProperty(n):t.style[n]=""}setProperty(t,n,r){t[n]=r}setValue(t,n){t.nodeValue=n}listen(t,n,r){return"string"==typeof t?this.eventManager.addGlobalEventListener(t,n,Nm(r)):this.eventManager.addEventListener(t,n,Nm(r))}}function Fm(e){return"TEMPLATE"===e.tagName&&void 0!==e.content}class sM extends bu{constructor(t,n,r,o){super(t),this.sharedStylesHost=n,this.hostEl=r,this.shadowRoot=r.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const i=Pm(o.id,o.styles);for(const s of i){const a=document.createElement("style");a.textContent=s,this.shadowRoot.appendChild(a)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,n){return super.appendChild(this.nodeOrShadowRoot(t),n)}insertBefore(t,n,r){return super.insertBefore(this.nodeOrShadowRoot(t),n,r)}removeChild(t,n){return super.removeChild(this.nodeOrShadowRoot(t),n)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class Eu extends bu{constructor(t,n,r,o,i=r.id){super(t),this.sharedStylesHost=n,this.removeStylesOnCompDestory=o,this.rendererUsageCount=0,this.styles=Pm(i,r.styles)}applyStyles(){this.sharedStylesHost.addStyles(this.styles),this.rendererUsageCount++}destroy(){this.removeStylesOnCompDestory&&(this.sharedStylesHost.removeStyles(this.styles),this.rendererUsageCount--,0===this.rendererUsageCount&&this.onDestroy?.())}}class Om extends Eu{constructor(t,n,r,o,i){const s=o+"-"+r.id;super(t,n,r,i,s),this.contentAttr=function rM(e){return"_ngcontent-%COMP%".replace(wu,e)}(s),this.hostAttr=function oM(e){return"_nghost-%COMP%".replace(wu,e)}(s)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,n){const r=super.createElement(t,n);return super.setAttribute(r,this.contentAttr,""),r}}let aM=(()=>{class e extends Tm{constructor(n){super(n)}supports(n){return!0}addEventListener(n,r,o){return n.addEventListener(r,o,!1),()=>this.removeEventListener(n,r,o)}removeEventListener(n,r,o){return n.removeEventListener(r,o)}}return e.\u0275fac=function(n){return new(n||e)(H(Pt))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();const Lm=["alt","control","meta","shift"],lM={"\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"},uM={alt:e=>e.altKey,control:e=>e.ctrlKey,meta:e=>e.metaKey,shift:e=>e.shiftKey};let cM=(()=>{class e extends Tm{constructor(n){super(n)}supports(n){return null!=e.parseEventName(n)}addEventListener(n,r,o){const i=e.parseEventName(r),s=e.eventCallback(i.fullKey,o,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Fi().onAndCancel(n,i.domEventName,s))}static parseEventName(n){const r=n.toLowerCase().split("."),o=r.shift();if(0===r.length||"keydown"!==o&&"keyup"!==o)return null;const i=e._normalizeKey(r.pop());let s="",a=r.indexOf("code");if(a>-1&&(r.splice(a,1),s="code."),Lm.forEach(u=>{const c=r.indexOf(u);c>-1&&(r.splice(c,1),s+=u+".")}),s+=i,0!=r.length||0===i.length)return null;const l={};return l.domEventName=o,l.fullKey=s,l}static matchEventFullKeyCode(n,r){let o=lM[n.key]||n.key,i="";return r.indexOf("code.")>-1&&(o=n.code,i="code."),!(null==o||!o)&&(o=o.toLowerCase()," "===o?o="space":"."===o&&(o="dot"),Lm.forEach(s=>{s!==o&&(0,uM[s])(n)&&(i+=s+".")}),i+=o,i===r)}static eventCallback(n,r,o){return i=>{e.matchEventFullKeyCode(i,n)&&o.runGuarded(()=>r(i))}}static _normalizeKey(n){return"esc"===n?"escape":n}}return e.\u0275fac=function(n){return new(n||e)(H(Pt))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();const hM=Lg(eS,"browser",[{provide:Hl,useValue:"browser"},{provide:xg,useValue:function dM(){Du.makeCurrent()},multi:!0},{provide:Pt,useFactory:function pM(){return function Vw(e){Ia=e}(document),document},deps:[]}]),Hm=new A(""),$m=[{provide:ki,useClass:class YT{addToWindow(t){ne.getAngularTestability=(r,o=!0)=>{const i=t.findTestabilityInTree(r,o);if(null==i)throw new Error("Could not find testability for element.");return i},ne.getAllAngularTestabilities=()=>t.getAllTestabilities(),ne.getAllAngularRootElements=()=>t.getAllRootElements(),ne.frameworkStabilizers||(ne.frameworkStabilizers=[]),ne.frameworkStabilizers.push(r=>{const o=ne.getAllAngularTestabilities();let i=o.length,s=!1;const a=function(l){s=s||l,i--,0==i&&r(s)};o.forEach(function(l){l.whenStable(a)})})}findTestabilityInTree(t,n,r){return null==n?null:t.getTestability(n)??(r?Fi().isShadowRoot(n)?this.findTestabilityInTree(t,n.host,!0):this.findTestabilityInTree(t,n.parentElement,!0):null)}},deps:[]},{provide:Rg,useClass:zl,deps:[Pe,Gl,ki]},{provide:zl,useClass:zl,deps:[Pe,Gl,ki]}],Vm=[{provide:Fa,useValue:"root"},{provide:Qn,useFactory:function fM(){return new Qn},deps:[]},{provide:Ji,useClass:aM,multi:!0,deps:[Pt,Pe,Hl]},{provide:Ji,useClass:cM,multi:!0,deps:[Pt]},{provide:_u,useClass:_u,deps:[Ki,uo,ro,Am]},{provide:If,useExisting:_u},{provide:Mm,useExisting:uo},{provide:uo,useClass:uo,deps:[Pt]},{provide:Ki,useClass:Ki,deps:[Ji,Pe]},{provide:_m,useClass:XT,deps:[]},[]];let gM=(()=>{class e{constructor(n){}static withServerTransition(n){return{ngModule:e,providers:[{provide:ro,useValue:n.appId},{provide:Sm,useExisting:ro},QT]}}}return e.\u0275fac=function(n){return new(n||e)(H(Hm,12))},e.\u0275mod=An({type:e}),e.\u0275inj=dn({providers:[...Vm,...$m],imports:[mT,tS]}),e})();typeof window<"u"&&window;class Qi{}class Su{}class Nt{constructor(t){this.normalizedNames=new Map,this.lazyUpdate=null,t?this.lazyInit="string"==typeof t?()=>{this.headers=new Map,t.split("\n").forEach(n=>{const r=n.indexOf(":");if(r>0){const o=n.slice(0,r),i=o.toLowerCase(),s=n.slice(r+1).trim();this.maybeSetNormalizedName(o,i),this.headers.has(i)?this.headers.get(i).push(s):this.headers.set(i,[s])}})}:()=>{this.headers=new Map,Object.entries(t).forEach(([n,r])=>{let o;if(o="string"==typeof r?[r]:"number"==typeof r?[r.toString()]:r.map(i=>i.toString()),o.length>0){const i=n.toLowerCase();this.headers.set(i,o),this.maybeSetNormalizedName(n,i)}})}:this.headers=new Map}has(t){return this.init(),this.headers.has(t.toLowerCase())}get(t){this.init();const n=this.headers.get(t.toLowerCase());return n&&n.length>0?n[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(t){return this.init(),this.headers.get(t.toLowerCase())||null}append(t,n){return this.clone({name:t,value:n,op:"a"})}set(t,n){return this.clone({name:t,value:n,op:"s"})}delete(t,n){return this.clone({name:t,value:n,op:"d"})}maybeSetNormalizedName(t,n){this.normalizedNames.has(n)||this.normalizedNames.set(n,t)}init(){this.lazyInit&&(this.lazyInit instanceof Nt?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(t=>this.applyUpdate(t)),this.lazyUpdate=null))}copyFrom(t){t.init(),Array.from(t.headers.keys()).forEach(n=>{this.headers.set(n,t.headers.get(n)),this.normalizedNames.set(n,t.normalizedNames.get(n))})}clone(t){const n=new Nt;return n.lazyInit=this.lazyInit&&this.lazyInit instanceof Nt?this.lazyInit:this,n.lazyUpdate=(this.lazyUpdate||[]).concat([t]),n}applyUpdate(t){const n=t.name.toLowerCase();switch(t.op){case"a":case"s":let r=t.value;if("string"==typeof r&&(r=[r]),0===r.length)return;this.maybeSetNormalizedName(t.name,n);const o=("a"===t.op?this.headers.get(n):void 0)||[];o.push(...r),this.headers.set(n,o);break;case"d":const i=t.value;if(i){let s=this.headers.get(n);if(!s)return;s=s.filter(a=>-1===i.indexOf(a)),0===s.length?(this.headers.delete(n),this.normalizedNames.delete(n)):this.headers.set(n,s)}else this.headers.delete(n),this.normalizedNames.delete(n)}}forEach(t){this.init(),Array.from(this.normalizedNames.keys()).forEach(n=>t(this.normalizedNames.get(n),this.headers.get(n)))}}class SM{encodeKey(t){return Gm(t)}encodeValue(t){return Gm(t)}decodeKey(t){return decodeURIComponent(t)}decodeValue(t){return decodeURIComponent(t)}}const MM=/%(\d[a-f0-9])/gi,xM={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function Gm(e){return encodeURIComponent(e).replace(MM,(t,n)=>xM[n]??t)}function Yi(e){return`${e}`}class ln{constructor(t={}){if(this.updates=null,this.cloneFrom=null,this.encoder=t.encoder||new SM,t.fromString){if(t.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=function TM(e,t){const n=new Map;return e.length>0&&e.replace(/^\?/,"").split("&").forEach(o=>{const i=o.indexOf("="),[s,a]=-1==i?[t.decodeKey(o),""]:[t.decodeKey(o.slice(0,i)),t.decodeValue(o.slice(i+1))],l=n.get(s)||[];l.push(a),n.set(s,l)}),n}(t.fromString,this.encoder)}else t.fromObject?(this.map=new Map,Object.keys(t.fromObject).forEach(n=>{const r=t.fromObject[n],o=Array.isArray(r)?r.map(Yi):[Yi(r)];this.map.set(n,o)})):this.map=null}has(t){return this.init(),this.map.has(t)}get(t){this.init();const n=this.map.get(t);return n?n[0]:null}getAll(t){return this.init(),this.map.get(t)||null}keys(){return this.init(),Array.from(this.map.keys())}append(t,n){return this.clone({param:t,value:n,op:"a"})}appendAll(t){const n=[];return Object.keys(t).forEach(r=>{const o=t[r];Array.isArray(o)?o.forEach(i=>{n.push({param:r,value:i,op:"a"})}):n.push({param:r,value:o,op:"a"})}),this.clone(n)}set(t,n){return this.clone({param:t,value:n,op:"s"})}delete(t,n){return this.clone({param:t,value:n,op:"d"})}toString(){return this.init(),this.keys().map(t=>{const n=this.encoder.encodeKey(t);return this.map.get(t).map(r=>n+"="+this.encoder.encodeValue(r)).join("&")}).filter(t=>""!==t).join("&")}clone(t){const n=new ln({encoder:this.encoder});return n.cloneFrom=this.cloneFrom||this,n.updates=(this.updates||[]).concat(t),n}init(){null===this.map&&(this.map=new Map),null!==this.cloneFrom&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(t=>this.map.set(t,this.cloneFrom.map.get(t))),this.updates.forEach(t=>{switch(t.op){case"a":case"s":const n=("a"===t.op?this.map.get(t.param):void 0)||[];n.push(Yi(t.value)),this.map.set(t.param,n);break;case"d":if(void 0===t.value){this.map.delete(t.param);break}{let r=this.map.get(t.param)||[];const o=r.indexOf(Yi(t.value));-1!==o&&r.splice(o,1),r.length>0?this.map.set(t.param,r):this.map.delete(t.param)}}}),this.cloneFrom=this.updates=null)}}class kM{constructor(){this.map=new Map}set(t,n){return this.map.set(t,n),this}get(t){return this.map.has(t)||this.map.set(t,t.defaultValue()),this.map.get(t)}delete(t){return this.map.delete(t),this}has(t){return this.map.has(t)}keys(){return this.map.keys()}}function qm(e){return typeof ArrayBuffer<"u"&&e instanceof ArrayBuffer}function Wm(e){return typeof Blob<"u"&&e instanceof Blob}function Zm(e){return typeof FormData<"u"&&e instanceof FormData}class co{constructor(t,n,r,o){let i;if(this.url=n,this.body=null,this.reportProgress=!1,this.withCredentials=!1,this.responseType="json",this.method=t.toUpperCase(),function AM(e){switch(e){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}(this.method)||o?(this.body=void 0!==r?r:null,i=o):i=r,i&&(this.reportProgress=!!i.reportProgress,this.withCredentials=!!i.withCredentials,i.responseType&&(this.responseType=i.responseType),i.headers&&(this.headers=i.headers),i.context&&(this.context=i.context),i.params&&(this.params=i.params)),this.headers||(this.headers=new Nt),this.context||(this.context=new kM),this.params){const s=this.params.toString();if(0===s.length)this.urlWithParams=n;else{const a=n.indexOf("?");this.urlWithParams=n+(-1===a?"?":a<n.length-1?"&":"")+s}}else this.params=new ln,this.urlWithParams=n}serializeBody(){return null===this.body?null:qm(this.body)||Wm(this.body)||Zm(this.body)||function PM(e){return typeof URLSearchParams<"u"&&e instanceof URLSearchParams}(this.body)||"string"==typeof this.body?this.body:this.body instanceof ln?this.body.toString():"object"==typeof this.body||"boolean"==typeof this.body||Array.isArray(this.body)?JSON.stringify(this.body):this.body.toString()}detectContentTypeHeader(){return null===this.body||Zm(this.body)?null:Wm(this.body)?this.body.type||null:qm(this.body)?null:"string"==typeof this.body?"text/plain":this.body instanceof ln?"application/x-www-form-urlencoded;charset=UTF-8":"object"==typeof this.body||"number"==typeof this.body||"boolean"==typeof this.body?"application/json":null}clone(t={}){const n=t.method||this.method,r=t.url||this.url,o=t.responseType||this.responseType,i=void 0!==t.body?t.body:this.body,s=void 0!==t.withCredentials?t.withCredentials:this.withCredentials,a=void 0!==t.reportProgress?t.reportProgress:this.reportProgress;let l=t.headers||this.headers,u=t.params||this.params;const c=t.context??this.context;return void 0!==t.setHeaders&&(l=Object.keys(t.setHeaders).reduce((d,p)=>d.set(p,t.setHeaders[p]),l)),t.setParams&&(u=Object.keys(t.setParams).reduce((d,p)=>d.set(p,t.setParams[p]),u)),new co(n,r,i,{params:u,headers:l,context:c,reportProgress:a,responseType:o,withCredentials:s})}}var ve=(()=>((ve=ve||{})[ve.Sent=0]="Sent",ve[ve.UploadProgress=1]="UploadProgress",ve[ve.ResponseHeader=2]="ResponseHeader",ve[ve.DownloadProgress=3]="DownloadProgress",ve[ve.Response=4]="Response",ve[ve.User=5]="User",ve))();class Tu{constructor(t,n=200,r="OK"){this.headers=t.headers||new Nt,this.status=void 0!==t.status?t.status:n,this.statusText=t.statusText||r,this.url=t.url||null,this.ok=this.status>=200&&this.status<300}}class Mu extends Tu{constructor(t={}){super(t),this.type=ve.ResponseHeader}clone(t={}){return new Mu({headers:t.headers||this.headers,status:void 0!==t.status?t.status:this.status,statusText:t.statusText||this.statusText,url:t.url||this.url||void 0})}}class Xi extends Tu{constructor(t={}){super(t),this.type=ve.Response,this.body=void 0!==t.body?t.body:null}clone(t={}){return new Xi({body:void 0!==t.body?t.body:this.body,headers:t.headers||this.headers,status:void 0!==t.status?t.status:this.status,statusText:t.statusText||this.statusText,url:t.url||this.url||void 0})}}class Jm extends Tu{constructor(t){super(t,0,"Unknown Error"),this.name="HttpErrorResponse",this.ok=!1,this.message=this.status>=200&&this.status<300?`Http failure during parsing for ${t.url||"(unknown url)"}`:`Http failure response for ${t.url||"(unknown url)"}: ${t.status} ${t.statusText}`,this.error=t.error||null}}function xu(e,t){return{body:t,headers:e.headers,context:e.context,observe:e.observe,params:e.params,reportProgress:e.reportProgress,responseType:e.responseType,withCredentials:e.withCredentials}}let Km=(()=>{class e{constructor(n){this.handler=n}request(n,r,o={}){let i;if(n instanceof co)i=n;else{let l,u;l=o.headers instanceof Nt?o.headers:new Nt(o.headers),o.params&&(u=o.params instanceof ln?o.params:new ln({fromObject:o.params})),i=new co(n,r,void 0!==o.body?o.body:null,{headers:l,context:o.context,params:u,reportProgress:o.reportProgress,responseType:o.responseType||"json",withCredentials:o.withCredentials})}const s=function EM(...e){return Dc(e,hc(e))}(i).pipe(function CM(e,t){return le(t)?Eo(e,t,1):Eo(e,1)}(l=>this.handler.handle(l)));if(n instanceof co||"events"===o.observe)return s;const a=s.pipe(function IM(e,t){return Mn((n,r)=>{let o=0;n.subscribe(Dr(r,i=>e.call(t,i,o++)&&r.next(i)))})}(l=>l instanceof Xi));switch(o.observe||"body"){case"body":switch(i.responseType){case"arraybuffer":return a.pipe(xn(l=>{if(null!==l.body&&!(l.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return l.body}));case"blob":return a.pipe(xn(l=>{if(null!==l.body&&!(l.body instanceof Blob))throw new Error("Response is not a Blob.");return l.body}));case"text":return a.pipe(xn(l=>{if(null!==l.body&&"string"!=typeof l.body)throw new Error("Response is not a string.");return l.body}));default:return a.pipe(xn(l=>l.body))}case"response":return a;default:throw new Error(`Unreachable: unhandled observe type ${o.observe}}`)}}delete(n,r={}){return this.request("DELETE",n,r)}get(n,r={}){return this.request("GET",n,r)}head(n,r={}){return this.request("HEAD",n,r)}jsonp(n,r){return this.request("JSONP",n,{params:(new ln).append(r,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(n,r={}){return this.request("OPTIONS",n,r)}patch(n,r,o={}){return this.request("PATCH",n,xu(o,r))}post(n,r,o={}){return this.request("POST",n,xu(o,r))}put(n,r,o={}){return this.request("PUT",n,xu(o,r))}}return e.\u0275fac=function(n){return new(n||e)(H(Qi))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();function Qm(e,t){return t(e)}function NM(e,t){return(n,r)=>t.intercept(n,{handle:o=>e(o,r)})}const FM=new A("HTTP_INTERCEPTORS"),fo=new A("HTTP_INTERCEPTOR_FNS");function OM(){let e=null;return(t,n)=>(null===e&&(e=(_r(FM,{optional:!0})??[]).reduceRight(NM,Qm)),e(t,n))}let Ym=(()=>{class e extends Qi{constructor(n,r){super(),this.backend=n,this.injector=r,this.chain=null}handle(n){if(null===this.chain){const r=Array.from(new Set(this.injector.get(fo)));this.chain=r.reduceRight((o,i)=>function RM(e,t,n){return(r,o)=>n.runInContext(()=>t(r,i=>e(i,o)))}(o,i,this.injector),Qm)}return this.chain(n,r=>this.backend.handle(r))}}return e.\u0275fac=function(n){return new(n||e)(H(Su),H(vn))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();const HM=/^\)\]\}',?\n/;let ey=(()=>{class e{constructor(n){this.xhrFactory=n}handle(n){if("JSONP"===n.method)throw new Error("Attempted to construct Jsonp request without HttpClientJsonpModule installed.");return new Ie(r=>{const o=this.xhrFactory.build();if(o.open(n.method,n.urlWithParams),n.withCredentials&&(o.withCredentials=!0),n.headers.forEach((f,h)=>o.setRequestHeader(f,h.join(","))),n.headers.has("Accept")||o.setRequestHeader("Accept","application/json, text/plain, */*"),!n.headers.has("Content-Type")){const f=n.detectContentTypeHeader();null!==f&&o.setRequestHeader("Content-Type",f)}if(n.responseType){const f=n.responseType.toLowerCase();o.responseType="json"!==f?f:"text"}const i=n.serializeBody();let s=null;const a=()=>{if(null!==s)return s;const f=o.statusText||"OK",h=new Nt(o.getAllResponseHeaders()),g=function $M(e){return"responseURL"in e&&e.responseURL?e.responseURL:/^X-Request-URL:/m.test(e.getAllResponseHeaders())?e.getResponseHeader("X-Request-URL"):null}(o)||n.url;return s=new Mu({headers:h,status:o.status,statusText:f,url:g}),s},l=()=>{let{headers:f,status:h,statusText:g,url:m}=a(),D=null;204!==h&&(D=typeof o.response>"u"?o.responseText:o.response),0===h&&(h=D?200:0);let w=h>=200&&h<300;if("json"===n.responseType&&"string"==typeof D){const y=D;D=D.replace(HM,"");try{D=""!==D?JSON.parse(D):null}catch(E){D=y,w&&(w=!1,D={error:E,text:D})}}w?(r.next(new Xi({body:D,headers:f,status:h,statusText:g,url:m||void 0})),r.complete()):r.error(new Jm({error:D,headers:f,status:h,statusText:g,url:m||void 0}))},u=f=>{const{url:h}=a(),g=new Jm({error:f,status:o.status||0,statusText:o.statusText||"Unknown Error",url:h||void 0});r.error(g)};let c=!1;const d=f=>{c||(r.next(a()),c=!0);let h={type:ve.DownloadProgress,loaded:f.loaded};f.lengthComputable&&(h.total=f.total),"text"===n.responseType&&o.responseText&&(h.partialText=o.responseText),r.next(h)},p=f=>{let h={type:ve.UploadProgress,loaded:f.loaded};f.lengthComputable&&(h.total=f.total),r.next(h)};return o.addEventListener("load",l),o.addEventListener("error",u),o.addEventListener("timeout",u),o.addEventListener("abort",u),n.reportProgress&&(o.addEventListener("progress",d),null!==i&&o.upload&&o.upload.addEventListener("progress",p)),o.send(i),r.next({type:ve.Sent}),()=>{o.removeEventListener("error",u),o.removeEventListener("abort",u),o.removeEventListener("load",l),o.removeEventListener("timeout",u),n.reportProgress&&(o.removeEventListener("progress",d),null!==i&&o.upload&&o.upload.removeEventListener("progress",p)),o.readyState!==o.DONE&&o.abort()}})}}return e.\u0275fac=function(n){return new(n||e)(H(_m))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();const ku=new A("XSRF_ENABLED"),ty=new A("XSRF_COOKIE_NAME",{providedIn:"root",factory:()=>"XSRF-TOKEN"}),ny=new A("XSRF_HEADER_NAME",{providedIn:"root",factory:()=>"X-XSRF-TOKEN"});class ry{}let zM=(()=>{class e{constructor(n,r,o){this.doc=n,this.platform=r,this.cookieName=o,this.lastCookieString="",this.lastToken=null,this.parseCount=0}getToken(){if("server"===this.platform)return null;const n=this.doc.cookie||"";return n!==this.lastCookieString&&(this.parseCount++,this.lastToken=um(n,this.cookieName),this.lastCookieString=n),this.lastToken}}return e.\u0275fac=function(n){return new(n||e)(H(Pt),H(Hl),H(ty))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();function GM(e,t){const n=e.url.toLowerCase();if(!_r(ku)||"GET"===e.method||"HEAD"===e.method||n.startsWith("http://")||n.startsWith("https://"))return t(e);const r=_r(ry).getToken(),o=_r(ny);return null!=r&&!e.headers.has(o)&&(e=e.clone({headers:e.headers.set(o,r)})),t(e)}var he=(()=>((he=he||{})[he.Interceptors=0]="Interceptors",he[he.LegacyInterceptors=1]="LegacyInterceptors",he[he.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",he[he.NoXsrfProtection=3]="NoXsrfProtection",he[he.JsonpSupport=4]="JsonpSupport",he[he.RequestsMadeViaParent=5]="RequestsMadeViaParent",he))();function mr(e,t){return{\u0275kind:e,\u0275providers:t}}function qM(...e){const t=[Km,ey,Ym,{provide:Qi,useExisting:Ym},{provide:Su,useExisting:ey},{provide:fo,useValue:GM,multi:!0},{provide:ku,useValue:!0},{provide:ry,useClass:zM}];for(const n of e)t.push(...n.\u0275providers);return function d_(e){return{\u0275providers:e}}(t)}const oy=new A("LEGACY_INTERCEPTOR_FN");let ZM=(()=>{class e{}return e.\u0275fac=function(n){return new(n||e)},e.\u0275mod=An({type:e}),e.\u0275inj=dn({providers:[qM(mr(he.LegacyInterceptors,[{provide:oy,useFactory:OM},{provide:fo,useExisting:oy,multi:!0}]))]}),e})();function iy(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,o)}function vt(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function s(l){iy(i,r,o,s,a,"next",l)}function a(l){iy(i,r,o,s,a,"throw",l)}s(void 0)})}}const JM=new A("JWT_OPTIONS");let KM=(()=>{class e{constructor(n=null){this.tokenGetter=n&&n.tokenGetter||function(){}}urlBase64Decode(n){let r=n.replace(/-/g,"+").replace(/_/g,"/");switch(r.length%4){case 0:break;case 2:r+="==";break;case 3:r+="=";break;default:throw new Error("Illegal base64url string!")}return this.b64DecodeUnicode(r)}b64decode(n){let o="";if((n=String(n).replace(/=+$/,"")).length%4==1)throw new Error("'atob' failed: The string to be decoded is not correctly encoded.");for(let s,a,i=0,l=0;a=n.charAt(l++);~a&&(s=i%4?64*s+a:a,i++%4)?o+=String.fromCharCode(255&s>>(-2*i&6)):0)a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(a);return o}b64DecodeUnicode(n){return decodeURIComponent(Array.prototype.map.call(this.b64decode(n),r=>"%"+("00"+r.charCodeAt(0).toString(16)).slice(-2)).join(""))}decodeToken(n=this.tokenGetter()){return n instanceof Promise?n.then(r=>this._decodeToken(r)):this._decodeToken(n)}_decodeToken(n){if(!n||""===n)return null;const r=n.split(".");if(3!==r.length)throw new Error("The inspected token doesn't appear to be a JWT. Check to make sure it has three parts and see https://jwt.io for more.");const o=this.urlBase64Decode(r[1]);if(!o)throw new Error("Cannot decode the token.");return JSON.parse(o)}getTokenExpirationDate(n=this.tokenGetter()){return n instanceof Promise?n.then(r=>this._getTokenExpirationDate(r)):this._getTokenExpirationDate(n)}_getTokenExpirationDate(n){let r;if(r=this.decodeToken(n),!r||!r.hasOwnProperty("exp"))return null;const o=new Date(0);return o.setUTCSeconds(r.exp),o}isTokenExpired(n=this.tokenGetter(),r){return n instanceof Promise?n.then(o=>this._isTokenExpired(o,r)):this._isTokenExpired(n,r)}_isTokenExpired(n,r){if(!n||""===n)return!0;const o=this.getTokenExpirationDate(n);return r=r||0,null!==o&&!(o.valueOf()>(new Date).valueOf()+1e3*r)}getAuthScheme(n,r){return"function"==typeof n?n(r):n}}return e.\u0275fac=function(n){return new(n||e)(H(JM))},e.\u0275prov=q({token:e,factory:e.\u0275fac}),e})();let Au=(()=>{class e{translations;ready=!1;constructor(){window.homebridge.i18nGetTranslation().then(n=>{this.translations=n,this.ready=!0})}static \u0275fac=function(r){return new(r||e)};static \u0275prov=q({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),ay=(()=>{class e{http;constructor(n){this.http=n}userData;createHeaders(n){return new Nt({Authorization:`Bearer ${n}`,"Content-Type":"application/json"})}getUserData(n,r){if(r){const o=this.createHeaders(r);return this.http.get(`${n}/userData/userData`,{headers:o}).pipe(xn(s=>(this.userData=s.userData,this.userData.startDate=function YM(e){const t=new Date(e),n=new Date;return!isNaN(t.getTime())&&t>n?t:new Date(n.getTime()+6e5)}(this.userData.expiryDate),this.userData)))}return new Ie(o=>{o.next(this.userData),o.complete()})}cancelSubscription(n,r,o){return this.createHeaders(o),fetch(`${r}/userData/cancel`,{method:"POST",headers:{Authorization:`Bearer ${o}`,"Content-Type":"application/json"},body:JSON.stringify({subscriptionID:n})}).then(s=>s.json())}saveSubscription(n,r,o){return fetch(`${r}/userData/subscribe`,{method:"POST",headers:{Authorization:`Bearer ${o}`,"Content-Type":"application/json"},body:JSON.stringify(n)}).then(i=>i.json())}scriptLoaded=!1;loadScript(){return new Promise((n,r)=>{if(this.scriptLoaded)return void n();if(!this.userData?.paypalScript)return void r(new Error("PayPal script URL is not available."));const o=document.createElement("script");o.src=this.userData?.paypalScript,o.onload=()=>{this.scriptLoaded=!0,n()},o.onerror=r,document.body.appendChild(o)})}static \u0275fac=function(r){return new(r||e)(H(Km))};static \u0275prov=q({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();let Sn={async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null};function ly(e){Sn=e}const po={exec:()=>null};function Q(e,t=""){let n="string"==typeof e?e:e.source;const r={replace:(o,i)=>{let s="string"==typeof i?i:i.source;return s=s.replace(je.caret,"$1"),n=n.replace(o,s),r},getRegex:()=>new RegExp(n,t)};return r}const je={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[\t ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ \t][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i")},ho=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,Nu=/(?:[*+-]|\d{1,9}[.)])/,uy=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,cy=Q(uy).replace(/bull/g,Nu).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),rx=Q(uy).replace(/bull/g,Nu).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),Ru=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,Fu=/(?!\s*\])(?:\\.|[^\[\]\\])+/,ix=Q(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",Fu).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),sx=Q(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,Nu).getRegex(),es="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Ou=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,ax=Q("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$))","i").replace("comment",Ou).replace("tag",es).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),dy=Q(Ru).replace("hr",ho).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",es).getRegex(),Lu={blockquote:Q(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",dy).getRegex(),code:/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,def:ix,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,hr:ho,html:ax,lheading:cy,list:sx,newline:/^(?:[ \t]*(?:\n|$))+/,paragraph:dy,table:po,text:/^[^\n]+/},fy=Q("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",ho).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3}\t)[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",es).getRegex(),lx={...Lu,lheading:rx,table:fy,paragraph:Q(Ru).replace("hr",ho).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",fy).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",es).getRegex()},ux={...Lu,html:Q("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",Ou).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:po,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Q(Ru).replace("hr",ho).replace("heading"," *#{1,6} *[^\n]").replace("lheading",cy).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},py=/^( {2,}|\\)\n(?!\s*$)/,ts=/[\p{P}\p{S}]/u,ju=/[\s\p{P}\p{S}]/u,hy=/[^\s\p{P}\p{S}]/u,px=Q(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,ju).getRegex(),gy=/(?!~)[\p{P}\p{S}]/u,my=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,yx=Q(my,"u").replace(/punct/g,ts).getRegex(),Dx=Q(my,"u").replace(/punct/g,gy).getRegex(),yy="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",vx=Q(yy,"gu").replace(/notPunctSpace/g,hy).replace(/punctSpace/g,ju).replace(/punct/g,ts).getRegex(),wx=Q(yy,"gu").replace(/notPunctSpace/g,/(?:[^\s\p{P}\p{S}]|~)/u).replace(/punctSpace/g,/(?!~)[\s\p{P}\p{S}]/u).replace(/punct/g,gy).getRegex(),_x=Q("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,hy).replace(/punctSpace/g,ju).replace(/punct/g,ts).getRegex(),bx=Q(/\\(punct)/,"gu").replace(/punct/g,ts).getRegex(),Ex=Q(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[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])?)+(?![-_])/).getRegex(),Cx=Q(Ou).replace("(?:--\x3e|$)","--\x3e").getRegex(),Ix=Q("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",Cx).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),ns=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,Sx=Q(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",ns).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Dy=Q(/^!?\[(label)\]\[(ref)\]/).replace("label",ns).replace("ref",Fu).getRegex(),vy=Q(/^!?\[(ref)\](?:\[\])?/).replace("ref",Fu).getRegex(),Bu={_backpedal:po,anyPunctuation:bx,autolink:Ex,blockSkip:/\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<[^<>]*?>/g,br:py,code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,del:po,emStrongLDelim:yx,emStrongRDelimAst:vx,emStrongRDelimUnd:_x,escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,link:Sx,nolink:vy,punctuation:px,reflink:Dy,reflinkSearch:Q("reflink|nolink(?!\\()","g").replace("reflink",Dy).replace("nolink",vy).getRegex(),tag:Ix,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,url:po},Mx={...Bu,link:Q(/^!?\[(label)\]\((.*?)\)/).replace("label",ns).getRegex(),reflink:Q(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",ns).getRegex()},Hu={...Bu,emStrongRDelimAst:wx,emStrongLDelim:Dx,url:Q(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,"i").replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\.|[^\\])*?(?:\\.|[^\s~\\]))\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/},xx={...Hu,br:Q(py).replace("{2,}","*").getRegex(),text:Q(Hu.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},rs={normal:Lu,gfm:lx,pedantic:ux},go={normal:Bu,gfm:Hu,breaks:xx,pedantic:Mx},kx={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},wy=e=>kx[e];function Rt(e,t){if(t){if(je.escapeTest.test(e))return e.replace(je.escapeReplace,wy)}else if(je.escapeTestNoEncode.test(e))return e.replace(je.escapeReplaceNoEncode,wy);return e}function _y(e){try{e=encodeURI(e).replace(je.percentDecode,"%")}catch{return null}return e}function by(e,t){const r=e.replace(je.findPipe,(i,s,a)=>{let l=!1,u=s;for(;--u>=0&&"\\"===a[u];)l=!l;return l?"|":" |"}).split(je.splitPipe);let o=0;if(r[0].trim()||r.shift(),r.length>0&&!r.at(-1)?.trim()&&r.pop(),t)if(r.length>t)r.splice(t);else for(;r.length<t;)r.push("");for(;o<r.length;o++)r[o]=r[o].trim().replace(je.slashPipe,"|");return r}function mo(e,t,n){const r=e.length;if(0===r)return"";let o=0;for(;o<r&&e.charAt(r-o-1)===t;)o++;return e.slice(0,r-o)}function Ey(e,t,n,r,o){const i=t.href,s=t.title||null,a=e[1].replace(o.other.outputLinkReplace,"$1");r.state.inLink=!0;const l={type:"!"===e[0].charAt(0)?"image":"link",raw:n,href:i,title:s,text:a,tokens:r.inlineTokens(a)};return r.state.inLink=!1,l}class os{options;rules;lexer;constructor(t){this.options=t||Sn}space(t){const n=this.rules.block.newline.exec(t);if(n&&n[0].length>0)return{type:"space",raw:n[0]}}code(t){const n=this.rules.block.code.exec(t);if(n){const r=n[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:n[0],codeBlockStyle:"indented",text:this.options.pedantic?r:mo(r,"\n")}}}fences(t){const n=this.rules.block.fences.exec(t);if(n){const r=n[0],o=function Px(e,t,n){const r=e.match(n.other.indentCodeCompensation);if(null===r)return t;const o=r[1];return t.split("\n").map(i=>{const s=i.match(n.other.beginningSpace);if(null===s)return i;const[a]=s;return a.length>=o.length?i.slice(o.length):i}).join("\n")}(r,n[3]||"",this.rules);return{type:"code",raw:r,lang:n[2]?n[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):n[2],text:o}}}heading(t){const n=this.rules.block.heading.exec(t);if(n){let r=n[2].trim();if(this.rules.other.endingHash.test(r)){const o=mo(r,"#");(this.options.pedantic||!o||this.rules.other.endingSpaceChar.test(o))&&(r=o.trim())}return{type:"heading",raw:n[0],depth:n[1].length,text:r,tokens:this.lexer.inline(r)}}}hr(t){const n=this.rules.block.hr.exec(t);if(n)return{type:"hr",raw:mo(n[0],"\n")}}blockquote(t){const n=this.rules.block.blockquote.exec(t);if(n){let r=mo(n[0],"\n").split("\n"),o="",i="";const s=[];for(;r.length>0;){let a=!1;const l=[];let u;for(u=0;u<r.length;u++)if(this.rules.other.blockquoteStart.test(r[u]))l.push(r[u]),a=!0;else{if(a)break;l.push(r[u])}r=r.slice(u);const c=l.join("\n"),d=c.replace(this.rules.other.blockquoteSetextReplace,"\n    $1").replace(this.rules.other.blockquoteSetextReplace2,"");o=o?`${o}\n${c}`:c,i=i?`${i}\n${d}`:d;const p=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(d,s,!0),this.lexer.state.top=p,0===r.length)break;const f=s.at(-1);if("code"===f?.type)break;if("blockquote"===f?.type){const h=f,g=h.raw+"\n"+r.join("\n"),m=this.blockquote(g);s[s.length-1]=m,o=o.substring(0,o.length-h.raw.length)+m.raw,i=i.substring(0,i.length-h.text.length)+m.text;break}if("list"!==f?.type);else{const h=f,g=h.raw+"\n"+r.join("\n"),m=this.list(g);s[s.length-1]=m,o=o.substring(0,o.length-f.raw.length)+m.raw,i=i.substring(0,i.length-h.raw.length)+m.raw,r=g.substring(s.at(-1).raw.length).split("\n")}}return{type:"blockquote",raw:o,tokens:s,text:i}}}list(t){let n=this.rules.block.list.exec(t);if(n){let r=n[1].trim();const o=r.length>1,i={type:"list",raw:"",ordered:o,start:o?+r.slice(0,-1):"",loose:!1,items:[]};r=o?`\\d{1,9}\\${r.slice(-1)}`:`\\${r}`,this.options.pedantic&&(r=o?r:"[*+-]");const s=this.rules.other.listItemRegex(r);let a=!1;for(;t;){let u=!1,c="",d="";if(!(n=s.exec(t))||this.rules.block.hr.test(t))break;c=n[0],t=t.substring(c.length);let p=n[2].split("\n",1)[0].replace(this.rules.other.listReplaceTabs,w=>" ".repeat(3*w.length)),f=t.split("\n",1)[0],h=!p.trim(),g=0;if(this.options.pedantic?(g=2,d=p.trimStart()):h?g=n[1].length+1:(g=n[2].search(this.rules.other.nonSpaceChar),g=g>4?1:g,d=p.slice(g),g+=n[1].length),h&&this.rules.other.blankLine.test(f)&&(c+=f+"\n",t=t.substring(f.length+1),u=!0),!u){const w=this.rules.other.nextBulletRegex(g),y=this.rules.other.hrRegex(g),E=this.rules.other.fencesBeginRegex(g),G=this.rules.other.headingBeginRegex(g),ae=this.rules.other.htmlBeginRegex(g);for(;t;){const as=t.split("\n",1)[0];let yo;if(f=as,this.options.pedantic?(f=f.replace(this.rules.other.listReplaceNesting,"  "),yo=f):yo=f.replace(this.rules.other.tabCharGlobal,"    "),E.test(f)||G.test(f)||ae.test(f)||w.test(f)||y.test(f))break;if(yo.search(this.rules.other.nonSpaceChar)>=g||!f.trim())d+="\n"+yo.slice(g);else{if(h||p.replace(this.rules.other.tabCharGlobal,"    ").search(this.rules.other.nonSpaceChar)>=4||E.test(p)||G.test(p)||y.test(p))break;d+="\n"+f}!h&&!f.trim()&&(h=!0),c+=as+"\n",t=t.substring(as.length+1),p=yo.slice(g)}}i.loose||(a?i.loose=!0:this.rules.other.doubleBlankLine.test(c)&&(a=!0));let D,m=null;this.options.gfm&&(m=this.rules.other.listIsTask.exec(d),m&&(D="[ ] "!==m[0],d=d.replace(this.rules.other.listReplaceTask,""))),i.items.push({type:"list_item",raw:c,task:!!m,checked:D,loose:!1,text:d,tokens:[]}),i.raw+=c}const l=i.items.at(-1);if(!l)return;l.raw=l.raw.trimEnd(),l.text=l.text.trimEnd(),i.raw=i.raw.trimEnd();for(let u=0;u<i.items.length;u++)if(this.lexer.state.top=!1,i.items[u].tokens=this.lexer.blockTokens(i.items[u].text,[]),!i.loose){const c=i.items[u].tokens.filter(p=>"space"===p.type),d=c.length>0&&c.some(p=>this.rules.other.anyLine.test(p.raw));i.loose=d}if(i.loose)for(let u=0;u<i.items.length;u++)i.items[u].loose=!0;return i}}html(t){const n=this.rules.block.html.exec(t);if(n)return{type:"html",block:!0,raw:n[0],pre:"pre"===n[1]||"script"===n[1]||"style"===n[1],text:n[0]}}def(t){const n=this.rules.block.def.exec(t);if(n){const r=n[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),o=n[2]?n[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",i=n[3]?n[3].substring(1,n[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):n[3];return{type:"def",tag:r,raw:n[0],href:o,title:i}}}table(t){const n=this.rules.block.table.exec(t);if(!n||!this.rules.other.tableDelimiter.test(n[2]))return;const r=by(n[1]),o=n[2].replace(this.rules.other.tableAlignChars,"").split("|"),i=n[3]?.trim()?n[3].replace(this.rules.other.tableRowBlankLine,"").split("\n"):[],s={type:"table",raw:n[0],header:[],align:[],rows:[]};if(r.length===o.length){for(const a of o)this.rules.other.tableAlignRight.test(a)?s.align.push("right"):this.rules.other.tableAlignCenter.test(a)?s.align.push("center"):this.rules.other.tableAlignLeft.test(a)?s.align.push("left"):s.align.push(null);for(let a=0;a<r.length;a++)s.header.push({text:r[a],tokens:this.lexer.inline(r[a]),header:!0,align:s.align[a]});for(const a of i)s.rows.push(by(a,s.header.length).map((l,u)=>({text:l,tokens:this.lexer.inline(l),header:!1,align:s.align[u]})));return s}}lheading(t){const n=this.rules.block.lheading.exec(t);if(n)return{type:"heading",raw:n[0],depth:"="===n[2].charAt(0)?1:2,text:n[1],tokens:this.lexer.inline(n[1])}}paragraph(t){const n=this.rules.block.paragraph.exec(t);if(n){const r="\n"===n[1].charAt(n[1].length-1)?n[1].slice(0,-1):n[1];return{type:"paragraph",raw:n[0],text:r,tokens:this.lexer.inline(r)}}}text(t){const n=this.rules.block.text.exec(t);if(n)return{type:"text",raw:n[0],text:n[0],tokens:this.lexer.inline(n[0])}}escape(t){const n=this.rules.inline.escape.exec(t);if(n)return{type:"escape",raw:n[0],text:n[1]}}tag(t){const n=this.rules.inline.tag.exec(t);if(n)return!this.lexer.state.inLink&&this.rules.other.startATag.test(n[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(n[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(n[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(n[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:n[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:n[0]}}link(t){const n=this.rules.inline.link.exec(t);if(n){const r=n[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(r)){if(!this.rules.other.endAngleBracket.test(r))return;const s=mo(r.slice(0,-1),"\\");if((r.length-s.length)%2==0)return}else{const s=function Ax(e,t){if(-1===e.indexOf(t[1]))return-1;let n=0;for(let r=0;r<e.length;r++)if("\\"===e[r])r++;else if(e[r]===t[0])n++;else if(e[r]===t[1]&&(n--,n<0))return r;return n>0?-2:-1}(n[2],"()");if(-2===s)return;if(s>-1){const l=(0===n[0].indexOf("!")?5:4)+n[1].length+s;n[2]=n[2].substring(0,s),n[0]=n[0].substring(0,l).trim(),n[3]=""}}let o=n[2],i="";if(this.options.pedantic){const s=this.rules.other.pedanticHrefTitle.exec(o);s&&(o=s[1],i=s[3])}else i=n[3]?n[3].slice(1,-1):"";return o=o.trim(),this.rules.other.startAngleBracket.test(o)&&(o=this.options.pedantic&&!this.rules.other.endAngleBracket.test(r)?o.slice(1):o.slice(1,-1)),Ey(n,{href:o&&o.replace(this.rules.inline.anyPunctuation,"$1"),title:i&&i.replace(this.rules.inline.anyPunctuation,"$1")},n[0],this.lexer,this.rules)}}reflink(t,n){let r;if((r=this.rules.inline.reflink.exec(t))||(r=this.rules.inline.nolink.exec(t))){const i=n[(r[2]||r[1]).replace(this.rules.other.multipleSpaceGlobal," ").toLowerCase()];if(!i){const s=r[0].charAt(0);return{type:"text",raw:s,text:s}}return Ey(r,i,r[0],this.lexer,this.rules)}}emStrong(t,n,r=""){let o=this.rules.inline.emStrongLDelim.exec(t);if(!(!o||o[3]&&r.match(this.rules.other.unicodeAlphaNumeric))&&(!o[1]&&!o[2]||!r||this.rules.inline.punctuation.exec(r))){const s=[...o[0]].length-1;let a,l,u=s,c=0;const d="*"===o[0][0]?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(d.lastIndex=0,n=n.slice(-1*t.length+s);null!=(o=d.exec(n));){if(a=o[1]||o[2]||o[3]||o[4]||o[5]||o[6],!a)continue;if(l=[...a].length,o[3]||o[4]){u+=l;continue}if((o[5]||o[6])&&s%3&&!((s+l)%3)){c+=l;continue}if(u-=l,u>0)continue;l=Math.min(l,l+u+c);const p=[...o[0]][0].length,f=t.slice(0,s+o.index+p+l);if(Math.min(s,l)%2){const g=f.slice(1,-1);return{type:"em",raw:f,text:g,tokens:this.lexer.inlineTokens(g)}}const h=f.slice(2,-2);return{type:"strong",raw:f,text:h,tokens:this.lexer.inlineTokens(h)}}}}codespan(t){const n=this.rules.inline.code.exec(t);if(n){let r=n[2].replace(this.rules.other.newLineCharGlobal," ");const o=this.rules.other.nonSpaceChar.test(r),i=this.rules.other.startingSpaceChar.test(r)&&this.rules.other.endingSpaceChar.test(r);return o&&i&&(r=r.substring(1,r.length-1)),{type:"codespan",raw:n[0],text:r}}}br(t){const n=this.rules.inline.br.exec(t);if(n)return{type:"br",raw:n[0]}}del(t){const n=this.rules.inline.del.exec(t);if(n)return{type:"del",raw:n[0],text:n[2],tokens:this.lexer.inlineTokens(n[2])}}autolink(t){const n=this.rules.inline.autolink.exec(t);if(n){let r,o;return"@"===n[2]?(r=n[1],o="mailto:"+r):(r=n[1],o=r),{type:"link",raw:n[0],text:r,href:o,tokens:[{type:"text",raw:r,text:r}]}}}url(t){let n;if(n=this.rules.inline.url.exec(t)){let r,o;if("@"===n[2])r=n[0],o="mailto:"+r;else{let i;do{i=n[0],n[0]=this.rules.inline._backpedal.exec(n[0])?.[0]??""}while(i!==n[0]);r=n[0],o="www."===n[1]?"http://"+n[0]:n[0]}return{type:"link",raw:n[0],text:r,href:o,tokens:[{type:"text",raw:r,text:r}]}}}inlineText(t){const n=this.rules.inline.text.exec(t);if(n)return{type:"text",raw:n[0],text:n[0],escaped:this.lexer.state.inRawBlock}}}class lt{tokens;options;state;tokenizer;inlineQueue;constructor(t){this.tokens=[],this.tokens.links=Object.create(null),this.options=t||Sn,this.options.tokenizer=this.options.tokenizer||new os,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const n={other:je,block:rs.normal,inline:go.normal};this.options.pedantic?(n.block=rs.pedantic,n.inline=go.pedantic):this.options.gfm&&(n.block=rs.gfm,n.inline=this.options.breaks?go.breaks:go.gfm),this.tokenizer.rules=n}static get rules(){return{block:rs,inline:go}}static lex(t,n){return new lt(n).lex(t)}static lexInline(t,n){return new lt(n).inlineTokens(t)}lex(t){t=t.replace(je.carriageReturn,"\n"),this.blockTokens(t,this.tokens);for(let n=0;n<this.inlineQueue.length;n++){const r=this.inlineQueue[n];this.inlineTokens(r.src,r.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(t,n=[],r=!1){for(this.options.pedantic&&(t=t.replace(je.tabCharGlobal,"    ").replace(je.spaceLine,""));t;){let o;if(this.options.extensions?.block?.some(s=>!!(o=s.call({lexer:this},t,n))&&(t=t.substring(o.raw.length),n.push(o),!0)))continue;if(o=this.tokenizer.space(t)){t=t.substring(o.raw.length);const s=n.at(-1);1===o.raw.length&&void 0!==s?s.raw+="\n":n.push(o);continue}if(o=this.tokenizer.code(t)){t=t.substring(o.raw.length);const s=n.at(-1);"paragraph"===s?.type||"text"===s?.type?(s.raw+="\n"+o.raw,s.text+="\n"+o.text,this.inlineQueue.at(-1).src=s.text):n.push(o);continue}if(o=this.tokenizer.fences(t)){t=t.substring(o.raw.length),n.push(o);continue}if(o=this.tokenizer.heading(t)){t=t.substring(o.raw.length),n.push(o);continue}if(o=this.tokenizer.hr(t)){t=t.substring(o.raw.length),n.push(o);continue}if(o=this.tokenizer.blockquote(t)){t=t.substring(o.raw.length),n.push(o);continue}if(o=this.tokenizer.list(t)){t=t.substring(o.raw.length),n.push(o);continue}if(o=this.tokenizer.html(t)){t=t.substring(o.raw.length),n.push(o);continue}if(o=this.tokenizer.def(t)){t=t.substring(o.raw.length);const s=n.at(-1);"paragraph"===s?.type||"text"===s?.type?(s.raw+="\n"+o.raw,s.text+="\n"+o.raw,this.inlineQueue.at(-1).src=s.text):this.tokens.links[o.tag]||(this.tokens.links[o.tag]={href:o.href,title:o.title});continue}if(o=this.tokenizer.table(t)){t=t.substring(o.raw.length),n.push(o);continue}if(o=this.tokenizer.lheading(t)){t=t.substring(o.raw.length),n.push(o);continue}let i=t;if(this.options.extensions?.startBlock){let s=1/0;const a=t.slice(1);let l;this.options.extensions.startBlock.forEach(u=>{l=u.call({lexer:this},a),"number"==typeof l&&l>=0&&(s=Math.min(s,l))}),s<1/0&&s>=0&&(i=t.substring(0,s+1))}if(this.state.top&&(o=this.tokenizer.paragraph(i))){const s=n.at(-1);r&&"paragraph"===s?.type?(s.raw+="\n"+o.raw,s.text+="\n"+o.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):n.push(o),r=i.length!==t.length,t=t.substring(o.raw.length)}else if(o=this.tokenizer.text(t)){t=t.substring(o.raw.length);const s=n.at(-1);"text"===s?.type?(s.raw+="\n"+o.raw,s.text+="\n"+o.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):n.push(o)}else if(t){const s="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(s);break}throw new Error(s)}}return this.state.top=!0,n}inline(t,n=[]){return this.inlineQueue.push({src:t,tokens:n}),n}inlineTokens(t,n=[]){let r=t,o=null;if(this.tokens.links){const a=Object.keys(this.tokens.links);if(a.length>0)for(;null!=(o=this.tokenizer.rules.inline.reflinkSearch.exec(r));)a.includes(o[0].slice(o[0].lastIndexOf("[")+1,-1))&&(r=r.slice(0,o.index)+"["+"a".repeat(o[0].length-2)+"]"+r.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(o=this.tokenizer.rules.inline.anyPunctuation.exec(r));)r=r.slice(0,o.index)+"++"+r.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;null!=(o=this.tokenizer.rules.inline.blockSkip.exec(r));)r=r.slice(0,o.index)+"["+"a".repeat(o[0].length-2)+"]"+r.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);let i=!1,s="";for(;t;){let a;if(i||(s=""),i=!1,this.options.extensions?.inline?.some(u=>!!(a=u.call({lexer:this},t,n))&&(t=t.substring(a.raw.length),n.push(a),!0)))continue;if(a=this.tokenizer.escape(t)){t=t.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.tag(t)){t=t.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.link(t)){t=t.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(a.raw.length);const u=n.at(-1);"text"===a.type&&"text"===u?.type?(u.raw+=a.raw,u.text+=a.text):n.push(a);continue}if(a=this.tokenizer.emStrong(t,r,s)){t=t.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.codespan(t)){t=t.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.br(t)){t=t.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.del(t)){t=t.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.autolink(t)){t=t.substring(a.raw.length),n.push(a);continue}if(!this.state.inLink&&(a=this.tokenizer.url(t))){t=t.substring(a.raw.length),n.push(a);continue}let l=t;if(this.options.extensions?.startInline){let u=1/0;const c=t.slice(1);let d;this.options.extensions.startInline.forEach(p=>{d=p.call({lexer:this},c),"number"==typeof d&&d>=0&&(u=Math.min(u,d))}),u<1/0&&u>=0&&(l=t.substring(0,u+1))}if(a=this.tokenizer.inlineText(l)){t=t.substring(a.raw.length),"_"!==a.raw.slice(-1)&&(s=a.raw.slice(-1)),i=!0;const u=n.at(-1);"text"===u?.type?(u.raw+=a.raw,u.text+=a.text):n.push(a)}else if(t){const u="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(u);break}throw new Error(u)}}return n}}class is{options;parser;constructor(t){this.options=t||Sn}space(t){return""}code({text:t,lang:n,escaped:r}){const o=(n||"").match(je.notSpaceStart)?.[0],i=t.replace(je.endingNewline,"")+"\n";return o?'<pre><code class="language-'+Rt(o)+'">'+(r?i:Rt(i,!0))+"</code></pre>\n":"<pre><code>"+(r?i:Rt(i,!0))+"</code></pre>\n"}blockquote({tokens:t}){return`<blockquote>\n${this.parser.parse(t)}</blockquote>\n`}html({text:t}){return t}heading({tokens:t,depth:n}){return`<h${n}>${this.parser.parseInline(t)}</h${n}>\n`}hr(t){return"<hr>\n"}list(t){const n=t.ordered,r=t.start;let o="";for(let a=0;a<t.items.length;a++)o+=this.listitem(t.items[a]);const i=n?"ol":"ul";return"<"+i+(n&&1!==r?' start="'+r+'"':"")+">\n"+o+"</"+i+">\n"}listitem(t){let n="";if(t.task){const r=this.checkbox({checked:!!t.checked});t.loose?"paragraph"===t.tokens[0]?.type?(t.tokens[0].text=r+" "+t.tokens[0].text,t.tokens[0].tokens&&t.tokens[0].tokens.length>0&&"text"===t.tokens[0].tokens[0].type&&(t.tokens[0].tokens[0].text=r+" "+Rt(t.tokens[0].tokens[0].text),t.tokens[0].tokens[0].escaped=!0)):t.tokens.unshift({type:"text",raw:r+" ",text:r+" ",escaped:!0}):n+=r+" "}return n+=this.parser.parse(t.tokens,!!t.loose),`<li>${n}</li>\n`}checkbox({checked:t}){return"<input "+(t?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:t}){return`<p>${this.parser.parseInline(t)}</p>\n`}table(t){let n="",r="";for(let i=0;i<t.header.length;i++)r+=this.tablecell(t.header[i]);n+=this.tablerow({text:r});let o="";for(let i=0;i<t.rows.length;i++){const s=t.rows[i];r="";for(let a=0;a<s.length;a++)r+=this.tablecell(s[a]);o+=this.tablerow({text:r})}return o&&(o=`<tbody>${o}</tbody>`),"<table>\n<thead>\n"+n+"</thead>\n"+o+"</table>\n"}tablerow({text:t}){return`<tr>\n${t}</tr>\n`}tablecell(t){const n=this.parser.parseInline(t.tokens),r=t.header?"th":"td";return(t.align?`<${r} align="${t.align}">`:`<${r}>`)+n+`</${r}>\n`}strong({tokens:t}){return`<strong>${this.parser.parseInline(t)}</strong>`}em({tokens:t}){return`<em>${this.parser.parseInline(t)}</em>`}codespan({text:t}){return`<code>${Rt(t,!0)}</code>`}br(t){return"<br>"}del({tokens:t}){return`<del>${this.parser.parseInline(t)}</del>`}link({href:t,title:n,tokens:r}){const o=this.parser.parseInline(r),i=_y(t);if(null===i)return o;let s='<a href="'+(t=i)+'"';return n&&(s+=' title="'+Rt(n)+'"'),s+=">"+o+"</a>",s}image({href:t,title:n,text:r,tokens:o}){o&&(r=this.parser.parseInline(o,this.parser.textRenderer));const i=_y(t);if(null===i)return Rt(r);let s=`<img src="${t=i}" alt="${r}"`;return n&&(s+=` title="${Rt(n)}"`),s+=">",s}text(t){return"tokens"in t&&t.tokens?this.parser.parseInline(t.tokens):"escaped"in t&&t.escaped?t.text:Rt(t.text)}}class $u{strong({text:t}){return t}em({text:t}){return t}codespan({text:t}){return t}del({text:t}){return t}html({text:t}){return t}text({text:t}){return t}link({text:t}){return""+t}image({text:t}){return""+t}br(){return""}}class ut{options;renderer;textRenderer;constructor(t){this.options=t||Sn,this.options.renderer=this.options.renderer||new is,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new $u}static parse(t,n){return new ut(n).parse(t)}static parseInline(t,n){return new ut(n).parseInline(t)}parse(t,n=!0){let r="";for(let o=0;o<t.length;o++){const i=t[o];if(this.options.extensions?.renderers?.[i.type]){const a=i,l=this.options.extensions.renderers[a.type].call({parser:this},a);if(!1!==l||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(a.type)){r+=l||"";continue}}const s=i;switch(s.type){case"space":r+=this.renderer.space(s);continue;case"hr":r+=this.renderer.hr(s);continue;case"heading":r+=this.renderer.heading(s);continue;case"code":r+=this.renderer.code(s);continue;case"table":r+=this.renderer.table(s);continue;case"blockquote":r+=this.renderer.blockquote(s);continue;case"list":r+=this.renderer.list(s);continue;case"html":r+=this.renderer.html(s);continue;case"paragraph":r+=this.renderer.paragraph(s);continue;case"text":{let a=s,l=this.renderer.text(a);for(;o+1<t.length&&"text"===t[o+1].type;)a=t[++o],l+="\n"+this.renderer.text(a);r+=n?this.renderer.paragraph({type:"paragraph",raw:l,text:l,tokens:[{type:"text",raw:l,text:l,escaped:!0}]}):l;continue}default:{const a='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(a),"";throw new Error(a)}}}return r}parseInline(t,n=this.renderer){let r="";for(let o=0;o<t.length;o++){const i=t[o];if(this.options.extensions?.renderers?.[i.type]){const a=this.options.extensions.renderers[i.type].call({parser:this},i);if(!1!==a||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(i.type)){r+=a||"";continue}}const s=i;switch(s.type){case"escape":case"text":r+=n.text(s);break;case"html":r+=n.html(s);break;case"link":r+=n.link(s);break;case"image":r+=n.image(s);break;case"strong":r+=n.strong(s);break;case"em":r+=n.em(s);break;case"codespan":r+=n.codespan(s);break;case"br":r+=n.br(s);break;case"del":r+=n.del(s);break;default:{const a='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(a),"";throw new Error(a)}}}return r}}class ss{options;block;constructor(t){this.options=t||Sn}static passThroughHooks=new Set(["preprocess","postprocess","processAllTokens"]);preprocess(t){return t}postprocess(t){return t}processAllTokens(t){return t}provideLexer(){return this.block?lt.lex:lt.lexInline}provideParser(){return this.block?ut.parse:ut.parseInline}}const Tn=new class Nx{defaults={async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null};options=this.setOptions;parse=this.parseMarkdown(!0);parseInline=this.parseMarkdown(!1);Parser=ut;Renderer=is;TextRenderer=$u;Lexer=lt;Tokenizer=os;Hooks=ss;constructor(...t){this.use(...t)}walkTokens(t,n){let r=[];for(const o of t)switch(r=r.concat(n.call(this,o)),o.type){case"table":{const i=o;for(const s of i.header)r=r.concat(this.walkTokens(s.tokens,n));for(const s of i.rows)for(const a of s)r=r.concat(this.walkTokens(a.tokens,n));break}case"list":r=r.concat(this.walkTokens(o.items,n));break;default:{const i=o;this.defaults.extensions?.childTokens?.[i.type]?this.defaults.extensions.childTokens[i.type].forEach(s=>{const a=i[s].flat(1/0);r=r.concat(this.walkTokens(a,n))}):i.tokens&&(r=r.concat(this.walkTokens(i.tokens,n)))}}return r}use(...t){const n=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach(r=>{const o={...r};if(o.async=this.defaults.async||o.async||!1,r.extensions&&(r.extensions.forEach(i=>{if(!i.name)throw new Error("extension name required");if("renderer"in i){const s=n.renderers[i.name];n.renderers[i.name]=s?function(...a){let l=i.renderer.apply(this,a);return!1===l&&(l=s.apply(this,a)),l}:i.renderer}if("tokenizer"in i){if(!i.level||"block"!==i.level&&"inline"!==i.level)throw new Error("extension level must be 'block' or 'inline'");const s=n[i.level];s?s.unshift(i.tokenizer):n[i.level]=[i.tokenizer],i.start&&("block"===i.level?n.startBlock?n.startBlock.push(i.start):n.startBlock=[i.start]:"inline"===i.level&&(n.startInline?n.startInline.push(i.start):n.startInline=[i.start]))}"childTokens"in i&&i.childTokens&&(n.childTokens[i.name]=i.childTokens)}),o.extensions=n),r.renderer){const i=this.defaults.renderer||new is(this.defaults);for(const s in r.renderer){if(!(s in i))throw new Error(`renderer '${s}' does not exist`);if(["options","parser"].includes(s))continue;const l=r.renderer[s],u=i[s];i[s]=(...c)=>{let d=l.apply(i,c);return!1===d&&(d=u.apply(i,c)),d||""}}o.renderer=i}if(r.tokenizer){const i=this.defaults.tokenizer||new os(this.defaults);for(const s in r.tokenizer){if(!(s in i))throw new Error(`tokenizer '${s}' does not exist`);if(["options","rules","lexer"].includes(s))continue;const l=r.tokenizer[s],u=i[s];i[s]=(...c)=>{let d=l.apply(i,c);return!1===d&&(d=u.apply(i,c)),d}}o.tokenizer=i}if(r.hooks){const i=this.defaults.hooks||new ss;for(const s in r.hooks){if(!(s in i))throw new Error(`hook '${s}' does not exist`);if(["options","block"].includes(s))continue;const l=r.hooks[s],u=i[s];i[s]=ss.passThroughHooks.has(s)?c=>{if(this.defaults.async)return Promise.resolve(l.call(i,c)).then(p=>u.call(i,p));const d=l.call(i,c);return u.call(i,d)}:(...c)=>{let d=l.apply(i,c);return!1===d&&(d=u.apply(i,c)),d}}o.hooks=i}if(r.walkTokens){const i=this.defaults.walkTokens,s=r.walkTokens;o.walkTokens=function(a){let l=[];return l.push(s.call(this,a)),i&&(l=l.concat(i.call(this,a))),l}}this.defaults={...this.defaults,...o}}),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,n){return lt.lex(t,n??this.defaults)}parser(t,n){return ut.parse(t,n??this.defaults)}parseMarkdown(t){return(r,o)=>{const i={...o},s={...this.defaults,...i},a=this.onError(!!s.silent,!!s.async);if(!0===this.defaults.async&&!1===i.async)return a(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof r>"u"||null===r)return a(new Error("marked(): input parameter is undefined or null"));if("string"!=typeof r)return a(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(r)+", string expected"));s.hooks&&(s.hooks.options=s,s.hooks.block=t);const l=s.hooks?s.hooks.provideLexer():t?lt.lex:lt.lexInline,u=s.hooks?s.hooks.provideParser():t?ut.parse:ut.parseInline;if(s.async)return Promise.resolve(s.hooks?s.hooks.preprocess(r):r).then(c=>l(c,s)).then(c=>s.hooks?s.hooks.processAllTokens(c):c).then(c=>s.walkTokens?Promise.all(this.walkTokens(c,s.walkTokens)).then(()=>c):c).then(c=>u(c,s)).then(c=>s.hooks?s.hooks.postprocess(c):c).catch(a);try{s.hooks&&(r=s.hooks.preprocess(r));let c=l(r,s);s.hooks&&(c=s.hooks.processAllTokens(c)),s.walkTokens&&this.walkTokens(c,s.walkTokens);let d=u(c,s);return s.hooks&&(d=s.hooks.postprocess(d)),d}catch(c){return a(c)}}}onError(t,n){return r=>{if(r.message+="\nPlease report this to https://github.com/markedjs/marked.",t){const o="<p>An error occurred:</p><pre>"+Rt(r.message+"",!0)+"</pre>";return n?Promise.resolve(o):o}if(n)return Promise.reject(r);throw r}}};function Y(e,t){return Tn.parse(e,t)}Y.options=Y.setOptions=function(e){return Tn.setOptions(e),ly(Y.defaults=Tn.defaults),Y},Y.getDefaults=function Pu(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}},Y.defaults=Sn,Y.use=function(...e){return Tn.use(...e),ly(Y.defaults=Tn.defaults),Y},Y.walkTokens=function(e,t){return Tn.walkTokens(e,t)},Y.parseInline=Tn.parseInline,Y.Parser=ut,Y.parser=ut.parse,Y.Renderer=is,Y.TextRenderer=$u,Y.Lexer=lt,Y.lexer=lt.lex,Y.Tokenizer=os,Y.Hooks=ss,Y.parse=Y;function Rx(e,t){1&e&&(I(0,"div",2)(1,"div",3)(2,"span",4),N(3,"Loading..."),S()()())}function Fx(e,t){1&e&&Ke(0,"div",5),2&e&&V("innerHTML",me().html,si)}let Ox=(()=>{class e{filename;html="";loading=!1;baseUrl="https://raw.githubusercontent.com/homebridge-plugins/homebridge-gsh/refs/heads/latest/homebridge-ui/public/src/assets/markdown/";ngOnChanges(n){var r=this;return vt(function*(){n.filename&&r.filename&&(yield r.loadMarkdown(r.filename))})()}loadMarkdown(n){var r=this;return vt(function*(){r.loading=!0,r.html="";const o=r.baseUrl+n;console.log("Loading markdown from:",o);try{const i=yield fetch(o);if(!i.ok)throw new Error(`Failed to fetch ${n}: ${i.status}`);const s=yield i.text();r.html=yield Y.parse(s)}catch(i){console.error("Markdown fetch failed:",i),window.homebridge.toast.error(`Failed to load ${n}`,"Error")}finally{r.loading=!1}})()}static \u0275fac=function(r){return new(r||e)};static \u0275cmp=Ao({type:e,selectors:[["app-markdown-viewer"]],inputs:{filename:"filename"},features:[xr],decls:2,vars:2,consts:[["class","d-flex justify-content-center my-4",4,"ngIf"],["class","markdown-body",3,"innerHTML",4,"ngIf"],[1,"d-flex","justify-content-center","my-4"],["role","status",1,"spinner-border"],[1,"visually-hidden"],[1,"markdown-body",3,"innerHTML"]],template:function(r,o){1&r&&(oe(0,Rx,4,0,"div",0),oe(1,Fx,1,1,"div",1)),2&r&&(V("ngIf",o.loading),T(1),V("ngIf",!o.loading))},dependencies:[Gi]})}return e})(),Lx=(()=>{class e{transform(n){if(console.log("DateToStringPipe",n),!n)return"N/A";const r=n instanceof Date?n:new Date(n);return isNaN(r.getTime())?"Invalid Date":r.toLocaleDateString("en-GB",{year:"numeric",month:"short",day:"numeric"})}static \u0275fac=function(r){return new(r||e)};static \u0275pipe=Se({name:"dateToString",type:e,pure:!0})}return e})();function jx(e,t){1&e&&(I(0,"div",14),Ke(1,"i",15),S())}function Bx(e,t){if(1&e&&(I(0,"div",16)(1,"div",17)(2,"div",18)(3,"div",19)(4,"h5",20),N(5),S(),I(6,"p",21),N(7),S()(),Ke(8,"div",22),S()()()),2&e){const n=t.$implicit,r=t.index;T(5),Qe(n.name),T(2),Qe(n.description),T(1),V("id","paypal-button-container-"+r)}}function Hx(e,t){if(1&e&&(I(0,"div")(1,"div",9)(2,"p")(3,"span",10),N(4,"Subscription Start Date:"),S(),N(5),ot(6,"dateToString"),S(),I(7,"div",11),oe(8,jx,2,0,"div",12),oe(9,Bx,9,3,"div",13),S()()()),2&e){const n=me(3);T(5),Gt(" ",it(6,3,n.userData.startDate)," "),T(3),V("ngIf",n.isLoadingPayPalButtons),T(1),V("ngForOf",n.userData.paypalPlans)}}const Cy=function(e,t){return{expandable:e,expanded:t}};function $x(e,t){if(1&e){const n=bn();I(0,"div",5)(1,"fieldset",6)(2,"legend",7),zt("click",function(){return tn(n),nn(me(2).toggleCreateSubscriptionExpand())}),N(3," Create Subscription "),S(),oe(4,Hx,10,5,"div",8),S()()}if(2&e){const n=me(2);T(1),V("ngClass",Sl(2,Cy,!n.createSubscriptionExpanded,n.createSubscriptionExpanded)),T(3),V("ngIf",n.createSubscriptionExpanded)}}function Vx(e,t){1&e&&(I(0,"div",14),Ke(1,"i",15),S())}function Ux(e,t){if(1&e){const n=bn();I(0,"div",30)(1,"div",31)(2,"h5",32),N(3,"Cancel your subscription?"),S(),I(4,"p",33),N(5,"Are you sure you want to cancel your "),I(6,"strong"),N(7),S(),N(8," subscription? This action cannot be undone."),S(),I(9,"p",34),N(10,"Your service will continue until the next billing date on "),I(11,"strong"),N(12),ot(13,"dateToString"),S(),N(14,"."),S(),I(15,"div",35)(16,"button",36),zt("click",function(){return tn(n),nn(me(4).showConfirmModal=!1)}),N(17," Keep Subscription "),S(),I(18,"button",37),zt("click",function(){return tn(n),nn(me(4).confirmCancel())}),N(19),S()()()()}if(2&e){const n=me(4);T(7),Qe(n.userData.paypalPlanName),T(5),Qe(it(13,5,n.userData.expiryDate)),T(4),V("disabled",n.isCancelling),T(2),V("disabled",n.isCancelling),T(1),Gt(" ",n.isCancelling?"Cancelling...":"Cancel Subscription"," ")}}function zx(e,t){if(1&e){const n=bn();I(0,"div")(1,"div",23),oe(2,Vx,2,0,"div",12),oe(3,Ux,20,7,"div",24),I(4,"div",25)(5,"table",26)(6,"tbody")(7,"tr")(8,"th",27),N(9,"Plan:"),S(),I(10,"td"),N(11),S()(),I(12,"tr")(13,"th",27),N(14,"Description:"),S(),I(15,"td"),N(16),S()(),I(17,"tr")(18,"th",27),N(19,"Subscription ID:"),S(),I(20,"td")(21,"span"),N(22),S()()(),I(23,"tr")(24,"th",27),N(25,"Next Billing Date:"),S(),I(26,"td"),N(27),ot(28,"dateToString"),S()()()(),I(29,"div",28)(30,"button",29),zt("click",function(){return tn(n),nn(me(3).showConfirmModal=!0)}),N(31," Cancel Subscription "),S()()()()()}if(2&e){const n=me(3);T(2),V("ngIf",n.isCancelling),T(1),V("ngIf",n.showConfirmModal),T(8),Qe(n.userData.paypalPlanName),T(5),Qe(n.userData.paypalPlanDescription),T(6),Gt(" ",n.userData.paypalSubscriptionID,"\xa0 "),T(5),Qe(it(28,6,n.userData.expiryDate))}}function Gx(e,t){if(1&e){const n=bn();I(0,"div",5)(1,"fieldset",6)(2,"legend",7),zt("click",function(){return tn(n),nn(me(2).toggleSubscriptionDetailsExpand())}),N(3," Subscription Details "),S(),oe(4,zx,32,8,"div",8),S()()}if(2&e){const n=me(2);T(1),V("ngClass",Sl(2,Cy,!n.subscriptionDetailsExpanded,n.subscriptionDetailsExpanded)),T(3),V("ngIf",n.subscriptionDetailsExpanded)}}function qx(e,t){if(1&e&&(I(0,"div",1),oe(1,$x,5,5,"div",2),oe(2,Gx,5,5,"div",2),I(3,"span",3),N(4," \u{1f4d6} "),I(5,"a",4),N(6," Subscription Service Details "),S()()()),2&e){const n=me();T(1),V("ngIf",!n.userData.subscriptionActive),T(1),V("ngIf",n.userData.subscriptionActive),T(3),dl("href",n.subscriptionDetailsURL,Aa)}}let Wx=(()=>{class e{userDataService;translateService;pluginConfig;linkDomain;user_id;userDataChange=new kt;userData;createSubscriptionExpanded=!1;subscriptionDetailsExpanded=!1;isCancelling=!1;isLoadingPayPalButtons=!0;subscriptionDetailsURL="https://github.com/homebridge-plugins/homebridge-gsh/wiki/Subscription-Service#Background";constructor(n,r){this.userDataService=n,this.translateService=r}ngOnInit(){this.loadUserData()}loadUserData(){var n=this;return vt(function*(){n.userDataService.getUserData(n.linkDomain,n.pluginConfig.token).subscribe({next:r=>{n.userData=r,n.userDataChange.emit(n.userData),console.log("\u2705 User data loaded:",r)},error:r=>{console.log("\u274c Failed to load user data:",r)}})})()}cancelSubscription(){this.showConfirmModal=!0}showConfirmModal=!1;confirmCancel(){var n=this;return vt(function*(){if(n.showConfirmModal=!1,n.isCancelling=!0,!n.userData?.paypalSubscriptionID)return console.error("No subscription ID found"),window.homebridge.toast.error("Failed to cancel subscription",n.translateService.translations["toast.title_error"]),void(n.isCancelling=!1);console.log("Cancelling subscription:",n.userData.paypalSubscriptionID),fetch(`${n.linkDomain}/userData/cancel`,{method:"POST",headers:{Authorization:`Bearer ${n.pluginConfig.token}`,"Content-Type":"application/json"},body:JSON.stringify({subscriptionID:n.userData.paypalSubscriptionID})}).then(function(){var o=vt(function*(i){if(!i.ok){const s=yield i.text();throw new Error(`Backend responded with ${i.status}: ${s}`)}return i.json()});return function(i){return o.apply(this,arguments)}}()).then(o=>{o.success?(window.homebridge.toast.success("Subscription Cancelled",n.translateService.translations["toast.title_success"]),n.userDataService.getUserData(n.linkDomain,n.pluginConfig.token).subscribe({next:i=>{n.userData=i,n.userDataChange.emit(n.userData),console.log("\u2705 Refreshed user data after cancel:",i)},error:i=>{console.error("\u274c Failed to refresh user data after cancel:",i)}})):(window.homebridge.toast.error("Failed to cancel subscription",n.translateService.translations["toast.title_error"]),console.error("\u274c Failed to cancel subscription:",o.message))}).catch(o=>{window.homebridge.toast.error("Failed to cancel subscription",n.translateService.translations["toast.title_error"]),console.error("\u274c Cancel subscription failed:",o.message||o)}).finally(()=>{n.isCancelling=!1})})()}toggleCreateSubscriptionExpand(){this.createSubscriptionExpanded=!this.createSubscriptionExpanded,this.subscriptionDetailsExpanded=!1,this.createSubscriptionExpanded&&setTimeout(()=>{console.log("Expanded and DOM updated, now rendering PayPal buttons"),this.renderPayPalButtons()},0)}toggleSubscriptionDetailsExpand(){this.subscriptionDetailsExpanded=!this.subscriptionDetailsExpanded,this.createSubscriptionExpanded=!1}renderPayPalButtons(){var n=this;this.createSubscriptionExpanded&&this.userData?.paypalPlans?.length?this.userDataService.loadScript().then(vt(function*(){const r=[];n.userData?.paypalPlans?.forEach((o,i)=>{const s=document.getElementById(`paypal-button-container-${i}`);s&&(s.innerHTML=""),r.push(n.renderPayPalButton(o,i))});try{yield Promise.all(r)}catch(o){console.error("Error rendering PayPal buttons:",o)}finally{n.isLoadingPayPalButtons=!1,console.log("\u2705 All PayPal buttons rendered")}})).catch(r=>{console.error("PayPal script failed to load",r),this.isLoadingPayPalButtons=!1}):console.log("\u274c No PayPal plans available or subscription creation not expanded")}renderPayPalButton(n,r){var o=this;return vt(function*(){if(!window.paypal?.Buttons)throw console.error("PayPal SDK not available."),new Error("PayPal SDK not available");return console.log(`Rendering PayPal button for plan ${n.id}`),new Promise((i,s)=>{var a;window.paypal.Buttons({createSubscription:(a,l)=>(console.log("Creating subscription for plan:",o.userData.startDate.toISOString()),l.subscription.create({plan_id:n.id,custom_id:"GSH|"+o.user_id,start_time:o.userData.startDate.toISOString(),application_context:{shipping_preference:"NO_SHIPPING"}})),onApprove:(a=vt(function*(l,u){console.log("\u2705 Subscription approved:",l);const c={planId:n.id,subscriptionID:l.subscriptionID,orderID:l.orderID,paymentSource:l.paymentSource,facilitatorAccessToken:l.facilitatorAccessToken};try{const p=yield(yield fetch(`${o.linkDomain}/userData/subscribe`,{method:"POST",headers:{Authorization:`Bearer ${o.pluginConfig.token}`,"Content-Type":"application/json"},body:JSON.stringify(c)})).json();console.log("\u2705 Backend subscription saved:",p),window.homebridge.toast.success("Service Subscription Created",o.translateService.translations["toast.title_success"])}catch(d){console.error("\u274c Failed to store subscription in backend:",d),window.homebridge.toast.error("Failed to create subscription",o.translateService.translations["toast.title_error"])}o.userDataService.getUserData(o.linkDomain,o.pluginConfig.token).subscribe({next:d=>{o.userData=d,o.userDataChange.emit(o.userData),console.log("\u2705 Refreshed user data after subscription:",d)},error:d=>{console.error("\u274c Failed to refresh user data after subscription:",d)}})}),function(u,c){return a.apply(this,arguments)}),onError:a=>{console.error(`PayPal error for ${n.id}:`,a),window.homebridge.toast.error("Failed to create subscription",o.translateService.translations["toast.title_error"])}}).render(`#paypal-button-container-${r}`).then(()=>{console.log(`\u2705 PayPal button rendered for plan ${n.id}`),i()}).catch(a=>{console.error(`\u274c Failed to render PayPal button for plan ${n.id}:`,a),s(a)})})})()}static \u0275fac=function(r){return new(r||e)(L(ay),L(Au))};static \u0275cmp=Ao({type:e,selectors:[["app-user-data"]],inputs:{pluginConfig:"pluginConfig",linkDomain:"linkDomain",user_id:"user_id"},outputs:{userDataChange:"userDataChange"},decls:1,vars:1,consts:[["class","card card-body w-100 mt-3",4,"ngIf"],[1,"card","card-body","w-100","mt-3"],["class","mt-3",4,"ngIf"],[2,"white-space","nowrap"],["target","_blank","rel","noopener noreferrer",3,"href"],[1,"mt-3"],[3,"ngClass"],[1,"legend",3,"click"],[4,"ngIf"],[1,"card-body","pt-3","px-0"],[1,"fw-bold"],[1,"position-relative"],["class","loading-overlay",4,"ngIf"],["class","paypal-plan-container",4,"ngFor","ngForOf"],[1,"loading-overlay"],[1,"fas","fa-fw","fa-spinner","fa-spin","fa-2x"],[1,"paypal-plan-container"],[1,"card","shadow-sm","mb-2"],[1,"card-body","d-flex","align-items-center","justify-content-between"],[1,"paypal-text"],[1,"card-title"],[1,"card-text"],[1,"paypal-button",3,"id"],[1,"card-body","pt-3","px-0","position-relative"],["class","position-fixed top-0 start-0 w-100 h-100 d-flex align-items-center justify-content-center","style","background: rgba(0,0,0,0.4); z-index: 1050;",4,"ngIf"],[1,"d-flex","justify-content-between","align-items-start","flex-wrap","w-100"],[1,"table","table-borderless","mb-0","subscription-table",2,"width","auto"],[1,"pe-3","text-nowrap"],[1,"ms-3"],[1,"btn","btn-primary",3,"click"],[1,"position-fixed","top-0","start-0","w-100","h-100","d-flex","align-items-center","justify-content-center",2,"background","rgba(0,0,0,0.4)","z-index","1050"],[1,"card","shadow","border-0","p-4",2,"max-width","400px","width","100%","border-radius","12px"],[1,"fw-bold","mb-3","text-center"],[1,"mb-2","text-center"],[1,"mb-4","text-center","small"],[1,"d-flex","justify-content-center","gap-3"],[1,"btn","btn-outline-secondary","px-4",3,"disabled","click"],[1,"btn","btn-danger","px-4",3,"disabled","click"]],template:function(r,o){1&r&&oe(0,qx,7,3,"div",0),2&r&&V("ngIf",null==o.userData?null:o.userData.subscriptionRequired)},dependencies:[du,pm,Gi,Lx],styles:['.expandable[_ngcontent-%COMP%] > legend[_ngcontent-%COMP%]:before, .expanded[_ngcontent-%COMP%] > legend[_ngcontent-%COMP%]:before{content:"\\f054";font-family:"Font Awesome 6 Free",FontAwesome;font-weight:900;padding-right:.3em}.expanded[_ngcontent-%COMP%] > legend[_ngcontent-%COMP%]:before{content:"\\f078";padding-right:.2em}fieldset[_ngcontent-%COMP%]{padding:0;border:none}legend[_ngcontent-%COMP%]{font-weight:700;cursor:pointer;-webkit-user-select:none;user-select:none;margin-bottom:.5rem}']})}return e})(),Zx=(()=>{class e{translateService;constructor(n){this.translateService=n}transform(n){return this.translateService.translations[n]}static \u0275fac=function(r){return new(r||e)(L(Au,16))};static \u0275pipe=Se({name:"translate",type:e,pure:!0})}return e})();function Jx(e,t){1&e&&(I(0,"div")(1,"div",1),Ke(2,"p",2),ot(3,"translate"),I(4,"p",3)(5,"span"),N(6),ot(7,"translate"),S(),I(8,"a",4),N(9," https://github.com/homebridge/homebridge-config-ui-x/wiki/Enabling-Accessory-Control "),S(),I(10,"span"),N(11),ot(12,"translate"),S()()()()),2&e&&(T(2),V("innerHTML",it(3,3,"accessories.message_must_use_insecure_mode"),si),T(4),Qe(it(7,5,"accessories.message_please_see")),T(5),Qe(it(12,7,"accessories.message_for_more_information")))}function Kx(e,t){1&e&&Ke(0,"p",8)}function Qx(e,t){1&e&&(I(0,"div"),Ke(1,"app-markdown-viewer",9),S()),2&e&&(T(1),V("filename","NEWUSER.md"))}function Yx(e,t){if(1&e){const n=bn();I(0,"div",10)(1,"button",11),zt("click",function(){return tn(n),nn(me(3).linkAccount())}),N(2),ot(3,"translate"),S()()}2&e&&(T(2),Gt(" ",it(3,1,"plugins.settings.custom.homebridge-gsh.label_link_account")," "))}function Xx(e,t){1&e&&Ke(0,"img",26)}function ek(e,t){1&e&&Ke(0,"img",27)}function tk(e,t){if(1&e&&(I(0,"li",20)(1,"span",21),Ke(2,"img",28),N(3," Google Home App: "),S(),I(4,"span",29),N(5),S()()),2&e){const n=me(4);T(4),V("ngClass",n.userData.gshNotLinked?"bg-danger":"bg-success"),T(1),Gt(" ",n.userData.gshNotLinked?"Not Linked":"Linked"," ")}}function nk(e,t){if(1&e&&(I(0,"li",20)(1,"span",21),N(2,"Account Status:"),S(),I(3,"span",22),N(4),S()()),2&e){const n=me(4);T(4),Qe(n.userData.accountStatus.text)}}function rk(e,t){1&e&&(I(0,"div",30)(1,"p")(2,"strong"),N(3,"Complete Setup:"),S(),N(4," Search for "),I(5,"strong"),N(6,"Homebridge"),S(),N(7," in the Google Home app and link the action to finalize your setup. "),S(),I(8,"div")(9,"span",31),N(10," \u{1f4d6} "),I(11,"a",32),N(12," Further instructions "),S()()()())}function ok(e,t){1&e&&(I(0,"div",33)(1,"strong"),N(2),ot(3,"translate"),S()()),2&e&&(T(2),Gt(" ",it(3,1,"plugins.settings.custom.homebridge-gsh.message_homebridge_restart_required")," "))}function ik(e,t){if(1&e){const n=bn();I(0,"div",12)(1,"div",13)(2,"div",14)(3,"h4",15),oe(4,Xx,1,0,"img",16),oe(5,ek,1,0,"img",17),I(6,"span"),N(7),ot(8,"titlecase"),ot(9,"translate"),S()(),I(10,"ul",18),oe(11,tk,6,2,"li",19),I(12,"li",20)(13,"span",21),N(14,"User ID:"),S(),I(15,"span",22),N(16),S()(),oe(17,nk,5,1,"li",19),S()()(),oe(18,rk,13,0,"div",23),I(19,"app-user-data",24),zt("userDataChange",function(o){return tn(n),nn(me(3).onUserDataChange(o))}),S(),oe(20,ok,4,3,"div",25),S()}if(2&e){const n=me(3);T(4),V("ngIf","google"===n.linkType),T(1),V("ngIf","github"===n.linkType),T(2),yl("",it(8,12,n.linkType)," ",it(9,14,"plugins.settings.custom.homebridge-gsh.label_account_linked"),""),T(4),V("ngIf",n.userData),T(5),Qe(n.user_id),T(1),V("ngIf",n.userData&&n.userData.subscriptionRequired),T(1),V("ngIf",n.pluginConfig.token&&n.userData&&n.userData.gshNotLinked),T(1),V("pluginConfig",n.pluginConfig)("linkDomain",n.linkDomain)("user_id",n.user_id),T(1),V("ngIf",n.justLinked)}}function sk(e,t){if(1&e&&(I(0,"div"),Ke(1,"span",2),ot(2,"translate"),oe(3,Kx,1,0,"p",5),oe(4,Qx,2,1,"div",0),oe(5,Yx,4,3,"div",6),oe(6,ik,21,16,"div",7),S()),2&e){const n=me(2);T(1),V("innerHTML",it(2,5,"plugins.settings.custom.homebridge-gsh.message_about"),si),T(2),V("ngIf",!n.pluginConfig.token),T(1),V("ngIf",!(null!=n.pluginConfig&&n.pluginConfig.token)),T(1),V("ngIf",!n.pluginConfig.token),T(1),V("ngIf",n.pluginConfig.token)}}function ak(e,t){if(1&e&&(I(0,"div"),oe(1,Jx,13,9,"div",0),oe(2,sk,7,7,"div",0),S()),2&e){const n=me();T(1),V("ngIf",!n.env.enableAccessories),T(1),V("ngIf",n.env.enableAccessories)}}const lk=new KM;let uk=(()=>{class e{translateService;userDataService;linkDomain;linkUrl;popup;originCheckInterval;pluginConfig;schema;env=window.homebridge.serverEnv.env;linkType;user_id;justLinked=!1;ready=!1;userData;constructor(n,r){this.translateService=n,this.userDataService=r}ngOnInit(){var n=this;return vt(function*(){n.schema=yield window.homebridge.getPluginConfigSchema();const r=yield window.homebridge.getPluginConfig();r.length?(n.pluginConfig=r[0],window.homebridge.showSchemaForm()):n.pluginConfig={name:"Google Smart Home",platform:n.schema.pluginAlias},n.linkDomain=n.pluginConfig.betaServer?"https://clone-gsh.homebridge.ca":"https://gsh.homebridge.ca",n.linkUrl=n.linkDomain+"/link-account",n.parseToken(),n.ready=!0,window.homebridge.addEventListener("configChanged",o=>{n.pluginConfig=o.data[0]})})()}updateConfig(){var n=this;return vt(function*(){return window.homebridge.updatePluginConfig([n.pluginConfig])})()}linkAccount(){window.addEventListener("message",this.windowMessageListener,!1);const o=window.top.outerHeight/2+window.top.screenY-350,i=window.top.outerWidth/2+window.top.screenX-225;this.popup=window.open(this.linkUrl,"oznu-google-smart-home-auth",`toolbar=no, location=no, directories=no, status=no, menubar=no scrollbars=no, resizable=no, copyhistory=no, width=450, height=700, top=${o}, left=${i}`),this.originCheckInterval=setInterval(()=>{this.popup.postMessage("origin-check",this.linkDomain)},2e3)}processToken(n){var r=this;return vt(function*(){clearInterval(r.originCheckInterval),r.popup&&r.popup.close(),r.pluginConfig.token=n,r.pluginConfig.notice="Keep your token a secret!",r.parseToken(),r.justLinked=!0,yield r.updateConfig(),yield window.homebridge.savePluginConfig(),window.homebridge.showSchemaForm()})()}parseToken(){if(this.pluginConfig.token)try{const n=lk.decodeToken(this.pluginConfig.token);this.linkType=n.id.split("|")[0].split("-")[0],this.user_id=n.id}catch{window.homebridge.toast.error("Invalid account linking token in config.json",this.translateService.translations["toast.title_error"]),delete this.pluginConfig.token}}windowMessageListener=n=>{if(n.origin===this.linkDomain)try{const r=JSON.parse(n.data);r.token?this.processToken(r.token):console.log("Received message from popup:",r)}catch(r){console.error(r)}};onUserDataChange(n){this.userData=n}ngOnDestroy(){clearInterval(this.originCheckInterval),window.removeEventListener("message",this.windowMessageListener),this.popup&&this.popup.close()}copyToClipboard(n){navigator.clipboard.writeText(n).then(()=>{window.homebridge.toast.success(`Copied ${n} to clipboard`)},r=>{console.error("\u274c Failed to copy:",r),window.homebridge.toast.error("Error","Failed to copy")})}static \u0275fac=function(r){return new(r||e)(L(Au),L(ay))};static \u0275cmp=Ao({type:e,selectors:[["app-root"]],decls:1,vars:1,consts:[[4,"ngIf"],["role","alert",1,"alert","alert-warning"],[3,"innerHTML"],[1,"mb-0"],["target","_blank","rel","noopener noreferrer","href","https://github.com/homebridge/homebridge-config-ui-x/wiki/Enabling-Accessory-Control"],["translate","plugins.settings.custom.homebridge-gsh.message_account_link_required",4,"ngIf"],["class","text-center",4,"ngIf"],["class","mt-1",4,"ngIf"],["translate","plugins.settings.custom.homebridge-gsh.message_account_link_required"],[3,"filename"],[1,"text-center"],[1,"btn","btn-primary","btn-lg",3,"click"],[1,"mt-1"],[1,"card"],[1,"card-body","p-3"],[1,"card-title","d-flex","align-items-center","justify-content-center","mb-3"],["class","me-2","src","assets/google-logo.svg","alt","Google Logo","style","height: 48px;",4,"ngIf"],["class","invert-on-dark me-2","src","assets/github-mark.svg","alt","GitHub Logo","style","height: 48px;",4,"ngIf"],[1,"list-group","list-group-flush"],["class","list-group-item d-flex justify-content-between align-items-center p-2",4,"ngIf"],[1,"list-group-item","d-flex","justify-content-between","align-items-center","p-2"],[1,"fw-bold"],[1,"text-break"],["class","alert alert-info mt-3","role","alert","style","text-align: left;",4,"ngIf"],[3,"pluginConfig","linkDomain","user_id","userDataChange"],["class","alert alert-info mt-3","role","alert",4,"ngIf"],["src","assets/google-logo.svg","alt","Google Logo",1,"me-2",2,"height","48px"],["src","assets/github-mark.svg","alt","GitHub Logo",1,"invert-on-dark","me-2",2,"height","48px"],["src","assets/google-home.svg","alt","Google Home Icon",2,"width","24px","height","24px","vertical-align","middle","margin-right","8px"],[1,"badge",3,"ngClass"],["role","alert",1,"alert","alert-info","mt-3",2,"text-align","left"],[2,"white-space","nowrap"],["href","https://github.com/homebridge-plugins/homebridge-gsh/wiki#add-homebridge-to-google-home-app","target","_blank","rel","noopener noreferrer"],["role","alert",1,"alert","alert-info","mt-3"]],template:function(r,o){1&r&&oe(0,ak,3,2,"div",0),2&r&&V("ngIf",o.translateService.ready&&o.ready)},dependencies:[du,Gi,Ox,Wx,ym,Zx]})}return e})();vo(178);let ck=(()=>{class e{static \u0275fac=function(r){return new(r||e)};static \u0275mod=An({type:e,bootstrap:[uk]});static \u0275inj=dn({imports:[gM,ZM]})}return e})();console.log=()=>{},console.warn=()=>{},hM().bootstrapModule(ck).catch(e=>console.error(e))},178:(Do,ls)=>{}},Do=>{Do(Do.s=450)}]);