From 45677b96472d5d98867fd0f956c636d51d6112b3 Mon Sep 17 00:00:00 2001 From: chrisfried Date: Sat, 9 Mar 2024 20:03:31 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20chrisfri?= =?UTF-8?q?ed/secret-scrublandeux@4301d3d96fe11e63026227a0886002f83b0bf81f?= =?UTF-8?q?=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 404.html | 2 +- index.html | 2 +- main.1cb7da7e802c6ca7.js | 1 + main.b0a2d2c8312e10f4.js | 1 - 4 files changed, 3 insertions(+), 3 deletions(-) create mode 100644 main.1cb7da7e802c6ca7.js delete mode 100644 main.b0a2d2c8312e10f4.js diff --git a/404.html b/404.html index a32923b..21d2a65 100644 --- a/404.html +++ b/404.html @@ -14,6 +14,6 @@ - + \ No newline at end of file diff --git a/index.html b/index.html index a32923b..21d2a65 100644 --- a/index.html +++ b/index.html @@ -14,6 +14,6 @@ - + \ No newline at end of file diff --git a/main.1cb7da7e802c6ca7.js b/main.1cb7da7e802c6ca7.js new file mode 100644 index 0000000..584e4ff --- /dev/null +++ b/main.1cb7da7e802c6ca7.js @@ -0,0 +1 @@ +(self.webpackChunkscrublandeux=self.webpackChunkscrublandeux||[]).push([[179],{1658:(Aa,ka,dt)=>{"use strict";function qr(n){return"function"==typeof n}let le=!1;const pt={Promise:void 0,set useDeprecatedSynchronousErrorHandling(n){if(n){const e=new Error;console.warn("DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \n"+e.stack)}else le&&console.log("RxJS: Back to a better error behavior. Thank you. <3");le=n},get useDeprecatedSynchronousErrorHandling(){return le}};function ps(n){setTimeout(()=>{throw n},0)}const Ia={closed:!0,next(n){},error(n){if(pt.useDeprecatedSynchronousErrorHandling)throw n;ps(n)},complete(){}},_i=Array.isArray||(n=>n&&"number"==typeof n.length);function ao(n){return null!==n&&"object"==typeof n}const Kr=(()=>{function n(e){return Error.call(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((t,i)=>`${i+1}) ${t.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e,this}return n.prototype=Object.create(Error.prototype),n})();class Tn{constructor(e){this.closed=!1,this._parentOrParents=null,this._subscriptions=null,e&&(this._unsubscribe=e)}unsubscribe(){let e;if(this.closed)return;let{_parentOrParents:t,_unsubscribe:i,_subscriptions:r}=this;if(this.closed=!0,this._parentOrParents=null,this._subscriptions=null,t instanceof Tn)t.remove(this);else if(null!==t)for(let s=0;se.concat(t instanceof Kr?t.errors:t),[])}Tn.EMPTY=((n=new Tn).closed=!0,n);const _e="function"==typeof Symbol?Symbol("rxSubscriber"):"@@rxSubscriber_"+Math.random();class di extends Tn{constructor(e,t,i){switch(super(),this.syncErrorValue=null,this.syncErrorThrown=!1,this.syncErrorThrowable=!1,this.isStopped=!1,arguments.length){case 0:this.destination=Ia;break;case 1:if(!e){this.destination=Ia;break}if("object"==typeof e){e instanceof di?(this.syncErrorThrowable=e.syncErrorThrowable,this.destination=e,e.add(this)):(this.syncErrorThrowable=!0,this.destination=new ks(this,e));break}default:this.syncErrorThrowable=!0,this.destination=new ks(this,e,t,i)}}[_e](){return this}static create(e,t,i){const r=new di(e,t,i);return r.syncErrorThrowable=!1,r}next(e){this.isStopped||this._next(e)}error(e){this.isStopped||(this.isStopped=!0,this._error(e))}complete(){this.isStopped||(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe())}_next(e){this.destination.next(e)}_error(e){this.destination.error(e),this.unsubscribe()}_complete(){this.destination.complete(),this.unsubscribe()}_unsubscribeAndRecycle(){const{_parentOrParents:e}=this;return this._parentOrParents=null,this.unsubscribe(),this.closed=!1,this.isStopped=!1,this._parentOrParents=e,this}}class ks extends di{constructor(e,t,i,r){super(),this._parentSubscriber=e;let s,o=this;qr(t)?s=t:t&&(s=t.next,i=t.error,r=t.complete,t!==Ia&&(o=Object.create(t),qr(o.unsubscribe)&&this.add(o.unsubscribe.bind(o)),o.unsubscribe=this.unsubscribe.bind(this))),this._context=o,this._next=s,this._error=i,this._complete=r}next(e){if(!this.isStopped&&this._next){const{_parentSubscriber:t}=this;pt.useDeprecatedSynchronousErrorHandling&&t.syncErrorThrowable?this.__tryOrSetError(t,this._next,e)&&this.unsubscribe():this.__tryOrUnsub(this._next,e)}}error(e){if(!this.isStopped){const{_parentSubscriber:t}=this,{useDeprecatedSynchronousErrorHandling:i}=pt;if(this._error)i&&t.syncErrorThrowable?(this.__tryOrSetError(t,this._error,e),this.unsubscribe()):(this.__tryOrUnsub(this._error,e),this.unsubscribe());else if(t.syncErrorThrowable)i?(t.syncErrorValue=e,t.syncErrorThrown=!0):ps(e),this.unsubscribe();else{if(this.unsubscribe(),i)throw e;ps(e)}}}complete(){if(!this.isStopped){const{_parentSubscriber:e}=this;if(this._complete){const t=()=>this._complete.call(this._context);pt.useDeprecatedSynchronousErrorHandling&&e.syncErrorThrowable?(this.__tryOrSetError(e,t),this.unsubscribe()):(this.__tryOrUnsub(t),this.unsubscribe())}else this.unsubscribe()}}__tryOrUnsub(e,t){try{e.call(this._context,t)}catch(i){if(this.unsubscribe(),pt.useDeprecatedSynchronousErrorHandling)throw i;ps(i)}}__tryOrSetError(e,t,i){if(!pt.useDeprecatedSynchronousErrorHandling)throw new Error("bad call");try{t.call(this._context,i)}catch(r){return pt.useDeprecatedSynchronousErrorHandling?(e.syncErrorValue=r,e.syncErrorThrown=!0,!0):(ps(r),!0)}return!1}_unsubscribe(){const{_parentSubscriber:e}=this;this._context=null,this._parentSubscriber=null,e.unsubscribe()}}const ms="function"==typeof Symbol&&Symbol.observable||"@@observable";function Is(n){return n}function Sr(n){return 0===n.length?Is:1===n.length?n[0]:function(t){return n.reduce((i,r)=>r(i),t)}}let un=(()=>{class n{constructor(t){this._isScalar=!1,t&&(this._subscribe=t)}lift(t){const i=new n;return i.source=this,i.operator=t,i}subscribe(t,i,r){const{operator:s}=this,o=function El(n,e,t){if(n){if(n instanceof di)return n;if(n[_e])return n[_e]()}return n||e||t?new di(n,e,t):new di(Ia)}(t,i,r);if(o.add(s?s.call(o,this.source):this.source||pt.useDeprecatedSynchronousErrorHandling&&!o.syncErrorThrowable?this._subscribe(o):this._trySubscribe(o)),pt.useDeprecatedSynchronousErrorHandling&&o.syncErrorThrowable&&(o.syncErrorThrowable=!1,o.syncErrorThrown))throw o.syncErrorValue;return o}_trySubscribe(t){try{return this._subscribe(t)}catch(i){pt.useDeprecatedSynchronousErrorHandling&&(t.syncErrorThrown=!0,t.syncErrorValue=i),function Fa(n){for(;n;){const{closed:e,destination:t,isStopped:i}=n;if(e||i)return!1;n=t&&t instanceof di?t:null}return!0}(t)?t.error(i):console.warn(i)}}forEach(t,i){return new(i=Ra(i))((r,s)=>{let o;o=this.subscribe(a=>{try{t(a)}catch(c){s(c),o&&o.unsubscribe()}},s,r)})}_subscribe(t){const{source:i}=this;return i&&i.subscribe(t)}[ms](){return this}pipe(...t){return 0===t.length?this:Sr(t)(this)}toPromise(t){return new(t=Ra(t))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=e=>new n(e),n})();function Ra(n){if(n||(n=pt.Promise||Promise),!n)throw new Error("no Promise impl found");return n}const Pa=(()=>{function n(){return Error.call(this),this.message="object unsubscribed",this.name="ObjectUnsubscribedError",this}return n.prototype=Object.create(Error.prototype),n})();class Ws extends Tn{constructor(e,t){super(),this.subject=e,this.subscriber=t,this.closed=!1}unsubscribe(){if(this.closed)return;this.closed=!0;const e=this.subject,t=e.observers;if(this.subject=null,!t||0===t.length||e.isStopped||e.closed)return;const i=t.indexOf(this.subscriber);-1!==i&&t.splice(i,1)}}class du extends di{constructor(e){super(e),this.destination=e}}let cn=(()=>{class n extends un{constructor(){super(),this.observers=[],this.closed=!1,this.isStopped=!1,this.hasError=!1,this.thrownError=null}[_e](){return new du(this)}lift(t){const i=new od(this,this);return i.operator=t,i}next(t){if(this.closed)throw new Pa;if(!this.isStopped){const{observers:i}=this,r=i.length,s=i.slice();for(let o=0;onew od(e,t),n})();class od extends cn{constructor(e,t){super(),this.destination=e,this.source=t}next(e){const{destination:t}=this;t&&t.next&&t.next(e)}error(e){const{destination:t}=this;t&&t.error&&this.destination.error(e)}complete(){const{destination:e}=this;e&&e.complete&&this.destination.complete()}_subscribe(e){const{source:t}=this;return t?this.source.subscribe(e):Tn.EMPTY}}function cc(n){return n&&"function"==typeof n.schedule}class Pt extends di{constructor(e,t,i){super(),this.parent=e,this.outerValue=t,this.outerIndex=i,this.index=0}_next(e){this.parent.notifyNext(this.outerValue,e,this.outerIndex,this.index++,this)}_error(e){this.parent.notifyError(e,this),this.unsubscribe()}_complete(){this.parent.notifyComplete(this),this.unsubscribe()}}const $t=n=>e=>{for(let t=0,i=n.length;tn&&"number"==typeof n.length&&"function"!=typeof n;function co(n){return!!n&&"function"!=typeof n.subscribe&&"function"==typeof n.then}const dc=n=>{if(n&&"function"==typeof n[ms])return(n=>e=>{const t=n[ms]();if("function"!=typeof t.subscribe)throw new TypeError("Provided object does not correctly implement Symbol.observable");return t.subscribe(e)})(n);if(lc(n))return $t(n);if(co(n))return(n=>e=>(n.then(t=>{e.closed||(e.next(t),e.complete())},t=>e.error(t)).then(null,ps),e))(n);if(n&&"function"==typeof n[fn])return(n=>e=>{const t=n[fn]();for(;;){let i;try{i=t.next()}catch(r){return e.error(r),e}if(i.done){e.complete();break}if(e.next(i.value),e.closed)break}return"function"==typeof t.return&&e.add(()=>{t.return&&t.return()}),e})(n);{const t=`You provided ${ao(n)?"an invalid object":`'${n}'`} where a stream was expected. You can provide an Observable, Promise, Array, or Iterable.`;throw new TypeError(t)}};function $o(n,e,t,i,r=new Pt(n,t,i)){if(!r.closed)return e instanceof un?e.subscribe(r):dc(e)(r)}class Fs extends di{notifyNext(e,t,i,r,s){this.destination.next(t)}notifyError(e,t){this.destination.error(e)}notifyComplete(e){this.destination.complete()}}function _t(n,e){return function(i){if("function"!=typeof n)throw new TypeError("argument is not a function. Are you looking for `mapTo()`?");return i.lift(new uu(n,e))}}class uu{constructor(e,t){this.project=e,this.thisArg=t}call(e,t){return t.subscribe(new zc(e,this.project,this.thisArg))}}class zc extends di{constructor(e,t,i){super(e),this.project=t,this.count=0,this.thisArg=i||this}_next(e){let t;try{t=this.project.call(this.thisArg,e,this.count++)}catch(i){return void this.destination.error(i)}this.destination.next(t)}}function lo(n,e){return new un(t=>{const i=new Tn;let r=0;return i.add(e.schedule(function(){r!==n.length?(t.next(n[r++]),t.closed||i.add(this.schedule())):t.complete()})),i})}function dr(n,e){return e?function Mp(n,e){if(null!=n){if(function Gc(n){return n&&"function"==typeof n[ms]}(n))return function hu(n,e){return new un(t=>{const i=new Tn;return i.add(e.schedule(()=>{const r=n[ms]();i.add(r.subscribe({next(s){i.add(e.schedule(()=>t.next(s)))},error(s){i.add(e.schedule(()=>t.error(s)))},complete(){i.add(e.schedule(()=>t.complete()))}}))})),i})}(n,e);if(co(n))return function Ep(n,e){return new un(t=>{const i=new Tn;return i.add(e.schedule(()=>n.then(r=>{i.add(e.schedule(()=>{t.next(r),i.add(e.schedule(()=>t.complete()))}))},r=>{i.add(e.schedule(()=>t.error(r)))}))),i})}(n,e);if(lc(n))return lo(n,e);if(function Oa(n){return n&&"function"==typeof n[fn]}(n)||"string"==typeof n)return function ad(n,e){if(!n)throw new Error("Iterable cannot be null");return new un(t=>{const i=new Tn;let r;return i.add(()=>{r&&"function"==typeof r.return&&r.return()}),i.add(e.schedule(()=>{r=n[fn](),i.add(e.schedule(function(){if(t.closed)return;let s,o;try{const a=r.next();s=a.value,o=a.done}catch(a){return void t.error(a)}o?t.complete():(t.next(s),this.schedule())}))})),i})}(n,e)}throw new TypeError((null!==n&&typeof n||n)+" is not observable")}(n,e):n instanceof un?n:new un(dc(n))}function ur(n,e,t=Number.POSITIVE_INFINITY){return"function"==typeof e?i=>i.pipe(ur((r,s)=>dr(n(r,s)).pipe(_t((o,a)=>e(r,o,s,a))),t)):("number"==typeof e&&(t=e),i=>i.lift(new qo(n,t)))}class qo{constructor(e,t=Number.POSITIVE_INFINITY){this.project=e,this.concurrent=t}call(e,t){return t.subscribe(new cd(e,this.project,this.concurrent))}}class cd extends Fs{constructor(e,t,i=Number.POSITIVE_INFINITY){super(e),this.project=t,this.concurrent=i,this.hasCompleted=!1,this.buffer=[],this.active=0,this.index=0}_next(e){this.active0?this._next(t.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()}}function Ml(n=Number.POSITIVE_INFINITY){return ur(Is,n)}function uc(n,e){return e?lo(n,e):new un($t(n))}function fa(...n){let e=Number.POSITIVE_INFINITY,t=null,i=n[n.length-1];return cc(i)?(t=n.pop(),n.length>1&&"number"==typeof n[n.length-1]&&(e=n.pop())):"number"==typeof i&&(e=n.pop()),null===t&&1===n.length&&n[0]instanceof un?n[0]:Ml(e)(uc(n,t))}function hc(){return function(e){return e.lift(new Cl(e))}}class Cl{constructor(e){this.connectable=e}call(e,t){const{connectable:i}=this;i._refCount++;const r=new Fh(e,i),s=t.subscribe(r);return r.closed||(r.connection=i.connect()),s}}class Fh extends di{constructor(e,t){super(e),this.connectable=t}_unsubscribe(){const{connectable:e}=this;if(!e)return void(this.connection=null);this.connectable=null;const t=e._refCount;if(t<=0)return void(this.connection=null);if(e._refCount=t-1,t>1)return void(this.connection=null);const{connection:i}=this,r=e._connection;this.connection=null,r&&(!i||r===i)&&r.unsubscribe()}}class ld extends un{constructor(e,t){super(),this.source=e,this.subjectFactory=t,this._refCount=0,this._isComplete=!1}_subscribe(e){return this.getSubject().subscribe(e)}getSubject(){const e=this._subject;return(!e||e.isStopped)&&(this._subject=this.subjectFactory()),this._subject}connect(){let e=this._connection;return e||(this._isComplete=!1,e=this._connection=new Tn,e.add(this.source.subscribe(new Ph(this.getSubject(),this))),e.closed&&(this._connection=null,e=Tn.EMPTY)),e}refCount(){return hc()(this)}}const Rh=(()=>{const n=ld.prototype;return{operator:{value:null},_refCount:{value:0,writable:!0},_subject:{value:null,writable:!0},_connection:{value:null,writable:!0},_subscribe:{value:n._subscribe},_isComplete:{value:n._isComplete,writable:!0},getSubject:{value:n.getSubject},connect:{value:n.connect},refCount:{value:n.refCount}}})();class Ph extends du{constructor(e,t){super(e),this.connectable=t}_error(e){this._unsubscribe(),super._error(e)}_complete(){this.connectable._isComplete=!0,this._unsubscribe(),super._complete()}_unsubscribe(){const e=this.connectable;if(e){this.connectable=null;const t=e._connection;e._refCount=0,e._subject=null,e._connection=null,t&&t.unsubscribe()}}}class Nh{constructor(e,t){this.subjectFactory=e,this.selector=t}call(e,t){const{selector:i}=this,r=this.subjectFactory(),s=i(r).subscribe(e);return s.add(t.subscribe(r)),s}}function Bh(){return new cn}function Dp(){return n=>hc()(function Lh(n,e){return function(i){let r;if(r="function"==typeof n?n:function(){return n},"function"==typeof e)return i.lift(new Nh(r,e));const s=Object.create(i,Rh);return s.source=i,s.subjectFactory=r,s}}(Bh)(n))}function Vi(n){for(let e in n)if(n[e]===Vi)return e;throw Error("Could not find renamed property on target object.")}function Vh(n,e){for(const t in e)e.hasOwnProperty(t)&&!n.hasOwnProperty(t)&&(n[t]=e[t])}function ki(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(ki).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const e=n.toString();if(null==e)return""+e;const t=e.indexOf("\n");return-1===t?e:e.substring(0,t)}function fu(n,e){return null==n||""===n?null===e?"":e:null==e||""===e?n:n+" "+e}const Tp=Vi({__forward_ref__:Vi});function Mi(n){return n.__forward_ref__=Mi,n.toString=function(){return ki(this())},n}function en(n){return Hh(n)?n():n}function Hh(n){return"function"==typeof n&&n.hasOwnProperty(Tp)&&n.__forward_ref__===Mi}function pu(n){return n&&!!n.\u0275providers}const mu="https://g.co/ng/security#xss";class Ue extends Error{constructor(e,t){super(Dl(e,t)),this.code=e}}function Dl(n,e){return`NG0${Math.abs(n)}${e?": "+e.trim():""}`}function wn(n){return"string"==typeof n?n:null==n?"":String(n)}function gu(n,e){throw new Ue(-201,!1)}function Rs(n,e){null==n&&function Ci(n,e,t,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${t} ${i} ${e} <=Actual]`))}(e,n,null,"!=")}function Je(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function On(n){return{providers:n.providers||[],imports:n.imports||[]}}function _u(n){return kp(n,Tl)||kp(n,zh)}function kp(n,e){return n.hasOwnProperty(e)?n[e]:null}function Uh(n){return n&&(n.hasOwnProperty(Xr)||n.hasOwnProperty(vu))?n[Xr]:null}const Tl=Vi({\u0275prov:Vi}),Xr=Vi({\u0275inj:Vi}),zh=Vi({ngInjectableDef:Vi}),vu=Vi({ngInjectorDef:Vi});var tn=(()=>((tn=tn||{})[tn.Default=0]="Default",tn[tn.Host=1]="Host",tn[tn.Self=2]="Self",tn[tn.SkipSelf=4]="SkipSelf",tn[tn.Optional=8]="Optional",tn))();let dd;function ho(n){const e=dd;return dd=n,e}function yu(n,e,t){const i=_u(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:t&tn.Optional?null:void 0!==e?e:void gu(ki(n))}const Ii=(()=>typeof globalThis<"u"&&globalThis||typeof global<"u"&&global||typeof window<"u"&&window||typeof self<"u"&&typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&self)(),pc={},qs="__NG_DI_FLAG__",hd="ngTempTokenPath",Gh="ngTokenPath",jh=/\n/gm,Op="\u0275",Wh="__source";let Ao;function hr(n){const e=Ao;return Ao=n,e}function Sb(n,e=tn.Default){if(void 0===Ao)throw new Ue(-203,!1);return null===Ao?yu(n,void 0,e):Ao.get(n,e&tn.Optional?null:void 0,e)}function xe(n,e=tn.Default){return(function Rp(){return dd}()||Sb)(en(n),e)}function hn(n,e=tn.Default){return xe(n,bu(e))}function bu(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Ut(n){const e=[];for(let t=0;t((ko=ko||{})[ko.OnPush=0]="OnPush",ko[ko.Default=1]="Default",ko))(),Ko=(()=>(function(n){n[n.Emulated=0]="Emulated",n[n.None=2]="None",n[n.ShadowDom=3]="ShadowDom"}(Ko||(Ko={})),Ko))();const Na={},Si=[],xu=Vi({\u0275cmp:Vi}),$h=Vi({\u0275dir:Vi}),fr=Vi({\u0275pipe:Vi}),qh=Vi({\u0275mod:Vi}),Ba=Vi({\u0275fac:Vi}),pr=Vi({__NG_ELEMENT_ID__:Vi});let Np=0;function Ln(n){return mc(()=>{const t=!0===n.standalone,i={},r={type:n.type,providersResolver:null,decls:n.decls,vars:n.vars,factory:null,template:n.template||null,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:i,inputs:null,outputs:null,exportAs:n.exportAs||null,onPush:n.changeDetection===ko.OnPush,directiveDefs:null,pipeDefs:null,standalone:t,dependencies:t&&n.dependencies||null,getStandaloneInjector:null,selectors:n.selectors||Si,viewQuery:n.viewQuery||null,features:n.features||null,data:n.data||{},encapsulation:n.encapsulation||Ko.Emulated,id:"c"+Np++,styles:n.styles||Si,_:null,setInput:null,schemas:n.schemas||null,tView:null,findHostDirectiveDefs:null,hostDirectives:null},s=n.dependencies,o=n.features;return r.inputs=Kh(n.inputs,i),r.outputs=Kh(n.outputs),o&&o.forEach(a=>a(r)),r.directiveDefs=s?()=>("function"==typeof s?s():s).map(wu).filter(fo):null,r.pipeDefs=s?()=>("function"==typeof s?s():s).map(Ps).filter(fo):null,r})}function wu(n){return Ei(n)||Ni(n)}function fo(n){return null!==n}function Mt(n){return mc(()=>({type:n.type,bootstrap:n.bootstrap||Si,declarations:n.declarations||Si,imports:n.imports||Si,exports:n.exports||Si,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function Kh(n,e){if(null==n)return Na;const t={};for(const i in n)if(n.hasOwnProperty(i)){let r=n[i],s=r;Array.isArray(r)&&(s=r[1],r=r[0]),t[r]=i,e&&(e[r]=s)}return t}const ut=Ln;function Yi(n){return{type:n.type,name:n.name,factory:null,pure:!1!==n.pure,standalone:!0===n.standalone,onDestroy:n.type.prototype.ngOnDestroy||null}}function Ei(n){return n[xu]||null}function Ni(n){return n[$h]||null}function Ps(n){return n[fr]||null}function po(n,e){const t=n[qh]||null;if(!t&&!0===e)throw new Error(`Type ${ki(n)} does not have '\u0275mod' property.`);return t}const Nr=0,xt=1,Sn=2,Zi=3,si=4,Ks=5,Br=6,Al=7,Ji=8,rt=9,w=10,Hn=11,fd=12,Va=13,pa=14,Ir=15,Jr=16,kl=17,gc=18,Qr=19,ma=20,Er=21,nn=22,mo=1,Ys=2,Fl=7,Io=8,ei=9,gs=10;function go(n){return Array.isArray(n)&&"object"==typeof n[mo]}function Yo(n){return Array.isArray(n)&&!0===n[mo]}function Vr(n){return 0!=(4&n.flags)}function _s(n){return n.componentOffset>-1}function ga(n){return 1==(1&n.flags)}function Fo(n){return null!==n.template}function Hp(n){return 0!=(256&n[Sn])}function qn(n,e){return n.hasOwnProperty(Ba)?n[Ba]:null}class mr{constructor(e,t,i){this.previousValue=e,this.currentValue=t,this.firstChange=i}isFirstChange(){return this.firstChange}}function Cn(){return Su}function Su(n){return n.type.prototype.ngOnChanges&&(n.setInput=vo),j0}function j0(){const n=gd(this),e=n?.current;if(e){const t=n.previous;if(t===Na)n.previous=e;else for(let i in e)t[i]=e[i];n.current=null,this.ngOnChanges(e)}}function vo(n,e,t,i){const r=this.declaredInputs[t],s=gd(n)||function Wc(n,e){return n[vc]=e}(n,{previous:Na,current:null}),o=s.current||(s.current={}),a=s.previous,c=a[r];o[r]=new mr(c&&c.currentValue,e,a===Na),n[i]=e}Cn.ngInherit=!0;const vc="__ngSimpleChanges__";function gd(n){return n[vc]||null}const Nn=function(n,e,t){},vd="svg";function Zt(n){for(;Array.isArray(n);)n=n[Nr];return n}function Jh(n,e){return Zt(e[n])}function Xs(n,e){return Zt(e[n.index])}function Ha(n,e){return n.data[e]}function yc(n,e){return n[e]}function Os(n,e){const t=e[n];return go(t)?t:t[Nr]}function bd(n){return 64==(64&n[Sn])}function h(n,e){return null==e?null:n[e]}function f(n){n[gc]=0}function _(n,e){n[Ks]+=e;let t=n,i=n[Zi];for(;null!==i&&(1===e&&1===t[Ks]||-1===e&&0===t[Ks]);)i[Ks]+=e,t=i,i=i[Zi]}const b={lFrame:es(null),bindingsEnabled:!0};function U(){return b.bindingsEnabled}function C(){return b.lFrame.lView}function B(){return b.lFrame.tView}function R(n){return b.lFrame.contextLView=n,n[Ji]}function V(n){return b.lFrame.contextLView=null,n}function L(){let n=$();for(;null!==n&&64===n.type;)n=n.parent;return n}function $(){return b.lFrame.currentTNode}function Q(n,e){const t=b.lFrame;t.currentTNode=n,t.isParent=e}function te(){return b.lFrame.isParent}function Se(){b.lFrame.isParent=!1}function ee(){const n=b.lFrame;let e=n.bindingRootIndex;return-1===e&&(e=n.bindingRootIndex=n.tView.bindingStartIndex),e}function be(){return b.lFrame.bindingIndex++}function ce(n){const e=b.lFrame,t=e.bindingIndex;return e.bindingIndex=e.bindingIndex+n,t}function Ie(n,e){const t=b.lFrame;t.bindingIndex=t.bindingRootIndex=n,Nt(e)}function Nt(n){b.lFrame.currentDirectiveIndex=n}function Lt(n){const e=b.lFrame.currentDirectiveIndex;return-1===e?null:n[e]}function Rn(){return b.lFrame.currentQueryIndex}function Y(n){b.lFrame.currentQueryIndex=n}function ui(n){const e=n[xt];return 2===e.type?e.declTNode:1===e.type?n[Br]:null}function oi(n,e,t){if(t&tn.SkipSelf){let r=e,s=n;for(;!(r=r.parent,null!==r||t&tn.Host||(r=ui(s),null===r||(s=s[Ir],10&r.type))););if(null===r)return!1;e=r,n=s}const i=b.lFrame=ln();return i.currentTNode=e,i.lView=n,!0}function Fi(n){const e=ln(),t=n[xt];b.lFrame=e,e.currentTNode=t.firstChild,e.lView=n,e.tView=t,e.contextLView=n,e.bindingIndex=t.bindingStartIndex,e.inI18n=!1}function ln(){const n=b.lFrame,e=null===n?null:n.child;return null===e?es(n):e}function es(n){const e={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:n,child:null,inI18n:!1};return null!==n&&(n.child=e),e}function vs(){const n=b.lFrame;return b.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const Ls=vs;function Kn(){const n=vs();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function ii(){return b.lFrame.selectedIndex}function gr(n){b.lFrame.selectedIndex=n}function an(){const n=b.lFrame;return Ha(n.tView,n.selectedIndex)}function $i(){b.lFrame.currentNamespace=vd}function Xo(){!function W0(){b.lFrame.currentNamespace=null}()}function Ro(n,e){for(let t=e.directiveStart,i=e.directiveEnd;t=i)break}else e[c]<0&&(n[gc]+=65536),(a>11>16&&(3&n[Sn])===e){n[Sn]+=2048,Nn(4,a,s);try{s.call(a)}finally{Nn(5,a,s)}}}else{Nn(4,a,s);try{s.call(a)}finally{Nn(5,a,s)}}}const va=-1;class Qh{constructor(e,t,i){this.factory=e,this.resolving=!1,this.canSeeViewProviders=t,this.injectImpl=i}}function jp(n,e,t){let i=0;for(;ie){o=s-1;break}}}for(;s>16}(n),i=e;for(;t>0;)i=i[Ir],t--;return i}let Ua=!0;function Mu(n){const e=Ua;return Ua=n,e}const Zo=255,Ab=5;let kb=0;const za={};function Ga(n,e){const t=Ib(n,e);if(-1!==t)return t;const i=e[xt];i.firstCreatePass&&(n.injectorIndex=e.length,qp(i.data,n),qp(e,null),qp(i.blueprint,null));const r=Du(n,e),s=n.injectorIndex;if(ef(r)){const o=Wp(r),a=$p(r,e),c=a[xt].data;for(let u=0;u<8;u++)e[s+u]=a[o+u]|c[o+u]}return e[s+8]=r,s}function qp(n,e){n.push(0,0,0,0,0,0,0,0,e)}function Ib(n,e){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===e[n.injectorIndex+8]?-1:n.injectorIndex}function Du(n,e){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let t=0,i=null,r=e;for(;null!==r;){if(i=Au(r),null===i)return va;if(t++,r=r[Ir],-1!==i.injectorIndex)return i.injectorIndex|t<<16}return va}function q0(n,e,t){!function tf(n,e,t){let i;"string"==typeof t?i=t.charCodeAt(0)||0:t.hasOwnProperty(pr)&&(i=t[pr]),null==i&&(i=t[pr]=kb++);const r=i&Zo;e.data[n+(r>>Ab)]|=1<=0?e&Zo:CE:e}(t);if("function"==typeof s){if(!oi(e,n,i))return i&tn.Host?ys(r,0,i):Kp(e,t,i,r);try{const o=s(i);if(null!=o||i&tn.Optional)return o;gu()}finally{Ls()}}else if("number"==typeof s){let o=null,a=Ib(n,e),c=va,u=i&tn.Host?e[Jr][Br]:null;for((-1===a||i&tn.SkipSelf)&&(c=-1===a?Du(n,e):e[a+8],c!==va&&Yp(i,!1)?(o=e[xt],a=Wp(c),e=$p(c,e)):a=-1);-1!==a;){const p=e[xt];if(Zs(s,a,p.data)){const g=Y0(a,e,t,o,i,u);if(g!==za)return g}c=e[a+8],c!==va&&Yp(i,e[xt].data[a+8]===u)&&Zs(s,a,e)?(o=p,a=Wp(c),e=$p(c,e)):a=-1}}return r}function Y0(n,e,t,i,r,s){const o=e[xt],a=o.data[n+8],p=Ed(a,o,t,null==i?_s(a)&&Ua:i!=o&&0!=(3&a.type),r&tn.Host&&s===a);return null!==p?Jo(e,o,p,a):za}function Ed(n,e,t,i,r){const s=n.providerIndexes,o=e.data,a=1048575&s,c=n.directiveStart,p=s>>20,v=r?a+p:n.directiveEnd;for(let y=i?a:a+p;y=c&&x.type===t)return y}if(r){const y=o[c];if(y&&Fo(y)&&y.type===t)return c}return null}function Jo(n,e,t,i){let r=n[t];const s=e.data;if(function wE(n){return n instanceof Qh}(r)){const o=r;o.resolving&&function Ap(n,e){const t=e?`. Dependency path: ${e.join(" > ")} > ${n}`:"";throw new Ue(-200,`Circular dependency in DI detected for ${n}${t}`)}(function wi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():wn(n)}(s[t]));const a=Mu(o.canSeeViewProviders);o.resolving=!0;const c=o.injectImpl?ho(o.injectImpl):null;oi(n,i,tn.Default);try{r=n[t]=o.factory(void 0,s,n,i),e.firstCreatePass&&t>=i.directiveStart&&function qc(n,e,t){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=e.type.prototype;if(i){const o=Su(e);(t.preOrderHooks||(t.preOrderHooks=[])).push(n,o),(t.preOrderCheckHooks||(t.preOrderCheckHooks=[])).push(n,o)}r&&(t.preOrderHooks||(t.preOrderHooks=[])).push(0-n,r),s&&((t.preOrderHooks||(t.preOrderHooks=[])).push(n,s),(t.preOrderCheckHooks||(t.preOrderCheckHooks=[])).push(n,s))}(t,s[t],e)}finally{null!==c&&ho(c),Mu(a),o.resolving=!1,Ls()}}return r}function Zs(n,e,t){return!!(t[e+(n>>Ab)]&1<{const e=n.prototype.constructor,t=e[Ba]||nf(e),i=Object.prototype;let r=Object.getPrototypeOf(n.prototype).constructor;for(;r&&r!==i;){const s=r[Ba]||nf(r);if(s&&s!==t)return s;r=Object.getPrototypeOf(r)}return s=>new s})}function nf(n){return Hh(n)?()=>{const e=nf(en(n));return e&&e()}:qn(n)}function Au(n){const e=n[xt],t=e.type;return 2===t?e.declTNode:1===t?n[Br]:null}function Kc(n){return function Fb(n,e){if("class"===e)return n.classes;if("style"===e)return n.styles;const t=n.attrs;if(t){const i=t.length;let r=0;for(;r{const i=function X0(n){return function(...t){if(n){const i=n(...t);for(const r in i)this[r]=i[r]}}}(e);function r(...s){if(this instanceof r)return i.apply(this,s),this;const o=new r(...s);return a.annotation=o,a;function a(c,u,p){const g=c.hasOwnProperty(Iu)?c[Iu]:Object.defineProperty(c,Iu,{value:[]})[Iu];for(;g.length<=p;)g.push(null);return(g[p]=g[p]||[]).push(o),c}}return t&&(r.prototype=Object.create(t.prototype)),r.prototype.ngMetadataName=n,r.annotationCls=r,r})}class Ze{constructor(e,t){this._desc=e,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof t?this.__NG_ELEMENT_ID__=t:void 0!==t&&(this.\u0275prov=Je({token:this,providedIn:t.providedIn||"root",factory:t.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}function Yc(n,e){n.forEach(t=>Array.isArray(t)?Yc(t,e):e(t))}function J0(n,e,t){e>=n.length?n.push(t):n.splice(e,0,t)}function Ru(n,e){return e>=n.length-1?n.pop():n.splice(e,1)[0]}function sf(n,e){const t=[];for(let i=0;i=0?n[1|i]=t:(i=~i,function RE(n,e,t,i){let r=n.length;if(r==e)n.push(t,i);else if(1===r)n.push(i,n[0]),n[0]=t;else{for(r--,n.push(n[r-1],n[r]);r>e;)n[r]=n[r-2],r--;n[e]=t,n[e+1]=i}}(n,i,e,t)),i}function Zp(n,e){const t=Pu(n,e);if(t>=0)return n[1|t]}function Pu(n,e){return function Qo(n,e,t){let i=0,r=n.length>>t;for(;r!==i;){const s=i+(r-i>>1),o=n[s<e?r=s:i=s+1}return~(r<({token:n})),-1),ba=jc(Rl("Optional"),8),Pl=jc(Rl("SkipSelf"),4);var Js=(()=>((Js=Js||{})[Js.Important=1]="Important",Js[Js.DashCase=2]="DashCase",Js))();const nm=new Map;let WE=0;const Ll="__ngContext__";function Ot(n,e){go(e)?(n[Ll]=e[ma],function $E(n){nm.set(n[ma],n)}(e)):n[Ll]=e}let sm;function h_(n,e){return sm(n,e)}function ff(n){const e=n[Zi];return Yo(e)?e[Zi]:e}function pf(n){return om(n[Va])}function f_(n){return om(n[si])}function om(n){for(;null!==n&&!Yo(n);)n=n[si];return n}function Lu(n,e,t,i,r){if(null!=i){let s,o=!1;Yo(i)?s=i:go(i)&&(o=!0,i=i[Nr]);const a=Zt(i);0===n&&null!==t?null==r?qa(e,t,a):Vl(e,t,a,r||null,!0):1===n&&null!==t?Vl(e,t,a,r||null,!0):2===n?function um(n,e,t){const i=cm(n,e);i&&function tM(n,e,t,i){n.removeChild(e,t,i)}(n,i,e,t)}(e,a,o):3===n&&e.destroyNode(a),null!=s&&function sM(n,e,t,i,r){const s=t[Fl];s!==Zt(t)&&Lu(e,n,i,s,r);for(let a=gs;a0&&(n[t-1][si]=i[si]);const s=Ru(n,gs+e);!function ZE(n,e){Bu(n,e,e[Hn],2,null,null),e[Nr]=null,e[Br]=null}(i[xt],i);const o=s[Qr];null!==o&&o.detachView(s[xt]),i[Zi]=null,i[si]=null,i[Sn]&=-65}return i}function m_(n,e){if(!(128&e[Sn])){const t=e[Hn];t.destroyNode&&Bu(n,e,t,3,null,null),function eM(n){let e=n[Va];if(!e)return Ad(n[xt],n);for(;e;){let t=null;if(go(e))t=e[Va];else{const i=e[gs];i&&(t=i)}if(!t){for(;e&&!e[si]&&e!==n;)go(e)&&Ad(e[xt],e),e=e[Zi];null===e&&(e=n),go(e)&&Ad(e[xt],e),t=e&&e[si]}e=t}}(e)}}function Ad(n,e){if(!(128&e[Sn])){e[Sn]&=-65,e[Sn]|=128,function sx(n,e){let t;if(null!=n&&null!=(t=n.destroyHooks))for(let i=0;i=0?i[r=o]():i[r=-o].unsubscribe(),s+=2}else{const o=i[r=t[s+1]];t[s].call(o)}if(null!==i){for(let s=r+1;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ko.None||s===Ko.Emulated)return null}return Xs(i,t)}}(n,e.parent,t)}function Vl(n,e,t,i,r){n.insertBefore(e,t,i,r)}function qa(n,e,t){n.appendChild(e,t)}function Hl(n,e,t,i,r){null!==i?Vl(n,e,t,i,r):qa(n,e,t)}function cm(n,e){return n.parentNode(e)}function ox(n,e,t){return cx(n,e,t)}let v_,fm,pm,cx=function ax(n,e,t){return 40&n.type?Xs(n,t):null};function lm(n,e,t,i){const r=__(n,i,e),s=e[Hn],a=ox(i.parent||e[Br],i,e);if(null!=r)if(Array.isArray(t))for(let c=0;cn,createScript:n=>n,createScriptURL:n=>n})}catch{}return fm}()?.createHTML(n)||n}class kd{constructor(e){this.changingThisBreaksApplicationSecurity=e}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${mu})`}}class dM extends kd{getTypeName(){return"HTML"}}class uM extends kd{getTypeName(){return"Style"}}class hM extends kd{getTypeName(){return"Script"}}class fM extends kd{getTypeName(){return"URL"}}class pM extends kd{getTypeName(){return"ResourceURL"}}function ta(n){return n instanceof kd?n.changingThisBreaksApplicationSecurity:n}function Ec(n,e){const t=function mM(n){return n instanceof kd&&n.getTypeName()||null}(n);if(null!=t&&t!==e){if("ResourceURL"===t&&"URL"===e)return!0;throw new Error(`Required a safe ${e}, got a ${t} (see ${mu})`)}return t===e}class xM{constructor(e){this.inertDocumentHelper=e}getInertBodyElement(e){e=""+e;try{const t=(new window.DOMParser).parseFromString(Vu(e),"text/html").body;return null===t?this.inertDocumentHelper.getInertBodyElement(e):(t.removeChild(t.firstChild),t)}catch{return null}}}class wM{constructor(e){this.defaultDoc=e,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert")}getInertBodyElement(e){const t=this.inertDocument.createElement("template");return t.innerHTML=Vu(e),t}}const w_=/^(?:(?:https?|mailto|data|ftp|tel|file|sms):|[^&:/?#]*(?:[/?#]|$))/gi;function _f(n){return(n=String(n)).match(w_)?n:"unsafe:"+n}function Qc(n){const e={};for(const t of n.split(","))e[t]=!0;return e}function vf(...n){const e={};for(const t of n)for(const i in t)t.hasOwnProperty(i)&&(e[i]=!0);return e}const yx=Qc("area,br,col,hr,img,wbr"),bx=Qc("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),xx=Qc("rp,rt"),_m=vf(yx,vf(bx,Qc("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")),vf(xx,Qc("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")),vf(xx,bx)),S_=Qc("background,cite,href,itemtype,longdesc,poster,src,xlink:href"),wx=vf(S_,Qc("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"),Qc("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")),EM=Qc("script,style,template");class MM{constructor(){this.sanitizedSomething=!1,this.buf=[]}sanitizeChildren(e){let t=e.firstChild,i=!0;for(;t;)if(t.nodeType===Node.ELEMENT_NODE?i=this.startElement(t):t.nodeType===Node.TEXT_NODE?this.chars(t.nodeValue):this.sanitizedSomething=!0,i&&t.firstChild)t=t.firstChild;else for(;t;){t.nodeType===Node.ELEMENT_NODE&&this.endElement(t);let r=this.checkClobberedElement(t,t.nextSibling);if(r){t=r;break}t=this.checkClobberedElement(t,t.parentNode)}return this.buf.join("")}startElement(e){const t=e.nodeName.toLowerCase();if(!_m.hasOwnProperty(t))return this.sanitizedSomething=!0,!EM.hasOwnProperty(t);this.buf.push("<"),this.buf.push(t);const i=e.attributes;for(let r=0;r"),!0}endElement(e){const t=e.nodeName.toLowerCase();_m.hasOwnProperty(t)&&!yx.hasOwnProperty(t)&&(this.buf.push(""))}chars(e){this.buf.push(Sx(e))}checkClobberedElement(e,t){if(t&&(e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY)===Node.DOCUMENT_POSITION_CONTAINED_BY)throw new Error(`Failed to sanitize html because the element is clobbered: ${e.outerHTML}`);return t}}const CM=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,DM=/([^\#-~ |!])/g;function Sx(n){return n.replace(/&/g,"&").replace(CM,function(e){return"&#"+(1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320)+65536)+";"}).replace(DM,function(e){return"&#"+e.charCodeAt(0)+";"}).replace(//g,">")}let vm;function Ex(n,e){let t=null;try{vm=vm||function vx(n){const e=new wM(n);return function SM(){try{return!!(new window.DOMParser).parseFromString(Vu(""),"text/html")}catch{return!1}}()?new xM(e):e}(n);let i=e?String(e):"";t=vm.getInertBodyElement(i);let r=5,s=i;do{if(0===r)throw new Error("Failed to sanitize html because the input is unstable");r--,i=s,s=t.innerHTML,t=vm.getInertBodyElement(i)}while(i!==s);return Vu((new MM).sanitizeChildren(M_(t)||t))}finally{if(t){const i=M_(t)||t;for(;i.firstChild;)i.removeChild(i.firstChild)}}}function M_(n){return"content"in n&&function TM(n){return n.nodeType===Node.ELEMENT_NODE&&"TEMPLATE"===n.nodeName}(n)?n.content:null}var Ri=(()=>((Ri=Ri||{})[Ri.NONE=0]="NONE",Ri[Ri.HTML=1]="HTML",Ri[Ri.STYLE=2]="STYLE",Ri[Ri.SCRIPT=3]="SCRIPT",Ri[Ri.URL=4]="URL",Ri[Ri.RESOURCE_URL=5]="RESOURCE_URL",Ri))();function Id(n){const e=function yf(){const n=C();return n&&n[fd]}();return e?e.sanitize(Ri.URL,n)||"":Ec(n,"URL")?ta(n):_f(wn(n))}const ym=new Ze("ENVIRONMENT_INITIALIZER"),Ax=new Ze("INJECTOR",-1),kx=new Ze("INJECTOR_DEF_TYPES");class Ix{get(e,t=pc){if(t===pc){const i=new Error(`NullInjectorError: No provider for ${ki(e)}!`);throw i.name="NullInjectorError",i}return t}}function Fx(n){return{\u0275providers:n}}function RM(...n){return{\u0275providers:Rx(0,n),\u0275fromNgModule:!0}}function Rx(n,...e){const t=[],i=new Set;let r;return Yc(e,s=>{const o=s;D_(o,t,[],i)&&(r||(r=[]),r.push(o))}),void 0!==r&&Px(r,t),t}function Px(n,e){for(let t=0;t{e.push(s)})}}function D_(n,e,t,i){if(!(n=en(n)))return!1;let r=null,s=Uh(n);const o=!s&&Ei(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const c=n.ngModule;if(s=Uh(c),!s)return!1;r=c}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const c="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const u of c)D_(u,e,t,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let u;i.add(r);try{Yc(s.imports,p=>{D_(p,e,t,i)&&(u||(u=[]),u.push(p))})}finally{}void 0!==u&&Px(u,e)}if(!a){const u=qn(r)||(()=>new r);e.push({provide:r,useFactory:u,deps:Si},{provide:kx,useValue:r,multi:!0},{provide:ym,useValue:()=>xe(r),multi:!0})}const c=s.providers;null==c||a||Hu(c,p=>{e.push(p)})}}return r!==n&&void 0!==n.providers}function Hu(n,e){for(let t of n)pu(t)&&(t=t.\u0275providers),Array.isArray(t)?Hu(t,e):e(t)}const PM=Vi({provide:String,useValue:Vi});function bm(n){return null!==n&&"object"==typeof n&&PM in n}function Ul(n){return"function"==typeof n}const wm=new Ze("Set Injector scope."),bf={},OM={};let A_;function Sm(){return void 0===A_&&(A_=new Ix),A_}class na{}class xf extends na{get destroyed(){return this._destroyed}constructor(e,t,i,r){super(),this.parent=t,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,R_(e,o=>this.processProvider(o)),this.records.set(Ax,Uu(void 0,this)),r.has("environment")&&this.records.set(na,Uu(void 0,this));const s=this.records.get(wm);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(kx.multi,Si,tn.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();for(const e of this._onDestroyHooks)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),this._onDestroyHooks.length=0}}onDestroy(e){this._onDestroyHooks.push(e)}runInContext(e){this.assertNotDestroyed();const t=hr(this),i=ho(void 0);try{return e()}finally{hr(t),ho(i)}}get(e,t=pc,i=tn.Default){this.assertNotDestroyed(),i=bu(i);const r=hr(this),s=ho(void 0);try{if(!(i&tn.SkipSelf)){let a=this.records.get(e);if(void 0===a){const c=function VM(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ze}(e)&&_u(e);a=c&&this.injectableDefInScope(c)?Uu(k_(e),bf):null,this.records.set(e,a)}if(null!=a)return this.hydrate(e,a)}return(i&tn.Self?Sm():this.parent).get(e,t=i&tn.Optional&&t===pc?null:t)}catch(o){if("NullInjectorError"===o.name){if((o[hd]=o[hd]||[]).unshift(ki(e)),r)throw o;return function H0(n,e,t,i){const r=n[hd];throw e[Wh]&&r.unshift(e[Wh]),n.message=function U0(n,e,t,i=null){n=n&&"\n"===n.charAt(0)&&n.charAt(1)==Op?n.slice(2):n;let r=ki(e);if(Array.isArray(e))r=e.map(ki).join(" -> ");else if("object"==typeof e){let s=[];for(let o in e)if(e.hasOwnProperty(o)){let a=e[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):ki(a)))}r=`{${s.join(", ")}}`}return`${t}${i?"("+i+")":""}[${r}]: ${n.replace(jh,"\n ")}`}("\n"+n.message,r,t,i),n[Gh]=r,n[hd]=null,n}(o,e,"R3InjectorError",this.source)}throw o}finally{ho(s),hr(r)}}resolveInjectorInitializers(){const e=hr(this),t=ho(void 0);try{const i=this.get(ym.multi,Si,tn.Self);for(const r of i)r()}finally{hr(e),ho(t)}}toString(){const e=[],t=this.records;for(const i of t.keys())e.push(ki(i));return`R3Injector[${e.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new Ue(205,!1)}processProvider(e){let t=Ul(e=en(e))?e:en(e&&e.provide);const i=function I_(n){return bm(n)?Uu(void 0,n.useValue):Uu(F_(n),bf)}(e);if(Ul(e)||!0!==e.multi)this.records.get(t);else{let r=this.records.get(t);r||(r=Uu(void 0,bf,!0),r.factory=()=>Ut(r.multi),this.records.set(t,r)),t=e,r.multi.push(e)}this.records.set(t,i)}hydrate(e,t){return t.value===bf&&(t.value=OM,t.value=t.factory()),"object"==typeof t.value&&t.value&&function BM(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(t.value)&&this._ngOnDestroyHooks.add(t.value),t.value}injectableDefInScope(e){if(!e.providedIn)return!1;const t=en(e.providedIn);return"string"==typeof t?"any"===t||this.scopes.has(t):this.injectorDefTypes.has(t)}}function k_(n){const e=_u(n),t=null!==e?e.factory:qn(n);if(null!==t)return t;if(n instanceof Ze)throw new Ue(204,!1);if(n instanceof Function)return function LM(n){const e=n.length;if(e>0)throw sf(e,"?"),new Ue(204,!1);const t=function Ip(n){const e=n&&(n[Tl]||n[zh]);return e?(function Fp(n){if(n.hasOwnProperty("name"))return n.name;(""+n).match(/^function\s*([^\s(]+)/)}(n),e):null}(n);return null!==t?()=>t.factory(n):()=>new n}(n);throw new Ue(204,!1)}function F_(n,e,t){let i;if(Ul(n)){const r=en(n);return qn(r)||k_(r)}if(bm(n))i=()=>en(n.useValue);else if(function xm(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Ut(n.deps||[]));else if(function T_(n){return!(!n||!n.useExisting)}(n))i=()=>xe(en(n.useExisting));else{const r=en(n&&(n.useClass||n.provide));if(!function NM(n){return!!n.deps}(n))return qn(r)||k_(r);i=()=>new r(...Ut(n.deps))}return i}function Uu(n,e,t=!1){return{factory:n,value:e,multi:t?[]:void 0}}function R_(n,e){for(const t of n)Array.isArray(t)?R_(t,e):t&&pu(t)?R_(t.\u0275providers,e):e(t)}class HM{}class Lx{}class zM{resolveComponentFactory(e){throw function UM(n){const e=Error(`No component factory found for ${ki(n)}. Did you add it to @NgModule.entryComponents?`);return e.ngComponent=n,e}(e)}}let Fd=(()=>{class n{}return n.NULL=new zM,n})();function Ka(){return zu(L(),C())}function zu(n,e){return new _n(Xs(n,e))}let _n=(()=>{class n{constructor(t){this.nativeElement=t}}return n.__NG_ELEMENT_ID__=Ka,n})();function Rd(n){return n instanceof _n?n.nativeElement:n}class yn{}let el=(()=>{class n{}return n.__NG_ELEMENT_ID__=()=>function Oo(){const n=C(),t=Os(L().index,n);return(go(t)?t:n)[Hn]}(),n})(),Rr=(()=>{class n{}return n.\u0275prov=Je({token:n,providedIn:"root",factory:()=>null}),n})();class Pd{constructor(e){this.full=e,this.major=e.split(".")[0],this.minor=e.split(".")[1],this.patch=e.split(".").slice(2).join(".")}}const zl=new Pd("15.2.1"),P_={},O_="ngOriginalError";function L_(n){return n[O_]}class tl{constructor(){this._console=console}handleError(e){const t=this._findOriginalError(e);this._console.error("ERROR",e),t&&this._console.error("ORIGINAL ERROR",t)}_findOriginalError(e){let t=e&&L_(e);for(;t&&L_(t);)t=L_(t);return t||null}}function il(n){return n instanceof Function?n():n}function Gu(n,e,t){let i=n.length;for(;;){const r=n.indexOf(e,t);if(-1===r)return r;if(0===r||n.charCodeAt(r-1)<=32){const s=e.length;if(r+s===i||n.charCodeAt(r+s)<=32)return r}t=r+1}}const Mm="ng-template";function KM(n,e,t){let i=0;for(;is?"":r[g+1].toLowerCase();const y=8&i?v:null;if(y&&-1!==Gu(y,u,0)||2&i&&u!==v){if(eo(i))return!1;o=!0}}}}else{if(!o&&!eo(i)&&!eo(c))return!1;if(o&&eo(c))continue;o=!1,i=c|1&i}}return eo(i)||o}function eo(n){return 0==(1&n)}function YM(n,e,t,i){if(null===e)return-1;let r=0;if(i||!t){let s=!1;for(;r-1)for(t++;t0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!eo(o)&&(e+=Mc(s,r),r=""),i=o,s=s||!eo(i);t++}return""!==r&&(e+=Mc(s,r)),e}const Dn={};function Le(n){Pi(B(),C(),ii()+n,!1)}function Pi(n,e,t,i){if(!i)if(3==(3&e[Sn])){const s=n.preOrderCheckHooks;null!==s&&wd(e,s,t)}else{const s=n.preOrderHooks;null!==s&&Bi(e,s,0,t)}gr(t)}function qx(n,e=null,t=null,i){const r=Kx(n,e,t,i);return r.resolveInjectorInitializers(),r}function Kx(n,e=null,t=null,i,r=new Set){const s=[t||Si,RM(n)];return i=i||("object"==typeof n?void 0:ki(n)),new xf(s,e||Sm(),i||null,r)}let ts=(()=>{class n{static create(t,i){if(Array.isArray(t))return qx({name:""},i,t,"");{const r=t.name??"";return qx({name:r},t.parent,t.providers,r)}}}return n.THROW_IF_NOT_FOUND=pc,n.NULL=new Ix,n.\u0275prov=Je({token:n,providedIn:"any",factory:()=>xe(Ax)}),n.__NG_ELEMENT_ID__=-1,n})();function ie(n,e=tn.Default){const t=C();return null===t?xe(n,e):K0(L(),t,en(n),e)}function Gl(){throw new Error("invalid")}function o1(n,e){const t=n.contentQueries;if(null!==t)for(let i=0;inn&&Pi(n,e,nn,!1),Nn(o?2:0,r),t(i,r)}finally{gr(s),Nn(o?3:1,r)}}function $_(n,e,t){if(Vr(e)){const r=e.directiveEnd;for(let s=e.directiveStart;s0;){const t=n[--e];if("number"==typeof t&&t<0)return t}return 0})(o)!=a&&o.push(a),o.push(t,i,s)}}(n,e,i,wf(n,t,r.hostVars,Dn),r)}function Cc(n,e,t,i,r,s){const o=Xs(n,e);!function ev(n,e,t,i,r,s,o){if(null==s)n.removeAttribute(e,r,t);else{const a=null==o?wn(s):o(s,i||"",r);n.setAttribute(e,r,a,t)}}(e[Hn],o,s,n.value,t,i,r)}function wC(n,e,t,i,r,s){const o=s[e];if(null!==o){const a=i.setInput;for(let c=0;c0&&iv(t)}}function iv(n){for(let i=pf(n);null!==i;i=f_(i))for(let r=gs;r0&&iv(s)}const t=n[xt].components;if(null!==t)for(let i=0;i0&&iv(r)}}function MC(n,e){const t=Os(e,n),i=t[xt];(function y1(n,e){for(let t=e.length;t-1&&(mf(e,i),Ru(t,i))}this._attachedToViewContainer=!1}m_(this._lView[xt],this._lView)}onDestroy(e){u1(this._lView[xt],this._lView,null,e)}markForCheck(){rv(this._cdRefInjectingView||this._lView)}detach(){this._lView[Sn]&=-65}reattach(){this._lView[Sn]|=64}detectChanges(){Rm(this._lView[xt],this._lView,this.context)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new Ue(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,function QE(n,e){Bu(n,e,e[Hn],2,null,null)}(this._lView[xt],this._lView)}attachToAppRef(e){if(this._attachedToViewContainer)throw new Ue(902,!1);this._appRef=e}}class CC extends Ef{constructor(e){super(e),this._view=e}detectChanges(){const e=this._view;Rm(e[xt],e,e[Ji],!1)}checkNoChanges(){}get context(){return null}}class M1 extends Fd{constructor(e){super(),this.ngModule=e}resolveComponentFactory(e){const t=Ei(e);return new Mf(t,this.ngModule)}}function C1(n){const e=[];for(let t in n)n.hasOwnProperty(t)&&e.push({propName:n[t],templateName:t});return e}class TC{constructor(e,t){this.injector=e,this.parentInjector=t}get(e,t,i){i=bu(i);const r=this.injector.get(e,P_,i);return r!==P_||t===P_?r:this.parentInjector.get(e,t,i)}}class Mf extends Lx{get inputs(){return C1(this.componentDef.inputs)}get outputs(){return C1(this.componentDef.outputs)}constructor(e,t){super(),this.componentDef=e,this.ngModule=t,this.componentType=e.type,this.selector=function zx(n){return n.map(Un).join(",")}(e.selectors),this.ngContentSelectors=e.ngContentSelectors?e.ngContentSelectors:[],this.isBoundToModule=!!t}create(e,t,i,r){let s=(r=r||this.ngModule)instanceof na?r:r?.injector;s&&null!==this.componentDef.getStandaloneInjector&&(s=this.componentDef.getStandaloneInjector(s)||s);const o=s?new TC(e,s):e,a=o.get(yn,null);if(null===a)throw new Ue(407,!1);const c=o.get(Rr,null),u=a.createRenderer(null,this.componentDef),p=this.componentDef.selectors[0][0]||"div",g=i?function hC(n,e,t){return n.selectRootElement(e,t===Ko.ShadowDom)}(u,i,this.componentDef.encapsulation):am(u,p,function DC(n){const e=n.toLowerCase();return"svg"===e?vd:"math"===e?"math":null}(p)),v=this.componentDef.onPush?288:272,y=Y_(0,null,null,1,0,null,null,null,null,null),x=Am(null,y,null,v,null,null,a,u,c,o,null);let T,N;Fi(x);try{const k=this.componentDef;let A,H=null;k.findHostDirectiveDefs?(A=[],H=new Map,k.findHostDirectiveDefs(k,A,H),A.push(k)):A=[k];const G=function kC(n,e){const t=n[xt],i=nn;return n[i]=e,Wu(t,i,2,"#host",null)}(x,g),X=function IC(n,e,t,i,r,s,o,a){const c=r[xt];!function FC(n,e,t,i){for(const r of n)e.mergedAttrs=Sd(e.mergedAttrs,r.hostAttrs);null!==e.mergedAttrs&&(Pm(e,e.mergedAttrs,!0),null!==t&&px(i,t,e))}(i,n,e,o);const u=s.createRenderer(e,t),p=Am(r,d1(t),null,t.onPush?32:16,r[n.index],n,s,u,a||null,null,null);return c.firstCreatePass&&J_(c,n,i.length-1),Fm(r,p),r[n.index]=p}(G,g,k,A,x,a,u);N=Ha(y,nn),g&&function m(n,e,t,i){if(i)jp(n,t,["ng-version",zl.full]);else{const{attrs:r,classes:s}=function wa(n){const e=[],t=[];let i=1,r=2;for(;i0&&fx(n,t,s.join(" "))}}(u,k,g,i),void 0!==t&&function S(n,e,t){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=e+=r.hostVars,r.hostAttrs=Sd(r.hostAttrs,t=Sd(t,r.hostAttrs))}}(i)}function me(n){return n===Na?{}:n===Si?[]:n}function Ee(n,e){const t=n.viewQuery;n.viewQuery=t?(i,r)=>{e(i,r),t(i,r)}:e}function qe(n,e){const t=n.contentQueries;n.contentQueries=t?(i,r,s)=>{e(i,r,s),t(i,r,s)}:e}function Ye(n,e){const t=n.hostBindings;n.hostBindings=t?(i,r)=>{e(i,r),t(i,r)}:e}function to(n){return!!Xa(n)&&(Array.isArray(n)||!(n instanceof Map)&&Symbol.iterator in n)}function Xa(n){return null!==n&&("function"==typeof n||"object"==typeof n)}function jl(n,e,t){return n[e]=t}function Vo(n,e,t){return!Object.is(n[e],t)&&(n[e]=t,!0)}function Cf(n,e,t,i){const r=Vo(n,e,t);return Vo(n,e+1,i)||r}function Di(n,e,t,i){const r=C();return Vo(r,be(),e)&&(B(),Cc(an(),r,n,e,t,i)),Di}function Nm(n,e,t,i){return Vo(n,be(),t)?e+wn(t)+i:Dn}function mt(n,e,t,i,r,s,o,a){const c=C(),u=B(),p=n+nn,g=u.firstCreatePass?function QV(n,e,t,i,r,s,o,a,c){const u=e.consts,p=Wu(e,n,4,o||null,h(u,a));X_(e,t,p,h(u,c)),Ro(e,p);const g=p.tViews=Y_(2,p,i,r,s,e.directiveRegistry,e.pipeRegistry,null,e.schemas,u);return null!==e.queries&&(e.queries.template(e,p),g.queries=e.queries.embeddedTView(p)),p}(p,u,c,e,t,i,r,s,o):u.data[p];Q(g,!1);const v=c[Hn].createComment("");lm(u,c,v,g),Ot(v,c),Fm(c,c[p]=v1(v,c,v,g)),ga(g)&&q_(u,c,g),null!=o&&K_(c,g,a)}function Tc(n){return yc(function Ae(){return b.lFrame.contextLView}(),nn+n)}function $e(n,e,t){const i=C();return Vo(i,be(),e)&&ra(B(),an(),i,n,e,i[Hn],t,!1),$e}function RC(n,e,t,i,r){const o=r?"class":"style";sv(n,t,e.inputs[o],o,i)}function ke(n,e,t,i){const r=C(),s=B(),o=nn+n,a=r[Hn],c=s.firstCreatePass?function tH(n,e,t,i,r,s){const o=e.consts,c=Wu(e,n,2,i,h(o,r));return X_(e,t,c,h(o,s)),null!==c.attrs&&Pm(c,c.attrs,!1),null!==c.mergedAttrs&&Pm(c,c.mergedAttrs,!0),null!==e.queries&&e.queries.elementStart(e,c),c}(o,s,r,e,t,i):s.data[o],u=r[o]=am(a,e,function _a(){return b.lFrame.currentNamespace}()),p=ga(c);return Q(c,!0),px(a,u,c),32!=(32&c.flags)&&lm(s,r,u,c),0===function D(){return b.lFrame.elementDepthCount}()&&Ot(u,r),function F(){b.lFrame.elementDepthCount++}(),p&&(q_(s,r,c),$_(s,c,r)),null!==i&&K_(r,c),ke}function Ne(){let n=L();te()?Se():(n=n.parent,Q(n,!1));const e=n;!function P(){b.lFrame.elementDepthCount--}();const t=B();return t.firstCreatePass&&(Ro(t,n),Vr(n)&&t.queries.elementEnd(n)),null!=e.classesWithoutHost&&function SE(n){return 0!=(8&n.flags)}(e)&&RC(t,e,C(),e.classesWithoutHost,!0),null!=e.stylesWithoutHost&&function EE(n){return 0!=(16&n.flags)}(e)&&RC(t,e,C(),e.stylesWithoutHost,!1),Ne}function qt(n,e,t,i){return ke(n,e,t,i),Ne(),qt}function av(n,e,t){const i=C(),r=B(),s=n+nn,o=r.firstCreatePass?function nH(n,e,t,i,r){const s=e.consts,o=h(s,i),a=Wu(e,n,8,"ng-container",o);return null!==o&&Pm(a,o,!0),X_(e,t,a,h(s,r)),null!==e.queries&&e.queries.elementStart(e,a),a}(s,r,i,e,t):r.data[s];Q(o,!0);const a=i[s]=i[Hn].createComment("");return lm(r,i,a,o),Ot(a,i),ga(o)&&(q_(r,i,o),$_(r,o,i)),null!=t&&K_(i,o),av}function cv(){let n=L();const e=B();return te()?Se():(n=n.parent,Q(n,!1)),e.firstCreatePass&&(Ro(e,n),Vr(n)&&e.queries.elementEnd(n)),cv}function Df(){return C()}function lv(n){return!!n&&"function"==typeof n.then}function kF(n){return!!n&&"function"==typeof n.subscribe}const PC=kF;function Gn(n,e,t,i){const r=C(),s=B(),o=L();return IF(s,r,r[Hn],o,n,e,i),Gn}function OC(n,e){const t=L(),i=C(),r=B();return IF(r,i,S1(Lt(r.data),t,i),t,n,e),OC}function IF(n,e,t,i,r,s,o){const a=ga(i),u=n.firstCreatePass&&w1(n),p=e[Ji],g=x1(e);let v=!0;if(3&i.type||o){const T=Xs(i,e),N=o?o(T):T,k=g.length,A=o?G=>o(Zt(G[i.index])):i.index;let H=null;if(!o&&a&&(H=function iH(n,e,t,i){const r=n.cleanup;if(null!=r)for(let s=0;sc?a[c]:null}"string"==typeof o&&(s+=2)}return null}(n,e,r,i.index)),null!==H)(H.__ngLastListenerFn__||H).__ngNextListenerFn__=s,H.__ngLastListenerFn__=s,v=!1;else{s=RF(i,e,p,s,!1);const G=t.listen(N,r,s);g.push(s,G),u&&u.push(r,A,k,k+1)}}else s=RF(i,e,p,s,!1);const y=i.outputs;let x;if(v&&null!==y&&(x=y[r])){const T=x.length;if(T)for(let N=0;N-1?Os(n.index,e):e);let c=FF(e,t,i,o),u=s.__ngNextListenerFn__;for(;u;)c=FF(e,t,u,o)&&c,u=u.__ngNextListenerFn__;return r&&!1===c&&(o.preventDefault(),o.returnValue=!1),c}}function Jt(n=1){return function Mr(n){return(b.lFrame.contextLView=function Qi(n,e){for(;n>0;)e=e[Ir],n--;return e}(n,b.lFrame.contextLView))[Ji]}(n)}function rH(n,e){let t=null;const i=function XM(n){const e=n.attrs;if(null!=e){const t=e.indexOf(5);if(!(1&t))return e[t+1]}return null}(n);for(let r=0;r>17&32767}function NC(n){return 2|n}function Tf(n){return(131068&n)>>2}function BC(n,e){return-131069&n|e<<2}function VC(n){return 1|n}function GF(n,e,t,i,r){const s=n[t+1],o=null===e;let a=i?$u(s):Tf(s),c=!1;for(;0!==a&&(!1===c||o);){const p=n[a+1];dH(n[a],e)&&(c=!0,n[a+1]=i?VC(p):NC(p)),a=i?$u(p):Tf(p)}c&&(n[t+1]=i?NC(s):VC(s))}function dH(n,e){return null===n||null==e||(Array.isArray(n)?n[1]:n)===e||!(!Array.isArray(n)||"string"!=typeof e)&&Pu(n,e)>=0}const Us={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function jF(n){return n.substring(Us.key,Us.keyEnd)}function WF(n,e){const t=Us.textEnd;return t===e?-1:(e=Us.keyEnd=function pH(n,e,t){for(;e32;)e++;return e}(n,Us.key=e,t),Wm(n,e,t))}function Wm(n,e,t){for(;e=0;t=WF(e,t))Ns(n,jF(e),!0)}function sl(n,e,t,i){const r=C(),s=B(),o=ce(2);s.firstUpdatePass&&ZF(s,n,o,i),e!==Dn&&Vo(r,o,e)&&QF(s,s.data[ii()],r,r[Hn],n,r[o+1]=function MH(n,e){return null==n||("string"==typeof e?n+=e:"object"==typeof n&&(n=ki(ta(n)))),n}(e,t),i,o)}function XF(n,e){return e>=n.expandoStartIndex}function ZF(n,e,t,i){const r=n.data;if(null===r[t+1]){const s=r[ii()],o=XF(n,t);tR(s,i)&&null===e&&!o&&(e=!1),e=function yH(n,e,t,i){const r=Lt(n);let s=i?e.residualClasses:e.residualStyles;if(null===r)0===(i?e.classBindings:e.styleBindings)&&(t=uv(t=HC(null,n,e,t,i),e.attrs,i),s=null);else{const o=e.directiveStylingLast;if(-1===o||n[o]!==r)if(t=HC(r,n,e,t,i),null===s){let c=function bH(n,e,t){const i=t?e.classBindings:e.styleBindings;if(0!==Tf(i))return n[$u(i)]}(n,e,i);void 0!==c&&Array.isArray(c)&&(c=HC(null,n,e,c[1],i),c=uv(c,e.attrs,i),function xH(n,e,t,i){n[$u(t?e.classBindings:e.styleBindings)]=i}(n,e,i,c))}else s=function wH(n,e,t){let i;const r=e.directiveEnd;for(let s=1+e.directiveStylingLast;s0)&&(u=!0)):p=t,r)if(0!==c){const v=$u(n[a+1]);n[i+1]=A1(v,a),0!==v&&(n[v+1]=BC(n[v+1],i)),n[a+1]=function oH(n,e){return 131071&n|e<<17}(n[a+1],i)}else n[i+1]=A1(a,0),0!==a&&(n[a+1]=BC(n[a+1],i)),a=i;else n[i+1]=A1(c,0),0===a?a=i:n[c+1]=BC(n[c+1],i),c=i;u&&(n[i+1]=NC(n[i+1])),GF(n,p,i,!0),GF(n,p,i,!1),function lH(n,e,t,i,r){const s=r?n.residualClasses:n.residualStyles;null!=s&&"string"==typeof e&&Pu(s,e)>=0&&(t[i+1]=VC(t[i+1]))}(e,p,n,i,s),o=A1(a,c),s?e.classBindings=o:e.styleBindings=o}(r,s,e,t,o,i)}}function HC(n,e,t,i,r){let s=null;const o=t.directiveEnd;let a=t.directiveStylingLast;for(-1===a?a=t.directiveStart:a++;a0;){const c=n[r],u=Array.isArray(c),p=u?c[1]:c,g=null===p;let v=t[r+1];v===Dn&&(v=g?Si:void 0);let y=g?Zp(v,i):p===i?v:void 0;if(u&&!k1(y)&&(y=Zp(c,i)),k1(y)&&(a=y,o))return a;const x=n[r+1];r=o?$u(x):Tf(x)}if(null!==e){let c=s?e.residualClasses:e.residualStyles;null!=c&&(a=Zp(c,i))}return a}function k1(n){return void 0!==n}function tR(n,e){return 0!=(n.flags&(e?8:16))}function it(n,e=""){const t=C(),i=B(),r=n+nn,s=i.firstCreatePass?Wu(i,r,1,e,null):i.data[r],o=t[r]=function p_(n,e){return n.createText(e)}(t[Hn],e);lm(i,t,o,s),Q(s,!1)}function Hi(n){return xs("",n,""),Hi}function xs(n,e,t){const i=C(),r=Nm(i,n,e,t);return r!==Dn&&function rl(n,e,t){const i=Jh(e,n);!function Nu(n,e,t){n.setValue(e,t)}(n[Hn],i,t)}(i,ii(),r),xs}function dR(n,e,t){!function ol(n,e,t,i){const r=B(),s=ce(2);r.firstUpdatePass&&ZF(r,null,s,i);const o=C();if(t!==Dn&&Vo(o,s,t)){const a=r.data[ii()];if(tR(a,i)&&!XF(r,s)){let c=i?a.classesWithoutHost:a.stylesWithoutHost;null!==c&&(t=fu(c,t||"")),RC(r,a,o,t,i)}else!function EH(n,e,t,i,r,s,o,a){r===Dn&&(r=Si);let c=0,u=0,p=0((Dt=Dt||{})[Dt.LocaleId=0]="LocaleId",Dt[Dt.DayPeriodsFormat=1]="DayPeriodsFormat",Dt[Dt.DayPeriodsStandalone=2]="DayPeriodsStandalone",Dt[Dt.DaysFormat=3]="DaysFormat",Dt[Dt.DaysStandalone=4]="DaysStandalone",Dt[Dt.MonthsFormat=5]="MonthsFormat",Dt[Dt.MonthsStandalone=6]="MonthsStandalone",Dt[Dt.Eras=7]="Eras",Dt[Dt.FirstDayOfWeek=8]="FirstDayOfWeek",Dt[Dt.WeekendRange=9]="WeekendRange",Dt[Dt.DateFormat=10]="DateFormat",Dt[Dt.TimeFormat=11]="TimeFormat",Dt[Dt.DateTimeFormat=12]="DateTimeFormat",Dt[Dt.NumberSymbols=13]="NumberSymbols",Dt[Dt.NumberFormats=14]="NumberFormats",Dt[Dt.CurrencyCode=15]="CurrencyCode",Dt[Dt.CurrencySymbol=16]="CurrencySymbol",Dt[Dt.CurrencyName=17]="CurrencyName",Dt[Dt.Currencies=18]="Currencies",Dt[Dt.Directionality=19]="Directionality",Dt[Dt.PluralCase=20]="PluralCase",Dt[Dt.ExtraData=21]="ExtraData",Dt))();const qm="en-US";let wR=qm;function jC(n,e,t,i,r){if(n=en(n),Array.isArray(n))for(let s=0;s>20;if(Ul(n)||!n.multi){const y=new Qh(c,r,ie),x=$C(a,e,r?p:p+v,g);-1===x?(q0(Ga(u,o),s,a),WC(s,n,e.length),e.push(a),u.directiveStart++,u.directiveEnd++,r&&(u.providerIndexes+=1048576),t.push(y),o.push(y)):(t[x]=y,o[x]=y)}else{const y=$C(a,e,p+v,g),x=$C(a,e,p,p+v),N=x>=0&&t[x];if(r&&!N||!r&&!(y>=0&&t[y])){q0(Ga(u,o),s,a);const k=function GU(n,e,t,i,r){const s=new Qh(n,t,ie);return s.multi=[],s.index=e,s.componentProviders=0,qR(s,r,i&&!t),s}(r?zU:UU,t.length,r,i,c);!r&&N&&(t[x].providerFactory=k),WC(s,n,e.length,0),e.push(a),u.directiveStart++,u.directiveEnd++,r&&(u.providerIndexes+=1048576),t.push(k),o.push(k)}else WC(s,n,y>-1?y:x,qR(t[r?x:y],c,!r&&i));!r&&i&&N&&t[x].componentProviders++}}}function WC(n,e,t,i){const r=Ul(e),s=function Ox(n){return!!n.useClass}(e);if(r||s){const c=(s?en(e.useClass):e).prototype.ngOnDestroy;if(c){const u=n.destroyHooks||(n.destroyHooks=[]);if(!r&&e.multi){const p=u.indexOf(t);-1===p?u.push(t,[i,c]):u[p+1].push(i,c)}else u.push(t,c)}}}function qR(n,e,t){return t&&n.componentProviders++,n.multi.push(e)-1}function $C(n,e,t,i){for(let r=t;r{t.providersResolver=(i,r)=>function HU(n,e,t){const i=B();if(i.firstCreatePass){const r=Fo(n);jC(t,i.data,i.blueprint,r,!0),jC(e,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,e)}}class Km{}class KR{}class YR extends Km{constructor(e,t){super(),this._parent=t,this._bootstrapComponents=[],this.destroyCbs=[],this.componentFactoryResolver=new M1(this);const i=po(e);this._bootstrapComponents=il(i.bootstrap),this._r3Injector=Kx(e,t,[{provide:Km,useValue:this},{provide:Fd,useValue:this.componentFactoryResolver}],ki(e),new Set(["environment"])),this._r3Injector.resolveInjectorInitializers(),this.instance=this._r3Injector.get(e)}get injector(){return this._r3Injector}destroy(){const e=this._r3Injector;!e.destroyed&&e.destroy(),this.destroyCbs.forEach(t=>t()),this.destroyCbs=null}onDestroy(e){this.destroyCbs.push(e)}}class KC extends KR{constructor(e){super(),this.moduleType=e}create(e){return new YR(this.moduleType,e)}}class WU extends Km{constructor(e,t,i){super(),this.componentFactoryResolver=new M1(this),this.instance=null;const r=new xf([...e,{provide:Km,useValue:this},{provide:Fd,useValue:this.componentFactoryResolver}],t||Sm(),i,new Set(["environment"]));this.injector=r,r.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(e){this.injector.onDestroy(e)}}function O1(n,e,t=null){return new WU(n,e,t).injector}let $U=(()=>{class n{constructor(t){this._injector=t,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(t){if(!t.standalone)return null;if(!this.cachedInjectors.has(t.id)){const i=Rx(0,t.type),r=i.length>0?O1([i],this._injector,`Standalone[${t.type.name}]`):null;this.cachedInjectors.set(t.id,r)}return this.cachedInjectors.get(t.id)}ngOnDestroy(){try{for(const t of this.cachedInjectors.values())null!==t&&t.destroy()}finally{this.cachedInjectors.clear()}}}return n.\u0275prov=Je({token:n,providedIn:"environment",factory:()=>new n(xe(na))}),n})();function _v(n){n.getStandaloneInjector=e=>e.get($U).getOrCreateStandaloneInjector(n)}function qu(n,e,t,i){return iP(C(),ee(),n,e,t,i)}function XC(n,e,t,i,r,s){return sP(C(),ee(),n,e,t,i,r,s)}function vv(n,e){const t=n[e];return t===Dn?void 0:t}function iP(n,e,t,i,r,s){const o=e+t;return Vo(n,o,r)?jl(n,o+1,s?i.call(s,r):i(r)):vv(n,o+1)}function rP(n,e,t,i,r,s,o){const a=e+t;return Cf(n,a,r,s)?jl(n,a+2,o?i.call(o,r,s):i(r,s)):vv(n,a+2)}function sP(n,e,t,i,r,s,o,a){const c=e+t;return function T1(n,e,t,i,r){const s=Cf(n,e,t,i);return Vo(n,e+2,r)||s}(n,c,r,s,o)?jl(n,c+3,a?i.call(a,r,s,o):i(r,s,o)):vv(n,c+3)}function ft(n,e){const t=B();let i;const r=n+nn;t.firstCreatePass?(i=function c9(n,e){if(e)for(let t=e.length-1;t>=0;t--){const i=e[t];if(n===i.name)return i}}(e,t.pipeRegistry),t.data[r]=i,i.onDestroy&&(t.destroyHooks||(t.destroyHooks=[])).push(r,i.onDestroy)):i=t.data[r];const s=i.factory||(i.factory=qn(i.type)),o=ho(ie);try{const a=Mu(!1),c=s();return Mu(a),function eH(n,e,t,i){t>=n.data.length&&(n.data[t]=null,n.blueprint[t]=null),e[t]=i}(t,C(),r,c),c}finally{ho(o)}}function vn(n,e,t){const i=n+nn,r=C(),s=yc(r,i);return bv(r,i)?iP(r,ee(),e,s.transform,t,s):s.transform(t)}function Ti(n,e,t,i){const r=n+nn,s=C(),o=yc(s,r);return bv(s,r)?rP(s,ee(),e,o.transform,t,i,o):o.transform(t,i)}function yv(n,e,t,i,r){const s=n+nn,o=C(),a=yc(o,s);return bv(o,s)?sP(o,ee(),e,a.transform,t,i,r,a):a.transform(t,i,r)}function bv(n,e){return n[xt].data[e].pure}function ZC(n){return e=>{setTimeout(n,void 0,e)}}const Pn=class u9 extends cn{constructor(e=!1){super(),this.__isAsync=e}emit(e){super.next(e)}subscribe(e,t,i){let r=e,s=t||(()=>null),o=i;if(e&&"object"==typeof e){const c=e;r=c.next?.bind(c),s=c.error?.bind(c),o=c.complete?.bind(c)}this.__isAsync&&(s=ZC(s),r&&(r=ZC(r)),o&&(o=ZC(o)));const a=super.subscribe({next:r,error:s,complete:o});return e instanceof Tn&&e.add(a),a}};function h9(){return this._results[Symbol.iterator]()}class xv{get changes(){return this._changes||(this._changes=new Pn)}constructor(e=!1){this._emitDistinctChangesOnly=e,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=null,this.length=0,this.first=void 0,this.last=void 0;const t=xv.prototype;t[Symbol.iterator]||(t[Symbol.iterator]=h9)}get(e){return this._results[e]}map(e){return this._results.map(e)}filter(e){return this._results.filter(e)}find(e){return this._results.find(e)}reduce(e,t){return this._results.reduce(e,t)}forEach(e){this._results.forEach(e)}some(e){return this._results.some(e)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(e,t){const i=this;i.dirty=!1;const r=function ya(n){return n.flat(Number.POSITIVE_INFINITY)}(e);(this._changesDetected=!function Nb(n,e,t){if(n.length!==e.length)return!1;for(let i=0;i{class n{}return n.__NG_ELEMENT_ID__=m9,n})();const f9=al,p9=class extends f9{constructor(e,t,i){super(),this._declarationLView=e,this._declarationTContainer=t,this.elementRef=i}createEmbeddedView(e,t){const i=this._declarationTContainer.tViews,r=Am(this._declarationLView,i,e,16,null,i.declTNode,null,null,null,null,t||null);r[kl]=this._declarationLView[this._declarationTContainer.index];const o=this._declarationLView[Qr];return null!==o&&(r[Qr]=o.createEmbeddedView(i)),W_(i,r,e),new Ef(r)}};function m9(){return L1(L(),C())}function L1(n,e){return 4&n.type?new p9(e,n,zu(n,e)):null}let Sa=(()=>{class n{}return n.__NG_ELEMENT_ID__=g9,n})();function g9(){return dP(L(),C())}const _9=Sa,cP=class extends _9{constructor(e,t,i){super(),this._lContainer=e,this._hostTNode=t,this._hostLView=i}get element(){return zu(this._hostTNode,this._hostLView)}get injector(){return new Tu(this._hostTNode,this._hostLView)}get parentInjector(){const e=Du(this._hostTNode,this._hostLView);if(ef(e)){const t=$p(e,this._hostLView),i=Wp(e);return new Tu(t[xt].data[i+8],t)}return new Tu(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(e){const t=lP(this._lContainer);return null!==t&&t[e]||null}get length(){return this._lContainer.length-gs}createEmbeddedView(e,t,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const o=e.createEmbeddedView(t||{},s);return this.insert(o,r),o}createComponent(e,t,i,r,s){const o=e&&!function rf(n){return"function"==typeof n}(e);let a;if(o)a=t;else{const g=t||{};a=g.index,i=g.injector,r=g.projectableNodes,s=g.environmentInjector||g.ngModuleRef}const c=o?e:new Mf(Ei(e)),u=i||this.parentInjector;if(!s&&null==c.ngModule){const v=(o?u:this.parentInjector).get(na,null);v&&(s=v)}const p=c.create(u,r,void 0,s);return this.insert(p.hostView,a),p}insert(e,t){const i=e._lView,r=i[xt];if(function l(n){return Yo(n[Zi])}(i)){const p=this.indexOf(e);if(-1!==p)this.detach(p);else{const g=i[Zi],v=new cP(g,g[Br],g[Zi]);v.detach(v.indexOf(e))}}const s=this._adjustIndex(t),o=this._lContainer;!function nx(n,e,t,i){const r=gs+i,s=t.length;i>0&&(t[r-1][si]=e),i0)i.push(o[a/2]);else{const u=s[a+1],p=e[-c];for(let g=gs;g{class n{constructor(t){this.appInits=t,this.resolve=B1,this.reject=B1,this.initialized=!1,this.done=!1,this.donePromise=new Promise((i,r)=>{this.resolve=i,this.reject=r})}runInitializers(){if(this.initialized)return;const t=[],i=()=>{this.done=!0,this.resolve()};if(this.appInits)for(let r=0;r{s.subscribe({complete:a,error:c})});t.push(o)}}Promise.all(t).then(()=>{i()}).catch(r=>{this.reject(r)}),0===t.length&&i(),this.initialized=!0}}return n.\u0275fac=function(t){return new(t||n)(xe(V1,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const Zm=new Ze("AppId",{providedIn:"root",factory:function RP(){return`${lD()}${lD()}${lD()}`}});function lD(){return String.fromCharCode(97+Math.floor(25*Math.random()))}const PP=new Ze("Platform Initializer"),U1=new Ze("Platform ID",{providedIn:"platform",factory:()=>"unknown"}),OP=new Ze("appBootstrapListener"),bo=new Ze("AnimationModuleType");let G9=(()=>{class n{log(t){console.log(t)}warn(t){console.warn(t)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})();const Ac=new Ze("LocaleId",{providedIn:"root",factory:()=>hn(Ac,tn.Optional|tn.SkipSelf)||function j9(){return typeof $localize<"u"&&$localize.locale||qm}()});class $9{constructor(e,t){this.ngModuleFactory=e,this.componentFactories=t}}let LP=(()=>{class n{compileModuleSync(t){return new KC(t)}compileModuleAsync(t){return Promise.resolve(this.compileModuleSync(t))}compileModuleAndAllComponentsSync(t){const i=this.compileModuleSync(t),s=il(po(t).declarations).reduce((o,a)=>{const c=Ei(a);return c&&o.push(new Mf(c)),o},[]);return new $9(i,s)}compileModuleAndAllComponentsAsync(t){return Promise.resolve(this.compileModuleAndAllComponentsSync(t))}clearCache(){}clearCacheFor(t){}getModuleId(t){}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const Y9=(()=>Promise.resolve(0))();function dD(n){typeof Zone>"u"?Y9.then(()=>{n&&n.apply(null,null)}):Zone.current.scheduleMicroTask("scheduleMicrotask",n)}class Xt{constructor({enableLongStackTrace:e=!1,shouldCoalesceEventChangeDetection:t=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Pn(!1),this.onMicrotaskEmpty=new Pn(!1),this.onStable=new Pn(!1),this.onError=new Pn(!1),typeof Zone>"u")throw new Ue(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),e&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&t,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function X9(){let n=Ii.requestAnimationFrame,e=Ii.cancelAnimationFrame;if(typeof Zone<"u"&&n&&e){const t=n[Zone.__symbol__("OriginalDelegate")];t&&(n=t);const i=e[Zone.__symbol__("OriginalDelegate")];i&&(e=i)}return{nativeRequestAnimationFrame:n,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function Q9(n){const e=()=>{!function J9(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(Ii,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,hD(n),n.isCheckStableRunning=!0,uD(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),hD(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(t,i,r,s,o,a)=>{try{return VP(n),t.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&e(),HP(n)}},onInvoke:(t,i,r,s,o,a,c)=>{try{return VP(n),t.invoke(r,s,o,a,c)}finally{n.shouldCoalesceRunChangeDetection&&e(),HP(n)}},onHasTask:(t,i,r,s)=>{t.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,hD(n),uD(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(t,i,r,s)=>(t.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Xt.isInAngularZone())throw new Ue(909,!1)}static assertNotInAngularZone(){if(Xt.isInAngularZone())throw new Ue(909,!1)}run(e,t,i){return this._inner.run(e,t,i)}runTask(e,t,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,e,Z9,B1,B1);try{return s.runTask(o,t,i)}finally{s.cancelTask(o)}}runGuarded(e,t,i){return this._inner.runGuarded(e,t,i)}runOutsideAngular(e){return this._outer.run(e)}}const Z9={};function uD(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function hD(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function VP(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function HP(n){n._nesting--,uD(n)}class e7{constructor(){this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new Pn,this.onMicrotaskEmpty=new Pn,this.onStable=new Pn,this.onError=new Pn}run(e,t,i){return e.apply(t,i)}runGuarded(e,t,i){return e.apply(t,i)}runOutsideAngular(e){return e()}runTask(e,t,i,r){return e.apply(t,i)}}const UP=new Ze(""),z1=new Ze("");let mD,fD=(()=>{class n{constructor(t,i,r){this._ngZone=t,this.registry=i,this._pendingCount=0,this._isZoneStable=!0,this._didWork=!1,this._callbacks=[],this.taskTrackingZone=null,mD||(function t7(n){mD=n}(r),r.addToWindow(i)),this._watchAngularEvents(),t.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:()=>{Xt.assertNotInAngularZone(),dD(()=>{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())dD(()=>{for(;0!==this._callbacks.length;){let t=this._callbacks.pop();clearTimeout(t.timeoutId),t.doneCb(this._didWork)}this._didWork=!1});else{let t=this.getPendingTasks();this._callbacks=this._callbacks.filter(i=>!i.updateCb||!i.updateCb(t)||(clearTimeout(i.timeoutId),!1)),this._didWork=!0}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(t=>({source:t.source,creationLocation:t.creationLocation,data:t.data})):[]}addCallback(t,i,r){let s=-1;i&&i>0&&(s=setTimeout(()=>{this._callbacks=this._callbacks.filter(o=>o.timeoutId!==s),t(this._didWork,this.getPendingTasks())},i)),this._callbacks.push({doneCb:t,timeoutId:s,updateCb:r})}whenStable(t,i,r){if(r&&!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(t,i,r),this._runCallbacksIfReady()}getPendingRequestCount(){return this._pendingCount}registerApplication(t){this.registry.registerApplication(t,this)}unregisterApplication(t){this.registry.unregisterApplication(t)}findProviders(t,i,r){return[]}}return n.\u0275fac=function(t){return new(t||n)(xe(Xt),xe(pD),xe(z1))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),pD=(()=>{class n{constructor(){this._applications=new Map}registerApplication(t,i){this._applications.set(t,i)}unregisterApplication(t){this._applications.delete(t)}unregisterAllApplications(){this._applications.clear()}getTestability(t){return this._applications.get(t)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(t,i=!0){return mD?.findTestabilityInTree(this,t,i)??null}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})(),Ku=null;const zP=new Ze("AllowMultipleToken"),gD=new Ze("PlatformDestroyListeners"),Ld=!1;class GP{constructor(e,t){this.name=e,this.token=t}}function WP(n,e,t=[]){const i=`Platform: ${e}`,r=new Ze(i);return(s=[])=>{let o=_D();if(!o||o.injector.get(zP,!1)){const a=[...t,...s,{provide:r,useValue:!0}];n?n(a):function r7(n){if(Ku&&!Ku.get(zP,!1))throw new Ue(400,!1);Ku=n;const e=n.get(qP);(function jP(n){const e=n.get(PP,null);e&&e.forEach(t=>t())})(n)}(function $P(n=[],e){return ts.create({name:e,providers:[{provide:wm,useValue:"platform"},{provide:gD,useValue:new Set([()=>Ku=null])},...n]})}(a,i))}return function o7(n){const e=_D();if(!e)throw new Ue(401,!1);return e}()}}function _D(){return Ku?.get(qP)??null}let qP=(()=>{class n{constructor(t){this._injector=t,this._modules=[],this._destroyListeners=[],this._destroyed=!1}bootstrapModuleFactory(t,i){const r=function YP(n,e){let t;return t="noop"===n?new e7:("zone.js"===n?void 0:n)||new Xt(e),t}(i?.ngZone,function KP(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:!(!n||!n.ngZoneEventCoalescing)||!1,shouldCoalesceRunChangeDetection:!(!n||!n.ngZoneRunCoalescing)||!1}}(i)),s=[{provide:Xt,useValue:r}];return r.run(()=>{const o=ts.create({providers:s,parent:this.injector,name:t.moduleType.name}),a=t.create(o),c=a.injector.get(tl,null);if(!c)throw new Ue(402,!1);return r.runOutsideAngular(()=>{const u=r.onError.subscribe({next:p=>{c.handleError(p)}});a.onDestroy(()=>{G1(this._modules,a),u.unsubscribe()})}),function XP(n,e,t){try{const i=t();return lv(i)?i.catch(r=>{throw e.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw e.runOutsideAngular(()=>n.handleError(i)),i}}(c,r,()=>{const u=a.injector.get(H1);return u.runInitializers(),u.donePromise.then(()=>(function SR(n){Rs(n,"Expected localeId to be defined"),"string"==typeof n&&(wR=n.toLowerCase().replace(/_/g,"-"))}(a.injector.get(Ac,qm)||qm),this._moduleDoBootstrap(a),a))})})}bootstrapModule(t,i=[]){const r=ZP({},i);return function n7(n,e,t){const i=new KC(t);return Promise.resolve(i)}(0,0,t).then(s=>this.bootstrapModuleFactory(s,r))}_moduleDoBootstrap(t){const i=t.injector.get(Jm);if(t._bootstrapComponents.length>0)t._bootstrapComponents.forEach(r=>i.bootstrap(r));else{if(!t.instance.ngDoBootstrap)throw new Ue(-403,!1);t.instance.ngDoBootstrap(i)}this._modules.push(t)}onDestroy(t){this._destroyListeners.push(t)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new Ue(404,!1);this._modules.slice().forEach(i=>i.destroy()),this._destroyListeners.forEach(i=>i());const t=this._injector.get(gD,null);t&&(t.forEach(i=>i()),t.clear()),this._destroyed=!0}get destroyed(){return this._destroyed}}return n.\u0275fac=function(t){return new(t||n)(xe(ts))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})();function ZP(n,e){return Array.isArray(e)?e.reduce(ZP,n):{...n,...e}}let Jm=(()=>{class n{get destroyed(){return this._destroyed}get injector(){return this._injector}constructor(t,i,r){this._zone=t,this._injector=i,this._exceptionHandler=r,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 s=new un(a=>{this._stable=this._zone.isStable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks,this._zone.runOutsideAngular(()=>{a.next(this._stable),a.complete()})}),o=new un(a=>{let c;this._zone.runOutsideAngular(()=>{c=this._zone.onStable.subscribe(()=>{Xt.assertNotInAngularZone(),dD(()=>{!this._stable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks&&(this._stable=!0,a.next(!0))})})});const u=this._zone.onUnstable.subscribe(()=>{Xt.assertInAngularZone(),this._stable&&(this._stable=!1,this._zone.runOutsideAngular(()=>{a.next(!1)}))});return()=>{c.unsubscribe(),u.unsubscribe()}});this.isStable=fa(s,o.pipe(Dp()))}bootstrap(t,i){const r=t instanceof Lx;if(!this._injector.get(H1).done){!r&&function Zr(n){const e=Ei(n)||Ni(n)||Ps(n);return null!==e&&e.standalone}(t);throw new Ue(405,Ld)}let o;o=r?t:this._injector.get(Fd).resolveComponentFactory(t),this.componentTypes.push(o.componentType);const a=function i7(n){return n.isBoundToModule}(o)?void 0:this._injector.get(Km),u=o.create(ts.NULL,[],i||o.selector,a),p=u.location.nativeElement,g=u.injector.get(UP,null);return g?.registerApplication(p),u.onDestroy(()=>{this.detachView(u.hostView),G1(this.components,u),g?.unregisterApplication(p)}),this._loadComponent(u),u}tick(){if(this._runningTick)throw new Ue(101,!1);try{this._runningTick=!0;for(let t of this._views)t.detectChanges()}catch(t){this._zone.runOutsideAngular(()=>this._exceptionHandler.handleError(t))}finally{this._runningTick=!1}}attachView(t){const i=t;this._views.push(i),i.attachToAppRef(this)}detachView(t){const i=t;G1(this._views,i),i.detachFromAppRef()}_loadComponent(t){this.attachView(t.hostView),this.tick(),this.components.push(t);const i=this._injector.get(OP,[]);i.push(...this._bootstrapListeners),i.forEach(r=>r(t))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(t=>t()),this._views.slice().forEach(t=>t.destroy()),this._onMicrotaskEmptySubscription.unsubscribe()}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(t){return this._destroyListeners.push(t),()=>G1(this._destroyListeners,t)}destroy(){if(this._destroyed)throw new Ue(406,!1);const t=this._injector;t.destroy&&!t.destroyed&&t.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}}return n.\u0275fac=function(t){return new(t||n)(xe(Xt),xe(na),xe(tl))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function G1(n,e){const t=n.indexOf(e);t>-1&&n.splice(t,1)}let aa=(()=>{class n{}return n.__NG_ELEMENT_ID__=c7,n})();function c7(n){return function l7(n,e,t){if(_s(n)&&!t){const i=Os(n.index,e);return new Ef(i,i)}return 47&n.type?new Ef(e[Jr],e):null}(L(),C(),16==(16&n))}class n3{constructor(){}supports(e){return to(e)}create(e){return new m7(e)}}const p7=(n,e)=>e;class m7{constructor(e){this.length=0,this._linkedRecords=null,this._unlinkedRecords=null,this._previousItHead=null,this._itHead=null,this._itTail=null,this._additionsHead=null,this._additionsTail=null,this._movesHead=null,this._movesTail=null,this._removalsHead=null,this._removalsTail=null,this._identityChangesHead=null,this._identityChangesTail=null,this._trackByFn=e||p7}forEachItem(e){let t;for(t=this._itHead;null!==t;t=t._next)e(t)}forEachOperation(e){let t=this._itHead,i=this._removalsHead,r=0,s=null;for(;t||i;){const o=!i||t&&t.currentIndex{o=this._trackByFn(r,a),null!==t&&Object.is(t.trackById,o)?(i&&(t=this._verifyReinsertion(t,a,o,r)),Object.is(t.item,a)||this._addIdentityChange(t,a)):(t=this._mismatch(t,a,o,r),i=!0),t=t._next,r++}),this.length=r;return this._truncate(t),this.collection=e,this.isDirty}get isDirty(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}_reset(){if(this.isDirty){let e;for(e=this._previousItHead=this._itHead;null!==e;e=e._next)e._nextPrevious=e._next;for(e=this._additionsHead;null!==e;e=e._nextAdded)e.previousIndex=e.currentIndex;for(this._additionsHead=this._additionsTail=null,e=this._movesHead;null!==e;e=e._nextMoved)e.previousIndex=e.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(e,t,i,r){let s;return null===e?s=this._itTail:(s=e._prev,this._remove(e)),null!==(e=null===this._unlinkedRecords?null:this._unlinkedRecords.get(i,null))?(Object.is(e.item,t)||this._addIdentityChange(e,t),this._reinsertAfter(e,s,r)):null!==(e=null===this._linkedRecords?null:this._linkedRecords.get(i,r))?(Object.is(e.item,t)||this._addIdentityChange(e,t),this._moveAfter(e,s,r)):e=this._addAfter(new g7(t,i),s,r),e}_verifyReinsertion(e,t,i,r){let s=null===this._unlinkedRecords?null:this._unlinkedRecords.get(i,null);return null!==s?e=this._reinsertAfter(s,e._prev,r):e.currentIndex!=r&&(e.currentIndex=r,this._addToMoves(e,r)),e}_truncate(e){for(;null!==e;){const t=e._next;this._addToRemovals(this._unlink(e)),e=t}null!==this._unlinkedRecords&&this._unlinkedRecords.clear(),null!==this._additionsTail&&(this._additionsTail._nextAdded=null),null!==this._movesTail&&(this._movesTail._nextMoved=null),null!==this._itTail&&(this._itTail._next=null),null!==this._removalsTail&&(this._removalsTail._nextRemoved=null),null!==this._identityChangesTail&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(e,t,i){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(e);const r=e._prevRemoved,s=e._nextRemoved;return null===r?this._removalsHead=s:r._nextRemoved=s,null===s?this._removalsTail=r:s._prevRemoved=r,this._insertAfter(e,t,i),this._addToMoves(e,i),e}_moveAfter(e,t,i){return this._unlink(e),this._insertAfter(e,t,i),this._addToMoves(e,i),e}_addAfter(e,t,i){return this._insertAfter(e,t,i),this._additionsTail=null===this._additionsTail?this._additionsHead=e:this._additionsTail._nextAdded=e,e}_insertAfter(e,t,i){const r=null===t?this._itHead:t._next;return e._next=r,e._prev=t,null===r?this._itTail=e:r._prev=e,null===t?this._itHead=e:t._next=e,null===this._linkedRecords&&(this._linkedRecords=new i3),this._linkedRecords.put(e),e.currentIndex=i,e}_remove(e){return this._addToRemovals(this._unlink(e))}_unlink(e){null!==this._linkedRecords&&this._linkedRecords.remove(e);const t=e._prev,i=e._next;return null===t?this._itHead=i:t._next=i,null===i?this._itTail=t:i._prev=t,e}_addToMoves(e,t){return e.previousIndex===t||(this._movesTail=null===this._movesTail?this._movesHead=e:this._movesTail._nextMoved=e),e}_addToRemovals(e){return null===this._unlinkedRecords&&(this._unlinkedRecords=new i3),this._unlinkedRecords.put(e),e.currentIndex=null,e._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=e,e._prevRemoved=null):(e._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=e),e}_addIdentityChange(e,t){return e.item=t,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=e:this._identityChangesTail._nextIdentityChange=e,e}}class g7{constructor(e,t){this.item=e,this.trackById=t,this.currentIndex=null,this.previousIndex=null,this._nextPrevious=null,this._prev=null,this._next=null,this._prevDup=null,this._nextDup=null,this._prevRemoved=null,this._nextRemoved=null,this._nextAdded=null,this._nextMoved=null,this._nextIdentityChange=null}}class _7{constructor(){this._head=null,this._tail=null}add(e){null===this._head?(this._head=this._tail=e,e._nextDup=null,e._prevDup=null):(this._tail._nextDup=e,e._prevDup=this._tail,e._nextDup=null,this._tail=e)}get(e,t){let i;for(i=this._head;null!==i;i=i._nextDup)if((null===t||t<=i.currentIndex)&&Object.is(i.trackById,e))return i;return null}remove(e){const t=e._prevDup,i=e._nextDup;return null===t?this._head=i:t._nextDup=i,null===i?this._tail=t:i._prevDup=t,null===this._head}}class i3{constructor(){this.map=new Map}put(e){const t=e.trackById;let i=this.map.get(t);i||(i=new _7,this.map.set(t,i)),i.add(e)}get(e,t){const r=this.map.get(e);return r?r.get(e,t):null}remove(e){const t=e.trackById;return this.map.get(t).remove(e)&&this.map.delete(t),e}get isEmpty(){return 0===this.map.size}clear(){this.map.clear()}}function r3(n,e,t){const i=n.previousIndex;if(null===i)return i;let r=0;return t&&i{if(t&&t.key===r)this._maybeAddToChanges(t,i),this._appendAfter=t,t=t._next;else{const s=this._getOrCreateRecordForKey(r,i);t=this._insertBeforeOrAppend(t,s)}}),t){t._prev&&(t._prev._next=null),this._removalsHead=t;for(let i=t;null!==i;i=i._nextRemoved)i===this._mapHead&&(this._mapHead=null),this._records.delete(i.key),i._nextRemoved=i._next,i.previousValue=i.currentValue,i.currentValue=null,i._prev=null,i._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(e,t){if(e){const i=e._prev;return t._next=e,t._prev=i,e._prev=t,i&&(i._next=t),e===this._mapHead&&(this._mapHead=t),this._appendAfter=e,e}return this._appendAfter?(this._appendAfter._next=t,t._prev=this._appendAfter):this._mapHead=t,this._appendAfter=t,null}_getOrCreateRecordForKey(e,t){if(this._records.has(e)){const r=this._records.get(e);this._maybeAddToChanges(r,t);const s=r._prev,o=r._next;return s&&(s._next=o),o&&(o._prev=s),r._next=null,r._prev=null,r}const i=new y7(e);return this._records.set(e,i),i.currentValue=t,this._addToAdditions(i),i}_reset(){if(this.isDirty){let e;for(this._previousMapHead=this._mapHead,e=this._previousMapHead;null!==e;e=e._next)e._nextPrevious=e._next;for(e=this._changesHead;null!==e;e=e._nextChanged)e.previousValue=e.currentValue;for(e=this._additionsHead;null!=e;e=e._nextAdded)e.previousValue=e.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(e,t){Object.is(t,e.currentValue)||(e.previousValue=e.currentValue,e.currentValue=t,this._addToChanges(e))}_addToAdditions(e){null===this._additionsHead?this._additionsHead=this._additionsTail=e:(this._additionsTail._nextAdded=e,this._additionsTail=e)}_addToChanges(e){null===this._changesHead?this._changesHead=this._changesTail=e:(this._changesTail._nextChanged=e,this._changesTail=e)}_forEach(e,t){e instanceof Map?e.forEach(t):Object.keys(e).forEach(i=>t(e[i],i))}}class y7{constructor(e){this.key=e,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._prev=null,this._nextAdded=null,this._nextRemoved=null,this._nextChanged=null}}function o3(){return new $1([new n3])}let $1=(()=>{class n{constructor(t){this.factories=t}static create(t,i){if(null!=i){const r=i.factories.slice();t=t.concat(r)}return new n(t)}static extend(t){return{provide:n,useFactory:i=>n.create(t,i||o3()),deps:[[n,new Pl,new ba]]}}find(t){const i=this.factories.find(r=>r.supports(t));if(null!=i)return i;throw new Ue(901,!1)}}return n.\u0275prov=Je({token:n,providedIn:"root",factory:o3}),n})();function a3(){return new Ev([new s3])}let Ev=(()=>{class n{constructor(t){this.factories=t}static create(t,i){if(i){const r=i.factories.slice();t=t.concat(r)}return new n(t)}static extend(t){return{provide:n,useFactory:i=>n.create(t,i||a3()),deps:[[n,new Pl,new ba]]}}find(t){const i=this.factories.find(r=>r.supports(t));if(i)return i;throw new Ue(901,!1)}}return n.\u0275prov=Je({token:n,providedIn:"root",factory:a3}),n})();const w7=WP(null,"core",[]);let S7=(()=>{class n{constructor(t){}}return n.\u0275fac=function(t){return new(t||n)(xe(Jm))},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})();let wD=null;function Nd(){return wD}class C7{}const Mn=new Ze("DocumentToken");let SD=(()=>{class n{historyGo(t){throw new Error("Not implemented")}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return function D7(){return xe(c3)}()},providedIn:"platform"}),n})();const T7=new Ze("Location Initialized");let c3=(()=>{class n extends SD{constructor(t){super(),this._doc=t,this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return Nd().getBaseHref(this._doc)}onPopState(t){const i=Nd().getGlobalEventTarget(this._doc,"window");return i.addEventListener("popstate",t,!1),()=>i.removeEventListener("popstate",t)}onHashChange(t){const i=Nd().getGlobalEventTarget(this._doc,"window");return i.addEventListener("hashchange",t,!1),()=>i.removeEventListener("hashchange",t)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(t){this._location.pathname=t}pushState(t,i,r){l3()?this._history.pushState(t,i,r):this._location.hash=r}replaceState(t,i,r){l3()?this._history.replaceState(t,i,r):this._location.hash=r}forward(){this._history.forward()}back(){this._history.back()}historyGo(t=0){this._history.go(t)}getState(){return this._history.state}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:function(){return function A7(){return new c3(xe(Mn))}()},providedIn:"platform"}),n})();function l3(){return!!window.history.pushState}function ED(n,e){if(0==n.length)return e;if(0==e.length)return n;let t=0;return n.endsWith("/")&&t++,e.startsWith("/")&&t++,2==t?n+e.substring(1):1==t?n+e:n+"/"+e}function d3(n){const e=n.match(/#|\?|$/),t=e&&e.index||n.length;return n.slice(0,t-("/"===n[t-1]?1:0))+n.slice(t)}function Bd(n){return n&&"?"!==n[0]?"?"+n:n}let Ff=(()=>{class n{historyGo(t){throw new Error("Not implemented")}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return hn(h3)},providedIn:"root"}),n})();const u3=new Ze("appBaseHref");let h3=(()=>{class n extends Ff{constructor(t,i){super(),this._platformLocation=t,this._removeListenerFns=[],this._baseHref=i??this._platformLocation.getBaseHrefFromDOM()??hn(Mn).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(t){this._removeListenerFns.push(this._platformLocation.onPopState(t),this._platformLocation.onHashChange(t))}getBaseHref(){return this._baseHref}prepareExternalUrl(t){return ED(this._baseHref,t)}path(t=!1){const i=this._platformLocation.pathname+Bd(this._platformLocation.search),r=this._platformLocation.hash;return r&&t?`${i}${r}`:i}pushState(t,i,r,s){const o=this.prepareExternalUrl(r+Bd(s));this._platformLocation.pushState(t,i,o)}replaceState(t,i,r,s){const o=this.prepareExternalUrl(r+Bd(s));this._platformLocation.replaceState(t,i,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(t=0){this._platformLocation.historyGo?.(t)}}return n.\u0275fac=function(t){return new(t||n)(xe(SD),xe(u3,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),k7=(()=>{class n extends Ff{constructor(t,i){super(),this._platformLocation=t,this._baseHref="",this._removeListenerFns=[],null!=i&&(this._baseHref=i)}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(t){this._removeListenerFns.push(this._platformLocation.onPopState(t),this._platformLocation.onHashChange(t))}getBaseHref(){return this._baseHref}path(t=!1){let i=this._platformLocation.hash;return null==i&&(i="#"),i.length>0?i.substring(1):i}prepareExternalUrl(t){const i=ED(this._baseHref,t);return i.length>0?"#"+i:i}pushState(t,i,r,s){let o=this.prepareExternalUrl(r+Bd(s));0==o.length&&(o=this._platformLocation.pathname),this._platformLocation.pushState(t,i,o)}replaceState(t,i,r,s){let o=this.prepareExternalUrl(r+Bd(s));0==o.length&&(o=this._platformLocation.pathname),this._platformLocation.replaceState(t,i,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(t=0){this._platformLocation.historyGo?.(t)}}return n.\u0275fac=function(t){return new(t||n)(xe(SD),xe(u3,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),Mv=(()=>{class n{constructor(t){this._subject=new Pn,this._urlChangeListeners=[],this._urlChangeSubscription=null,this._locationStrategy=t;const i=this._locationStrategy.getBaseHref();this._basePath=function R7(n){if(new RegExp("^(https?:)?//").test(n)){const[,t]=n.split(/\/\/[^\/]+/);return t}return n}(d3(f3(i))),this._locationStrategy.onPopState(r=>{this._subject.emit({url:this.path(!0),pop:!0,state:r.state,type:r.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(t=!1){return this.normalize(this._locationStrategy.path(t))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(t,i=""){return this.path()==this.normalize(t+Bd(i))}normalize(t){return n.stripTrailingSlash(function F7(n,e){if(!n||!e.startsWith(n))return e;const t=e.substring(n.length);return""===t||["/",";","?","#"].includes(t[0])?t:e}(this._basePath,f3(t)))}prepareExternalUrl(t){return t&&"/"!==t[0]&&(t="/"+t),this._locationStrategy.prepareExternalUrl(t)}go(t,i="",r=null){this._locationStrategy.pushState(r,"",t,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+Bd(i)),r)}replaceState(t,i="",r=null){this._locationStrategy.replaceState(r,"",t,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+Bd(i)),r)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(t=0){this._locationStrategy.historyGo?.(t)}onUrlChange(t){return this._urlChangeListeners.push(t),this._urlChangeSubscription||(this._urlChangeSubscription=this.subscribe(i=>{this._notifyUrlChangeListeners(i.url,i.state)})),()=>{const i=this._urlChangeListeners.indexOf(t);this._urlChangeListeners.splice(i,1),0===this._urlChangeListeners.length&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(t="",i){this._urlChangeListeners.forEach(r=>r(t,i))}subscribe(t,i,r){return this._subject.subscribe({next:t,error:i,complete:r})}}return n.normalizeQueryParams=Bd,n.joinWithSlash=ED,n.stripTrailingSlash=d3,n.\u0275fac=function(t){return new(t||n)(xe(Ff))},n.\u0275prov=Je({token:n,factory:function(){return function I7(){return new Mv(xe(Ff))}()},providedIn:"root"}),n})();function f3(n){return n.replace(/\/index.html$/,"")}var rs=(()=>((rs=rs||{})[rs.Format=0]="Format",rs[rs.Standalone=1]="Standalone",rs))(),fi=(()=>((fi=fi||{})[fi.Narrow=0]="Narrow",fi[fi.Abbreviated=1]="Abbreviated",fi[fi.Wide=2]="Wide",fi[fi.Short=3]="Short",fi))(),Or=(()=>((Or=Or||{})[Or.Short=0]="Short",Or[Or.Medium=1]="Medium",Or[Or.Long=2]="Long",Or[Or.Full=3]="Full",Or))(),mn=(()=>((mn=mn||{})[mn.Decimal=0]="Decimal",mn[mn.Group=1]="Group",mn[mn.List=2]="List",mn[mn.PercentSign=3]="PercentSign",mn[mn.PlusSign=4]="PlusSign",mn[mn.MinusSign=5]="MinusSign",mn[mn.Exponential=6]="Exponential",mn[mn.SuperscriptingExponent=7]="SuperscriptingExponent",mn[mn.PerMille=8]="PerMille",mn[mn.Infinity=9]="Infinity",mn[mn.NaN=10]="NaN",mn[mn.TimeSeparator=11]="TimeSeparator",mn[mn.CurrencyDecimal=12]="CurrencyDecimal",mn[mn.CurrencyGroup=13]="CurrencyGroup",mn))();function q1(n,e){return Ic(sa(n)[Dt.DateFormat],e)}function K1(n,e){return Ic(sa(n)[Dt.TimeFormat],e)}function Y1(n,e){return Ic(sa(n)[Dt.DateTimeFormat],e)}function kc(n,e){const t=sa(n),i=t[Dt.NumberSymbols][e];if(typeof i>"u"){if(e===mn.CurrencyDecimal)return t[Dt.NumberSymbols][mn.Decimal];if(e===mn.CurrencyGroup)return t[Dt.NumberSymbols][mn.Group]}return i}function m3(n){if(!n[Dt.ExtraData])throw new Error(`Missing extra locale data for the locale "${n[Dt.LocaleId]}". Use "registerLocaleData" to load new data. See the "I18n guide" on angular.io to know more.`)}function Ic(n,e){for(let t=e;t>-1;t--)if(typeof n[t]<"u")return n[t];throw new Error("Locale data API: locale data undefined")}function CD(n){const[e,t]=n.split(":");return{hours:+e,minutes:+t}}const $7=/^(\d{4,})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/,Cv={},q7=/((?:[^BEGHLMOSWYZabcdhmswyz']+)|(?:'(?:[^']|'')*')|(?:G{1,5}|y{1,4}|Y{1,4}|M{1,5}|L{1,5}|w{1,2}|W{1}|d{1,2}|E{1,6}|c{1,6}|a{1,5}|b{1,5}|B{1,5}|h{1,2}|H{1,2}|m{1,2}|s{1,2}|S{1,3}|z{1,4}|Z{1,5}|O{1,4}))([\s\S]*)/;var zs=(()=>((zs=zs||{})[zs.Short=0]="Short",zs[zs.ShortGMT=1]="ShortGMT",zs[zs.Long=2]="Long",zs[zs.Extended=3]="Extended",zs))(),bn=(()=>((bn=bn||{})[bn.FullYear=0]="FullYear",bn[bn.Month=1]="Month",bn[bn.Date=2]="Date",bn[bn.Hours=3]="Hours",bn[bn.Minutes=4]="Minutes",bn[bn.Seconds=5]="Seconds",bn[bn.FractionalSeconds=6]="FractionalSeconds",bn[bn.Day=7]="Day",bn))(),Zn=(()=>((Zn=Zn||{})[Zn.DayPeriods=0]="DayPeriods",Zn[Zn.Days=1]="Days",Zn[Zn.Months=2]="Months",Zn[Zn.Eras=3]="Eras",Zn))();function DD(n,e,t,i){let r=function nz(n){if(v3(n))return n;if("number"==typeof n&&!isNaN(n))return new Date(n);if("string"==typeof n){if(n=n.trim(),/^(\d{4}(-\d{1,2}(-\d{1,2})?)?)$/.test(n)){const[r,s=1,o=1]=n.split("-").map(a=>+a);return X1(r,s-1,o)}const t=parseFloat(n);if(!isNaN(n-t))return new Date(t);let i;if(i=n.match($7))return function iz(n){const e=new Date(0);let t=0,i=0;const r=n[8]?e.setUTCFullYear:e.setFullYear,s=n[8]?e.setUTCHours:e.setHours;n[9]&&(t=Number(n[9]+n[10]),i=Number(n[9]+n[11])),r.call(e,Number(n[1]),Number(n[2])-1,Number(n[3]));const o=Number(n[4]||0)-t,a=Number(n[5]||0)-i,c=Number(n[6]||0),u=Math.floor(1e3*parseFloat("0."+(n[7]||0)));return s.call(e,o,a,c,u),e}(i)}const e=new Date(n);if(!v3(e))throw new Error(`Unable to convert "${n}" into a date`);return e}(n);e=Vd(t,e)||e;let a,o=[];for(;e;){if(a=q7.exec(e),!a){o.push(e);break}{o=o.concat(a.slice(1));const p=o.pop();if(!p)break;e=p}}let c=r.getTimezoneOffset();i&&(c=_3(i,c),r=function tz(n,e,t){const i=t?-1:1,r=n.getTimezoneOffset();return function ez(n,e){return(n=new Date(n.getTime())).setMinutes(n.getMinutes()+e),n}(n,i*(_3(e,r)-r))}(r,i,!0));let u="";return o.forEach(p=>{const g=function Q7(n){if(AD[n])return AD[n];let e;switch(n){case"G":case"GG":case"GGG":e=ar(Zn.Eras,fi.Abbreviated);break;case"GGGG":e=ar(Zn.Eras,fi.Wide);break;case"GGGGG":e=ar(Zn.Eras,fi.Narrow);break;case"y":e=Ss(bn.FullYear,1,0,!1,!0);break;case"yy":e=Ss(bn.FullYear,2,0,!0,!0);break;case"yyy":e=Ss(bn.FullYear,3,0,!1,!0);break;case"yyyy":e=Ss(bn.FullYear,4,0,!1,!0);break;case"Y":e=ew(1);break;case"YY":e=ew(2,!0);break;case"YYY":e=ew(3);break;case"YYYY":e=ew(4);break;case"M":case"L":e=Ss(bn.Month,1,1);break;case"MM":case"LL":e=Ss(bn.Month,2,1);break;case"MMM":e=ar(Zn.Months,fi.Abbreviated);break;case"MMMM":e=ar(Zn.Months,fi.Wide);break;case"MMMMM":e=ar(Zn.Months,fi.Narrow);break;case"LLL":e=ar(Zn.Months,fi.Abbreviated,rs.Standalone);break;case"LLLL":e=ar(Zn.Months,fi.Wide,rs.Standalone);break;case"LLLLL":e=ar(Zn.Months,fi.Narrow,rs.Standalone);break;case"w":e=TD(1);break;case"ww":e=TD(2);break;case"W":e=TD(1,!0);break;case"d":e=Ss(bn.Date,1);break;case"dd":e=Ss(bn.Date,2);break;case"c":case"cc":e=Ss(bn.Day,1);break;case"ccc":e=ar(Zn.Days,fi.Abbreviated,rs.Standalone);break;case"cccc":e=ar(Zn.Days,fi.Wide,rs.Standalone);break;case"ccccc":e=ar(Zn.Days,fi.Narrow,rs.Standalone);break;case"cccccc":e=ar(Zn.Days,fi.Short,rs.Standalone);break;case"E":case"EE":case"EEE":e=ar(Zn.Days,fi.Abbreviated);break;case"EEEE":e=ar(Zn.Days,fi.Wide);break;case"EEEEE":e=ar(Zn.Days,fi.Narrow);break;case"EEEEEE":e=ar(Zn.Days,fi.Short);break;case"a":case"aa":case"aaa":e=ar(Zn.DayPeriods,fi.Abbreviated);break;case"aaaa":e=ar(Zn.DayPeriods,fi.Wide);break;case"aaaaa":e=ar(Zn.DayPeriods,fi.Narrow);break;case"b":case"bb":case"bbb":e=ar(Zn.DayPeriods,fi.Abbreviated,rs.Standalone,!0);break;case"bbbb":e=ar(Zn.DayPeriods,fi.Wide,rs.Standalone,!0);break;case"bbbbb":e=ar(Zn.DayPeriods,fi.Narrow,rs.Standalone,!0);break;case"B":case"BB":case"BBB":e=ar(Zn.DayPeriods,fi.Abbreviated,rs.Format,!0);break;case"BBBB":e=ar(Zn.DayPeriods,fi.Wide,rs.Format,!0);break;case"BBBBB":e=ar(Zn.DayPeriods,fi.Narrow,rs.Format,!0);break;case"h":e=Ss(bn.Hours,1,-12);break;case"hh":e=Ss(bn.Hours,2,-12);break;case"H":e=Ss(bn.Hours,1);break;case"HH":e=Ss(bn.Hours,2);break;case"m":e=Ss(bn.Minutes,1);break;case"mm":e=Ss(bn.Minutes,2);break;case"s":e=Ss(bn.Seconds,1);break;case"ss":e=Ss(bn.Seconds,2);break;case"S":e=Ss(bn.FractionalSeconds,1);break;case"SS":e=Ss(bn.FractionalSeconds,2);break;case"SSS":e=Ss(bn.FractionalSeconds,3);break;case"Z":case"ZZ":case"ZZZ":e=J1(zs.Short);break;case"ZZZZZ":e=J1(zs.Extended);break;case"O":case"OO":case"OOO":case"z":case"zz":case"zzz":e=J1(zs.ShortGMT);break;case"OOOO":case"ZZZZ":case"zzzz":e=J1(zs.Long);break;default:return null}return AD[n]=e,e}(p);u+=g?g(r,t,c):"''"===p?"'":p.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),u}function X1(n,e,t){const i=new Date(0);return i.setFullYear(n,e,t),i.setHours(0,0,0),i}function Vd(n,e){const t=function P7(n){return sa(n)[Dt.LocaleId]}(n);if(Cv[t]=Cv[t]||{},Cv[t][e])return Cv[t][e];let i="";switch(e){case"shortDate":i=q1(n,Or.Short);break;case"mediumDate":i=q1(n,Or.Medium);break;case"longDate":i=q1(n,Or.Long);break;case"fullDate":i=q1(n,Or.Full);break;case"shortTime":i=K1(n,Or.Short);break;case"mediumTime":i=K1(n,Or.Medium);break;case"longTime":i=K1(n,Or.Long);break;case"fullTime":i=K1(n,Or.Full);break;case"short":const r=Vd(n,"shortTime"),s=Vd(n,"shortDate");i=Z1(Y1(n,Or.Short),[r,s]);break;case"medium":const o=Vd(n,"mediumTime"),a=Vd(n,"mediumDate");i=Z1(Y1(n,Or.Medium),[o,a]);break;case"long":const c=Vd(n,"longTime"),u=Vd(n,"longDate");i=Z1(Y1(n,Or.Long),[c,u]);break;case"full":const p=Vd(n,"fullTime"),g=Vd(n,"fullDate");i=Z1(Y1(n,Or.Full),[p,g])}return i&&(Cv[t][e]=i),i}function Z1(n,e){return e&&(n=n.replace(/\{([^}]+)}/g,function(t,i){return null!=e&&i in e?e[i]:t})),n}function ll(n,e,t="-",i,r){let s="";(n<0||r&&n<=0)&&(r?n=1-n:(n=-n,s=t));let o=String(n);for(;o.length0||a>-t)&&(a+=t),n===bn.Hours)0===a&&-12===t&&(a=12);else if(n===bn.FractionalSeconds)return function K7(n,e){return ll(n,3).substring(0,e)}(a,e);const c=kc(o,mn.MinusSign);return ll(a,e,c,i,r)}}function ar(n,e,t=rs.Format,i=!1){return function(r,s){return function X7(n,e,t,i,r,s){switch(t){case Zn.Months:return function N7(n,e,t){const i=sa(n),s=Ic([i[Dt.MonthsFormat],i[Dt.MonthsStandalone]],e);return Ic(s,t)}(e,r,i)[n.getMonth()];case Zn.Days:return function L7(n,e,t){const i=sa(n),s=Ic([i[Dt.DaysFormat],i[Dt.DaysStandalone]],e);return Ic(s,t)}(e,r,i)[n.getDay()];case Zn.DayPeriods:const o=n.getHours(),a=n.getMinutes();if(s){const u=function U7(n){const e=sa(n);return m3(e),(e[Dt.ExtraData][2]||[]).map(i=>"string"==typeof i?CD(i):[CD(i[0]),CD(i[1])])}(e),p=function z7(n,e,t){const i=sa(n);m3(i);const s=Ic([i[Dt.ExtraData][0],i[Dt.ExtraData][1]],e)||[];return Ic(s,t)||[]}(e,r,i),g=u.findIndex(v=>{if(Array.isArray(v)){const[y,x]=v,T=o>=y.hours&&a>=y.minutes,N=o0?Math.floor(r/60):Math.ceil(r/60);switch(n){case zs.Short:return(r>=0?"+":"")+ll(o,2,s)+ll(Math.abs(r%60),2,s);case zs.ShortGMT:return"GMT"+(r>=0?"+":"")+ll(o,1,s);case zs.Long:return"GMT"+(r>=0?"+":"")+ll(o,2,s)+":"+ll(Math.abs(r%60),2,s);case zs.Extended:return 0===i?"Z":(r>=0?"+":"")+ll(o,2,s)+":"+ll(Math.abs(r%60),2,s);default:throw new Error(`Unknown zone width "${n}"`)}}}const Z7=0,Q1=4;function g3(n){return X1(n.getFullYear(),n.getMonth(),n.getDate()+(Q1-n.getDay()))}function TD(n,e=!1){return function(t,i){let r;if(e){const s=new Date(t.getFullYear(),t.getMonth(),1).getDay()-1,o=t.getDate();r=1+Math.floor((o+s)/7)}else{const s=g3(t),o=function J7(n){const e=X1(n,Z7,1).getDay();return X1(n,0,1+(e<=Q1?Q1:Q1+7)-e)}(s.getFullYear()),a=s.getTime()-o.getTime();r=1+Math.round(a/6048e5)}return ll(r,n,kc(i,mn.MinusSign))}}function ew(n,e=!1){return function(t,i){return ll(g3(t).getFullYear(),n,kc(i,mn.MinusSign),e)}}const AD={};function _3(n,e){n=n.replace(/:/g,"");const t=Date.parse("Jan 01, 1970 00:00:00 "+n)/6e4;return isNaN(t)?e:t}function v3(n){return n instanceof Date&&!isNaN(n.valueOf())}function Es(n,e,t){return function WH(n,e,t){"string"!=typeof e&&(t=e,e=n[Dt.LocaleId]),e=e.toLowerCase().replace(/_/g,"-"),$m[e]=n,t&&($m[e][Dt.ExtraData]=t)}(n,e,t)}function w3(n,e){e=encodeURIComponent(e);for(const t of n.split(";")){const i=t.indexOf("="),[r,s]=-1==i?[t,""]:[t.slice(0,i),t.slice(i+1)];if(r.trim()===e)return decodeURIComponent(s)}return null}const OD=/\s+/,S3=[];let eg=(()=>{class n{constructor(t,i,r,s){this._iterableDiffers=t,this._keyValueDiffers=i,this._ngEl=r,this._renderer=s,this.initialClasses=S3,this.stateMap=new Map}set klass(t){this.initialClasses=null!=t?t.trim().split(OD):S3}set ngClass(t){this.rawClass="string"==typeof t?t.trim().split(OD):t}ngDoCheck(){for(const i of this.initialClasses)this._updateState(i,!0);const t=this.rawClass;if(Array.isArray(t)||t instanceof Set)for(const i of t)this._updateState(i,!0);else if(null!=t)for(const i of Object.keys(t))this._updateState(i,Boolean(t[i]));this._applyStateDiff()}_updateState(t,i){const r=this.stateMap.get(t);void 0!==r?(r.enabled!==i&&(r.changed=!0,r.enabled=i),r.touched=!0):this.stateMap.set(t,{enabled:i,changed:!0,touched:!0})}_applyStateDiff(){for(const t of this.stateMap){const i=t[0],r=t[1];r.changed?(this._toggleClass(i,r.enabled),r.changed=!1):r.touched||(r.enabled&&this._toggleClass(i,!1),this.stateMap.delete(i)),r.touched=!1}}_toggleClass(t,i){(t=t.trim()).length>0&&t.split(OD).forEach(r=>{i?this._renderer.addClass(this._ngEl.nativeElement,r):this._renderer.removeClass(this._ngEl.nativeElement,r)})}}return n.\u0275fac=function(t){return new(t||n)(ie($1),ie(Ev),ie(_n),ie(el))},n.\u0275dir=ut({type:n,selectors:[["","ngClass",""]],inputs:{klass:["class","klass"],ngClass:"ngClass"},standalone:!0}),n})();class gz{constructor(e,t,i,r){this.$implicit=e,this.ngForOf=t,this.index=i,this.count=r}get first(){return 0===this.index}get last(){return this.index===this.count-1}get even(){return this.index%2==0}get odd(){return!this.even}}let tg=(()=>{class n{set ngForOf(t){this._ngForOf=t,this._ngForOfDirty=!0}set ngForTrackBy(t){this._trackByFn=t}get ngForTrackBy(){return this._trackByFn}constructor(t,i,r){this._viewContainer=t,this._template=i,this._differs=r,this._ngForOf=null,this._ngForOfDirty=!0,this._differ=null}set ngForTemplate(t){t&&(this._template=t)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;const t=this._ngForOf;!this._differ&&t&&(this._differ=this._differs.find(t).create(this.ngForTrackBy))}if(this._differ){const t=this._differ.diff(this._ngForOf);t&&this._applyChanges(t)}}_applyChanges(t){const i=this._viewContainer;t.forEachOperation((r,s,o)=>{if(null==r.previousIndex)i.createEmbeddedView(this._template,new gz(r.item,this._ngForOf,-1,-1),null===o?void 0:o);else if(null==o)i.remove(null===s?void 0:s);else if(null!==s){const a=i.get(s);i.move(a,o),C3(a,r)}});for(let r=0,s=i.length;r{C3(i.get(r.currentIndex),r)})}static ngTemplateContextGuard(t,i){return!0}}return n.\u0275fac=function(t){return new(t||n)(ie(Sa),ie(al),ie($1))},n.\u0275dir=ut({type:n,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"},standalone:!0}),n})();function C3(n,e){n.context.$implicit=e.item}let Yu=(()=>{class n{constructor(t,i){this._viewContainer=t,this._context=new vz,this._thenTemplateRef=null,this._elseTemplateRef=null,this._thenViewRef=null,this._elseViewRef=null,this._thenTemplateRef=i}set ngIf(t){this._context.$implicit=this._context.ngIf=t,this._updateView()}set ngIfThen(t){D3("ngIfThen",t),this._thenTemplateRef=t,this._thenViewRef=null,this._updateView()}set ngIfElse(t){D3("ngIfElse",t),this._elseTemplateRef=t,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(t,i){return!0}}return n.\u0275fac=function(t){return new(t||n)(ie(Sa),ie(al))},n.\u0275dir=ut({type:n,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"},standalone:!0}),n})();class vz{constructor(){this.$implicit=null,this.ngIf=null}}function D3(n,e){if(e&&!e.createEmbeddedView)throw new Error(`${n} must be a TemplateRef, but received '${ki(e)}'.`)}class LD{constructor(e,t){this._viewContainerRef=e,this._templateRef=t,this._created=!1}create(){this._created=!0,this._viewContainerRef.createEmbeddedView(this._templateRef)}destroy(){this._created=!1,this._viewContainerRef.clear()}enforceState(e){e&&!this._created?this.create():!e&&this._created&&this.destroy()}}let Tv=(()=>{class n{constructor(){this._defaultViews=[],this._defaultUsed=!1,this._caseCount=0,this._lastCaseCheckIndex=0,this._lastCasesMatched=!1}set ngSwitch(t){this._ngSwitch=t,0===this._caseCount&&this._updateDefaultCases(!0)}_addCase(){return this._caseCount++}_addDefault(t){this._defaultViews.push(t)}_matchCase(t){const i=t==this._ngSwitch;return this._lastCasesMatched=this._lastCasesMatched||i,this._lastCaseCheckIndex++,this._lastCaseCheckIndex===this._caseCount&&(this._updateDefaultCases(!this._lastCasesMatched),this._lastCaseCheckIndex=0,this._lastCasesMatched=!1),i}_updateDefaultCases(t){if(this._defaultViews.length>0&&t!==this._defaultUsed){this._defaultUsed=t;for(const i of this._defaultViews)i.enforceState(t)}}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["","ngSwitch",""]],inputs:{ngSwitch:"ngSwitch"},standalone:!0}),n})(),ND=(()=>{class n{constructor(t,i,r){this.ngSwitch=r,r._addCase(),this._view=new LD(t,i)}ngDoCheck(){this._view.enforceState(this.ngSwitch._matchCase(this.ngSwitchCase))}}return n.\u0275fac=function(t){return new(t||n)(ie(Sa),ie(al),ie(Tv,9))},n.\u0275dir=ut({type:n,selectors:[["","ngSwitchCase",""]],inputs:{ngSwitchCase:"ngSwitchCase"},standalone:!0}),n})(),T3=(()=>{class n{constructor(t,i,r){r._addDefault(new LD(t,i))}}return n.\u0275fac=function(t){return new(t||n)(ie(Sa),ie(al),ie(Tv,9))},n.\u0275dir=ut({type:n,selectors:[["","ngSwitchDefault",""]],standalone:!0}),n})(),nw=(()=>{class n{constructor(t,i,r){this._ngEl=t,this._differs=i,this._renderer=r,this._ngStyle=null,this._differ=null}set ngStyle(t){this._ngStyle=t,!this._differ&&t&&(this._differ=this._differs.find(t).create())}ngDoCheck(){if(this._differ){const t=this._differ.diff(this._ngStyle);t&&this._applyChanges(t)}}_setStyle(t,i){const[r,s]=t.split("."),o=-1===r.indexOf("-")?void 0:Js.DashCase;null!=i?this._renderer.setStyle(this._ngEl.nativeElement,r,s?`${i}${s}`:i,o):this._renderer.removeStyle(this._ngEl.nativeElement,r,o)}_applyChanges(t){t.forEachRemovedItem(i=>this._setStyle(i.key,null)),t.forEachAddedItem(i=>this._setStyle(i.key,i.currentValue)),t.forEachChangedItem(i=>this._setStyle(i.key,i.currentValue))}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Ev),ie(el))},n.\u0275dir=ut({type:n,selectors:[["","ngStyle",""]],inputs:{ngStyle:"ngStyle"},standalone:!0}),n})(),BD=(()=>{class n{constructor(t){this._viewContainerRef=t,this._viewRef=null,this.ngTemplateOutletContext=null,this.ngTemplateOutlet=null,this.ngTemplateOutletInjector=null}ngOnChanges(t){if(t.ngTemplateOutlet||t.ngTemplateOutletInjector){const i=this._viewContainerRef;if(this._viewRef&&i.remove(i.indexOf(this._viewRef)),this.ngTemplateOutlet){const{ngTemplateOutlet:r,ngTemplateOutletContext:s,ngTemplateOutletInjector:o}=this;this._viewRef=i.createEmbeddedView(r,s,o?{injector:o}:void 0)}else this._viewRef=null}else this._viewRef&&t.ngTemplateOutletContext&&this.ngTemplateOutletContext&&(this._viewRef.context=this.ngTemplateOutletContext)}}return n.\u0275fac=function(t){return new(t||n)(ie(Sa))},n.\u0275dir=ut({type:n,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet",ngTemplateOutletInjector:"ngTemplateOutletInjector"},standalone:!0,features:[Cn]}),n})();function dl(n,e){return new Ue(2100,!1)}class bz{createSubscription(e,t){return e.subscribe({next:t,error:i=>{throw i}})}dispose(e){e.unsubscribe()}}class xz{createSubscription(e,t){return e.then(t,i=>{throw i})}dispose(e){}}const wz=new xz,Sz=new bz;let Rf=(()=>{class n{constructor(t){this._latestValue=null,this._subscription=null,this._obj=null,this._strategy=null,this._ref=t}ngOnDestroy(){this._subscription&&this._dispose(),this._ref=null}transform(t){return this._obj?t!==this._obj?(this._dispose(),this.transform(t)):this._latestValue:(t&&this._subscribe(t),this._latestValue)}_subscribe(t){this._obj=t,this._strategy=this._selectStrategy(t),this._subscription=this._strategy.createSubscription(t,i=>this._updateLatestValue(t,i))}_selectStrategy(t){if(lv(t))return wz;if(kF(t))return Sz;throw dl()}_dispose(){this._strategy.dispose(this._subscription),this._latestValue=null,this._subscription=null,this._obj=null}_updateLatestValue(t,i){t===this._obj&&(this._latestValue=i,this._ref.markForCheck())}}return n.\u0275fac=function(t){return new(t||n)(ie(aa,16))},n.\u0275pipe=Yi({name:"async",type:n,pure:!1,standalone:!0}),n})();const Az=new Ze("DATE_PIPE_DEFAULT_TIMEZONE"),kz=new Ze("DATE_PIPE_DEFAULT_OPTIONS");let k3=(()=>{class n{constructor(t,i,r){this.locale=t,this.defaultTimezone=i,this.defaultOptions=r}transform(t,i,r,s){if(null==t||""===t||t!=t)return null;try{return DD(t,i??this.defaultOptions?.dateFormat??"mediumDate",s||this.locale,r??this.defaultOptions?.timezone??this.defaultTimezone??void 0)}catch(o){throw dl()}}}return n.\u0275fac=function(t){return new(t||n)(ie(Ac,16),ie(Az,24),ie(kz,24))},n.\u0275pipe=Yi({name:"date",type:n,pure:!0,standalone:!0}),n})(),ul=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})();const F3="browser";let jz=(()=>{class n{}return n.\u0275prov=Je({token:n,providedIn:"root",factory:()=>new Wz(xe(Mn),window)}),n})();class Wz{constructor(e,t){this.document=e,this.window=t,this.offset=()=>[0,0]}setOffset(e){this.offset=Array.isArray(e)?()=>e:e}getScrollPosition(){return this.supportsScrolling()?[this.window.pageXOffset,this.window.pageYOffset]:[0,0]}scrollToPosition(e){this.supportsScrolling()&&this.window.scrollTo(e[0],e[1])}scrollToAnchor(e){if(!this.supportsScrolling())return;const t=function $z(n,e){const t=n.getElementById(e)||n.getElementsByName(e)[0];if(t)return t;if("function"==typeof n.createTreeWalker&&n.body&&(n.body.createShadowRoot||n.body.attachShadow)){const i=n.createTreeWalker(n.body,NodeFilter.SHOW_ELEMENT);let r=i.currentNode;for(;r;){const s=r.shadowRoot;if(s){const o=s.getElementById(e)||s.querySelector(`[name="${e}"]`);if(o)return o}r=i.nextNode()}}return null}(this.document,e);t&&(this.scrollToElement(t),t.focus())}setHistoryScrollRestoration(e){if(this.supportScrollRestoration()){const t=this.window.history;t&&t.scrollRestoration&&(t.scrollRestoration=e)}}scrollToElement(e){const t=e.getBoundingClientRect(),i=t.left+this.window.pageXOffset,r=t.top+this.window.pageYOffset,s=this.offset();this.window.scrollTo(i-s[0],r-s[1])}supportScrollRestoration(){try{if(!this.supportsScrolling())return!1;const e=R3(this.window.history)||R3(Object.getPrototypeOf(this.window.history));return!(!e||!e.writable&&!e.set)}catch{return!1}}supportsScrolling(){try{return!!this.window&&!!this.window.scrollTo&&"pageXOffset"in this.window}catch{return!1}}}function R3(n){return Object.getOwnPropertyDescriptor(n,"scrollRestoration")}class P3{}class yG extends C7{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class GD extends yG{static makeCurrent(){!function M7(n){wD||(wD=n)}(new GD)}onAndCancel(e,t,i){return e.addEventListener(t,i,!1),()=>{e.removeEventListener(t,i,!1)}}dispatchEvent(e,t){e.dispatchEvent(t)}remove(e){e.parentNode&&e.parentNode.removeChild(e)}createElement(e,t){return(t=t||this.getDefaultDocument()).createElement(e)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(e){return e.nodeType===Node.ELEMENT_NODE}isShadowRoot(e){return e instanceof DocumentFragment}getGlobalEventTarget(e,t){return"window"===t?window:"document"===t?e:"body"===t?e.body:null}getBaseHref(e){const t=function bG(){return kv=kv||document.querySelector("base"),kv?kv.getAttribute("href"):null}();return null==t?null:function xG(n){sw=sw||document.createElement("a"),sw.setAttribute("href",n);const e=sw.pathname;return"/"===e.charAt(0)?e:`/${e}`}(t)}resetBaseElement(){kv=null}getUserAgent(){return window.navigator.userAgent}getCookie(e){return w3(document.cookie,e)}}let sw,kv=null;const V3=new Ze("TRANSITION_ID"),SG=[{provide:V1,useFactory:function wG(n,e,t){return()=>{t.get(H1).donePromise.then(()=>{const i=Nd(),r=e.querySelectorAll(`style[ng-transition="${n}"]`);for(let s=0;s{class n{build(){return new XMLHttpRequest}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const ow=new Ze("EventManagerPlugins");let aw=(()=>{class n{constructor(t,i){this._zone=i,this._eventNameToPlugin=new Map,t.forEach(r=>r.manager=this),this._plugins=t.slice().reverse()}addEventListener(t,i,r){return this._findPluginFor(i).addEventListener(t,i,r)}addGlobalEventListener(t,i,r){return this._findPluginFor(i).addGlobalEventListener(t,i,r)}getZone(){return this._zone}_findPluginFor(t){const i=this._eventNameToPlugin.get(t);if(i)return i;const r=this._plugins;for(let s=0;s{class n{constructor(){this.usageCount=new Map}addStyles(t){for(const i of t)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(t){for(const i of t)0===this.changeUsageCount(i,-1)&&this.onStyleRemoved(i)}onStyleRemoved(t){}onStyleAdded(t){}getAllStyles(){return this.usageCount.keys()}changeUsageCount(t,i){const r=this.usageCount;let s=r.get(t)??0;return s+=i,s>0?r.set(t,s):r.delete(t),s}ngOnDestroy(){for(const t of this.getAllStyles())this.onStyleRemoved(t);this.usageCount.clear()}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),Iv=(()=>{class n extends U3{constructor(t){super(),this.doc=t,this.styleRef=new Map,this.hostNodes=new Set,this.resetHostNodes()}onStyleAdded(t){for(const i of this.hostNodes)this.addStyleToHost(i,t)}onStyleRemoved(t){const i=this.styleRef;i.get(t)?.forEach(s=>s.remove()),i.delete(t)}ngOnDestroy(){super.ngOnDestroy(),this.styleRef.clear(),this.resetHostNodes()}addHost(t){this.hostNodes.add(t);for(const i of this.getAllStyles())this.addStyleToHost(t,i)}removeHost(t){this.hostNodes.delete(t)}addStyleToHost(t,i){const r=this.doc.createElement("style");r.textContent=i,t.appendChild(r);const s=this.styleRef.get(i);s?s.push(r):this.styleRef.set(i,[r])}resetHostNodes(){const t=this.hostNodes;t.clear(),t.add(this.doc.head)}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const jD={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/"},WD=/%COMP%/g,j3=new Ze("RemoveStylesOnCompDestory",{providedIn:"root",factory:()=>!1});function W3(n,e){return e.flat(100).map(t=>t.replace(WD,n))}function $3(n){return e=>{if("__ngUnwrap__"===e)return n;!1===n(e)&&(e.preventDefault(),e.returnValue=!1)}}let cw=(()=>{class n{constructor(t,i,r,s){this.eventManager=t,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestory=s,this.rendererByCompId=new Map,this.defaultRenderer=new $D(t)}createRenderer(t,i){if(!t||!i)return this.defaultRenderer;const r=this.getOrCreateRenderer(t,i);return r instanceof Y3?r.applyToHost(t):r instanceof qD&&r.applyStyles(),r}getOrCreateRenderer(t,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.eventManager,a=this.sharedStylesHost,c=this.removeStylesOnCompDestory;switch(i.encapsulation){case Ko.Emulated:s=new Y3(o,a,i,this.appId,c);break;case Ko.ShadowDom:return new FG(o,a,t,i);default:s=new qD(o,a,i,c)}s.onDestroy=()=>r.delete(i.id),r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}begin(){}end(){}}return n.\u0275fac=function(t){return new(t||n)(xe(aw),xe(Iv),xe(Zm),xe(j3))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class $D{constructor(e){this.eventManager=e,this.data=Object.create(null),this.destroyNode=null}destroy(){}createElement(e,t){return t?document.createElementNS(jD[t]||t,e):document.createElement(e)}createComment(e){return document.createComment(e)}createText(e){return document.createTextNode(e)}appendChild(e,t){(K3(e)?e.content:e).appendChild(t)}insertBefore(e,t,i){e&&(K3(e)?e.content:e).insertBefore(t,i)}removeChild(e,t){e&&e.removeChild(t)}selectRootElement(e,t){let i="string"==typeof e?document.querySelector(e):e;if(!i)throw new Error(`The selector "${e}" did not match any elements`);return t||(i.textContent=""),i}parentNode(e){return e.parentNode}nextSibling(e){return e.nextSibling}setAttribute(e,t,i,r){if(r){t=r+":"+t;const s=jD[r];s?e.setAttributeNS(s,t,i):e.setAttribute(t,i)}else e.setAttribute(t,i)}removeAttribute(e,t,i){if(i){const r=jD[i];r?e.removeAttributeNS(r,t):e.removeAttribute(`${i}:${t}`)}else e.removeAttribute(t)}addClass(e,t){e.classList.add(t)}removeClass(e,t){e.classList.remove(t)}setStyle(e,t,i,r){r&(Js.DashCase|Js.Important)?e.style.setProperty(t,i,r&Js.Important?"important":""):e.style[t]=i}removeStyle(e,t,i){i&Js.DashCase?e.style.removeProperty(t):e.style[t]=""}setProperty(e,t,i){e[t]=i}setValue(e,t){e.nodeValue=t}listen(e,t,i){return"string"==typeof e?this.eventManager.addGlobalEventListener(e,t,$3(i)):this.eventManager.addEventListener(e,t,$3(i))}}function K3(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class FG extends $D{constructor(e,t,i,r){super(e),this.sharedStylesHost=t,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const s=W3(r.id,r.styles);for(const o of s){const a=document.createElement("style");a.textContent=o,this.shadowRoot.appendChild(a)}}nodeOrShadowRoot(e){return e===this.hostEl?this.shadowRoot:e}appendChild(e,t){return super.appendChild(this.nodeOrShadowRoot(e),t)}insertBefore(e,t,i){return super.insertBefore(this.nodeOrShadowRoot(e),t,i)}removeChild(e,t){return super.removeChild(this.nodeOrShadowRoot(e),t)}parentNode(e){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(e)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class qD extends $D{constructor(e,t,i,r,s=i.id){super(e),this.sharedStylesHost=t,this.removeStylesOnCompDestory=r,this.rendererUsageCount=0,this.styles=W3(s,i.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 Y3 extends qD{constructor(e,t,i,r,s){const o=r+"-"+i.id;super(e,t,i,s,o),this.contentAttr=function AG(n){return"_ngcontent-%COMP%".replace(WD,n)}(o),this.hostAttr=function kG(n){return"_nghost-%COMP%".replace(WD,n)}(o)}applyToHost(e){this.applyStyles(),this.setAttribute(e,this.hostAttr,"")}createElement(e,t){const i=super.createElement(e,t);return super.setAttribute(i,this.contentAttr,""),i}}let RG=(()=>{class n extends H3{constructor(t){super(t)}supports(t){return!0}addEventListener(t,i,r){return t.addEventListener(i,r,!1),()=>this.removeEventListener(t,i,r)}removeEventListener(t,i,r){return t.removeEventListener(i,r)}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const X3=["alt","control","meta","shift"],PG={"\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"},OG={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let LG=(()=>{class n extends H3{constructor(t){super(t)}supports(t){return null!=n.parseEventName(t)}addEventListener(t,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Nd().onAndCancel(t,s.domEventName,o))}static parseEventName(t){const i=t.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),X3.forEach(u=>{const p=i.indexOf(u);p>-1&&(i.splice(p,1),o+=u+".")}),o+=s,0!=i.length||0===s.length)return null;const c={};return c.domEventName=r,c.fullKey=o,c}static matchEventFullKeyCode(t,i){let r=PG[t.key]||t.key,s="";return i.indexOf("code.")>-1&&(r=t.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),X3.forEach(o=>{o!==r&&(0,OG[o])(t)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(t,i,r){return s=>{n.matchEventFullKeyCode(s,t)&&r.runGuarded(()=>i(s))}}static _normalizeKey(t){return"esc"===t?"escape":t}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const J3=[{provide:U1,useValue:F3},{provide:PP,useValue:function NG(){GD.makeCurrent()},multi:!0},{provide:Mn,useFactory:function VG(){return function lM(n){pm=n}(document),document},deps:[]}],HG=WP(w7,"browser",J3),Q3=new Ze(""),eO=[{provide:z1,useClass:class EG{addToWindow(e){Ii.getAngularTestability=(i,r=!0)=>{const s=e.findTestabilityInTree(i,r);if(null==s)throw new Error("Could not find testability for element.");return s},Ii.getAllAngularTestabilities=()=>e.getAllTestabilities(),Ii.getAllAngularRootElements=()=>e.getAllRootElements(),Ii.frameworkStabilizers||(Ii.frameworkStabilizers=[]),Ii.frameworkStabilizers.push(i=>{const r=Ii.getAllAngularTestabilities();let s=r.length,o=!1;const a=function(c){o=o||c,s--,0==s&&i(o)};r.forEach(function(c){c.whenStable(a)})})}findTestabilityInTree(e,t,i){return null==t?null:e.getTestability(t)??(i?Nd().isShadowRoot(t)?this.findTestabilityInTree(e,t.host,!0):this.findTestabilityInTree(e,t.parentElement,!0):null)}},deps:[]},{provide:UP,useClass:fD,deps:[Xt,pD,z1]},{provide:fD,useClass:fD,deps:[Xt,pD,z1]}],tO=[{provide:wm,useValue:"root"},{provide:tl,useFactory:function BG(){return new tl},deps:[]},{provide:ow,useClass:RG,multi:!0,deps:[Mn,Xt,U1]},{provide:ow,useClass:LG,multi:!0,deps:[Mn]},{provide:cw,useClass:cw,deps:[aw,Iv,Zm,j3]},{provide:yn,useExisting:cw},{provide:U3,useExisting:Iv},{provide:Iv,useClass:Iv,deps:[Mn]},{provide:aw,useClass:aw,deps:[ow,Xt]},{provide:P3,useClass:MG,deps:[]},[]];let nO=(()=>{class n{constructor(t){}static withServerTransition(t){return{ngModule:n,providers:[{provide:Zm,useValue:t.appId},{provide:V3,useExisting:Zm},SG]}}}return n.\u0275fac=function(t){return new(t||n)(xe(Q3,12))},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[...tO,...eO],imports:[ul,S7]}),n})(),iO=(()=>{class n{constructor(t){this._doc=t}getTitle(){return this._doc.title}setTitle(t){this._doc.title=t||""}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:function(t){let i=null;return i=t?new t:function zG(){return new iO(xe(Mn))}(),i},providedIn:"root"}),n})();typeof window<"u"&&window;let XD=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(t){let i=null;return i=t?new(t||n):xe(oO),i},providedIn:"root"}),n})(),oO=(()=>{class n extends XD{constructor(t){super(),this._doc=t}sanitize(t,i){if(null==i)return null;switch(t){case Ri.NONE:return i;case Ri.HTML:return Ec(i,"HTML")?ta(i):Ex(this._doc,String(i)).toString();case Ri.STYLE:return Ec(i,"Style")?ta(i):i;case Ri.SCRIPT:if(Ec(i,"Script"))return ta(i);throw new Error("unsafe value used in a script context");case Ri.URL:return Ec(i,"URL")?ta(i):_f(String(i));case Ri.RESOURCE_URL:if(Ec(i,"ResourceURL"))return ta(i);throw new Error(`unsafe value used in a resource URL context (see ${mu})`);default:throw new Error(`Unexpected SecurityContext ${t} (see ${mu})`)}}bypassSecurityTrustHtml(t){return function gM(n){return new dM(n)}(t)}bypassSecurityTrustStyle(t){return function _M(n){return new uM(n)}(t)}bypassSecurityTrustScript(t){return function vM(n){return new hM(n)}(t)}bypassSecurityTrustUrl(t){return function yM(n){return new fM(n)}(t)}bypassSecurityTrustResourceUrl(t){return function bM(n){return new pM(n)}(t)}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:function(t){let i=null;return i=t?new t:function YG(n){return new oO(n.get(Mn))}(xe(ts)),i},providedIn:"root"}),n})();function Tt(...n){let e=n[n.length-1];return cc(e)?(n.pop(),lo(n,e)):uc(n)}function Zu(n,e){return ur(n,e,1)}function Ui(n,e){return function(i){return i.lift(new XG(n,e))}}class XG{constructor(e,t){this.predicate=e,this.thisArg=t}call(e,t){return t.subscribe(new ZG(e,this.predicate,this.thisArg))}}class ZG extends di{constructor(e,t,i){super(e),this.predicate=t,this.thisArg=i,this.count=0}_next(e){let t;try{t=this.predicate.call(this.thisArg,e,this.count++)}catch(i){return void this.destination.error(i)}t&&this.destination.next(e)}}class lw{}class ZD{}class Ho{constructor(e){this.normalizedNames=new Map,this.lazyUpdate=null,e?this.lazyInit="string"==typeof e?()=>{this.headers=new Map,e.split("\n").forEach(t=>{const i=t.indexOf(":");if(i>0){const r=t.slice(0,i),s=r.toLowerCase(),o=t.slice(i+1).trim();this.maybeSetNormalizedName(r,s),this.headers.has(s)?this.headers.get(s).push(o):this.headers.set(s,[o])}})}:()=>{this.headers=new Map,Object.keys(e).forEach(t=>{let i=e[t];const r=t.toLowerCase();"string"==typeof i&&(i=[i]),i.length>0&&(this.headers.set(r,i),this.maybeSetNormalizedName(t,r))})}:this.headers=new Map}has(e){return this.init(),this.headers.has(e.toLowerCase())}get(e){this.init();const t=this.headers.get(e.toLowerCase());return t&&t.length>0?t[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(e){return this.init(),this.headers.get(e.toLowerCase())||null}append(e,t){return this.clone({name:e,value:t,op:"a"})}set(e,t){return this.clone({name:e,value:t,op:"s"})}delete(e,t){return this.clone({name:e,value:t,op:"d"})}maybeSetNormalizedName(e,t){this.normalizedNames.has(t)||this.normalizedNames.set(t,e)}init(){this.lazyInit&&(this.lazyInit instanceof Ho?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(e=>this.applyUpdate(e)),this.lazyUpdate=null))}copyFrom(e){e.init(),Array.from(e.headers.keys()).forEach(t=>{this.headers.set(t,e.headers.get(t)),this.normalizedNames.set(t,e.normalizedNames.get(t))})}clone(e){const t=new Ho;return t.lazyInit=this.lazyInit&&this.lazyInit instanceof Ho?this.lazyInit:this,t.lazyUpdate=(this.lazyUpdate||[]).concat([e]),t}applyUpdate(e){const t=e.name.toLowerCase();switch(e.op){case"a":case"s":let i=e.value;if("string"==typeof i&&(i=[i]),0===i.length)return;this.maybeSetNormalizedName(e.name,t);const r=("a"===e.op?this.headers.get(t):void 0)||[];r.push(...i),this.headers.set(t,r);break;case"d":const s=e.value;if(s){let o=this.headers.get(t);if(!o)return;o=o.filter(a=>-1===s.indexOf(a)),0===o.length?(this.headers.delete(t),this.normalizedNames.delete(t)):this.headers.set(t,o)}else this.headers.delete(t),this.normalizedNames.delete(t)}}forEach(e){this.init(),Array.from(this.normalizedNames.keys()).forEach(t=>e(this.normalizedNames.get(t),this.headers.get(t)))}}class JG{encodeKey(e){return aO(e)}encodeValue(e){return aO(e)}decodeKey(e){return decodeURIComponent(e)}decodeValue(e){return decodeURIComponent(e)}}const ej=/%(\d[a-f0-9])/gi,tj={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function aO(n){return encodeURIComponent(n).replace(ej,(e,t)=>tj[t]??e)}function dw(n){return`${n}`}class Za{constructor(e={}){if(this.updates=null,this.cloneFrom=null,this.encoder=e.encoder||new JG,e.fromString){if(e.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=function QG(n,e){const t=new Map;return n.length>0&&n.replace(/^\?/,"").split("&").forEach(r=>{const s=r.indexOf("="),[o,a]=-1==s?[e.decodeKey(r),""]:[e.decodeKey(r.slice(0,s)),e.decodeValue(r.slice(s+1))],c=t.get(o)||[];c.push(a),t.set(o,c)}),t}(e.fromString,this.encoder)}else e.fromObject?(this.map=new Map,Object.keys(e.fromObject).forEach(t=>{const i=e.fromObject[t],r=Array.isArray(i)?i.map(dw):[dw(i)];this.map.set(t,r)})):this.map=null}has(e){return this.init(),this.map.has(e)}get(e){this.init();const t=this.map.get(e);return t?t[0]:null}getAll(e){return this.init(),this.map.get(e)||null}keys(){return this.init(),Array.from(this.map.keys())}append(e,t){return this.clone({param:e,value:t,op:"a"})}appendAll(e){const t=[];return Object.keys(e).forEach(i=>{const r=e[i];Array.isArray(r)?r.forEach(s=>{t.push({param:i,value:s,op:"a"})}):t.push({param:i,value:r,op:"a"})}),this.clone(t)}set(e,t){return this.clone({param:e,value:t,op:"s"})}delete(e,t){return this.clone({param:e,value:t,op:"d"})}toString(){return this.init(),this.keys().map(e=>{const t=this.encoder.encodeKey(e);return this.map.get(e).map(i=>t+"="+this.encoder.encodeValue(i)).join("&")}).filter(e=>""!==e).join("&")}clone(e){const t=new Za({encoder:this.encoder});return t.cloneFrom=this.cloneFrom||this,t.updates=(this.updates||[]).concat(e),t}init(){null===this.map&&(this.map=new Map),null!==this.cloneFrom&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(e=>this.map.set(e,this.cloneFrom.map.get(e))),this.updates.forEach(e=>{switch(e.op){case"a":case"s":const t=("a"===e.op?this.map.get(e.param):void 0)||[];t.push(dw(e.value)),this.map.set(e.param,t);break;case"d":if(void 0===e.value){this.map.delete(e.param);break}{let i=this.map.get(e.param)||[];const r=i.indexOf(dw(e.value));-1!==r&&i.splice(r,1),i.length>0?this.map.set(e.param,i):this.map.delete(e.param)}}}),this.cloneFrom=this.updates=null)}}class nj{constructor(){this.map=new Map}set(e,t){return this.map.set(e,t),this}get(e){return this.map.has(e)||this.map.set(e,e.defaultValue()),this.map.get(e)}delete(e){return this.map.delete(e),this}has(e){return this.map.has(e)}keys(){return this.map.keys()}}function cO(n){return typeof ArrayBuffer<"u"&&n instanceof ArrayBuffer}function lO(n){return typeof Blob<"u"&&n instanceof Blob}function dO(n){return typeof FormData<"u"&&n instanceof FormData}class Fv{constructor(e,t,i,r){let s;if(this.url=t,this.body=null,this.reportProgress=!1,this.withCredentials=!1,this.responseType="json",this.method=e.toUpperCase(),function ij(n){switch(n){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}(this.method)||r?(this.body=void 0!==i?i:null,s=r):s=i,s&&(this.reportProgress=!!s.reportProgress,this.withCredentials=!!s.withCredentials,s.responseType&&(this.responseType=s.responseType),s.headers&&(this.headers=s.headers),s.context&&(this.context=s.context),s.params&&(this.params=s.params)),this.headers||(this.headers=new Ho),this.context||(this.context=new nj),this.params){const o=this.params.toString();if(0===o.length)this.urlWithParams=t;else{const a=t.indexOf("?");this.urlWithParams=t+(-1===a?"?":ag.set(v,e.setHeaders[v]),c)),e.setParams&&(u=Object.keys(e.setParams).reduce((g,v)=>g.set(v,e.setParams[v]),u)),new Fv(t,i,s,{params:u,headers:c,context:p,reportProgress:a,responseType:r,withCredentials:o})}}var Ms=(()=>((Ms=Ms||{})[Ms.Sent=0]="Sent",Ms[Ms.UploadProgress=1]="UploadProgress",Ms[Ms.ResponseHeader=2]="ResponseHeader",Ms[Ms.DownloadProgress=3]="DownloadProgress",Ms[Ms.Response=4]="Response",Ms[Ms.User=5]="User",Ms))();class JD{constructor(e,t=200,i="OK"){this.headers=e.headers||new Ho,this.status=void 0!==e.status?e.status:t,this.statusText=e.statusText||i,this.url=e.url||null,this.ok=this.status>=200&&this.status<300}}class QD extends JD{constructor(e={}){super(e),this.type=Ms.ResponseHeader}clone(e={}){return new QD({headers:e.headers||this.headers,status:void 0!==e.status?e.status:this.status,statusText:e.statusText||this.statusText,url:e.url||this.url||void 0})}}class uw extends JD{constructor(e={}){super(e),this.type=Ms.Response,this.body=void 0!==e.body?e.body:null}clone(e={}){return new uw({body:void 0!==e.body?e.body:this.body,headers:e.headers||this.headers,status:void 0!==e.status?e.status:this.status,statusText:e.statusText||this.statusText,url:e.url||this.url||void 0})}}class uO extends JD{constructor(e){super(e,0,"Unknown Error"),this.name="HttpErrorResponse",this.ok=!1,this.message=this.status>=200&&this.status<300?`Http failure during parsing for ${e.url||"(unknown url)"}`:`Http failure response for ${e.url||"(unknown url)"}: ${e.status} ${e.statusText}`,this.error=e.error||null}}function eT(n,e){return{body:e,headers:n.headers,context:n.context,observe:n.observe,params:n.params,reportProgress:n.reportProgress,responseType:n.responseType,withCredentials:n.withCredentials}}let Ju=(()=>{class n{constructor(t){this.handler=t}request(t,i,r={}){let s;if(t instanceof Fv)s=t;else{let c,u;c=r.headers instanceof Ho?r.headers:new Ho(r.headers),r.params&&(u=r.params instanceof Za?r.params:new Za({fromObject:r.params})),s=new Fv(t,i,void 0!==r.body?r.body:null,{headers:c,context:r.context,params:u,reportProgress:r.reportProgress,responseType:r.responseType||"json",withCredentials:r.withCredentials})}const o=Tt(s).pipe(Zu(c=>this.handler.handle(c)));if(t instanceof Fv||"events"===r.observe)return o;const a=o.pipe(Ui(c=>c instanceof uw));switch(r.observe||"body"){case"body":switch(s.responseType){case"arraybuffer":return a.pipe(_t(c=>{if(null!==c.body&&!(c.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return c.body}));case"blob":return a.pipe(_t(c=>{if(null!==c.body&&!(c.body instanceof Blob))throw new Error("Response is not a Blob.");return c.body}));case"text":return a.pipe(_t(c=>{if(null!==c.body&&"string"!=typeof c.body)throw new Error("Response is not a string.");return c.body}));default:return a.pipe(_t(c=>c.body))}case"response":return a;default:throw new Error(`Unreachable: unhandled observe type ${r.observe}}`)}}delete(t,i={}){return this.request("DELETE",t,i)}get(t,i={}){return this.request("GET",t,i)}head(t,i={}){return this.request("HEAD",t,i)}jsonp(t,i){return this.request("JSONP",t,{params:(new Za).append(i,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(t,i={}){return this.request("OPTIONS",t,i)}patch(t,i,r={}){return this.request("PATCH",t,eT(r,i))}post(t,i,r={}){return this.request("POST",t,eT(r,i))}put(t,i,r={}){return this.request("PUT",t,eT(r,i))}}return n.\u0275fac=function(t){return new(t||n)(xe(lw))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();function hO(n,e){return e(n)}function sj(n,e){return(t,i)=>e.intercept(t,{handle:r=>n(r,i)})}const tT=new Ze("HTTP_INTERCEPTORS"),Rv=new Ze("HTTP_INTERCEPTOR_FNS");function aj(){let n=null;return(e,t)=>(null===n&&(n=(hn(tT,{optional:!0})??[]).reduceRight(sj,hO)),n(e,t))}let fO=(()=>{class n extends lw{constructor(t,i){super(),this.backend=t,this.injector=i,this.chain=null}handle(t){if(null===this.chain){const i=Array.from(new Set(this.injector.get(Rv)));this.chain=i.reduceRight((r,s)=>function oj(n,e,t){return(i,r)=>t.runInContext(()=>e(i,s=>n(s,r)))}(r,s,this.injector),hO)}return this.chain(t,i=>this.backend.handle(i))}}return n.\u0275fac=function(t){return new(t||n)(xe(ZD),xe(na))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const uj=/^\)\]\}',?\n/;let mO=(()=>{class n{constructor(t){this.xhrFactory=t}handle(t){if("JSONP"===t.method)throw new Error("Attempted to construct Jsonp request without HttpClientJsonpModule installed.");return new un(i=>{const r=this.xhrFactory.build();if(r.open(t.method,t.urlWithParams),t.withCredentials&&(r.withCredentials=!0),t.headers.forEach((y,x)=>r.setRequestHeader(y,x.join(","))),t.headers.has("Accept")||r.setRequestHeader("Accept","application/json, text/plain, */*"),!t.headers.has("Content-Type")){const y=t.detectContentTypeHeader();null!==y&&r.setRequestHeader("Content-Type",y)}if(t.responseType){const y=t.responseType.toLowerCase();r.responseType="json"!==y?y:"text"}const s=t.serializeBody();let o=null;const a=()=>{if(null!==o)return o;const y=r.statusText||"OK",x=new Ho(r.getAllResponseHeaders()),T=function hj(n){return"responseURL"in n&&n.responseURL?n.responseURL:/^X-Request-URL:/m.test(n.getAllResponseHeaders())?n.getResponseHeader("X-Request-URL"):null}(r)||t.url;return o=new QD({headers:x,status:r.status,statusText:y,url:T}),o},c=()=>{let{headers:y,status:x,statusText:T,url:N}=a(),k=null;204!==x&&(k=typeof r.response>"u"?r.responseText:r.response),0===x&&(x=k?200:0);let A=x>=200&&x<300;if("json"===t.responseType&&"string"==typeof k){const H=k;k=k.replace(uj,"");try{k=""!==k?JSON.parse(k):null}catch(G){k=H,A&&(A=!1,k={error:G,text:k})}}A?(i.next(new uw({body:k,headers:y,status:x,statusText:T,url:N||void 0})),i.complete()):i.error(new uO({error:k,headers:y,status:x,statusText:T,url:N||void 0}))},u=y=>{const{url:x}=a(),T=new uO({error:y,status:r.status||0,statusText:r.statusText||"Unknown Error",url:x||void 0});i.error(T)};let p=!1;const g=y=>{p||(i.next(a()),p=!0);let x={type:Ms.DownloadProgress,loaded:y.loaded};y.lengthComputable&&(x.total=y.total),"text"===t.responseType&&r.responseText&&(x.partialText=r.responseText),i.next(x)},v=y=>{let x={type:Ms.UploadProgress,loaded:y.loaded};y.lengthComputable&&(x.total=y.total),i.next(x)};return r.addEventListener("load",c),r.addEventListener("error",u),r.addEventListener("timeout",u),r.addEventListener("abort",u),t.reportProgress&&(r.addEventListener("progress",g),null!==s&&r.upload&&r.upload.addEventListener("progress",v)),r.send(s),i.next({type:Ms.Sent}),()=>{r.removeEventListener("error",u),r.removeEventListener("abort",u),r.removeEventListener("load",c),r.removeEventListener("timeout",u),t.reportProgress&&(r.removeEventListener("progress",g),null!==s&&r.upload&&r.upload.removeEventListener("progress",v)),r.readyState!==r.DONE&&r.abort()}})}}return n.\u0275fac=function(t){return new(t||n)(xe(P3))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const nT=new Ze("XSRF_ENABLED"),gO=new Ze("XSRF_COOKIE_NAME",{providedIn:"root",factory:()=>"XSRF-TOKEN"}),_O=new Ze("XSRF_HEADER_NAME",{providedIn:"root",factory:()=>"X-XSRF-TOKEN"});class vO{}let mj=(()=>{class n{constructor(t,i,r){this.doc=t,this.platform=i,this.cookieName=r,this.lastCookieString="",this.lastToken=null,this.parseCount=0}getToken(){if("server"===this.platform)return null;const t=this.doc.cookie||"";return t!==this.lastCookieString&&(this.parseCount++,this.lastToken=w3(t,this.cookieName),this.lastCookieString=t),this.lastToken}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn),xe(U1),xe(gO))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();function gj(n,e){const t=n.url.toLowerCase();if(!hn(nT)||"GET"===n.method||"HEAD"===n.method||t.startsWith("http://")||t.startsWith("https://"))return e(n);const i=hn(vO).getToken(),r=hn(_O);return null!=i&&!n.headers.has(r)&&(n=n.clone({headers:n.headers.set(r,i)})),e(n)}var os=(()=>((os=os||{})[os.Interceptors=0]="Interceptors",os[os.LegacyInterceptors=1]="LegacyInterceptors",os[os.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",os[os.NoXsrfProtection=3]="NoXsrfProtection",os[os.JsonpSupport=4]="JsonpSupport",os[os.RequestsMadeViaParent=5]="RequestsMadeViaParent",os))();function ng(n,e){return{\u0275kind:n,\u0275providers:e}}function _j(...n){const e=[Ju,mO,fO,{provide:lw,useExisting:fO},{provide:ZD,useExisting:mO},{provide:Rv,useValue:gj,multi:!0},{provide:nT,useValue:!0},{provide:vO,useClass:mj}];for(const t of n)e.push(...t.\u0275providers);return Fx(e)}const yO=new Ze("LEGACY_INTERCEPTOR_FN");let yj=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[_j(ng(os.LegacyInterceptors,[{provide:yO,useFactory:aj},{provide:Rv,useExisting:yO,multi:!0}]))]}),n})();function ig(...n){if(1===n.length){const e=n[0];if(_i(e))return hw(e,null);if(ao(e)&&Object.getPrototypeOf(e)===Object.prototype){const t=Object.keys(e);return hw(t.map(i=>e[i]),t)}}if("function"==typeof n[n.length-1]){const e=n.pop();return hw(n=1===n.length&&_i(n[0])?n[0]:n,null).pipe(_t(t=>e(...t)))}return hw(n,null)}function hw(n,e){return new un(t=>{const i=n.length;if(0===i)return void t.complete();const r=new Array(i);let s=0,o=0;for(let a=0;a{u||(u=!0,o++),r[a]=p},error:p=>t.error(p),complete:()=>{s++,(s===i||!u)&&(o===i&&t.next(e?e.reduce((p,g,v)=>(p[g]=r[v],p),{}):r),t.complete())}}))}})}let bO=(()=>{class n{constructor(t,i){this._renderer=t,this._elementRef=i,this.onChange=r=>{},this.onTouched=()=>{}}setProperty(t,i){this._renderer.setProperty(this._elementRef.nativeElement,t,i)}registerOnTouched(t){this.onTouched=t}registerOnChange(t){this.onChange=t}setDisabledState(t){this.setProperty("disabled",t)}}return n.\u0275fac=function(t){return new(t||n)(ie(el),ie(_n))},n.\u0275dir=ut({type:n}),n})(),Pf=(()=>{class n extends bO{}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275dir=ut({type:n,features:[Z]}),n})();const Ja=new Ze("NgValueAccessor"),xj={provide:Ja,useExisting:Mi(()=>iT),multi:!0},Sj=new Ze("CompositionEventMode");let iT=(()=>{class n extends bO{constructor(t,i,r){super(t,i),this._compositionMode=r,this._composing=!1,null==this._compositionMode&&(this._compositionMode=!function wj(){const n=Nd()?Nd().getUserAgent():"";return/android (\d+)/.test(n.toLowerCase())}())}writeValue(t){this.setProperty("value",t??"")}_handleInput(t){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(t)}_compositionStart(){this._composing=!0}_compositionEnd(t){this._composing=!1,this._compositionMode&&this.onChange(t)}}return n.\u0275fac=function(t){return new(t||n)(ie(el),ie(_n),ie(Sj,8))},n.\u0275dir=ut({type:n,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(t,i){1&t&&Gn("input",function(s){return i._handleInput(s.target.value)})("blur",function(){return i.onTouched()})("compositionstart",function(){return i._compositionStart()})("compositionend",function(s){return i._compositionEnd(s.target.value)})},features:[Oi([xj]),Z]}),n})();const Ej=!1;function Qu(n){return null==n||("string"==typeof n||Array.isArray(n))&&0===n.length}function wO(n){return null!=n&&"number"==typeof n.length}const xo=new Ze("NgValidators"),eh=new Ze("NgAsyncValidators"),Mj=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;class Cj{static min(e){return function SO(n){return e=>{if(Qu(e.value)||Qu(n))return null;const t=parseFloat(e.value);return!isNaN(t)&&t{if(Qu(e.value)||Qu(n))return null;const t=parseFloat(e.value);return!isNaN(t)&&t>n?{max:{max:n,actual:e.value}}:null}}(e)}static required(e){return function MO(n){return Qu(n.value)?{required:!0}:null}(e)}static requiredTrue(e){return function CO(n){return!0===n.value?null:{required:!0}}(e)}static email(e){return function DO(n){return Qu(n.value)||Mj.test(n.value)?null:{email:!0}}(e)}static minLength(e){return function TO(n){return e=>Qu(e.value)||!wO(e.value)?null:e.value.lengthwO(e.value)&&e.value.length>n?{maxlength:{requiredLength:n,actualLength:e.value.length}}:null}(e)}static pattern(e){return function kO(n){if(!n)return fw;let e,t;return"string"==typeof n?(t="","^"!==n.charAt(0)&&(t+="^"),t+=n,"$"!==n.charAt(n.length-1)&&(t+="$"),e=new RegExp(t)):(t=n.toString(),e=n),i=>{if(Qu(i.value))return null;const r=i.value;return e.test(r)?null:{pattern:{requiredPattern:t,actualValue:r}}}}(e)}static nullValidator(e){return null}static compose(e){return LO(e)}static composeAsync(e){return NO(e)}}function fw(n){return null}function IO(n){return null!=n}function FO(n){const e=lv(n)?dr(n):n;if(Ej&&!PC(e)){let t="Expected async validator to return Promise or Observable.";throw"object"==typeof n&&(t+=" Are you using a synchronous validator where an async validator is expected?"),new Ue(-1101,t)}return e}function RO(n){let e={};return n.forEach(t=>{e=null!=t?{...e,...t}:e}),0===Object.keys(e).length?null:e}function PO(n,e){return e.map(t=>t(n))}function OO(n){return n.map(e=>function Dj(n){return!n.validate}(e)?e:t=>e.validate(t))}function LO(n){if(!n)return null;const e=n.filter(IO);return 0==e.length?null:function(t){return RO(PO(t,e))}}function rT(n){return null!=n?LO(OO(n)):null}function NO(n){if(!n)return null;const e=n.filter(IO);return 0==e.length?null:function(t){return ig(PO(t,e).map(FO)).pipe(_t(RO))}}function sT(n){return null!=n?NO(OO(n)):null}function BO(n,e){return null===n?[e]:Array.isArray(n)?[...n,e]:[n,e]}function VO(n){return n._rawValidators}function HO(n){return n._rawAsyncValidators}function oT(n){return n?Array.isArray(n)?n:[n]:[]}function pw(n,e){return Array.isArray(n)?n.includes(e):n===e}function UO(n,e){const t=oT(e);return oT(n).forEach(r=>{pw(t,r)||t.push(r)}),t}function zO(n,e){return oT(e).filter(t=>!pw(n,t))}class GO{constructor(){this._rawValidators=[],this._rawAsyncValidators=[],this._onDestroyCallbacks=[]}get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_setValidators(e){this._rawValidators=e||[],this._composedValidatorFn=rT(this._rawValidators)}_setAsyncValidators(e){this._rawAsyncValidators=e||[],this._composedAsyncValidatorFn=sT(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_registerOnDestroy(e){this._onDestroyCallbacks.push(e)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(e=>e()),this._onDestroyCallbacks=[]}reset(e){this.control&&this.control.reset(e)}hasError(e,t){return!!this.control&&this.control.hasError(e,t)}getError(e,t){return this.control?this.control.getError(e,t):null}}class ca extends GO{get formDirective(){return null}get path(){return null}}class Hd extends GO{constructor(){super(...arguments),this._parent=null,this.name=null,this.valueAccessor=null}}class jO{constructor(e){this._cd=e}get isTouched(){return!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return!!this._cd?.submitted}}let aT=(()=>{class n extends jO{constructor(t){super(t)}}return n.\u0275fac=function(t){return new(t||n)(ie(Hd,2))},n.\u0275dir=ut({type:n,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(t,i){2&t&&hi("ng-untouched",i.isUntouched)("ng-touched",i.isTouched)("ng-pristine",i.isPristine)("ng-dirty",i.isDirty)("ng-valid",i.isValid)("ng-invalid",i.isInvalid)("ng-pending",i.isPending)},features:[Z]}),n})();function WO(n,e){return n?`with name: '${e}'`:`at index: ${e}`}const dT=!1,Pv="VALID",gw="INVALID",rg="PENDING",Ov="DISABLED";function uT(n){return(_w(n)?n.validators:n)||null}function hT(n,e){return(_w(e)?e.asyncValidators:n)||null}function _w(n){return null!=n&&!Array.isArray(n)&&"object"==typeof n}class KO{constructor(e,t){this._pendingDirty=!1,this._hasOwnPendingAsyncValidator=!1,this._pendingTouched=!1,this._onCollectionChange=()=>{},this._parent=null,this.pristine=!0,this.touched=!1,this._onDisabledChange=[],this._assignValidators(e),this._assignAsyncValidators(t)}get validator(){return this._composedValidatorFn}set validator(e){this._rawValidators=this._composedValidatorFn=e}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(e){this._rawAsyncValidators=this._composedAsyncValidatorFn=e}get parent(){return this._parent}get valid(){return this.status===Pv}get invalid(){return this.status===gw}get pending(){return this.status==rg}get disabled(){return this.status===Ov}get enabled(){return this.status!==Ov}get dirty(){return!this.pristine}get untouched(){return!this.touched}get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(e){this._assignValidators(e)}setAsyncValidators(e){this._assignAsyncValidators(e)}addValidators(e){this.setValidators(UO(e,this._rawValidators))}addAsyncValidators(e){this.setAsyncValidators(UO(e,this._rawAsyncValidators))}removeValidators(e){this.setValidators(zO(e,this._rawValidators))}removeAsyncValidators(e){this.setAsyncValidators(zO(e,this._rawAsyncValidators))}hasValidator(e){return pw(this._rawValidators,e)}hasAsyncValidator(e){return pw(this._rawAsyncValidators,e)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(e={}){this.touched=!0,this._parent&&!e.onlySelf&&this._parent.markAsTouched(e)}markAllAsTouched(){this.markAsTouched({onlySelf:!0}),this._forEachChild(e=>e.markAllAsTouched())}markAsUntouched(e={}){this.touched=!1,this._pendingTouched=!1,this._forEachChild(t=>{t.markAsUntouched({onlySelf:!0})}),this._parent&&!e.onlySelf&&this._parent._updateTouched(e)}markAsDirty(e={}){this.pristine=!1,this._parent&&!e.onlySelf&&this._parent.markAsDirty(e)}markAsPristine(e={}){this.pristine=!0,this._pendingDirty=!1,this._forEachChild(t=>{t.markAsPristine({onlySelf:!0})}),this._parent&&!e.onlySelf&&this._parent._updatePristine(e)}markAsPending(e={}){this.status=rg,!1!==e.emitEvent&&this.statusChanges.emit(this.status),this._parent&&!e.onlySelf&&this._parent.markAsPending(e)}disable(e={}){const t=this._parentMarkedDirty(e.onlySelf);this.status=Ov,this.errors=null,this._forEachChild(i=>{i.disable({...e,onlySelf:!0})}),this._updateValue(),!1!==e.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors({...e,skipPristineCheck:t}),this._onDisabledChange.forEach(i=>i(!0))}enable(e={}){const t=this._parentMarkedDirty(e.onlySelf);this.status=Pv,this._forEachChild(i=>{i.enable({...e,onlySelf:!0})}),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent}),this._updateAncestors({...e,skipPristineCheck:t}),this._onDisabledChange.forEach(i=>i(!1))}_updateAncestors(e){this._parent&&!e.onlySelf&&(this._parent.updateValueAndValidity(e),e.skipPristineCheck||this._parent._updatePristine(),this._parent._updateTouched())}setParent(e){this._parent=e}getRawValue(){return this.value}updateValueAndValidity(e={}){this._setInitialStatus(),this._updateValue(),this.enabled&&(this._cancelExistingSubscription(),this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===Pv||this.status===rg)&&this._runAsyncValidator(e.emitEvent)),!1!==e.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!e.onlySelf&&this._parent.updateValueAndValidity(e)}_updateTreeValidity(e={emitEvent:!0}){this._forEachChild(t=>t._updateTreeValidity(e)),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?Ov:Pv}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(e){if(this.asyncValidator){this.status=rg,this._hasOwnPendingAsyncValidator=!0;const t=FO(this.asyncValidator(this));this._asyncValidationSubscription=t.subscribe(i=>{this._hasOwnPendingAsyncValidator=!1,this.setErrors(i,{emitEvent:e})})}}_cancelExistingSubscription(){this._asyncValidationSubscription&&(this._asyncValidationSubscription.unsubscribe(),this._hasOwnPendingAsyncValidator=!1)}setErrors(e,t={}){this.errors=e,this._updateControlsErrors(!1!==t.emitEvent)}get(e){let t=e;return null==t||(Array.isArray(t)||(t=t.split(".")),0===t.length)?null:t.reduce((i,r)=>i&&i._find(r),this)}getError(e,t){const i=t?this.get(t):this;return i&&i.errors?i.errors[e]:null}hasError(e,t){return!!this.getError(e,t)}get root(){let e=this;for(;e._parent;)e=e._parent;return e}_updateControlsErrors(e){this.status=this._calculateStatus(),e&&this.statusChanges.emit(this.status),this._parent&&this._parent._updateControlsErrors(e)}_initObservables(){this.valueChanges=new Pn,this.statusChanges=new Pn}_calculateStatus(){return this._allControlsDisabled()?Ov:this.errors?gw:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(rg)?rg:this._anyControlsHaveStatus(gw)?gw:Pv}_anyControlsHaveStatus(e){return this._anyControls(t=>t.status===e)}_anyControlsDirty(){return this._anyControls(e=>e.dirty)}_anyControlsTouched(){return this._anyControls(e=>e.touched)}_updatePristine(e={}){this.pristine=!this._anyControlsDirty(),this._parent&&!e.onlySelf&&this._parent._updatePristine(e)}_updateTouched(e={}){this.touched=this._anyControlsTouched(),this._parent&&!e.onlySelf&&this._parent._updateTouched(e)}_registerOnCollectionChange(e){this._onCollectionChange=e}_setUpdateStrategy(e){_w(e)&&null!=e.updateOn&&(this._updateOn=e.updateOn)}_parentMarkedDirty(e){return!e&&!(!this._parent||!this._parent.dirty)&&!this._parent._anyControlsDirty()}_find(e){return null}_assignValidators(e){this._rawValidators=Array.isArray(e)?e.slice():e,this._composedValidatorFn=function Oj(n){return Array.isArray(n)?rT(n):n||null}(this._rawValidators)}_assignAsyncValidators(e){this._rawAsyncValidators=Array.isArray(e)?e.slice():e,this._composedAsyncValidatorFn=function Lj(n){return Array.isArray(n)?sT(n):n||null}(this._rawAsyncValidators)}}class fT extends KO{constructor(e,t,i){super(uT(t),hT(i,t)),this.controls=e,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}registerControl(e,t){return this.controls[e]?this.controls[e]:(this.controls[e]=t,t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange),t)}addControl(e,t,i={}){this.registerControl(e,t),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}removeControl(e,t={}){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}setControl(e,t,i={}){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],t&&this.registerControl(e,t),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}contains(e){return this.controls.hasOwnProperty(e)&&this.controls[e].enabled}setValue(e,t={}){(function qO(n,e,t){n._forEachChild((i,r)=>{if(void 0===t[r])throw new Ue(1002,dT?function Pj(n,e){return`Must supply a value for form control ${WO(n,e)}`}(e,r):"")})})(this,!0,e),Object.keys(e).forEach(i=>{(function $O(n,e,t){const i=n.controls;if(!(e?Object.keys(i):i).length)throw new Ue(1e3,dT?function Fj(n){return`\n There are no form controls registered with this ${n?"group":"array"} yet. If you're using ngModel,\n you may want to check next tick (e.g. use setTimeout).\n `}(e):"");if(!i[t])throw new Ue(1001,dT?function Rj(n,e){return`Cannot find form control ${WO(n,e)}`}(e,t):"")})(this,!0,i),this.controls[i].setValue(e[i],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(e,t={}){null!=e&&(Object.keys(e).forEach(i=>{const r=this.controls[i];r&&r.patchValue(e[i],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t))}reset(e={},t={}){this._forEachChild((i,r)=>{i.reset(e[r],{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t),this._updateTouched(t),this.updateValueAndValidity(t)}getRawValue(){return this._reduceChildren({},(e,t,i)=>(e[i]=t.getRawValue(),e))}_syncPendingControls(){let e=this._reduceChildren(!1,(t,i)=>!!i._syncPendingControls()||t);return e&&this.updateValueAndValidity({onlySelf:!0}),e}_forEachChild(e){Object.keys(this.controls).forEach(t=>{const i=this.controls[t];i&&e(i,t)})}_setUpControls(){this._forEachChild(e=>{e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(e){for(const[t,i]of Object.entries(this.controls))if(this.contains(t)&&e(i))return!0;return!1}_reduceValue(){return this._reduceChildren({},(t,i,r)=>((i.enabled||this.disabled)&&(t[r]=i.value),t))}_reduceChildren(e,t){let i=e;return this._forEachChild((r,s)=>{i=t(i,r,s)}),i}_allControlsDisabled(){for(const e of Object.keys(this.controls))if(this.controls[e].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(e){return this.controls.hasOwnProperty(e)?this.controls[e]:null}}const sg=new Ze("CallSetDisabledState",{providedIn:"root",factory:()=>vw}),vw="always";function Lv(n,e,t=vw){pT(n,e),e.valueAccessor.writeValue(n.value),(n.disabled||"always"===t)&&e.valueAccessor.setDisabledState?.(n.disabled),function Vj(n,e){e.valueAccessor.registerOnChange(t=>{n._pendingValue=t,n._pendingChange=!0,n._pendingDirty=!0,"change"===n.updateOn&&YO(n,e)})}(n,e),function Uj(n,e){const t=(i,r)=>{e.valueAccessor.writeValue(i),r&&e.viewToModelUpdate(i)};n.registerOnChange(t),e._registerOnDestroy(()=>{n._unregisterOnChange(t)})}(n,e),function Hj(n,e){e.valueAccessor.registerOnTouched(()=>{n._pendingTouched=!0,"blur"===n.updateOn&&n._pendingChange&&YO(n,e),"submit"!==n.updateOn&&n.markAsTouched()})}(n,e),function Bj(n,e){if(e.valueAccessor.setDisabledState){const t=i=>{e.valueAccessor.setDisabledState(i)};n.registerOnDisabledChange(t),e._registerOnDestroy(()=>{n._unregisterOnDisabledChange(t)})}}(n,e)}function bw(n,e,t=!0){const i=()=>{};e.valueAccessor&&(e.valueAccessor.registerOnChange(i),e.valueAccessor.registerOnTouched(i)),ww(n,e),n&&(e._invokeOnDestroyCallbacks(),n._registerOnCollectionChange(()=>{}))}function xw(n,e){n.forEach(t=>{t.registerOnValidatorChange&&t.registerOnValidatorChange(e)})}function pT(n,e){const t=VO(n);null!==e.validator?n.setValidators(BO(t,e.validator)):"function"==typeof t&&n.setValidators([t]);const i=HO(n);null!==e.asyncValidator?n.setAsyncValidators(BO(i,e.asyncValidator)):"function"==typeof i&&n.setAsyncValidators([i]);const r=()=>n.updateValueAndValidity();xw(e._rawValidators,r),xw(e._rawAsyncValidators,r)}function ww(n,e){let t=!1;if(null!==n){if(null!==e.validator){const r=VO(n);if(Array.isArray(r)&&r.length>0){const s=r.filter(o=>o!==e.validator);s.length!==r.length&&(t=!0,n.setValidators(s))}}if(null!==e.asyncValidator){const r=HO(n);if(Array.isArray(r)&&r.length>0){const s=r.filter(o=>o!==e.asyncValidator);s.length!==r.length&&(t=!0,n.setAsyncValidators(s))}}}const i=()=>{};return xw(e._rawValidators,i),xw(e._rawAsyncValidators,i),t}function YO(n,e){n._pendingDirty&&n.markAsDirty(),n.setValue(n._pendingValue,{emitModelToViewChange:!1}),e.viewToModelUpdate(n._pendingValue),n._pendingChange=!1}function XO(n,e){pT(n,e)}function ZO(n,e){n._syncPendingControls(),e.forEach(t=>{const i=t.control;"submit"===i.updateOn&&i._pendingChange&&(t.viewToModelUpdate(i._pendingValue),i._pendingChange=!1)})}const $j={provide:ca,useExisting:Mi(()=>Sw)},Nv=(()=>Promise.resolve())();let Sw=(()=>{class n extends ca{constructor(t,i,r){super(),this.callSetDisabledState=r,this.submitted=!1,this._directives=new Set,this.ngSubmit=new Pn,this.form=new fT({},rT(t),sT(i))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(t){Nv.then(()=>{const i=this._findContainer(t.path);t.control=i.registerControl(t.name,t.control),Lv(t.control,t,this.callSetDisabledState),t.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(t)})}getControl(t){return this.form.get(t.path)}removeControl(t){Nv.then(()=>{const i=this._findContainer(t.path);i&&i.removeControl(t.name),this._directives.delete(t)})}addFormGroup(t){Nv.then(()=>{const i=this._findContainer(t.path),r=new fT({});XO(r,t),i.registerControl(t.name,r),r.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(t){Nv.then(()=>{const i=this._findContainer(t.path);i&&i.removeControl(t.name)})}getFormGroup(t){return this.form.get(t.path)}updateModel(t,i){Nv.then(()=>{this.form.get(t.path).setValue(i)})}setValue(t){this.control.setValue(t)}onSubmit(t){return this.submitted=!0,ZO(this.form,this._directives),this.ngSubmit.emit(t),"dialog"===t?.target?.method}onReset(){this.resetForm()}resetForm(t){this.form.reset(t),this.submitted=!1}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.form._updateOn=this.options.updateOn)}_findContainer(t){return t.pop(),t.length?this.form.get(t):this.form}}return n.\u0275fac=function(t){return new(t||n)(ie(xo,10),ie(eh,10),ie(sg,8))},n.\u0275dir=ut({type:n,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(t,i){1&t&&Gn("submit",function(s){return i.onSubmit(s)})("reset",function(){return i.onReset()})},inputs:{options:["ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Oi([$j]),Z]}),n})();function JO(n,e){const t=n.indexOf(e);t>-1&&n.splice(t,1)}function QO(n){return"object"==typeof n&&null!==n&&2===Object.keys(n).length&&"value"in n&&"disabled"in n}const eL=class extends KO{constructor(e=null,t,i){super(uT(t),hT(i,t)),this.defaultValue=null,this._onChange=[],this._pendingChange=!1,this._applyFormState(e),this._setUpdateStrategy(t),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),_w(t)&&(t.nonNullable||t.initialValueIsDefault)&&(this.defaultValue=QO(e)?e.value:e)}setValue(e,t={}){this.value=this._pendingValue=e,this._onChange.length&&!1!==t.emitModelToViewChange&&this._onChange.forEach(i=>i(this.value,!1!==t.emitViewToModelChange)),this.updateValueAndValidity(t)}patchValue(e,t={}){this.setValue(e,t)}reset(e=this.defaultValue,t={}){this._applyFormState(e),this.markAsPristine(t),this.markAsUntouched(t),this.setValue(this.value,t),this._pendingChange=!1}_updateValue(){}_anyControls(e){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(e){this._onChange.push(e)}_unregisterOnChange(e){JO(this._onChange,e)}registerOnDisabledChange(e){this._onDisabledChange.push(e)}_unregisterOnDisabledChange(e){JO(this._onDisabledChange,e)}_forEachChild(e){}_syncPendingControls(){return!("submit"!==this.updateOn||(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),!this._pendingChange)||(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),0))}_applyFormState(e){QO(e)?(this.value=this._pendingValue=e.value,e.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=e}},Yj={provide:Hd,useExisting:Mi(()=>Ew)},iL=(()=>Promise.resolve())();let Ew=(()=>{class n extends Hd{constructor(t,i,r,s,o,a){super(),this._changeDetectorRef=o,this.callSetDisabledState=a,this.control=new eL,this._registered=!1,this.update=new Pn,this._parent=t,this._setValidators(i),this._setAsyncValidators(r),this.valueAccessor=function _T(n,e){if(!e)return null;let t,i,r;return Array.isArray(e),e.forEach(s=>{s.constructor===iT?t=s:function jj(n){return Object.getPrototypeOf(n.constructor)===Pf}(s)?i=s:r=s}),r||i||t||null}(0,s)}ngOnChanges(t){if(this._checkForErrors(),!this._registered||"name"in t){if(this._registered&&(this._checkName(),this.formDirective)){const i=t.name.previousValue;this.formDirective.removeControl({name:i,path:this._getPath(i)})}this._setUpControl()}"isDisabled"in t&&this._updateDisabled(t),function gT(n,e){if(!n.hasOwnProperty("model"))return!1;const t=n.model;return!!t.isFirstChange()||!Object.is(e,t.currentValue)}(t,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!(!this.options||!this.options.standalone)}_setUpStandalone(){Lv(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._isStandalone()||this._checkParentType(),this._checkName()}_checkParentType(){}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),this._isStandalone()}_updateValue(t){iL.then(()=>{this.control.setValue(t,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(t){const i=t.isDisabled.currentValue,r=0!==i&&function Qm(n){return"boolean"==typeof n?n:null!=n&&"false"!==n}(i);iL.then(()=>{r&&!this.control.disabled?this.control.disable():!r&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(t){return this._parent?function yw(n,e){return[...e.path,n]}(t,this._parent):[t]}}return n.\u0275fac=function(t){return new(t||n)(ie(ca,9),ie(xo,10),ie(eh,10),ie(Ja,10),ie(aa,8),ie(sg,8))},n.\u0275dir=ut({type:n,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:["disabled","isDisabled"],model:["ngModel","model"],options:["ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],features:[Oi([Yj]),Z,Cn]}),n})(),sL=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})();const nW={provide:ca,useExisting:Mi(()=>Mw)};let ET,Mw=(()=>{class n extends ca{constructor(t,i,r){super(),this.callSetDisabledState=r,this.submitted=!1,this._onCollectionChange=()=>this._updateDomValue(),this.directives=[],this.form=null,this.ngSubmit=new Pn,this._setValidators(t),this._setAsyncValidators(i)}ngOnChanges(t){this._checkFormPresent(),t.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(ww(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(t){const i=this.form.get(t.path);return Lv(i,t,this.callSetDisabledState),i.updateValueAndValidity({emitEvent:!1}),this.directives.push(t),i}getControl(t){return this.form.get(t.path)}removeControl(t){bw(t.control||null,t,!1),function Wj(n,e){const t=n.indexOf(e);t>-1&&n.splice(t,1)}(this.directives,t)}addFormGroup(t){this._setUpFormContainer(t)}removeFormGroup(t){this._cleanUpFormContainer(t)}getFormGroup(t){return this.form.get(t.path)}addFormArray(t){this._setUpFormContainer(t)}removeFormArray(t){this._cleanUpFormContainer(t)}getFormArray(t){return this.form.get(t.path)}updateModel(t,i){this.form.get(t.path).setValue(i)}onSubmit(t){return this.submitted=!0,ZO(this.form,this.directives),this.ngSubmit.emit(t),"dialog"===t?.target?.method}onReset(){this.resetForm()}resetForm(t){this.form.reset(t),this.submitted=!1}_updateDomValue(){this.directives.forEach(t=>{const i=t.control,r=this.form.get(t.path);i!==r&&(bw(i||null,t),(n=>n instanceof eL)(r)&&(Lv(r,t,this.callSetDisabledState),t.control=r))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(t){const i=this.form.get(t.path);XO(i,t),i.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(t){if(this.form){const i=this.form.get(t.path);i&&function zj(n,e){return ww(n,e)}(i,t)&&i.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){pT(this.form,this),this._oldForm&&ww(this._oldForm,this)}_checkFormPresent(){}}return n.\u0275fac=function(t){return new(t||n)(ie(xo,10),ie(eh,10),ie(sg,8))},n.\u0275dir=ut({type:n,selectors:[["","formGroup",""]],hostBindings:function(t,i){1&t&&Gn("submit",function(s){return i.onSubmit(s)})("reset",function(){return i.onReset()})},inputs:{form:["formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Oi([nW]),Z,Cn]}),n})(),bW=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[sL]}),n})(),wW=(()=>{class n{static withConfig(t){return{ngModule:n,providers:[{provide:sg,useValue:t.callSetDisabledState??vw}]}}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[bW]}),n})();try{ET=typeof Intl<"u"&&Intl.v8BreakIterator}catch{ET=!1}let Bv,Cw,Lf,MT,as=(()=>{class n{constructor(t){this._platformId=t,this.isBrowser=this._platformId?function Gz(n){return n===F3}(this._platformId):"object"==typeof document&&!!document,this.EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent),this.TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent),this.BLINK=this.isBrowser&&!(!window.chrome&&!ET)&&typeof CSS<"u"&&!this.EDGE&&!this.TRIDENT,this.WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT,this.IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window),this.FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent),this.ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT,this.SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT}}return n.\u0275fac=function(t){return new(t||n)(xe(U1))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function Vv(n){return function SW(){if(null==Bv&&typeof window<"u")try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>Bv=!0}))}finally{Bv=Bv||!1}return Bv}()?n:!!n.capture}function SL(){if(null==Lf){if("object"!=typeof document||!document||"function"!=typeof Element||!Element)return Lf=!1,Lf;if("scrollBehavior"in document.documentElement.style)Lf=!0;else{const n=Element.prototype.scrollTo;Lf=!!n&&!/\{\s*\[native code\]\s*\}/.test(n.toString())}}return Lf}function Hv(){if("object"!=typeof document||!document)return 0;if(null==Cw){const n=document.createElement("div"),e=n.style;n.dir="rtl",e.width="1px",e.overflow="auto",e.visibility="hidden",e.pointerEvents="none",e.position="absolute";const t=document.createElement("div"),i=t.style;i.width="2px",i.height="1px",n.appendChild(t),document.body.appendChild(n),Cw=0,0===n.scrollLeft&&(n.scrollLeft=1,Cw=0===n.scrollLeft?1:2),n.remove()}return Cw}function Dw(){let n=typeof document<"u"&&document?document.activeElement:null;for(;n&&n.shadowRoot;){const e=n.shadowRoot.activeElement;if(e===n)break;n=e}return n}function th(n){return n.composedPath?n.composedPath()[0]:n.target}function CT(){return typeof __karma__<"u"&&!!__karma__||typeof jasmine<"u"&&!!jasmine||typeof jest<"u"&&!!jest||typeof Mocha<"u"&&!!Mocha}class er extends cn{constructor(e){super(),this._value=e}get value(){return this.getValue()}_subscribe(e){const t=super._subscribe(e);return t&&!t.closed&&e.next(this._value),t}getValue(){if(this.hasError)throw this.thrownError;if(this.closed)throw new Pa;return this._value}next(e){super.next(this._value=e)}}function ql(n,...e){return e.length?e.some(t=>n[t]):n.altKey||n.shiftKey||n.ctrlKey||n.metaKey}function nh(){}function Dr(n,e,t){return function(r){return r.lift(new VW(n,e,t))}}class VW{constructor(e,t,i){this.nextOrObserver=e,this.error=t,this.complete=i}call(e,t){return t.subscribe(new HW(e,this.nextOrObserver,this.error,this.complete))}}class HW extends di{constructor(e,t,i,r){super(e),this._tapNext=nh,this._tapError=nh,this._tapComplete=nh,this._tapError=i||nh,this._tapComplete=r||nh,qr(t)?(this._context=this,this._tapNext=t):t&&(this._context=t,this._tapNext=t.next||nh,this._tapError=t.error||nh,this._tapComplete=t.complete||nh)}_next(e){try{this._tapNext.call(this._context,e)}catch(t){return void this.destination.error(t)}this.destination.next(e)}_error(e){try{this._tapError.call(this._context,e)}catch(t){return void this.destination.error(t)}this.destination.error(e)}_complete(){try{this._tapComplete.call(this._context)}catch(e){return void this.destination.error(e)}return this.destination.complete()}}class UW extends Tn{constructor(e,t){super()}schedule(e,t=0){return this}}class kT extends UW{constructor(e,t){super(e,t),this.scheduler=e,this.work=t,this.pending=!1}schedule(e,t=0){if(this.closed)return this;this.state=e;const i=this.id,r=this.scheduler;return null!=i&&(this.id=this.recycleAsyncId(r,i,t)),this.pending=!0,this.delay=t,this.id=this.id||this.requestAsyncId(r,this.id,t),this}requestAsyncId(e,t,i=0){return setInterval(e.flush.bind(e,this),i)}recycleAsyncId(e,t,i=0){if(null!==i&&this.delay===i&&!1===this.pending)return t;clearInterval(t)}execute(e,t){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;const i=this._execute(e,t);if(i)return i;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(e,t){let r,i=!1;try{this.work(e)}catch(s){i=!0,r=!!s&&s||new Error(s)}if(i)return this.unsubscribe(),r}_unsubscribe(){const e=this.id,t=this.scheduler,i=t.actions,r=i.indexOf(this);this.work=null,this.state=null,this.pending=!1,this.scheduler=null,-1!==r&&i.splice(r,1),null!=e&&(this.id=this.recycleAsyncId(t,e,null)),this.delay=null}}let CL=(()=>{class n{constructor(t,i=n.now){this.SchedulerAction=t,this.now=i}schedule(t,i=0,r){return new this.SchedulerAction(this,t).schedule(r,i)}}return n.now=()=>Date.now(),n})();class Kl extends CL{constructor(e,t=CL.now){super(e,()=>Kl.delegate&&Kl.delegate!==this?Kl.delegate.now():t()),this.actions=[],this.active=!1,this.scheduled=void 0}schedule(e,t=0,i){return Kl.delegate&&Kl.delegate!==this?Kl.delegate.schedule(e,t,i):super.schedule(e,t,i)}flush(e){const{actions:t}=this;if(this.active)return void t.push(e);let i;this.active=!0;do{if(i=e.execute(e.state,e.delay))break}while(e=t.shift());if(this.active=!1,i){for(;e=t.shift();)e.unsubscribe();throw i}}}const ag=new Kl(kT);function zv(n,e=ag){return t=>t.lift(new zW(n,e))}class zW{constructor(e,t){this.dueTime=e,this.scheduler=t}call(e,t){return t.subscribe(new GW(e,this.dueTime,this.scheduler))}}class GW extends di{constructor(e,t,i){super(e),this.dueTime=t,this.scheduler=i,this.debouncedSubscription=null,this.lastValue=null,this.hasValue=!1}_next(e){this.clearDebounce(),this.lastValue=e,this.hasValue=!0,this.add(this.debouncedSubscription=this.scheduler.schedule(jW,this.dueTime,this))}_complete(){this.debouncedNext(),this.destination.complete()}debouncedNext(){if(this.clearDebounce(),this.hasValue){const{lastValue:e}=this;this.lastValue=null,this.hasValue=!1,this.destination.next(e)}}clearDebounce(){const e=this.debouncedSubscription;null!==e&&(this.remove(e),e.unsubscribe(),this.debouncedSubscription=null)}}function jW(n){n.debouncedNext()}const DL=(()=>{function n(){return Error.call(this),this.message="argument out of range",this.name="ArgumentOutOfRangeError",this}return n.prototype=Object.create(Error.prototype),n})(),Fc=new un(n=>n.complete());function kw(n){return n?function WW(n){return new un(e=>n.schedule(()=>e.complete()))}(n):Fc}function Gr(n){return e=>0===n?kw():e.lift(new $W(n))}class $W{constructor(e){if(this.total=e,this.total<0)throw new DL}call(e,t){return t.subscribe(new qW(e,this.total))}}class qW extends di{constructor(e,t){super(e),this.total=t,this.count=0}_next(e){const t=this.total,i=++this.count;i<=t&&(this.destination.next(e),i===t&&(this.destination.complete(),this.unsubscribe()))}}function TL(n){return e=>e.lift(new KW(n))}class KW{constructor(e){this.total=e}call(e,t){return t.subscribe(new YW(e,this.total))}}class YW extends di{constructor(e,t){super(e),this.total=t,this.count=0}_next(e){++this.count>this.total&&this.destination.next(e)}}function Rc(n,e){return t=>t.lift(new XW(n,e))}class XW{constructor(e,t){this.compare=e,this.keySelector=t}call(e,t){return t.subscribe(new ZW(e,this.compare,this.keySelector))}}class ZW extends di{constructor(e,t,i){super(e),this.keySelector=i,this.hasKey=!1,"function"==typeof t&&(this.compare=t)}compare(e,t){return e===t}_next(e){let t;try{const{keySelector:r}=this;t=r?r(e):e}catch(r){return this.destination.error(r)}let i=!1;if(this.hasKey)try{const{compare:r}=this;i=r(this.key,t)}catch(r){return this.destination.error(r)}else this.hasKey=!0;i||(this.key=t,this.destination.next(e))}}function Tr(n){return e=>e.lift(new JW(n))}class JW{constructor(e){this.notifier=e}call(e,t){const i=new QW(e),r=$o(i,this.notifier);return r&&!i.seenValue?(i.add(r),t.subscribe(i)):i}}class QW extends Fs{constructor(e){super(e),this.seenValue=!1}notifyNext(e,t,i,r,s){this.seenValue=!0,this.complete()}notifyComplete(){}}function bi(n){return null!=n&&"false"!=`${n}`}function ih(n,e=0){return function e$(n){return!isNaN(parseFloat(n))&&!isNaN(Number(n))}(n)?Number(n):e}function Iw(n){return Array.isArray(n)?n:[n]}function Cs(n){return null==n?"":"string"==typeof n?n:`${n}px`}function Nf(n){return n instanceof _n?n.nativeElement:n}let AL=(()=>{class n{create(t){return typeof MutationObserver>"u"?null:new MutationObserver(t)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),t$=(()=>{class n{constructor(t){this._mutationObserverFactory=t,this._observedElements=new Map}ngOnDestroy(){this._observedElements.forEach((t,i)=>this._cleanupObserver(i))}observe(t){const i=Nf(t);return new un(r=>{const o=this._observeElement(i).subscribe(r);return()=>{o.unsubscribe(),this._unobserveElement(i)}})}_observeElement(t){if(this._observedElements.has(t))this._observedElements.get(t).count++;else{const i=new cn,r=this._mutationObserverFactory.create(s=>i.next(s));r&&r.observe(t,{characterData:!0,childList:!0,subtree:!0}),this._observedElements.set(t,{observer:r,stream:i,count:1})}return this._observedElements.get(t).stream}_unobserveElement(t){this._observedElements.has(t)&&(this._observedElements.get(t).count--,this._observedElements.get(t).count||this._cleanupObserver(t))}_cleanupObserver(t){if(this._observedElements.has(t)){const{observer:i,stream:r}=this._observedElements.get(t);i&&i.disconnect(),r.complete(),this._observedElements.delete(t)}}}return n.\u0275fac=function(t){return new(t||n)(xe(AL))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),IT=(()=>{class n{get disabled(){return this._disabled}set disabled(t){this._disabled=bi(t),this._disabled?this._unsubscribe():this._subscribe()}get debounce(){return this._debounce}set debounce(t){this._debounce=ih(t),this._subscribe()}constructor(t,i,r){this._contentObserver=t,this._elementRef=i,this._ngZone=r,this.event=new Pn,this._disabled=!1,this._currentSubscription=null}ngAfterContentInit(){!this._currentSubscription&&!this.disabled&&this._subscribe()}ngOnDestroy(){this._unsubscribe()}_subscribe(){this._unsubscribe();const t=this._contentObserver.observe(this._elementRef);this._ngZone.runOutsideAngular(()=>{this._currentSubscription=(this.debounce?t.pipe(zv(this.debounce)):t).subscribe(this.event)})}_unsubscribe(){this._currentSubscription?.unsubscribe()}}return n.\u0275fac=function(t){return new(t||n)(ie(t$),ie(_n),ie(Xt))},n.\u0275dir=ut({type:n,selectors:[["","cdkObserveContent",""]],inputs:{disabled:["cdkObserveContentDisabled","disabled"],debounce:"debounce"},outputs:{event:"cdkObserveContent"},exportAs:["cdkObserveContent"]}),n})(),FT=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[AL]}),n})();const kL={};function Fw(...n){let e=null,t=null;return cc(n[n.length-1])&&(t=n.pop()),"function"==typeof n[n.length-1]&&(e=n.pop()),1===n.length&&_i(n[0])&&(n=n[0]),uc(n,t).lift(new n$(e))}class n${constructor(e){this.resultSelector=e}call(e,t){return t.subscribe(new i$(e,this.resultSelector))}}class i$ extends Fs{constructor(e,t){super(e),this.resultSelector=t,this.active=0,this.values=[],this.observables=[]}_next(e){this.values.push(kL),this.observables.push(e)}_complete(){const e=this.observables,t=e.length;if(0===t)this.destination.complete();else{this.active=t,this.toRespond=t;for(let i=0;iRw(n,t,e)):t=>Rw(n,t)}const IL=new Set;let cg,s$=(()=>{class n{constructor(t){this._platform=t,this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):a$}matchMedia(t){return(this._platform.WEBKIT||this._platform.BLINK)&&function o$(n){if(!IL.has(n))try{cg||(cg=document.createElement("style"),cg.setAttribute("type","text/css"),document.head.appendChild(cg)),cg.sheet&&(cg.sheet.insertRule(`@media ${n} {body{ }}`,0),IL.add(n))}catch(e){console.error(e)}}(t),this._matchMedia(t)}}return n.\u0275fac=function(t){return new(t||n)(xe(as))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function a$(n){return{matches:"all"===n||""===n,media:n,addListener:()=>{},removeListener:()=>{}}}let FL=(()=>{class n{constructor(t,i){this._mediaMatcher=t,this._zone=i,this._queries=new Map,this._destroySubject=new cn}ngOnDestroy(){this._destroySubject.next(),this._destroySubject.complete()}isMatched(t){return RL(Iw(t)).some(r=>this._registerQuery(r).mql.matches)}observe(t){let s=Fw(RL(Iw(t)).map(o=>this._registerQuery(o).observable));return s=Rw(s.pipe(Gr(1)),s.pipe(TL(1),zv(0))),s.pipe(_t(o=>{const a={matches:!1,breakpoints:{}};return o.forEach(({matches:c,query:u})=>{a.matches=a.matches||c,a.breakpoints[u]=c}),a}))}_registerQuery(t){if(this._queries.has(t))return this._queries.get(t);const i=this._mediaMatcher.matchMedia(t),s={observable:new un(o=>{const a=c=>this._zone.run(()=>o.next(c));return i.addListener(a),()=>{i.removeListener(a)}}).pipe(Bf(i),_t(({matches:o})=>({query:t,matches:o})),Tr(this._destroySubject)),mql:i};return this._queries.set(t,s),s}}return n.\u0275fac=function(t){return new(t||n)(xe(s$),xe(Xt))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function RL(n){return n.map(e=>e.split(",")).reduce((e,t)=>e.concat(t)).map(e=>e.trim())}const lg_Medium="(min-width: 960px) and (max-width: 1279.98px)",lg_Large="(min-width: 1280px) and (max-width: 1919.98px)";function Pw(n,e){return(n.getAttribute(e)||"").match(/\S+/g)||[]}const OL="cdk-describedby-message",Ow="cdk-describedby-host";let RT=0,d$=(()=>{class n{constructor(t,i){this._platform=i,this._messageRegistry=new Map,this._messagesContainer=null,this._id=""+RT++,this._document=t,this._id=hn(Zm)+"-"+RT++}describe(t,i,r){if(!this._canBeDescribed(t,i))return;const s=PT(i,r);"string"!=typeof i?(LL(i,this._id),this._messageRegistry.set(s,{messageElement:i,referenceCount:0})):this._messageRegistry.has(s)||this._createMessageElement(i,r),this._isElementDescribedByMessage(t,s)||this._addMessageReference(t,s)}removeDescription(t,i,r){if(!i||!this._isElementNode(t))return;const s=PT(i,r);if(this._isElementDescribedByMessage(t,s)&&this._removeMessageReference(t,s),"string"==typeof i){const o=this._messageRegistry.get(s);o&&0===o.referenceCount&&this._deleteMessageElement(s)}0===this._messagesContainer?.childNodes.length&&(this._messagesContainer.remove(),this._messagesContainer=null)}ngOnDestroy(){const t=this._document.querySelectorAll(`[${Ow}="${this._id}"]`);for(let i=0;i0!=r.indexOf(OL));t.setAttribute("aria-describedby",i.join(" "))}_addMessageReference(t,i){const r=this._messageRegistry.get(i);(function c$(n,e,t){const i=Pw(n,e);i.some(r=>r.trim()==t.trim())||(i.push(t.trim()),n.setAttribute(e,i.join(" ")))})(t,"aria-describedby",r.messageElement.id),t.setAttribute(Ow,this._id),r.referenceCount++}_removeMessageReference(t,i){const r=this._messageRegistry.get(i);r.referenceCount--,function l$(n,e,t){const r=Pw(n,e).filter(s=>s!=t.trim());r.length?n.setAttribute(e,r.join(" ")):n.removeAttribute(e)}(t,"aria-describedby",r.messageElement.id),t.removeAttribute(Ow)}_isElementDescribedByMessage(t,i){const r=Pw(t,"aria-describedby"),s=this._messageRegistry.get(i),o=s&&s.messageElement.id;return!!o&&-1!=r.indexOf(o)}_canBeDescribed(t,i){if(!this._isElementNode(t))return!1;if(i&&"object"==typeof i)return!0;const r=null==i?"":`${i}`.trim(),s=t.getAttribute("aria-label");return!(!r||s&&s.trim()===r)}_isElementNode(t){return t.nodeType===this._document.ELEMENT_NODE}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn),xe(as))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function PT(n,e){return"string"==typeof n?`${e||""}/${n}`:n}function LL(n,e){n.id||(n.id=`${OL}-${e}-${RT++}`)}class NL{constructor(e){this._items=e,this._activeItemIndex=-1,this._activeItem=null,this._wrap=!1,this._letterKeyStream=new cn,this._typeaheadSubscription=Tn.EMPTY,this._vertical=!0,this._allowedModifierKeys=[],this._homeAndEnd=!1,this._pageUpAndDown={enabled:!1,delta:10},this._skipPredicateFn=t=>t.disabled,this._pressedLetters=[],this.tabOut=new cn,this.change=new cn,e instanceof xv&&(this._itemChangesSubscription=e.changes.subscribe(t=>{if(this._activeItem){const r=t.toArray().indexOf(this._activeItem);r>-1&&r!==this._activeItemIndex&&(this._activeItemIndex=r)}}))}skipPredicate(e){return this._skipPredicateFn=e,this}withWrap(e=!0){return this._wrap=e,this}withVerticalOrientation(e=!0){return this._vertical=e,this}withHorizontalOrientation(e){return this._horizontal=e,this}withAllowedModifierKeys(e){return this._allowedModifierKeys=e,this}withTypeAhead(e=200){return this._typeaheadSubscription.unsubscribe(),this._typeaheadSubscription=this._letterKeyStream.pipe(Dr(t=>this._pressedLetters.push(t)),zv(e),Ui(()=>this._pressedLetters.length>0),_t(()=>this._pressedLetters.join(""))).subscribe(t=>{const i=this._getItemsArray();for(let r=1;r!e[s]||this._allowedModifierKeys.indexOf(s)>-1);switch(t){case 9:return void this.tabOut.next();case 40:if(this._vertical&&r){this.setNextItemActive();break}return;case 38:if(this._vertical&&r){this.setPreviousItemActive();break}return;case 39:if(this._horizontal&&r){"rtl"===this._horizontal?this.setPreviousItemActive():this.setNextItemActive();break}return;case 37:if(this._horizontal&&r){"rtl"===this._horizontal?this.setNextItemActive():this.setPreviousItemActive();break}return;case 36:if(this._homeAndEnd&&r){this.setFirstItemActive();break}return;case 35:if(this._homeAndEnd&&r){this.setLastItemActive();break}return;case 33:if(this._pageUpAndDown.enabled&&r){const s=this._activeItemIndex-this._pageUpAndDown.delta;this._setActiveItemByIndex(s>0?s:0,1);break}return;case 34:if(this._pageUpAndDown.enabled&&r){const s=this._activeItemIndex+this._pageUpAndDown.delta,o=this._getItemsArray().length;this._setActiveItemByIndex(s=65&&t<=90||t>=48&&t<=57)&&this._letterKeyStream.next(String.fromCharCode(t))))}this._pressedLetters=[],e.preventDefault()}get activeItemIndex(){return this._activeItemIndex}get activeItem(){return this._activeItem}isTyping(){return this._pressedLetters.length>0}setFirstItemActive(){this._setActiveItemByIndex(0,1)}setLastItemActive(){this._setActiveItemByIndex(this._items.length-1,-1)}setNextItemActive(){this._activeItemIndex<0?this.setFirstItemActive():this._setActiveItemByDelta(1)}setPreviousItemActive(){this._activeItemIndex<0&&this._wrap?this.setLastItemActive():this._setActiveItemByDelta(-1)}updateActiveItem(e){const t=this._getItemsArray(),i="number"==typeof e?e:t.indexOf(e);this._activeItem=t[i]??null,this._activeItemIndex=i}destroy(){this._typeaheadSubscription.unsubscribe(),this._itemChangesSubscription?.unsubscribe(),this._letterKeyStream.complete(),this.tabOut.complete(),this.change.complete(),this._pressedLetters=[]}_setActiveItemByDelta(e){this._wrap?this._setActiveInWrapMode(e):this._setActiveInDefaultMode(e)}_setActiveInWrapMode(e){const t=this._getItemsArray();for(let i=1;i<=t.length;i++){const r=(this._activeItemIndex+e*i+t.length)%t.length;if(!this._skipPredicateFn(t[r]))return void this.setActiveItem(r)}}_setActiveInDefaultMode(e){this._setActiveItemByIndex(this._activeItemIndex+e,e)}_setActiveItemByIndex(e,t){const i=this._getItemsArray();if(i[e]){for(;this._skipPredicateFn(i[e]);)if(!i[e+=t])return;this.setActiveItem(e)}}_getItemsArray(){return this._items instanceof xv?this._items.toArray():this._items}}class u$ extends NL{setActiveItem(e){this.activeItem&&this.activeItem.setInactiveStyles(),super.setActiveItem(e),this.activeItem&&this.activeItem.setActiveStyles()}}let Gv=(()=>{class n{constructor(t){this._platform=t}isDisabled(t){return t.hasAttribute("disabled")}isVisible(t){return function p$(n){return!!(n.offsetWidth||n.offsetHeight||"function"==typeof n.getClientRects&&n.getClientRects().length)}(t)&&"visible"===getComputedStyle(t).visibility}isTabbable(t){if(!this._platform.isBrowser)return!1;const i=function f$(n){try{return n.frameElement}catch{return null}}(function w$(n){return n.ownerDocument&&n.ownerDocument.defaultView||window}(t));if(i&&(-1===VL(i)||!this.isVisible(i)))return!1;let r=t.nodeName.toLowerCase(),s=VL(t);return t.hasAttribute("contenteditable")?-1!==s:!("iframe"===r||"object"===r||this._platform.WEBKIT&&this._platform.IOS&&!function b$(n){let e=n.nodeName.toLowerCase(),t="input"===e&&n.type;return"text"===t||"password"===t||"select"===e||"textarea"===e}(t))&&("audio"===r?!!t.hasAttribute("controls")&&-1!==s:"video"===r?-1!==s&&(null!==s||this._platform.FIREFOX||t.hasAttribute("controls")):t.tabIndex>=0)}isFocusable(t,i){return function x$(n){return!function g$(n){return function v$(n){return"input"==n.nodeName.toLowerCase()}(n)&&"hidden"==n.type}(n)&&(function m$(n){let e=n.nodeName.toLowerCase();return"input"===e||"select"===e||"button"===e||"textarea"===e}(n)||function _$(n){return function y$(n){return"a"==n.nodeName.toLowerCase()}(n)&&n.hasAttribute("href")}(n)||n.hasAttribute("contenteditable")||BL(n))}(t)&&!this.isDisabled(t)&&(i?.ignoreVisibility||this.isVisible(t))}}return n.\u0275fac=function(t){return new(t||n)(xe(as))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function BL(n){if(!n.hasAttribute("tabindex")||void 0===n.tabIndex)return!1;let e=n.getAttribute("tabindex");return!(!e||isNaN(parseInt(e,10)))}function VL(n){if(!BL(n))return null;const e=parseInt(n.getAttribute("tabindex")||"",10);return isNaN(e)?-1:e}class S${get enabled(){return this._enabled}set enabled(e){this._enabled=e,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(e,this._startAnchor),this._toggleAnchorTabIndex(e,this._endAnchor))}constructor(e,t,i,r,s=!1){this._element=e,this._checker=t,this._ngZone=i,this._document=r,this._hasAttached=!1,this.startAnchorListener=()=>this.focusLastTabbableElement(),this.endAnchorListener=()=>this.focusFirstTabbableElement(),this._enabled=!0,s||this.attachAnchors()}destroy(){const e=this._startAnchor,t=this._endAnchor;e&&(e.removeEventListener("focus",this.startAnchorListener),e.remove()),t&&(t.removeEventListener("focus",this.endAnchorListener),t.remove()),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}attachAnchors(){return!!this._hasAttached||(this._ngZone.runOutsideAngular(()=>{this._startAnchor||(this._startAnchor=this._createAnchor(),this._startAnchor.addEventListener("focus",this.startAnchorListener)),this._endAnchor||(this._endAnchor=this._createAnchor(),this._endAnchor.addEventListener("focus",this.endAnchorListener))}),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}focusInitialElementWhenReady(e){return new Promise(t=>{this._executeOnStable(()=>t(this.focusInitialElement(e)))})}focusFirstTabbableElementWhenReady(e){return new Promise(t=>{this._executeOnStable(()=>t(this.focusFirstTabbableElement(e)))})}focusLastTabbableElementWhenReady(e){return new Promise(t=>{this._executeOnStable(()=>t(this.focusLastTabbableElement(e)))})}_getRegionBoundary(e){const t=this._element.querySelectorAll(`[cdk-focus-region-${e}], [cdkFocusRegion${e}], [cdk-focus-${e}]`);return"start"==e?t.length?t[0]:this._getFirstTabbableElement(this._element):t.length?t[t.length-1]:this._getLastTabbableElement(this._element)}focusInitialElement(e){const t=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");if(t){if(!this._checker.isFocusable(t)){const i=this._getFirstTabbableElement(t);return i?.focus(e),!!i}return t.focus(e),!0}return this.focusFirstTabbableElement(e)}focusFirstTabbableElement(e){const t=this._getRegionBoundary("start");return t&&t.focus(e),!!t}focusLastTabbableElement(e){const t=this._getRegionBoundary("end");return t&&t.focus(e),!!t}hasAttached(){return this._hasAttached}_getFirstTabbableElement(e){if(this._checker.isFocusable(e)&&this._checker.isTabbable(e))return e;const t=e.children;for(let i=0;i=0;i--){const r=t[i].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(t[i]):null;if(r)return r}return null}_createAnchor(){const e=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,e),e.classList.add("cdk-visually-hidden"),e.classList.add("cdk-focus-trap-anchor"),e.setAttribute("aria-hidden","true"),e}_toggleAnchorTabIndex(e,t){e?t.setAttribute("tabindex","0"):t.removeAttribute("tabindex")}toggleAnchors(e){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(e,this._startAnchor),this._toggleAnchorTabIndex(e,this._endAnchor))}_executeOnStable(e){this._ngZone.isStable?e():this._ngZone.onStable.pipe(Gr(1)).subscribe(e)}}let Lw=(()=>{class n{constructor(t,i,r){this._checker=t,this._ngZone=i,this._document=r}create(t,i=!1){return new S$(t,this._checker,this._ngZone,this._document,i)}}return n.\u0275fac=function(t){return new(t||n)(xe(Gv),xe(Xt),xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function HL(n){return 0===n.buttons||0===n.offsetX&&0===n.offsetY}function UL(n){const e=n.touches&&n.touches[0]||n.changedTouches&&n.changedTouches[0];return!(!e||-1!==e.identifier||null!=e.radiusX&&1!==e.radiusX||null!=e.radiusY&&1!==e.radiusY)}const E$=new Ze("cdk-input-modality-detector-options"),M$={ignoreKeys:[18,17,224,91,16]},dg=Vv({passive:!0,capture:!0});let C$=(()=>{class n{get mostRecentModality(){return this._modality.value}constructor(t,i,r,s){this._platform=t,this._mostRecentTarget=null,this._modality=new er(null),this._lastTouchMs=0,this._onKeydown=o=>{this._options?.ignoreKeys?.some(a=>a===o.keyCode)||(this._modality.next("keyboard"),this._mostRecentTarget=th(o))},this._onMousedown=o=>{Date.now()-this._lastTouchMs<650||(this._modality.next(HL(o)?"keyboard":"mouse"),this._mostRecentTarget=th(o))},this._onTouchstart=o=>{UL(o)?this._modality.next("keyboard"):(this._lastTouchMs=Date.now(),this._modality.next("touch"),this._mostRecentTarget=th(o))},this._options={...M$,...s},this.modalityDetected=this._modality.pipe(TL(1)),this.modalityChanged=this.modalityDetected.pipe(Rc()),t.isBrowser&&i.runOutsideAngular(()=>{r.addEventListener("keydown",this._onKeydown,dg),r.addEventListener("mousedown",this._onMousedown,dg),r.addEventListener("touchstart",this._onTouchstart,dg)})}ngOnDestroy(){this._modality.complete(),this._platform.isBrowser&&(document.removeEventListener("keydown",this._onKeydown,dg),document.removeEventListener("mousedown",this._onMousedown,dg),document.removeEventListener("touchstart",this._onTouchstart,dg))}}return n.\u0275fac=function(t){return new(t||n)(xe(as),xe(Xt),xe(Mn),xe(E$,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const D$=new Ze("liveAnnouncerElement",{providedIn:"root",factory:function T$(){return null}}),A$=new Ze("LIVE_ANNOUNCER_DEFAULT_OPTIONS");let k$=0,I$=(()=>{class n{constructor(t,i,r,s){this._ngZone=i,this._defaultOptions=s,this._document=r,this._liveElement=t||this._createLiveElement()}announce(t,...i){const r=this._defaultOptions;let s,o;return 1===i.length&&"number"==typeof i[0]?o=i[0]:[s,o]=i,this.clear(),clearTimeout(this._previousTimeout),s||(s=r&&r.politeness?r.politeness:"polite"),null==o&&r&&(o=r.duration),this._liveElement.setAttribute("aria-live",s),this._liveElement.id&&this._exposeAnnouncerToModals(this._liveElement.id),this._ngZone.runOutsideAngular(()=>(this._currentPromise||(this._currentPromise=new Promise(a=>this._currentResolve=a)),clearTimeout(this._previousTimeout),this._previousTimeout=setTimeout(()=>{this._liveElement.textContent=t,"number"==typeof o&&(this._previousTimeout=setTimeout(()=>this.clear(),o)),this._currentResolve(),this._currentPromise=this._currentResolve=void 0},100),this._currentPromise))}clear(){this._liveElement&&(this._liveElement.textContent="")}ngOnDestroy(){clearTimeout(this._previousTimeout),this._liveElement?.remove(),this._liveElement=null,this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0}_createLiveElement(){const t="cdk-live-announcer-element",i=this._document.getElementsByClassName(t),r=this._document.createElement("div");for(let s=0;s .cdk-overlay-container [aria-modal="true"]');for(let r=0;r{class n{constructor(t,i,r,s,o){this._ngZone=t,this._platform=i,this._inputModalityDetector=r,this._origin=null,this._windowFocused=!1,this._originFromTouchInteraction=!1,this._elementInfo=new Map,this._monitoredElementCount=0,this._rootNodeFocusListenerCount=new Map,this._windowFocusListener=()=>{this._windowFocused=!0,this._windowFocusTimeoutId=window.setTimeout(()=>this._windowFocused=!1)},this._stopInputModalityDetector=new cn,this._rootNodeFocusAndBlurListener=a=>{for(let u=th(a);u;u=u.parentElement)"focus"===a.type?this._onFocus(a,u):this._onBlur(a,u)},this._document=s,this._detectionMode=o?.detectionMode||0}monitor(t,i=!1){const r=Nf(t);if(!this._platform.isBrowser||1!==r.nodeType)return Tt(null);const s=function MW(n){if(function EW(){if(null==MT){const n=typeof document<"u"?document.head:null;MT=!(!n||!n.createShadowRoot&&!n.attachShadow)}return MT}()){const e=n.getRootNode?n.getRootNode():null;if(typeof ShadowRoot<"u"&&ShadowRoot&&e instanceof ShadowRoot)return e}return null}(r)||this._getDocument(),o=this._elementInfo.get(r);if(o)return i&&(o.checkChildren=!0),o.subject;const a={checkChildren:i,subject:new cn,rootNode:s};return this._elementInfo.set(r,a),this._registerGlobalListeners(a),a.subject}stopMonitoring(t){const i=Nf(t),r=this._elementInfo.get(i);r&&(r.subject.complete(),this._setClasses(i),this._elementInfo.delete(i),this._removeGlobalListeners(r))}focusVia(t,i,r){const s=Nf(t);s===this._getDocument().activeElement?this._getClosestElementsInfo(s).forEach(([a,c])=>this._originChanged(a,i,c)):(this._setOrigin(i),"function"==typeof s.focus&&s.focus(r))}ngOnDestroy(){this._elementInfo.forEach((t,i)=>this.stopMonitoring(i))}_getDocument(){return this._document||document}_getWindow(){return this._getDocument().defaultView||window}_getFocusOrigin(t){return this._origin?this._originFromTouchInteraction?this._shouldBeAttributedToTouch(t)?"touch":"program":this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:t&&this._isLastInteractionFromInputLabel(t)?"mouse":"program"}_shouldBeAttributedToTouch(t){return 1===this._detectionMode||!!t?.contains(this._inputModalityDetector._mostRecentTarget)}_setClasses(t,i){t.classList.toggle("cdk-focused",!!i),t.classList.toggle("cdk-touch-focused","touch"===i),t.classList.toggle("cdk-keyboard-focused","keyboard"===i),t.classList.toggle("cdk-mouse-focused","mouse"===i),t.classList.toggle("cdk-program-focused","program"===i)}_setOrigin(t,i=!1){this._ngZone.runOutsideAngular(()=>{this._origin=t,this._originFromTouchInteraction="touch"===t&&i,0===this._detectionMode&&(clearTimeout(this._originTimeoutId),this._originTimeoutId=setTimeout(()=>this._origin=null,this._originFromTouchInteraction?650:1))})}_onFocus(t,i){const r=this._elementInfo.get(i),s=th(t);!r||!r.checkChildren&&i!==s||this._originChanged(i,this._getFocusOrigin(s),r)}_onBlur(t,i){const r=this._elementInfo.get(i);!r||r.checkChildren&&t.relatedTarget instanceof Node&&i.contains(t.relatedTarget)||(this._setClasses(i),this._emitOrigin(r,null))}_emitOrigin(t,i){t.subject.observers.length&&this._ngZone.run(()=>t.subject.next(i))}_registerGlobalListeners(t){if(!this._platform.isBrowser)return;const i=t.rootNode,r=this._rootNodeFocusListenerCount.get(i)||0;r||this._ngZone.runOutsideAngular(()=>{i.addEventListener("focus",this._rootNodeFocusAndBlurListener,Nw),i.addEventListener("blur",this._rootNodeFocusAndBlurListener,Nw)}),this._rootNodeFocusListenerCount.set(i,r+1),1==++this._monitoredElementCount&&(this._ngZone.runOutsideAngular(()=>{this._getWindow().addEventListener("focus",this._windowFocusListener)}),this._inputModalityDetector.modalityDetected.pipe(Tr(this._stopInputModalityDetector)).subscribe(s=>{this._setOrigin(s,!0)}))}_removeGlobalListeners(t){const i=t.rootNode;if(this._rootNodeFocusListenerCount.has(i)){const r=this._rootNodeFocusListenerCount.get(i);r>1?this._rootNodeFocusListenerCount.set(i,r-1):(i.removeEventListener("focus",this._rootNodeFocusAndBlurListener,Nw),i.removeEventListener("blur",this._rootNodeFocusAndBlurListener,Nw),this._rootNodeFocusListenerCount.delete(i))}--this._monitoredElementCount||(this._getWindow().removeEventListener("focus",this._windowFocusListener),this._stopInputModalityDetector.next(),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._originTimeoutId))}_originChanged(t,i,r){this._setClasses(t,i),this._emitOrigin(r,i),this._lastFocusOrigin=i}_getClosestElementsInfo(t){const i=[];return this._elementInfo.forEach((r,s)=>{(s===t||r.checkChildren&&s.contains(t))&&i.push([s,r])}),i}_isLastInteractionFromInputLabel(t){const{_mostRecentTarget:i,mostRecentModality:r}=this._inputModalityDetector;if("mouse"!==r||!i||i===t||"INPUT"!==t.nodeName&&"TEXTAREA"!==t.nodeName||t.disabled)return!1;const s=t.labels;if(s)for(let o=0;o{class n{constructor(t,i){this._platform=t,this._document=i,this._breakpointSubscription=hn(FL).observe("(forced-colors: active)").subscribe(()=>{this._hasCheckedHighContrastMode&&(this._hasCheckedHighContrastMode=!1,this._applyBodyHighContrastModeCssClasses())})}getHighContrastMode(){if(!this._platform.isBrowser)return 0;const t=this._document.createElement("div");t.style.backgroundColor="rgb(1,2,3)",t.style.position="absolute",this._document.body.appendChild(t);const i=this._document.defaultView||window,r=i&&i.getComputedStyle?i.getComputedStyle(t):null,s=(r&&r.backgroundColor||"").replace(/ /g,"");switch(t.remove(),s){case"rgb(0,0,0)":case"rgb(45,50,54)":case"rgb(32,32,32)":return 2;case"rgb(255,255,255)":case"rgb(255,250,239)":return 1}return 0}ngOnDestroy(){this._breakpointSubscription.unsubscribe()}_applyBodyHighContrastModeCssClasses(){if(!this._hasCheckedHighContrastMode&&this._platform.isBrowser&&this._document.body){const t=this._document.body.classList;t.remove(OT,GL,jL),this._hasCheckedHighContrastMode=!0;const i=this.getHighContrastMode();1===i?t.add(OT,GL):2===i&&t.add(OT,jL)}}}return n.\u0275fac=function(t){return new(t||n)(xe(as),xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),$L=(()=>{class n{constructor(t){t._applyBodyHighContrastModeCssClasses()}}return n.\u0275fac=function(t){return new(t||n)(xe(WL))},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[FT]}),n})();const R$=new Ze("cdk-dir-doc",{providedIn:"root",factory:function P$(){return hn(Mn)}}),O$=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;let Yl=(()=>{class n{constructor(t){this.value="ltr",this.change=new Pn,t&&(this.value=function L$(n){const e=n?.toLowerCase()||"";return"auto"===e&&typeof navigator<"u"&&navigator?.language?O$.test(navigator.language)?"rtl":"ltr":"rtl"===e?"rtl":"ltr"}((t.body?t.body.dir:null)||(t.documentElement?t.documentElement.dir:null)||"ltr"))}ngOnDestroy(){this.change.complete()}}return n.\u0275fac=function(t){return new(t||n)(xe(R$,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),jv=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})();const N$=["text"];function B$(n,e){if(1&n&&qt(0,"mat-pseudo-checkbox",6),2&n){const t=Jt();$e("state",t.selected?"checked":"unchecked")("disabled",t.disabled)}}function V$(n,e){1&n&&qt(0,"mat-pseudo-checkbox",7),2&n&&$e("disabled",Jt().disabled)}function H$(n,e){if(1&n&&(ke(0,"span",8),it(1),Ne()),2&n){const t=Jt();Le(1),xs("(",t.group.label,")")}}const U$=[[["mat-icon"]],"*"],z$=["mat-icon","*"];let YL=(()=>{class n{}return n.STANDARD_CURVE="cubic-bezier(0.4,0.0,0.2,1)",n.DECELERATION_CURVE="cubic-bezier(0.0,0.0,0.2,1)",n.ACCELERATION_CURVE="cubic-bezier(0.4,0.0,1,1)",n.SHARP_CURVE="cubic-bezier(0.4,0.0,0.6,1)",n})(),XL=(()=>{class n{}return n.COMPLEX="375ms",n.ENTERING="225ms",n.EXITING="195ms",n})();const j$=new Ze("mat-sanity-checks",{providedIn:"root",factory:function G$(){return!0}});let rr=(()=>{class n{constructor(t,i,r){this._sanityChecks=i,this._document=r,this._hasDoneGlobalChecks=!1,t._applyBodyHighContrastModeCssClasses(),this._hasDoneGlobalChecks||(this._hasDoneGlobalChecks=!0)}_checkIsEnabled(t){return!CT()&&("boolean"==typeof this._sanityChecks?this._sanityChecks:!!this._sanityChecks[t])}}return n.\u0275fac=function(t){return new(t||n)(xe(WL),xe(j$,8),xe(Mn))},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[jv,jv]}),n})();function LT(n){return class extends n{get disabled(){return this._disabled}set disabled(e){this._disabled=bi(e)}constructor(...e){super(...e),this._disabled=!1}}}function NT(n,e){return class extends n{get color(){return this._color}set color(t){const i=t||this.defaultColor;i!==this._color&&(this._color&&this._elementRef.nativeElement.classList.remove(`mat-${this._color}`),i&&this._elementRef.nativeElement.classList.add(`mat-${i}`),this._color=i)}constructor(...t){super(...t),this.defaultColor=e,this.color=e}}}function Bw(n){return class extends n{get disableRipple(){return this._disableRipple}set disableRipple(e){this._disableRipple=bi(e)}constructor(...e){super(...e),this._disableRipple=!1}}}function ZL(n,e=0){return class extends n{get tabIndex(){return this.disabled?-1:this._tabIndex}set tabIndex(t){this._tabIndex=null!=t?ih(t):this.defaultTabIndex}constructor(...t){super(...t),this._tabIndex=e,this.defaultTabIndex=e}}}function W$(n){return class extends n{updateErrorState(){const e=this.errorState,s=(this.errorStateMatcher||this._defaultErrorStateMatcher).isErrorState(this.ngControl?this.ngControl.control:null,this._parentFormGroup||this._parentForm);s!==e&&(this.errorState=s,this.stateChanges.next())}constructor(...e){super(...e),this.errorState=!1}}}let q$=(()=>{class n{isErrorState(t,i){return!!(t&&t.invalid&&(t.touched||i&&i.submitted))}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();class K${constructor(e,t,i,r=!1){this._renderer=e,this.element=t,this.config=i,this._animationForciblyDisabledThroughCss=r,this.state=3}fadeOut(){this._renderer.fadeOutRipple(this)}}const JL=Vv({passive:!0,capture:!0});class Y${constructor(){this._events=new Map,this._delegateEventHandler=e=>{const t=th(e);t&&this._events.get(e.type)?.forEach((i,r)=>{(r===t||r.contains(t))&&i.forEach(s=>s.handleEvent(e))})}}addHandler(e,t,i,r){const s=this._events.get(t);if(s){const o=s.get(i);o?o.add(r):s.set(i,new Set([r]))}else this._events.set(t,new Map([[i,new Set([r])]])),e.runOutsideAngular(()=>{document.addEventListener(t,this._delegateEventHandler,JL)})}removeHandler(e,t,i){const r=this._events.get(e);if(!r)return;const s=r.get(t);s&&(s.delete(i),0===s.size&&r.delete(t),0===r.size&&(this._events.delete(e),document.removeEventListener(e,this._delegateEventHandler,JL)))}}const QL={enterDuration:225,exitDuration:150},eN=Vv({passive:!0,capture:!0}),tN=["mousedown","touchstart"],nN=["mouseup","mouseleave","touchend","touchcancel"];class ug{constructor(e,t,i,r){this._target=e,this._ngZone=t,this._platform=r,this._isPointerDown=!1,this._activeRipples=new Map,this._pointerUpEventsRegistered=!1,r.isBrowser&&(this._containerElement=Nf(i))}fadeInRipple(e,t,i={}){const r=this._containerRect=this._containerRect||this._containerElement.getBoundingClientRect(),s={...QL,...i.animation};i.centered&&(e=r.left+r.width/2,t=r.top+r.height/2);const o=i.radius||function Z$(n,e,t){const i=Math.max(Math.abs(n-t.left),Math.abs(n-t.right)),r=Math.max(Math.abs(e-t.top),Math.abs(e-t.bottom));return Math.sqrt(i*i+r*r)}(e,t,r),a=e-r.left,c=t-r.top,u=s.enterDuration,p=document.createElement("div");p.classList.add("mat-ripple-element"),p.style.left=a-o+"px",p.style.top=c-o+"px",p.style.height=2*o+"px",p.style.width=2*o+"px",null!=i.color&&(p.style.backgroundColor=i.color),p.style.transitionDuration=`${u}ms`,this._containerElement.appendChild(p);const g=window.getComputedStyle(p),y=g.transitionDuration,x="none"===g.transitionProperty||"0s"===y||"0s, 0s"===y||0===r.width&&0===r.height,T=new K$(this,p,i,x);p.style.transform="scale3d(1, 1, 1)",T.state=0,i.persistent||(this._mostRecentTransientRipple=T);let N=null;return!x&&(u||s.exitDuration)&&this._ngZone.runOutsideAngular(()=>{const k=()=>this._finishRippleTransition(T),A=()=>this._destroyRipple(T);p.addEventListener("transitionend",k),p.addEventListener("transitioncancel",A),N={onTransitionEnd:k,onTransitionCancel:A}}),this._activeRipples.set(T,N),(x||!u)&&this._finishRippleTransition(T),T}fadeOutRipple(e){if(2===e.state||3===e.state)return;const t=e.element,i={...QL,...e.config.animation};t.style.transitionDuration=`${i.exitDuration}ms`,t.style.opacity="0",e.state=2,(e._animationForciblyDisabledThroughCss||!i.exitDuration)&&this._finishRippleTransition(e)}fadeOutAll(){this._getActiveRipples().forEach(e=>e.fadeOut())}fadeOutAllNonPersistent(){this._getActiveRipples().forEach(e=>{e.config.persistent||e.fadeOut()})}setupTriggerEvents(e){const t=Nf(e);!this._platform.isBrowser||!t||t===this._triggerElement||(this._removeTriggerEvents(),this._triggerElement=t,tN.forEach(i=>{ug._eventManager.addHandler(this._ngZone,i,t,this)}))}handleEvent(e){"mousedown"===e.type?this._onMousedown(e):"touchstart"===e.type?this._onTouchStart(e):this._onPointerUp(),this._pointerUpEventsRegistered||(this._ngZone.runOutsideAngular(()=>{nN.forEach(t=>{this._triggerElement.addEventListener(t,this,eN)})}),this._pointerUpEventsRegistered=!0)}_finishRippleTransition(e){0===e.state?this._startFadeOutTransition(e):2===e.state&&this._destroyRipple(e)}_startFadeOutTransition(e){const t=e===this._mostRecentTransientRipple,{persistent:i}=e.config;e.state=1,!i&&(!t||!this._isPointerDown)&&e.fadeOut()}_destroyRipple(e){const t=this._activeRipples.get(e)??null;this._activeRipples.delete(e),this._activeRipples.size||(this._containerRect=null),e===this._mostRecentTransientRipple&&(this._mostRecentTransientRipple=null),e.state=3,null!==t&&(e.element.removeEventListener("transitionend",t.onTransitionEnd),e.element.removeEventListener("transitioncancel",t.onTransitionCancel)),e.element.remove()}_onMousedown(e){const t=HL(e),i=this._lastTouchStartEvent&&Date.now(){!e.config.persistent&&(1===e.state||e.config.terminateOnPointerUp&&0===e.state)&&e.fadeOut()}))}_getActiveRipples(){return Array.from(this._activeRipples.keys())}_removeTriggerEvents(){const e=this._triggerElement;e&&(tN.forEach(t=>ug._eventManager.removeHandler(t,e,this)),this._pointerUpEventsRegistered&&nN.forEach(t=>e.removeEventListener(t,this,eN)))}}ug._eventManager=new Y$;const Vw=new Ze("mat-ripple-global-options");let rh=(()=>{class n{get disabled(){return this._disabled}set disabled(t){t&&this.fadeOutAllNonPersistent(),this._disabled=t,this._setupTriggerEventsIfEnabled()}get trigger(){return this._trigger||this._elementRef.nativeElement}set trigger(t){this._trigger=t,this._setupTriggerEventsIfEnabled()}constructor(t,i,r,s,o){this._elementRef=t,this._animationMode=o,this.radius=0,this._disabled=!1,this._isInitialized=!1,this._globalOptions=s||{},this._rippleRenderer=new ug(this,i,t,r)}ngOnInit(){this._isInitialized=!0,this._setupTriggerEventsIfEnabled()}ngOnDestroy(){this._rippleRenderer._removeTriggerEvents()}fadeOutAll(){this._rippleRenderer.fadeOutAll()}fadeOutAllNonPersistent(){this._rippleRenderer.fadeOutAllNonPersistent()}get rippleConfig(){return{centered:this.centered,radius:this.radius,color:this.color,animation:{...this._globalOptions.animation,..."NoopAnimations"===this._animationMode?{enterDuration:0,exitDuration:0}:{},...this.animation},terminateOnPointerUp:this._globalOptions.terminateOnPointerUp}}get rippleDisabled(){return this.disabled||!!this._globalOptions.disabled}_setupTriggerEventsIfEnabled(){!this.disabled&&this._isInitialized&&this._rippleRenderer.setupTriggerEvents(this.trigger)}launch(t,i=0,r){return"number"==typeof t?this._rippleRenderer.fadeInRipple(t,i,{...this.rippleConfig,...r}):this._rippleRenderer.fadeInRipple(0,0,{...this.rippleConfig,...t})}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Xt),ie(as),ie(Vw,8),ie(bo,8))},n.\u0275dir=ut({type:n,selectors:[["","mat-ripple",""],["","matRipple",""]],hostAttrs:[1,"mat-ripple"],hostVars:2,hostBindings:function(t,i){2&t&&hi("mat-ripple-unbounded",i.unbounded)},inputs:{color:["matRippleColor","color"],unbounded:["matRippleUnbounded","unbounded"],centered:["matRippleCentered","centered"],radius:["matRippleRadius","radius"],animation:["matRippleAnimation","animation"],disabled:["matRippleDisabled","disabled"],trigger:["matRippleTrigger","trigger"]},exportAs:["matRipple"]}),n})(),$v=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,rr]}),n})(),J$=(()=>{class n{constructor(t){this._animationMode=t,this.state="unchecked",this.disabled=!1,this.appearance="full"}}return n.\u0275fac=function(t){return new(t||n)(ie(bo,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-pseudo-checkbox"]],hostAttrs:[1,"mat-pseudo-checkbox"],hostVars:12,hostBindings:function(t,i){2&t&&hi("mat-pseudo-checkbox-indeterminate","indeterminate"===i.state)("mat-pseudo-checkbox-checked","checked"===i.state)("mat-pseudo-checkbox-disabled",i.disabled)("mat-pseudo-checkbox-minimal","minimal"===i.appearance)("mat-pseudo-checkbox-full","full"===i.appearance)("_mat-animation-noopable","NoopAnimations"===i._animationMode)},inputs:{state:"state",disabled:"disabled",appearance:"appearance"},decls:0,vars:0,template:function(t,i){},styles:['.mat-pseudo-checkbox{border-radius:2px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1),background-color 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox::after{position:absolute;opacity:0;content:"";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox._mat-animation-noopable{transition:none !important;animation:none !important}.mat-pseudo-checkbox._mat-animation-noopable::after{transition:none}.mat-pseudo-checkbox-disabled{cursor:default}.mat-pseudo-checkbox-indeterminate::after{left:1px;opacity:1;border-radius:2px}.mat-pseudo-checkbox-checked::after{left:1px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box}.mat-pseudo-checkbox-full{border:2px solid}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate{border-color:rgba(0,0,0,0)}.mat-pseudo-checkbox{width:18px;height:18px}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked::after{width:14px;height:6px;transform-origin:center;top:-4.2426406871px;left:0;bottom:0;right:0;margin:auto}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate::after{top:8px;width:16px}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked::after{width:10px;height:4px;transform-origin:center;top:-2.8284271247px;left:0;bottom:0;right:0;margin:auto}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate::after{top:6px;width:12px}'],encapsulation:2,changeDetection:0}),n})(),iN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr]}),n})();const rN=new Ze("MAT_OPTION_PARENT_COMPONENT"),sN=new Ze("MatOptgroup");let Q$=0;class eq{constructor(e,t=!1){this.source=e,this.isUserInput=t}}let tq=(()=>{class n{get multiple(){return this._parent&&this._parent.multiple}get selected(){return this._selected}get disabled(){return this.group&&this.group.disabled||this._disabled}set disabled(t){this._disabled=bi(t)}get disableRipple(){return!(!this._parent||!this._parent.disableRipple)}get hideSingleSelectionIndicator(){return!(!this._parent||!this._parent.hideSingleSelectionIndicator)}constructor(t,i,r,s){this._element=t,this._changeDetectorRef=i,this._parent=r,this.group=s,this._selected=!1,this._active=!1,this._disabled=!1,this._mostRecentViewValue="",this.id="mat-option-"+Q$++,this.onSelectionChange=new Pn,this._stateChanges=new cn}get active(){return this._active}get viewValue(){return(this._text?.nativeElement.textContent||"").trim()}select(){this._selected||(this._selected=!0,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent())}deselect(){this._selected&&(this._selected=!1,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent())}focus(t,i){const r=this._getHostElement();"function"==typeof r.focus&&r.focus(i)}setActiveStyles(){this._active||(this._active=!0,this._changeDetectorRef.markForCheck())}setInactiveStyles(){this._active&&(this._active=!1,this._changeDetectorRef.markForCheck())}getLabel(){return this.viewValue}_handleKeydown(t){(13===t.keyCode||32===t.keyCode)&&!ql(t)&&(this._selectViaInteraction(),t.preventDefault())}_selectViaInteraction(){this.disabled||(this._selected=!this.multiple||!this._selected,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent(!0))}_getAriaSelected(){return this.selected||!this.multiple&&null}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._element.nativeElement}ngAfterViewChecked(){if(this._selected){const t=this.viewValue;t!==this._mostRecentViewValue&&(this._mostRecentViewValue&&this._stateChanges.next(),this._mostRecentViewValue=t)}}ngOnDestroy(){this._stateChanges.complete()}_emitSelectionChangeEvent(t=!1){this.onSelectionChange.emit(new eq(this,t))}}return n.\u0275fac=function(t){Gl()},n.\u0275dir=ut({type:n,viewQuery:function(t,i){if(1&t&&zr(N$,7),2&t){let r;Yn(r=Xn())&&(i._text=r.first)}},inputs:{value:"value",id:"id",disabled:"disabled"},outputs:{onSelectionChange:"onSelectionChange"}}),n})(),BT=(()=>{class n extends tq{constructor(t,i,r,s){super(t,i,r,s)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(aa),ie(rN,8),ie(sN,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-option"]],hostAttrs:["role","option",1,"mat-mdc-option","mat-mdc-focus-indicator","mdc-list-item"],hostVars:12,hostBindings:function(t,i){1&t&&Gn("click",function(){return i._selectViaInteraction()})("keydown",function(s){return i._handleKeydown(s)}),2&t&&(Af("id",i.id),Di("tabindex",i._getTabIndex())("aria-selected",i._getAriaSelected())("aria-disabled",i.disabled.toString()),hi("mdc-list-item--selected",i.selected)("mat-mdc-option-multiple",i.multiple)("mat-mdc-option-active",i.active)("mdc-list-item--disabled",i.disabled))},exportAs:["matOption"],features:[Z],ngContentSelectors:z$,decls:8,vars:5,consts:[["class","mat-mdc-option-pseudo-checkbox",3,"state","disabled",4,"ngIf"],[1,"mdc-list-item__primary-text"],["text",""],["class","mat-mdc-option-pseudo-checkbox","state","checked","appearance","minimal",3,"disabled",4,"ngIf"],["class","cdk-visually-hidden",4,"ngIf"],["mat-ripple","",1,"mat-mdc-option-ripple",3,"matRippleTrigger","matRippleDisabled"],[1,"mat-mdc-option-pseudo-checkbox",3,"state","disabled"],["state","checked","appearance","minimal",1,"mat-mdc-option-pseudo-checkbox",3,"disabled"],[1,"cdk-visually-hidden"]],template:function(t,i){1&t&&(Hs(U$),mt(0,B$,1,2,"mat-pseudo-checkbox",0),En(1),ke(2,"span",1,2),En(4,1),Ne(),mt(5,V$,1,1,"mat-pseudo-checkbox",3),mt(6,H$,2,1,"span",4),qt(7,"div",5)),2&t&&($e("ngIf",i.multiple),Le(5),$e("ngIf",!i.multiple&&i.selected&&!i.hideSingleSelectionIndicator),Le(1),$e("ngIf",i.group&&i.group._inert),Le(1),$e("matRippleTrigger",i._getHostElement())("matRippleDisabled",i.disabled||i.disableRipple))},dependencies:[rh,Yu,J$],styles:['.mat-mdc-option{display:flex;position:relative;align-items:center;justify-content:flex-start;overflow:hidden;padding:0;padding-left:16px;padding-right:16px;-webkit-user-select:none;user-select:none;cursor:pointer;-webkit-tap-highlight-color:rgba(0,0,0,0);min-height:48px}.mat-mdc-option:focus{outline:none}[dir=rtl] .mat-mdc-option,.mat-mdc-option[dir=rtl]{padding-left:16px;padding-right:16px}.mat-mdc-option.mdc-list-item{align-items:center}.mat-mdc-option.mdc-list-item--disabled{opacity:.38;cursor:default}.mat-mdc-optgroup .mat-mdc-option:not(.mat-mdc-option-multiple){padding-left:32px}[dir=rtl] .mat-mdc-optgroup .mat-mdc-option:not(.mat-mdc-option-multiple){padding-left:16px;padding-right:32px}.mat-mdc-option .mat-icon,.mat-mdc-option .mat-pseudo-checkbox-full{margin-right:16px;flex-shrink:0}[dir=rtl] .mat-mdc-option .mat-icon,[dir=rtl] .mat-mdc-option .mat-pseudo-checkbox-full{margin-right:0;margin-left:16px}.mat-mdc-option .mat-pseudo-checkbox-minimal{margin-left:16px;flex-shrink:0}[dir=rtl] .mat-mdc-option .mat-pseudo-checkbox-minimal{margin-right:16px;margin-left:0}.mat-mdc-option .mat-mdc-option-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-mdc-option .mdc-list-item__primary-text{white-space:normal;font-size:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;font-family:inherit;text-decoration:inherit;text-transform:inherit;margin-right:auto}[dir=rtl] .mat-mdc-option .mdc-list-item__primary-text{margin-right:0;margin-left:auto}.cdk-high-contrast-active .mat-mdc-option.mdc-list-item--selected:not(.mat-mdc-option-multiple)::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}[dir=rtl] .cdk-high-contrast-active .mat-mdc-option.mdc-list-item--selected:not(.mat-mdc-option-multiple)::after{right:auto;left:16px}.mat-mdc-option-active::before{content:""}'],encapsulation:2,changeDetection:0}),n})(),oN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[$v,ul,rr,iN]}),n})();const aN=["mat-button",""],VT=[[["",8,"material-icons",3,"iconPositionEnd",""],["mat-icon",3,"iconPositionEnd",""],["","matButtonIcon","",3,"iconPositionEnd",""]],"*",[["","iconPositionEnd","",8,"material-icons"],["mat-icon","iconPositionEnd",""],["","matButtonIcon","","iconPositionEnd",""]]],HT=[".material-icons:not([iconPositionEnd]), mat-icon:not([iconPositionEnd]), [matButtonIcon]:not([iconPositionEnd])","*",".material-icons[iconPositionEnd], mat-icon[iconPositionEnd], [matButtonIcon][iconPositionEnd]"],oq=["mat-mini-fab",""],cq=[{selector:"mat-button",mdcClasses:["mdc-button","mat-mdc-button"]},{selector:"mat-flat-button",mdcClasses:["mdc-button","mdc-button--unelevated","mat-mdc-unelevated-button"]},{selector:"mat-raised-button",mdcClasses:["mdc-button","mdc-button--raised","mat-mdc-raised-button"]},{selector:"mat-stroked-button",mdcClasses:["mdc-button","mdc-button--outlined","mat-mdc-outlined-button"]},{selector:"mat-fab",mdcClasses:["mdc-fab","mat-mdc-fab"]},{selector:"mat-mini-fab",mdcClasses:["mdc-fab","mdc-fab--mini","mat-mdc-mini-fab"]},{selector:"mat-icon-button",mdcClasses:["mdc-icon-button","mat-mdc-icon-button"]}],lq=NT(LT(Bw(class{constructor(n){this._elementRef=n}})));let UT=(()=>{class n extends lq{constructor(t,i,r,s){super(t),this._platform=i,this._ngZone=r,this._animationMode=s,this._focusMonitor=hn(Vf),this._isFab=!1;const o=t.nativeElement.classList;for(const a of cq)this._hasHostAttributes(a.selector)&&a.mdcClasses.forEach(c=>{o.add(c)})}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef)}focus(t="program",i){t?this._focusMonitor.focusVia(this._elementRef.nativeElement,t,i):this._elementRef.nativeElement.focus(i)}_hasHostAttributes(...t){return t.some(i=>this._elementRef.nativeElement.hasAttribute(i))}_isRippleDisabled(){return this.disableRipple||this.disabled}}return n.\u0275fac=function(t){Gl()},n.\u0275dir=ut({type:n,viewQuery:function(t,i){if(1&t&&zr(rh,5),2&t){let r;Yn(r=Xn())&&(i.ripple=r.first)}},features:[Z]}),n})(),uq=(()=>{class n extends UT{constructor(t,i,r,s){super(t,i,r,s),this._haltDisabledEvents=o=>{this.disabled&&(o.preventDefault(),o.stopImmediatePropagation())}}ngOnInit(){this._ngZone.runOutsideAngular(()=>{this._elementRef.nativeElement.addEventListener("click",this._haltDisabledEvents)})}ngOnDestroy(){super.ngOnDestroy(),this._elementRef.nativeElement.removeEventListener("click",this._haltDisabledEvents)}}return n.\u0275fac=function(t){Gl()},n.\u0275dir=ut({type:n,features:[Z]}),n})(),cN=(()=>{class n extends UT{constructor(t,i,r,s){super(t,i,r,s)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(as),ie(Xt),ie(bo,8))},n.\u0275cmp=Ln({type:n,selectors:[["button","mat-button",""],["button","mat-raised-button",""],["button","mat-flat-button",""],["button","mat-stroked-button",""]],hostVars:7,hostBindings:function(t,i){2&t&&(Di("disabled",i.disabled||null),hi("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mat-unthemed",!i.color)("mat-mdc-button-base",!0))},inputs:{disabled:"disabled",disableRipple:"disableRipple",color:"color"},exportAs:["matButton"],features:[Z],attrs:aN,ngContentSelectors:HT,decls:8,vars:6,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-mdc-focus-indicator"],["matRipple","",1,"mat-mdc-button-ripple",3,"matRippleDisabled","matRippleTrigger"],[1,"mat-mdc-button-touch-target"]],template:function(t,i){1&t&&(Hs(VT),qt(0,"span",0),En(1),ke(2,"span",1),En(3,1),Ne(),En(4,2),qt(5,"span",2)(6,"span",3)(7,"span",4)),2&t&&(hi("mdc-button__ripple",!i._isFab)("mdc-fab__ripple",i._isFab),Le(6),$e("matRippleDisabled",i._isRippleDisabled())("matRippleTrigger",i._elementRef.nativeElement))},dependencies:[rh],styles:['.mdc-touch-target-wrapper{display:inline}.mdc-elevation-overlay{position:absolute;border-radius:inherit;pointer-events:none;opacity:var(--mdc-elevation-overlay-opacity, 0);transition:opacity 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-button{position:relative;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:64px;border:none;outline:none;line-height:inherit;user-select:none;-webkit-appearance:none;overflow:visible;vertical-align:middle;background:rgba(0,0,0,0)}.mdc-button .mdc-elevation-overlay{width:100%;height:100%;top:0;left:0}.mdc-button::-moz-focus-inner{padding:0;border:0}.mdc-button:active{outline:none}.mdc-button:hover{cursor:pointer}.mdc-button:disabled{cursor:default;pointer-events:none}.mdc-button[hidden]{display:none}.mdc-button .mdc-button__icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top}[dir=rtl] .mdc-button .mdc-button__icon,.mdc-button .mdc-button__icon[dir=rtl]{margin-left:8px;margin-right:0}.mdc-button .mdc-button__progress-indicator{font-size:0;position:absolute;transform:translate(-50%, -50%);top:50%;left:50%;line-height:initial}.mdc-button .mdc-button__label{position:relative}.mdc-button .mdc-button__focus-ring{pointer-events:none;border:2px solid rgba(0,0,0,0);border-radius:6px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(\n 100% + 4px\n );width:calc(\n 100% + 4px\n );display:none}@media screen and (forced-colors: active){.mdc-button .mdc-button__focus-ring{border-color:CanvasText}}.mdc-button .mdc-button__focus-ring::after{content:"";border:2px solid rgba(0,0,0,0);border-radius:8px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-button .mdc-button__focus-ring::after{border-color:CanvasText}}@media screen and (forced-colors: active){.mdc-button.mdc-ripple-upgraded--background-focused .mdc-button__focus-ring,.mdc-button:not(.mdc-ripple-upgraded):focus .mdc-button__focus-ring{display:block}}.mdc-button .mdc-button__touch{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%)}.mdc-button__label+.mdc-button__icon{margin-left:8px;margin-right:0}[dir=rtl] .mdc-button__label+.mdc-button__icon,.mdc-button__label+.mdc-button__icon[dir=rtl]{margin-left:0;margin-right:8px}svg.mdc-button__icon{fill:currentColor}.mdc-button--touch{margin-top:6px;margin-bottom:6px}.mdc-button{padding:0 8px 0 8px}.mdc-button--unelevated{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);padding:0 16px 0 16px}.mdc-button--unelevated.mdc-button--icon-trailing{padding:0 12px 0 16px}.mdc-button--unelevated.mdc-button--icon-leading{padding:0 16px 0 12px}.mdc-button--raised{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);padding:0 16px 0 16px}.mdc-button--raised.mdc-button--icon-trailing{padding:0 12px 0 16px}.mdc-button--raised.mdc-button--icon-leading{padding:0 16px 0 12px}.mdc-button--outlined{border-style:solid;transition:border 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-button--outlined .mdc-button__ripple{border-style:solid;border-color:rgba(0,0,0,0)}.mat-mdc-button{height:var(--mdc-text-button-container-height, 36px);border-radius:var(--mdc-text-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-button:not(:disabled){color:var(--mdc-text-button-label-text-color, inherit)}.mat-mdc-button:disabled{color:var(--mdc-text-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-button .mdc-button__ripple{border-radius:var(--mdc-text-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-unelevated-button{height:var(--mdc-filled-button-container-height, 36px);border-radius:var(--mdc-filled-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-unelevated-button:not(:disabled){background-color:var(--mdc-filled-button-container-color, transparent)}.mat-mdc-unelevated-button:disabled{background-color:var(--mdc-filled-button-disabled-container-color, rgba(0, 0, 0, 0.12))}.mat-mdc-unelevated-button:not(:disabled){color:var(--mdc-filled-button-label-text-color, inherit)}.mat-mdc-unelevated-button:disabled{color:var(--mdc-filled-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-unelevated-button .mdc-button__ripple{border-radius:var(--mdc-filled-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-raised-button{height:var(--mdc-protected-button-container-height, 36px);border-radius:var(--mdc-protected-button-container-shape, var(--mdc-shape-small, 4px));box-shadow:var(--mdc-protected-button-container-elevation, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled){background-color:var(--mdc-protected-button-container-color, transparent)}.mat-mdc-raised-button:disabled{background-color:var(--mdc-protected-button-disabled-container-color, rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled){color:var(--mdc-protected-button-label-text-color, inherit)}.mat-mdc-raised-button:disabled{color:var(--mdc-protected-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-raised-button .mdc-button__ripple{border-radius:var(--mdc-protected-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-raised-button.mdc-ripple-upgraded--background-focused,.mat-mdc-raised-button:not(.mdc-ripple-upgraded):focus{box-shadow:var(--mdc-protected-button-focus-container-elevation, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:hover{box-shadow:var(--mdc-protected-button-hover-container-elevation, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled):active{box-shadow:var(--mdc-protected-button-pressed-container-elevation, 0px 5px 5px -3px rgba(0, 0, 0, 0.2), 0px 8px 10px 1px rgba(0, 0, 0, 0.14), 0px 3px 14px 2px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:disabled{box-shadow:var(--mdc-protected-button-disabled-container-elevation, 0px 0px 0px 0px rgba(0, 0, 0, 0.2), 0px 0px 0px 0px rgba(0, 0, 0, 0.14), 0px 0px 0px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button{height:var(--mdc-outlined-button-container-height, 36px);border-radius:var(--mdc-outlined-button-container-shape, var(--mdc-shape-small, 4px));padding:0 15px 0 15px;border-width:var(--mdc-outlined-button-outline-width, 1px)}.mat-mdc-outlined-button:not(:disabled){color:var(--mdc-outlined-button-label-text-color, inherit)}.mat-mdc-outlined-button:disabled{color:var(--mdc-outlined-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-outlined-button .mdc-button__ripple{border-radius:var(--mdc-outlined-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-outlined-button:not(:disabled){border-color:var(--mdc-outlined-button-outline-color, rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button:disabled{border-color:var(--mdc-outlined-button-disabled-outline-color, rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button.mdc-button--icon-trailing{padding:0 11px 0 15px}.mat-mdc-outlined-button.mdc-button--icon-leading{padding:0 15px 0 11px}.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px;border-width:var(--mdc-outlined-button-outline-width, 1px)}.mat-mdc-outlined-button .mdc-button__touch{left:calc(-1 * var(--mdc-outlined-button-outline-width, 1px));width:calc(100% + 2 * var(--mdc-outlined-button-outline-width, 1px))}.mat-mdc-button,.mat-mdc-unelevated-button,.mat-mdc-raised-button,.mat-mdc-outlined-button{-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-button .mat-mdc-button-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0;background-color:var(--mat-mdc-button-persistent-ripple-color)}.mat-mdc-button .mat-ripple-element,.mat-mdc-unelevated-button .mat-ripple-element,.mat-mdc-raised-button .mat-ripple-element,.mat-mdc-outlined-button .mat-ripple-element{background-color:var(--mat-mdc-button-ripple-color)}.mat-mdc-button .mdc-button__label,.mat-mdc-unelevated-button .mdc-button__label,.mat-mdc-raised-button .mdc-button__label,.mat-mdc-outlined-button .mdc-button__label{z-index:1}.mat-mdc-button .mat-mdc-focus-indicator,.mat-mdc-unelevated-button .mat-mdc-focus-indicator,.mat-mdc-raised-button .mat-mdc-focus-indicator,.mat-mdc-outlined-button .mat-mdc-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-unelevated-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-raised-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-outlined-button:focus .mat-mdc-focus-indicator::before{content:""}.mat-mdc-button[disabled],.mat-mdc-unelevated-button[disabled],.mat-mdc-raised-button[disabled],.mat-mdc-outlined-button[disabled]{cursor:default;pointer-events:none}.mat-mdc-button .mat-mdc-button-touch-target,.mat-mdc-unelevated-button .mat-mdc-button-touch-target,.mat-mdc-raised-button .mat-mdc-button-touch-target,.mat-mdc-outlined-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%)}.mat-mdc-button._mat-animation-noopable,.mat-mdc-unelevated-button._mat-animation-noopable,.mat-mdc-raised-button._mat-animation-noopable,.mat-mdc-outlined-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-button>.mat-icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem}[dir=rtl] .mat-mdc-button>.mat-icon,.mat-mdc-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:0}.mat-mdc-button .mdc-button__label+.mat-icon{margin-left:8px;margin-right:0}[dir=rtl] .mat-mdc-button .mdc-button__label+.mat-icon,.mat-mdc-button .mdc-button__label+.mat-icon[dir=rtl]{margin-left:0;margin-right:8px}.mat-mdc-unelevated-button>.mat-icon,.mat-mdc-raised-button>.mat-icon,.mat-mdc-outlined-button>.mat-icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem;margin-left:-4px;margin-right:8px}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon,[dir=rtl] .mat-mdc-raised-button>.mat-icon,[dir=rtl] .mat-mdc-outlined-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon[dir=rtl],.mat-mdc-raised-button>.mat-icon[dir=rtl],.mat-mdc-outlined-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:0}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon,[dir=rtl] .mat-mdc-raised-button>.mat-icon,[dir=rtl] .mat-mdc-outlined-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon[dir=rtl],.mat-mdc-raised-button>.mat-icon[dir=rtl],.mat-mdc-outlined-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:-4px}.mat-mdc-unelevated-button .mdc-button__label+.mat-icon,.mat-mdc-raised-button .mdc-button__label+.mat-icon,.mat-mdc-outlined-button .mdc-button__label+.mat-icon{margin-left:8px;margin-right:-4px}[dir=rtl] .mat-mdc-unelevated-button .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-raised-button .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-outlined-button .mdc-button__label+.mat-icon,.mat-mdc-unelevated-button .mdc-button__label+.mat-icon[dir=rtl],.mat-mdc-raised-button .mdc-button__label+.mat-icon[dir=rtl],.mat-mdc-outlined-button .mdc-button__label+.mat-icon[dir=rtl]{margin-left:-4px;margin-right:8px}.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px;border-width:-1px}.mat-mdc-unelevated-button .mat-mdc-focus-indicator::before,.mat-mdc-raised-button .mat-mdc-focus-indicator::before{margin:calc(calc(var(--mat-mdc-focus-indicator-border-width, 3px) + 2px) * -1)}.mat-mdc-outlined-button .mat-mdc-focus-indicator::before{margin:calc(calc(var(--mat-mdc-focus-indicator-border-width, 3px) + 3px) * -1)}',".cdk-high-contrast-active .mat-mdc-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-unelevated-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-raised-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-outlined-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-icon-button{outline:solid 1px}"],encapsulation:2,changeDetection:0}),n})(),hq=(()=>{class n extends uq{constructor(t,i,r,s){super(t,i,r,s)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(as),ie(Xt),ie(bo,8))},n.\u0275cmp=Ln({type:n,selectors:[["a","mat-button",""],["a","mat-raised-button",""],["a","mat-flat-button",""],["a","mat-stroked-button",""]],hostVars:9,hostBindings:function(t,i){2&t&&(Di("disabled",i.disabled||null)("tabindex",i.disabled?-1:i.tabIndex)("aria-disabled",i.disabled.toString()),hi("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mat-unthemed",!i.color)("mat-mdc-button-base",!0))},inputs:{disabled:"disabled",disableRipple:"disableRipple",color:"color",tabIndex:"tabIndex"},exportAs:["matButton","matAnchor"],features:[Z],attrs:aN,ngContentSelectors:HT,decls:8,vars:6,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-mdc-focus-indicator"],["matRipple","",1,"mat-mdc-button-ripple",3,"matRippleDisabled","matRippleTrigger"],[1,"mat-mdc-button-touch-target"]],template:function(t,i){1&t&&(Hs(VT),qt(0,"span",0),En(1),ke(2,"span",1),En(3,1),Ne(),En(4,2),qt(5,"span",2)(6,"span",3)(7,"span",4)),2&t&&(hi("mdc-button__ripple",!i._isFab)("mdc-fab__ripple",i._isFab),Le(6),$e("matRippleDisabled",i._isRippleDisabled())("matRippleTrigger",i._elementRef.nativeElement))},dependencies:[rh],styles:['.mdc-touch-target-wrapper{display:inline}.mdc-elevation-overlay{position:absolute;border-radius:inherit;pointer-events:none;opacity:var(--mdc-elevation-overlay-opacity, 0);transition:opacity 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-button{position:relative;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:64px;border:none;outline:none;line-height:inherit;user-select:none;-webkit-appearance:none;overflow:visible;vertical-align:middle;background:rgba(0,0,0,0)}.mdc-button .mdc-elevation-overlay{width:100%;height:100%;top:0;left:0}.mdc-button::-moz-focus-inner{padding:0;border:0}.mdc-button:active{outline:none}.mdc-button:hover{cursor:pointer}.mdc-button:disabled{cursor:default;pointer-events:none}.mdc-button[hidden]{display:none}.mdc-button .mdc-button__icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top}[dir=rtl] .mdc-button .mdc-button__icon,.mdc-button .mdc-button__icon[dir=rtl]{margin-left:8px;margin-right:0}.mdc-button .mdc-button__progress-indicator{font-size:0;position:absolute;transform:translate(-50%, -50%);top:50%;left:50%;line-height:initial}.mdc-button .mdc-button__label{position:relative}.mdc-button .mdc-button__focus-ring{pointer-events:none;border:2px solid rgba(0,0,0,0);border-radius:6px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(\n 100% + 4px\n );width:calc(\n 100% + 4px\n );display:none}@media screen and (forced-colors: active){.mdc-button .mdc-button__focus-ring{border-color:CanvasText}}.mdc-button .mdc-button__focus-ring::after{content:"";border:2px solid rgba(0,0,0,0);border-radius:8px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-button .mdc-button__focus-ring::after{border-color:CanvasText}}@media screen and (forced-colors: active){.mdc-button.mdc-ripple-upgraded--background-focused .mdc-button__focus-ring,.mdc-button:not(.mdc-ripple-upgraded):focus .mdc-button__focus-ring{display:block}}.mdc-button .mdc-button__touch{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%)}.mdc-button__label+.mdc-button__icon{margin-left:8px;margin-right:0}[dir=rtl] .mdc-button__label+.mdc-button__icon,.mdc-button__label+.mdc-button__icon[dir=rtl]{margin-left:0;margin-right:8px}svg.mdc-button__icon{fill:currentColor}.mdc-button--touch{margin-top:6px;margin-bottom:6px}.mdc-button{padding:0 8px 0 8px}.mdc-button--unelevated{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);padding:0 16px 0 16px}.mdc-button--unelevated.mdc-button--icon-trailing{padding:0 12px 0 16px}.mdc-button--unelevated.mdc-button--icon-leading{padding:0 16px 0 12px}.mdc-button--raised{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);padding:0 16px 0 16px}.mdc-button--raised.mdc-button--icon-trailing{padding:0 12px 0 16px}.mdc-button--raised.mdc-button--icon-leading{padding:0 16px 0 12px}.mdc-button--outlined{border-style:solid;transition:border 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-button--outlined .mdc-button__ripple{border-style:solid;border-color:rgba(0,0,0,0)}.mat-mdc-button{height:var(--mdc-text-button-container-height, 36px);border-radius:var(--mdc-text-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-button:not(:disabled){color:var(--mdc-text-button-label-text-color, inherit)}.mat-mdc-button:disabled{color:var(--mdc-text-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-button .mdc-button__ripple{border-radius:var(--mdc-text-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-unelevated-button{height:var(--mdc-filled-button-container-height, 36px);border-radius:var(--mdc-filled-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-unelevated-button:not(:disabled){background-color:var(--mdc-filled-button-container-color, transparent)}.mat-mdc-unelevated-button:disabled{background-color:var(--mdc-filled-button-disabled-container-color, rgba(0, 0, 0, 0.12))}.mat-mdc-unelevated-button:not(:disabled){color:var(--mdc-filled-button-label-text-color, inherit)}.mat-mdc-unelevated-button:disabled{color:var(--mdc-filled-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-unelevated-button .mdc-button__ripple{border-radius:var(--mdc-filled-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-raised-button{height:var(--mdc-protected-button-container-height, 36px);border-radius:var(--mdc-protected-button-container-shape, var(--mdc-shape-small, 4px));box-shadow:var(--mdc-protected-button-container-elevation, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled){background-color:var(--mdc-protected-button-container-color, transparent)}.mat-mdc-raised-button:disabled{background-color:var(--mdc-protected-button-disabled-container-color, rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled){color:var(--mdc-protected-button-label-text-color, inherit)}.mat-mdc-raised-button:disabled{color:var(--mdc-protected-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-raised-button .mdc-button__ripple{border-radius:var(--mdc-protected-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-raised-button.mdc-ripple-upgraded--background-focused,.mat-mdc-raised-button:not(.mdc-ripple-upgraded):focus{box-shadow:var(--mdc-protected-button-focus-container-elevation, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:hover{box-shadow:var(--mdc-protected-button-hover-container-elevation, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled):active{box-shadow:var(--mdc-protected-button-pressed-container-elevation, 0px 5px 5px -3px rgba(0, 0, 0, 0.2), 0px 8px 10px 1px rgba(0, 0, 0, 0.14), 0px 3px 14px 2px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:disabled{box-shadow:var(--mdc-protected-button-disabled-container-elevation, 0px 0px 0px 0px rgba(0, 0, 0, 0.2), 0px 0px 0px 0px rgba(0, 0, 0, 0.14), 0px 0px 0px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button{height:var(--mdc-outlined-button-container-height, 36px);border-radius:var(--mdc-outlined-button-container-shape, var(--mdc-shape-small, 4px));padding:0 15px 0 15px;border-width:var(--mdc-outlined-button-outline-width, 1px)}.mat-mdc-outlined-button:not(:disabled){color:var(--mdc-outlined-button-label-text-color, inherit)}.mat-mdc-outlined-button:disabled{color:var(--mdc-outlined-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-outlined-button .mdc-button__ripple{border-radius:var(--mdc-outlined-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-outlined-button:not(:disabled){border-color:var(--mdc-outlined-button-outline-color, rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button:disabled{border-color:var(--mdc-outlined-button-disabled-outline-color, rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button.mdc-button--icon-trailing{padding:0 11px 0 15px}.mat-mdc-outlined-button.mdc-button--icon-leading{padding:0 15px 0 11px}.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px;border-width:var(--mdc-outlined-button-outline-width, 1px)}.mat-mdc-outlined-button .mdc-button__touch{left:calc(-1 * var(--mdc-outlined-button-outline-width, 1px));width:calc(100% + 2 * var(--mdc-outlined-button-outline-width, 1px))}.mat-mdc-button,.mat-mdc-unelevated-button,.mat-mdc-raised-button,.mat-mdc-outlined-button{-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-button .mat-mdc-button-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0;background-color:var(--mat-mdc-button-persistent-ripple-color)}.mat-mdc-button .mat-ripple-element,.mat-mdc-unelevated-button .mat-ripple-element,.mat-mdc-raised-button .mat-ripple-element,.mat-mdc-outlined-button .mat-ripple-element{background-color:var(--mat-mdc-button-ripple-color)}.mat-mdc-button .mdc-button__label,.mat-mdc-unelevated-button .mdc-button__label,.mat-mdc-raised-button .mdc-button__label,.mat-mdc-outlined-button .mdc-button__label{z-index:1}.mat-mdc-button .mat-mdc-focus-indicator,.mat-mdc-unelevated-button .mat-mdc-focus-indicator,.mat-mdc-raised-button .mat-mdc-focus-indicator,.mat-mdc-outlined-button .mat-mdc-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-unelevated-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-raised-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-outlined-button:focus .mat-mdc-focus-indicator::before{content:""}.mat-mdc-button[disabled],.mat-mdc-unelevated-button[disabled],.mat-mdc-raised-button[disabled],.mat-mdc-outlined-button[disabled]{cursor:default;pointer-events:none}.mat-mdc-button .mat-mdc-button-touch-target,.mat-mdc-unelevated-button .mat-mdc-button-touch-target,.mat-mdc-raised-button .mat-mdc-button-touch-target,.mat-mdc-outlined-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%)}.mat-mdc-button._mat-animation-noopable,.mat-mdc-unelevated-button._mat-animation-noopable,.mat-mdc-raised-button._mat-animation-noopable,.mat-mdc-outlined-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-button>.mat-icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem}[dir=rtl] .mat-mdc-button>.mat-icon,.mat-mdc-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:0}.mat-mdc-button .mdc-button__label+.mat-icon{margin-left:8px;margin-right:0}[dir=rtl] .mat-mdc-button .mdc-button__label+.mat-icon,.mat-mdc-button .mdc-button__label+.mat-icon[dir=rtl]{margin-left:0;margin-right:8px}.mat-mdc-unelevated-button>.mat-icon,.mat-mdc-raised-button>.mat-icon,.mat-mdc-outlined-button>.mat-icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem;margin-left:-4px;margin-right:8px}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon,[dir=rtl] .mat-mdc-raised-button>.mat-icon,[dir=rtl] .mat-mdc-outlined-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon[dir=rtl],.mat-mdc-raised-button>.mat-icon[dir=rtl],.mat-mdc-outlined-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:0}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon,[dir=rtl] .mat-mdc-raised-button>.mat-icon,[dir=rtl] .mat-mdc-outlined-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon[dir=rtl],.mat-mdc-raised-button>.mat-icon[dir=rtl],.mat-mdc-outlined-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:-4px}.mat-mdc-unelevated-button .mdc-button__label+.mat-icon,.mat-mdc-raised-button .mdc-button__label+.mat-icon,.mat-mdc-outlined-button .mdc-button__label+.mat-icon{margin-left:8px;margin-right:-4px}[dir=rtl] .mat-mdc-unelevated-button .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-raised-button .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-outlined-button .mdc-button__label+.mat-icon,.mat-mdc-unelevated-button .mdc-button__label+.mat-icon[dir=rtl],.mat-mdc-raised-button .mdc-button__label+.mat-icon[dir=rtl],.mat-mdc-outlined-button .mdc-button__label+.mat-icon[dir=rtl]{margin-left:-4px;margin-right:8px}.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px;border-width:-1px}.mat-mdc-unelevated-button .mat-mdc-focus-indicator::before,.mat-mdc-raised-button .mat-mdc-focus-indicator::before{margin:calc(calc(var(--mat-mdc-focus-indicator-border-width, 3px) + 2px) * -1)}.mat-mdc-outlined-button .mat-mdc-focus-indicator::before{margin:calc(calc(var(--mat-mdc-focus-indicator-border-width, 3px) + 3px) * -1)}',".cdk-high-contrast-active .mat-mdc-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-unelevated-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-raised-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-outlined-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-icon-button{outline:solid 1px}"],encapsulation:2,changeDetection:0}),n})();const fq=new Ze("mat-mdc-fab-default-options",{providedIn:"root",factory:lN});function lN(){return{color:"accent"}}const dN=lN();let pq=(()=>{class n extends UT{constructor(t,i,r,s,o){super(t,i,r,s),this._options=o,this._isFab=!0,this._options=this._options||dN,this.color=this.defaultColor=this._options.color||dN.color}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(as),ie(Xt),ie(bo,8),ie(fq,8))},n.\u0275cmp=Ln({type:n,selectors:[["button","mat-mini-fab",""]],hostVars:7,hostBindings:function(t,i){2&t&&(Di("disabled",i.disabled||null),hi("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mat-unthemed",!i.color)("mat-mdc-button-base",!0))},inputs:{disabled:"disabled",disableRipple:"disableRipple",color:"color"},exportAs:["matButton"],features:[Z],attrs:oq,ngContentSelectors:HT,decls:8,vars:6,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-mdc-focus-indicator"],["matRipple","",1,"mat-mdc-button-ripple",3,"matRippleDisabled","matRippleTrigger"],[1,"mat-mdc-button-touch-target"]],template:function(t,i){1&t&&(Hs(VT),qt(0,"span",0),En(1),ke(2,"span",1),En(3,1),Ne(),En(4,2),qt(5,"span",2)(6,"span",3)(7,"span",4)),2&t&&(hi("mdc-button__ripple",!i._isFab)("mdc-fab__ripple",i._isFab),Le(6),$e("matRippleDisabled",i._isRippleDisabled())("matRippleTrigger",i._elementRef.nativeElement))},dependencies:[rh],styles:['.mdc-touch-target-wrapper{display:inline}.mdc-elevation-overlay{position:absolute;border-radius:inherit;pointer-events:none;opacity:var(--mdc-elevation-overlay-opacity, 0);transition:opacity 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-fab{position:relative;display:inline-flex;position:relative;align-items:center;justify-content:center;box-sizing:border-box;width:56px;height:56px;padding:0;border:none;fill:currentColor;text-decoration:none;cursor:pointer;user-select:none;-moz-appearance:none;-webkit-appearance:none;overflow:visible;transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1),opacity 15ms linear 30ms,transform 270ms 0ms cubic-bezier(0, 0, 0.2, 1)}.mdc-fab .mdc-elevation-overlay{width:100%;height:100%;top:0;left:0}.mdc-fab[hidden]{display:none}.mdc-fab::-moz-focus-inner{padding:0;border:0}.mdc-fab .mdc-fab__focus-ring{position:absolute}.mdc-fab.mdc-ripple-upgraded--background-focused .mdc-fab__focus-ring,.mdc-fab:not(.mdc-ripple-upgraded):focus .mdc-fab__focus-ring{pointer-events:none;border:2px solid rgba(0,0,0,0);border-radius:6px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(\n 100% + 4px\n );width:calc(\n 100% + 4px\n )}@media screen and (forced-colors: active){.mdc-fab.mdc-ripple-upgraded--background-focused .mdc-fab__focus-ring,.mdc-fab:not(.mdc-ripple-upgraded):focus .mdc-fab__focus-ring{border-color:CanvasText}}.mdc-fab.mdc-ripple-upgraded--background-focused .mdc-fab__focus-ring::after,.mdc-fab:not(.mdc-ripple-upgraded):focus .mdc-fab__focus-ring::after{content:"";border:2px solid rgba(0,0,0,0);border-radius:8px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-fab.mdc-ripple-upgraded--background-focused .mdc-fab__focus-ring::after,.mdc-fab:not(.mdc-ripple-upgraded):focus .mdc-fab__focus-ring::after{border-color:CanvasText}}.mdc-fab:active,.mdc-fab:focus{outline:none}.mdc-fab:hover{cursor:pointer}.mdc-fab>svg{width:100%}.mdc-fab--mini{width:40px;height:40px}.mdc-fab--extended{border-radius:24px;padding-left:20px;padding-right:20px;width:auto;max-width:100%;height:48px;line-height:normal}.mdc-fab--extended .mdc-fab__ripple{border-radius:24px}.mdc-fab--extended .mdc-fab__icon{margin-left:calc(12px - 20px);margin-right:12px}[dir=rtl] .mdc-fab--extended .mdc-fab__icon,.mdc-fab--extended .mdc-fab__icon[dir=rtl]{margin-left:12px;margin-right:calc(12px - 20px)}.mdc-fab--extended .mdc-fab__label+.mdc-fab__icon{margin-left:12px;margin-right:calc(12px - 20px)}[dir=rtl] .mdc-fab--extended .mdc-fab__label+.mdc-fab__icon,.mdc-fab--extended .mdc-fab__label+.mdc-fab__icon[dir=rtl]{margin-left:calc(12px - 20px);margin-right:12px}.mdc-fab--touch{margin-top:4px;margin-bottom:4px;margin-right:4px;margin-left:4px}.mdc-fab--touch .mdc-fab__touch{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%)}.mdc-fab::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-fab::before{border-color:CanvasText}}.mdc-fab__label{justify-content:flex-start;text-overflow:ellipsis;white-space:nowrap;overflow-x:hidden;overflow-y:visible}.mdc-fab__icon{transition:transform 180ms 90ms cubic-bezier(0, 0, 0.2, 1);fill:currentColor;will-change:transform}.mdc-fab .mdc-fab__icon{display:inline-flex;align-items:center;justify-content:center}.mdc-fab--exited{transform:scale(0);opacity:0;transition:opacity 15ms linear 150ms,transform 180ms 0ms cubic-bezier(0.4, 0, 1, 1)}.mdc-fab--exited .mdc-fab__icon{transform:scale(0);transition:transform 135ms 0ms cubic-bezier(0.4, 0, 1, 1)}.mdc-fab .mdc-fab__icon{width:24px;height:24px;font-size:24px}.mdc-fab:not(.mdc-fab--extended){border-radius:50%}.mdc-fab:not(.mdc-fab--extended) .mdc-fab__ripple{border-radius:50%}.mat-mdc-fab,.mat-mdc-mini-fab{-webkit-tap-highlight-color:rgba(0,0,0,0);background-color:var(--mdc-fab-container-color, transparent);box-shadow:0px 3px 5px -1px rgba(0, 0, 0, 0.2), 0px 6px 10px 0px rgba(0, 0, 0, 0.14), 0px 1px 18px 0px rgba(0, 0, 0, 0.12);color:var(--mat-mdc-fab-color, inherit);flex-shrink:0}.mat-mdc-fab .mat-mdc-button-ripple,.mat-mdc-fab .mat-mdc-button-persistent-ripple,.mat-mdc-fab .mat-mdc-button-persistent-ripple::before,.mat-mdc-mini-fab .mat-mdc-button-ripple,.mat-mdc-mini-fab .mat-mdc-button-persistent-ripple,.mat-mdc-mini-fab .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-fab .mat-mdc-button-persistent-ripple::before,.mat-mdc-mini-fab .mat-mdc-button-persistent-ripple::before{content:"";opacity:0;background-color:var(--mat-mdc-button-persistent-ripple-color)}.mat-mdc-fab .mat-ripple-element,.mat-mdc-mini-fab .mat-ripple-element{background-color:var(--mat-mdc-button-ripple-color)}.mat-mdc-fab .mdc-button__label,.mat-mdc-mini-fab .mdc-button__label{z-index:1}.mat-mdc-fab .mat-mdc-focus-indicator,.mat-mdc-mini-fab .mat-mdc-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-fab:focus .mat-mdc-focus-indicator::before,.mat-mdc-mini-fab:focus .mat-mdc-focus-indicator::before{content:""}.mat-mdc-fab .mat-mdc-button-touch-target,.mat-mdc-mini-fab .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%)}.mat-mdc-fab._mat-animation-noopable,.mat-mdc-mini-fab._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-fab:not(:disabled) .mdc-fab__icon,.mat-mdc-mini-fab:not(:disabled) .mdc-fab__icon{color:var(--mdc-fab-icon-color, inherit)}.mat-mdc-fab:not(.mdc-fab--extended),.mat-mdc-mini-fab:not(.mdc-fab--extended){border-radius:var(--mdc-fab-container-shape, 50%)}.mat-mdc-fab:not(.mdc-fab--extended) .mdc-fab__ripple,.mat-mdc-mini-fab:not(.mdc-fab--extended) .mdc-fab__ripple{border-radius:var(--mdc-fab-container-shape, 50%)}.mat-mdc-fab:hover,.mat-mdc-fab:focus,.mat-mdc-mini-fab:hover,.mat-mdc-mini-fab:focus{box-shadow:0px 5px 5px -3px rgba(0, 0, 0, 0.2), 0px 8px 10px 1px rgba(0, 0, 0, 0.14), 0px 3px 14px 2px rgba(0, 0, 0, 0.12)}.mat-mdc-fab:active,.mat-mdc-fab:focus:active,.mat-mdc-mini-fab:active,.mat-mdc-mini-fab:focus:active{box-shadow:0px 7px 8px -4px rgba(0, 0, 0, 0.2), 0px 12px 17px 2px rgba(0, 0, 0, 0.14), 0px 5px 22px 4px rgba(0, 0, 0, 0.12)}.mat-mdc-fab[disabled],.mat-mdc-mini-fab[disabled]{cursor:default;pointer-events:none;box-shadow:0px 0px 0px 0px rgba(0, 0, 0, 0.2), 0px 0px 0px 0px rgba(0, 0, 0, 0.14), 0px 0px 0px 0px rgba(0, 0, 0, 0.12)}.mat-mdc-fab:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-mini-fab:not(.mdc-ripple-upgraded):focus::before{background:rgba(0,0,0,0);opacity:1}.mat-mdc-fab .mat-icon,.mat-mdc-fab .material-icons,.mat-mdc-mini-fab .mat-icon,.mat-mdc-mini-fab .material-icons{transition:transform 180ms 90ms cubic-bezier(0, 0, 0.2, 1);fill:currentColor;will-change:transform}.mat-mdc-fab .mat-mdc-focus-indicator::before,.mat-mdc-mini-fab .mat-mdc-focus-indicator::before{margin:calc(calc(var(--mat-mdc-focus-indicator-border-width, 3px) + 2px) * -1)}.mat-mdc-extended-fab{border-radius:24px;padding-left:20px;padding-right:20px;width:auto;max-width:100%;height:48px;line-height:normal}.mat-mdc-extended-fab .mdc-fab__ripple{border-radius:24px}.mat-mdc-extended-fab .mdc-fab__icon{margin-left:calc(12px - 20px);margin-right:12px}[dir=rtl] .mat-mdc-extended-fab .mdc-fab__icon,.mat-mdc-extended-fab .mdc-fab__icon[dir=rtl]{margin-left:12px;margin-right:calc(12px - 20px)}.mat-mdc-extended-fab .mdc-fab__label+.mdc-fab__icon{margin-left:12px;margin-right:calc(12px - 20px)}[dir=rtl] .mat-mdc-extended-fab .mdc-fab__label+.mdc-fab__icon,.mat-mdc-extended-fab .mdc-fab__label+.mdc-fab__icon[dir=rtl]{margin-left:calc(12px - 20px);margin-right:12px}.mat-mdc-extended-fab>.mat-icon,.mat-mdc-extended-fab>.material-icons{margin-left:calc(12px - 20px);margin-right:12px}[dir=rtl] .mat-mdc-extended-fab>.mat-icon,[dir=rtl] .mat-mdc-extended-fab>.material-icons,.mat-mdc-extended-fab>.mat-icon[dir=rtl],.mat-mdc-extended-fab>.material-icons[dir=rtl]{margin-left:12px;margin-right:calc(12px - 20px)}.mat-mdc-extended-fab .mdc-button__label+.mat-icon,.mat-mdc-extended-fab .mdc-button__label+.material-icons{margin-left:12px;margin-right:calc(12px - 20px)}[dir=rtl] .mat-mdc-extended-fab .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-extended-fab .mdc-button__label+.material-icons,.mat-mdc-extended-fab .mdc-button__label+.mat-icon[dir=rtl],.mat-mdc-extended-fab .mdc-button__label+.material-icons[dir=rtl]{margin-left:calc(12px - 20px);margin-right:12px}.mat-mdc-extended-fab .mat-mdc-button-touch-target{width:100%}'],encapsulation:2,changeDetection:0}),n})(),uN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,$v,rr]}),n})();class Hw{get selected(){return this._selected||(this._selected=Array.from(this._selection.values())),this._selected}constructor(e=!1,t,i=!0,r){this._multiple=e,this._emitChanges=i,this.compareWith=r,this._selection=new Set,this._deselectedToEmit=[],this._selectedToEmit=[],this.changed=new cn,t&&t.length&&(e?t.forEach(s=>this._markSelected(s)):this._markSelected(t[0]),this._selectedToEmit.length=0)}select(...e){this._verifyValueAssignment(e),e.forEach(i=>this._markSelected(i));const t=this._hasQueuedChanges();return this._emitChangeEvent(),t}deselect(...e){this._verifyValueAssignment(e),e.forEach(i=>this._unmarkSelected(i));const t=this._hasQueuedChanges();return this._emitChangeEvent(),t}setSelection(...e){this._verifyValueAssignment(e);const t=this.selected,i=new Set(e);e.forEach(s=>this._markSelected(s)),t.filter(s=>!i.has(s)).forEach(s=>this._unmarkSelected(s));const r=this._hasQueuedChanges();return this._emitChangeEvent(),r}toggle(e){return this.isSelected(e)?this.deselect(e):this.select(e)}clear(e=!0){this._unmarkAll();const t=this._hasQueuedChanges();return e&&this._emitChangeEvent(),t}isSelected(e){return this._selection.has(this._getConcreteValue(e))}isEmpty(){return 0===this._selection.size}hasValue(){return!this.isEmpty()}sort(e){this._multiple&&this.selected&&this._selected.sort(e)}isMultipleSelection(){return this._multiple}_emitChangeEvent(){this._selected=null,(this._selectedToEmit.length||this._deselectedToEmit.length)&&(this.changed.next({source:this,added:this._selectedToEmit,removed:this._deselectedToEmit}),this._deselectedToEmit=[],this._selectedToEmit=[])}_markSelected(e){e=this._getConcreteValue(e),this.isSelected(e)||(this._multiple||this._unmarkAll(),this.isSelected(e)||this._selection.add(e),this._emitChanges&&this._selectedToEmit.push(e))}_unmarkSelected(e){e=this._getConcreteValue(e),this.isSelected(e)&&(this._selection.delete(e),this._emitChanges&&this._deselectedToEmit.push(e))}_unmarkAll(){this.isEmpty()||this._selection.forEach(e=>this._unmarkSelected(e))}_verifyValueAssignment(e){}_hasQueuedChanges(){return!(!this._deselectedToEmit.length&&!this._selectedToEmit.length)}_getConcreteValue(e){if(this.compareWith){for(let t of this._selection)if(this.compareWith(e,t))return t;return e}return e}}const mq=["button"],gq=["*"],hN=new Ze("MAT_BUTTON_TOGGLE_DEFAULT_OPTIONS"),fN=new Ze("MatButtonToggleGroup"),_q={provide:Ja,useExisting:Mi(()=>gN),multi:!0};let pN=0;class mN{constructor(e,t){this.source=e,this.value=t}}let gN=(()=>{class n{get name(){return this._name}set name(t){this._name=t,this._markButtonsForCheck()}get vertical(){return this._vertical}set vertical(t){this._vertical=bi(t)}get value(){const t=this._selectionModel?this._selectionModel.selected:[];return this.multiple?t.map(i=>i.value):t[0]?t[0].value:void 0}set value(t){this._setSelectionByValue(t),this.valueChange.emit(this.value)}get selected(){const t=this._selectionModel?this._selectionModel.selected:[];return this.multiple?t:t[0]||null}get multiple(){return this._multiple}set multiple(t){this._multiple=bi(t),this._markButtonsForCheck()}get disabled(){return this._disabled}set disabled(t){this._disabled=bi(t),this._markButtonsForCheck()}constructor(t,i){this._changeDetector=t,this._vertical=!1,this._multiple=!1,this._disabled=!1,this._controlValueAccessorChangeFn=()=>{},this._onTouched=()=>{},this._name="mat-button-toggle-group-"+pN++,this.valueChange=new Pn,this.change=new Pn,this.appearance=i&&i.appearance?i.appearance:"standard"}ngOnInit(){this._selectionModel=new Hw(this.multiple,void 0,!1)}ngAfterContentInit(){this._selectionModel.select(...this._buttonToggles.filter(t=>t.checked))}writeValue(t){this.value=t,this._changeDetector.markForCheck()}registerOnChange(t){this._controlValueAccessorChangeFn=t}registerOnTouched(t){this._onTouched=t}setDisabledState(t){this.disabled=t}_emitChangeEvent(t){const i=new mN(t,this.value);this._controlValueAccessorChangeFn(i.value),this.change.emit(i)}_syncButtonToggle(t,i,r=!1,s=!1){!this.multiple&&this.selected&&!t.checked&&(this.selected.checked=!1),this._selectionModel?i?this._selectionModel.select(t):this._selectionModel.deselect(t):s=!0,s?Promise.resolve().then(()=>this._updateModelValue(t,r)):this._updateModelValue(t,r)}_isSelected(t){return this._selectionModel&&this._selectionModel.isSelected(t)}_isPrechecked(t){return!(typeof this._rawValue>"u")&&(this.multiple&&Array.isArray(this._rawValue)?this._rawValue.some(i=>null!=t.value&&i===t.value):t.value===this._rawValue)}_setSelectionByValue(t){this._rawValue=t,this._buttonToggles&&(this.multiple&&t?(Array.isArray(t),this._clearSelection(),t.forEach(i=>this._selectValue(i))):(this._clearSelection(),this._selectValue(t)))}_clearSelection(){this._selectionModel.clear(),this._buttonToggles.forEach(t=>t.checked=!1)}_selectValue(t){const i=this._buttonToggles.find(r=>null!=r.value&&r.value===t);i&&(i.checked=!0,this._selectionModel.select(i))}_updateModelValue(t,i){i&&this._emitChangeEvent(t),this.valueChange.emit(this.value)}_markButtonsForCheck(){this._buttonToggles?.forEach(t=>t._markForCheck())}}return n.\u0275fac=function(t){return new(t||n)(ie(aa),ie(hN,8))},n.\u0275dir=ut({type:n,selectors:[["mat-button-toggle-group"]],contentQueries:function(t,i,r){if(1&t&&is(r,_N,5),2&t){let s;Yn(s=Xn())&&(i._buttonToggles=s)}},hostAttrs:["role","group",1,"mat-button-toggle-group"],hostVars:5,hostBindings:function(t,i){2&t&&(Di("aria-disabled",i.disabled),hi("mat-button-toggle-vertical",i.vertical)("mat-button-toggle-group-appearance-standard","standard"===i.appearance))},inputs:{appearance:"appearance",name:"name",vertical:"vertical",value:"value",multiple:"multiple",disabled:"disabled"},outputs:{valueChange:"valueChange",change:"change"},exportAs:["matButtonToggleGroup"],features:[Oi([_q,{provide:fN,useExisting:n}])]}),n})();const vq=Bw(class{});let _N=(()=>{class n extends vq{get buttonId(){return`${this.id}-button`}get appearance(){return this.buttonToggleGroup?this.buttonToggleGroup.appearance:this._appearance}set appearance(t){this._appearance=t}get checked(){return this.buttonToggleGroup?this.buttonToggleGroup._isSelected(this):this._checked}set checked(t){const i=bi(t);i!==this._checked&&(this._checked=i,this.buttonToggleGroup&&this.buttonToggleGroup._syncButtonToggle(this,this._checked),this._changeDetectorRef.markForCheck())}get disabled(){return this._disabled||this.buttonToggleGroup&&this.buttonToggleGroup.disabled}set disabled(t){this._disabled=bi(t)}constructor(t,i,r,s,o,a){super(),this._changeDetectorRef=i,this._elementRef=r,this._focusMonitor=s,this._checked=!1,this.ariaLabelledby=null,this._disabled=!1,this.change=new Pn;const c=Number(o);this.tabIndex=c||0===c?c:null,this.buttonToggleGroup=t,this.appearance=a&&a.appearance?a.appearance:"standard"}ngOnInit(){const t=this.buttonToggleGroup;this.id=this.id||"mat-button-toggle-"+pN++,t&&(t._isPrechecked(this)?this.checked=!0:t._isSelected(this)!==this._checked&&t._syncButtonToggle(this,this._checked))}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){const t=this.buttonToggleGroup;this._focusMonitor.stopMonitoring(this._elementRef),t&&t._isSelected(this)&&t._syncButtonToggle(this,!1,!1,!0)}focus(t){this._buttonElement.nativeElement.focus(t)}_onButtonClick(){const t=!!this._isSingleSelector()||!this._checked;t!==this._checked&&(this._checked=t,this.buttonToggleGroup&&(this.buttonToggleGroup._syncButtonToggle(this,this._checked,!0),this.buttonToggleGroup._onTouched())),this.change.emit(new mN(this,this.value))}_markForCheck(){this._changeDetectorRef.markForCheck()}_getButtonName(){return this._isSingleSelector()?this.buttonToggleGroup.name:this.name||null}_isSingleSelector(){return this.buttonToggleGroup&&!this.buttonToggleGroup.multiple}}return n.\u0275fac=function(t){return new(t||n)(ie(fN,8),ie(aa),ie(_n),ie(Vf),Kc("tabindex"),ie(hN,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-button-toggle"]],viewQuery:function(t,i){if(1&t&&zr(mq,5),2&t){let r;Yn(r=Xn())&&(i._buttonElement=r.first)}},hostAttrs:["role","presentation",1,"mat-button-toggle"],hostVars:12,hostBindings:function(t,i){1&t&&Gn("focus",function(){return i.focus()}),2&t&&(Di("aria-label",null)("aria-labelledby",null)("id",i.id)("name",null),hi("mat-button-toggle-standalone",!i.buttonToggleGroup)("mat-button-toggle-checked",i.checked)("mat-button-toggle-disabled",i.disabled)("mat-button-toggle-appearance-standard","standard"===i.appearance))},inputs:{disableRipple:"disableRipple",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],id:"id",name:"name",value:"value",tabIndex:"tabIndex",appearance:"appearance",checked:"checked",disabled:"disabled"},outputs:{change:"change"},exportAs:["matButtonToggle"],features:[Z],ngContentSelectors:gq,decls:6,vars:9,consts:[["type","button",1,"mat-button-toggle-button","mat-focus-indicator",3,"id","disabled","click"],["button",""],[1,"mat-button-toggle-label-content"],[1,"mat-button-toggle-focus-overlay"],["matRipple","",1,"mat-button-toggle-ripple",3,"matRippleTrigger","matRippleDisabled"]],template:function(t,i){if(1&t&&(Hs(),ke(0,"button",0,1),Gn("click",function(){return i._onButtonClick()}),ke(2,"span",2),En(3),Ne()(),qt(4,"span",3)(5,"span",4)),2&t){const r=Tc(1);$e("id",i.buttonId)("disabled",i.disabled||null),Di("tabindex",i.disabled?-1:i.tabIndex)("aria-pressed",i.checked)("name",i._getButtonName())("aria-label",i.ariaLabel)("aria-labelledby",i.ariaLabelledby),Le(5),$e("matRippleTrigger",r)("matRippleDisabled",i.disableRipple||i.disabled)}},dependencies:[rh],styles:[".mat-button-toggle-standalone,.mat-button-toggle-group{position:relative;display:inline-flex;flex-direction:row;white-space:nowrap;overflow:hidden;border-radius:2px;-webkit-tap-highlight-color:rgba(0,0,0,0);transform:translateZ(0)}.cdk-high-contrast-active .mat-button-toggle-standalone,.cdk-high-contrast-active .mat-button-toggle-group{outline:solid 1px}.mat-button-toggle-standalone.mat-button-toggle-appearance-standard,.mat-button-toggle-group-appearance-standard{border-radius:4px}.cdk-high-contrast-active .mat-button-toggle-standalone.mat-button-toggle-appearance-standard,.cdk-high-contrast-active .mat-button-toggle-group-appearance-standard{outline:0}.mat-button-toggle-vertical{flex-direction:column}.mat-button-toggle-vertical .mat-button-toggle-label-content{display:block}.mat-button-toggle{white-space:nowrap;position:relative}.mat-button-toggle .mat-icon svg{vertical-align:top}.mat-button-toggle.cdk-keyboard-focused .mat-button-toggle-focus-overlay{opacity:1}.mat-button-toggle-appearance-standard:not(.mat-button-toggle-disabled):hover .mat-button-toggle-focus-overlay{opacity:.04}.mat-button-toggle-appearance-standard.cdk-keyboard-focused:not(.mat-button-toggle-disabled) .mat-button-toggle-focus-overlay{opacity:.12}@media(hover: none){.mat-button-toggle-appearance-standard:not(.mat-button-toggle-disabled):hover .mat-button-toggle-focus-overlay{display:none}}.mat-button-toggle-label-content{-webkit-user-select:none;user-select:none;display:inline-block;line-height:36px;padding:0 16px;position:relative}.mat-button-toggle-appearance-standard .mat-button-toggle-label-content{padding:0 12px}.mat-button-toggle-label-content>*{vertical-align:middle}.mat-button-toggle-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:inherit;pointer-events:none;opacity:0}.cdk-high-contrast-active .mat-button-toggle-checked .mat-button-toggle-focus-overlay{border-bottom:solid 36px;opacity:.5;height:0}.cdk-high-contrast-active .mat-button-toggle-checked:hover .mat-button-toggle-focus-overlay{opacity:.6}.cdk-high-contrast-active .mat-button-toggle-checked.mat-button-toggle-appearance-standard .mat-button-toggle-focus-overlay{border-bottom:solid 500px}.mat-button-toggle .mat-button-toggle-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-button-toggle-button{border:0;background:none;color:inherit;padding:0;margin:0;font:inherit;outline:none;width:100%;cursor:pointer}.mat-button-toggle-disabled .mat-button-toggle-button{cursor:default}.mat-button-toggle-button::-moz-focus-inner{border:0}"],encapsulation:2,changeDetection:0}),n})(),yq=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,$v,rr]}),n})();const bq=["input"],xq=["label"],wq=["*"],Sq=new Ze("mat-checkbox-default-options",{providedIn:"root",factory:vN});function vN(){return{color:"accent",clickAction:"check-indeterminate"}}const Eq={provide:Ja,useExisting:Mi(()=>bN),multi:!0};class Mq{}let Cq=0;const yN=vN(),Dq=ZL(NT(Bw(LT(class{constructor(n){this._elementRef=n}}))));let Tq=(()=>{class n extends Dq{get inputId(){return`${this.id||this._uniqueId}-input`}get required(){return this._required}set required(t){this._required=bi(t)}constructor(t,i,r,s,o,a,c){super(i),this._changeDetectorRef=r,this._ngZone=s,this._animationMode=a,this._options=c,this.ariaLabel="",this.ariaLabelledby=null,this.labelPosition="after",this.name=null,this.change=new Pn,this.indeterminateChange=new Pn,this._onTouched=()=>{},this._currentAnimationClass="",this._currentCheckState=0,this._controlValueAccessorChangeFn=()=>{},this._checked=!1,this._disabled=!1,this._indeterminate=!1,this._options=this._options||yN,this.color=this.defaultColor=this._options.color||yN.color,this.tabIndex=parseInt(o)||0,this.id=this._uniqueId=`${t}${++Cq}`}ngAfterViewInit(){this._syncIndeterminate(this._indeterminate)}get checked(){return this._checked}set checked(t){const i=bi(t);i!=this.checked&&(this._checked=i,this._changeDetectorRef.markForCheck())}get disabled(){return this._disabled}set disabled(t){const i=bi(t);i!==this.disabled&&(this._disabled=i,this._changeDetectorRef.markForCheck())}get indeterminate(){return this._indeterminate}set indeterminate(t){const i=t!=this._indeterminate;this._indeterminate=bi(t),i&&(this._transitionCheckState(this._indeterminate?3:this.checked?1:2),this.indeterminateChange.emit(this._indeterminate)),this._syncIndeterminate(this._indeterminate)}_isRippleDisabled(){return this.disableRipple||this.disabled}_onLabelTextChange(){this._changeDetectorRef.detectChanges()}writeValue(t){this.checked=!!t}registerOnChange(t){this._controlValueAccessorChangeFn=t}registerOnTouched(t){this._onTouched=t}setDisabledState(t){this.disabled=t}_getAriaChecked(){return this.checked?"true":this.indeterminate?"mixed":"false"}_transitionCheckState(t){let i=this._currentCheckState,r=this._getAnimationTargetElement();if(i!==t&&r&&(this._currentAnimationClass&&r.classList.remove(this._currentAnimationClass),this._currentAnimationClass=this._getAnimationClassForCheckStateTransition(i,t),this._currentCheckState=t,this._currentAnimationClass.length>0)){r.classList.add(this._currentAnimationClass);const s=this._currentAnimationClass;this._ngZone.runOutsideAngular(()=>{setTimeout(()=>{r.classList.remove(s)},1e3)})}}_emitChangeEvent(){this._controlValueAccessorChangeFn(this.checked),this.change.emit(this._createChangeEvent(this.checked)),this._inputElement&&(this._inputElement.nativeElement.checked=this.checked)}toggle(){this.checked=!this.checked,this._controlValueAccessorChangeFn(this.checked)}_handleInputClick(){const t=this._options?.clickAction;this.disabled||"noop"===t?!this.disabled&&"noop"===t&&(this._inputElement.nativeElement.checked=this.checked,this._inputElement.nativeElement.indeterminate=this.indeterminate):(this.indeterminate&&"check"!==t&&Promise.resolve().then(()=>{this._indeterminate=!1,this.indeterminateChange.emit(this._indeterminate)}),this._checked=!this._checked,this._transitionCheckState(this._checked?1:2),this._emitChangeEvent())}_onInteractionEvent(t){t.stopPropagation()}_onBlur(){Promise.resolve().then(()=>{this._onTouched(),this._changeDetectorRef.markForCheck()})}_getAnimationClassForCheckStateTransition(t,i){if("NoopAnimations"===this._animationMode)return"";switch(t){case 0:if(1===i)return this._animationClasses.uncheckedToChecked;if(3==i)return this._checked?this._animationClasses.checkedToIndeterminate:this._animationClasses.uncheckedToIndeterminate;break;case 2:return 1===i?this._animationClasses.uncheckedToChecked:this._animationClasses.uncheckedToIndeterminate;case 1:return 2===i?this._animationClasses.checkedToUnchecked:this._animationClasses.checkedToIndeterminate;case 3:return 1===i?this._animationClasses.indeterminateToChecked:this._animationClasses.indeterminateToUnchecked}return""}_syncIndeterminate(t){const i=this._inputElement;i&&(i.nativeElement.indeterminate=t)}}return n.\u0275fac=function(t){Gl()},n.\u0275dir=ut({type:n,viewQuery:function(t,i){if(1&t&&(zr(bq,5),zr(xq,5),zr(rh,5)),2&t){let r;Yn(r=Xn())&&(i._inputElement=r.first),Yn(r=Xn())&&(i._labelElement=r.first),Yn(r=Xn())&&(i.ripple=r.first)}},inputs:{ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],ariaDescribedby:["aria-describedby","ariaDescribedby"],id:"id",required:"required",labelPosition:"labelPosition",name:"name",value:"value",checked:"checked",disabled:"disabled",indeterminate:"indeterminate"},outputs:{change:"change",indeterminateChange:"indeterminateChange"},features:[Z]}),n})(),bN=(()=>{class n extends Tq{constructor(t,i,r,s,o,a){super("mat-mdc-checkbox-",t,i,r,s,o,a),this._animationClasses={uncheckedToChecked:"mdc-checkbox--anim-unchecked-checked",uncheckedToIndeterminate:"mdc-checkbox--anim-unchecked-indeterminate",checkedToUnchecked:"mdc-checkbox--anim-checked-unchecked",checkedToIndeterminate:"mdc-checkbox--anim-checked-indeterminate",indeterminateToChecked:"mdc-checkbox--anim-indeterminate-checked",indeterminateToUnchecked:"mdc-checkbox--anim-indeterminate-unchecked"}}focus(){this._inputElement.nativeElement.focus()}_createChangeEvent(t){const i=new Mq;return i.source=this,i.checked=t,i}_getAnimationTargetElement(){return this._inputElement?.nativeElement}_onInputClick(){super._handleInputClick()}_onTouchTargetClick(){super._handleInputClick(),this.disabled||this._inputElement.nativeElement.focus()}_preventBubblingFromLabel(t){t.target&&this._labelElement.nativeElement.contains(t.target)&&t.stopPropagation()}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(aa),ie(Xt),Kc("tabindex"),ie(bo,8),ie(Sq,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-checkbox"]],hostAttrs:[1,"mat-mdc-checkbox"],hostVars:12,hostBindings:function(t,i){2&t&&(Af("id",i.id),Di("tabindex",null)("aria-label",null)("aria-labelledby",null),hi("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mdc-checkbox--disabled",i.disabled)("mat-mdc-checkbox-disabled",i.disabled)("mat-mdc-checkbox-checked",i.checked))},inputs:{disableRipple:"disableRipple",color:"color",tabIndex:"tabIndex"},exportAs:["matCheckbox"],features:[Oi([Eq]),Z],ngContentSelectors:wq,decls:15,vars:19,consts:[[1,"mdc-form-field",3,"click"],[1,"mdc-checkbox"],["checkbox",""],[1,"mat-mdc-checkbox-touch-target",3,"click"],["type","checkbox",1,"mdc-checkbox__native-control",3,"checked","disabled","id","required","tabIndex","blur","click","change"],["input",""],[1,"mdc-checkbox__ripple"],[1,"mdc-checkbox__background"],["focusable","false","viewBox","0 0 24 24","aria-hidden","true",1,"mdc-checkbox__checkmark"],["fill","none","d","M1.73,12.91 8.1,19.28 22.79,4.59",1,"mdc-checkbox__checkmark-path"],[1,"mdc-checkbox__mixedmark"],["mat-ripple","",1,"mat-mdc-checkbox-ripple","mat-mdc-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleCentered"],[3,"for"],["label",""]],template:function(t,i){if(1&t&&(Hs(),ke(0,"div",0),Gn("click",function(s){return i._preventBubblingFromLabel(s)}),ke(1,"div",1,2)(3,"div",3),Gn("click",function(){return i._onTouchTargetClick()}),Ne(),ke(4,"input",4,5),Gn("blur",function(){return i._onBlur()})("click",function(){return i._onInputClick()})("change",function(s){return i._onInteractionEvent(s)}),Ne(),qt(6,"div",6),ke(7,"div",7),$i(),ke(8,"svg",8),qt(9,"path",9),Ne(),Xo(),qt(10,"div",10),Ne(),qt(11,"div",11),Ne(),ke(12,"label",12,13),En(14),Ne()()),2&t){const r=Tc(2);hi("mdc-form-field--align-end","before"==i.labelPosition),Le(4),hi("mdc-checkbox--selected",i.checked),$e("checked",i.checked)("disabled",i.disabled)("id",i.inputId)("required",i.required)("tabIndex",i.tabIndex),Di("aria-checked",i._getAriaChecked())("aria-label",i.ariaLabel||null)("aria-labelledby",i.ariaLabelledby)("aria-describedby",i.ariaDescribedby)("name",i.name)("value",i.value),Le(7),$e("matRippleTrigger",r)("matRippleDisabled",i.disableRipple||i.disabled)("matRippleCentered",!0),Le(1),$e("for",i.inputId)}},dependencies:[rh],styles:['.mdc-touch-target-wrapper{display:inline}@keyframes mdc-checkbox-unchecked-checked-checkmark-path{0%,50%{stroke-dashoffset:29.7833385}50%{animation-timing-function:cubic-bezier(0, 0, 0.2, 1)}100%{stroke-dashoffset:0}}@keyframes mdc-checkbox-unchecked-indeterminate-mixedmark{0%,68.2%{transform:scaleX(0)}68.2%{animation-timing-function:cubic-bezier(0, 0, 0, 1)}100%{transform:scaleX(1)}}@keyframes mdc-checkbox-checked-unchecked-checkmark-path{from{animation-timing-function:cubic-bezier(0.4, 0, 1, 1);opacity:1;stroke-dashoffset:0}to{opacity:0;stroke-dashoffset:-29.7833385}}@keyframes mdc-checkbox-checked-indeterminate-checkmark{from{animation-timing-function:cubic-bezier(0, 0, 0.2, 1);transform:rotate(0deg);opacity:1}to{transform:rotate(45deg);opacity:0}}@keyframes mdc-checkbox-indeterminate-checked-checkmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);transform:rotate(45deg);opacity:0}to{transform:rotate(360deg);opacity:1}}@keyframes mdc-checkbox-checked-indeterminate-mixedmark{from{animation-timing-function:mdc-animation-deceleration-curve-timing-function;transform:rotate(-45deg);opacity:0}to{transform:rotate(0deg);opacity:1}}@keyframes mdc-checkbox-indeterminate-checked-mixedmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);transform:rotate(0deg);opacity:1}to{transform:rotate(315deg);opacity:0}}@keyframes mdc-checkbox-indeterminate-unchecked-mixedmark{0%{animation-timing-function:linear;transform:scaleX(1);opacity:1}32.8%,100%{transform:scaleX(0);opacity:0}}.mdc-checkbox{display:inline-block;position:relative;flex:0 0 18px;box-sizing:content-box;width:18px;height:18px;line-height:0;white-space:nowrap;cursor:pointer;vertical-align:bottom}.mdc-checkbox[hidden]{display:none}.mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__focus-ring,.mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__focus-ring{pointer-events:none;border:2px solid rgba(0,0,0,0);border-radius:6px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:100%;width:100%}@media screen and (forced-colors: active){.mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__focus-ring,.mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__focus-ring{border-color:CanvasText}}.mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__focus-ring::after,.mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__focus-ring::after{content:"";border:2px solid rgba(0,0,0,0);border-radius:8px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__focus-ring::after,.mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__focus-ring::after{border-color:CanvasText}}@media all and (-ms-high-contrast: none){.mdc-checkbox .mdc-checkbox__focus-ring{display:none}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-checkbox__mixedmark{margin:0 1px}}.mdc-checkbox--disabled{cursor:default;pointer-events:none}.mdc-checkbox__background{display:inline-flex;position:absolute;align-items:center;justify-content:center;box-sizing:border-box;width:18px;height:18px;border:2px solid currentColor;border-radius:2px;background-color:rgba(0,0,0,0);pointer-events:none;will-change:background-color,border-color;transition:background-color 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1),border-color 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox__checkmark{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;opacity:0;transition:opacity 180ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox--upgraded .mdc-checkbox__checkmark{opacity:1}.mdc-checkbox__checkmark-path{transition:stroke-dashoffset 180ms 0ms cubic-bezier(0.4, 0, 0.6, 1);stroke:currentColor;stroke-width:3.12px;stroke-dashoffset:29.7833385;stroke-dasharray:29.7833385}.mdc-checkbox__mixedmark{width:100%;height:0;transform:scaleX(0) rotate(0deg);border-width:1px;border-style:solid;opacity:0;transition:opacity 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1),transform 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__background,.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__background,.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__background,.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__background{animation-duration:180ms;animation-timing-function:linear}.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__checkmark-path{animation:mdc-checkbox-unchecked-checked-checkmark-path 180ms linear 0s;transition:none}.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__mixedmark{animation:mdc-checkbox-unchecked-indeterminate-mixedmark 90ms linear 0s;transition:none}.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__checkmark-path{animation:mdc-checkbox-checked-unchecked-checkmark-path 90ms linear 0s;transition:none}.mdc-checkbox--anim-checked-indeterminate .mdc-checkbox__checkmark{animation:mdc-checkbox-checked-indeterminate-checkmark 90ms linear 0s;transition:none}.mdc-checkbox--anim-checked-indeterminate .mdc-checkbox__mixedmark{animation:mdc-checkbox-checked-indeterminate-mixedmark 90ms linear 0s;transition:none}.mdc-checkbox--anim-indeterminate-checked .mdc-checkbox__checkmark{animation:mdc-checkbox-indeterminate-checked-checkmark 500ms linear 0s;transition:none}.mdc-checkbox--anim-indeterminate-checked .mdc-checkbox__mixedmark{animation:mdc-checkbox-indeterminate-checked-mixedmark 500ms linear 0s;transition:none}.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__mixedmark{animation:mdc-checkbox-indeterminate-unchecked-mixedmark 300ms linear 0s;transition:none}.mdc-checkbox__native-control:checked~.mdc-checkbox__background,.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background{transition:border-color 90ms 0ms cubic-bezier(0, 0, 0.2, 1),background-color 90ms 0ms cubic-bezier(0, 0, 0.2, 1)}.mdc-checkbox__native-control:checked~.mdc-checkbox__background .mdc-checkbox__checkmark-path,.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background .mdc-checkbox__checkmark-path,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background .mdc-checkbox__checkmark-path{stroke-dashoffset:0}.mdc-checkbox__native-control{position:absolute;margin:0;padding:0;opacity:0;cursor:inherit}.mdc-checkbox__native-control:disabled{cursor:default;pointer-events:none}.mdc-checkbox--touch{margin:calc((var(--mdc-checkbox-state-layer-size, 48px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2)}.mdc-checkbox--touch .mdc-checkbox__native-control{top:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 48px)) / 2);right:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 48px)) / 2);left:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 48px)) / 2);width:var(--mdc-checkbox-state-layer-size, 48px);height:var(--mdc-checkbox-state-layer-size, 48px)}.mdc-checkbox__native-control:checked~.mdc-checkbox__background .mdc-checkbox__checkmark{transition:opacity 180ms 0ms cubic-bezier(0, 0, 0.2, 1),transform 180ms 0ms cubic-bezier(0, 0, 0.2, 1);opacity:1}.mdc-checkbox__native-control:checked~.mdc-checkbox__background .mdc-checkbox__mixedmark{transform:scaleX(1) rotate(-45deg)}.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background .mdc-checkbox__checkmark,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background .mdc-checkbox__checkmark{transform:rotate(45deg);opacity:0;transition:opacity 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1),transform 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background .mdc-checkbox__mixedmark,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background .mdc-checkbox__mixedmark{transform:scaleX(1) rotate(0deg);opacity:1}.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__background,.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__checkmark,.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__checkmark-path,.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__mixedmark{transition:none}.mdc-form-field{display:inline-flex;align-items:center;vertical-align:middle}.mdc-form-field[hidden]{display:none}.mdc-form-field>label{margin-left:0;margin-right:auto;padding-left:4px;padding-right:0;order:0}[dir=rtl] .mdc-form-field>label,.mdc-form-field>label[dir=rtl]{margin-left:auto;margin-right:0}[dir=rtl] .mdc-form-field>label,.mdc-form-field>label[dir=rtl]{padding-left:0;padding-right:4px}.mdc-form-field--nowrap>label{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.mdc-form-field--align-end>label{margin-left:auto;margin-right:0;padding-left:0;padding-right:4px;order:-1}[dir=rtl] .mdc-form-field--align-end>label,.mdc-form-field--align-end>label[dir=rtl]{margin-left:0;margin-right:auto}[dir=rtl] .mdc-form-field--align-end>label,.mdc-form-field--align-end>label[dir=rtl]{padding-left:4px;padding-right:0}.mdc-form-field--space-between{justify-content:space-between}.mdc-form-field--space-between>label{margin:0}[dir=rtl] .mdc-form-field--space-between>label,.mdc-form-field--space-between>label[dir=rtl]{margin:0}.mat-mdc-checkbox{display:inline-block;position:relative;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-checkbox .mdc-checkbox{padding:calc((var(--mdc-checkbox-state-layer-size, 40px) - 18px) / 2);margin:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control[disabled]:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-disabled-unselected-icon-color, rgba(0, 0, 0, 0.38));background-color:transparent}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control[disabled]:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control[disabled]:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control[data-indeterminate=true][disabled]~.mdc-checkbox__background{border-color:transparent;background-color:var(--mdc-checkbox-disabled-selected-icon-color, rgba(0, 0, 0, 0.38))}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:enabled~.mdc-checkbox__background .mdc-checkbox__checkmark{color:var(--mdc-checkbox-selected-checkmark-color, #fff)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:enabled~.mdc-checkbox__background .mdc-checkbox__mixedmark{border-color:var(--mdc-checkbox-selected-checkmark-color, #fff)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:disabled~.mdc-checkbox__background .mdc-checkbox__checkmark{color:var(--mdc-checkbox-disabled-selected-checkmark-color, #fff)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:disabled~.mdc-checkbox__background .mdc-checkbox__mixedmark{border-color:var(--mdc-checkbox-disabled-selected-checkmark-color, #fff)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786))}@keyframes mdc-checkbox-fade-in-background-8A000000FF01878600000000FF018786{0%{border-color:var(--mdc-checkbox-unselected-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}50%{border-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786))}}@keyframes mdc-checkbox-fade-out-background-8A000000FF01878600000000FF018786{0%,80%{border-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786))}100%{border-color:var(--mdc-checkbox-unselected-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}}.mat-mdc-checkbox .mdc-checkbox.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-in-background-8A000000FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-out-background-8A000000FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox:hover .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}.mat-mdc-checkbox .mdc-checkbox:hover .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:hover .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:hover .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786))}@keyframes mdc-checkbox-fade-in-background-FF018786FF01878600000000FF018786{0%{border-color:var(--mdc-checkbox-unselected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}50%{border-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786))}}@keyframes mdc-checkbox-fade-out-background-FF018786FF01878600000000FF018786{0%,80%{border-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786))}100%{border-color:var(--mdc-checkbox-unselected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}}.mat-mdc-checkbox .mdc-checkbox:hover.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:hover.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-in-background-FF018786FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox:hover.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:hover.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-out-background-FF018786FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786))}@keyframes mdc-checkbox-fade-in-background-FF018786FF01878600000000FF018786{0%{border-color:var(--mdc-checkbox-unselected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}50%{border-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786))}}@keyframes mdc-checkbox-fade-out-background-FF018786FF01878600000000FF018786{0%,80%{border-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786))}100%{border-color:var(--mdc-checkbox-unselected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}}.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-in-background-FF018786FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-out-background-FF018786FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-pressed-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786))}@keyframes mdc-checkbox-fade-in-background-8A000000FF01878600000000FF018786{0%{border-color:var(--mdc-checkbox-unselected-pressed-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}50%{border-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786))}}@keyframes mdc-checkbox-fade-out-background-8A000000FF01878600000000FF018786{0%,80%{border-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786))}100%{border-color:var(--mdc-checkbox-unselected-pressed-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}}.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-in-background-8A000000FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-out-background-8A000000FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__background{top:calc((var(--mdc-checkbox-state-layer-size, 40px) - 18px) / 2);left:calc((var(--mdc-checkbox-state-layer-size, 40px) - 18px) / 2)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control{top:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2);right:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2);left:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2);width:var(--mdc-checkbox-state-layer-size, 40px);height:var(--mdc-checkbox-state-layer-size, 40px)}.mat-mdc-checkbox .mdc-checkbox:hover .mdc-checkbox__native-control:not([disabled])~.mdc-checkbox__ripple{opacity:.04;transform:scale(1);transition:opacity 80ms 0 cubic-bezier(0, 0, 0.2, 1),transform 80ms 0 cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:not([disabled]):focus~.mdc-checkbox__ripple{opacity:.16}.mat-mdc-checkbox .mdc-checkbox__background{-webkit-print-color-adjust:exact;color-adjust:exact}.mat-mdc-checkbox._mat-animation-noopable *,.mat-mdc-checkbox._mat-animation-noopable *::before{transition:none !important;animation:none !important}.mat-mdc-checkbox label{cursor:pointer}.mat-mdc-checkbox.mat-mdc-checkbox-disabled label{cursor:default}.mat-mdc-checkbox label:empty{display:none}.mat-mdc-checkbox .mdc-checkbox__native-control:focus:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-focus-icon-color, black)}.cdk-high-contrast-active .mat-mdc-checkbox.mat-mdc-checkbox-disabled{opacity:.5}.cdk-high-contrast-active .mat-mdc-checkbox .mdc-checkbox__checkmark{--mdc-checkbox-selected-checkmark-color: CanvasText;--mdc-checkbox-disabled-selected-checkmark-color: CanvasText}.mat-mdc-checkbox .mdc-checkbox__ripple{opacity:0}.mat-mdc-checkbox-ripple,.mdc-checkbox__ripple{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:50%;pointer-events:none}.mat-mdc-checkbox-ripple:not(:empty),.mdc-checkbox__ripple:not(:empty){transform:translateZ(0)}.mat-mdc-checkbox-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%)}.mat-mdc-checkbox-ripple::before{border-radius:50%}.mdc-checkbox__native-control:focus~.mat-mdc-focus-indicator::before{content:""}'],encapsulation:2,changeDetection:0}),n})(),xN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})(),Iq=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,$v,xN,rr,xN]}),n})();const Fq=["*"],Nq=new Ze("MAT_CARD_CONFIG");let Uw=(()=>{class n{constructor(t){this.appearance=t?.appearance||"raised"}}return n.\u0275fac=function(t){return new(t||n)(ie(Nq,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-card"]],hostAttrs:[1,"mat-mdc-card","mdc-card"],hostVars:4,hostBindings:function(t,i){2&t&&hi("mat-mdc-card-outlined","outlined"===i.appearance)("mdc-card--outlined","outlined"===i.appearance)},inputs:{appearance:"appearance"},exportAs:["matCard"],ngContentSelectors:Fq,decls:1,vars:0,template:function(t,i){1&t&&(Hs(),En(0))},styles:['.mdc-card{display:flex;flex-direction:column;box-sizing:border-box}.mdc-card::after{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none;pointer-events:none}@media screen and (forced-colors: active){.mdc-card::after{border-color:CanvasText}}.mdc-card--outlined::after{border:none}.mdc-card__content{border-radius:inherit;height:100%}.mdc-card__media{position:relative;box-sizing:border-box;background-repeat:no-repeat;background-position:center;background-size:cover}.mdc-card__media::before{display:block;content:""}.mdc-card__media:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}.mdc-card__media:last-child{border-bottom-left-radius:inherit;border-bottom-right-radius:inherit}.mdc-card__media--square::before{margin-top:100%}.mdc-card__media--16-9::before{margin-top:56.25%}.mdc-card__media-content{position:absolute;top:0;right:0;bottom:0;left:0;box-sizing:border-box}.mdc-card__primary-action{display:flex;flex-direction:column;box-sizing:border-box;position:relative;outline:none;color:inherit;text-decoration:none;cursor:pointer;overflow:hidden}.mdc-card__primary-action:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}.mdc-card__primary-action:last-child{border-bottom-left-radius:inherit;border-bottom-right-radius:inherit}.mdc-card__actions{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;min-height:52px;padding:8px}.mdc-card__actions--full-bleed{padding:0}.mdc-card__action-buttons,.mdc-card__action-icons{display:flex;flex-direction:row;align-items:center;box-sizing:border-box}.mdc-card__action-icons{flex-grow:1;justify-content:flex-end}.mdc-card__action-buttons+.mdc-card__action-icons{margin-left:16px;margin-right:0}[dir=rtl] .mdc-card__action-buttons+.mdc-card__action-icons,.mdc-card__action-buttons+.mdc-card__action-icons[dir=rtl]{margin-left:0;margin-right:16px}.mdc-card__action{display:inline-flex;flex-direction:row;align-items:center;box-sizing:border-box;justify-content:center;cursor:pointer;user-select:none}.mdc-card__action:focus{outline:none}.mdc-card__action--button{margin-left:0;margin-right:8px;padding:0 8px}[dir=rtl] .mdc-card__action--button,.mdc-card__action--button[dir=rtl]{margin-left:8px;margin-right:0}.mdc-card__action--button:last-child{margin-left:0;margin-right:0}[dir=rtl] .mdc-card__action--button:last-child,.mdc-card__action--button:last-child[dir=rtl]{margin-left:0;margin-right:0}.mdc-card__actions--full-bleed .mdc-card__action--button{justify-content:space-between;width:100%;height:auto;max-height:none;margin:0;padding:8px 16px;text-align:left}[dir=rtl] .mdc-card__actions--full-bleed .mdc-card__action--button,.mdc-card__actions--full-bleed .mdc-card__action--button[dir=rtl]{text-align:right}.mdc-card__action--icon{margin:-6px 0;padding:12px}.mat-mdc-card{position:relative;border-radius:var(--mdc-elevated-card-container-shape, var(--mdc-shape-medium, 4px));background-color:var(--mdc-elevated-card-container-color, transparent);border-width:0;border-style:solid;border-color:var(--mdc-elevated-card-container-color, transparent)}.mat-mdc-card .mdc-card::after{border-radius:var(--mdc-elevated-card-container-shape, var(--mdc-shape-medium, 4px))}.mat-mdc-card-outlined{border-width:var(--mdc-outlined-card-outline-width, 1px);border-style:solid;border-color:var(--mdc-outlined-card-outline-color, transparent)}.mat-mdc-card-title,.mat-mdc-card-subtitle{display:block;margin:0}.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-title,.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-subtitle{padding:16px 16px 0}.mat-mdc-card-header{display:flex;padding:16px 16px 0}.mat-mdc-card-content{display:block;padding:0 16px}.mat-mdc-card-content:first-child{padding-top:16px}.mat-mdc-card-content:last-child{padding-bottom:16px}.mat-mdc-card-title-group{display:flex;justify-content:space-between;width:100%}.mat-mdc-card-avatar{height:40px;width:40px;border-radius:50%;flex-shrink:0;margin-bottom:16px;object-fit:cover}.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-subtitle,.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-title{line-height:normal}.mat-mdc-card-sm-image{width:80px;height:80px}.mat-mdc-card-md-image{width:112px;height:112px}.mat-mdc-card-lg-image{width:152px;height:152px}.mat-mdc-card-xl-image{width:240px;height:240px}.mat-mdc-card-subtitle~.mat-mdc-card-title,.mat-mdc-card-title~.mat-mdc-card-subtitle,.mat-mdc-card-header .mat-mdc-card-header-text .mat-mdc-card-title,.mat-mdc-card-header .mat-mdc-card-header-text .mat-mdc-card-subtitle,.mat-mdc-card-title-group .mat-mdc-card-title,.mat-mdc-card-title-group .mat-mdc-card-subtitle{padding-top:0}.mat-mdc-card-content>:last-child:not(.mat-mdc-card-footer){margin-bottom:0}.mat-mdc-card-actions-align-end{justify-content:flex-end}'],encapsulation:2,changeDetection:0}),n})(),zT=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["mat-card-title"],["","mat-card-title",""],["","matCardTitle",""]],hostAttrs:[1,"mat-mdc-card-title"]}),n})(),GT=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["mat-card-subtitle"],["","mat-card-subtitle",""],["","matCardSubtitle",""]],hostAttrs:[1,"mat-mdc-card-subtitle"]}),n})(),Yq=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,ul,rr]}),n})();function jT(n,e,t,i){return qr(t)&&(i=t,t=void 0),i?jT(n,e,t).pipe(_t(r=>_i(r)?i(...r):i(r))):new un(r=>{wN(n,e,function s(o){r.next(arguments.length>1?Array.prototype.slice.call(arguments):o)},r,t)})}function wN(n,e,t,i,r){let s;if(function Jq(n){return n&&"function"==typeof n.addEventListener&&"function"==typeof n.removeEventListener}(n)){const o=n;n.addEventListener(e,t,r),s=()=>o.removeEventListener(e,t,r)}else if(function Zq(n){return n&&"function"==typeof n.on&&"function"==typeof n.off}(n)){const o=n;n.on(e,t),s=()=>o.off(e,t)}else if(function Xq(n){return n&&"function"==typeof n.addListener&&"function"==typeof n.removeListener}(n)){const o=n;n.addListener(e,t),s=()=>o.removeListener(e,t)}else{if(!n||!n.length)throw new TypeError("Invalid event target");for(let o=0,a=n.length;o0?super.requestAsyncId(e,t,i):(e.actions.push(this),e.scheduled||(e.scheduled=requestAnimationFrame(()=>e.flush(null))))}recycleAsyncId(e,t,i=0){if(null!==i&&i>0||null===i&&this.delay>0)return super.recycleAsyncId(e,t,i);0===e.actions.length&&(cancelAnimationFrame(t),e.scheduled=void 0)}});let nK=1;const iK=Promise.resolve(),zw={};function SN(n){return n in zw&&(delete zw[n],!0)}const EN={setImmediate(n){const e=nK++;return zw[e]=!0,iK.then(()=>SN(e)&&n()),e},clearImmediate(n){SN(n)}},oK=new class sK extends Kl{flush(e){this.active=!0,this.scheduled=void 0;const{actions:t}=this;let i,r=-1,s=t.length;e=e||t.shift();do{if(i=e.execute(e.state,e.delay))break}while(++r0?super.requestAsyncId(e,t,i):(e.actions.push(this),e.scheduled||(e.scheduled=EN.setImmediate(e.flush.bind(e,null))))}recycleAsyncId(e,t,i=0){if(null!==i&&i>0||null===i&&this.delay>0)return super.recycleAsyncId(e,t,i);0===e.actions.length&&(EN.clearImmediate(t),e.scheduled=void 0)}});class cK{constructor(e){this.durationSelector=e}call(e,t){return t.subscribe(new lK(e,this.durationSelector))}}class lK extends Fs{constructor(e,t){super(e),this.durationSelector=t,this.hasValue=!1}_next(e){if(this.value=e,this.hasValue=!0,!this.throttled){let t;try{const{durationSelector:r}=this;t=r(e)}catch(r){return this.destination.error(r)}const i=$o(this,t);!i||i.closed?this.clearThrottle():this.add(this.throttled=i)}}clearThrottle(){const{value:e,hasValue:t,throttled:i}=this;i&&(this.remove(i),this.throttled=null,i.unsubscribe()),t&&(this.value=null,this.hasValue=!1,this.destination.next(e))}notifyNext(e,t,i,r){this.clearThrottle()}notifyComplete(){this.clearThrottle()}}function MN(n){return!_i(n)&&n-parseFloat(n)+1>=0}function uK(n){const{index:e,period:t,subscriber:i}=n;if(i.next(e),!i.closed){if(-1===t)return i.complete();n.index=e+1,this.schedule(n,t)}}function WT(n,e=ag){return function aK(n){return function(t){return t.lift(new cK(n))}}(()=>function dK(n=0,e,t){let i=-1;return MN(e)?i=Number(e)<1?1:Number(e):cc(e)&&(t=e),cc(t)||(t=ag),new un(r=>{const s=MN(n)?n:+n-t.now();return t.schedule(uK,s,{index:0,period:i,subscriber:r})})}(n,e))}const hK=["contentWrapper"],fK=["*"],pK=new Ze("VIRTUAL_SCROLL_STRATEGY");let qv=(()=>{class n{constructor(t,i,r){this._ngZone=t,this._platform=i,this._scrolled=new cn,this._globalSubscription=null,this._scrolledCount=0,this.scrollContainers=new Map,this._document=r}register(t){this.scrollContainers.has(t)||this.scrollContainers.set(t,t.elementScrolled().subscribe(()=>this._scrolled.next(t)))}deregister(t){const i=this.scrollContainers.get(t);i&&(i.unsubscribe(),this.scrollContainers.delete(t))}scrolled(t=20){return this._platform.isBrowser?new un(i=>{this._globalSubscription||this._addGlobalListener();const r=t>0?this._scrolled.pipe(WT(t)).subscribe(i):this._scrolled.subscribe(i);return this._scrolledCount++,()=>{r.unsubscribe(),this._scrolledCount--,this._scrolledCount||this._removeGlobalListener()}}):Tt()}ngOnDestroy(){this._removeGlobalListener(),this.scrollContainers.forEach((t,i)=>this.deregister(i)),this._scrolled.complete()}ancestorScrolled(t,i){const r=this.getAncestorScrollContainers(t);return this.scrolled(i).pipe(Ui(s=>!s||r.indexOf(s)>-1))}getAncestorScrollContainers(t){const i=[];return this.scrollContainers.forEach((r,s)=>{this._scrollableContainsElement(s,t)&&i.push(s)}),i}_getWindow(){return this._document.defaultView||window}_scrollableContainsElement(t,i){let r=Nf(i),s=t.getElementRef().nativeElement;do{if(r==s)return!0}while(r=r.parentElement);return!1}_addGlobalListener(){this._globalSubscription=this._ngZone.runOutsideAngular(()=>jT(this._getWindow().document,"scroll").subscribe(()=>this._scrolled.next()))}_removeGlobalListener(){this._globalSubscription&&(this._globalSubscription.unsubscribe(),this._globalSubscription=null)}}return n.\u0275fac=function(t){return new(t||n)(xe(Xt),xe(as),xe(Mn,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),CN=(()=>{class n{constructor(t,i,r,s){this.elementRef=t,this.scrollDispatcher=i,this.ngZone=r,this.dir=s,this._destroyed=new cn,this._elementScrolled=new un(o=>this.ngZone.runOutsideAngular(()=>jT(this.elementRef.nativeElement,"scroll").pipe(Tr(this._destroyed)).subscribe(o)))}ngOnInit(){this.scrollDispatcher.register(this)}ngOnDestroy(){this.scrollDispatcher.deregister(this),this._destroyed.next(),this._destroyed.complete()}elementScrolled(){return this._elementScrolled}getElementRef(){return this.elementRef}scrollTo(t){const i=this.elementRef.nativeElement,r=this.dir&&"rtl"==this.dir.value;null==t.left&&(t.left=r?t.end:t.start),null==t.right&&(t.right=r?t.start:t.end),null!=t.bottom&&(t.top=i.scrollHeight-i.clientHeight-t.bottom),r&&0!=Hv()?(null!=t.left&&(t.right=i.scrollWidth-i.clientWidth-t.left),2==Hv()?t.left=t.right:1==Hv()&&(t.left=t.right?-t.right:t.right)):null!=t.right&&(t.left=i.scrollWidth-i.clientWidth-t.right),this._applyScrollToOptions(t)}_applyScrollToOptions(t){const i=this.elementRef.nativeElement;SL()?i.scrollTo(t):(null!=t.top&&(i.scrollTop=t.top),null!=t.left&&(i.scrollLeft=t.left))}measureScrollOffset(t){const i="left",r="right",s=this.elementRef.nativeElement;if("top"==t)return s.scrollTop;if("bottom"==t)return s.scrollHeight-s.clientHeight-s.scrollTop;const o=this.dir&&"rtl"==this.dir.value;return"start"==t?t=o?r:i:"end"==t&&(t=o?i:r),o&&2==Hv()?t==i?s.scrollWidth-s.clientWidth-s.scrollLeft:s.scrollLeft:o&&1==Hv()?t==i?s.scrollLeft+s.scrollWidth-s.clientWidth:-s.scrollLeft:t==i?s.scrollLeft:s.scrollWidth-s.clientWidth-s.scrollLeft}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(qv),ie(Xt),ie(Yl,8))},n.\u0275dir=ut({type:n,selectors:[["","cdk-scrollable",""],["","cdkScrollable",""]],standalone:!0}),n})(),Gw=(()=>{class n{constructor(t,i,r){this._platform=t,this._change=new cn,this._changeListener=s=>{this._change.next(s)},this._document=r,i.runOutsideAngular(()=>{if(t.isBrowser){const s=this._getWindow();s.addEventListener("resize",this._changeListener),s.addEventListener("orientationchange",this._changeListener)}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){if(this._platform.isBrowser){const t=this._getWindow();t.removeEventListener("resize",this._changeListener),t.removeEventListener("orientationchange",this._changeListener)}this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();const t={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),t}getViewportRect(){const t=this.getViewportScrollPosition(),{width:i,height:r}=this.getViewportSize();return{top:t.top,left:t.left,bottom:t.top+r,right:t.left+i,height:r,width:i}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};const t=this._document,i=this._getWindow(),r=t.documentElement,s=r.getBoundingClientRect();return{top:-s.top||t.body.scrollTop||i.scrollY||r.scrollTop||0,left:-s.left||t.body.scrollLeft||i.scrollX||r.scrollLeft||0}}change(t=20){return t>0?this._change.pipe(WT(t)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){const t=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:t.innerWidth,height:t.innerHeight}:{width:0,height:0}}}return n.\u0275fac=function(t){return new(t||n)(xe(as),xe(Xt),xe(Mn,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const DN=new Ze("VIRTUAL_SCROLLABLE");let _K=(()=>{class n extends CN{constructor(t,i,r,s){super(t,i,r,s)}measureViewportSize(t){const i=this.elementRef.nativeElement;return"horizontal"===t?i.clientWidth:i.clientHeight}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(qv),ie(Xt),ie(Yl,8))},n.\u0275dir=ut({type:n,features:[Z]}),n})();const yK=typeof requestAnimationFrame<"u"?tK:oK;let bK=(()=>{class n extends _K{get orientation(){return this._orientation}set orientation(t){this._orientation!==t&&(this._orientation=t,this._calculateSpacerSize())}get appendOnly(){return this._appendOnly}set appendOnly(t){this._appendOnly=bi(t)}constructor(t,i,r,s,o,a,c,u){super(t,a,r,o),this.elementRef=t,this._changeDetectorRef=i,this._scrollStrategy=s,this.scrollable=u,this._platform=hn(as),this._detachedSubject=new cn,this._renderedRangeSubject=new cn,this._orientation="vertical",this._appendOnly=!1,this.scrolledIndexChange=new un(p=>this._scrollStrategy.scrolledIndexChange.subscribe(g=>Promise.resolve().then(()=>this.ngZone.run(()=>p.next(g))))),this.renderedRangeStream=this._renderedRangeSubject,this._totalContentSize=0,this._totalContentWidth="",this._totalContentHeight="",this._renderedRange={start:0,end:0},this._dataLength=0,this._viewportSize=0,this._renderedContentOffset=0,this._renderedContentOffsetNeedsRewrite=!1,this._isChangeDetectionPending=!1,this._runAfterChangeDetection=[],this._viewportChanges=Tn.EMPTY,this._viewportChanges=c.change().subscribe(()=>{this.checkViewportSize()}),this.scrollable||(this.elementRef.nativeElement.classList.add("cdk-virtual-scrollable"),this.scrollable=this)}ngOnInit(){this._platform.isBrowser&&(this.scrollable===this&&super.ngOnInit(),this.ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>{this._measureViewportSize(),this._scrollStrategy.attach(this),this.scrollable.elementScrolled().pipe(Bf(null),WT(0,yK)).subscribe(()=>this._scrollStrategy.onContentScrolled()),this._markChangeDetectionNeeded()})))}ngOnDestroy(){this.detach(),this._scrollStrategy.detach(),this._renderedRangeSubject.complete(),this._detachedSubject.complete(),this._viewportChanges.unsubscribe(),super.ngOnDestroy()}attach(t){this.ngZone.runOutsideAngular(()=>{this._forOf=t,this._forOf.dataStream.pipe(Tr(this._detachedSubject)).subscribe(i=>{const r=i.length;r!==this._dataLength&&(this._dataLength=r,this._scrollStrategy.onDataLengthChanged()),this._doChangeDetection()})})}detach(){this._forOf=null,this._detachedSubject.next()}getDataLength(){return this._dataLength}getViewportSize(){return this._viewportSize}getRenderedRange(){return this._renderedRange}measureBoundingClientRectWithScrollOffset(t){return this.getElementRef().nativeElement.getBoundingClientRect()[t]}setTotalContentSize(t){this._totalContentSize!==t&&(this._totalContentSize=t,this._calculateSpacerSize(),this._markChangeDetectionNeeded())}setRenderedRange(t){(function vK(n,e){return n.start==e.start&&n.end==e.end})(this._renderedRange,t)||(this.appendOnly&&(t={start:0,end:Math.max(this._renderedRange.end,t.end)}),this._renderedRangeSubject.next(this._renderedRange=t),this._markChangeDetectionNeeded(()=>this._scrollStrategy.onContentRendered()))}getOffsetToRenderedContentStart(){return this._renderedContentOffsetNeedsRewrite?null:this._renderedContentOffset}setRenderedContentOffset(t,i="to-start"){t=this.appendOnly&&"to-start"===i?0:t;const s="horizontal"==this.orientation,o=s?"X":"Y";let c=`translate${o}(${Number((s&&this.dir&&"rtl"==this.dir.value?-1:1)*t)}px)`;this._renderedContentOffset=t,"to-end"===i&&(c+=` translate${o}(-100%)`,this._renderedContentOffsetNeedsRewrite=!0),this._renderedContentTransform!=c&&(this._renderedContentTransform=c,this._markChangeDetectionNeeded(()=>{this._renderedContentOffsetNeedsRewrite?(this._renderedContentOffset-=this.measureRenderedContentSize(),this._renderedContentOffsetNeedsRewrite=!1,this.setRenderedContentOffset(this._renderedContentOffset)):this._scrollStrategy.onRenderedOffsetChanged()}))}scrollToOffset(t,i="auto"){const r={behavior:i};"horizontal"===this.orientation?r.start=t:r.top=t,this.scrollable.scrollTo(r)}scrollToIndex(t,i="auto"){this._scrollStrategy.scrollToIndex(t,i)}measureScrollOffset(t){let i;return i=this.scrollable==this?r=>super.measureScrollOffset(r):r=>this.scrollable.measureScrollOffset(r),Math.max(0,i(t??("horizontal"===this.orientation?"start":"top"))-this.measureViewportOffset())}measureViewportOffset(t){let i;const r="left",s="right",o="rtl"==this.dir?.value;i="start"==t?o?s:r:"end"==t?o?r:s:t||("horizontal"===this.orientation?"left":"top");const a=this.scrollable.measureBoundingClientRectWithScrollOffset(i);return this.elementRef.nativeElement.getBoundingClientRect()[i]-a}measureRenderedContentSize(){const t=this._contentWrapper.nativeElement;return"horizontal"===this.orientation?t.offsetWidth:t.offsetHeight}measureRangeSize(t){return this._forOf?this._forOf.measureRangeSize(t,this.orientation):0}checkViewportSize(){this._measureViewportSize(),this._scrollStrategy.onDataLengthChanged()}_measureViewportSize(){this._viewportSize=this.scrollable.measureViewportSize(this.orientation)}_markChangeDetectionNeeded(t){t&&this._runAfterChangeDetection.push(t),this._isChangeDetectionPending||(this._isChangeDetectionPending=!0,this.ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>{this._doChangeDetection()})))}_doChangeDetection(){this._isChangeDetectionPending=!1,this._contentWrapper.nativeElement.style.transform=this._renderedContentTransform,this.ngZone.run(()=>this._changeDetectorRef.markForCheck());const t=this._runAfterChangeDetection;this._runAfterChangeDetection=[];for(const i of t)i()}_calculateSpacerSize(){this._totalContentHeight="horizontal"===this.orientation?"":`${this._totalContentSize}px`,this._totalContentWidth="horizontal"===this.orientation?`${this._totalContentSize}px`:""}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(aa),ie(Xt),ie(pK,8),ie(Yl,8),ie(qv),ie(Gw),ie(DN,8))},n.\u0275cmp=Ln({type:n,selectors:[["cdk-virtual-scroll-viewport"]],viewQuery:function(t,i){if(1&t&&zr(hK,7),2&t){let r;Yn(r=Xn())&&(i._contentWrapper=r.first)}},hostAttrs:[1,"cdk-virtual-scroll-viewport"],hostVars:4,hostBindings:function(t,i){2&t&&hi("cdk-virtual-scroll-orientation-horizontal","horizontal"===i.orientation)("cdk-virtual-scroll-orientation-vertical","horizontal"!==i.orientation)},inputs:{orientation:"orientation",appendOnly:"appendOnly"},outputs:{scrolledIndexChange:"scrolledIndexChange"},standalone:!0,features:[Oi([{provide:CN,useFactory:(e,t)=>e||t,deps:[[new ba,new af(DN)],n]}]),Z,_v],ngContentSelectors:fK,decls:4,vars:4,consts:[[1,"cdk-virtual-scroll-content-wrapper"],["contentWrapper",""],[1,"cdk-virtual-scroll-spacer"]],template:function(t,i){1&t&&(Hs(),ke(0,"div",0,1),En(2),Ne(),qt(3,"div",2)),2&t&&(Le(3),dv("width",i._totalContentWidth)("height",i._totalContentHeight))},styles:["cdk-virtual-scroll-viewport{display:block;position:relative;transform:translateZ(0)}.cdk-virtual-scrollable{overflow:auto;will-change:scroll-position;contain:strict;-webkit-overflow-scrolling:touch}.cdk-virtual-scroll-content-wrapper{position:absolute;top:0;left:0;contain:content}[dir=rtl] .cdk-virtual-scroll-content-wrapper{right:0;left:auto}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper{min-height:100%}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-left:0;padding-right:0;margin-left:0;margin-right:0;border-left-width:0;border-right-width:0;outline:none}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper{min-width:100%}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-top:0;padding-bottom:0;margin-top:0;margin-bottom:0;border-top-width:0;border-bottom-width:0;outline:none}.cdk-virtual-scroll-spacer{height:1px;transform-origin:0 0;flex:0 0 auto}[dir=rtl] .cdk-virtual-scroll-spacer{transform-origin:100% 0}"],encapsulation:2,changeDetection:0}),n})(),jw=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})(),TN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[jv,jw,bK,jv,jw]}),n})();class $T{attach(e){return this._attachedHost=e,e.attach(this)}detach(){let e=this._attachedHost;null!=e&&(this._attachedHost=null,e.detach())}get isAttached(){return null!=this._attachedHost}setAttachedHost(e){this._attachedHost=e}}class Ww extends $T{constructor(e,t,i,r,s){super(),this.component=e,this.viewContainerRef=t,this.injector=i,this.componentFactoryResolver=r,this.projectableNodes=s}}class qT extends $T{constructor(e,t,i,r){super(),this.templateRef=e,this.viewContainerRef=t,this.context=i,this.injector=r}get origin(){return this.templateRef.elementRef}attach(e,t=this.context){return this.context=t,super.attach(e)}detach(){return this.context=void 0,super.detach()}}class xK extends $T{constructor(e){super(),this.element=e instanceof _n?e.nativeElement:e}}class KT{constructor(){this._isDisposed=!1,this.attachDomPortal=null}hasAttached(){return!!this._attachedPortal}attach(e){return e instanceof Ww?(this._attachedPortal=e,this.attachComponentPortal(e)):e instanceof qT?(this._attachedPortal=e,this.attachTemplatePortal(e)):this.attachDomPortal&&e instanceof xK?(this._attachedPortal=e,this.attachDomPortal(e)):void 0}detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(e){this._disposeFn=e}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}}class wK extends KT{constructor(e,t,i,r,s){super(),this.outletElement=e,this._componentFactoryResolver=t,this._appRef=i,this._defaultInjector=r,this.attachDomPortal=o=>{const a=o.element,c=this._document.createComment("dom-portal");a.parentNode.insertBefore(c,a),this.outletElement.appendChild(a),this._attachedPortal=o,super.setDisposeFn(()=>{c.parentNode&&c.parentNode.replaceChild(a,c)})},this._document=s}attachComponentPortal(e){const i=(e.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(e.component);let r;return e.viewContainerRef?(r=e.viewContainerRef.createComponent(i,e.viewContainerRef.length,e.injector||e.viewContainerRef.injector,e.projectableNodes||void 0),this.setDisposeFn(()=>r.destroy())):(r=i.create(e.injector||this._defaultInjector||ts.NULL),this._appRef.attachView(r.hostView),this.setDisposeFn(()=>{this._appRef.viewCount>0&&this._appRef.detachView(r.hostView),r.destroy()})),this.outletElement.appendChild(this._getComponentRootNode(r)),this._attachedPortal=e,r}attachTemplatePortal(e){let t=e.viewContainerRef,i=t.createEmbeddedView(e.templateRef,e.context,{injector:e.injector});return i.rootNodes.forEach(r=>this.outletElement.appendChild(r)),i.detectChanges(),this.setDisposeFn(()=>{let r=t.indexOf(i);-1!==r&&t.remove(r)}),this._attachedPortal=e,i}dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(e){return e.hostView.rootNodes[0]}}let $w=(()=>{class n extends KT{constructor(t,i,r){super(),this._componentFactoryResolver=t,this._viewContainerRef=i,this._isInitialized=!1,this.attached=new Pn,this.attachDomPortal=s=>{const o=s.element,a=this._document.createComment("dom-portal");s.setAttachedHost(this),o.parentNode.insertBefore(a,o),this._getRootNode().appendChild(o),this._attachedPortal=s,super.setDisposeFn(()=>{a.parentNode&&a.parentNode.replaceChild(o,a)})},this._document=r}get portal(){return this._attachedPortal}set portal(t){this.hasAttached()&&!t&&!this._isInitialized||(this.hasAttached()&&super.detach(),t&&super.attach(t),this._attachedPortal=t||null)}get attachedRef(){return this._attachedRef}ngOnInit(){this._isInitialized=!0}ngOnDestroy(){super.dispose(),this._attachedRef=this._attachedPortal=null}attachComponentPortal(t){t.setAttachedHost(this);const i=null!=t.viewContainerRef?t.viewContainerRef:this._viewContainerRef,s=(t.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(t.component),o=i.createComponent(s,i.length,t.injector||i.injector,t.projectableNodes||void 0);return i!==this._viewContainerRef&&this._getRootNode().appendChild(o.hostView.rootNodes[0]),super.setDisposeFn(()=>o.destroy()),this._attachedPortal=t,this._attachedRef=o,this.attached.emit(o),o}attachTemplatePortal(t){t.setAttachedHost(this);const i=this._viewContainerRef.createEmbeddedView(t.templateRef,t.context,{injector:t.injector});return super.setDisposeFn(()=>this._viewContainerRef.clear()),this._attachedPortal=t,this._attachedRef=i,this.attached.emit(i),i}_getRootNode(){const t=this._viewContainerRef.element.nativeElement;return t.nodeType===t.ELEMENT_NODE?t:t.parentNode}}return n.\u0275fac=function(t){return new(t||n)(ie(Fd),ie(Sa),ie(Mn))},n.\u0275dir=ut({type:n,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:["cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[Z]}),n})(),Kv=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})();function AN(n,e=!1){return t=>t.lift(new SK(n,e))}class SK{constructor(e,t){this.predicate=e,this.inclusive=t}call(e,t){return t.subscribe(new EK(e,this.predicate,this.inclusive))}}class EK extends di{constructor(e,t,i){super(e),this.predicate=t,this.inclusive=i,this.index=0}_next(e){const t=this.destination;let i;try{i=this.predicate(e,this.index++)}catch(r){return void t.error(r)}this.nextOrComplete(e,i)}nextOrComplete(e,t){const i=this.destination;Boolean(t)?i.next(e):(this.inclusive&&i.next(e),i.complete())}}const kN=SL();class MK{constructor(e,t){this._viewportRuler=e,this._previousHTMLStyles={top:"",left:""},this._isEnabled=!1,this._document=t}attach(){}enable(){if(this._canBeEnabled()){const e=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=e.style.left||"",this._previousHTMLStyles.top=e.style.top||"",e.style.left=Cs(-this._previousScrollPosition.left),e.style.top=Cs(-this._previousScrollPosition.top),e.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}disable(){if(this._isEnabled){const e=this._document.documentElement,i=e.style,r=this._document.body.style,s=i.scrollBehavior||"",o=r.scrollBehavior||"";this._isEnabled=!1,i.left=this._previousHTMLStyles.left,i.top=this._previousHTMLStyles.top,e.classList.remove("cdk-global-scrollblock"),kN&&(i.scrollBehavior=r.scrollBehavior="auto"),window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),kN&&(i.scrollBehavior=s,r.scrollBehavior=o)}}_canBeEnabled(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;const t=this._document.body,i=this._viewportRuler.getViewportSize();return t.scrollHeight>i.height||t.scrollWidth>i.width}}class CK{constructor(e,t,i,r){this._scrollDispatcher=e,this._ngZone=t,this._viewportRuler=i,this._config=r,this._scrollSubscription=null,this._detach=()=>{this.disable(),this._overlayRef.hasAttached()&&this._ngZone.run(()=>this._overlayRef.detach())}}attach(e){this._overlayRef=e}enable(){if(this._scrollSubscription)return;const e=this._scrollDispatcher.scrolled(0);this._config&&this._config.threshold&&this._config.threshold>1?(this._initialScrollPosition=this._viewportRuler.getViewportScrollPosition().top,this._scrollSubscription=e.subscribe(()=>{const t=this._viewportRuler.getViewportScrollPosition().top;Math.abs(t-this._initialScrollPosition)>this._config.threshold?this._detach():this._overlayRef.updatePosition()})):this._scrollSubscription=e.subscribe(this._detach)}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}}class IN{enable(){}disable(){}attach(){}}function YT(n,e){return e.some(t=>n.bottomt.bottom||n.rightt.right)}function FN(n,e){return e.some(t=>n.topt.bottom||n.leftt.right)}class DK{constructor(e,t,i,r){this._scrollDispatcher=e,this._viewportRuler=t,this._ngZone=i,this._config=r,this._scrollSubscription=null}attach(e){this._overlayRef=e}enable(){this._scrollSubscription||(this._scrollSubscription=this._scrollDispatcher.scrolled(this._config?this._config.scrollThrottle:0).subscribe(()=>{if(this._overlayRef.updatePosition(),this._config&&this._config.autoClose){const t=this._overlayRef.overlayElement.getBoundingClientRect(),{width:i,height:r}=this._viewportRuler.getViewportSize();YT(t,[{width:i,height:r,bottom:r,right:i,top:0,left:0}])&&(this.disable(),this._ngZone.run(()=>this._overlayRef.detach()))}}))}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}}let TK=(()=>{class n{constructor(t,i,r,s){this._scrollDispatcher=t,this._viewportRuler=i,this._ngZone=r,this.noop=()=>new IN,this.close=o=>new CK(this._scrollDispatcher,this._ngZone,this._viewportRuler,o),this.block=()=>new MK(this._viewportRuler,this._document),this.reposition=o=>new DK(this._scrollDispatcher,this._viewportRuler,this._ngZone,o),this._document=s}}return n.\u0275fac=function(t){return new(t||n)(xe(qv),xe(Gw),xe(Xt),xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();class XT{constructor(e){if(this.scrollStrategy=new IN,this.panelClass="",this.hasBackdrop=!1,this.backdropClass="cdk-overlay-dark-backdrop",this.disposeOnNavigation=!1,e){const t=Object.keys(e);for(const i of t)void 0!==e[i]&&(this[i]=e[i])}}}class AK{constructor(e,t){this.connectionPair=e,this.scrollableViewProperties=t}}let RN=(()=>{class n{constructor(t){this._attachedOverlays=[],this._document=t}ngOnDestroy(){this.detach()}add(t){this.remove(t),this._attachedOverlays.push(t)}remove(t){const i=this._attachedOverlays.indexOf(t);i>-1&&this._attachedOverlays.splice(i,1),0===this._attachedOverlays.length&&this.detach()}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),kK=(()=>{class n extends RN{constructor(t,i){super(t),this._ngZone=i,this._keydownListener=r=>{const s=this._attachedOverlays;for(let o=s.length-1;o>-1;o--)if(s[o]._keydownEvents.observers.length>0){const a=s[o]._keydownEvents;this._ngZone?this._ngZone.run(()=>a.next(r)):a.next(r);break}}}add(t){super.add(t),this._isAttached||(this._ngZone?this._ngZone.runOutsideAngular(()=>this._document.body.addEventListener("keydown",this._keydownListener)):this._document.body.addEventListener("keydown",this._keydownListener),this._isAttached=!0)}detach(){this._isAttached&&(this._document.body.removeEventListener("keydown",this._keydownListener),this._isAttached=!1)}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn),xe(Xt,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),IK=(()=>{class n extends RN{constructor(t,i,r){super(t),this._platform=i,this._ngZone=r,this._cursorStyleIsSet=!1,this._pointerDownListener=s=>{this._pointerDownEventTarget=th(s)},this._clickListener=s=>{const o=th(s),a="click"===s.type&&this._pointerDownEventTarget?this._pointerDownEventTarget:o;this._pointerDownEventTarget=null;const c=this._attachedOverlays.slice();for(let u=c.length-1;u>-1;u--){const p=c[u];if(p._outsidePointerEvents.observers.length<1||!p.hasAttached())continue;if(p.overlayElement.contains(o)||p.overlayElement.contains(a))break;const g=p._outsidePointerEvents;this._ngZone?this._ngZone.run(()=>g.next(s)):g.next(s)}}}add(t){if(super.add(t),!this._isAttached){const i=this._document.body;this._ngZone?this._ngZone.runOutsideAngular(()=>this._addEventListeners(i)):this._addEventListeners(i),this._platform.IOS&&!this._cursorStyleIsSet&&(this._cursorOriginalValue=i.style.cursor,i.style.cursor="pointer",this._cursorStyleIsSet=!0),this._isAttached=!0}}detach(){if(this._isAttached){const t=this._document.body;t.removeEventListener("pointerdown",this._pointerDownListener,!0),t.removeEventListener("click",this._clickListener,!0),t.removeEventListener("auxclick",this._clickListener,!0),t.removeEventListener("contextmenu",this._clickListener,!0),this._platform.IOS&&this._cursorStyleIsSet&&(t.style.cursor=this._cursorOriginalValue,this._cursorStyleIsSet=!1),this._isAttached=!1}}_addEventListeners(t){t.addEventListener("pointerdown",this._pointerDownListener,!0),t.addEventListener("click",this._clickListener,!0),t.addEventListener("auxclick",this._clickListener,!0),t.addEventListener("contextmenu",this._clickListener,!0)}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn),xe(as),xe(Xt,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),qw=(()=>{class n{constructor(t,i){this._platform=i,this._document=t}ngOnDestroy(){this._containerElement?.remove()}getContainerElement(){return this._containerElement||this._createContainer(),this._containerElement}_createContainer(){const t="cdk-overlay-container";if(this._platform.isBrowser||CT()){const r=this._document.querySelectorAll(`.${t}[platform="server"], .${t}[platform="test"]`);for(let s=0;sthis._backdropClick.next(g),this._backdropTransitionendHandler=g=>{this._disposeBackdrop(g.target)},this._keydownEvents=new cn,this._outsidePointerEvents=new cn,r.scrollStrategy&&(this._scrollStrategy=r.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=r.positionStrategy}get overlayElement(){return this._pane}get backdropElement(){return this._backdropElement}get hostElement(){return this._host}attach(e){!this._host.parentElement&&this._previousHostParent&&this._previousHostParent.appendChild(this._host);const t=this._portalOutlet.attach(e);return this._positionStrategy&&this._positionStrategy.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._ngZone.onStable.pipe(Gr(1)).subscribe(()=>{this.hasAttached()&&this.updatePosition()}),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&(this._locationChanges=this._location.subscribe(()=>this.dispose())),this._outsideClickDispatcher.add(this),"function"==typeof t?.onDestroy&&t.onDestroy(()=>{this.hasAttached()&&this._ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>this.detach()))}),t}detach(){if(!this.hasAttached())return;this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();const e=this._portalOutlet.detach();return this._detachments.next(),this._keyboardDispatcher.remove(this),this._detachContentWhenStable(),this._locationChanges.unsubscribe(),this._outsideClickDispatcher.remove(this),e}dispose(){const e=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this._disposeBackdrop(this._backdropElement),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._outsidePointerEvents.complete(),this._outsideClickDispatcher.remove(this),this._host?.remove(),this._previousHostParent=this._pane=this._host=null,e&&this._detachments.next(),this._detachments.complete()}hasAttached(){return this._portalOutlet.hasAttached()}backdropClick(){return this._backdropClick}attachments(){return this._attachments}detachments(){return this._detachments}keydownEvents(){return this._keydownEvents}outsidePointerEvents(){return this._outsidePointerEvents}getConfig(){return this._config}updatePosition(){this._positionStrategy&&this._positionStrategy.apply()}updatePositionStrategy(e){e!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=e,this.hasAttached()&&(e.attach(this),this.updatePosition()))}updateSize(e){this._config={...this._config,...e},this._updateElementSize()}setDirection(e){this._config={...this._config,direction:e},this._updateElementDirection()}addPanelClass(e){this._pane&&this._toggleClasses(this._pane,e,!0)}removePanelClass(e){this._pane&&this._toggleClasses(this._pane,e,!1)}getDirection(){const e=this._config.direction;return e?"string"==typeof e?e:e.value:"ltr"}updateScrollStrategy(e){e!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=e,this.hasAttached()&&(e.attach(this),e.enable()))}_updateElementDirection(){this._host.setAttribute("dir",this.getDirection())}_updateElementSize(){if(!this._pane)return;const e=this._pane.style;e.width=Cs(this._config.width),e.height=Cs(this._config.height),e.minWidth=Cs(this._config.minWidth),e.minHeight=Cs(this._config.minHeight),e.maxWidth=Cs(this._config.maxWidth),e.maxHeight=Cs(this._config.maxHeight)}_togglePointerEvents(e){this._pane.style.pointerEvents=e?"":"none"}_attachBackdrop(){const e="cdk-overlay-backdrop-showing";this._backdropElement=this._document.createElement("div"),this._backdropElement.classList.add("cdk-overlay-backdrop"),this._animationsDisabled&&this._backdropElement.classList.add("cdk-overlay-backdrop-noop-animation"),this._config.backdropClass&&this._toggleClasses(this._backdropElement,this._config.backdropClass,!0),this._host.parentElement.insertBefore(this._backdropElement,this._host),this._backdropElement.addEventListener("click",this._backdropClickHandler),!this._animationsDisabled&&typeof requestAnimationFrame<"u"?this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>{this._backdropElement&&this._backdropElement.classList.add(e)})}):this._backdropElement.classList.add(e)}_updateStackingOrder(){this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}detachBackdrop(){const e=this._backdropElement;if(e){if(this._animationsDisabled)return void this._disposeBackdrop(e);e.classList.remove("cdk-overlay-backdrop-showing"),this._ngZone.runOutsideAngular(()=>{e.addEventListener("transitionend",this._backdropTransitionendHandler)}),e.style.pointerEvents="none",this._backdropTimeout=this._ngZone.runOutsideAngular(()=>setTimeout(()=>{this._disposeBackdrop(e)},500))}}_toggleClasses(e,t,i){const r=Iw(t||[]).filter(s=>!!s);r.length&&(i?e.classList.add(...r):e.classList.remove(...r))}_detachContentWhenStable(){this._ngZone.runOutsideAngular(()=>{const e=this._ngZone.onStable.pipe(Tr(fa(this._attachments,this._detachments))).subscribe(()=>{(!this._pane||!this._host||0===this._pane.children.length)&&(this._pane&&this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!1),this._host&&this._host.parentElement&&(this._previousHostParent=this._host.parentElement,this._host.remove()),e.unsubscribe())})})}_disposeScrollStrategy(){const e=this._scrollStrategy;e&&(e.disable(),e.detach&&e.detach())}_disposeBackdrop(e){e&&(e.removeEventListener("click",this._backdropClickHandler),e.removeEventListener("transitionend",this._backdropTransitionendHandler),e.remove(),this._backdropElement===e&&(this._backdropElement=null)),this._backdropTimeout&&(clearTimeout(this._backdropTimeout),this._backdropTimeout=void 0)}}const PN="cdk-overlay-connected-position-bounding-box",FK=/([A-Za-z%]+)$/;class RK{get positions(){return this._preferredPositions}constructor(e,t,i,r,s){this._viewportRuler=t,this._document=i,this._platform=r,this._overlayContainer=s,this._lastBoundingBoxSize={width:0,height:0},this._isPushed=!1,this._canPush=!0,this._growAfterOpen=!1,this._hasFlexibleDimensions=!0,this._positionLocked=!1,this._viewportMargin=0,this._scrollables=[],this._preferredPositions=[],this._positionChanges=new cn,this._resizeSubscription=Tn.EMPTY,this._offsetX=0,this._offsetY=0,this._appliedPanelClasses=[],this.positionChanges=this._positionChanges,this.setOrigin(e)}attach(e){this._validatePositions(),e.hostElement.classList.add(PN),this._overlayRef=e,this._boundingBox=e.hostElement,this._pane=e.overlayElement,this._isDisposed=!1,this._isInitialRender=!0,this._lastPosition=null,this._resizeSubscription.unsubscribe(),this._resizeSubscription=this._viewportRuler.change().subscribe(()=>{this._isInitialRender=!0,this.apply()})}apply(){if(this._isDisposed||!this._platform.isBrowser)return;if(!this._isInitialRender&&this._positionLocked&&this._lastPosition)return void this.reapplyLastPosition();this._clearPanelClasses(),this._resetOverlayElementStyles(),this._resetBoundingBoxStyles(),this._viewportRect=this._getNarrowedViewportRect(),this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const e=this._originRect,t=this._overlayRect,i=this._viewportRect,r=this._containerRect,s=[];let o;for(let a of this._preferredPositions){let c=this._getOriginPoint(e,r,a),u=this._getOverlayPoint(c,t,a),p=this._getOverlayFit(u,t,i,a);if(p.isCompletelyWithinViewport)return this._isPushed=!1,void this._applyPosition(a,c);this._canFitWithFlexibleDimensions(p,u,i)?s.push({position:a,origin:c,overlayRect:t,boundingBoxRect:this._calculateBoundingBoxRect(c,a)}):(!o||o.overlayFit.visibleAreac&&(c=p,a=u)}return this._isPushed=!1,void this._applyPosition(a.position,a.origin)}if(this._canPush)return this._isPushed=!0,void this._applyPosition(o.position,o.originPoint);this._applyPosition(o.position,o.originPoint)}detach(){this._clearPanelClasses(),this._lastPosition=null,this._previousPushAmount=null,this._resizeSubscription.unsubscribe()}dispose(){this._isDisposed||(this._boundingBox&&Hf(this._boundingBox.style,{top:"",left:"",right:"",bottom:"",height:"",width:"",alignItems:"",justifyContent:""}),this._pane&&this._resetOverlayElementStyles(),this._overlayRef&&this._overlayRef.hostElement.classList.remove(PN),this.detach(),this._positionChanges.complete(),this._overlayRef=this._boundingBox=null,this._isDisposed=!0)}reapplyLastPosition(){if(this._isDisposed||!this._platform.isBrowser)return;const e=this._lastPosition;if(e){this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._viewportRect=this._getNarrowedViewportRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const t=this._getOriginPoint(this._originRect,this._containerRect,e);this._applyPosition(e,t)}else this.apply()}withScrollableContainers(e){return this._scrollables=e,this}withPositions(e){return this._preferredPositions=e,-1===e.indexOf(this._lastPosition)&&(this._lastPosition=null),this._validatePositions(),this}withViewportMargin(e){return this._viewportMargin=e,this}withFlexibleDimensions(e=!0){return this._hasFlexibleDimensions=e,this}withGrowAfterOpen(e=!0){return this._growAfterOpen=e,this}withPush(e=!0){return this._canPush=e,this}withLockedPosition(e=!0){return this._positionLocked=e,this}setOrigin(e){return this._origin=e,this}withDefaultOffsetX(e){return this._offsetX=e,this}withDefaultOffsetY(e){return this._offsetY=e,this}withTransformOriginOn(e){return this._transformOriginSelector=e,this}_getOriginPoint(e,t,i){let r,s;if("center"==i.originX)r=e.left+e.width/2;else{const o=this._isRtl()?e.right:e.left,a=this._isRtl()?e.left:e.right;r="start"==i.originX?o:a}return t.left<0&&(r-=t.left),s="center"==i.originY?e.top+e.height/2:"top"==i.originY?e.top:e.bottom,t.top<0&&(s-=t.top),{x:r,y:s}}_getOverlayPoint(e,t,i){let r,s;return r="center"==i.overlayX?-t.width/2:"start"===i.overlayX?this._isRtl()?-t.width:0:this._isRtl()?0:-t.width,s="center"==i.overlayY?-t.height/2:"top"==i.overlayY?0:-t.height,{x:e.x+r,y:e.y+s}}_getOverlayFit(e,t,i,r){const s=LN(t);let{x:o,y:a}=e,c=this._getOffset(r,"x"),u=this._getOffset(r,"y");c&&(o+=c),u&&(a+=u);let v=0-a,y=a+s.height-i.height,x=this._subtractOverflows(s.width,0-o,o+s.width-i.width),T=this._subtractOverflows(s.height,v,y),N=x*T;return{visibleArea:N,isCompletelyWithinViewport:s.width*s.height===N,fitsInViewportVertically:T===s.height,fitsInViewportHorizontally:x==s.width}}_canFitWithFlexibleDimensions(e,t,i){if(this._hasFlexibleDimensions){const r=i.bottom-t.y,s=i.right-t.x,o=ON(this._overlayRef.getConfig().minHeight),a=ON(this._overlayRef.getConfig().minWidth);return(e.fitsInViewportVertically||null!=o&&o<=r)&&(e.fitsInViewportHorizontally||null!=a&&a<=s)}return!1}_pushOverlayOnScreen(e,t,i){if(this._previousPushAmount&&this._positionLocked)return{x:e.x+this._previousPushAmount.x,y:e.y+this._previousPushAmount.y};const r=LN(t),s=this._viewportRect,o=Math.max(e.x+r.width-s.width,0),a=Math.max(e.y+r.height-s.height,0),c=Math.max(s.top-i.top-e.y,0),u=Math.max(s.left-i.left-e.x,0);let p=0,g=0;return p=r.width<=s.width?u||-o:e.xx&&!this._isInitialRender&&!this._growAfterOpen&&(o=e.y-x/2)}if("end"===t.overlayX&&!r||"start"===t.overlayX&&r)v=i.width-e.x+this._viewportMargin,p=e.x-this._viewportMargin;else if("start"===t.overlayX&&!r||"end"===t.overlayX&&r)g=e.x,p=i.right-e.x;else{const y=Math.min(i.right-e.x+i.left,e.x),x=this._lastBoundingBoxSize.width;p=2*y,g=e.x-y,p>x&&!this._isInitialRender&&!this._growAfterOpen&&(g=e.x-x/2)}return{top:o,left:g,bottom:a,right:v,width:p,height:s}}_setBoundingBoxStyles(e,t){const i=this._calculateBoundingBoxRect(e,t);!this._isInitialRender&&!this._growAfterOpen&&(i.height=Math.min(i.height,this._lastBoundingBoxSize.height),i.width=Math.min(i.width,this._lastBoundingBoxSize.width));const r={};if(this._hasExactPosition())r.top=r.left="0",r.bottom=r.right=r.maxHeight=r.maxWidth="",r.width=r.height="100%";else{const s=this._overlayRef.getConfig().maxHeight,o=this._overlayRef.getConfig().maxWidth;r.height=Cs(i.height),r.top=Cs(i.top),r.bottom=Cs(i.bottom),r.width=Cs(i.width),r.left=Cs(i.left),r.right=Cs(i.right),r.alignItems="center"===t.overlayX?"center":"end"===t.overlayX?"flex-end":"flex-start",r.justifyContent="center"===t.overlayY?"center":"bottom"===t.overlayY?"flex-end":"flex-start",s&&(r.maxHeight=Cs(s)),o&&(r.maxWidth=Cs(o))}this._lastBoundingBoxSize=i,Hf(this._boundingBox.style,r)}_resetBoundingBoxStyles(){Hf(this._boundingBox.style,{top:"0",left:"0",right:"0",bottom:"0",height:"",width:"",alignItems:"",justifyContent:""})}_resetOverlayElementStyles(){Hf(this._pane.style,{top:"",left:"",bottom:"",right:"",position:"",transform:""})}_setOverlayElementStyles(e,t){const i={},r=this._hasExactPosition(),s=this._hasFlexibleDimensions,o=this._overlayRef.getConfig();if(r){const p=this._viewportRuler.getViewportScrollPosition();Hf(i,this._getExactOverlayY(t,e,p)),Hf(i,this._getExactOverlayX(t,e,p))}else i.position="static";let a="",c=this._getOffset(t,"x"),u=this._getOffset(t,"y");c&&(a+=`translateX(${c}px) `),u&&(a+=`translateY(${u}px)`),i.transform=a.trim(),o.maxHeight&&(r?i.maxHeight=Cs(o.maxHeight):s&&(i.maxHeight="")),o.maxWidth&&(r?i.maxWidth=Cs(o.maxWidth):s&&(i.maxWidth="")),Hf(this._pane.style,i)}_getExactOverlayY(e,t,i){let r={top:"",bottom:""},s=this._getOverlayPoint(t,this._overlayRect,e);return this._isPushed&&(s=this._pushOverlayOnScreen(s,this._overlayRect,i)),"bottom"===e.overlayY?r.bottom=this._document.documentElement.clientHeight-(s.y+this._overlayRect.height)+"px":r.top=Cs(s.y),r}_getExactOverlayX(e,t,i){let o,r={left:"",right:""},s=this._getOverlayPoint(t,this._overlayRect,e);return this._isPushed&&(s=this._pushOverlayOnScreen(s,this._overlayRect,i)),o=this._isRtl()?"end"===e.overlayX?"left":"right":"end"===e.overlayX?"right":"left","right"===o?r.right=this._document.documentElement.clientWidth-(s.x+this._overlayRect.width)+"px":r.left=Cs(s.x),r}_getScrollVisibility(){const e=this._getOriginRect(),t=this._pane.getBoundingClientRect(),i=this._scrollables.map(r=>r.getElementRef().nativeElement.getBoundingClientRect());return{isOriginClipped:FN(e,i),isOriginOutsideView:YT(e,i),isOverlayClipped:FN(t,i),isOverlayOutsideView:YT(t,i)}}_subtractOverflows(e,...t){return t.reduce((i,r)=>i-Math.max(r,0),e)}_getNarrowedViewportRect(){const e=this._document.documentElement.clientWidth,t=this._document.documentElement.clientHeight,i=this._viewportRuler.getViewportScrollPosition();return{top:i.top+this._viewportMargin,left:i.left+this._viewportMargin,right:i.left+e-this._viewportMargin,bottom:i.top+t-this._viewportMargin,width:e-2*this._viewportMargin,height:t-2*this._viewportMargin}}_isRtl(){return"rtl"===this._overlayRef.getDirection()}_hasExactPosition(){return!this._hasFlexibleDimensions||this._isPushed}_getOffset(e,t){return"x"===t?null==e.offsetX?this._offsetX:e.offsetX:null==e.offsetY?this._offsetY:e.offsetY}_validatePositions(){}_addPanelClasses(e){this._pane&&Iw(e).forEach(t=>{""!==t&&-1===this._appliedPanelClasses.indexOf(t)&&(this._appliedPanelClasses.push(t),this._pane.classList.add(t))})}_clearPanelClasses(){this._pane&&(this._appliedPanelClasses.forEach(e=>{this._pane.classList.remove(e)}),this._appliedPanelClasses=[])}_getOriginRect(){const e=this._origin;if(e instanceof _n)return e.nativeElement.getBoundingClientRect();if(e instanceof Element)return e.getBoundingClientRect();const t=e.width||0,i=e.height||0;return{top:e.y,bottom:e.y+i,left:e.x,right:e.x+t,height:i,width:t}}}function Hf(n,e){for(let t in e)e.hasOwnProperty(t)&&(n[t]=e[t]);return n}function ON(n){if("number"!=typeof n&&null!=n){const[e,t]=n.split(FK);return t&&"px"!==t?null:parseFloat(e)}return n||null}function LN(n){return{top:Math.floor(n.top),right:Math.floor(n.right),bottom:Math.floor(n.bottom),left:Math.floor(n.left),width:Math.floor(n.width),height:Math.floor(n.height)}}const NN="cdk-global-overlay-wrapper";class PK{constructor(){this._cssPosition="static",this._topOffset="",this._bottomOffset="",this._alignItems="",this._xPosition="",this._xOffset="",this._width="",this._height="",this._isDisposed=!1}attach(e){const t=e.getConfig();this._overlayRef=e,this._width&&!t.width&&e.updateSize({width:this._width}),this._height&&!t.height&&e.updateSize({height:this._height}),e.hostElement.classList.add(NN),this._isDisposed=!1}top(e=""){return this._bottomOffset="",this._topOffset=e,this._alignItems="flex-start",this}left(e=""){return this._xOffset=e,this._xPosition="left",this}bottom(e=""){return this._topOffset="",this._bottomOffset=e,this._alignItems="flex-end",this}right(e=""){return this._xOffset=e,this._xPosition="right",this}start(e=""){return this._xOffset=e,this._xPosition="start",this}end(e=""){return this._xOffset=e,this._xPosition="end",this}width(e=""){return this._overlayRef?this._overlayRef.updateSize({width:e}):this._width=e,this}height(e=""){return this._overlayRef?this._overlayRef.updateSize({height:e}):this._height=e,this}centerHorizontally(e=""){return this.left(e),this._xPosition="center",this}centerVertically(e=""){return this.top(e),this._alignItems="center",this}apply(){if(!this._overlayRef||!this._overlayRef.hasAttached())return;const e=this._overlayRef.overlayElement.style,t=this._overlayRef.hostElement.style,i=this._overlayRef.getConfig(),{width:r,height:s,maxWidth:o,maxHeight:a}=i,c=!("100%"!==r&&"100vw"!==r||o&&"100%"!==o&&"100vw"!==o),u=!("100%"!==s&&"100vh"!==s||a&&"100%"!==a&&"100vh"!==a),p=this._xPosition,g=this._xOffset,v="rtl"===this._overlayRef.getConfig().direction;let y="",x="",T="";c?T="flex-start":"center"===p?(T="center",v?x=g:y=g):v?"left"===p||"end"===p?(T="flex-end",y=g):("right"===p||"start"===p)&&(T="flex-start",x=g):"left"===p||"start"===p?(T="flex-start",y=g):("right"===p||"end"===p)&&(T="flex-end",x=g),e.position=this._cssPosition,e.marginLeft=c?"0":y,e.marginTop=u?"0":this._topOffset,e.marginBottom=this._bottomOffset,e.marginRight=c?"0":x,t.justifyContent=T,t.alignItems=u?"flex-start":this._alignItems}dispose(){if(this._isDisposed||!this._overlayRef)return;const e=this._overlayRef.overlayElement.style,t=this._overlayRef.hostElement,i=t.style;t.classList.remove(NN),i.justifyContent=i.alignItems=e.marginTop=e.marginBottom=e.marginLeft=e.marginRight=e.position="",this._overlayRef=null,this._isDisposed=!0}}let OK=(()=>{class n{constructor(t,i,r,s){this._viewportRuler=t,this._document=i,this._platform=r,this._overlayContainer=s}global(){return new PK}flexibleConnectedTo(t){return new RK(t,this._viewportRuler,this._document,this._platform,this._overlayContainer)}}return n.\u0275fac=function(t){return new(t||n)(xe(Gw),xe(Mn),xe(as),xe(qw))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),LK=0,hl=(()=>{class n{constructor(t,i,r,s,o,a,c,u,p,g,v,y){this.scrollStrategies=t,this._overlayContainer=i,this._componentFactoryResolver=r,this._positionBuilder=s,this._keyboardDispatcher=o,this._injector=a,this._ngZone=c,this._document=u,this._directionality=p,this._location=g,this._outsideClickDispatcher=v,this._animationsModuleType=y}create(t){const i=this._createHostElement(),r=this._createPaneElement(i),s=this._createPortalOutlet(r),o=new XT(t);return o.direction=o.direction||this._directionality.value,new hg(s,i,r,o,this._ngZone,this._keyboardDispatcher,this._document,this._location,this._outsideClickDispatcher,"NoopAnimations"===this._animationsModuleType)}position(){return this._positionBuilder}_createPaneElement(t){const i=this._document.createElement("div");return i.id="cdk-overlay-"+LK++,i.classList.add("cdk-overlay-pane"),t.appendChild(i),i}_createHostElement(){const t=this._document.createElement("div");return this._overlayContainer.getContainerElement().appendChild(t),t}_createPortalOutlet(t){return this._appRef||(this._appRef=this._injector.get(Jm)),new wK(t,this._componentFactoryResolver,this._appRef,this._injector,this._document)}}return n.\u0275fac=function(t){return new(t||n)(xe(TK),xe(qw),xe(Fd),xe(OK),xe(kK),xe(ts),xe(Xt),xe(Mn),xe(Yl),xe(Mv),xe(IK),xe(bo,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const NK=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],BN=new Ze("cdk-connected-overlay-scroll-strategy");let ZT=(()=>{class n{constructor(t){this.elementRef=t}}return n.\u0275fac=function(t){return new(t||n)(ie(_n))},n.\u0275dir=ut({type:n,selectors:[["","cdk-overlay-origin",""],["","overlay-origin",""],["","cdkOverlayOrigin",""]],exportAs:["cdkOverlayOrigin"],standalone:!0}),n})(),VN=(()=>{class n{get offsetX(){return this._offsetX}set offsetX(t){this._offsetX=t,this._position&&this._updatePositionStrategy(this._position)}get offsetY(){return this._offsetY}set offsetY(t){this._offsetY=t,this._position&&this._updatePositionStrategy(this._position)}get hasBackdrop(){return this._hasBackdrop}set hasBackdrop(t){this._hasBackdrop=bi(t)}get lockPosition(){return this._lockPosition}set lockPosition(t){this._lockPosition=bi(t)}get flexibleDimensions(){return this._flexibleDimensions}set flexibleDimensions(t){this._flexibleDimensions=bi(t)}get growAfterOpen(){return this._growAfterOpen}set growAfterOpen(t){this._growAfterOpen=bi(t)}get push(){return this._push}set push(t){this._push=bi(t)}constructor(t,i,r,s,o){this._overlay=t,this._dir=o,this._hasBackdrop=!1,this._lockPosition=!1,this._growAfterOpen=!1,this._flexibleDimensions=!1,this._push=!1,this._backdropSubscription=Tn.EMPTY,this._attachSubscription=Tn.EMPTY,this._detachSubscription=Tn.EMPTY,this._positionSubscription=Tn.EMPTY,this.viewportMargin=0,this.open=!1,this.disableClose=!1,this.backdropClick=new Pn,this.positionChange=new Pn,this.attach=new Pn,this.detach=new Pn,this.overlayKeydown=new Pn,this.overlayOutsideClick=new Pn,this._templatePortal=new qT(i,r),this._scrollStrategyFactory=s,this.scrollStrategy=this._scrollStrategyFactory()}get overlayRef(){return this._overlayRef}get dir(){return this._dir?this._dir.value:"ltr"}ngOnDestroy(){this._attachSubscription.unsubscribe(),this._detachSubscription.unsubscribe(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this._overlayRef&&this._overlayRef.dispose()}ngOnChanges(t){this._position&&(this._updatePositionStrategy(this._position),this._overlayRef.updateSize({width:this.width,minWidth:this.minWidth,height:this.height,minHeight:this.minHeight}),t.origin&&this.open&&this._position.apply()),t.open&&(this.open?this._attachOverlay():this._detachOverlay())}_createOverlay(){(!this.positions||!this.positions.length)&&(this.positions=NK);const t=this._overlayRef=this._overlay.create(this._buildConfig());this._attachSubscription=t.attachments().subscribe(()=>this.attach.emit()),this._detachSubscription=t.detachments().subscribe(()=>this.detach.emit()),t.keydownEvents().subscribe(i=>{this.overlayKeydown.next(i),27===i.keyCode&&!this.disableClose&&!ql(i)&&(i.preventDefault(),this._detachOverlay())}),this._overlayRef.outsidePointerEvents().subscribe(i=>{this.overlayOutsideClick.next(i)})}_buildConfig(){const t=this._position=this.positionStrategy||this._createPositionStrategy(),i=new XT({direction:this._dir,positionStrategy:t,scrollStrategy:this.scrollStrategy,hasBackdrop:this.hasBackdrop});return(this.width||0===this.width)&&(i.width=this.width),(this.height||0===this.height)&&(i.height=this.height),(this.minWidth||0===this.minWidth)&&(i.minWidth=this.minWidth),(this.minHeight||0===this.minHeight)&&(i.minHeight=this.minHeight),this.backdropClass&&(i.backdropClass=this.backdropClass),this.panelClass&&(i.panelClass=this.panelClass),i}_updatePositionStrategy(t){const i=this.positions.map(r=>({originX:r.originX,originY:r.originY,overlayX:r.overlayX,overlayY:r.overlayY,offsetX:r.offsetX||this.offsetX,offsetY:r.offsetY||this.offsetY,panelClass:r.panelClass||void 0}));return t.setOrigin(this._getFlexibleConnectedPositionStrategyOrigin()).withPositions(i).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector)}_createPositionStrategy(){const t=this._overlay.position().flexibleConnectedTo(this._getFlexibleConnectedPositionStrategyOrigin());return this._updatePositionStrategy(t),t}_getFlexibleConnectedPositionStrategyOrigin(){return this.origin instanceof ZT?this.origin.elementRef:this.origin}_attachOverlay(){this._overlayRef?this._overlayRef.getConfig().hasBackdrop=this.hasBackdrop:this._createOverlay(),this._overlayRef.hasAttached()||this._overlayRef.attach(this._templatePortal),this.hasBackdrop?this._backdropSubscription=this._overlayRef.backdropClick().subscribe(t=>{this.backdropClick.emit(t)}):this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.positionChange.observers.length>0&&(this._positionSubscription=this._position.positionChanges.pipe(AN(()=>this.positionChange.observers.length>0)).subscribe(t=>{this.positionChange.emit(t),0===this.positionChange.observers.length&&this._positionSubscription.unsubscribe()}))}_detachOverlay(){this._overlayRef&&this._overlayRef.detach(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe()}}return n.\u0275fac=function(t){return new(t||n)(ie(hl),ie(al),ie(Sa),ie(BN),ie(Yl,8))},n.\u0275dir=ut({type:n,selectors:[["","cdk-connected-overlay",""],["","connected-overlay",""],["","cdkConnectedOverlay",""]],inputs:{origin:["cdkConnectedOverlayOrigin","origin"],positions:["cdkConnectedOverlayPositions","positions"],positionStrategy:["cdkConnectedOverlayPositionStrategy","positionStrategy"],offsetX:["cdkConnectedOverlayOffsetX","offsetX"],offsetY:["cdkConnectedOverlayOffsetY","offsetY"],width:["cdkConnectedOverlayWidth","width"],height:["cdkConnectedOverlayHeight","height"],minWidth:["cdkConnectedOverlayMinWidth","minWidth"],minHeight:["cdkConnectedOverlayMinHeight","minHeight"],backdropClass:["cdkConnectedOverlayBackdropClass","backdropClass"],panelClass:["cdkConnectedOverlayPanelClass","panelClass"],viewportMargin:["cdkConnectedOverlayViewportMargin","viewportMargin"],scrollStrategy:["cdkConnectedOverlayScrollStrategy","scrollStrategy"],open:["cdkConnectedOverlayOpen","open"],disableClose:["cdkConnectedOverlayDisableClose","disableClose"],transformOriginSelector:["cdkConnectedOverlayTransformOriginOn","transformOriginSelector"],hasBackdrop:["cdkConnectedOverlayHasBackdrop","hasBackdrop"],lockPosition:["cdkConnectedOverlayLockPosition","lockPosition"],flexibleDimensions:["cdkConnectedOverlayFlexibleDimensions","flexibleDimensions"],growAfterOpen:["cdkConnectedOverlayGrowAfterOpen","growAfterOpen"],push:["cdkConnectedOverlayPush","push"]},outputs:{backdropClick:"backdropClick",positionChange:"positionChange",attach:"attach",detach:"detach",overlayKeydown:"overlayKeydown",overlayOutsideClick:"overlayOutsideClick"},exportAs:["cdkConnectedOverlay"],standalone:!0,features:[Cn]}),n})();const VK={provide:BN,deps:[hl],useFactory:function BK(n){return()=>n.scrollStrategies.reposition()}};let Kw=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[hl,VK],imports:[jv,Kv,TN,TN]}),n})();function Yv(n){return new un(e=>{let t;try{t=n()}catch(r){return void e.error(r)}return(t?dr(t):kw()).subscribe(e)})}function HK(n,e){}class Xv{constructor(){this.role="dialog",this.panelClass="",this.hasBackdrop=!0,this.backdropClass="",this.disableClose=!1,this.width="",this.height="",this.data=null,this.ariaDescribedBy=null,this.ariaLabelledBy=null,this.ariaLabel=null,this.ariaModal=!0,this.autoFocus="first-tabbable",this.restoreFocus=!0,this.closeOnNavigation=!0,this.closeOnDestroy=!0,this.closeOnOverlayDetachments=!0}}let JT=(()=>{class n extends KT{constructor(t,i,r,s,o,a,c,u){super(),this._elementRef=t,this._focusTrapFactory=i,this._config=s,this._interactivityChecker=o,this._ngZone=a,this._overlayRef=c,this._focusMonitor=u,this._elementFocusedBeforeDialogWasOpened=null,this._closeInteractionType=null,this.attachDomPortal=p=>{this._portalOutlet.hasAttached();const g=this._portalOutlet.attachDomPortal(p);return this._contentAttached(),g},this._ariaLabelledBy=this._config.ariaLabelledBy||null,this._document=r}_contentAttached(){this._initializeFocusTrap(),this._handleBackdropClicks(),this._captureInitialFocus()}_captureInitialFocus(){this._trapFocus()}ngOnDestroy(){this._restoreFocus()}attachComponentPortal(t){this._portalOutlet.hasAttached();const i=this._portalOutlet.attachComponentPortal(t);return this._contentAttached(),i}attachTemplatePortal(t){this._portalOutlet.hasAttached();const i=this._portalOutlet.attachTemplatePortal(t);return this._contentAttached(),i}_recaptureFocus(){this._containsFocus()||this._trapFocus()}_forceFocus(t,i){this._interactivityChecker.isFocusable(t)||(t.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{const r=()=>{t.removeEventListener("blur",r),t.removeEventListener("mousedown",r),t.removeAttribute("tabindex")};t.addEventListener("blur",r),t.addEventListener("mousedown",r)})),t.focus(i)}_focusByCssSelector(t,i){let r=this._elementRef.nativeElement.querySelector(t);r&&this._forceFocus(r,i)}_trapFocus(){const t=this._elementRef.nativeElement;switch(this._config.autoFocus){case!1:case"dialog":this._containsFocus()||t.focus();break;case!0:case"first-tabbable":this._focusTrap.focusInitialElementWhenReady().then(i=>{i||this._focusDialogContainer()});break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]');break;default:this._focusByCssSelector(this._config.autoFocus)}}_restoreFocus(){const t=this._config.restoreFocus;let i=null;if("string"==typeof t?i=this._document.querySelector(t):"boolean"==typeof t?i=t?this._elementFocusedBeforeDialogWasOpened:null:t&&(i=t),this._config.restoreFocus&&i&&"function"==typeof i.focus){const r=Dw(),s=this._elementRef.nativeElement;(!r||r===this._document.body||r===s||s.contains(r))&&(this._focusMonitor?(this._focusMonitor.focusVia(i,this._closeInteractionType),this._closeInteractionType=null):i.focus())}this._focusTrap&&this._focusTrap.destroy()}_focusDialogContainer(){this._elementRef.nativeElement.focus&&this._elementRef.nativeElement.focus()}_containsFocus(){const t=this._elementRef.nativeElement,i=Dw();return t===i||t.contains(i)}_initializeFocusTrap(){this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._document&&(this._elementFocusedBeforeDialogWasOpened=Dw())}_handleBackdropClicks(){this._overlayRef.backdropClick().subscribe(()=>{this._config.disableClose&&this._recaptureFocus()})}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Lw),ie(Mn,8),ie(Xv),ie(Gv),ie(Xt),ie(hg),ie(Vf))},n.\u0275cmp=Ln({type:n,selectors:[["cdk-dialog-container"]],viewQuery:function(t,i){if(1&t&&zr($w,7),2&t){let r;Yn(r=Xn())&&(i._portalOutlet=r.first)}},hostAttrs:["tabindex","-1",1,"cdk-dialog-container"],hostVars:6,hostBindings:function(t,i){2&t&&Di("id",i._config.id||null)("role",i._config.role)("aria-modal",i._config.ariaModal)("aria-labelledby",i._config.ariaLabel?null:i._ariaLabelledBy)("aria-label",i._config.ariaLabel)("aria-describedby",i._config.ariaDescribedBy||null)},features:[Z],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(t,i){1&t&&mt(0,HK,0,0,"ng-template",0)},dependencies:[$w],styles:[".cdk-dialog-container{display:block;width:100%;height:100%;min-height:inherit;max-height:inherit}"],encapsulation:2}),n})();class QT{constructor(e,t){this.overlayRef=e,this.config=t,this.closed=new cn,this.disableClose=t.disableClose,this.backdropClick=e.backdropClick(),this.keydownEvents=e.keydownEvents(),this.outsidePointerEvents=e.outsidePointerEvents(),this.id=t.id,this.keydownEvents.subscribe(i=>{27===i.keyCode&&!this.disableClose&&!ql(i)&&(i.preventDefault(),this.close(void 0,{focusOrigin:"keyboard"}))}),this.backdropClick.subscribe(()=>{this.disableClose||this.close(void 0,{focusOrigin:"mouse"})}),this._detachSubscription=e.detachments().subscribe(()=>{!1!==t.closeOnOverlayDetachments&&this.close()})}close(e,t){if(this.containerInstance){const i=this.closed;this.containerInstance._closeInteractionType=t?.focusOrigin||"program",this._detachSubscription.unsubscribe(),this.overlayRef.dispose(),i.next(e),i.complete(),this.componentInstance=this.containerInstance=null}}updatePosition(){return this.overlayRef.updatePosition(),this}updateSize(e="",t=""){return this.overlayRef.updateSize({width:e,height:t}),this}addPanelClass(e){return this.overlayRef.addPanelClass(e),this}removePanelClass(e){return this.overlayRef.removePanelClass(e),this}}const HN=new Ze("DialogScrollStrategy"),UK=new Ze("DialogData"),zK=new Ze("DefaultDialogConfig"),jK={provide:HN,deps:[hl],useFactory:function GK(n){return()=>n.scrollStrategies.block()}};let WK=0,eA=(()=>{class n{get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}constructor(t,i,r,s,o,a){this._overlay=t,this._injector=i,this._defaultOptions=r,this._parentDialog=s,this._overlayContainer=o,this._openDialogsAtThisLevel=[],this._afterAllClosedAtThisLevel=new cn,this._afterOpenedAtThisLevel=new cn,this._ariaHiddenElements=new Map,this.afterAllClosed=Yv(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(Bf(void 0))),this._scrollStrategy=a}open(t,i){(i={...this._defaultOptions||new Xv,...i}).id=i.id||"cdk-dialog-"+WK++,i.id&&this.getDialogById(i.id);const s=this._getOverlayConfig(i),o=this._overlay.create(s),a=new QT(o,i),c=this._attachContainer(o,a,i);return a.containerInstance=c,this._attachDialogContent(t,a,c,i),this.openDialogs.length||this._hideNonDialogContentFromAssistiveTechnology(),this.openDialogs.push(a),a.closed.subscribe(()=>this._removeOpenDialog(a,!0)),this.afterOpened.next(a),a}closeAll(){tA(this.openDialogs,t=>t.close())}getDialogById(t){return this.openDialogs.find(i=>i.id===t)}ngOnDestroy(){tA(this._openDialogsAtThisLevel,t=>{!1===t.config.closeOnDestroy&&this._removeOpenDialog(t,!1)}),tA(this._openDialogsAtThisLevel,t=>t.close()),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete(),this._openDialogsAtThisLevel=[]}_getOverlayConfig(t){const i=new XT({positionStrategy:t.positionStrategy||this._overlay.position().global().centerHorizontally().centerVertically(),scrollStrategy:t.scrollStrategy||this._scrollStrategy(),panelClass:t.panelClass,hasBackdrop:t.hasBackdrop,direction:t.direction,minWidth:t.minWidth,minHeight:t.minHeight,maxWidth:t.maxWidth,maxHeight:t.maxHeight,width:t.width,height:t.height,disposeOnNavigation:t.closeOnNavigation});return t.backdropClass&&(i.backdropClass=t.backdropClass),i}_attachContainer(t,i,r){const s=r.injector||r.viewContainerRef?.injector,o=[{provide:Xv,useValue:r},{provide:QT,useValue:i},{provide:hg,useValue:t}];let a;r.container?"function"==typeof r.container?a=r.container:(a=r.container.type,o.push(...r.container.providers(r))):a=JT;const c=new Ww(a,r.viewContainerRef,ts.create({parent:s||this._injector,providers:o}),r.componentFactoryResolver);return t.attach(c).instance}_attachDialogContent(t,i,r,s){if(t instanceof al){const o=this._createInjector(s,i,r,void 0);let a={$implicit:s.data,dialogRef:i};s.templateContext&&(a={...a,..."function"==typeof s.templateContext?s.templateContext():s.templateContext}),r.attachTemplatePortal(new qT(t,null,a,o))}else{const o=this._createInjector(s,i,r,this._injector),a=r.attachComponentPortal(new Ww(t,s.viewContainerRef,o,s.componentFactoryResolver));i.componentInstance=a.instance}}_createInjector(t,i,r,s){const o=t.injector||t.viewContainerRef?.injector,a=[{provide:UK,useValue:t.data},{provide:QT,useValue:i}];return t.providers&&("function"==typeof t.providers?a.push(...t.providers(i,t,r)):a.push(...t.providers)),t.direction&&(!o||!o.get(Yl,null,{optional:!0}))&&a.push({provide:Yl,useValue:{value:t.direction,change:Tt()}}),ts.create({parent:o||s,providers:a})}_removeOpenDialog(t,i){const r=this.openDialogs.indexOf(t);r>-1&&(this.openDialogs.splice(r,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((s,o)=>{s?o.setAttribute("aria-hidden",s):o.removeAttribute("aria-hidden")}),this._ariaHiddenElements.clear(),i&&this._getAfterAllClosed().next()))}_hideNonDialogContentFromAssistiveTechnology(){const t=this._overlayContainer.getContainerElement();if(t.parentElement){const i=t.parentElement.children;for(let r=i.length-1;r>-1;r--){const s=i[r];s!==t&&"SCRIPT"!==s.nodeName&&"STYLE"!==s.nodeName&&!s.hasAttribute("aria-live")&&(this._ariaHiddenElements.set(s,s.getAttribute("aria-hidden")),s.setAttribute("aria-hidden","true"))}}}_getAfterAllClosed(){const t=this._parentDialog;return t?t._getAfterAllClosed():this._afterAllClosedAtThisLevel}}return n.\u0275fac=function(t){return new(t||n)(xe(hl),xe(ts),xe(zK,8),xe(n,12),xe(qw),xe(HN))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();function tA(n,e){let t=n.length;for(;t--;)e(n[t])}let UN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[eA,jK],imports:[Kw,Kv,$L,Kv]}),n})();class zN{}class $K{}const Ud="*";function fg(n,e){return{type:7,name:n,definitions:e,options:{}}}function zd(n,e=null){return{type:4,styles:e,timings:n}}function Yw(n,e=null){return{type:3,steps:n,options:e}}function GN(n,e=null){return{type:2,steps:n,options:e}}function la(n){return{type:6,styles:n,offset:null}}function sh(n,e,t){return{type:0,name:n,styles:e,options:t}}function Xl(n,e,t=null){return{type:1,expr:n,animation:e,options:t}}function Zv(n=null){return{type:9,options:n}}function Jv(n,e,t=null){return{type:11,selector:n,animation:e,options:t}}function jN(n){Promise.resolve().then(n)}class Qv{constructor(e=0,t=0){this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._originalOnDoneFns=[],this._originalOnStartFns=[],this._started=!1,this._destroyed=!1,this._finished=!1,this._position=0,this.parentPlayer=null,this.totalTime=e+t}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}onStart(e){this._originalOnStartFns.push(e),this._onStartFns.push(e)}onDone(e){this._originalOnDoneFns.push(e),this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}hasStarted(){return this._started}init(){}play(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}triggerMicrotask(){jN(()=>this._onFinish())}_onStart(){this._onStartFns.forEach(e=>e()),this._onStartFns=[]}pause(){}restart(){}finish(){this._onFinish()}destroy(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}reset(){this._started=!1,this._finished=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}setPosition(e){this._position=this.totalTime?e*this.totalTime:1}getPosition(){return this.totalTime?this._position/this.totalTime:1}triggerCallback(e){const t="start"==e?this._onStartFns:this._onDoneFns;t.forEach(i=>i()),t.length=0}}class WN{constructor(e){this._onDoneFns=[],this._onStartFns=[],this._finished=!1,this._started=!1,this._destroyed=!1,this._onDestroyFns=[],this.parentPlayer=null,this.totalTime=0,this.players=e;let t=0,i=0,r=0;const s=this.players.length;0==s?jN(()=>this._onFinish()):this.players.forEach(o=>{o.onDone(()=>{++t==s&&this._onFinish()}),o.onDestroy(()=>{++i==s&&this._onDestroy()}),o.onStart(()=>{++r==s&&this._onStart()})}),this.totalTime=this.players.reduce((o,a)=>Math.max(o,a.totalTime),0)}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this.players.forEach(e=>e.init())}onStart(e){this._onStartFns.push(e)}_onStart(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach(e=>e()),this._onStartFns=[])}onDone(e){this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}hasStarted(){return this._started}play(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach(e=>e.play())}pause(){this.players.forEach(e=>e.pause())}restart(){this.players.forEach(e=>e.restart())}finish(){this._onFinish(),this.players.forEach(e=>e.finish())}destroy(){this._onDestroy()}_onDestroy(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach(e=>e.destroy()),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}reset(){this.players.forEach(e=>e.reset()),this._destroyed=!1,this._finished=!1,this._started=!1}setPosition(e){const t=e*this.totalTime;this.players.forEach(i=>{const r=i.totalTime?Math.min(1,t/i.totalTime):1;i.setPosition(r)})}getPosition(){const e=this.players.reduce((t,i)=>null===t||i.totalTime>t.totalTime?i:t,null);return null!=e?e.getPosition():0}beforeDestroy(){this.players.forEach(e=>{e.beforeDestroy&&e.beforeDestroy()})}triggerCallback(e){const t="start"==e?this._onStartFns:this._onDoneFns;t.forEach(i=>i()),t.length=0}}const nA="!";function qK(n,e){}class Xw{constructor(){this.role="dialog",this.panelClass="",this.hasBackdrop=!0,this.backdropClass="",this.disableClose=!1,this.width="",this.height="",this.maxWidth="80vw",this.data=null,this.ariaDescribedBy=null,this.ariaLabelledBy=null,this.ariaLabel=null,this.ariaModal=!0,this.autoFocus="first-tabbable",this.restoreFocus=!0,this.delayFocusTrap=!0,this.closeOnNavigation=!0}}const iA="mdc-dialog--open",$N="mdc-dialog--opening",qN="mdc-dialog--closing";let XK=(()=>{class n extends JT{constructor(t,i,r,s,o,a,c,u){super(t,i,r,s,o,a,c,u),this._animationStateChanged=new Pn}_captureInitialFocus(){this._config.delayFocusTrap||this._trapFocus()}_openAnimationDone(t){this._config.delayFocusTrap&&this._trapFocus(),this._animationStateChanged.next({state:"opened",totalTime:t})}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Lw),ie(Mn,8),ie(Xw),ie(Gv),ie(Xt),ie(hg),ie(Vf))},n.\u0275cmp=Ln({type:n,selectors:[["ng-component"]],features:[Z],decls:0,vars:0,template:function(t,i){},encapsulation:2}),n})();const KN="--mat-dialog-transition-duration";function YN(n){return null==n?null:"number"==typeof n?n:n.endsWith("ms")?ih(n.substring(0,n.length-2)):n.endsWith("s")?1e3*ih(n.substring(0,n.length-1)):"0"===n?0:null}let ZK=(()=>{class n extends XK{constructor(t,i,r,s,o,a,c,u,p){super(t,i,r,s,o,a,c,p),this._animationMode=u,this._animationsEnabled="NoopAnimations"!==this._animationMode,this._hostElement=this._elementRef.nativeElement,this._openAnimationDuration=this._animationsEnabled?YN(this._config.enterAnimationDuration)??150:0,this._closeAnimationDuration=this._animationsEnabled?YN(this._config.exitAnimationDuration)??75:0,this._animationTimer=null,this._finishDialogOpen=()=>{this._clearAnimationClasses(),this._openAnimationDone(this._openAnimationDuration)},this._finishDialogClose=()=>{this._clearAnimationClasses(),this._animationStateChanged.emit({state:"closed",totalTime:this._closeAnimationDuration})}}_contentAttached(){super._contentAttached(),this._startOpenAnimation()}ngOnDestroy(){super.ngOnDestroy(),null!==this._animationTimer&&clearTimeout(this._animationTimer)}_startOpenAnimation(){this._animationStateChanged.emit({state:"opening",totalTime:this._openAnimationDuration}),this._animationsEnabled?(this._hostElement.style.setProperty(KN,`${this._openAnimationDuration}ms`),this._hostElement.classList.add($N),this._hostElement.classList.add(iA),this._waitForAnimationToComplete(this._openAnimationDuration,this._finishDialogOpen)):(this._hostElement.classList.add(iA),Promise.resolve().then(()=>this._finishDialogOpen()))}_startExitAnimation(){this._animationStateChanged.emit({state:"closing",totalTime:this._closeAnimationDuration}),this._hostElement.classList.remove(iA),this._animationsEnabled?(this._hostElement.style.setProperty(KN,`${this._openAnimationDuration}ms`),this._hostElement.classList.add(qN),this._waitForAnimationToComplete(this._closeAnimationDuration,this._finishDialogClose)):Promise.resolve().then(()=>this._finishDialogClose())}_clearAnimationClasses(){this._hostElement.classList.remove($N),this._hostElement.classList.remove(qN)}_waitForAnimationToComplete(t,i){null!==this._animationTimer&&clearTimeout(this._animationTimer),this._animationTimer=setTimeout(i,t)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Lw),ie(Mn,8),ie(Xw),ie(Gv),ie(Xt),ie(hg),ie(bo,8),ie(Vf))},n.\u0275cmp=Ln({type:n,selectors:[["mat-dialog-container"]],hostAttrs:["tabindex","-1",1,"mat-mdc-dialog-container","mdc-dialog"],hostVars:8,hostBindings:function(t,i){2&t&&(Af("id",i._config.id),Di("aria-modal",i._config.ariaModal)("role",i._config.role)("aria-labelledby",i._config.ariaLabel?null:i._ariaLabelledBy)("aria-label",i._config.ariaLabel)("aria-describedby",i._config.ariaDescribedBy||null),hi("_mat-animation-noopable",!i._animationsEnabled))},features:[Z],decls:3,vars:0,consts:[[1,"mdc-dialog__container"],[1,"mat-mdc-dialog-surface","mdc-dialog__surface"],["cdkPortalOutlet",""]],template:function(t,i){1&t&&(ke(0,"div",0)(1,"div",1),mt(2,qK,0,0,"ng-template",2),Ne()())},dependencies:[$w],styles:['.mdc-elevation-overlay{position:absolute;border-radius:inherit;pointer-events:none;opacity:var(--mdc-elevation-overlay-opacity, 0);transition:opacity 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-dialog,.mdc-dialog__scrim{position:fixed;top:0;left:0;align-items:center;justify-content:center;box-sizing:border-box;width:100%;height:100%}.mdc-dialog{display:none;z-index:var(--mdc-dialog-z-index, 7)}.mdc-dialog .mdc-dialog__content{padding:20px 24px 20px 24px}.mdc-dialog .mdc-dialog__surface{min-width:280px}@media(max-width: 592px){.mdc-dialog .mdc-dialog__surface{max-width:calc(100vw - 32px)}}@media(min-width: 592px){.mdc-dialog .mdc-dialog__surface{max-width:560px}}.mdc-dialog .mdc-dialog__surface{max-height:calc(100% - 32px)}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{max-width:none}@media(max-width: 960px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{max-height:560px;width:560px}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__close{right:-12px}}@media(max-width: 720px)and (max-width: 672px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{width:calc(100vw - 112px)}}@media(max-width: 720px)and (min-width: 672px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{width:560px}}@media(max-width: 720px)and (max-height: 720px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{max-height:calc(100vh - 160px)}}@media(max-width: 720px)and (min-height: 720px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{max-height:560px}}@media(max-width: 720px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__close{right:-12px}}@media(max-width: 720px)and (max-height: 400px),(max-width: 600px),(min-width: 720px)and (max-height: 400px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{height:100%;max-height:100vh;max-width:100vw;width:100vw;border-radius:0}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__close{order:-1;left:-12px}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__header{padding:0 16px 9px;justify-content:flex-start}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__title{margin-left:calc(16px - 2 * 12px)}}@media(min-width: 960px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{width:calc(100vw - 400px)}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__close{right:-12px}}.mdc-dialog.mdc-dialog__scrim--hidden .mdc-dialog__scrim{opacity:0}.mdc-dialog__scrim{opacity:0;z-index:-1}.mdc-dialog__container{display:flex;flex-direction:row;align-items:center;justify-content:space-around;box-sizing:border-box;height:100%;transform:scale(0.8);opacity:0;pointer-events:none}.mdc-dialog__surface{position:relative;display:flex;flex-direction:column;flex-grow:0;flex-shrink:0;box-sizing:border-box;max-width:100%;max-height:100%;pointer-events:auto;overflow-y:auto}.mdc-dialog__surface .mdc-elevation-overlay{width:100%;height:100%;top:0;left:0}[dir=rtl] .mdc-dialog__surface,.mdc-dialog__surface[dir=rtl]{text-align:right}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-dialog__surface{outline:2px solid windowText}}.mdc-dialog__surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:2px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-dialog__surface::before{border-color:CanvasText}}@media screen and (-ms-high-contrast: active),screen and (-ms-high-contrast: none){.mdc-dialog__surface::before{content:none}}.mdc-dialog__title{display:block;margin-top:0;position:relative;flex-shrink:0;box-sizing:border-box;margin:0 0 1px;padding:0 24px 9px}.mdc-dialog__title::before{display:inline-block;width:0;height:40px;content:"";vertical-align:0}[dir=rtl] .mdc-dialog__title,.mdc-dialog__title[dir=rtl]{text-align:right}.mdc-dialog--scrollable .mdc-dialog__title{margin-bottom:1px;padding-bottom:15px}.mdc-dialog--fullscreen .mdc-dialog__header{align-items:baseline;border-bottom:1px solid rgba(0,0,0,0);display:inline-flex;justify-content:space-between;padding:0 24px 9px;z-index:1}@media screen and (forced-colors: active){.mdc-dialog--fullscreen .mdc-dialog__header{border-bottom-color:CanvasText}}.mdc-dialog--fullscreen .mdc-dialog__header .mdc-dialog__close{right:-12px}.mdc-dialog--fullscreen .mdc-dialog__title{margin-bottom:0;padding:0;border-bottom:0}.mdc-dialog--fullscreen.mdc-dialog--scrollable .mdc-dialog__title{border-bottom:0;margin-bottom:0}.mdc-dialog--fullscreen .mdc-dialog__close{top:5px}.mdc-dialog--fullscreen.mdc-dialog--scrollable .mdc-dialog__actions{border-top:1px solid rgba(0,0,0,0)}@media screen and (forced-colors: active){.mdc-dialog--fullscreen.mdc-dialog--scrollable .mdc-dialog__actions{border-top-color:CanvasText}}.mdc-dialog--fullscreen--titleless .mdc-dialog__close{margin-top:4px}.mdc-dialog--fullscreen--titleless.mdc-dialog--scrollable .mdc-dialog__close{margin-top:0}.mdc-dialog__content{flex-grow:1;box-sizing:border-box;margin:0;overflow:auto}.mdc-dialog__content>:first-child{margin-top:0}.mdc-dialog__content>:last-child{margin-bottom:0}.mdc-dialog__title+.mdc-dialog__content,.mdc-dialog__header+.mdc-dialog__content{padding-top:0}.mdc-dialog--scrollable .mdc-dialog__title+.mdc-dialog__content{padding-top:8px;padding-bottom:8px}.mdc-dialog__content .mdc-deprecated-list:first-child:last-child{padding:6px 0 0}.mdc-dialog--scrollable .mdc-dialog__content .mdc-deprecated-list:first-child:last-child{padding:0}.mdc-dialog__actions{display:flex;position:relative;flex-shrink:0;flex-wrap:wrap;align-items:center;justify-content:flex-end;box-sizing:border-box;min-height:52px;margin:0;padding:8px;border-top:1px solid rgba(0,0,0,0)}@media screen and (forced-colors: active){.mdc-dialog__actions{border-top-color:CanvasText}}.mdc-dialog--stacked .mdc-dialog__actions{flex-direction:column;align-items:flex-end}.mdc-dialog__button{margin-left:8px;margin-right:0;max-width:100%;text-align:right}[dir=rtl] .mdc-dialog__button,.mdc-dialog__button[dir=rtl]{margin-left:0;margin-right:8px}.mdc-dialog__button:first-child{margin-left:0;margin-right:0}[dir=rtl] .mdc-dialog__button:first-child,.mdc-dialog__button:first-child[dir=rtl]{margin-left:0;margin-right:0}[dir=rtl] .mdc-dialog__button,.mdc-dialog__button[dir=rtl]{text-align:left}.mdc-dialog--stacked .mdc-dialog__button:not(:first-child){margin-top:12px}.mdc-dialog--open,.mdc-dialog--opening,.mdc-dialog--closing{display:flex}.mdc-dialog--opening .mdc-dialog__scrim{transition:opacity 150ms linear}.mdc-dialog--opening .mdc-dialog__container{transition:opacity 75ms linear,transform 150ms 0ms cubic-bezier(0, 0, 0.2, 1)}.mdc-dialog--closing .mdc-dialog__scrim,.mdc-dialog--closing .mdc-dialog__container{transition:opacity 75ms linear}.mdc-dialog--closing .mdc-dialog__container{transform:none}.mdc-dialog--open .mdc-dialog__scrim{opacity:1}.mdc-dialog--open .mdc-dialog__container{transform:none;opacity:1}.mdc-dialog--open.mdc-dialog__surface-scrim--shown .mdc-dialog__surface-scrim{opacity:1}.mdc-dialog--open.mdc-dialog__surface-scrim--hiding .mdc-dialog__surface-scrim{transition:opacity 75ms linear}.mdc-dialog--open.mdc-dialog__surface-scrim--showing .mdc-dialog__surface-scrim{transition:opacity 150ms linear}.mdc-dialog__surface-scrim{display:none;opacity:0;position:absolute;width:100%;height:100%;z-index:1}.mdc-dialog__surface-scrim--shown .mdc-dialog__surface-scrim,.mdc-dialog__surface-scrim--showing .mdc-dialog__surface-scrim,.mdc-dialog__surface-scrim--hiding .mdc-dialog__surface-scrim{display:block}.mdc-dialog-scroll-lock{overflow:hidden}.mdc-dialog--no-content-padding .mdc-dialog__content{padding:0}.mdc-dialog--sheet .mdc-dialog__close{right:12px;top:9px;position:absolute;z-index:1}.mdc-dialog__scrim--removed{pointer-events:none}.mdc-dialog__scrim--removed .mdc-dialog__scrim,.mdc-dialog__scrim--removed .mdc-dialog__surface-scrim{display:none}.mat-mdc-dialog-content{max-height:65vh}.mat-mdc-dialog-container{position:static;display:block}.mat-mdc-dialog-container,.mat-mdc-dialog-container .mdc-dialog__container,.mat-mdc-dialog-container .mdc-dialog__surface{max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit}.mat-mdc-dialog-container .mdc-dialog__surface{display:block;width:100%;height:100%}.mat-mdc-dialog-container{outline:0}.mat-mdc-dialog-container .mdc-dialog__surface{background-color:var(--mdc-dialog-container-color, white)}.mat-mdc-dialog-container .mdc-dialog__surface{box-shadow:var(--mdc-dialog-container-elevation, 0px 11px 15px -7px rgba(0, 0, 0, 0.2), 0px 24px 38px 3px rgba(0, 0, 0, 0.14), 0px 9px 46px 8px rgba(0, 0, 0, 0.12))}.mat-mdc-dialog-container .mdc-dialog__surface{border-radius:var(--mdc-dialog-container-shape, var(--mdc-shape-medium, 4px))}.mat-mdc-dialog-container.mdc-dialog--scrollable .mdc-dialog__title,.mat-mdc-dialog-container.mdc-dialog--scrollable .mdc-dialog__actions,.mat-mdc-dialog-container.mdc-dialog--scrollable.mdc-dialog-scroll-divider-footer .mdc-dialog__actions{border-color:var(--mdc-dialog-with-divider-divider-color, black)}.mat-mdc-dialog-container.mdc-dialog--scrollable .mdc-dialog__title{border-bottom-color:var(--mdc-dialog-with-divider-divider-color, black)}.mat-mdc-dialog-container .mdc-dialog__title{font-family:var(--mdc-dialog-subhead-font, "Arial");line-height:var(--mdc-dialog-subhead-line-height, 14px);font-size:var(--mdc-dialog-subhead-size, 14px);font-weight:var(--mdc-dialog-subhead-weight, 500);letter-spacing:var(--mdc-dialog-subhead-tracking, 1px)}.mat-mdc-dialog-container .mdc-dialog__title{color:var(--mdc-dialog-subhead-color, black)}.mat-mdc-dialog-container .mdc-dialog__content{font-family:var(--mdc-dialog-supporting-text-font, "Arial");line-height:var(--mdc-dialog-supporting-text-line-height, 14px);font-size:var(--mdc-dialog-supporting-text-size, 14px);font-weight:var(--mdc-dialog-supporting-text-weight, 500);letter-spacing:var(--mdc-dialog-supporting-text-tracking, 1px)}.mat-mdc-dialog-container .mdc-dialog__content{color:var(--mdc-dialog-supporting-text-color, black)}.mat-mdc-dialog-container .mdc-dialog__container{transition-duration:var(--mat-dialog-transition-duration, 0ms)}.mat-mdc-dialog-container._mat-animation-noopable .mdc-dialog__container{transition:none}.mat-mdc-dialog-content{display:block}.mat-mdc-dialog-actions{justify-content:start}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-center,.mat-mdc-dialog-actions[align=center]{justify-content:center}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-end,.mat-mdc-dialog-actions[align=end]{justify-content:flex-end}.mat-mdc-dialog-actions .mat-button-base+.mat-button-base,.mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-mdc-dialog-actions .mat-button-base+.mat-button-base,[dir=rtl] .mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:0;margin-right:8px}'],encapsulation:2}),n})();class XN{constructor(e,t,i){this._ref=e,this._containerInstance=i,this._afterOpened=new cn,this._beforeClosed=new cn,this._state=0,this.disableClose=t.disableClose,this.id=e.id,i._animationStateChanged.pipe(Ui(r=>"opened"===r.state),Gr(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),i._animationStateChanged.pipe(Ui(r=>"closed"===r.state),Gr(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose()}),e.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose()}),fa(this.backdropClick(),this.keydownEvents().pipe(Ui(r=>27===r.keyCode&&!this.disableClose&&!ql(r)))).subscribe(r=>{this.disableClose||(r.preventDefault(),function JK(n,e,t){n._closeInteractionType=e,n.close(t)}(this,"keydown"===r.type?"keyboard":"mouse"))})}close(e){this._result=e,this._containerInstance._animationStateChanged.pipe(Ui(t=>"closing"===t.state),Gr(1)).subscribe(t=>{this._beforeClosed.next(e),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),t.totalTime+100)}),this._state=1,this._containerInstance._startExitAnimation()}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(e){let t=this._ref.config.positionStrategy;return e&&(e.left||e.right)?e.left?t.left(e.left):t.right(e.right):t.centerHorizontally(),e&&(e.top||e.bottom)?e.top?t.top(e.top):t.bottom(e.bottom):t.centerVertically(),this._ref.updatePosition(),this}updateSize(e="",t=""){return this._ref.updateSize(e,t),this}addPanelClass(e){return this._ref.addPanelClass(e),this}removePanelClass(e){return this._ref.removePanelClass(e),this}getState(){return this._state}_finishDialogClose(){this._state=2,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null}}const ZN=new Ze("MatMdcDialogData"),QK=new Ze("mat-mdc-dialog-default-options"),JN=new Ze("mat-mdc-dialog-scroll-strategy"),tY={provide:JN,deps:[hl],useFactory:function eY(n){return()=>n.scrollStrategies.block()}};let nY=0,iY=(()=>{class n{get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){const t=this._parentDialog;return t?t._getAfterAllClosed():this._afterAllClosedAtThisLevel}constructor(t,i,r,s,o,a,c,u,p,g){this._overlay=t,this._defaultOptions=r,this._parentDialog=s,this._dialogRefConstructor=c,this._dialogContainerType=u,this._dialogDataToken=p,this._openDialogsAtThisLevel=[],this._afterAllClosedAtThisLevel=new cn,this._afterOpenedAtThisLevel=new cn,this._idPrefix="mat-dialog-",this.dialogConfigClass=Xw,this.afterAllClosed=Yv(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(Bf(void 0))),this._scrollStrategy=a,this._dialog=i.get(eA)}open(t,i){let r;(i={...this._defaultOptions||new Xw,...i}).id=i.id||`${this._idPrefix}${nY++}`,i.scrollStrategy=i.scrollStrategy||this._scrollStrategy();const s=this._dialog.open(t,{...i,positionStrategy:this._overlay.position().global().centerHorizontally().centerVertically(),disableClose:!0,closeOnDestroy:!1,closeOnOverlayDetachments:!1,container:{type:this._dialogContainerType,providers:()=>[{provide:this.dialogConfigClass,useValue:i},{provide:Xv,useValue:i}]},templateContext:()=>({dialogRef:r}),providers:(o,a,c)=>(r=new this._dialogRefConstructor(o,i,c),r.updatePosition(i?.position),[{provide:this._dialogContainerType,useValue:c},{provide:this._dialogDataToken,useValue:a.data},{provide:this._dialogRefConstructor,useValue:r}])});return r.componentInstance=s.componentInstance,this.openDialogs.push(r),this.afterOpened.next(r),r.afterClosed().subscribe(()=>{const o=this.openDialogs.indexOf(r);o>-1&&(this.openDialogs.splice(o,1),this.openDialogs.length||this._getAfterAllClosed().next())}),r}closeAll(){this._closeDialogs(this.openDialogs)}getDialogById(t){return this.openDialogs.find(i=>i.id===t)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete()}_closeDialogs(t){let i=t.length;for(;i--;)t[i].close()}}return n.\u0275fac=function(t){Gl()},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),Zw=(()=>{class n extends iY{constructor(t,i,r,s,o,a,c,u){super(t,i,s,a,c,o,XN,ZK,ZN,u),this._idPrefix="mat-mdc-dialog-"}}return n.\u0275fac=function(t){return new(t||n)(xe(hl),xe(ts),xe(Mv,8),xe(QK,8),xe(JN),xe(n,12),xe(qw),xe(bo,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),rY=0,sY=(()=>{class n{constructor(t,i,r){this._dialogRef=t,this._elementRef=i,this._dialog=r,this.id="mat-mdc-dialog-title-"+rY++}ngOnInit(){this._dialogRef||(this._dialogRef=function aY(n,e){let t=n.nativeElement.parentElement;for(;t&&!t.classList.contains("mat-mdc-dialog-container");)t=t.parentElement;return t?e.find(i=>i.id===t.id):null}(this._elementRef,this._dialog.openDialogs)),this._dialogRef&&Promise.resolve().then(()=>{const t=this._dialogRef._containerInstance;t&&!t._ariaLabelledBy&&(t._ariaLabelledBy=this.id)})}}return n.\u0275fac=function(t){return new(t||n)(ie(XN,8),ie(_n),ie(Zw))},n.\u0275dir=ut({type:n,selectors:[["","mat-dialog-title",""],["","matDialogTitle",""]],hostAttrs:[1,"mat-mdc-dialog-title","mdc-dialog__title"],hostVars:1,hostBindings:function(t,i){2&t&&Af("id",i.id)},inputs:{id:"id"},exportAs:["matDialogTitle"]}),n})(),oY=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["","mat-dialog-content",""],["mat-dialog-content"],["","matDialogContent",""]],hostAttrs:[1,"mat-mdc-dialog-content","mdc-dialog__content"]}),n})(),cY=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[Zw,tY],imports:[UN,Kw,Kv,rr,rr]}),n})();function Pc(n,e){return new un(e?t=>e.schedule(lY,0,{error:n,subscriber:t}):t=>t.error(n))}function lY({error:n,subscriber:e}){e.error(n)}function da(n){return function(t){const i=new dY(n),r=t.lift(i);return i.caught=r}}class dY{constructor(e){this.selector=e}call(e,t){return t.subscribe(new uY(e,this.selector,this.caught))}}class uY extends Fs{constructor(e,t,i){super(e),this.selector=t,this.caught=i}error(e){if(!this.isStopped){let t;try{t=this.selector(e,this.caught)}catch(s){return void super.error(s)}this._unsubscribeAndRecycle();const i=new Pt(this,void 0,void 0);this.add(i);const r=$o(this,t,void 0,void 0,i);r!==i&&this.add(r)}}}function Jw(n){return e=>e.lift(new hY(n))}class hY{constructor(e){this.callback=e}call(e,t){return t.subscribe(new fY(e,this.callback))}}class fY extends di{constructor(e,t){super(e),this.add(new Tn(t))}}const pY=["*"];let Qw;function ey(n){return function mY(){if(void 0===Qw&&(Qw=null,typeof window<"u")){const n=window;void 0!==n.trustedTypes&&(Qw=n.trustedTypes.createPolicy("angular#components",{createHTML:e=>e}))}return Qw}()?.createHTML(n)||n}function e4(n){return Error(`Unable to find icon with the name "${n}"`)}function t4(n){return Error(`The URL provided to MatIconRegistry was not trusted as a resource URL via Angular's DomSanitizer. Attempted URL was "${n}".`)}function n4(n){return Error(`The literal provided to MatIconRegistry was not trusted as safe HTML by Angular's DomSanitizer. Attempted literal was "${n}".`)}class Uf{constructor(e,t,i){this.url=e,this.svgText=t,this.options=i}}let eS=(()=>{class n{constructor(t,i,r,s){this._httpClient=t,this._sanitizer=i,this._errorHandler=s,this._svgIconConfigs=new Map,this._iconSetConfigs=new Map,this._cachedIconsByUrl=new Map,this._inProgressUrlFetches=new Map,this._fontCssClassesByAlias=new Map,this._resolvers=[],this._defaultFontSetClass=["material-icons","mat-ligature-font"],this._document=r}addSvgIcon(t,i,r){return this.addSvgIconInNamespace("",t,i,r)}addSvgIconLiteral(t,i,r){return this.addSvgIconLiteralInNamespace("",t,i,r)}addSvgIconInNamespace(t,i,r,s){return this._addSvgIconConfig(t,i,new Uf(r,null,s))}addSvgIconResolver(t){return this._resolvers.push(t),this}addSvgIconLiteralInNamespace(t,i,r,s){const o=this._sanitizer.sanitize(Ri.HTML,r);if(!o)throw n4(r);const a=ey(o);return this._addSvgIconConfig(t,i,new Uf("",a,s))}addSvgIconSet(t,i){return this.addSvgIconSetInNamespace("",t,i)}addSvgIconSetLiteral(t,i){return this.addSvgIconSetLiteralInNamespace("",t,i)}addSvgIconSetInNamespace(t,i,r){return this._addSvgIconSetConfig(t,new Uf(i,null,r))}addSvgIconSetLiteralInNamespace(t,i,r){const s=this._sanitizer.sanitize(Ri.HTML,i);if(!s)throw n4(i);const o=ey(s);return this._addSvgIconSetConfig(t,new Uf("",o,r))}registerFontClassAlias(t,i=t){return this._fontCssClassesByAlias.set(t,i),this}classNameForFontAlias(t){return this._fontCssClassesByAlias.get(t)||t}setDefaultFontSetClass(...t){return this._defaultFontSetClass=t,this}getDefaultFontSetClass(){return this._defaultFontSetClass}getSvgIconFromUrl(t){const i=this._sanitizer.sanitize(Ri.RESOURCE_URL,t);if(!i)throw t4(t);const r=this._cachedIconsByUrl.get(i);return r?Tt(tS(r)):this._loadSvgIconFromConfig(new Uf(t,null)).pipe(Dr(s=>this._cachedIconsByUrl.set(i,s)),_t(s=>tS(s)))}getNamedSvgIcon(t,i=""){const r=i4(i,t);let s=this._svgIconConfigs.get(r);if(s)return this._getSvgFromConfig(s);if(s=this._getIconConfigFromResolvers(i,t),s)return this._svgIconConfigs.set(r,s),this._getSvgFromConfig(s);const o=this._iconSetConfigs.get(i);return o?this._getSvgFromIconSetConfigs(t,o):Pc(e4(r))}ngOnDestroy(){this._resolvers=[],this._svgIconConfigs.clear(),this._iconSetConfigs.clear(),this._cachedIconsByUrl.clear()}_getSvgFromConfig(t){return t.svgText?Tt(tS(this._svgElementFromConfig(t))):this._loadSvgIconFromConfig(t).pipe(_t(i=>tS(i)))}_getSvgFromIconSetConfigs(t,i){const r=this._extractIconWithNameFromAnySet(t,i);return r?Tt(r):ig(i.filter(o=>!o.svgText).map(o=>this._loadSvgIconSetFromConfig(o).pipe(da(a=>{const u=`Loading icon set URL: ${this._sanitizer.sanitize(Ri.RESOURCE_URL,o.url)} failed: ${a.message}`;return this._errorHandler.handleError(new Error(u)),Tt(null)})))).pipe(_t(()=>{const o=this._extractIconWithNameFromAnySet(t,i);if(!o)throw e4(t);return o}))}_extractIconWithNameFromAnySet(t,i){for(let r=i.length-1;r>=0;r--){const s=i[r];if(s.svgText&&s.svgText.toString().indexOf(t)>-1){const o=this._svgElementFromConfig(s),a=this._extractSvgIconFromSet(o,t,s.options);if(a)return a}}return null}_loadSvgIconFromConfig(t){return this._fetchIcon(t).pipe(Dr(i=>t.svgText=i),_t(()=>this._svgElementFromConfig(t)))}_loadSvgIconSetFromConfig(t){return t.svgText?Tt(null):this._fetchIcon(t).pipe(Dr(i=>t.svgText=i))}_extractSvgIconFromSet(t,i,r){const s=t.querySelector(`[id="${i}"]`);if(!s)return null;const o=s.cloneNode(!0);if(o.removeAttribute("id"),"svg"===o.nodeName.toLowerCase())return this._setSvgAttributes(o,r);if("symbol"===o.nodeName.toLowerCase())return this._setSvgAttributes(this._toSvgElement(o),r);const a=this._svgElementFromString(ey(""));return a.appendChild(o),this._setSvgAttributes(a,r)}_svgElementFromString(t){const i=this._document.createElement("DIV");i.innerHTML=t;const r=i.querySelector("svg");if(!r)throw Error(" tag not found");return r}_toSvgElement(t){const i=this._svgElementFromString(ey("")),r=t.attributes;for(let s=0;sey(u)),Jw(()=>this._inProgressUrlFetches.delete(o)),Dp());return this._inProgressUrlFetches.set(o,c),c}_addSvgIconConfig(t,i,r){return this._svgIconConfigs.set(i4(t,i),r),this}_addSvgIconSetConfig(t,i){const r=this._iconSetConfigs.get(t);return r?r.push(i):this._iconSetConfigs.set(t,[i]),this}_svgElementFromConfig(t){if(!t.svgElement){const i=this._svgElementFromString(t.svgText);this._setSvgAttributes(i,t.options),t.svgElement=i}return t.svgElement}_getIconConfigFromResolvers(t,i){for(let r=0;re?e.pathname+e.search:""}}}),r4=["clip-path","color-profile","src","cursor","fill","filter","marker","marker-start","marker-mid","marker-end","mask","stroke"],SY=r4.map(n=>`[${n}]`).join(", "),EY=/^url\(['"]?#(.*?)['"]?\)$/;let nS=(()=>{class n extends yY{get inline(){return this._inline}set inline(t){this._inline=bi(t)}get svgIcon(){return this._svgIcon}set svgIcon(t){t!==this._svgIcon&&(t?this._updateSvgIcon(t):this._svgIcon&&this._clearSvgElement(),this._svgIcon=t)}get fontSet(){return this._fontSet}set fontSet(t){const i=this._cleanupFontValue(t);i!==this._fontSet&&(this._fontSet=i,this._updateFontIconClasses())}get fontIcon(){return this._fontIcon}set fontIcon(t){const i=this._cleanupFontValue(t);i!==this._fontIcon&&(this._fontIcon=i,this._updateFontIconClasses())}constructor(t,i,r,s,o,a){super(t),this._iconRegistry=i,this._location=s,this._errorHandler=o,this._inline=!1,this._previousFontSetClass=[],this._currentIconFetch=Tn.EMPTY,a&&(a.color&&(this.color=this.defaultColor=a.color),a.fontSet&&(this.fontSet=a.fontSet)),r||t.nativeElement.setAttribute("aria-hidden","true")}_splitIconName(t){if(!t)return["",""];const i=t.split(":");switch(i.length){case 1:return["",i[0]];case 2:return i;default:throw Error(`Invalid icon name: "${t}"`)}}ngOnInit(){this._updateFontIconClasses()}ngAfterViewChecked(){const t=this._elementsWithExternalReferences;if(t&&t.size){const i=this._location.getPathname();i!==this._previousPath&&(this._previousPath=i,this._prependPathToReferences(i))}}ngOnDestroy(){this._currentIconFetch.unsubscribe(),this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear()}_usingFontIcon(){return!this.svgIcon}_setSvgElement(t){this._clearSvgElement();const i=this._location.getPathname();this._previousPath=i,this._cacheChildrenWithExternalReferences(t),this._prependPathToReferences(i),this._elementRef.nativeElement.appendChild(t)}_clearSvgElement(){const t=this._elementRef.nativeElement;let i=t.childNodes.length;for(this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear();i--;){const r=t.childNodes[i];(1!==r.nodeType||"svg"===r.nodeName.toLowerCase())&&r.remove()}}_updateFontIconClasses(){if(!this._usingFontIcon())return;const t=this._elementRef.nativeElement,i=(this.fontSet?this._iconRegistry.classNameForFontAlias(this.fontSet).split(/ +/):this._iconRegistry.getDefaultFontSetClass()).filter(r=>r.length>0);this._previousFontSetClass.forEach(r=>t.classList.remove(r)),i.forEach(r=>t.classList.add(r)),this._previousFontSetClass=i,this.fontIcon!==this._previousFontIconClass&&!i.includes("mat-ligature-font")&&(this._previousFontIconClass&&t.classList.remove(this._previousFontIconClass),this.fontIcon&&t.classList.add(this.fontIcon),this._previousFontIconClass=this.fontIcon)}_cleanupFontValue(t){return"string"==typeof t?t.trim().split(" ")[0]:t}_prependPathToReferences(t){const i=this._elementsWithExternalReferences;i&&i.forEach((r,s)=>{r.forEach(o=>{s.setAttribute(o.name,`url('${t}#${o.value}')`)})})}_cacheChildrenWithExternalReferences(t){const i=t.querySelectorAll(SY),r=this._elementsWithExternalReferences=this._elementsWithExternalReferences||new Map;for(let s=0;s{const a=i[s],c=a.getAttribute(o),u=c?c.match(EY):null;if(u){let p=r.get(a);p||(p=[],r.set(a,p)),p.push({name:o,value:u[1]})}})}_updateSvgIcon(t){if(this._svgNamespace=null,this._svgName=null,this._currentIconFetch.unsubscribe(),t){const[i,r]=this._splitIconName(t);i&&(this._svgNamespace=i),r&&(this._svgName=r),this._currentIconFetch=this._iconRegistry.getNamedSvgIcon(r,i).pipe(Gr(1)).subscribe(s=>this._setSvgElement(s),s=>{this._errorHandler.handleError(new Error(`Error retrieving icon ${i}:${r}! ${s.message}`))})}}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(eS),Kc("aria-hidden"),ie(xY),ie(tl),ie(bY,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-icon"]],hostAttrs:["role","img",1,"mat-icon","notranslate"],hostVars:8,hostBindings:function(t,i){2&t&&(Di("data-mat-icon-type",i._usingFontIcon()?"font":"svg")("data-mat-icon-name",i._svgName||i.fontIcon)("data-mat-icon-namespace",i._svgNamespace||i.fontSet)("fontIcon",i._usingFontIcon()?i.fontIcon:null),hi("mat-icon-inline",i.inline)("mat-icon-no-color","primary"!==i.color&&"accent"!==i.color&&"warn"!==i.color))},inputs:{color:"color",inline:"inline",svgIcon:"svgIcon",fontSet:"fontSet",fontIcon:"fontIcon"},exportAs:["matIcon"],features:[Z],ngContentSelectors:pY,decls:1,vars:0,template:function(t,i){1&t&&(Hs(),En(0))},styles:[".mat-icon{-webkit-user-select:none;user-select:none;background-repeat:no-repeat;display:inline-block;fill:currentColor;height:24px;width:24px;overflow:hidden}.mat-icon.mat-icon-inline{font-size:inherit;height:inherit;line-height:inherit;width:inherit}.mat-icon.mat-ligature-font[fontIcon]::before{content:attr(fontIcon)}[dir=rtl] .mat-icon-rtl-mirror{transform:scale(-1, 1)}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon{display:block}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mat-icon{margin:auto}"],encapsulation:2,changeDetection:0}),n})(),s4=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,rr]}),n})();const MY=["matFormFieldNotchedOutline",""],CY=["*"],DY=["textField"],TY=["iconPrefixContainer"],AY=["textPrefixContainer"];function kY(n,e){1&n&&qt(0,"span",19)}function IY(n,e){if(1&n){const t=Df();ke(0,"label",17),Gn("cdkObserveContent",function(){return R(t),V(Jt(2)._refreshOutlineNotchWidth())}),En(1,1),mt(2,kY,1,0,"span",18),Ne()}if(2&n){const t=Jt(2);$e("floating",t._shouldLabelFloat())("cdkObserveContentDisabled",!t._hasOutline())("id",t._labelId),Di("for",t._control.id)("aria-owns",t._control.id),Le(2),$e("ngIf",!t.hideRequiredMarker&&t._control.required)}}function FY(n,e){1&n&&mt(0,IY,3,6,"label",16),2&n&&$e("ngIf",Jt()._hasFloatingLabel())}function RY(n,e){1&n&&qt(0,"div",20)}function PY(n,e){}function OY(n,e){1&n&&mt(0,PY,0,0,"ng-template",22),2&n&&(Jt(2),$e("ngTemplateOutlet",Tc(1)))}function LY(n,e){if(1&n&&(ke(0,"div",21),mt(1,OY,1,1,"ng-template",9),Ne()),2&n){const t=Jt();$e("matFormFieldNotchedOutlineOpen",t._shouldLabelFloat())("matFormFieldNotchedOutlineLabelWidth",t._labelWidth),Le(1),$e("ngIf",!t._forceDisplayInfixLabel())}}function NY(n,e){1&n&&(ke(0,"div",23,24),En(2,2),Ne())}function BY(n,e){1&n&&(ke(0,"div",25,26),En(2,3),Ne())}function VY(n,e){}function HY(n,e){1&n&&mt(0,VY,0,0,"ng-template",22),2&n&&(Jt(),$e("ngTemplateOutlet",Tc(1)))}function UY(n,e){1&n&&(ke(0,"div",27),En(1,4),Ne())}function zY(n,e){1&n&&(ke(0,"div",28),En(1,5),Ne())}function GY(n,e){1&n&&qt(0,"div",29)}function jY(n,e){1&n&&(ke(0,"div",30),En(1,6),Ne()),2&n&&$e("@transitionMessages",Jt()._subscriptAnimationState)}function WY(n,e){if(1&n&&(ke(0,"mat-hint",34),it(1),Ne()),2&n){const t=Jt(2);$e("id",t._hintLabelId),Le(1),Hi(t.hintLabel)}}function $Y(n,e){if(1&n&&(ke(0,"div",31),mt(1,WY,2,2,"mat-hint",32),En(2,7),qt(3,"div",33),En(4,8),Ne()),2&n){const t=Jt();$e("@transitionMessages",t._subscriptAnimationState),Le(1),$e("ngIf",t.hintLabel)}}const qY=["*",[["mat-label"]],[["","matPrefix",""],["","matIconPrefix",""]],[["","matTextPrefix",""]],[["","matTextSuffix",""]],[["","matSuffix",""],["","matIconSuffix",""]],[["mat-error"],["","matError",""]],[["mat-hint",3,"align","end"]],[["mat-hint","align","end"]]],KY=["*","mat-label","[matPrefix], [matIconPrefix]","[matTextPrefix]","[matTextSuffix]","[matSuffix], [matIconSuffix]","mat-error, [matError]","mat-hint:not([align='end'])","mat-hint[align='end']"];let o4=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["mat-label"]]}),n})();const YY=new Ze("MatError");let XY=0,a4=(()=>{class n{constructor(){this.align="start",this.id="mat-mdc-hint-"+XY++}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["mat-hint"]],hostAttrs:[1,"mat-mdc-form-field-hint","mat-mdc-form-field-bottom-align"],hostVars:4,hostBindings:function(t,i){2&t&&(Af("id",i.id),Di("align",null),hi("mat-mdc-form-field-hint-end","end"===i.align))},inputs:{align:"align",id:"id"}}),n})();const ZY=new Ze("MatPrefix"),JY=new Ze("MatSuffix");let c4=(()=>{class n{constructor(t){this._elementRef=t,this.floating=!1}getWidth(){return function QY(n){if(null!==n.offsetParent)return n.scrollWidth;const t=n.cloneNode(!0);t.style.setProperty("position","absolute"),t.style.setProperty("transform","translate(-9999px, -9999px)"),document.documentElement.appendChild(t);const i=t.scrollWidth;return t.remove(),i}(this._elementRef.nativeElement)}get element(){return this._elementRef.nativeElement}}return n.\u0275fac=function(t){return new(t||n)(ie(_n))},n.\u0275dir=ut({type:n,selectors:[["label","matFormFieldFloatingLabel",""]],hostAttrs:[1,"mdc-floating-label","mat-mdc-floating-label"],hostVars:2,hostBindings:function(t,i){2&t&&hi("mdc-floating-label--float-above",i.floating)},inputs:{floating:"floating"}}),n})();const l4="mdc-line-ripple--active",iS="mdc-line-ripple--deactivating";let d4=(()=>{class n{constructor(t,i){this._elementRef=t,this._handleTransitionEnd=r=>{const s=this._elementRef.nativeElement.classList,o=s.contains(iS);"opacity"===r.propertyName&&o&&s.remove(l4,iS)},i.runOutsideAngular(()=>{t.nativeElement.addEventListener("transitionend",this._handleTransitionEnd)})}activate(){const t=this._elementRef.nativeElement.classList;t.remove(iS),t.add(l4)}deactivate(){this._elementRef.nativeElement.classList.add(iS)}ngOnDestroy(){this._elementRef.nativeElement.removeEventListener("transitionend",this._handleTransitionEnd)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Xt))},n.\u0275dir=ut({type:n,selectors:[["div","matFormFieldLineRipple",""]],hostAttrs:[1,"mdc-line-ripple"]}),n})(),u4=(()=>{class n{constructor(t,i){this._elementRef=t,this._ngZone=i,this.labelWidth=0,this.open=!1}ngAfterViewInit(){const t=this._elementRef.nativeElement.querySelector(".mdc-floating-label");t?(this._elementRef.nativeElement.classList.add("mdc-notched-outline--upgraded"),"function"==typeof requestAnimationFrame&&(t.style.transitionDuration="0s",this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>t.style.transitionDuration="")}))):this._elementRef.nativeElement.classList.add("mdc-notched-outline--no-label")}_getNotchWidth(){return this.open?this.labelWidth>0?`calc(${this.labelWidth}px * var(--mat-mdc-form-field-floating-label-scale, 0.75) + 9px)`:"0px":null}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Xt))},n.\u0275cmp=Ln({type:n,selectors:[["div","matFormFieldNotchedOutline",""]],hostAttrs:[1,"mdc-notched-outline"],hostVars:2,hostBindings:function(t,i){2&t&&hi("mdc-notched-outline--notched",i.open)},inputs:{labelWidth:["matFormFieldNotchedOutlineLabelWidth","labelWidth"],open:["matFormFieldNotchedOutlineOpen","open"]},attrs:MY,ngContentSelectors:CY,decls:4,vars:2,consts:[[1,"mdc-notched-outline__leading"],[1,"mdc-notched-outline__notch"],[1,"mdc-notched-outline__trailing"]],template:function(t,i){1&t&&(Hs(),qt(0,"div",0),ke(1,"div",1),En(2),Ne(),qt(3,"div",2)),2&t&&(Le(1),dv("width",i._getNotchWidth()))},encapsulation:2,changeDetection:0}),n})();const eX={transitionMessages:fg("transitionMessages",[sh("enter",la({opacity:1,transform:"translateY(0%)"})),Xl("void => enter",[la({opacity:0,transform:"translateY(-5px)"}),zd("300ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])};let h4=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n}),n})();const f4=new Ze("MatFormField"),tX=new Ze("MAT_FORM_FIELD_DEFAULT_OPTIONS");let p4=0,_4=(()=>{class n{get hideRequiredMarker(){return this._hideRequiredMarker}set hideRequiredMarker(t){this._hideRequiredMarker=bi(t)}get floatLabel(){return this._floatLabel||this._defaults?.floatLabel||"auto"}set floatLabel(t){t!==this._floatLabel&&(this._floatLabel=t,this._changeDetectorRef.markForCheck())}get appearance(){return this._appearance}set appearance(t){const i=this._appearance;this._appearance=t||this._defaults?.appearance||"fill","outline"===this._appearance&&this._appearance!==i&&(this._refreshOutlineNotchWidth(),this._needsOutlineLabelOffsetUpdateOnStable=!0)}get subscriptSizing(){return this._subscriptSizing||this._defaults?.subscriptSizing||"fixed"}set subscriptSizing(t){this._subscriptSizing=t||this._defaults?.subscriptSizing||"fixed"}get hintLabel(){return this._hintLabel}set hintLabel(t){this._hintLabel=t,this._processHints()}get _control(){return this._explicitFormFieldControl||this._formFieldControl}set _control(t){this._explicitFormFieldControl=t}constructor(t,i,r,s,o,a,c,u){this._elementRef=t,this._changeDetectorRef=i,this._ngZone=r,this._dir=s,this._platform=o,this._defaults=a,this._animationMode=c,this._document=u,this._hideRequiredMarker=!1,this.color="primary",this._appearance="fill",this._subscriptSizing=null,this._hintLabel="",this._hasIconPrefix=!1,this._hasTextPrefix=!1,this._hasIconSuffix=!1,this._hasTextSuffix=!1,this._labelId="mat-mdc-form-field-label-"+p4++,this._hintLabelId="mat-mdc-hint-"+p4++,this._subscriptAnimationState="",this._labelWidth=0,this._destroyed=new cn,this._isFocused=null,this._needsOutlineLabelOffsetUpdateOnStable=!1,a&&(a.appearance&&(this.appearance=a.appearance),this._hideRequiredMarker=Boolean(a?.hideRequiredMarker),a.color&&(this.color=a.color))}ngAfterViewInit(){this._updateFocusState(),this._refreshOutlineNotchWidth(),this._document?.fonts?.ready?this._document.fonts.ready.then(()=>{this._refreshOutlineNotchWidth(),this._changeDetectorRef.markForCheck()}):setTimeout(()=>this._refreshOutlineNotchWidth(),100),this._subscriptAnimationState="enter",this._changeDetectorRef.detectChanges()}ngAfterContentInit(){this._assertFormFieldControl(),this._initializeControl(),this._initializeSubscript(),this._initializePrefixAndSuffix(),this._initializeOutlineLabelOffsetSubscriptions()}ngAfterContentChecked(){this._assertFormFieldControl()}ngOnDestroy(){this._destroyed.next(),this._destroyed.complete()}getLabelId(){return this._hasFloatingLabel()?this._labelId:null}getConnectedOverlayOrigin(){return this._textField||this._elementRef}_animateAndLockLabel(){this._hasFloatingLabel()&&(this.floatLabel="always")}_initializeControl(){const t=this._control;t.controlType&&this._elementRef.nativeElement.classList.add(`mat-mdc-form-field-type-${t.controlType}`),t.stateChanges.subscribe(()=>{this._updateFocusState(),this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),t.ngControl&&t.ngControl.valueChanges&&t.ngControl.valueChanges.pipe(Tr(this._destroyed)).subscribe(()=>this._changeDetectorRef.markForCheck())}_checkPrefixAndSuffixTypes(){this._hasIconPrefix=!!this._prefixChildren.find(t=>!t._isText),this._hasTextPrefix=!!this._prefixChildren.find(t=>t._isText),this._hasIconSuffix=!!this._suffixChildren.find(t=>!t._isText),this._hasTextSuffix=!!this._suffixChildren.find(t=>t._isText)}_initializePrefixAndSuffix(){this._checkPrefixAndSuffixTypes(),fa(this._prefixChildren.changes,this._suffixChildren.changes).subscribe(()=>{this._checkPrefixAndSuffixTypes(),this._changeDetectorRef.markForCheck()})}_initializeSubscript(){this._hintChildren.changes.subscribe(()=>{this._processHints(),this._changeDetectorRef.markForCheck()}),this._errorChildren.changes.subscribe(()=>{this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),this._validateHints(),this._syncDescribedByIds()}_assertFormFieldControl(){}_updateFocusState(){this._control.focused&&!this._isFocused?(this._isFocused=!0,this._lineRipple?.activate()):!this._control.focused&&(this._isFocused||null===this._isFocused)&&(this._isFocused=!1,this._lineRipple?.deactivate()),this._textField?.nativeElement.classList.toggle("mdc-text-field--focused",this._control.focused)}_initializeOutlineLabelOffsetSubscriptions(){this._prefixChildren.changes.subscribe(()=>this._needsOutlineLabelOffsetUpdateOnStable=!0),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.pipe(Tr(this._destroyed)).subscribe(()=>{this._needsOutlineLabelOffsetUpdateOnStable&&(this._needsOutlineLabelOffsetUpdateOnStable=!1,this._updateOutlineLabelOffset())})}),this._dir.change.pipe(Tr(this._destroyed)).subscribe(()=>this._needsOutlineLabelOffsetUpdateOnStable=!0)}_shouldAlwaysFloat(){return"always"===this.floatLabel}_hasOutline(){return"outline"===this.appearance}_forceDisplayInfixLabel(){return!this._platform.isBrowser&&this._prefixChildren.length&&!this._shouldLabelFloat()}_hasFloatingLabel(){return!!this._labelChildNonStatic||!!this._labelChildStatic}_shouldLabelFloat(){return this._control.shouldLabelFloat||this._shouldAlwaysFloat()}_shouldForward(t){const i=this._control?this._control.ngControl:null;return i&&i[t]}_getDisplayedMessages(){return this._errorChildren&&this._errorChildren.length>0&&this._control.errorState?"error":"hint"}_refreshOutlineNotchWidth(){!this._hasOutline()||!this._floatingLabel||(this._labelWidth=this._floatingLabel.getWidth())}_processHints(){this._validateHints(),this._syncDescribedByIds()}_validateHints(){}_syncDescribedByIds(){if(this._control){let t=[];if(this._control.userAriaDescribedBy&&"string"==typeof this._control.userAriaDescribedBy&&t.push(...this._control.userAriaDescribedBy.split(" ")),"hint"===this._getDisplayedMessages()){const i=this._hintChildren?this._hintChildren.find(s=>"start"===s.align):null,r=this._hintChildren?this._hintChildren.find(s=>"end"===s.align):null;i?t.push(i.id):this._hintLabel&&t.push(this._hintLabelId),r&&t.push(r.id)}else this._errorChildren&&t.push(...this._errorChildren.map(i=>i.id));this._control.setDescribedByIds(t)}}_updateOutlineLabelOffset(){if(!this._platform.isBrowser||!this._hasOutline()||!this._floatingLabel)return;const t=this._floatingLabel.element;if(!this._iconPrefixContainer&&!this._textPrefixContainer)return void(t.style.transform="");if(!this._isAttachedToDom())return void(this._needsOutlineLabelOffsetUpdateOnStable=!0);const i=this._iconPrefixContainer?.nativeElement,r=this._textPrefixContainer?.nativeElement,s=i?.getBoundingClientRect().width??0,o=r?.getBoundingClientRect().width??0;t.style.transform=`var(\n --mat-mdc-form-field-label-transform,\n translateY(-50%) translateX(calc(${"rtl"===this._dir.value?"-1":"1"} * (${s+o}px + var(--mat-mdc-form-field-label-offset-x, 0px))))\n )`}_isAttachedToDom(){const t=this._elementRef.nativeElement;if(t.getRootNode){const i=t.getRootNode();return i&&i!==t}return document.documentElement.contains(t)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(aa),ie(Xt),ie(Yl),ie(as),ie(tX,8),ie(bo,8),ie(Mn))},n.\u0275cmp=Ln({type:n,selectors:[["mat-form-field"]],contentQueries:function(t,i,r){if(1&t&&(is(r,o4,5),is(r,o4,7),is(r,h4,5),is(r,ZY,5),is(r,JY,5),is(r,YY,5),is(r,a4,5)),2&t){let s;Yn(s=Xn())&&(i._labelChildNonStatic=s.first),Yn(s=Xn())&&(i._labelChildStatic=s.first),Yn(s=Xn())&&(i._formFieldControl=s.first),Yn(s=Xn())&&(i._prefixChildren=s),Yn(s=Xn())&&(i._suffixChildren=s),Yn(s=Xn())&&(i._errorChildren=s),Yn(s=Xn())&&(i._hintChildren=s)}},viewQuery:function(t,i){if(1&t&&(zr(DY,5),zr(TY,5),zr(AY,5),zr(c4,5),zr(u4,5),zr(d4,5)),2&t){let r;Yn(r=Xn())&&(i._textField=r.first),Yn(r=Xn())&&(i._iconPrefixContainer=r.first),Yn(r=Xn())&&(i._textPrefixContainer=r.first),Yn(r=Xn())&&(i._floatingLabel=r.first),Yn(r=Xn())&&(i._notchedOutline=r.first),Yn(r=Xn())&&(i._lineRipple=r.first)}},hostAttrs:[1,"mat-mdc-form-field"],hostVars:42,hostBindings:function(t,i){2&t&&hi("mat-mdc-form-field-label-always-float",i._shouldAlwaysFloat())("mat-mdc-form-field-has-icon-prefix",i._hasIconPrefix)("mat-mdc-form-field-has-icon-suffix",i._hasIconSuffix)("mat-form-field-invalid",i._control.errorState)("mat-form-field-disabled",i._control.disabled)("mat-form-field-autofilled",i._control.autofilled)("mat-form-field-no-animations","NoopAnimations"===i._animationMode)("mat-form-field-appearance-fill","fill"==i.appearance)("mat-form-field-appearance-outline","outline"==i.appearance)("mat-form-field-hide-placeholder",i._hasFloatingLabel()&&!i._shouldLabelFloat())("mat-focused",i._control.focused)("mat-primary","accent"!==i.color&&"warn"!==i.color)("mat-accent","accent"===i.color)("mat-warn","warn"===i.color)("ng-untouched",i._shouldForward("untouched"))("ng-touched",i._shouldForward("touched"))("ng-pristine",i._shouldForward("pristine"))("ng-dirty",i._shouldForward("dirty"))("ng-valid",i._shouldForward("valid"))("ng-invalid",i._shouldForward("invalid"))("ng-pending",i._shouldForward("pending"))},inputs:{hideRequiredMarker:"hideRequiredMarker",color:"color",floatLabel:"floatLabel",appearance:"appearance",subscriptSizing:"subscriptSizing",hintLabel:"hintLabel"},exportAs:["matFormField"],features:[Oi([{provide:f4,useExisting:n}])],ngContentSelectors:KY,decls:18,vars:23,consts:[["labelTemplate",""],[1,"mat-mdc-text-field-wrapper","mdc-text-field",3,"click"],["textField",""],["class","mat-mdc-form-field-focus-overlay",4,"ngIf"],[1,"mat-mdc-form-field-flex"],["matFormFieldNotchedOutline","",3,"matFormFieldNotchedOutlineOpen","matFormFieldNotchedOutlineLabelWidth",4,"ngIf"],["class","mat-mdc-form-field-icon-prefix",4,"ngIf"],["class","mat-mdc-form-field-text-prefix",4,"ngIf"],[1,"mat-mdc-form-field-infix"],[3,"ngIf"],["class","mat-mdc-form-field-text-suffix",4,"ngIf"],["class","mat-mdc-form-field-icon-suffix",4,"ngIf"],["matFormFieldLineRipple","",4,"ngIf"],[1,"mat-mdc-form-field-subscript-wrapper","mat-mdc-form-field-bottom-align",3,"ngSwitch"],["class","mat-mdc-form-field-error-wrapper",4,"ngSwitchCase"],["class","mat-mdc-form-field-hint-wrapper",4,"ngSwitchCase"],["matFormFieldFloatingLabel","",3,"floating","cdkObserveContentDisabled","id","cdkObserveContent",4,"ngIf"],["matFormFieldFloatingLabel","",3,"floating","cdkObserveContentDisabled","id","cdkObserveContent"],["aria-hidden","true","class","mat-mdc-form-field-required-marker mdc-floating-label--required",4,"ngIf"],["aria-hidden","true",1,"mat-mdc-form-field-required-marker","mdc-floating-label--required"],[1,"mat-mdc-form-field-focus-overlay"],["matFormFieldNotchedOutline","",3,"matFormFieldNotchedOutlineOpen","matFormFieldNotchedOutlineLabelWidth"],[3,"ngTemplateOutlet"],[1,"mat-mdc-form-field-icon-prefix"],["iconPrefixContainer",""],[1,"mat-mdc-form-field-text-prefix"],["textPrefixContainer",""],[1,"mat-mdc-form-field-text-suffix"],[1,"mat-mdc-form-field-icon-suffix"],["matFormFieldLineRipple",""],[1,"mat-mdc-form-field-error-wrapper"],[1,"mat-mdc-form-field-hint-wrapper"],[3,"id",4,"ngIf"],[1,"mat-mdc-form-field-hint-spacer"],[3,"id"]],template:function(t,i){1&t&&(Hs(qY),mt(0,FY,1,1,"ng-template",null,0,wv),ke(2,"div",1,2),Gn("click",function(s){return i._control.onContainerClick&&i._control.onContainerClick(s)}),mt(4,RY,1,0,"div",3),ke(5,"div",4),mt(6,LY,2,3,"div",5),mt(7,NY,3,0,"div",6),mt(8,BY,3,0,"div",7),ke(9,"div",8),mt(10,HY,1,1,"ng-template",9),En(11),Ne(),mt(12,UY,2,0,"div",10),mt(13,zY,2,0,"div",11),Ne(),mt(14,GY,1,0,"div",12),Ne(),ke(15,"div",13),mt(16,jY,2,1,"div",14),mt(17,$Y,5,2,"div",15),Ne()),2&t&&(Le(2),hi("mdc-text-field--filled",!i._hasOutline())("mdc-text-field--outlined",i._hasOutline())("mdc-text-field--no-label",!i._hasFloatingLabel())("mdc-text-field--disabled",i._control.disabled)("mdc-text-field--invalid",i._control.errorState),Le(2),$e("ngIf",!i._hasOutline()&&!i._control.disabled),Le(2),$e("ngIf",i._hasOutline()),Le(1),$e("ngIf",i._hasIconPrefix),Le(1),$e("ngIf",i._hasTextPrefix),Le(2),$e("ngIf",!i._hasOutline()||i._forceDisplayInfixLabel()),Le(2),$e("ngIf",i._hasTextSuffix),Le(1),$e("ngIf",i._hasIconSuffix),Le(1),$e("ngIf",!i._hasOutline()),Le(1),hi("mat-mdc-form-field-subscript-dynamic-size","dynamic"===i.subscriptSizing),$e("ngSwitch",i._getDisplayedMessages()),Le(1),$e("ngSwitchCase","error"),Le(1),$e("ngSwitchCase","hint"))},dependencies:[Yu,BD,Tv,ND,IT,a4,c4,u4,d4],styles:['.mdc-text-field{border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:0;border-bottom-left-radius:0;display:inline-flex;align-items:baseline;padding:0 16px;position:relative;box-sizing:border-box;overflow:hidden;will-change:opacity,transform,color}.mdc-text-field .mdc-floating-label{top:50%;transform:translateY(-50%);pointer-events:none}.mdc-text-field__input{height:28px;width:100%;min-width:0;border:none;border-radius:0;background:none;appearance:none;padding:0}.mdc-text-field__input::-ms-clear{display:none}.mdc-text-field__input::-webkit-calendar-picker-indicator{display:none}.mdc-text-field__input:focus{outline:none}.mdc-text-field__input:invalid{box-shadow:none}@media all{.mdc-text-field__input::placeholder{opacity:0}}@media all{.mdc-text-field__input:-ms-input-placeholder{opacity:0}}@media all{.mdc-text-field--no-label .mdc-text-field__input::placeholder,.mdc-text-field--focused .mdc-text-field__input::placeholder{opacity:1}}@media all{.mdc-text-field--no-label .mdc-text-field__input:-ms-input-placeholder,.mdc-text-field--focused .mdc-text-field__input:-ms-input-placeholder{opacity:1}}.mdc-text-field__affix{height:28px;opacity:0;white-space:nowrap}.mdc-text-field--label-floating .mdc-text-field__affix,.mdc-text-field--no-label .mdc-text-field__affix{opacity:1}@supports(-webkit-hyphens: none){.mdc-text-field--outlined .mdc-text-field__affix{align-items:center;align-self:center;display:inline-flex;height:100%}}.mdc-text-field__affix--prefix{padding-left:0;padding-right:2px}[dir=rtl] .mdc-text-field__affix--prefix,.mdc-text-field__affix--prefix[dir=rtl]{padding-left:2px;padding-right:0}.mdc-text-field--end-aligned .mdc-text-field__affix--prefix{padding-left:0;padding-right:12px}[dir=rtl] .mdc-text-field--end-aligned .mdc-text-field__affix--prefix,.mdc-text-field--end-aligned .mdc-text-field__affix--prefix[dir=rtl]{padding-left:12px;padding-right:0}.mdc-text-field__affix--suffix{padding-left:12px;padding-right:0}[dir=rtl] .mdc-text-field__affix--suffix,.mdc-text-field__affix--suffix[dir=rtl]{padding-left:0;padding-right:12px}.mdc-text-field--end-aligned .mdc-text-field__affix--suffix{padding-left:2px;padding-right:0}[dir=rtl] .mdc-text-field--end-aligned .mdc-text-field__affix--suffix,.mdc-text-field--end-aligned .mdc-text-field__affix--suffix[dir=rtl]{padding-left:0;padding-right:2px}.mdc-text-field--filled{height:56px}.mdc-text-field--filled::before{display:inline-block;width:0;height:40px;content:"";vertical-align:0}.mdc-text-field--filled .mdc-floating-label{left:16px;right:initial}[dir=rtl] .mdc-text-field--filled .mdc-floating-label,.mdc-text-field--filled .mdc-floating-label[dir=rtl]{left:initial;right:16px}.mdc-text-field--filled .mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__input{height:100%}.mdc-text-field--filled.mdc-text-field--no-label .mdc-floating-label{display:none}.mdc-text-field--filled.mdc-text-field--no-label::before{display:none}@supports(-webkit-hyphens: none){.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__affix{align-items:center;align-self:center;display:inline-flex;height:100%}}.mdc-text-field--outlined{height:56px;overflow:visible}.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-37.25px) scale(1)}.mdc-text-field--outlined .mdc-floating-label--float-above{font-size:.75rem}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) scale(0.75)}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-text-field--outlined .mdc-text-field__input{height:100%}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading{border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:var(--mdc-shape-small, 4px)}[dir=rtl] .mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading,.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading[dir=rtl]{border-top-left-radius:0;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:var(--mdc-shape-small, 4px);border-bottom-left-radius:0}@supports(top: max(0%)){.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading{width:max(12px, var(--mdc-shape-small, 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__notch{max-width:calc(100% - max(12px, var(--mdc-shape-small, 4px))*2)}}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__trailing{border-top-left-radius:0;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:var(--mdc-shape-small, 4px);border-bottom-left-radius:0}[dir=rtl] .mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__trailing,.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__trailing[dir=rtl]{border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:var(--mdc-shape-small, 4px)}@supports(top: max(0%)){.mdc-text-field--outlined{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined{padding-right:max(16px, var(--mdc-shape-small, 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined+.mdc-text-field-helper-line{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined+.mdc-text-field-helper-line{padding-right:max(16px, var(--mdc-shape-small, 4px))}}.mdc-text-field--outlined.mdc-text-field--with-leading-icon{padding-left:0}@supports(top: max(0%)){.mdc-text-field--outlined.mdc-text-field--with-leading-icon{padding-right:max(16px, var(--mdc-shape-small, 4px))}}[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-leading-icon,.mdc-text-field--outlined.mdc-text-field--with-leading-icon[dir=rtl]{padding-right:0}@supports(top: max(0%)){[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-leading-icon,.mdc-text-field--outlined.mdc-text-field--with-leading-icon[dir=rtl]{padding-left:max(16px, var(--mdc-shape-small, 4px))}}.mdc-text-field--outlined.mdc-text-field--with-trailing-icon{padding-right:0}@supports(top: max(0%)){.mdc-text-field--outlined.mdc-text-field--with-trailing-icon{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-trailing-icon,.mdc-text-field--outlined.mdc-text-field--with-trailing-icon[dir=rtl]{padding-left:0}@supports(top: max(0%)){[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-trailing-icon,.mdc-text-field--outlined.mdc-text-field--with-trailing-icon[dir=rtl]{padding-right:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}.mdc-text-field--outlined.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon{padding-left:0;padding-right:0}.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:1px}.mdc-text-field--outlined .mdc-floating-label{left:4px;right:initial}[dir=rtl] .mdc-text-field--outlined .mdc-floating-label,.mdc-text-field--outlined .mdc-floating-label[dir=rtl]{left:initial;right:4px}.mdc-text-field--outlined .mdc-text-field__input{display:flex;border:none !important;background-color:rgba(0,0,0,0)}.mdc-text-field--outlined .mdc-notched-outline{z-index:1}.mdc-text-field--textarea{flex-direction:column;align-items:center;width:auto;height:auto;padding:0}.mdc-text-field--textarea .mdc-floating-label{top:19px}.mdc-text-field--textarea .mdc-floating-label:not(.mdc-floating-label--float-above){transform:none}.mdc-text-field--textarea .mdc-text-field__input{flex-grow:1;height:auto;min-height:1.5rem;overflow-x:hidden;overflow-y:auto;box-sizing:border-box;resize:none;padding:0 16px}.mdc-text-field--textarea.mdc-text-field--filled::before{display:none}.mdc-text-field--textarea.mdc-text-field--filled .mdc-floating-label--float-above{transform:translateY(-10.25px) scale(0.75)}.mdc-text-field--textarea.mdc-text-field--filled .mdc-text-field__input{margin-top:23px;margin-bottom:9px}.mdc-text-field--textarea.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__input{margin-top:16px;margin-bottom:16px}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:0}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-27.25px) scale(1)}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label--float-above{font-size:.75rem}.mdc-text-field--textarea.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--textarea.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-24.75px) scale(0.75)}.mdc-text-field--textarea.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--textarea.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-text-field__input{margin-top:16px;margin-bottom:16px}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label{top:18px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field__input{margin-bottom:2px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field-character-counter{align-self:flex-end;padding:0 16px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field-character-counter::after{display:inline-block;width:0;height:16px;content:"";vertical-align:-16px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field-character-counter::before{display:none}.mdc-text-field__resizer{align-self:stretch;display:inline-flex;flex-direction:column;flex-grow:1;max-height:100%;max-width:100%;min-height:56px;min-width:fit-content;min-width:-moz-available;min-width:-webkit-fill-available;overflow:hidden;resize:both}.mdc-text-field--filled .mdc-text-field__resizer{transform:translateY(-1px)}.mdc-text-field--filled .mdc-text-field__resizer .mdc-text-field__input,.mdc-text-field--filled .mdc-text-field__resizer .mdc-text-field-character-counter{transform:translateY(1px)}.mdc-text-field--outlined .mdc-text-field__resizer{transform:translateX(-1px) translateY(-1px)}[dir=rtl] .mdc-text-field--outlined .mdc-text-field__resizer,.mdc-text-field--outlined .mdc-text-field__resizer[dir=rtl]{transform:translateX(1px) translateY(-1px)}.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field__input,.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field-character-counter{transform:translateX(1px) translateY(1px)}[dir=rtl] .mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field__input,[dir=rtl] .mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field-character-counter,.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field__input[dir=rtl],.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field-character-counter[dir=rtl]{transform:translateX(-1px) translateY(1px)}.mdc-text-field--with-leading-icon{padding-left:0;padding-right:16px}[dir=rtl] .mdc-text-field--with-leading-icon,.mdc-text-field--with-leading-icon[dir=rtl]{padding-left:16px;padding-right:0}.mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label{max-width:calc(100% - 48px);left:48px;right:initial}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label,.mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label[dir=rtl]{left:initial;right:48px}.mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 64px / 0.75)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label{left:36px;right:initial}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label[dir=rtl]{left:initial;right:36px}.mdc-text-field--with-leading-icon.mdc-text-field--outlined :not(.mdc-notched-outline--notched) .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-37.25px) translateX(-32px) scale(1)}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above[dir=rtl]{transform:translateY(-37.25px) translateX(32px) scale(1)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above{font-size:.75rem}.mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) translateX(-32px) scale(0.75)}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above[dir=rtl],.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above[dir=rtl]{transform:translateY(-34.75px) translateX(32px) scale(0.75)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-text-field--with-trailing-icon{padding-left:16px;padding-right:0}[dir=rtl] .mdc-text-field--with-trailing-icon,.mdc-text-field--with-trailing-icon[dir=rtl]{padding-left:0;padding-right:16px}.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label{max-width:calc(100% - 64px)}.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 64px / 0.75)}.mdc-text-field--with-trailing-icon.mdc-text-field--outlined :not(.mdc-notched-outline--notched) .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon{padding-left:0;padding-right:0}.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label{max-width:calc(100% - 96px)}.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 96px / 0.75)}.mdc-text-field-helper-line{display:flex;justify-content:space-between;box-sizing:border-box}.mdc-text-field+.mdc-text-field-helper-line{padding-right:16px;padding-left:16px}.mdc-form-field>.mdc-text-field+label{align-self:flex-start}.mdc-text-field--focused .mdc-notched-outline__leading,.mdc-text-field--focused .mdc-notched-outline__notch,.mdc-text-field--focused .mdc-notched-outline__trailing{border-width:2px}.mdc-text-field--focused+.mdc-text-field-helper-line .mdc-text-field-helper-text:not(.mdc-text-field-helper-text--validation-msg){opacity:1}.mdc-text-field--focused.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:2px}.mdc-text-field--focused.mdc-text-field--outlined.mdc-text-field--textarea .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:0}.mdc-text-field--invalid+.mdc-text-field-helper-line .mdc-text-field-helper-text--validation-msg{opacity:1}.mdc-text-field--disabled{pointer-events:none}@media screen and (forced-colors: active){.mdc-text-field--disabled .mdc-text-field__input{background-color:Window}.mdc-text-field--disabled .mdc-floating-label{z-index:1}}.mdc-text-field--disabled .mdc-floating-label{cursor:default}.mdc-text-field--disabled.mdc-text-field--filled .mdc-text-field__ripple{display:none}.mdc-text-field--disabled .mdc-text-field__input{pointer-events:auto}.mdc-text-field--end-aligned .mdc-text-field__input{text-align:right}[dir=rtl] .mdc-text-field--end-aligned .mdc-text-field__input,.mdc-text-field--end-aligned .mdc-text-field__input[dir=rtl]{text-align:left}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__input,[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__input,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix{direction:ltr}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--prefix{padding-left:0;padding-right:2px}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--suffix{padding-left:12px;padding-right:0}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__icon--leading,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__icon--leading{order:1}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--suffix{order:2}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__input,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__input{order:3}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--prefix{order:4}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__icon--trailing,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__icon--trailing{order:5}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__input,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__input{text-align:right}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__affix--prefix{padding-right:12px}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__affix--suffix{padding-left:2px}.mdc-floating-label{position:absolute;left:0;-webkit-transform-origin:left top;transform-origin:left top;line-height:1.15rem;text-align:left;text-overflow:ellipsis;white-space:nowrap;cursor:text;overflow:hidden;will-change:transform}[dir=rtl] .mdc-floating-label,.mdc-floating-label[dir=rtl]{right:0;left:auto;-webkit-transform-origin:right top;transform-origin:right top;text-align:right}.mdc-floating-label--float-above{cursor:auto}.mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)::after{margin-left:1px;margin-right:0px;content:"*"}[dir=rtl] .mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)::after,.mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)[dir=rtl]::after{margin-left:0;margin-right:1px}.mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-notched-outline{display:flex;position:absolute;top:0;right:0;left:0;box-sizing:border-box;width:100%;max-width:100%;height:100%;text-align:left;pointer-events:none}[dir=rtl] .mdc-notched-outline,.mdc-notched-outline[dir=rtl]{text-align:right}.mdc-notched-outline__leading,.mdc-notched-outline__notch,.mdc-notched-outline__trailing{box-sizing:border-box;height:100%;border-top:1px solid;border-bottom:1px solid;pointer-events:none}.mdc-notched-outline__leading{border-left:1px solid;border-right:none;width:12px}[dir=rtl] .mdc-notched-outline__leading,.mdc-notched-outline__leading[dir=rtl]{border-left:none;border-right:1px solid}.mdc-notched-outline__trailing{border-left:none;border-right:1px solid;flex-grow:1}[dir=rtl] .mdc-notched-outline__trailing,.mdc-notched-outline__trailing[dir=rtl]{border-left:1px solid;border-right:none}.mdc-notched-outline__notch{flex:0 0 auto;width:auto;max-width:calc(100% - 12px * 2)}.mdc-notched-outline .mdc-floating-label{display:inline-block;position:relative;max-width:100%}.mdc-notched-outline .mdc-floating-label--float-above{text-overflow:clip}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:133.3333333333%}.mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:0;padding-right:8px;border-top:none}[dir=rtl] .mdc-notched-outline--notched .mdc-notched-outline__notch,.mdc-notched-outline--notched .mdc-notched-outline__notch[dir=rtl]{padding-left:8px;padding-right:0}.mdc-notched-outline--no-label .mdc-notched-outline__notch{display:none}.mdc-line-ripple::before,.mdc-line-ripple::after{position:absolute;bottom:0;left:0;width:100%;border-bottom-style:solid;content:""}.mdc-line-ripple::before{border-bottom-width:1px}.mdc-line-ripple::after{border-bottom-width:2px}.mdc-line-ripple::before{z-index:1}.mdc-line-ripple::after{transform:scaleX(0);opacity:0;z-index:2}.mdc-line-ripple--active::after{transform:scaleX(1);opacity:1}.mdc-line-ripple--deactivating::after{opacity:0}.mat-mdc-form-field-textarea-control{vertical-align:middle;resize:vertical;box-sizing:border-box;height:auto;margin:0;padding:0;border:none;overflow:auto}.mat-mdc-form-field-input-control.mat-mdc-form-field-input-control{font:inherit;letter-spacing:inherit;text-decoration:inherit;text-transform:inherit;border:none}.mat-mdc-form-field .mat-mdc-floating-label.mdc-floating-label{line-height:normal;pointer-events:all}.mdc-text-field--no-label:not(.mdc-text-field--textarea) .mat-mdc-form-field-input-control.mdc-text-field__input,.mat-mdc-text-field-wrapper .mat-mdc-form-field-input-control{height:auto}.mat-mdc-text-field-wrapper .mat-mdc-form-field-input-control.mdc-text-field__input[type=color]{height:23px}.mat-mdc-text-field-wrapper{height:auto;flex:auto}.mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper{padding-left:0;--mat-mdc-form-field-label-offset-x: -16px}.mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper{padding-right:0}[dir=rtl] .mat-mdc-text-field-wrapper{padding-left:16px;padding-right:16px}[dir=rtl] .mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper{padding-left:0}[dir=rtl] .mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper{padding-right:0}.mat-mdc-form-field-label-always-float .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms;opacity:1}.mat-mdc-text-field-wrapper .mat-mdc-form-field-infix .mat-mdc-floating-label{left:auto;right:auto}.mat-mdc-text-field-wrapper.mdc-text-field--outlined .mdc-text-field__input{display:inline-block}.mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field .mdc-notched-outline__notch{padding-top:0}.mat-mdc-text-field-wrapper::before{content:none}.mat-mdc-form-field-subscript-wrapper{box-sizing:border-box;width:100%;position:relative}.mat-mdc-form-field-hint-wrapper,.mat-mdc-form-field-error-wrapper{position:absolute;top:0;left:0;right:0;padding:0 16px}.mat-mdc-form-field-subscript-dynamic-size .mat-mdc-form-field-hint-wrapper,.mat-mdc-form-field-subscript-dynamic-size .mat-mdc-form-field-error-wrapper{position:static}.mat-mdc-form-field-bottom-align::before{content:"";display:inline-block;height:16px}.mat-mdc-form-field-bottom-align.mat-mdc-form-field-subscript-dynamic-size::before{content:unset}.mat-mdc-form-field-hint-end{order:1}.mat-mdc-form-field-hint-wrapper{display:flex}.mat-mdc-form-field-hint-spacer{flex:1 0 1em}.mat-mdc-form-field-error{display:block}.mat-mdc-form-field-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;opacity:0;pointer-events:none}select.mat-mdc-form-field-input-control{-moz-appearance:none;-webkit-appearance:none;background-color:rgba(0,0,0,0);display:inline-flex;box-sizing:border-box}select.mat-mdc-form-field-input-control:not(:disabled){cursor:pointer}.mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-infix::after{content:"";width:0;height:0;border-left:5px solid rgba(0,0,0,0);border-right:5px solid rgba(0,0,0,0);border-top:5px solid;position:absolute;right:0;top:50%;margin-top:-2.5px;pointer-events:none}[dir=rtl] .mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-infix::after{right:auto;left:0}.mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-input-control{padding-right:15px}[dir=rtl] .mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-input-control{padding-right:0;padding-left:15px}.cdk-high-contrast-active .mat-form-field-appearance-fill .mat-mdc-text-field-wrapper{outline:solid 1px}.cdk-high-contrast-active .mat-form-field-appearance-fill.mat-form-field-disabled .mat-mdc-text-field-wrapper{outline-color:GrayText}.cdk-high-contrast-active .mat-form-field-appearance-fill.mat-focused .mat-mdc-text-field-wrapper{outline:dashed 3px}.cdk-high-contrast-active .mat-mdc-form-field.mat-focused .mdc-notched-outline{border:dashed 3px}.mat-mdc-form-field{--mat-mdc-form-field-floating-label-scale: 0.75;display:inline-flex;flex-direction:column;min-width:0;text-align:left}[dir=rtl] .mat-mdc-form-field{text-align:right}.mat-mdc-form-field-flex{display:inline-flex;align-items:baseline;box-sizing:border-box;width:100%}.mat-mdc-text-field-wrapper{width:100%}.mat-mdc-form-field-icon-prefix,.mat-mdc-form-field-icon-suffix{align-self:center;line-height:0;pointer-events:auto}.mat-mdc-form-field-icon-prefix,[dir=rtl] .mat-mdc-form-field-icon-suffix{padding:0 4px 0 0}.mat-mdc-form-field-icon-suffix,[dir=rtl] .mat-mdc-form-field-icon-prefix{padding:0 0 0 4px}.mat-mdc-form-field-icon-prefix>.mat-icon,.mat-mdc-form-field-icon-suffix>.mat-icon{padding:12px;box-sizing:content-box}.mat-mdc-form-field-subscript-wrapper .mat-icon,.mat-mdc-form-field label .mat-icon{width:1em;height:1em;font-size:inherit}.mat-mdc-form-field-infix{flex:auto;min-width:0;width:180px;position:relative;box-sizing:border-box}.mat-mdc-form-field .mdc-notched-outline__notch{margin-left:-1px;-webkit-clip-path:inset(-9em -999em -9em 1px);clip-path:inset(-9em -999em -9em 1px)}[dir=rtl] .mat-mdc-form-field .mdc-notched-outline__notch{margin-left:0;margin-right:-1px;-webkit-clip-path:inset(-9em 1px -9em -999em);clip-path:inset(-9em 1px -9em -999em)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input{transition:opacity 150ms 0ms cubic-bezier(0.4, 0, 0.2, 1)}@media all{.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::placeholder{transition:opacity 67ms 0ms cubic-bezier(0.4, 0, 0.2, 1)}}@media all{.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input:-ms-input-placeholder{transition:opacity 67ms 0ms cubic-bezier(0.4, 0, 0.2, 1)}}@media all{.mdc-text-field--no-label .mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::placeholder,.mdc-text-field--focused .mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms}}@media all{.mdc-text-field--no-label .mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input:-ms-input-placeholder,.mdc-text-field--focused .mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input:-ms-input-placeholder{transition-delay:40ms;transition-duration:110ms}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__affix{transition:opacity 150ms 0ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--filled.mdc-ripple-upgraded--background-focused .mdc-text-field__ripple::before,.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--filled:not(.mdc-ripple-upgraded):focus .mdc-text-field__ripple::before{transition-duration:75ms}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--outlined .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-text-field-outlined 250ms 1}@keyframes mdc-floating-label-shake-float-above-text-field-outlined{0%{transform:translateX(calc(0 - 0%)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-34.75px) scale(0.75)}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--textarea{transition:none}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--textarea.mdc-text-field--filled .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-textarea-filled 250ms 1}@keyframes mdc-floating-label-shake-float-above-textarea-filled{0%{transform:translateX(calc(0 - 0%)) translateY(-10.25px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-10.25px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-10.25px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-10.25px) scale(0.75)}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-textarea-outlined 250ms 1}@keyframes mdc-floating-label-shake-float-above-textarea-outlined{0%{transform:translateX(calc(0 - 0%)) translateY(-24.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-24.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-24.75px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-24.75px) scale(0.75)}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-text-field-outlined-leading-icon 250ms 1}@keyframes mdc-floating-label-shake-float-above-text-field-outlined-leading-icon{0%{transform:translateX(calc(0 - 32px)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 32px)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 32px)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - 32px)) translateY(-34.75px) scale(0.75)}}[dir=rtl] .mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--shake,.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--with-leading-icon.mdc-text-field--outlined[dir=rtl] .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-text-field-outlined-leading-icon 250ms 1}@keyframes mdc-floating-label-shake-float-above-text-field-outlined-leading-icon-rtl{0%{transform:translateX(calc(0 - -32px)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - -32px)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - -32px)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - -32px)) translateY(-34.75px) scale(0.75)}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-floating-label{transition:transform 150ms cubic-bezier(0.4, 0, 0.2, 1),color 150ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-standard 250ms 1}@keyframes mdc-floating-label-shake-float-above-standard{0%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-106%) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-106%) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-line-ripple::after{transition:transform 180ms cubic-bezier(0.4, 0, 0.2, 1),opacity 180ms cubic-bezier(0.4, 0, 0.2, 1)}'],encapsulation:2,data:{animation:[eX.transitionMessages]},changeDetection:0}),n})(),rX=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,ul,FT,rr]}),n})();function wo(n,e){return"function"==typeof e?t=>t.pipe(wo((i,r)=>dr(n(i,r)).pipe(_t((s,o)=>e(i,s,r,o))))):t=>t.lift(new sX(n))}class sX{constructor(e){this.project=e}call(e,t){return t.subscribe(new oX(e,this.project))}}class oX extends Fs{constructor(e,t){super(e),this.project=t,this.index=0}_next(e){let t;const i=this.index++;try{t=this.project(e,i)}catch(r){return void this.destination.error(r)}this._innerSub(t,e,i)}_innerSub(e,t,i){const r=this.innerSubscription;r&&r.unsubscribe();const s=new Pt(this,t,i),o=this.destination;o.add(s),this.innerSubscription=$o(this,e,void 0,void 0,s),this.innerSubscription!==s&&o.add(this.innerSubscription)}_complete(){const{innerSubscription:e}=this;(!e||e.closed)&&super._complete(),this.unsubscribe()}_unsubscribe(){this.innerSubscription=null}notifyComplete(e){this.destination.remove(e),this.innerSubscription=null,this.isStopped&&super._complete()}notifyNext(e,t,i,r,s){this.destination.next(t)}}const aX=["trigger"],cX=["panel"];function lX(n,e){if(1&n&&(ke(0,"span",10),it(1),Ne()),2&n){const t=Jt();Le(1),Hi(t.placeholder)}}function dX(n,e){if(1&n&&(ke(0,"span",14),it(1),Ne()),2&n){const t=Jt(2);Le(1),Hi(t.triggerValue)}}function uX(n,e){1&n&&En(0,0,["*ngSwitchCase","true"])}function hX(n,e){1&n&&(ke(0,"span",11),mt(1,dX,2,1,"span",12),mt(2,uX,1,0,"ng-content",13),Ne()),2&n&&($e("ngSwitch",!!Jt().customTrigger),Le(2),$e("ngSwitchCase",!0))}function fX(n,e){if(1&n){const t=Df();$i(),Xo(),ke(0,"div",15,16),Gn("@transformPanel.done",function(r){return R(t),V(Jt()._panelDoneAnimatingStream.next(r.toState))})("keydown",function(r){return R(t),V(Jt()._handleKeydown(r))}),En(2,1),Ne()}if(2&n){const t=Jt();dR("mat-mdc-select-panel mdc-menu-surface mdc-menu-surface--open ",t._getPanelTheme(),""),$e("ngClass",t.panelClass)("@transformPanel","showing"),Di("id",t.id+"-panel")("aria-multiselectable",t.multiple)("aria-label",t.ariaLabel||null)("aria-labelledby",t._getPanelAriaLabelledby())}}const pX=[[["mat-select-trigger"]],"*"],mX=["mat-select-trigger","*"],gX={transformPanelWrap:fg("transformPanelWrap",[Xl("* => void",Jv("@transformPanel",[Zv()],{optional:!0}))]),transformPanel:fg("transformPanel",[sh("void",la({opacity:0,transform:"scale(1, 0.8)"})),Xl("void => showing",zd("120ms cubic-bezier(0, 0, 0.2, 1)",la({opacity:1,transform:"scale(1, 1)"}))),Xl("* => void",zd("100ms linear",la({opacity:0})))])};let v4=0;const y4=new Ze("mat-select-scroll-strategy"),vX=new Ze("MAT_SELECT_CONFIG"),yX={provide:y4,deps:[hl],useFactory:function _X(n){return()=>n.scrollStrategies.reposition()}},bX=new Ze("MatSelectTrigger");class xX{constructor(e,t){this.source=e,this.value=t}}const wX=Bw(ZL(LT(W$(class{constructor(n,e,t,i,r){this._elementRef=n,this._defaultErrorStateMatcher=e,this._parentForm=t,this._parentFormGroup=i,this.ngControl=r,this.stateChanges=new cn}}))));let SX=(()=>{class n extends wX{get focused(){return this._focused||this._panelOpen}get placeholder(){return this._placeholder}set placeholder(t){this._placeholder=t,this.stateChanges.next()}get required(){return this._required??this.ngControl?.control?.hasValidator(Cj.required)??!1}set required(t){this._required=bi(t),this.stateChanges.next()}get multiple(){return this._multiple}set multiple(t){this._multiple=bi(t)}get disableOptionCentering(){return this._disableOptionCentering}set disableOptionCentering(t){this._disableOptionCentering=bi(t)}get compareWith(){return this._compareWith}set compareWith(t){this._compareWith=t,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(t){this._assignValue(t)&&this._onChange(t)}get typeaheadDebounceInterval(){return this._typeaheadDebounceInterval}set typeaheadDebounceInterval(t){this._typeaheadDebounceInterval=ih(t)}get id(){return this._id}set id(t){this._id=t||this._uid,this.stateChanges.next()}constructor(t,i,r,s,o,a,c,u,p,g,v,y,x,T){super(o,s,c,u,g),this._viewportRuler=t,this._changeDetectorRef=i,this._ngZone=r,this._dir=a,this._parentFormField=p,this._liveAnnouncer=x,this._defaultOptions=T,this._panelOpen=!1,this._compareWith=(N,k)=>N===k,this._uid="mat-select-"+v4++,this._triggerAriaLabelledBy=null,this._destroy=new cn,this._onChange=()=>{},this._onTouched=()=>{},this._valueId="mat-select-value-"+v4++,this._panelDoneAnimatingStream=new cn,this._overlayPanelClass=this._defaultOptions?.overlayPanelClass||"",this._focused=!1,this.controlType="mat-select",this._multiple=!1,this._disableOptionCentering=this._defaultOptions?.disableOptionCentering??!1,this.ariaLabel="",this.optionSelectionChanges=Yv(()=>{const N=this.options;return N?N.changes.pipe(Bf(N),wo(()=>fa(...N.map(k=>k.onSelectionChange)))):this._ngZone.onStable.pipe(Gr(1),wo(()=>this.optionSelectionChanges))}),this.openedChange=new Pn,this._openedStream=this.openedChange.pipe(Ui(N=>N),_t(()=>{})),this._closedStream=this.openedChange.pipe(Ui(N=>!N),_t(()=>{})),this.selectionChange=new Pn,this.valueChange=new Pn,this.ngControl&&(this.ngControl.valueAccessor=this),null!=T?.typeaheadDebounceInterval&&(this._typeaheadDebounceInterval=T.typeaheadDebounceInterval),this._scrollStrategyFactory=y,this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=parseInt(v)||0,this.id=this.id}ngOnInit(){this._selectionModel=new Hw(this.multiple),this.stateChanges.next(),this._panelDoneAnimatingStream.pipe(Rc(),Tr(this._destroy)).subscribe(()=>this._panelDoneAnimating(this.panelOpen))}ngAfterContentInit(){this._initKeyManager(),this._selectionModel.changed.pipe(Tr(this._destroy)).subscribe(t=>{t.added.forEach(i=>i.select()),t.removed.forEach(i=>i.deselect())}),this.options.changes.pipe(Bf(null),Tr(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection()})}ngDoCheck(){const t=this._getTriggerAriaLabelledby(),i=this.ngControl;if(t!==this._triggerAriaLabelledBy){const r=this._elementRef.nativeElement;this._triggerAriaLabelledBy=t,t?r.setAttribute("aria-labelledby",t):r.removeAttribute("aria-labelledby")}i&&(this._previousControl!==i.control&&(void 0!==this._previousControl&&null!==i.disabled&&i.disabled!==this.disabled&&(this.disabled=i.disabled),this._previousControl=i.control),this.updateErrorState())}ngOnChanges(t){(t.disabled||t.userAriaDescribedBy)&&this.stateChanges.next(),t.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this._typeaheadDebounceInterval)}ngOnDestroy(){this._keyManager?.destroy(),this._destroy.next(),this._destroy.complete(),this.stateChanges.complete()}toggle(){this.panelOpen?this.close():this.open()}open(){this._canOpen()&&(this._panelOpen=!0,this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck())}close(){this._panelOpen&&(this._panelOpen=!1,this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched())}writeValue(t){this._assignValue(t)}registerOnChange(t){this._onChange=t}registerOnTouched(t){this._onTouched=t}setDisabledState(t){this.disabled=t,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}get panelOpen(){return this._panelOpen}get selected(){return this.multiple?this._selectionModel?.selected||[]:this._selectionModel?.selected[0]}get triggerValue(){if(this.empty)return"";if(this._multiple){const t=this._selectionModel.selected.map(i=>i.viewValue);return this._isRtl()&&t.reverse(),t.join(", ")}return this._selectionModel.selected[0].viewValue}_isRtl(){return!!this._dir&&"rtl"===this._dir.value}_handleKeydown(t){this.disabled||(this.panelOpen?this._handleOpenKeydown(t):this._handleClosedKeydown(t))}_handleClosedKeydown(t){const i=t.keyCode,r=40===i||38===i||37===i||39===i,s=13===i||32===i,o=this._keyManager;if(!o.isTyping()&&s&&!ql(t)||(this.multiple||t.altKey)&&r)t.preventDefault(),this.open();else if(!this.multiple){const a=this.selected;o.onKeydown(t);const c=this.selected;c&&a!==c&&this._liveAnnouncer.announce(c.viewValue,1e4)}}_handleOpenKeydown(t){const i=this._keyManager,r=t.keyCode,s=40===r||38===r,o=i.isTyping();if(s&&t.altKey)t.preventDefault(),this.close();else if(o||13!==r&&32!==r||!i.activeItem||ql(t))if(!o&&this._multiple&&65===r&&t.ctrlKey){t.preventDefault();const a=this.options.some(c=>!c.disabled&&!c.selected);this.options.forEach(c=>{c.disabled||(a?c.select():c.deselect())})}else{const a=i.activeItemIndex;i.onKeydown(t),this._multiple&&s&&t.shiftKey&&i.activeItem&&i.activeItemIndex!==a&&i.activeItem._selectViaInteraction()}else t.preventDefault(),i.activeItem._selectViaInteraction()}_onFocus(){this.disabled||(this._focused=!0,this.stateChanges.next())}_onBlur(){this._focused=!1,this._keyManager?.cancelTypeahead(),!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}_onAttached(){this._overlayDir.positionChange.pipe(Gr(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled()})}_getPanelTheme(){return this._parentFormField?`mat-${this._parentFormField.color}`:""}get empty(){return!this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next()})}_setSelectionByValue(t){if(this.options.forEach(i=>i.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&t)Array.isArray(t),t.forEach(i=>this._selectOptionByValue(i)),this._sortValues();else{const i=this._selectOptionByValue(t);i?this._keyManager.updateActiveItem(i):this.panelOpen||this._keyManager.updateActiveItem(-1)}this._changeDetectorRef.markForCheck()}_selectOptionByValue(t){const i=this.options.find(r=>{if(this._selectionModel.isSelected(r))return!1;try{return null!=r.value&&this._compareWith(r.value,t)}catch{return!1}});return i&&this._selectionModel.select(i),i}_assignValue(t){return!!(t!==this._value||this._multiple&&Array.isArray(t))&&(this.options&&this._setSelectionByValue(t),this._value=t,!0)}_initKeyManager(){this._keyManager=new u$(this.options).withTypeAhead(this._typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withPageUpDown().withAllowedModifierKeys(["shiftKey"]),this._keyManager.tabOut.subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close())}),this._keyManager.change.subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction()})}_resetOptions(){const t=fa(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(Tr(t)).subscribe(i=>{this._onSelect(i.source,i.isUserInput),i.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus())}),fa(...this.options.map(i=>i._stateChanges)).pipe(Tr(t)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this.stateChanges.next()})}_onSelect(t,i){const r=this._selectionModel.isSelected(t);null!=t.value||this._multiple?(r!==t.selected&&(t.selected?this._selectionModel.select(t):this._selectionModel.deselect(t)),i&&this._keyManager.setActiveItem(t),this.multiple&&(this._sortValues(),i&&this.focus())):(t.deselect(),this._selectionModel.clear(),null!=this.value&&this._propagateChanges(t.value)),r!==this._selectionModel.isSelected(t)&&this._propagateChanges(),this.stateChanges.next()}_sortValues(){if(this.multiple){const t=this.options.toArray();this._selectionModel.sort((i,r)=>this.sortComparator?this.sortComparator(i,r,t):t.indexOf(i)-t.indexOf(r)),this.stateChanges.next()}}_propagateChanges(t){let i=null;i=this.multiple?this.selected.map(r=>r.value):this.selected?this.selected.value:t,this._value=i,this.valueChange.emit(i),this._onChange(i),this.selectionChange.emit(this._getChangeEvent(i)),this._changeDetectorRef.markForCheck()}_highlightCorrectOption(){this._keyManager&&(this.empty?this._keyManager.setFirstItemActive():this._keyManager.setActiveItem(this._selectionModel.selected[0]))}_canOpen(){return!this._panelOpen&&!this.disabled&&this.options?.length>0}focus(t){this._elementRef.nativeElement.focus(t)}_getPanelAriaLabelledby(){if(this.ariaLabel)return null;const t=this._parentFormField?.getLabelId();return this.ariaLabelledby?(t?t+" ":"")+this.ariaLabelledby:t}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){if(this.ariaLabel)return null;const t=this._parentFormField?.getLabelId();let i=(t?t+" ":"")+this._valueId;return this.ariaLabelledby&&(i+=" "+this.ariaLabelledby),i}_panelDoneAnimating(t){this.openedChange.emit(t)}setDescribedByIds(t){t.length?this._elementRef.nativeElement.setAttribute("aria-describedby",t.join(" ")):this._elementRef.nativeElement.removeAttribute("aria-describedby")}onContainerClick(){this.focus(),this.open()}get shouldLabelFloat(){return this._panelOpen||!this.empty||this._focused&&!!this._placeholder}}return n.\u0275fac=function(t){return new(t||n)(ie(Gw),ie(aa),ie(Xt),ie(q$),ie(_n),ie(Yl,8),ie(Sw,8),ie(Mw,8),ie(f4,8),ie(Hd,10),Kc("tabindex"),ie(y4),ie(I$),ie(vX,8))},n.\u0275dir=ut({type:n,viewQuery:function(t,i){if(1&t&&(zr(aX,5),zr(cX,5),zr(VN,5)),2&t){let r;Yn(r=Xn())&&(i.trigger=r.first),Yn(r=Xn())&&(i.panel=r.first),Yn(r=Xn())&&(i._overlayDir=r.first)}},inputs:{userAriaDescribedBy:["aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",placeholder:"placeholder",required:"required",multiple:"multiple",disableOptionCentering:"disableOptionCentering",compareWith:"compareWith",value:"value",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:"typeaheadDebounceInterval",sortComparator:"sortComparator",id:"id"},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},features:[Z,Cn]}),n})(),b4=(()=>{class n extends SX{constructor(){super(...arguments),this._positions=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"}],this._hideSingleSelectionIndicator=this._defaultOptions?.hideSingleSelectionIndicator??!1}get shouldLabelFloat(){return this.panelOpen||!this.empty||this.focused&&!!this.placeholder}ngOnInit(){super.ngOnInit(),this._viewportRuler.change().pipe(Tr(this._destroy)).subscribe(()=>{this.panelOpen&&(this._overlayWidth=this._getOverlayWidth(),this._changeDetectorRef.detectChanges())})}ngAfterViewInit(){this._parentFormField&&(this._preferredOverlayOrigin=this._parentFormField.getConnectedOverlayOrigin())}open(){this._overlayWidth=this._getOverlayWidth(),super.open(),this.stateChanges.next()}close(){super.close(),this.stateChanges.next()}_scrollOptionIntoView(t){const i=this.options.toArray()[t];if(i){const r=this.panel.nativeElement,s=function nq(n,e,t){if(t.length){let i=e.toArray(),r=t.toArray(),s=0;for(let o=0;ot+i?Math.max(0,n-i+e):t}(o.offsetTop,o.offsetHeight,r.scrollTop,r.offsetHeight)}}_positioningSettled(){this._scrollOptionIntoView(this._keyManager.activeItemIndex||0)}_getChangeEvent(t){return new xX(this,t)}_getOverlayWidth(){return(this._preferredOverlayOrigin instanceof ZT?this._preferredOverlayOrigin.elementRef:this._preferredOverlayOrigin||this._elementRef).nativeElement.getBoundingClientRect().width}get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(t){this._hideSingleSelectionIndicator=bi(t),this._syncParentProperties()}_syncParentProperties(){if(this.options)for(const t of this.options)t._changeDetectorRef.markForCheck()}}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275cmp=Ln({type:n,selectors:[["mat-select"]],contentQueries:function(t,i,r){if(1&t&&(is(r,bX,5),is(r,BT,5),is(r,sN,5)),2&t){let s;Yn(s=Xn())&&(i.customTrigger=s.first),Yn(s=Xn())&&(i.options=s),Yn(s=Xn())&&(i.optionGroups=s)}},hostAttrs:["role","combobox","aria-autocomplete","none","aria-haspopup","listbox",1,"mat-mdc-select"],hostVars:19,hostBindings:function(t,i){1&t&&Gn("keydown",function(s){return i._handleKeydown(s)})("focus",function(){return i._onFocus()})("blur",function(){return i._onBlur()}),2&t&&(Di("id",i.id)("tabindex",i.tabIndex)("aria-controls",i.panelOpen?i.id+"-panel":null)("aria-expanded",i.panelOpen)("aria-label",i.ariaLabel||null)("aria-required",i.required.toString())("aria-disabled",i.disabled.toString())("aria-invalid",i.errorState)("aria-activedescendant",i._getAriaActiveDescendant()),hi("mat-mdc-select-disabled",i.disabled)("mat-mdc-select-invalid",i.errorState)("mat-mdc-select-required",i.required)("mat-mdc-select-empty",i.empty)("mat-mdc-select-multiple",i.multiple))},inputs:{disabled:"disabled",disableRipple:"disableRipple",tabIndex:"tabIndex",hideSingleSelectionIndicator:"hideSingleSelectionIndicator"},exportAs:["matSelect"],features:[Oi([{provide:h4,useExisting:n},{provide:rN,useExisting:n}]),Z],ngContentSelectors:mX,decls:11,vars:11,consts:[["cdk-overlay-origin","",1,"mat-mdc-select-trigger",3,"click"],["fallbackOverlayOrigin","cdkOverlayOrigin","trigger",""],[1,"mat-mdc-select-value",3,"ngSwitch"],["class","mat-mdc-select-placeholder mat-mdc-select-min-line",4,"ngSwitchCase"],["class","mat-mdc-select-value-text",3,"ngSwitch",4,"ngSwitchCase"],[1,"mat-mdc-select-arrow-wrapper"],[1,"mat-mdc-select-arrow"],["viewBox","0 0 24 24","width","24px","height","24px","focusable","false"],["d","M7 10l5 5 5-5z"],["cdk-connected-overlay","","cdkConnectedOverlayLockPosition","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayOpen","cdkConnectedOverlayPositions","cdkConnectedOverlayWidth","backdropClick","attach","detach"],[1,"mat-mdc-select-placeholder","mat-mdc-select-min-line"],[1,"mat-mdc-select-value-text",3,"ngSwitch"],["class","mat-mdc-select-min-line",4,"ngSwitchDefault"],[4,"ngSwitchCase"],[1,"mat-mdc-select-min-line"],["role","listbox","tabindex","-1",3,"ngClass","keydown"],["panel",""]],template:function(t,i){if(1&t&&(Hs(pX),ke(0,"div",0,1),Gn("click",function(){return i.toggle()}),ke(3,"div",2),mt(4,lX,2,1,"span",3),mt(5,hX,3,2,"span",4),Ne(),ke(6,"div",5)(7,"div",6),$i(),ke(8,"svg",7),qt(9,"path",8),Ne()()()(),mt(10,fX,3,9,"ng-template",9),Gn("backdropClick",function(){return i.close()})("attach",function(){return i._onAttached()})("detach",function(){return i.close()})),2&t){const r=Tc(1);Di("aria-owns",i.panelOpen?i.id+"-panel":null),Le(3),$e("ngSwitch",i.empty),Di("id",i._valueId),Le(1),$e("ngSwitchCase",!0),Le(1),$e("ngSwitchCase",!1),Le(5),$e("cdkConnectedOverlayPanelClass",i._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",i._scrollStrategy)("cdkConnectedOverlayOrigin",i._preferredOverlayOrigin||r)("cdkConnectedOverlayOpen",i.panelOpen)("cdkConnectedOverlayPositions",i._positions)("cdkConnectedOverlayWidth",i._overlayWidth)}},dependencies:[eg,Tv,ND,T3,VN,ZT],styles:['.mdc-menu-surface{display:none;position:absolute;box-sizing:border-box;max-width:calc(100vw - 32px);max-width:var(--mdc-menu-max-width, calc(100vw - 32px));max-height:calc(100vh - 32px);max-height:var(--mdc-menu-max-height, calc(100vh - 32px));margin:0;padding:0;transform:scale(1);transform-origin:top left;opacity:0;overflow:auto;will-change:transform,opacity;z-index:8;border-radius:4px;border-radius:var(--mdc-shape-medium, 4px);transform-origin-left:top left;transform-origin-right:top right}.mdc-menu-surface:focus{outline:none}.mdc-menu-surface--animating-open{display:inline-block;transform:scale(0.8);opacity:0}.mdc-menu-surface--open{display:inline-block;transform:scale(1);opacity:1}.mdc-menu-surface--animating-closed{display:inline-block;opacity:0}[dir=rtl] .mdc-menu-surface,.mdc-menu-surface[dir=rtl]{transform-origin-left:top right;transform-origin-right:top left}.mdc-menu-surface--anchor{position:relative;overflow:visible}.mdc-menu-surface--fixed{position:fixed}.mdc-menu-surface--fullwidth{width:100%}.mat-mdc-select{display:inline-block;width:100%;outline:none}.mat-mdc-select-trigger{display:inline-flex;align-items:center;cursor:pointer;position:relative;box-sizing:border-box;width:100%}.mat-mdc-select-disabled .mat-mdc-select-trigger{-webkit-user-select:none;user-select:none;cursor:default}.mat-mdc-select-value{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mat-mdc-select-value-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mat-mdc-select-arrow-wrapper{height:24px;flex-shrink:0;display:inline-flex;align-items:center}.mat-form-field-appearance-fill .mat-mdc-select-arrow-wrapper{transform:translateY(-8px)}.mat-form-field-appearance-fill .mdc-text-field--no-label .mat-mdc-select-arrow-wrapper{transform:none}.mat-mdc-select-arrow{width:10px;height:5px;position:relative}.mat-mdc-select-arrow svg{fill:currentColor;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%)}.cdk-high-contrast-active .mat-mdc-select-arrow svg{fill:CanvasText}.mat-mdc-select-disabled .cdk-high-contrast-active .mat-mdc-select-arrow svg{fill:GrayText}.mdc-menu-surface.mat-mdc-select-panel{width:100%;max-height:275px;position:static;outline:0;margin:0;padding:8px 0;list-style-type:none}.mdc-menu-surface.mat-mdc-select-panel:focus{outline:none}.cdk-high-contrast-active .mdc-menu-surface.mat-mdc-select-panel{outline:solid 1px}.cdk-overlay-pane:not(.mat-mdc-select-panel-above) .mdc-menu-surface.mat-mdc-select-panel{border-top-left-radius:0;border-top-right-radius:0;transform-origin:top center}.mat-mdc-select-panel-above .mdc-menu-surface.mat-mdc-select-panel{border-bottom-left-radius:0;border-bottom-right-radius:0;transform-origin:bottom center}.mat-mdc-select-placeholder{transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1)}._mat-animation-noopable .mat-mdc-select-placeholder{transition:none}.mat-form-field-hide-placeholder .mat-mdc-select-placeholder{color:rgba(0,0,0,0);-webkit-text-fill-color:rgba(0,0,0,0);transition:none;display:block}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-fill .mat-mdc-floating-label{max-width:calc(100% - 18px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-fill .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 24px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-outline .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-outline .mdc-text-field--label-floating .mdc-notched-outline__notch{max-width:calc(100% - 24px)}.mat-mdc-select-min-line:empty::before{content:" ";white-space:pre;width:1px;display:inline-block;visibility:hidden}'],encapsulation:2,data:{animation:[gX.transformPanel]},changeDetection:0}),n})(),EX=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[yX],imports:[ul,Kw,oN,rr,jw,rX,oN,rr]}),n})();const MX=["tooltip"],x4=new Ze("mat-tooltip-scroll-strategy"),TX={provide:x4,deps:[hl],useFactory:function DX(n){return()=>n.scrollStrategies.reposition({scrollThrottle:20})}},kX=new Ze("mat-tooltip-default-options",{providedIn:"root",factory:function AX(){return{showDelay:0,hideDelay:0,touchendHideDelay:1500}}}),w4="tooltip-panel",S4=Vv({passive:!0});let LX=(()=>{class n{get position(){return this._position}set position(t){t!==this._position&&(this._position=t,this._overlayRef&&(this._updatePosition(this._overlayRef),this._tooltipInstance?.show(0),this._overlayRef.updatePosition()))}get positionAtOrigin(){return this._positionAtOrigin}set positionAtOrigin(t){this._positionAtOrigin=bi(t),this._detach(),this._overlayRef=null}get disabled(){return this._disabled}set disabled(t){this._disabled=bi(t),this._disabled?this.hide(0):this._setupPointerEnterEventsIfNeeded()}get showDelay(){return this._showDelay}set showDelay(t){this._showDelay=ih(t)}get hideDelay(){return this._hideDelay}set hideDelay(t){this._hideDelay=ih(t),this._tooltipInstance&&(this._tooltipInstance._mouseLeaveHideDelay=this._hideDelay)}get message(){return this._message}set message(t){this._ariaDescriber.removeDescription(this._elementRef.nativeElement,this._message,"tooltip"),this._message=null!=t?String(t).trim():"",!this._message&&this._isTooltipVisible()?this.hide(0):(this._setupPointerEnterEventsIfNeeded(),this._updateTooltipMessage(),this._ngZone.runOutsideAngular(()=>{Promise.resolve().then(()=>{this._ariaDescriber.describe(this._elementRef.nativeElement,this.message,"tooltip")})}))}get tooltipClass(){return this._tooltipClass}set tooltipClass(t){this._tooltipClass=t,this._tooltipInstance&&this._setTooltipClass(this._tooltipClass)}constructor(t,i,r,s,o,a,c,u,p,g,v,y){this._overlay=t,this._elementRef=i,this._scrollDispatcher=r,this._viewContainerRef=s,this._ngZone=o,this._platform=a,this._ariaDescriber=c,this._focusMonitor=u,this._dir=g,this._defaultOptions=v,this._position="below",this._positionAtOrigin=!1,this._disabled=!1,this._viewInitialized=!1,this._pointerExitEventsInitialized=!1,this._viewportMargin=8,this._cssClassPrefix="mat",this._showDelay=this._defaultOptions.showDelay,this._hideDelay=this._defaultOptions.hideDelay,this.touchGestures="auto",this._message="",this._passiveListeners=[],this._destroyed=new cn,this._scrollStrategy=p,this._document=y,v&&(v.position&&(this.position=v.position),v.positionAtOrigin&&(this.positionAtOrigin=v.positionAtOrigin),v.touchGestures&&(this.touchGestures=v.touchGestures)),g.change.pipe(Tr(this._destroyed)).subscribe(()=>{this._overlayRef&&this._updatePosition(this._overlayRef)})}ngAfterViewInit(){this._viewInitialized=!0,this._setupPointerEnterEventsIfNeeded(),this._focusMonitor.monitor(this._elementRef).pipe(Tr(this._destroyed)).subscribe(t=>{t?"keyboard"===t&&this._ngZone.run(()=>this.show()):this._ngZone.run(()=>this.hide(0))})}ngOnDestroy(){const t=this._elementRef.nativeElement;clearTimeout(this._touchstartTimeout),this._overlayRef&&(this._overlayRef.dispose(),this._tooltipInstance=null),this._passiveListeners.forEach(([i,r])=>{t.removeEventListener(i,r,S4)}),this._passiveListeners.length=0,this._destroyed.next(),this._destroyed.complete(),this._ariaDescriber.removeDescription(t,this.message,"tooltip"),this._focusMonitor.stopMonitoring(t)}show(t=this.showDelay,i){if(this.disabled||!this.message||this._isTooltipVisible())return void this._tooltipInstance?._cancelPendingAnimations();const r=this._createOverlay(i);this._detach(),this._portal=this._portal||new Ww(this._tooltipComponent,this._viewContainerRef);const s=this._tooltipInstance=r.attach(this._portal).instance;s._triggerElement=this._elementRef.nativeElement,s._mouseLeaveHideDelay=this._hideDelay,s.afterHidden().pipe(Tr(this._destroyed)).subscribe(()=>this._detach()),this._setTooltipClass(this._tooltipClass),this._updateTooltipMessage(),s.show(t)}hide(t=this.hideDelay){const i=this._tooltipInstance;i&&(i.isVisible()?i.hide(t):(i._cancelPendingAnimations(),this._detach()))}toggle(t){this._isTooltipVisible()?this.hide():this.show(void 0,t)}_isTooltipVisible(){return!!this._tooltipInstance&&this._tooltipInstance.isVisible()}_createOverlay(t){if(this._overlayRef){const s=this._overlayRef.getConfig().positionStrategy;if((!this.positionAtOrigin||!t)&&s._origin instanceof _n)return this._overlayRef;this._detach()}const i=this._scrollDispatcher.getAncestorScrollContainers(this._elementRef),r=this._overlay.position().flexibleConnectedTo(this.positionAtOrigin&&t||this._elementRef).withTransformOriginOn(`.${this._cssClassPrefix}-tooltip`).withFlexibleDimensions(!1).withViewportMargin(this._viewportMargin).withScrollableContainers(i);return r.positionChanges.pipe(Tr(this._destroyed)).subscribe(s=>{this._updateCurrentPositionClass(s.connectionPair),this._tooltipInstance&&s.scrollableViewProperties.isOverlayClipped&&this._tooltipInstance.isVisible()&&this._ngZone.run(()=>this.hide(0))}),this._overlayRef=this._overlay.create({direction:this._dir,positionStrategy:r,panelClass:`${this._cssClassPrefix}-${w4}`,scrollStrategy:this._scrollStrategy()}),this._updatePosition(this._overlayRef),this._overlayRef.detachments().pipe(Tr(this._destroyed)).subscribe(()=>this._detach()),this._overlayRef.outsidePointerEvents().pipe(Tr(this._destroyed)).subscribe(()=>this._tooltipInstance?._handleBodyInteraction()),this._overlayRef.keydownEvents().pipe(Tr(this._destroyed)).subscribe(s=>{this._isTooltipVisible()&&27===s.keyCode&&!ql(s)&&(s.preventDefault(),s.stopPropagation(),this._ngZone.run(()=>this.hide(0)))}),this._defaultOptions?.disableTooltipInteractivity&&this._overlayRef.addPanelClass(`${this._cssClassPrefix}-tooltip-panel-non-interactive`),this._overlayRef}_detach(){this._overlayRef&&this._overlayRef.hasAttached()&&this._overlayRef.detach(),this._tooltipInstance=null}_updatePosition(t){const i=t.getConfig().positionStrategy,r=this._getOrigin(),s=this._getOverlayPosition();i.withPositions([this._addOffset({...r.main,...s.main}),this._addOffset({...r.fallback,...s.fallback})])}_addOffset(t){return t}_getOrigin(){const t=!this._dir||"ltr"==this._dir.value,i=this.position;let r;"above"==i||"below"==i?r={originX:"center",originY:"above"==i?"top":"bottom"}:"before"==i||"left"==i&&t||"right"==i&&!t?r={originX:"start",originY:"center"}:("after"==i||"right"==i&&t||"left"==i&&!t)&&(r={originX:"end",originY:"center"});const{x:s,y:o}=this._invertPosition(r.originX,r.originY);return{main:r,fallback:{originX:s,originY:o}}}_getOverlayPosition(){const t=!this._dir||"ltr"==this._dir.value,i=this.position;let r;"above"==i?r={overlayX:"center",overlayY:"bottom"}:"below"==i?r={overlayX:"center",overlayY:"top"}:"before"==i||"left"==i&&t||"right"==i&&!t?r={overlayX:"end",overlayY:"center"}:("after"==i||"right"==i&&t||"left"==i&&!t)&&(r={overlayX:"start",overlayY:"center"});const{x:s,y:o}=this._invertPosition(r.overlayX,r.overlayY);return{main:r,fallback:{overlayX:s,overlayY:o}}}_updateTooltipMessage(){this._tooltipInstance&&(this._tooltipInstance.message=this.message,this._tooltipInstance._markForCheck(),this._ngZone.onMicrotaskEmpty.pipe(Gr(1),Tr(this._destroyed)).subscribe(()=>{this._tooltipInstance&&this._overlayRef.updatePosition()}))}_setTooltipClass(t){this._tooltipInstance&&(this._tooltipInstance.tooltipClass=t,this._tooltipInstance._markForCheck())}_invertPosition(t,i){return"above"===this.position||"below"===this.position?"top"===i?i="bottom":"bottom"===i&&(i="top"):"end"===t?t="start":"start"===t&&(t="end"),{x:t,y:i}}_updateCurrentPositionClass(t){const{overlayY:i,originX:r,originY:s}=t;let o;if(o="center"===i?this._dir&&"rtl"===this._dir.value?"end"===r?"left":"right":"start"===r?"left":"right":"bottom"===i&&"top"===s?"above":"below",o!==this._currentPosition){const a=this._overlayRef;if(a){const c=`${this._cssClassPrefix}-${w4}-`;a.removePanelClass(c+this._currentPosition),a.addPanelClass(c+o)}this._currentPosition=o}}_setupPointerEnterEventsIfNeeded(){this._disabled||!this.message||!this._viewInitialized||this._passiveListeners.length||(this._platformSupportsMouseEvents()?this._passiveListeners.push(["mouseenter",t=>{let i;this._setupPointerExitEventsIfNeeded(),void 0!==t.x&&void 0!==t.y&&(i=t),this.show(void 0,i)}]):"off"!==this.touchGestures&&(this._disableNativeGesturesIfNecessary(),this._passiveListeners.push(["touchstart",t=>{const i=t.targetTouches?.[0],r=i?{x:i.clientX,y:i.clientY}:void 0;this._setupPointerExitEventsIfNeeded(),clearTimeout(this._touchstartTimeout),this._touchstartTimeout=setTimeout(()=>this.show(void 0,r),500)}])),this._addListeners(this._passiveListeners))}_setupPointerExitEventsIfNeeded(){if(this._pointerExitEventsInitialized)return;this._pointerExitEventsInitialized=!0;const t=[];if(this._platformSupportsMouseEvents())t.push(["mouseleave",i=>{const r=i.relatedTarget;(!r||!this._overlayRef?.overlayElement.contains(r))&&this.hide()}],["wheel",i=>this._wheelListener(i)]);else if("off"!==this.touchGestures){this._disableNativeGesturesIfNecessary();const i=()=>{clearTimeout(this._touchstartTimeout),this.hide(this._defaultOptions.touchendHideDelay)};t.push(["touchend",i],["touchcancel",i])}this._addListeners(t),this._passiveListeners.push(...t)}_addListeners(t){t.forEach(([i,r])=>{this._elementRef.nativeElement.addEventListener(i,r,S4)})}_platformSupportsMouseEvents(){return!this._platform.IOS&&!this._platform.ANDROID}_wheelListener(t){if(this._isTooltipVisible()){const i=this._document.elementFromPoint(t.clientX,t.clientY),r=this._elementRef.nativeElement;i!==r&&!r.contains(i)&&this.hide()}}_disableNativeGesturesIfNecessary(){const t=this.touchGestures;if("off"!==t){const i=this._elementRef.nativeElement,r=i.style;("on"===t||"INPUT"!==i.nodeName&&"TEXTAREA"!==i.nodeName)&&(r.userSelect=r.msUserSelect=r.webkitUserSelect=r.MozUserSelect="none"),("on"===t||!i.draggable)&&(r.webkitUserDrag="none"),r.touchAction="none",r.webkitTapHighlightColor="transparent"}}}return n.\u0275fac=function(t){Gl()},n.\u0275dir=ut({type:n,inputs:{position:["matTooltipPosition","position"],positionAtOrigin:["matTooltipPositionAtOrigin","positionAtOrigin"],disabled:["matTooltipDisabled","disabled"],showDelay:["matTooltipShowDelay","showDelay"],hideDelay:["matTooltipHideDelay","hideDelay"],touchGestures:["matTooltipTouchGestures","touchGestures"],message:["matTooltip","message"],tooltipClass:["matTooltipClass","tooltipClass"]}}),n})(),rA=(()=>{class n extends LX{constructor(t,i,r,s,o,a,c,u,p,g,v,y){super(t,i,r,s,o,a,c,u,p,g,v,y),this._tooltipComponent=BX,this._cssClassPrefix="mat-mdc",this._viewportMargin=8}_addOffset(t){const r=!this._dir||"ltr"==this._dir.value;return"top"===t.originY?t.offsetY=-8:"bottom"===t.originY?t.offsetY=8:"start"===t.originX?t.offsetX=r?-8:8:"end"===t.originX&&(t.offsetX=r?8:-8),t}}return n.\u0275fac=function(t){return new(t||n)(ie(hl),ie(_n),ie(qv),ie(Sa),ie(Xt),ie(as),ie(d$),ie(Vf),ie(x4),ie(Yl,8),ie(kX,8),ie(Mn))},n.\u0275dir=ut({type:n,selectors:[["","matTooltip",""]],hostAttrs:[1,"mat-mdc-tooltip-trigger"],exportAs:["matTooltip"],features:[Z]}),n})(),NX=(()=>{class n{constructor(t,i){this._changeDetectorRef=t,this._closeOnInteraction=!1,this._isVisible=!1,this._onHide=new cn,this._animationsDisabled="NoopAnimations"===i}show(t){clearTimeout(this._hideTimeoutId),this._showTimeoutId=setTimeout(()=>{this._toggleVisibility(!0),this._showTimeoutId=void 0},t)}hide(t){clearTimeout(this._showTimeoutId),this._hideTimeoutId=setTimeout(()=>{this._toggleVisibility(!1),this._hideTimeoutId=void 0},t)}afterHidden(){return this._onHide}isVisible(){return this._isVisible}ngOnDestroy(){this._cancelPendingAnimations(),this._onHide.complete(),this._triggerElement=null}_handleBodyInteraction(){this._closeOnInteraction&&this.hide(0)}_markForCheck(){this._changeDetectorRef.markForCheck()}_handleMouseLeave({relatedTarget:t}){(!t||!this._triggerElement.contains(t))&&(this.isVisible()?this.hide(this._mouseLeaveHideDelay):this._finalizeAnimation(!1))}_onShow(){}_handleAnimationEnd({animationName:t}){(t===this._showAnimation||t===this._hideAnimation)&&this._finalizeAnimation(t===this._showAnimation)}_cancelPendingAnimations(){clearTimeout(this._showTimeoutId),clearTimeout(this._hideTimeoutId),this._showTimeoutId=this._hideTimeoutId=void 0}_finalizeAnimation(t){t?this._closeOnInteraction=!0:this.isVisible()||this._onHide.next()}_toggleVisibility(t){const i=this._tooltip.nativeElement,r=this._showAnimation,s=this._hideAnimation;if(i.classList.remove(t?s:r),i.classList.add(t?r:s),this._isVisible=t,t&&!this._animationsDisabled&&"function"==typeof getComputedStyle){const o=getComputedStyle(i);("0s"===o.getPropertyValue("animation-duration")||"none"===o.getPropertyValue("animation-name"))&&(this._animationsDisabled=!0)}t&&this._onShow(),this._animationsDisabled&&(i.classList.add("_mat-animation-noopable"),this._finalizeAnimation(t))}}return n.\u0275fac=function(t){return new(t||n)(ie(aa),ie(bo,8))},n.\u0275dir=ut({type:n}),n})(),BX=(()=>{class n extends NX{constructor(t,i,r){super(t,r),this._elementRef=i,this._isMultiline=!1,this._showAnimation="mat-mdc-tooltip-show",this._hideAnimation="mat-mdc-tooltip-hide"}_onShow(){this._isMultiline=this._isTooltipMultiline(),this._markForCheck()}_isTooltipMultiline(){const t=this._elementRef.nativeElement.getBoundingClientRect();return t.height>24&&t.width>=200}}return n.\u0275fac=function(t){return new(t||n)(ie(aa),ie(_n),ie(bo,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-tooltip-component"]],viewQuery:function(t,i){if(1&t&&zr(MX,7),2&t){let r;Yn(r=Xn())&&(i._tooltip=r.first)}},hostAttrs:["aria-hidden","true"],hostVars:2,hostBindings:function(t,i){1&t&&Gn("mouseleave",function(s){return i._handleMouseLeave(s)}),2&t&&dv("zoom",i.isVisible()?1:null)},features:[Z],decls:4,vars:4,consts:[[1,"mdc-tooltip","mdc-tooltip--shown","mat-mdc-tooltip",3,"ngClass","animationend"],["tooltip",""],[1,"mdc-tooltip__surface","mdc-tooltip__surface-animation"]],template:function(t,i){1&t&&(ke(0,"div",0,1),Gn("animationend",function(s){return i._handleAnimationEnd(s)}),ke(2,"div",2),it(3),Ne()()),2&t&&(hi("mdc-tooltip--multiline",i._isMultiline),$e("ngClass",i.tooltipClass),Le(3),Hi(i.message))},dependencies:[eg],styles:['.mdc-tooltip__surface{word-break:var(--mdc-tooltip-word-break, normal);overflow-wrap:anywhere}.mdc-tooltip{position:fixed;display:none;z-index:9}.mdc-tooltip-wrapper--rich{position:relative}.mdc-tooltip--shown,.mdc-tooltip--showing,.mdc-tooltip--hide{display:inline-flex}.mdc-tooltip--shown.mdc-tooltip--rich,.mdc-tooltip--showing.mdc-tooltip--rich,.mdc-tooltip--hide.mdc-tooltip--rich{display:inline-block;left:-320px;position:absolute}.mdc-tooltip__surface{line-height:16px;padding:4px 8px;min-width:40px;max-width:200px;min-height:24px;max-height:40vh;box-sizing:border-box;overflow:hidden;text-align:center}.mdc-tooltip__surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-tooltip__surface::before{border-color:CanvasText}}.mdc-tooltip--rich .mdc-tooltip__surface{align-items:flex-start;display:flex;flex-direction:column;min-height:24px;min-width:40px;max-width:320px;position:relative}.mdc-tooltip--multiline .mdc-tooltip__surface{text-align:left}[dir=rtl] .mdc-tooltip--multiline .mdc-tooltip__surface,.mdc-tooltip--multiline .mdc-tooltip__surface[dir=rtl]{text-align:right}.mdc-tooltip__surface .mdc-tooltip__title{margin:0 8px}.mdc-tooltip__surface .mdc-tooltip__content{max-width:calc(200px - (2 * 8px));margin:8px;text-align:left}[dir=rtl] .mdc-tooltip__surface .mdc-tooltip__content,.mdc-tooltip__surface .mdc-tooltip__content[dir=rtl]{text-align:right}.mdc-tooltip--rich .mdc-tooltip__surface .mdc-tooltip__content{max-width:calc(320px - (2 * 8px));align-self:stretch}.mdc-tooltip__surface .mdc-tooltip__content-link{text-decoration:none}.mdc-tooltip--rich-actions,.mdc-tooltip__content,.mdc-tooltip__title{z-index:1}.mdc-tooltip__surface-animation{opacity:0;transform:scale(0.8);will-change:transform,opacity}.mdc-tooltip--shown .mdc-tooltip__surface-animation{transform:scale(1);opacity:1}.mdc-tooltip--hide .mdc-tooltip__surface-animation{transform:scale(1)}.mdc-tooltip__caret-surface-top,.mdc-tooltip__caret-surface-bottom{position:absolute;height:24px;width:24px;transform:rotate(35deg) skewY(20deg) scaleX(0.9396926208)}.mdc-tooltip__caret-surface-top .mdc-elevation-overlay,.mdc-tooltip__caret-surface-bottom .mdc-elevation-overlay{width:100%;height:100%;top:0;left:0}.mdc-tooltip__caret-surface-bottom{outline:1px solid rgba(0,0,0,0);z-index:-1}@media screen and (forced-colors: active){.mdc-tooltip__caret-surface-bottom{outline-color:CanvasText}}.mdc-tooltip__surface{background-color:var(--mdc-plain-tooltip-container-color, #fff)}.mdc-tooltip__surface{border-radius:var(--mdc-plain-tooltip-container-shape, var(--mdc-shape-small, 4px))}.mdc-tooltip__caret-surface-top,.mdc-tooltip__caret-surface-bottom{border-radius:var(--mdc-plain-tooltip-container-shape, var(--mdc-shape-small, 4px))}.mdc-tooltip__surface{color:var(--mdc-plain-tooltip-supporting-text-color, #000)}.mdc-tooltip__surface{font-family:var(--mdc-plain-tooltip-supporting-text-font, inherit);font-size:var(--mdc-plain-tooltip-supporting-text-size, inherit);font-weight:var(--mdc-plain-tooltip-supporting-text-weight, inherit);letter-spacing:var(--mdc-plain-tooltip-supporting-text-tracking, inherit)}.mat-mdc-tooltip{position:relative;transform:scale(0)}.mat-mdc-tooltip::before{content:"";top:-8px;right:-8px;bottom:-8px;left:-8px;z-index:-1;position:absolute}.mat-mdc-tooltip._mat-animation-noopable{animation:none;transform:scale(1)}.mat-mdc-tooltip-panel-non-interactive{pointer-events:none}@keyframes mat-mdc-tooltip-show{0%{opacity:0;transform:scale(0.8)}100%{opacity:1;transform:scale(1)}}@keyframes mat-mdc-tooltip-hide{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(0.8)}}.mat-mdc-tooltip-show{animation:mat-mdc-tooltip-show 150ms cubic-bezier(0, 0, 0.2, 1) forwards}.mat-mdc-tooltip-hide{animation:mat-mdc-tooltip-hide 75ms cubic-bezier(0.4, 0, 1, 1) forwards}'],encapsulation:2,changeDetection:0}),n})(),VX=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[TX],imports:[$L,ul,Kw,rr,rr,jw]}),n})();function E4(n){return new Ue(3e3,!1)}function bZ(){return typeof window<"u"&&typeof window.document<"u"}function sA(){return typeof process<"u"&&"[object process]"==={}.toString.call(process)}function oh(n){switch(n.length){case 0:return new Qv;case 1:return n[0];default:return new WN(n)}}function M4(n,e,t,i,r=new Map,s=new Map){const o=[],a=[];let c=-1,u=null;if(i.forEach(p=>{const g=p.get("offset"),v=g==c,y=v&&u||new Map;p.forEach((x,T)=>{let N=T,k=x;if("offset"!==T)switch(N=e.normalizePropertyName(N,o),k){case nA:k=r.get(T);break;case Ud:k=s.get(T);break;default:k=e.normalizeStyleValue(T,N,k,o)}y.set(N,k)}),v||a.push(y),u=y,c=g}),o.length)throw function cZ(n){return new Ue(3502,!1)}();return a}function oA(n,e,t,i){switch(e){case"start":n.onStart(()=>i(t&&aA(t,"start",n)));break;case"done":n.onDone(()=>i(t&&aA(t,"done",n)));break;case"destroy":n.onDestroy(()=>i(t&&aA(t,"destroy",n)))}}function aA(n,e,t){const s=cA(n.element,n.triggerName,n.fromState,n.toState,e||n.phaseName,t.totalTime??n.totalTime,!!t.disabled),o=n._data;return null!=o&&(s._data=o),s}function cA(n,e,t,i,r="",s=0,o){return{element:n,triggerName:e,fromState:t,toState:i,phaseName:r,totalTime:s,disabled:!!o}}function Qa(n,e,t){let i=n.get(e);return i||n.set(e,i=t),i}function C4(n){const e=n.indexOf(":");return[n.substring(1,e),n.slice(e+1)]}let lA=(n,e)=>!1,D4=(n,e,t)=>[],T4=null;function dA(n){const e=n.parentNode||n.host;return e===T4?null:e}(sA()||typeof Element<"u")&&(bZ()?(T4=(()=>document.documentElement)(),lA=(n,e)=>{for(;e;){if(e===n)return!0;e=dA(e)}return!1}):lA=(n,e)=>n.contains(e),D4=(n,e,t)=>{if(t)return Array.from(n.querySelectorAll(e));const i=n.querySelector(e);return i?[i]:[]});let zf=null,A4=!1;const k4=lA,I4=D4;let F4=(()=>{class n{validateStyleProperty(t){return function wZ(n){zf||(zf=function SZ(){return typeof document<"u"?document.body:null}()||{},A4=!!zf.style&&"WebkitAppearance"in zf.style);let e=!0;return zf.style&&!function xZ(n){return"ebkit"==n.substring(1,6)}(n)&&(e=n in zf.style,!e&&A4&&(e="Webkit"+n.charAt(0).toUpperCase()+n.slice(1)in zf.style)),e}(t)}matchesElement(t,i){return!1}containsElement(t,i){return k4(t,i)}getParentElement(t){return dA(t)}query(t,i,r){return I4(t,i,r)}computeStyle(t,i,r){return r||""}animate(t,i,r,s,o,a=[],c){return new Qv(r,s)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),uA=(()=>{class n{}return n.NOOP=new F4,n})();const EZ=1e3,hA="ng-enter",rS="ng-leave",sS="ng-trigger",oS=".ng-trigger",P4="ng-animating",fA=".ng-animating";function Gd(n){if("number"==typeof n)return n;const e=n.match(/^(-?[\.\d]+)(m?s)/);return!e||e.length<2?0:pA(parseFloat(e[1]),e[2])}function pA(n,e){return"s"===e?n*EZ:n}function aS(n,e,t){return n.hasOwnProperty("duration")?n:function CZ(n,e,t){let r,s=0,o="";if("string"==typeof n){const a=n.match(/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i);if(null===a)return e.push(E4()),{duration:0,delay:0,easing:""};r=pA(parseFloat(a[1]),a[2]);const c=a[3];null!=c&&(s=pA(parseFloat(c),a[4]));const u=a[5];u&&(o=u)}else r=n;if(!t){let a=!1,c=e.length;r<0&&(e.push(function HX(){return new Ue(3100,!1)}()),a=!0),s<0&&(e.push(function UX(){return new Ue(3101,!1)}()),a=!0),a&&e.splice(c,0,E4())}return{duration:r,delay:s,easing:o}}(n,e,t)}function ty(n,e={}){return Object.keys(n).forEach(t=>{e[t]=n[t]}),e}function O4(n){const e=new Map;return Object.keys(n).forEach(t=>{e.set(t,n[t])}),e}function ah(n,e=new Map,t){if(t)for(let[i,r]of t)e.set(i,r);for(let[i,r]of n)e.set(i,r);return e}function N4(n,e,t){return t?e+":"+t+";":""}function B4(n){let e="";for(let t=0;t{const s=gA(r);t&&!t.has(r)&&t.set(r,n.style[s]),n.style[s]=i}),sA()&&B4(n))}function Gf(n,e){n.style&&(e.forEach((t,i)=>{const r=gA(i);n.style[r]=""}),sA()&&B4(n))}function ny(n){return Array.isArray(n)?1==n.length?n[0]:GN(n):n}const mA=new RegExp("{{\\s*(.+?)\\s*}}","g");function V4(n){let e=[];if("string"==typeof n){let t;for(;t=mA.exec(n);)e.push(t[1]);mA.lastIndex=0}return e}function iy(n,e,t){const i=n.toString(),r=i.replace(mA,(s,o)=>{let a=e[o];return null==a&&(t.push(function GX(n){return new Ue(3003,!1)}()),a=""),a.toString()});return r==i?n:r}function cS(n){const e=[];let t=n.next();for(;!t.done;)e.push(t.value),t=n.next();return e}const AZ=/-+([a-z0-9])/g;function gA(n){return n.replace(AZ,(...e)=>e[1].toUpperCase())}function kZ(n){return n.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function ec(n,e,t){switch(e.type){case 7:return n.visitTrigger(e,t);case 0:return n.visitState(e,t);case 1:return n.visitTransition(e,t);case 2:return n.visitSequence(e,t);case 3:return n.visitGroup(e,t);case 4:return n.visitAnimate(e,t);case 5:return n.visitKeyframes(e,t);case 6:return n.visitStyle(e,t);case 8:return n.visitReference(e,t);case 9:return n.visitAnimateChild(e,t);case 10:return n.visitAnimateRef(e,t);case 11:return n.visitQuery(e,t);case 12:return n.visitStagger(e,t);default:throw function jX(n){return new Ue(3004,!1)}()}}function H4(n,e){return window.getComputedStyle(n)[e]}const uS="*";function LZ(n,e){const t=[];return"string"==typeof n?n.split(/\s*,\s*/).forEach(i=>function NZ(n,e,t){if(":"==n[0]){const c=function BZ(n,e){switch(n){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(t,i)=>parseFloat(i)>parseFloat(t);case":decrement":return(t,i)=>parseFloat(i) *"}}(n,t);if("function"==typeof c)return void e.push(c);n=c}const i=n.match(/^(\*|[-\w]+)\s*()\s*(\*|[-\w]+)$/);if(null==i||i.length<4)return t.push(function iZ(n){return new Ue(3015,!1)}()),e;const r=i[1],s=i[2],o=i[3];e.push(U4(r,o));"<"==s[0]&&!(r==uS&&o==uS)&&e.push(U4(o,r))}(i,t,e)):t.push(n),t}const hS=new Set(["true","1"]),fS=new Set(["false","0"]);function U4(n,e){const t=hS.has(n)||fS.has(n),i=hS.has(e)||fS.has(e);return(r,s)=>{let o=n==uS||n==r,a=e==uS||e==s;return!o&&t&&"boolean"==typeof r&&(o=r?hS.has(n):fS.has(n)),!a&&i&&"boolean"==typeof s&&(a=s?hS.has(e):fS.has(e)),o&&a}}const VZ=new RegExp("s*:selfs*,?","g");function _A(n,e,t,i){return new HZ(n).build(e,t,i)}class HZ{constructor(e){this._driver=e}build(e,t,i){const r=new GZ(t);return this._resetContextStyleTimingState(r),ec(this,ny(e),r)}_resetContextStyleTimingState(e){e.currentQuerySelector="",e.collectedStyles=new Map,e.collectedStyles.set("",new Map),e.currentTime=0}visitTrigger(e,t){let i=t.queryCount=0,r=t.depCount=0;const s=[],o=[];return"@"==e.name.charAt(0)&&t.errors.push(function $X(){return new Ue(3006,!1)}()),e.definitions.forEach(a=>{if(this._resetContextStyleTimingState(t),0==a.type){const c=a,u=c.name;u.toString().split(/\s*,\s*/).forEach(p=>{c.name=p,s.push(this.visitState(c,t))}),c.name=u}else if(1==a.type){const c=this.visitTransition(a,t);i+=c.queryCount,r+=c.depCount,o.push(c)}else t.errors.push(function qX(){return new Ue(3007,!1)}())}),{type:7,name:e.name,states:s,transitions:o,queryCount:i,depCount:r,options:null}}visitState(e,t){const i=this.visitStyle(e.styles,t),r=e.options&&e.options.params||null;if(i.containsDynamicStyles){const s=new Set,o=r||{};i.styles.forEach(a=>{a instanceof Map&&a.forEach(c=>{V4(c).forEach(u=>{o.hasOwnProperty(u)||s.add(u)})})}),s.size&&(cS(s.values()),t.errors.push(function KX(n,e){return new Ue(3008,!1)}()))}return{type:0,name:e.name,style:i,options:r?{params:r}:null}}visitTransition(e,t){t.queryCount=0,t.depCount=0;const i=ec(this,ny(e.animation),t);return{type:1,matchers:LZ(e.expr,t.errors),animation:i,queryCount:t.queryCount,depCount:t.depCount,options:jf(e.options)}}visitSequence(e,t){return{type:2,steps:e.steps.map(i=>ec(this,i,t)),options:jf(e.options)}}visitGroup(e,t){const i=t.currentTime;let r=0;const s=e.steps.map(o=>{t.currentTime=i;const a=ec(this,o,t);return r=Math.max(r,t.currentTime),a});return t.currentTime=r,{type:3,steps:s,options:jf(e.options)}}visitAnimate(e,t){const i=function WZ(n,e){if(n.hasOwnProperty("duration"))return n;if("number"==typeof n)return vA(aS(n,e).duration,0,"");const t=n;if(t.split(/\s+/).some(s=>"{"==s.charAt(0)&&"{"==s.charAt(1))){const s=vA(0,0,"");return s.dynamic=!0,s.strValue=t,s}const r=aS(t,e);return vA(r.duration,r.delay,r.easing)}(e.timings,t.errors);t.currentAnimateTimings=i;let r,s=e.styles?e.styles:la({});if(5==s.type)r=this.visitKeyframes(s,t);else{let o=e.styles,a=!1;if(!o){a=!0;const u={};i.easing&&(u.easing=i.easing),o=la(u)}t.currentTime+=i.duration+i.delay;const c=this.visitStyle(o,t);c.isEmptyStep=a,r=c}return t.currentAnimateTimings=null,{type:4,timings:i,style:r,options:null}}visitStyle(e,t){const i=this._makeStyleAst(e,t);return this._validateStyleAst(i,t),i}_makeStyleAst(e,t){const i=[],r=Array.isArray(e.styles)?e.styles:[e.styles];for(let a of r)"string"==typeof a?a===Ud?i.push(a):t.errors.push(new Ue(3002,!1)):i.push(O4(a));let s=!1,o=null;return i.forEach(a=>{if(a instanceof Map&&(a.has("easing")&&(o=a.get("easing"),a.delete("easing")),!s))for(let c of a.values())if(c.toString().indexOf("{{")>=0){s=!0;break}}),{type:6,styles:i,easing:o,offset:e.offset,containsDynamicStyles:s,options:null}}_validateStyleAst(e,t){const i=t.currentAnimateTimings;let r=t.currentTime,s=t.currentTime;i&&s>0&&(s-=i.duration+i.delay),e.styles.forEach(o=>{"string"!=typeof o&&o.forEach((a,c)=>{const u=t.collectedStyles.get(t.currentQuerySelector),p=u.get(c);let g=!0;p&&(s!=r&&s>=p.startTime&&r<=p.endTime&&(t.errors.push(function XX(n,e,t,i,r){return new Ue(3010,!1)}()),g=!1),s=p.startTime),g&&u.set(c,{startTime:s,endTime:r}),t.options&&function TZ(n,e,t){const i=e.params||{},r=V4(n);r.length&&r.forEach(s=>{i.hasOwnProperty(s)||t.push(function zX(n){return new Ue(3001,!1)}())})}(a,t.options,t.errors)})})}visitKeyframes(e,t){const i={type:5,styles:[],options:null};if(!t.currentAnimateTimings)return t.errors.push(function ZX(){return new Ue(3011,!1)}()),i;let s=0;const o=[];let a=!1,c=!1,u=0;const p=e.steps.map(k=>{const A=this._makeStyleAst(k,t);let H=null!=A.offset?A.offset:function jZ(n){if("string"==typeof n)return null;let e=null;if(Array.isArray(n))n.forEach(t=>{if(t instanceof Map&&t.has("offset")){const i=t;e=parseFloat(i.get("offset")),i.delete("offset")}});else if(n instanceof Map&&n.has("offset")){const t=n;e=parseFloat(t.get("offset")),t.delete("offset")}return e}(A.styles),G=0;return null!=H&&(s++,G=A.offset=H),c=c||G<0||G>1,a=a||G0&&s{const H=v>0?A==y?1:v*A:o[A],G=H*N;t.currentTime=x+T.delay+G,T.duration=G,this._validateStyleAst(k,t),k.offset=H,i.styles.push(k)}),i}visitReference(e,t){return{type:8,animation:ec(this,ny(e.animation),t),options:jf(e.options)}}visitAnimateChild(e,t){return t.depCount++,{type:9,options:jf(e.options)}}visitAnimateRef(e,t){return{type:10,animation:this.visitReference(e.animation,t),options:jf(e.options)}}visitQuery(e,t){const i=t.currentQuerySelector,r=e.options||{};t.queryCount++,t.currentQuery=e;const[s,o]=function UZ(n){const e=!!n.split(/\s*,\s*/).find(t=>":self"==t);return e&&(n=n.replace(VZ,"")),n=n.replace(/@\*/g,oS).replace(/@\w+/g,t=>oS+"-"+t.slice(1)).replace(/:animating/g,fA),[n,e]}(e.selector);t.currentQuerySelector=i.length?i+" "+s:s,Qa(t.collectedStyles,t.currentQuerySelector,new Map);const a=ec(this,ny(e.animation),t);return t.currentQuery=null,t.currentQuerySelector=i,{type:11,selector:s,limit:r.limit||0,optional:!!r.optional,includeSelf:o,animation:a,originalSelector:e.selector,options:jf(e.options)}}visitStagger(e,t){t.currentQuery||t.errors.push(function tZ(){return new Ue(3013,!1)}());const i="full"===e.timings?{duration:0,delay:0,easing:"full"}:aS(e.timings,t.errors,!0);return{type:12,animation:ec(this,ny(e.animation),t),timings:i,options:null}}}class GZ{constructor(e){this.errors=e,this.queryCount=0,this.depCount=0,this.currentTransition=null,this.currentQuery=null,this.currentQuerySelector=null,this.currentAnimateTimings=null,this.currentTime=0,this.collectedStyles=new Map,this.options=null,this.unsupportedCSSPropertiesFound=new Set}}function jf(n){return n?(n=ty(n)).params&&(n.params=function zZ(n){return n?ty(n):null}(n.params)):n={},n}function vA(n,e,t){return{duration:n,delay:e,easing:t}}function yA(n,e,t,i,r,s,o=null,a=!1){return{type:1,element:n,keyframes:e,preStyleProps:t,postStyleProps:i,duration:r,delay:s,totalTime:r+s,easing:o,subTimeline:a}}class pS{constructor(){this._map=new Map}get(e){return this._map.get(e)||[]}append(e,t){let i=this._map.get(e);i||this._map.set(e,i=[]),i.push(...t)}has(e){return this._map.has(e)}clear(){this._map.clear()}}const KZ=new RegExp(":enter","g"),XZ=new RegExp(":leave","g");function bA(n,e,t,i,r,s=new Map,o=new Map,a,c,u=[]){return(new ZZ).buildKeyframes(n,e,t,i,r,s,o,a,c,u)}class ZZ{buildKeyframes(e,t,i,r,s,o,a,c,u,p=[]){u=u||new pS;const g=new xA(e,t,u,r,s,p,[]);g.options=c;const v=c.delay?Gd(c.delay):0;g.currentTimeline.delayNextStep(v),g.currentTimeline.setStyles([o],null,g.errors,c),ec(this,i,g);const y=g.timelines.filter(x=>x.containsAnimation());if(y.length&&a.size){let x;for(let T=y.length-1;T>=0;T--){const N=y[T];if(N.element===t){x=N;break}}x&&!x.allowOnlyTimelineStyles()&&x.setStyles([a],null,g.errors,c)}return y.length?y.map(x=>x.buildKeyframes()):[yA(t,[],[],[],0,v,"",!1)]}visitTrigger(e,t){}visitState(e,t){}visitTransition(e,t){}visitAnimateChild(e,t){const i=t.subInstructions.get(t.element);if(i){const r=t.createSubContext(e.options),s=t.currentTimeline.currentTime,o=this._visitSubInstructions(i,r,r.options);s!=o&&t.transformIntoNewTimeline(o)}t.previousNode=e}visitAnimateRef(e,t){const i=t.createSubContext(e.options);i.transformIntoNewTimeline(),this._applyAnimationRefDelays([e.options,e.animation.options],t,i),this.visitReference(e.animation,i),t.transformIntoNewTimeline(i.currentTimeline.currentTime),t.previousNode=e}_applyAnimationRefDelays(e,t,i){for(const r of e){const s=r?.delay;if(s){const o="number"==typeof s?s:Gd(iy(s,r?.params??{},t.errors));i.delayNextStep(o)}}}_visitSubInstructions(e,t,i){let s=t.currentTimeline.currentTime;const o=null!=i.duration?Gd(i.duration):null,a=null!=i.delay?Gd(i.delay):null;return 0!==o&&e.forEach(c=>{const u=t.appendInstructionToTimeline(c,o,a);s=Math.max(s,u.duration+u.delay)}),s}visitReference(e,t){t.updateOptions(e.options,!0),ec(this,e.animation,t),t.previousNode=e}visitSequence(e,t){const i=t.subContextCount;let r=t;const s=e.options;if(s&&(s.params||s.delay)&&(r=t.createSubContext(s),r.transformIntoNewTimeline(),null!=s.delay)){6==r.previousNode.type&&(r.currentTimeline.snapshotCurrentStyles(),r.previousNode=mS);const o=Gd(s.delay);r.delayNextStep(o)}e.steps.length&&(e.steps.forEach(o=>ec(this,o,r)),r.currentTimeline.applyStylesToKeyframe(),r.subContextCount>i&&r.transformIntoNewTimeline()),t.previousNode=e}visitGroup(e,t){const i=[];let r=t.currentTimeline.currentTime;const s=e.options&&e.options.delay?Gd(e.options.delay):0;e.steps.forEach(o=>{const a=t.createSubContext(e.options);s&&a.delayNextStep(s),ec(this,o,a),r=Math.max(r,a.currentTimeline.currentTime),i.push(a.currentTimeline)}),i.forEach(o=>t.currentTimeline.mergeTimelineCollectedStyles(o)),t.transformIntoNewTimeline(r),t.previousNode=e}_visitTiming(e,t){if(e.dynamic){const i=e.strValue;return aS(t.params?iy(i,t.params,t.errors):i,t.errors)}return{duration:e.duration,delay:e.delay,easing:e.easing}}visitAnimate(e,t){const i=t.currentAnimateTimings=this._visitTiming(e.timings,t),r=t.currentTimeline;i.delay&&(t.incrementTime(i.delay),r.snapshotCurrentStyles());const s=e.style;5==s.type?this.visitKeyframes(s,t):(t.incrementTime(i.duration),this.visitStyle(s,t),r.applyStylesToKeyframe()),t.currentAnimateTimings=null,t.previousNode=e}visitStyle(e,t){const i=t.currentTimeline,r=t.currentAnimateTimings;!r&&i.hasCurrentStyleProperties()&&i.forwardFrame();const s=r&&r.easing||e.easing;e.isEmptyStep?i.applyEmptyStep(s):i.setStyles(e.styles,s,t.errors,t.options),t.previousNode=e}visitKeyframes(e,t){const i=t.currentAnimateTimings,r=t.currentTimeline.duration,s=i.duration,a=t.createSubContext().currentTimeline;a.easing=i.easing,e.styles.forEach(c=>{a.forwardTime((c.offset||0)*s),a.setStyles(c.styles,c.easing,t.errors,t.options),a.applyStylesToKeyframe()}),t.currentTimeline.mergeTimelineCollectedStyles(a),t.transformIntoNewTimeline(r+s),t.previousNode=e}visitQuery(e,t){const i=t.currentTimeline.currentTime,r=e.options||{},s=r.delay?Gd(r.delay):0;s&&(6===t.previousNode.type||0==i&&t.currentTimeline.hasCurrentStyleProperties())&&(t.currentTimeline.snapshotCurrentStyles(),t.previousNode=mS);let o=i;const a=t.invokeQuery(e.selector,e.originalSelector,e.limit,e.includeSelf,!!r.optional,t.errors);t.currentQueryTotal=a.length;let c=null;a.forEach((u,p)=>{t.currentQueryIndex=p;const g=t.createSubContext(e.options,u);s&&g.delayNextStep(s),u===t.element&&(c=g.currentTimeline),ec(this,e.animation,g),g.currentTimeline.applyStylesToKeyframe(),o=Math.max(o,g.currentTimeline.currentTime)}),t.currentQueryIndex=0,t.currentQueryTotal=0,t.transformIntoNewTimeline(o),c&&(t.currentTimeline.mergeTimelineCollectedStyles(c),t.currentTimeline.snapshotCurrentStyles()),t.previousNode=e}visitStagger(e,t){const i=t.parentContext,r=t.currentTimeline,s=e.timings,o=Math.abs(s.duration),a=o*(t.currentQueryTotal-1);let c=o*t.currentQueryIndex;switch(s.duration<0?"reverse":s.easing){case"reverse":c=a-c;break;case"full":c=i.currentStaggerTime}const p=t.currentTimeline;c&&p.delayNextStep(c);const g=p.currentTime;ec(this,e.animation,t),t.previousNode=e,i.currentStaggerTime=r.currentTime-g+(r.startTime-i.currentTimeline.startTime)}}const mS={};class xA{constructor(e,t,i,r,s,o,a,c){this._driver=e,this.element=t,this.subInstructions=i,this._enterClassName=r,this._leaveClassName=s,this.errors=o,this.timelines=a,this.parentContext=null,this.currentAnimateTimings=null,this.previousNode=mS,this.subContextCount=0,this.options={},this.currentQueryIndex=0,this.currentQueryTotal=0,this.currentStaggerTime=0,this.currentTimeline=c||new gS(this._driver,t,0),a.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(e,t){if(!e)return;const i=e;let r=this.options;null!=i.duration&&(r.duration=Gd(i.duration)),null!=i.delay&&(r.delay=Gd(i.delay));const s=i.params;if(s){let o=r.params;o||(o=this.options.params={}),Object.keys(s).forEach(a=>{(!t||!o.hasOwnProperty(a))&&(o[a]=iy(s[a],o,this.errors))})}}_copyOptions(){const e={};if(this.options){const t=this.options.params;if(t){const i=e.params={};Object.keys(t).forEach(r=>{i[r]=t[r]})}}return e}createSubContext(e=null,t,i){const r=t||this.element,s=new xA(this._driver,r,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(r,i||0));return s.previousNode=this.previousNode,s.currentAnimateTimings=this.currentAnimateTimings,s.options=this._copyOptions(),s.updateOptions(e),s.currentQueryIndex=this.currentQueryIndex,s.currentQueryTotal=this.currentQueryTotal,s.parentContext=this,this.subContextCount++,s}transformIntoNewTimeline(e){return this.previousNode=mS,this.currentTimeline=this.currentTimeline.fork(this.element,e),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(e,t,i){const r={duration:t??e.duration,delay:this.currentTimeline.currentTime+(i??0)+e.delay,easing:""},s=new JZ(this._driver,e.element,e.keyframes,e.preStyleProps,e.postStyleProps,r,e.stretchStartingKeyframe);return this.timelines.push(s),r}incrementTime(e){this.currentTimeline.forwardTime(this.currentTimeline.duration+e)}delayNextStep(e){e>0&&this.currentTimeline.delayNextStep(e)}invokeQuery(e,t,i,r,s,o){let a=[];if(r&&a.push(this.element),e.length>0){e=(e=e.replace(KZ,"."+this._enterClassName)).replace(XZ,"."+this._leaveClassName);let u=this._driver.query(this.element,e,1!=i);0!==i&&(u=i<0?u.slice(u.length+i,u.length):u.slice(0,i)),a.push(...u)}return!s&&0==a.length&&o.push(function nZ(n){return new Ue(3014,!1)}()),a}}class gS{constructor(e,t,i,r){this._driver=e,this.element=t,this.startTime=i,this._elementTimelineStylesLookup=r,this.duration=0,this._previousKeyframe=new Map,this._currentKeyframe=new Map,this._keyframes=new Map,this._styleSummary=new Map,this._localTimelineStyles=new Map,this._pendingStyles=new Map,this._backFill=new Map,this._currentEmptyStepKeyframe=null,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(t),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(t,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.hasCurrentStyleProperties();default:return!0}}hasCurrentStyleProperties(){return this._currentKeyframe.size>0}get currentTime(){return this.startTime+this.duration}delayNextStep(e){const t=1===this._keyframes.size&&this._pendingStyles.size;this.duration||t?(this.forwardTime(this.currentTime+e),t&&this.snapshotCurrentStyles()):this.startTime+=e}fork(e,t){return this.applyStylesToKeyframe(),new gS(this._driver,e,t||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=new Map,this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=1,this._loadKeyframe()}forwardTime(e){this.applyStylesToKeyframe(),this.duration=e,this._loadKeyframe()}_updateStyle(e,t){this._localTimelineStyles.set(e,t),this._globalTimelineStyles.set(e,t),this._styleSummary.set(e,{time:this.currentTime,value:t})}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(e){e&&this._previousKeyframe.set("easing",e);for(let[t,i]of this._globalTimelineStyles)this._backFill.set(t,i||Ud),this._currentKeyframe.set(t,Ud);this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(e,t,i,r){t&&this._previousKeyframe.set("easing",t);const s=r&&r.params||{},o=function QZ(n,e){const t=new Map;let i;return n.forEach(r=>{if("*"===r){i=i||e.keys();for(let s of i)t.set(s,Ud)}else ah(r,t)}),t}(e,this._globalTimelineStyles);for(let[a,c]of o){const u=iy(c,s,i);this._pendingStyles.set(a,u),this._localTimelineStyles.has(a)||this._backFill.set(a,this._globalTimelineStyles.get(a)??Ud),this._updateStyle(a,u)}}applyStylesToKeyframe(){0!=this._pendingStyles.size&&(this._pendingStyles.forEach((e,t)=>{this._currentKeyframe.set(t,e)}),this._pendingStyles.clear(),this._localTimelineStyles.forEach((e,t)=>{this._currentKeyframe.has(t)||this._currentKeyframe.set(t,e)}))}snapshotCurrentStyles(){for(let[e,t]of this._localTimelineStyles)this._pendingStyles.set(e,t),this._updateStyle(e,t)}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){const e=[];for(let t in this._currentKeyframe)e.push(t);return e}mergeTimelineCollectedStyles(e){e._styleSummary.forEach((t,i)=>{const r=this._styleSummary.get(i);(!r||t.time>r.time)&&this._updateStyle(i,t.value)})}buildKeyframes(){this.applyStylesToKeyframe();const e=new Set,t=new Set,i=1===this._keyframes.size&&0===this.duration;let r=[];this._keyframes.forEach((a,c)=>{const u=ah(a,new Map,this._backFill);u.forEach((p,g)=>{p===nA?e.add(g):p===Ud&&t.add(g)}),i||u.set("offset",c/this.duration),r.push(u)});const s=e.size?cS(e.values()):[],o=t.size?cS(t.values()):[];if(i){const a=r[0],c=new Map(a);a.set("offset",0),c.set("offset",1),r=[a,c]}return yA(this.element,r,s,o,this.duration,this.startTime,this.easing,!1)}}class JZ extends gS{constructor(e,t,i,r,s,o,a=!1){super(e,t,o.delay),this.keyframes=i,this.preStyleProps=r,this.postStyleProps=s,this._stretchStartingKeyframe=a,this.timings={duration:o.duration,delay:o.delay,easing:o.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let e=this.keyframes,{delay:t,duration:i,easing:r}=this.timings;if(this._stretchStartingKeyframe&&t){const s=[],o=i+t,a=t/o,c=ah(e[0]);c.set("offset",0),s.push(c);const u=ah(e[0]);u.set("offset",j4(a)),s.push(u);const p=e.length-1;for(let g=1;g<=p;g++){let v=ah(e[g]);const y=v.get("offset");v.set("offset",j4((t+y*i)/o)),s.push(v)}i=o,t=0,r="",e=s}return yA(this.element,e,this.preStyleProps,this.postStyleProps,i,t,r,!0)}}function j4(n,e=3){const t=Math.pow(10,e-1);return Math.round(n*t)/t}class wA{}const eJ=new Set(["width","height","minWidth","minHeight","maxWidth","maxHeight","left","top","bottom","right","fontSize","outlineWidth","outlineOffset","paddingTop","paddingLeft","paddingBottom","paddingRight","marginTop","marginLeft","marginBottom","marginRight","borderRadius","borderWidth","borderTopWidth","borderLeftWidth","borderRightWidth","borderBottomWidth","textIndent","perspective"]);class tJ extends wA{normalizePropertyName(e,t){return gA(e)}normalizeStyleValue(e,t,i,r){let s="";const o=i.toString().trim();if(eJ.has(t)&&0!==i&&"0"!==i)if("number"==typeof i)s="px";else{const a=i.match(/^[+-]?[\d\.]+([a-z]*)$/);a&&0==a[1].length&&r.push(function WX(n,e){return new Ue(3005,!1)}())}return o+s}}function W4(n,e,t,i,r,s,o,a,c,u,p,g,v){return{type:0,element:n,triggerName:e,isRemovalTransition:r,fromState:t,fromStyles:s,toState:i,toStyles:o,timelines:a,queriedElements:c,preStyleProps:u,postStyleProps:p,totalTime:g,errors:v}}const SA={};class $4{constructor(e,t,i){this._triggerName=e,this.ast=t,this._stateStyles=i}match(e,t,i,r){return function nJ(n,e,t,i,r){return n.some(s=>s(e,t,i,r))}(this.ast.matchers,e,t,i,r)}buildStyles(e,t,i){let r=this._stateStyles.get("*");return void 0!==e&&(r=this._stateStyles.get(e?.toString())||r),r?r.buildStyles(t,i):new Map}build(e,t,i,r,s,o,a,c,u,p){const g=[],v=this.ast.options&&this.ast.options.params||SA,x=this.buildStyles(i,a&&a.params||SA,g),T=c&&c.params||SA,N=this.buildStyles(r,T,g),k=new Set,A=new Map,H=new Map,G="void"===r,X={params:iJ(T,v),delay:this.ast.options?.delay},se=p?[]:bA(e,t,this.ast.animation,s,o,x,N,X,u,g);let K=0;if(se.forEach(De=>{K=Math.max(De.duration+De.delay,K)}),g.length)return W4(t,this._triggerName,i,r,G,x,N,[],[],A,H,K,g);se.forEach(De=>{const Te=De.element,ge=Qa(A,Te,new Set);De.preStyleProps.forEach(Pe=>ge.add(Pe));const Qe=Qa(H,Te,new Set);De.postStyleProps.forEach(Pe=>Qe.add(Pe)),Te!==t&&k.add(Te)});const he=cS(k.values());return W4(t,this._triggerName,i,r,G,x,N,se,he,A,H,K)}}function iJ(n,e){const t=ty(e);for(const i in n)n.hasOwnProperty(i)&&null!=n[i]&&(t[i]=n[i]);return t}class rJ{constructor(e,t,i){this.styles=e,this.defaultParams=t,this.normalizer=i}buildStyles(e,t){const i=new Map,r=ty(this.defaultParams);return Object.keys(e).forEach(s=>{const o=e[s];null!==o&&(r[s]=o)}),this.styles.styles.forEach(s=>{"string"!=typeof s&&s.forEach((o,a)=>{o&&(o=iy(o,r,t));const c=this.normalizer.normalizePropertyName(a,t);o=this.normalizer.normalizeStyleValue(a,c,o,t),i.set(a,o)})}),i}}class oJ{constructor(e,t,i){this.name=e,this.ast=t,this._normalizer=i,this.transitionFactories=[],this.states=new Map,t.states.forEach(r=>{this.states.set(r.name,new rJ(r.style,r.options&&r.options.params||{},i))}),q4(this.states,"true","1"),q4(this.states,"false","0"),t.transitions.forEach(r=>{this.transitionFactories.push(new $4(e,r,this.states))}),this.fallbackTransition=function aJ(n,e,t){return new $4(n,{type:1,animation:{type:2,steps:[],options:null},matchers:[(o,a)=>!0],options:null,queryCount:0,depCount:0},e)}(e,this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(e,t,i,r){return this.transitionFactories.find(o=>o.match(e,t,i,r))||null}matchStyles(e,t,i){return this.fallbackTransition.buildStyles(e,t,i)}}function q4(n,e,t){n.has(e)?n.has(t)||n.set(t,n.get(e)):n.has(t)&&n.set(e,n.get(t))}const cJ=new pS;class lJ{constructor(e,t,i){this.bodyNode=e,this._driver=t,this._normalizer=i,this._animations=new Map,this._playersById=new Map,this.players=[]}register(e,t){const i=[],r=[],s=_A(this._driver,t,i,r);if(i.length)throw function lZ(n){return new Ue(3503,!1)}();this._animations.set(e,s)}_buildPlayer(e,t,i){const r=e.element,s=M4(0,this._normalizer,0,e.keyframes,t,i);return this._driver.animate(r,s,e.duration,e.delay,e.easing,[],!0)}create(e,t,i={}){const r=[],s=this._animations.get(e);let o;const a=new Map;if(s?(o=bA(this._driver,t,s,hA,rS,new Map,new Map,i,cJ,r),o.forEach(p=>{const g=Qa(a,p.element,new Map);p.postStyleProps.forEach(v=>g.set(v,null))})):(r.push(function dZ(){return new Ue(3300,!1)}()),o=[]),r.length)throw function uZ(n){return new Ue(3504,!1)}();a.forEach((p,g)=>{p.forEach((v,y)=>{p.set(y,this._driver.computeStyle(g,y,Ud))})});const u=oh(o.map(p=>{const g=a.get(p.element);return this._buildPlayer(p,new Map,g)}));return this._playersById.set(e,u),u.onDestroy(()=>this.destroy(e)),this.players.push(u),u}destroy(e){const t=this._getPlayer(e);t.destroy(),this._playersById.delete(e);const i=this.players.indexOf(t);i>=0&&this.players.splice(i,1)}_getPlayer(e){const t=this._playersById.get(e);if(!t)throw function hZ(n){return new Ue(3301,!1)}();return t}listen(e,t,i,r){const s=cA(t,"","","");return oA(this._getPlayer(e),i,s,r),()=>{}}command(e,t,i,r){if("register"==i)return void this.register(e,r[0]);if("create"==i)return void this.create(e,t,r[0]||{});const s=this._getPlayer(e);switch(i){case"play":s.play();break;case"pause":s.pause();break;case"reset":s.reset();break;case"restart":s.restart();break;case"finish":s.finish();break;case"init":s.init();break;case"setPosition":s.setPosition(parseFloat(r[0]));break;case"destroy":this.destroy(e)}}}const K4="ng-animate-queued",EA="ng-animate-disabled",pJ=[],Y4={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},mJ={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},Oc="__ng_removed";class MA{get params(){return this.options.params}constructor(e,t=""){this.namespaceId=t;const i=e&&e.hasOwnProperty("value");if(this.value=function yJ(n){return n??null}(i?e.value:e),i){const s=ty(e);delete s.value,this.options=s}else this.options={};this.options.params||(this.options.params={})}absorbOptions(e){const t=e.params;if(t){const i=this.options.params;Object.keys(t).forEach(r=>{null==i[r]&&(i[r]=t[r])})}}}const ry="void",CA=new MA(ry);class gJ{constructor(e,t,i){this.id=e,this.hostElement=t,this._engine=i,this.players=[],this._triggers=new Map,this._queue=[],this._elementListeners=new Map,this._hostClassName="ng-tns-"+e,Lc(t,this._hostClassName)}listen(e,t,i,r){if(!this._triggers.has(t))throw function fZ(n,e){return new Ue(3302,!1)}();if(null==i||0==i.length)throw function pZ(n){return new Ue(3303,!1)}();if(!function bJ(n){return"start"==n||"done"==n}(i))throw function mZ(n,e){return new Ue(3400,!1)}();const s=Qa(this._elementListeners,e,[]),o={name:t,phase:i,callback:r};s.push(o);const a=Qa(this._engine.statesByElement,e,new Map);return a.has(t)||(Lc(e,sS),Lc(e,sS+"-"+t),a.set(t,CA)),()=>{this._engine.afterFlush(()=>{const c=s.indexOf(o);c>=0&&s.splice(c,1),this._triggers.has(t)||a.delete(t)})}}register(e,t){return!this._triggers.has(e)&&(this._triggers.set(e,t),!0)}_getTrigger(e){const t=this._triggers.get(e);if(!t)throw function gZ(n){return new Ue(3401,!1)}();return t}trigger(e,t,i,r=!0){const s=this._getTrigger(t),o=new DA(this.id,t,e);let a=this._engine.statesByElement.get(e);a||(Lc(e,sS),Lc(e,sS+"-"+t),this._engine.statesByElement.set(e,a=new Map));let c=a.get(t);const u=new MA(i,this.id);if(!(i&&i.hasOwnProperty("value"))&&c&&u.absorbOptions(c.options),a.set(t,u),c||(c=CA),u.value!==ry&&c.value===u.value){if(!function SJ(n,e){const t=Object.keys(n),i=Object.keys(e);if(t.length!=i.length)return!1;for(let r=0;r{Gf(e,N),Zl(e,k)})}return}const v=Qa(this._engine.playersByElement,e,[]);v.forEach(T=>{T.namespaceId==this.id&&T.triggerName==t&&T.queued&&T.destroy()});let y=s.matchTransition(c.value,u.value,e,u.params),x=!1;if(!y){if(!r)return;y=s.fallbackTransition,x=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:t,transition:y,fromState:c,toState:u,player:o,isFallbackTransition:x}),x||(Lc(e,K4),o.onStart(()=>{pg(e,K4)})),o.onDone(()=>{let T=this.players.indexOf(o);T>=0&&this.players.splice(T,1);const N=this._engine.playersByElement.get(e);if(N){let k=N.indexOf(o);k>=0&&N.splice(k,1)}}),this.players.push(o),v.push(o),o}deregister(e){this._triggers.delete(e),this._engine.statesByElement.forEach(t=>t.delete(e)),this._elementListeners.forEach((t,i)=>{this._elementListeners.set(i,t.filter(r=>r.name!=e))})}clearElementCache(e){this._engine.statesByElement.delete(e),this._elementListeners.delete(e);const t=this._engine.playersByElement.get(e);t&&(t.forEach(i=>i.destroy()),this._engine.playersByElement.delete(e))}_signalRemovalForInnerTriggers(e,t){const i=this._engine.driver.query(e,oS,!0);i.forEach(r=>{if(r[Oc])return;const s=this._engine.fetchNamespacesByElement(r);s.size?s.forEach(o=>o.triggerLeaveAnimation(r,t,!1,!0)):this.clearElementCache(r)}),this._engine.afterFlushAnimationsDone(()=>i.forEach(r=>this.clearElementCache(r)))}triggerLeaveAnimation(e,t,i,r){const s=this._engine.statesByElement.get(e),o=new Map;if(s){const a=[];if(s.forEach((c,u)=>{if(o.set(u,c.value),this._triggers.has(u)){const p=this.trigger(e,u,ry,r);p&&a.push(p)}}),a.length)return this._engine.markElementAsRemoved(this.id,e,!0,t,o),i&&oh(a).onDone(()=>this._engine.processLeaveNode(e)),!0}return!1}prepareLeaveAnimationListeners(e){const t=this._elementListeners.get(e),i=this._engine.statesByElement.get(e);if(t&&i){const r=new Set;t.forEach(s=>{const o=s.name;if(r.has(o))return;r.add(o);const c=this._triggers.get(o).fallbackTransition,u=i.get(o)||CA,p=new MA(ry),g=new DA(this.id,o,e);this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:o,transition:c,fromState:u,toState:p,player:g,isFallbackTransition:!0})})}}removeNode(e,t){const i=this._engine;if(e.childElementCount&&this._signalRemovalForInnerTriggers(e,t),this.triggerLeaveAnimation(e,t,!0))return;let r=!1;if(i.totalAnimations){const s=i.players.length?i.playersByQueriedElement.get(e):[];if(s&&s.length)r=!0;else{let o=e;for(;o=o.parentNode;)if(i.statesByElement.get(o)){r=!0;break}}}if(this.prepareLeaveAnimationListeners(e),r)i.markElementAsRemoved(this.id,e,!1,t);else{const s=e[Oc];(!s||s===Y4)&&(i.afterFlush(()=>this.clearElementCache(e)),i.destroyInnerAnimations(e),i._onRemovalComplete(e,t))}}insertNode(e,t){Lc(e,this._hostClassName)}drainQueuedTransitions(e){const t=[];return this._queue.forEach(i=>{const r=i.player;if(r.destroyed)return;const s=i.element,o=this._elementListeners.get(s);o&&o.forEach(a=>{if(a.name==i.triggerName){const c=cA(s,i.triggerName,i.fromState.value,i.toState.value);c._data=e,oA(i.player,a.phase,c,a.callback)}}),r.markedForDestroy?this._engine.afterFlush(()=>{r.destroy()}):t.push(i)}),this._queue=[],t.sort((i,r)=>{const s=i.transition.ast.depCount,o=r.transition.ast.depCount;return 0==s||0==o?s-o:this._engine.driver.containsElement(i.element,r.element)?1:-1})}destroy(e){this.players.forEach(t=>t.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,e)}elementContainsData(e){let t=!1;return this._elementListeners.has(e)&&(t=!0),t=!!this._queue.find(i=>i.element===e)||t,t}}class _J{_onRemovalComplete(e,t){this.onRemovalComplete(e,t)}constructor(e,t,i){this.bodyNode=e,this.driver=t,this._normalizer=i,this.players=[],this.newHostElements=new Map,this.playersByElement=new Map,this.playersByQueriedElement=new Map,this.statesByElement=new Map,this.disabledNodes=new Set,this.totalAnimations=0,this.totalQueuedPlayers=0,this._namespaceLookup={},this._namespaceList=[],this._flushFns=[],this._whenQuietFns=[],this.namespacesByHostElement=new Map,this.collectedEnterElements=[],this.collectedLeaveElements=[],this.onRemovalComplete=(r,s)=>{}}get queuedPlayers(){const e=[];return this._namespaceList.forEach(t=>{t.players.forEach(i=>{i.queued&&e.push(i)})}),e}createNamespace(e,t){const i=new gJ(e,t,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,t)?this._balanceNamespaceList(i,t):(this.newHostElements.set(t,i),this.collectEnterElement(t)),this._namespaceLookup[e]=i}_balanceNamespaceList(e,t){const i=this._namespaceList,r=this.namespacesByHostElement;if(i.length-1>=0){let o=!1,a=this.driver.getParentElement(t);for(;a;){const c=r.get(a);if(c){const u=i.indexOf(c);i.splice(u+1,0,e),o=!0;break}a=this.driver.getParentElement(a)}o||i.unshift(e)}else i.push(e);return r.set(t,e),e}register(e,t){let i=this._namespaceLookup[e];return i||(i=this.createNamespace(e,t)),i}registerTrigger(e,t,i){let r=this._namespaceLookup[e];r&&r.register(t,i)&&this.totalAnimations++}destroy(e,t){if(!e)return;const i=this._fetchNamespace(e);this.afterFlush(()=>{this.namespacesByHostElement.delete(i.hostElement),delete this._namespaceLookup[e];const r=this._namespaceList.indexOf(i);r>=0&&this._namespaceList.splice(r,1)}),this.afterFlushAnimationsDone(()=>i.destroy(t))}_fetchNamespace(e){return this._namespaceLookup[e]}fetchNamespacesByElement(e){const t=new Set,i=this.statesByElement.get(e);if(i)for(let r of i.values())if(r.namespaceId){const s=this._fetchNamespace(r.namespaceId);s&&t.add(s)}return t}trigger(e,t,i,r){if(_S(t)){const s=this._fetchNamespace(e);if(s)return s.trigger(t,i,r),!0}return!1}insertNode(e,t,i,r){if(!_S(t))return;const s=t[Oc];if(s&&s.setForRemoval){s.setForRemoval=!1,s.setForMove=!0;const o=this.collectedLeaveElements.indexOf(t);o>=0&&this.collectedLeaveElements.splice(o,1)}if(e){const o=this._fetchNamespace(e);o&&o.insertNode(t,i)}r&&this.collectEnterElement(t)}collectEnterElement(e){this.collectedEnterElements.push(e)}markElementAsDisabled(e,t){t?this.disabledNodes.has(e)||(this.disabledNodes.add(e),Lc(e,EA)):this.disabledNodes.has(e)&&(this.disabledNodes.delete(e),pg(e,EA))}removeNode(e,t,i,r){if(_S(t)){const s=e?this._fetchNamespace(e):null;if(s?s.removeNode(t,r):this.markElementAsRemoved(e,t,!1,r),i){const o=this.namespacesByHostElement.get(t);o&&o.id!==e&&o.removeNode(t,r)}}else this._onRemovalComplete(t,r)}markElementAsRemoved(e,t,i,r,s){this.collectedLeaveElements.push(t),t[Oc]={namespaceId:e,setForRemoval:r,hasAnimation:i,removedBeforeQueried:!1,previousTriggersValues:s}}listen(e,t,i,r,s){return _S(t)?this._fetchNamespace(e).listen(t,i,r,s):()=>{}}_buildInstruction(e,t,i,r,s){return e.transition.build(this.driver,e.element,e.fromState.value,e.toState.value,i,r,e.fromState.options,e.toState.options,t,s)}destroyInnerAnimations(e){let t=this.driver.query(e,oS,!0);t.forEach(i=>this.destroyActiveAnimationsForElement(i)),0!=this.playersByQueriedElement.size&&(t=this.driver.query(e,fA,!0),t.forEach(i=>this.finishActiveQueriedAnimationOnElement(i)))}destroyActiveAnimationsForElement(e){const t=this.playersByElement.get(e);t&&t.forEach(i=>{i.queued?i.markedForDestroy=!0:i.destroy()})}finishActiveQueriedAnimationOnElement(e){const t=this.playersByQueriedElement.get(e);t&&t.forEach(i=>i.finish())}whenRenderingDone(){return new Promise(e=>{if(this.players.length)return oh(this.players).onDone(()=>e());e()})}processLeaveNode(e){const t=e[Oc];if(t&&t.setForRemoval){if(e[Oc]=Y4,t.namespaceId){this.destroyInnerAnimations(e);const i=this._fetchNamespace(t.namespaceId);i&&i.clearElementCache(e)}this._onRemovalComplete(e,t.setForRemoval)}e.classList?.contains(EA)&&this.markElementAsDisabled(e,!1),this.driver.query(e,".ng-animate-disabled",!0).forEach(i=>{this.markElementAsDisabled(i,!1)})}flush(e=-1){let t=[];if(this.newHostElements.size&&(this.newHostElements.forEach((i,r)=>this._balanceNamespaceList(i,r)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let i=0;ii()),this._flushFns=[],this._whenQuietFns.length){const i=this._whenQuietFns;this._whenQuietFns=[],t.length?oh(t).onDone(()=>{i.forEach(r=>r())}):i.forEach(r=>r())}}reportError(e){throw function _Z(n){return new Ue(3402,!1)}()}_flushAnimations(e,t){const i=new pS,r=[],s=new Map,o=[],a=new Map,c=new Map,u=new Map,p=new Set;this.disabledNodes.forEach(ye=>{p.add(ye);const Me=this.driver.query(ye,".ng-animate-queued",!0);for(let je=0;je{const je=hA+T++;x.set(Me,je),ye.forEach(lt=>Lc(lt,je))});const N=[],k=new Set,A=new Set;for(let ye=0;yek.add(lt)):A.add(Me))}const H=new Map,G=J4(v,Array.from(k));G.forEach((ye,Me)=>{const je=rS+T++;H.set(Me,je),ye.forEach(lt=>Lc(lt,je))}),e.push(()=>{y.forEach((ye,Me)=>{const je=x.get(Me);ye.forEach(lt=>pg(lt,je))}),G.forEach((ye,Me)=>{const je=H.get(Me);ye.forEach(lt=>pg(lt,je))}),N.forEach(ye=>{this.processLeaveNode(ye)})});const X=[],se=[];for(let ye=this._namespaceList.length-1;ye>=0;ye--)this._namespaceList[ye].drainQueuedTransitions(t).forEach(je=>{const lt=je.player,ze=je.element;if(X.push(lt),this.collectedEnterElements.length){const Qt=ze[Oc];if(Qt&&Qt.setForMove){if(Qt.previousTriggersValues&&Qt.previousTriggersValues.has(je.triggerName)){const sn=Qt.previousTriggersValues.get(je.triggerName),It=this.statesByElement.get(je.element);if(It&&It.has(je.triggerName)){const on=It.get(je.triggerName);on.value=sn,It.set(je.triggerName,on)}}return void lt.destroy()}}const Ke=!g||!this.driver.containsElement(g,ze),vt=H.get(ze),yt=x.get(ze),gt=this._buildInstruction(je,i,yt,vt,Ke);if(gt.errors&>.errors.length)return void se.push(gt);if(Ke)return lt.onStart(()=>Gf(ze,gt.fromStyles)),lt.onDestroy(()=>Zl(ze,gt.toStyles)),void r.push(lt);if(je.isFallbackTransition)return lt.onStart(()=>Gf(ze,gt.fromStyles)),lt.onDestroy(()=>Zl(ze,gt.toStyles)),void r.push(lt);const mi=[];gt.timelines.forEach(Qt=>{Qt.stretchStartingKeyframe=!0,this.disabledNodes.has(Qt.element)||mi.push(Qt)}),gt.timelines=mi,i.append(ze,gt.timelines),o.push({instruction:gt,player:lt,element:ze}),gt.queriedElements.forEach(Qt=>Qa(a,Qt,[]).push(lt)),gt.preStyleProps.forEach((Qt,sn)=>{if(Qt.size){let It=c.get(sn);It||c.set(sn,It=new Set),Qt.forEach((on,gi)=>It.add(gi))}}),gt.postStyleProps.forEach((Qt,sn)=>{let It=u.get(sn);It||u.set(sn,It=new Set),Qt.forEach((on,gi)=>It.add(gi))})});if(se.length){const ye=[];se.forEach(Me=>{ye.push(function vZ(n,e){return new Ue(3505,!1)}())}),X.forEach(Me=>Me.destroy()),this.reportError(ye)}const K=new Map,he=new Map;o.forEach(ye=>{const Me=ye.element;i.has(Me)&&(he.set(Me,Me),this._beforeAnimationBuild(ye.player.namespaceId,ye.instruction,K))}),r.forEach(ye=>{const Me=ye.element;this._getPreviousPlayers(Me,!1,ye.namespaceId,ye.triggerName,null).forEach(lt=>{Qa(K,Me,[]).push(lt),lt.destroy()})});const De=N.filter(ye=>e5(ye,c,u)),Te=new Map;Z4(Te,this.driver,A,u,Ud).forEach(ye=>{e5(ye,c,u)&&De.push(ye)});const Qe=new Map;y.forEach((ye,Me)=>{Z4(Qe,this.driver,new Set(ye),c,nA)}),De.forEach(ye=>{const Me=Te.get(ye),je=Qe.get(ye);Te.set(ye,new Map([...Array.from(Me?.entries()??[]),...Array.from(je?.entries()??[])]))});const Pe=[],Oe=[],Ve={};o.forEach(ye=>{const{element:Me,player:je,instruction:lt}=ye;if(i.has(Me)){if(p.has(Me))return je.onDestroy(()=>Zl(Me,lt.toStyles)),je.disabled=!0,je.overrideTotalTime(lt.totalTime),void r.push(je);let ze=Ve;if(he.size>1){let vt=Me;const yt=[];for(;vt=vt.parentNode;){const gt=he.get(vt);if(gt){ze=gt;break}yt.push(vt)}yt.forEach(gt=>he.set(gt,ze))}const Ke=this._buildAnimation(je.namespaceId,lt,K,s,Qe,Te);if(je.setRealPlayer(Ke),ze===Ve)Pe.push(je);else{const vt=this.playersByElement.get(ze);vt&&vt.length&&(je.parentPlayer=oh(vt)),r.push(je)}}else Gf(Me,lt.fromStyles),je.onDestroy(()=>Zl(Me,lt.toStyles)),Oe.push(je),p.has(Me)&&r.push(je)}),Oe.forEach(ye=>{const Me=s.get(ye.element);if(Me&&Me.length){const je=oh(Me);ye.setRealPlayer(je)}}),r.forEach(ye=>{ye.parentPlayer?ye.syncPlayerEvents(ye.parentPlayer):ye.destroy()});for(let ye=0;ye!Ke.destroyed);ze.length?xJ(this,Me,ze):this.processLeaveNode(Me)}return N.length=0,Pe.forEach(ye=>{this.players.push(ye),ye.onDone(()=>{ye.destroy();const Me=this.players.indexOf(ye);this.players.splice(Me,1)}),ye.play()}),Pe}elementContainsData(e,t){let i=!1;const r=t[Oc];return r&&r.setForRemoval&&(i=!0),this.playersByElement.has(t)&&(i=!0),this.playersByQueriedElement.has(t)&&(i=!0),this.statesByElement.has(t)&&(i=!0),this._fetchNamespace(e).elementContainsData(t)||i}afterFlush(e){this._flushFns.push(e)}afterFlushAnimationsDone(e){this._whenQuietFns.push(e)}_getPreviousPlayers(e,t,i,r,s){let o=[];if(t){const a=this.playersByQueriedElement.get(e);a&&(o=a)}else{const a=this.playersByElement.get(e);if(a){const c=!s||s==ry;a.forEach(u=>{u.queued||!c&&u.triggerName!=r||o.push(u)})}}return(i||r)&&(o=o.filter(a=>!(i&&i!=a.namespaceId||r&&r!=a.triggerName))),o}_beforeAnimationBuild(e,t,i){const s=t.element,o=t.isRemovalTransition?void 0:e,a=t.isRemovalTransition?void 0:t.triggerName;for(const c of t.timelines){const u=c.element,p=u!==s,g=Qa(i,u,[]);this._getPreviousPlayers(u,p,o,a,t.toState).forEach(y=>{const x=y.getRealPlayer();x.beforeDestroy&&x.beforeDestroy(),y.destroy(),g.push(y)})}Gf(s,t.fromStyles)}_buildAnimation(e,t,i,r,s,o){const a=t.triggerName,c=t.element,u=[],p=new Set,g=new Set,v=t.timelines.map(x=>{const T=x.element;p.add(T);const N=T[Oc];if(N&&N.removedBeforeQueried)return new Qv(x.duration,x.delay);const k=T!==c,A=function wJ(n){const e=[];return Q4(n,e),e}((i.get(T)||pJ).map(K=>K.getRealPlayer())).filter(K=>!!K.element&&K.element===T),H=s.get(T),G=o.get(T),X=M4(0,this._normalizer,0,x.keyframes,H,G),se=this._buildPlayer(x,X,A);if(x.subTimeline&&r&&g.add(T),k){const K=new DA(e,a,T);K.setRealPlayer(se),u.push(K)}return se});u.forEach(x=>{Qa(this.playersByQueriedElement,x.element,[]).push(x),x.onDone(()=>function vJ(n,e,t){let i=n.get(e);if(i){if(i.length){const r=i.indexOf(t);i.splice(r,1)}0==i.length&&n.delete(e)}return i}(this.playersByQueriedElement,x.element,x))}),p.forEach(x=>Lc(x,P4));const y=oh(v);return y.onDestroy(()=>{p.forEach(x=>pg(x,P4)),Zl(c,t.toStyles)}),g.forEach(x=>{Qa(r,x,[]).push(y)}),y}_buildPlayer(e,t,i){return t.length>0?this.driver.animate(e.element,t,e.duration,e.delay,e.easing,i):new Qv(e.duration,e.delay)}}class DA{constructor(e,t,i){this.namespaceId=e,this.triggerName=t,this.element=i,this._player=new Qv,this._containsRealPlayer=!1,this._queuedCallbacks=new Map,this.destroyed=!1,this.markedForDestroy=!1,this.disabled=!1,this.queued=!0,this.totalTime=0}setRealPlayer(e){this._containsRealPlayer||(this._player=e,this._queuedCallbacks.forEach((t,i)=>{t.forEach(r=>oA(e,i,void 0,r))}),this._queuedCallbacks.clear(),this._containsRealPlayer=!0,this.overrideTotalTime(e.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(e){this.totalTime=e}syncPlayerEvents(e){const t=this._player;t.triggerCallback&&e.onStart(()=>t.triggerCallback("start")),e.onDone(()=>this.finish()),e.onDestroy(()=>this.destroy())}_queueEvent(e,t){Qa(this._queuedCallbacks,e,[]).push(t)}onDone(e){this.queued&&this._queueEvent("done",e),this._player.onDone(e)}onStart(e){this.queued&&this._queueEvent("start",e),this._player.onStart(e)}onDestroy(e){this.queued&&this._queueEvent("destroy",e),this._player.onDestroy(e)}init(){this._player.init()}hasStarted(){return!this.queued&&this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(e){this.queued||this._player.setPosition(e)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(e){const t=this._player;t.triggerCallback&&t.triggerCallback(e)}}function _S(n){return n&&1===n.nodeType}function X4(n,e){const t=n.style.display;return n.style.display=e??"none",t}function Z4(n,e,t,i,r){const s=[];t.forEach(c=>s.push(X4(c)));const o=[];i.forEach((c,u)=>{const p=new Map;c.forEach(g=>{const v=e.computeStyle(u,g,r);p.set(g,v),(!v||0==v.length)&&(u[Oc]=mJ,o.push(u))}),n.set(u,p)});let a=0;return t.forEach(c=>X4(c,s[a++])),o}function J4(n,e){const t=new Map;if(n.forEach(a=>t.set(a,[])),0==e.length)return t;const i=1,r=new Set(e),s=new Map;function o(a){if(!a)return i;let c=s.get(a);if(c)return c;const u=a.parentNode;return c=t.has(u)?u:r.has(u)?i:o(u),s.set(a,c),c}return e.forEach(a=>{const c=o(a);c!==i&&t.get(c).push(a)}),t}function Lc(n,e){n.classList?.add(e)}function pg(n,e){n.classList?.remove(e)}function xJ(n,e,t){oh(t).onDone(()=>n.processLeaveNode(e))}function Q4(n,e){for(let t=0;tr.add(s)):e.set(n,i),t.delete(n),!0}class vS{constructor(e,t,i){this.bodyNode=e,this._driver=t,this._normalizer=i,this._triggerCache={},this.onRemovalComplete=(r,s)=>{},this._transitionEngine=new _J(e,t,i),this._timelineEngine=new lJ(e,t,i),this._transitionEngine.onRemovalComplete=(r,s)=>this.onRemovalComplete(r,s)}registerTrigger(e,t,i,r,s){const o=e+"-"+r;let a=this._triggerCache[o];if(!a){const c=[],u=[],p=_A(this._driver,s,c,u);if(c.length)throw function aZ(n,e){return new Ue(3404,!1)}();a=function sJ(n,e,t){return new oJ(n,e,t)}(r,p,this._normalizer),this._triggerCache[o]=a}this._transitionEngine.registerTrigger(t,r,a)}register(e,t){this._transitionEngine.register(e,t)}destroy(e,t){this._transitionEngine.destroy(e,t)}onInsert(e,t,i,r){this._transitionEngine.insertNode(e,t,i,r)}onRemove(e,t,i,r){this._transitionEngine.removeNode(e,t,r||!1,i)}disableAnimations(e,t){this._transitionEngine.markElementAsDisabled(e,t)}process(e,t,i,r){if("@"==i.charAt(0)){const[s,o]=C4(i);this._timelineEngine.command(s,t,o,r)}else this._transitionEngine.trigger(e,t,i,r)}listen(e,t,i,r,s){if("@"==i.charAt(0)){const[o,a]=C4(i);return this._timelineEngine.listen(o,t,a,s)}return this._transitionEngine.listen(e,t,i,r,s)}flush(e=-1){this._transitionEngine.flush(e)}get players(){return this._transitionEngine.players.concat(this._timelineEngine.players)}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}}let MJ=(()=>{class n{constructor(t,i,r){this._element=t,this._startStyles=i,this._endStyles=r,this._state=0;let s=n.initialStylesByElement.get(t);s||n.initialStylesByElement.set(t,s=new Map),this._initialStyles=s}start(){this._state<1&&(this._startStyles&&Zl(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(Zl(this._element,this._initialStyles),this._endStyles&&(Zl(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(n.initialStylesByElement.delete(this._element),this._startStyles&&(Gf(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(Gf(this._element,this._endStyles),this._endStyles=null),Zl(this._element,this._initialStyles),this._state=3)}}return n.initialStylesByElement=new WeakMap,n})();function TA(n){let e=null;return n.forEach((t,i)=>{(function CJ(n){return"display"===n||"position"===n})(i)&&(e=e||new Map,e.set(i,t))}),e}class t5{constructor(e,t,i,r){this.element=e,this.keyframes=t,this.options=i,this._specialStyles=r,this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._initialized=!1,this._finished=!1,this._started=!1,this._destroyed=!1,this._originalOnDoneFns=[],this._originalOnStartFns=[],this.time=0,this.parentPlayer=null,this.currentSnapshot=new Map,this._duration=i.duration,this._delay=i.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this._buildPlayer(),this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return;this._initialized=!0;const e=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,e,this.options),this._finalKeyframe=e.length?e[e.length-1]:new Map,this.domPlayer.addEventListener("finish",()=>this._onFinish())}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}_convertKeyframesToObject(e){const t=[];return e.forEach(i=>{t.push(Object.fromEntries(i))}),t}_triggerWebAnimation(e,t,i){return e.animate(this._convertKeyframesToObject(t),i)}onStart(e){this._originalOnStartFns.push(e),this._onStartFns.push(e)}onDone(e){this._originalOnDoneFns.push(e),this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}play(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach(e=>e()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}pause(){this.init(),this.domPlayer.pause()}finish(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}_resetDomPlayerState(){this.domPlayer&&this.domPlayer.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}setPosition(e){void 0===this.domPlayer&&this.init(),this.domPlayer.currentTime=e*this.time}getPosition(){return this.domPlayer.currentTime/this.time}get totalTime(){return this._delay+this._duration}beforeDestroy(){const e=new Map;this.hasStarted()&&this._finalKeyframe.forEach((i,r)=>{"offset"!==r&&e.set(r,this._finished?i:H4(this.element,r))}),this.currentSnapshot=e}triggerCallback(e){const t="start"===e?this._onStartFns:this._onDoneFns;t.forEach(i=>i()),t.length=0}}class DJ{validateStyleProperty(e){return!0}validateAnimatableStyleProperty(e){return!0}matchesElement(e,t){return!1}containsElement(e,t){return k4(e,t)}getParentElement(e){return dA(e)}query(e,t,i){return I4(e,t,i)}computeStyle(e,t,i){return window.getComputedStyle(e)[t]}animate(e,t,i,r,s,o=[]){const c={duration:i,delay:r,fill:0==r?"both":"forwards"};s&&(c.easing=s);const u=new Map,p=o.filter(y=>y instanceof t5);(function IZ(n,e){return 0===n||0===e})(i,r)&&p.forEach(y=>{y.currentSnapshot.forEach((x,T)=>u.set(T,x))});let g=function DZ(n){return n.length?n[0]instanceof Map?n:n.map(e=>O4(e)):[]}(t).map(y=>ah(y));g=function FZ(n,e,t){if(t.size&&e.length){let i=e[0],r=[];if(t.forEach((s,o)=>{i.has(o)||r.push(o),i.set(o,s)}),r.length)for(let s=1;so.set(a,H4(n,a)))}}return e}(e,g,u);const v=function EJ(n,e){let t=null,i=null;return Array.isArray(e)&&e.length?(t=TA(e[0]),e.length>1&&(i=TA(e[e.length-1]))):e instanceof Map&&(t=TA(e)),t||i?new MJ(n,t,i):null}(e,g);return new t5(e,g,c,v)}}let TJ=(()=>{class n extends zN{constructor(t,i){super(),this._nextAnimationId=0,this._renderer=t.createRenderer(i.body,{id:"0",encapsulation:Ko.None,styles:[],data:{animation:[]}})}build(t){const i=this._nextAnimationId.toString();this._nextAnimationId++;const r=Array.isArray(t)?GN(t):t;return n5(this._renderer,null,i,"register",[r]),new AJ(i,this._renderer)}}return n.\u0275fac=function(t){return new(t||n)(xe(yn),xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class AJ extends $K{constructor(e,t){super(),this._id=e,this._renderer=t}create(e,t){return new kJ(this._id,e,t||{},this._renderer)}}class kJ{constructor(e,t,i,r){this.id=e,this.element=t,this._renderer=r,this.parentPlayer=null,this._started=!1,this.totalTime=0,this._command("create",i)}_listen(e,t){return this._renderer.listen(this.element,`@@${this.id}:${e}`,t)}_command(e,...t){return n5(this._renderer,this.element,this.id,e,t)}onDone(e){this._listen("done",e)}onStart(e){this._listen("start",e)}onDestroy(e){this._listen("destroy",e)}init(){this._command("init")}hasStarted(){return this._started}play(){this._command("play"),this._started=!0}pause(){this._command("pause")}restart(){this._command("restart")}finish(){this._command("finish")}destroy(){this._command("destroy")}reset(){this._command("reset"),this._started=!1}setPosition(e){this._command("setPosition",e)}getPosition(){return this._renderer.engine.players[+this.id]?.getPosition()??0}}function n5(n,e,t,i,r){return n.setProperty(e,`@@${t}:${i}`,r)}const i5="@.disabled";let IJ=(()=>{class n{constructor(t,i,r){this.delegate=t,this.engine=i,this._zone=r,this._currentId=0,this._microtaskId=1,this._animationCallbacksBuffer=[],this._rendererCache=new Map,this._cdRecurDepth=0,this.promise=Promise.resolve(0),i.onRemovalComplete=(s,o)=>{const a=o?.parentNode(s);a&&o.removeChild(a,s)}}createRenderer(t,i){const s=this.delegate.createRenderer(t,i);if(!(t&&i&&i.data&&i.data.animation)){let p=this._rendererCache.get(s);return p||(p=new r5("",s,this.engine,()=>this._rendererCache.delete(s)),this._rendererCache.set(s,p)),p}const o=i.id,a=i.id+"-"+this._currentId;this._currentId++,this.engine.register(a,t);const c=p=>{Array.isArray(p)?p.forEach(c):this.engine.registerTrigger(o,a,t,p.name,p)};return i.data.animation.forEach(c),new FJ(this,a,s,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){this.promise.then(()=>{this._microtaskId++})}scheduleListenerCallback(t,i,r){t>=0&&ti(r)):(0==this._animationCallbacksBuffer.length&&Promise.resolve(null).then(()=>{this._zone.run(()=>{this._animationCallbacksBuffer.forEach(s=>{const[o,a]=s;o(a)}),this._animationCallbacksBuffer=[]})}),this._animationCallbacksBuffer.push([i,r]))}end(){this._cdRecurDepth--,0==this._cdRecurDepth&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}}return n.\u0275fac=function(t){return new(t||n)(xe(yn),xe(vS),xe(Xt))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class r5{constructor(e,t,i,r){this.namespaceId=e,this.delegate=t,this.engine=i,this._onDestroy=r,this.destroyNode=this.delegate.destroyNode?s=>t.destroyNode(s):null}get data(){return this.delegate.data}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.delegate.destroy(),this._onDestroy?.()}createElement(e,t){return this.delegate.createElement(e,t)}createComment(e){return this.delegate.createComment(e)}createText(e){return this.delegate.createText(e)}appendChild(e,t){this.delegate.appendChild(e,t),this.engine.onInsert(this.namespaceId,t,e,!1)}insertBefore(e,t,i,r=!0){this.delegate.insertBefore(e,t,i),this.engine.onInsert(this.namespaceId,t,e,r)}removeChild(e,t,i){this.engine.onRemove(this.namespaceId,t,this.delegate,i)}selectRootElement(e,t){return this.delegate.selectRootElement(e,t)}parentNode(e){return this.delegate.parentNode(e)}nextSibling(e){return this.delegate.nextSibling(e)}setAttribute(e,t,i,r){this.delegate.setAttribute(e,t,i,r)}removeAttribute(e,t,i){this.delegate.removeAttribute(e,t,i)}addClass(e,t){this.delegate.addClass(e,t)}removeClass(e,t){this.delegate.removeClass(e,t)}setStyle(e,t,i,r){this.delegate.setStyle(e,t,i,r)}removeStyle(e,t,i){this.delegate.removeStyle(e,t,i)}setProperty(e,t,i){"@"==t.charAt(0)&&t==i5?this.disableAnimations(e,!!i):this.delegate.setProperty(e,t,i)}setValue(e,t){this.delegate.setValue(e,t)}listen(e,t,i){return this.delegate.listen(e,t,i)}disableAnimations(e,t){this.engine.disableAnimations(e,t)}}class FJ extends r5{constructor(e,t,i,r,s){super(t,i,r,s),this.factory=e,this.namespaceId=t}setProperty(e,t,i){"@"==t.charAt(0)?"."==t.charAt(1)&&t==i5?this.disableAnimations(e,i=void 0===i||!!i):this.engine.process(this.namespaceId,e,t.slice(1),i):this.delegate.setProperty(e,t,i)}listen(e,t,i){if("@"==t.charAt(0)){const r=function RJ(n){switch(n){case"body":return document.body;case"document":return document;case"window":return window;default:return n}}(e);let s=t.slice(1),o="";return"@"!=s.charAt(0)&&([s,o]=function PJ(n){const e=n.indexOf(".");return[n.substring(0,e),n.slice(e+1)]}(s)),this.engine.listen(this.namespaceId,r,s,o,a=>{this.factory.scheduleListenerCallback(a._data||-1,i,a)})}return this.delegate.listen(e,t,i)}}let OJ=(()=>{class n extends vS{constructor(t,i,r,s){super(t.body,i,r)}ngOnDestroy(){this.flush()}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn),xe(uA),xe(wA),xe(Jm))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const s5=[{provide:zN,useClass:TJ},{provide:wA,useFactory:function LJ(){return new tJ}},{provide:vS,useClass:OJ},{provide:yn,useFactory:function NJ(n,e,t){return new IJ(n,e,t)},deps:[cw,vS,Xt]}],AA=[{provide:uA,useFactory:()=>new DJ},{provide:bo,useValue:"BrowserAnimations"},...s5],o5=[{provide:uA,useClass:F4},{provide:bo,useValue:"NoopAnimations"},...s5];let BJ=(()=>{class n{static withConfig(t){return{ngModule:n,providers:t.disableAnimations?o5:AA}}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:AA,imports:[nO]}),n})();function a5(n,e,t,i,r,s,o){try{var a=n[s](o),c=a.value}catch(u){return void t(u)}a.done?e(c):Promise.resolve(c).then(i,r)}function fl(n){return function(){var e=this,t=arguments;return new Promise(function(i,r){var s=n.apply(e,t);function o(c){a5(s,i,r,o,a,"next",c)}function a(c){a5(s,i,r,o,a,"throw",c)}o(void 0)})}}var kA=dt(2573);class HJ{call(e,t){return t.subscribe(new UJ(e))}}class UJ extends Fs{constructor(e){super(e),this.hasFirst=!1,this.observables=[],this.subscriptions=[]}_next(e){this.observables.push(e)}_complete(){const e=this.observables,t=e.length;if(0===t)this.destination.complete();else{for(let i=0;ir.lift(new zJ(i,e))}pl.completeNotification=new pl("C"),pl.undefinedValueNotification=new pl("N",void 0);class zJ{constructor(e,t){this.delay=e,this.scheduler=t}call(e,t){return t.subscribe(new FA(e,this.delay,this.scheduler))}}class FA extends di{constructor(e,t,i){super(e),this.delay=t,this.scheduler=i,this.queue=[],this.active=!1,this.errored=!1}static dispatch(e){const t=e.source,i=t.queue,r=e.scheduler,s=e.destination;for(;i.length>0&&i[0].time-r.now()<=0;)i.shift().notification.observe(s);if(i.length>0){const o=Math.max(0,i[0].time-r.now());this.schedule(e,o)}else this.unsubscribe(),t.active=!1}_schedule(e){this.active=!0,this.destination.add(e.schedule(FA.dispatch,this.delay,{source:this,destination:this.destination,scheduler:e}))}scheduleNotification(e){if(!0===this.errored)return;const t=this.scheduler,i=new GJ(t.now()+this.delay,e);this.queue.push(i),!1===this.active&&this._schedule(t)}_next(e){this.scheduleNotification(pl.createNext(e))}_error(e){this.errored=!0,this.queue=[],this.destination.error(e),this.unsubscribe()}_complete(){this.scheduleNotification(pl.createComplete()),this.unsubscribe()}}class GJ{constructor(e,t){this.time=e,this.notification=t}}const bS=(()=>{function n(){return Error.call(this),this.message="no elements in sequence",this.name="EmptyError",this}return n.prototype=Object.create(Error.prototype),n})();function xS(n=null){return e=>e.lift(new jJ(n))}class jJ{constructor(e){this.defaultValue=e}call(e,t){return t.subscribe(new WJ(e,this.defaultValue))}}class WJ extends di{constructor(e,t){super(e),this.defaultValue=t,this.isEmpty=!0}_next(e){this.isEmpty=!1,this.destination.next(e)}_complete(){this.isEmpty&&this.destination.next(this.defaultValue),this.destination.complete()}}function l5(n=KJ){return e=>e.lift(new $J(n))}class $J{constructor(e){this.errorFactory=e}call(e,t){return t.subscribe(new qJ(e,this.errorFactory))}}class qJ extends di{constructor(e,t){super(e),this.errorFactory=t,this.hasValue=!1}_next(e){this.hasValue=!0,this.destination.next(e)}_complete(){if(this.hasValue)return this.destination.complete();{let e;try{e=this.errorFactory()}catch(t){e=t}this.destination.error(e)}}}function KJ(){return new bS}function ml(n,e){const t=arguments.length>=2;return i=>i.pipe(n?Ui((r,s)=>n(r,s,i)):Is,Gr(1),t?xS(e):l5(()=>new bS))}const YJ=(()=>{function n(){return Error.call(this),this.message="Timeout has occurred",this.name="TimeoutError",this}return n.prototype=Object.create(Error.prototype),n})();class ZJ{constructor(e,t,i,r){this.waitFor=e,this.absoluteTimeout=t,this.withObservable=i,this.scheduler=r}call(e,t){return t.subscribe(new RA(e,this.absoluteTimeout,this.waitFor,this.withObservable,this.scheduler))}}class RA extends Fs{constructor(e,t,i,r,s){super(e),this.absoluteTimeout=t,this.waitFor=i,this.withObservable=r,this.scheduler=s,this.action=null,this.scheduleTimeout()}static dispatchTimeout(e){const{withObservable:t}=e;e._unsubscribeAndRecycle(),e.add($o(e,t))}scheduleTimeout(){const{action:e}=this;e?this.action=e.schedule(this,this.waitFor):this.add(this.action=this.scheduler.schedule(RA.dispatchTimeout,this.waitFor,this))}_next(e){this.absoluteTimeout||this.scheduleTimeout(),super._next(e)}_unsubscribe(){this.action=null,this.scheduler=null,this.withObservable=null}}class d5{validateSignature(e){return Promise.resolve(null)}validateAtHash(e){return Promise.resolve(!0)}}class u5{}class PA{}let QJ=(()=>{class n extends PA{now(){return Date.now()}new(){return new Date}}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class h5{}class OA{}let eQ=(()=>{class n{constructor(){this.data=new Map}getItem(t){return this.data.get(t)}removeItem(t){this.data.delete(t)}setItem(t,i){this.data.set(t,i)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class LA{constructor(e){this.type=e}}class tc extends LA{constructor(e,t=null){super(e),this.info=t}}class jd extends LA{constructor(e,t=null){super(e),this.info=t}}class cs extends LA{constructor(e,t,i=null){super(e),this.reason=t,this.params=i}}function f5(n){const e=n.replace(/\-/g,"+").replace(/\_/g,"/");return decodeURIComponent(atob(e).split("").map(function(t){return"%"+("00"+t.charCodeAt(0).toString(16)).slice(-2)}).join(""))}function NA(n){return btoa(n).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}class wS{constructor(e){this.clientId="",this.redirectUri="",this.postLogoutRedirectUri="",this.redirectUriAsPostLogoutRedirectUriFallback=!0,this.loginUrl="",this.scope="openid profile",this.resource="",this.rngUrl="",this.oidc=!0,this.requestAccessToken=!0,this.options=null,this.issuer="",this.logoutUrl="",this.clearHashAfterLogin=!0,this.tokenEndpoint=null,this.revocationEndpoint=null,this.customTokenParameters=[],this.userinfoEndpoint=null,this.responseType="",this.showDebugInformation=!1,this.silentRefreshRedirectUri="",this.silentRefreshMessagePrefix="",this.silentRefreshShowIFrame=!1,this.siletRefreshTimeout=2e4,this.silentRefreshTimeout=2e4,this.dummyClientSecret="",this.requireHttps="remoteOnly",this.strictDiscoveryDocumentValidation=!0,this.jwks=null,this.customQueryParams=null,this.silentRefreshIFrameName="angular-oauth-oidc-silent-refresh-iframe",this.timeoutFactor=.75,this.sessionChecksEnabled=!1,this.sessionCheckIntervall=3e3,this.sessionCheckIFrameUrl=null,this.sessionCheckIFrameName="angular-oauth-oidc-check-session-iframe",this.disableAtHashCheck=!1,this.skipSubjectCheck=!1,this.useIdTokenHintForSilentRefresh=!1,this.skipIssuerCheck=!1,this.nonceStateSeparator=";",this.useHttpBasicAuth=!1,this.decreaseExpirationBySec=0,this.waitForTokenInMsec=0,this.disablePKCE=!1,this.preserveRequestedRoute=!1,this.disableIdTokenTimer=!1,this.checkOrigin=!1,this.openUri=t=>{location.href=t},e&&Object.assign(this,e)}}class sy{encodeKey(e){return encodeURIComponent(e)}encodeValue(e){return encodeURIComponent(e)}decodeKey(e){return decodeURIComponent(e)}decodeValue(e){return decodeURIComponent(e)}}class p5{}class tQ{validateAtHash(e){var t=this;return fl(function*(){let i=t.inferHashAlgorithm(e.idTokenHeader),r=yield t.calcHash(e.accessToken,i),o=NA(r.substr(0,r.length/2)),a=e.idTokenClaims.at_hash.replace(/=/g,"");return o!==a&&(console.error("exptected at_hash: "+o),console.error("actual at_hash: "+a)),o===a})()}inferHashAlgorithm(e){let t=e.alg;if(!t.match(/^.S[0-9]{3}$/))throw new Error("Algorithm not supported: "+t);return"sha-"+t.substr(2)}}let m5=(()=>{class n{getHashFragmentParams(t){let i=t||window.location.hash;if(i=decodeURIComponent(i),0!==i.indexOf("#"))return{};const r=i.indexOf("?");return i=i.substr(r>-1?r+1:1),this.parseQueryString(i)}parseQueryString(t){const i={};let r,s,o,a,c,u,p;if(null===t)return i;r=t.split("&");for(let g=0;g=64;){for(s=e[0],o=e[1],a=e[2],c=e[3],u=e[4],p=e[5],g=e[6],v=e[7],x=0;x<16;x++)T=i+4*x,n[x]=(255&t[T])<<24|(255&t[T+1])<<16|(255&t[T+2])<<8|255&t[T+3];for(x=16;x<64;x++)y=n[x-2],N=(y>>>17|y<<15)^(y>>>19|y<<13)^y>>>10,y=n[x-15],k=(y>>>7|y<<25)^(y>>>18|y<<14)^y>>>3,n[x]=(N+n[x-7]|0)+(k+n[x-16]|0);for(x=0;x<64;x++)N=(((u>>>6|u<<26)^(u>>>11|u<<21)^(u>>>25|u<<7))+(u&p^~u&g)|0)+(v+(iQ[x]+n[x]|0)|0)|0,k=((s>>>2|s<<30)^(s>>>13|s<<19)^(s>>>22|s<<10))+(s&o^s&a^o&a)|0,v=g,g=p,p=u,u=c+N|0,c=a,a=o,o=s,s=N+k|0;e[0]+=s,e[1]+=o,e[2]+=a,e[3]+=c,e[4]+=u,e[5]+=p,e[6]+=g,e[7]+=v,i+=64,r-=64}return i}class SS{constructor(){this.digestLength=32,this.blockSize=64,this.state=new Int32Array(8),this.temp=new Int32Array(64),this.buffer=new Uint8Array(128),this.bufferLength=0,this.bytesHashed=0,this.finished=!1,this.reset()}reset(){return this.state[0]=1779033703,this.state[1]=3144134277,this.state[2]=1013904242,this.state[3]=2773480762,this.state[4]=1359893119,this.state[5]=2600822924,this.state[6]=528734635,this.state[7]=1541459225,this.bufferLength=0,this.bytesHashed=0,this.finished=!1,this}clean(){for(let e=0;e0){for(;this.bufferLength<64&&t>0;)this.buffer[this.bufferLength++]=e[i++],t--;64===this.bufferLength&&(BA(this.temp,this.state,this.buffer,0,64),this.bufferLength=0)}for(t>=64&&(i=BA(this.temp,this.state,e,i,t),t%=64);t>0;)this.buffer[this.bufferLength++]=e[i++],t--;return this}finish(e){if(!this.finished){const t=this.bytesHashed,i=this.bufferLength,r=t/536870912|0,s=t<<3,o=t%64<56?64:128;this.buffer[i]=128;for(let a=i+1;a>>24&255,this.buffer[o-7]=r>>>16&255,this.buffer[o-6]=r>>>8&255,this.buffer[o-5]=r>>>0&255,this.buffer[o-4]=s>>>24&255,this.buffer[o-3]=s>>>16&255,this.buffer[o-2]=s>>>8&255,this.buffer[o-1]=s>>>0&255,BA(this.temp,this.state,this.buffer,0,o),this.finished=!0}for(let t=0;t<8;t++)e[4*t+0]=this.state[t]>>>24&255,e[4*t+1]=this.state[t]>>>16&255,e[4*t+2]=this.state[t]>>>8&255,e[4*t+3]=this.state[t]>>>0&255;return this}digest(){const e=new Uint8Array(this.digestLength);return this.finish(e),e}_saveState(e){for(let t=0;t{class n{calcHash(t,i){return fl(function*(){return function lQ(n){var e,t=[];for(e=0;e{class n extends wS{constructor(t,i,r,s,o,a,c,u,p,g){super(),this.ngZone=t,this.http=i,this.config=o,this.urlHelper=a,this.logger=c,this.crypto=u,this.dateTimeService=g,this.discoveryDocumentLoaded=!1,this.state="",this.eventsSubject=new cn,this.discoveryDocumentLoadedSubject=new cn,this.grantTypesSupported=[],this.inImplicitFlow=!1,this.saveNoncesInLocalStorage=!1,this.debug("angular-oauth2-oidc v10"),this.document=p,o||(o={}),this.discoveryDocumentLoaded$=this.discoveryDocumentLoadedSubject.asObservable(),this.events=this.eventsSubject.asObservable(),s&&(this.tokenValidationHandler=s),o&&this.configure(o);try{r?this.setStorage(r):typeof sessionStorage<"u"&&this.setStorage(sessionStorage)}catch(v){console.error("No OAuthStorage provided and cannot access default (sessionStorage).Consider providing a custom OAuthStorage implementation in your module.",v)}if(this.checkLocalStorageAccessable()){const v=window?.navigator?.userAgent;(v?.includes("MSIE ")||v?.includes("Trident"))&&(this.saveNoncesInLocalStorage=!0)}this.setupRefreshTimer()}checkLocalStorageAccessable(){if(typeof window>"u")return!1;const t="test";try{return!(typeof window.localStorage>"u"||(localStorage.setItem(t,t),localStorage.removeItem(t),0))}catch{return!1}}configure(t){Object.assign(this,new wS,t),this.config=Object.assign({},new wS,t),this.sessionChecksEnabled&&this.setupSessionCheck(),this.configChanged()}configChanged(){this.setupRefreshTimer()}restartSessionChecksIfStillLoggedIn(){this.hasValidIdToken()&&this.initSessionCheck()}restartRefreshTimerIfStillLoggedIn(){this.setupExpirationTimers()}setupSessionCheck(){this.events.pipe(Ui(t=>"token_received"===t.type)).subscribe(t=>{this.initSessionCheck()})}setupAutomaticSilentRefresh(t={},i,r=!0){let s=!0;this.clearAutomaticRefreshTimer(),this.automaticRefreshSubscription=this.events.pipe(Dr(o=>{"token_received"===o.type?s=!0:"logout"===o.type&&(s=!1)}),Ui(o=>"token_expires"===o.type&&(null==i||"any"===i||o.info===i)),zv(1e3)).subscribe(o=>{s&&this.refreshInternal(t,r).catch(a=>{this.debug("Automatic silent refresh did not work")})}),this.restartRefreshTimerIfStillLoggedIn()}refreshInternal(t,i){return this.useSilentRefresh||"code"!==this.responseType?this.silentRefresh(t,i):this.refreshToken()}loadDiscoveryDocumentAndTryLogin(t=null){return this.loadDiscoveryDocument().then(i=>this.tryLogin(t))}loadDiscoveryDocumentAndLogin(t=null){return this.loadDiscoveryDocumentAndTryLogin(t=t||{}).then(i=>!(!this.hasValidIdToken()||!this.hasValidAccessToken())||(this.initLoginFlow("string"==typeof t.state?t.state:""),!1))}debug(...t){this.showDebugInformation&&this.logger.debug.apply(this.logger,t)}validateUrlFromDiscoveryDocument(t){const i=[],r=this.validateUrlForHttps(t),s=this.validateUrlAgainstIssuer(t);return r||i.push("https for all urls required. Also for urls received by discovery."),s||i.push("Every url in discovery document has to start with the issuer url.Also see property strictDiscoveryDocumentValidation."),i}validateUrlForHttps(t){if(!t)return!0;const i=t.toLowerCase();return!(!1!==this.requireHttps&&(!i.match(/^http:\/\/localhost($|[:\/])/)&&!i.match(/^http:\/\/localhost($|[:\/])/)||"remoteOnly"!==this.requireHttps))||i.startsWith("https://")}assertUrlNotNullAndCorrectProtocol(t,i){if(!t)throw new Error(`'${i}' should not be null`);if(!this.validateUrlForHttps(t))throw new Error(`'${i}' must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).`)}validateUrlAgainstIssuer(t){return!this.strictDiscoveryDocumentValidation||!t||t.toLowerCase().startsWith(this.issuer.toLowerCase())}setupRefreshTimer(){typeof window>"u"?this.debug("timer not supported on this plattform"):((this.hasValidIdToken()||this.hasValidAccessToken())&&(this.clearAccessTokenTimer(),this.clearIdTokenTimer(),this.setupExpirationTimers()),this.tokenReceivedSubscription&&this.tokenReceivedSubscription.unsubscribe(),this.tokenReceivedSubscription=this.events.pipe(Ui(t=>"token_received"===t.type)).subscribe(t=>{this.clearAccessTokenTimer(),this.clearIdTokenTimer(),this.setupExpirationTimers()}))}setupExpirationTimers(){this.hasValidAccessToken()&&this.setupAccessTokenTimer(),!this.disableIdTokenTimer&&this.hasValidIdToken()&&this.setupIdTokenTimer()}setupAccessTokenTimer(){const t=this.getAccessTokenExpiration(),i=this.getAccessTokenStoredAt(),r=this.calcTimeout(i,t);this.ngZone.runOutsideAngular(()=>{this.accessTokenTimeoutSubscription=Tt(new jd("token_expires","access_token")).pipe(IA(r)).subscribe(s=>{this.ngZone.run(()=>{this.eventsSubject.next(s)})})})}setupIdTokenTimer(){const t=this.getIdTokenExpiration(),i=this.getIdTokenStoredAt(),r=this.calcTimeout(i,t);this.ngZone.runOutsideAngular(()=>{this.idTokenTimeoutSubscription=Tt(new jd("token_expires","id_token")).pipe(IA(r)).subscribe(s=>{this.ngZone.run(()=>{this.eventsSubject.next(s)})})})}stopAutomaticRefresh(){this.clearAccessTokenTimer(),this.clearIdTokenTimer(),this.clearAutomaticRefreshTimer()}clearAccessTokenTimer(){this.accessTokenTimeoutSubscription&&this.accessTokenTimeoutSubscription.unsubscribe()}clearIdTokenTimer(){this.idTokenTimeoutSubscription&&this.idTokenTimeoutSubscription.unsubscribe()}clearAutomaticRefreshTimer(){this.automaticRefreshSubscription&&this.automaticRefreshSubscription.unsubscribe()}calcTimeout(t,i){const r=this.dateTimeService.now(),o=Math.max(0,(i-t)*this.timeoutFactor-(r-t)),a=2147483647;return o>a?a:o}setStorage(t){this._storage=t,this.configChanged()}loadDiscoveryDocument(t=null){return new Promise((i,r)=>{t||((t=this.issuer||"").endsWith("/")||(t+="/"),t+=".well-known/openid-configuration"),this.validateUrlForHttps(t)?this.http.get(t).subscribe(s=>{if(!this.validateDiscoveryDocument(s))return this.eventsSubject.next(new cs("discovery_document_validation_error",null)),void r("discovery_document_validation_error");this.loginUrl=s.authorization_endpoint,this.logoutUrl=s.end_session_endpoint||this.logoutUrl,this.grantTypesSupported=s.grant_types_supported,this.issuer=s.issuer,this.tokenEndpoint=s.token_endpoint,this.userinfoEndpoint=s.userinfo_endpoint||this.userinfoEndpoint,this.jwksUri=s.jwks_uri,this.sessionCheckIFrameUrl=s.check_session_iframe||this.sessionCheckIFrameUrl,this.discoveryDocumentLoaded=!0,this.discoveryDocumentLoadedSubject.next(s),this.revocationEndpoint=s.revocation_endpoint||this.revocationEndpoint,this.sessionChecksEnabled&&this.restartSessionChecksIfStillLoggedIn(),this.loadJwks().then(o=>{const c=new tc("discovery_document_loaded",{discoveryDocument:s,jwks:o});this.eventsSubject.next(c),i(c)}).catch(o=>{this.eventsSubject.next(new cs("discovery_document_load_error",o)),r(o)})},s=>{this.logger.error("error loading discovery document",s),this.eventsSubject.next(new cs("discovery_document_load_error",s)),r(s)}):r("issuer must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).")})}loadJwks(){return new Promise((t,i)=>{this.jwksUri?this.http.get(this.jwksUri).subscribe(r=>{this.jwks=r,t(r)},r=>{this.logger.error("error loading jwks",r),this.eventsSubject.next(new cs("jwks_load_error",r)),i(r)}):t(null)})}validateDiscoveryDocument(t){let i;return this.skipIssuerCheck||t.issuer===this.issuer?(i=this.validateUrlFromDiscoveryDocument(t.authorization_endpoint),i.length>0?(this.logger.error("error validating authorization_endpoint in discovery document",i),!1):(i=this.validateUrlFromDiscoveryDocument(t.end_session_endpoint),i.length>0?(this.logger.error("error validating end_session_endpoint in discovery document",i),!1):(i=this.validateUrlFromDiscoveryDocument(t.token_endpoint),i.length>0&&this.logger.error("error validating token_endpoint in discovery document",i),i=this.validateUrlFromDiscoveryDocument(t.revocation_endpoint),i.length>0&&this.logger.error("error validating revocation_endpoint in discovery document",i),i=this.validateUrlFromDiscoveryDocument(t.userinfo_endpoint),i.length>0?(this.logger.error("error validating userinfo_endpoint in discovery document",i),!1):(i=this.validateUrlFromDiscoveryDocument(t.jwks_uri),i.length>0?(this.logger.error("error validating jwks_uri in discovery document",i),!1):(this.sessionChecksEnabled&&!t.check_session_iframe&&this.logger.warn("sessionChecksEnabled is activated but discovery document does not contain a check_session_iframe field"),!0))))):(this.logger.error("invalid issuer in discovery document","expected: "+this.issuer,"current: "+t.issuer),!1)}fetchTokenUsingPasswordFlowAndLoadUserProfile(t,i,r=new Ho){return this.fetchTokenUsingPasswordFlow(t,i,r).then(()=>this.loadUserProfile())}loadUserProfile(){if(!this.hasValidAccessToken())throw new Error("Can not load User Profile without access_token");if(!this.validateUrlForHttps(this.userinfoEndpoint))throw new Error("userinfoEndpoint must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).");return new Promise((t,i)=>{const r=(new Ho).set("Authorization","Bearer "+this.getAccessToken());this.http.get(this.userinfoEndpoint,{headers:r,observe:"response",responseType:"text"}).subscribe(s=>{if(this.debug("userinfo received",JSON.stringify(s)),s.headers.get("content-type").startsWith("application/json")){let o=JSON.parse(s.body);const a=this.getIdentityClaims()||{};if(!this.skipSubjectCheck&&this.oidc&&(!a.sub||o.sub!==a.sub))return void i("if property oidc is true, the received user-id (sub) has to be the user-id of the user that has logged in with oidc.\nif you are not using oidc but just oauth2 password flow set oidc to false");o=Object.assign({},a,o),this._storage.setItem("id_token_claims_obj",JSON.stringify(o)),this.eventsSubject.next(new tc("user_profile_loaded")),t({info:o})}else this.debug("userinfo is not JSON, treating it as JWE/JWS"),this.eventsSubject.next(new tc("user_profile_loaded")),t(JSON.parse(s.body))},s=>{this.logger.error("error loading user info",s),this.eventsSubject.next(new cs("user_profile_load_error",s)),i(s)})})}fetchTokenUsingPasswordFlow(t,i,r=new Ho){return this.fetchTokenUsingGrant("password",{username:t,password:i},r)}fetchTokenUsingGrant(t,i,r=new Ho){this.assertUrlNotNullAndCorrectProtocol(this.tokenEndpoint,"tokenEndpoint");let s=new Za({encoder:new sy}).set("grant_type",t).set("scope",this.scope);if(this.useHttpBasicAuth){const o=btoa(`${this.clientId}:${this.dummyClientSecret}`);r=r.set("Authorization","Basic "+o)}if(this.useHttpBasicAuth||(s=s.set("client_id",this.clientId)),!this.useHttpBasicAuth&&this.dummyClientSecret&&(s=s.set("client_secret",this.dummyClientSecret)),this.customQueryParams)for(const o of Object.getOwnPropertyNames(this.customQueryParams))s=s.set(o,this.customQueryParams[o]);for(const o of Object.keys(i))s=s.set(o,i[o]);return r=r.set("Content-Type","application/x-www-form-urlencoded"),new Promise((o,a)=>{this.http.post(this.tokenEndpoint,s,{headers:r}).subscribe(c=>{this.debug("tokenResponse",c),this.storeAccessTokenResponse(c.access_token,c.refresh_token,c.expires_in||this.fallbackAccessTokenExpirationTimeInSec,c.scope,this.extractRecognizedCustomParameters(c)),this.oidc&&c.id_token&&this.processIdToken(c.id_token,c.access_token).then(u=>{this.storeIdToken(u),o(c)}),this.eventsSubject.next(new tc("token_received")),o(c)},c=>{this.logger.error("Error performing ${grantType} flow",c),this.eventsSubject.next(new cs("token_error",c)),a(c)})})}refreshToken(){return this.assertUrlNotNullAndCorrectProtocol(this.tokenEndpoint,"tokenEndpoint"),new Promise((t,i)=>{let r=new Za({encoder:new sy}).set("grant_type","refresh_token").set("scope",this.scope).set("refresh_token",this._storage.getItem("refresh_token")),s=(new Ho).set("Content-Type","application/x-www-form-urlencoded");if(this.useHttpBasicAuth){const o=btoa(`${this.clientId}:${this.dummyClientSecret}`);s=s.set("Authorization","Basic "+o)}if(this.useHttpBasicAuth||(r=r.set("client_id",this.clientId)),!this.useHttpBasicAuth&&this.dummyClientSecret&&(r=r.set("client_secret",this.dummyClientSecret)),this.customQueryParams)for(const o of Object.getOwnPropertyNames(this.customQueryParams))r=r.set(o,this.customQueryParams[o]);this.http.post(this.tokenEndpoint,r,{headers:s}).pipe(wo(o=>this.oidc&&o.id_token?dr(this.processIdToken(o.id_token,o.access_token,!0)).pipe(Dr(a=>this.storeIdToken(a)),_t(a=>o)):Tt(o))).subscribe(o=>{this.debug("refresh tokenResponse",o),this.storeAccessTokenResponse(o.access_token,o.refresh_token,o.expires_in||this.fallbackAccessTokenExpirationTimeInSec,o.scope,this.extractRecognizedCustomParameters(o)),this.eventsSubject.next(new tc("token_received")),this.eventsSubject.next(new tc("token_refreshed")),t(o)},o=>{this.logger.error("Error refreshing token",o),this.eventsSubject.next(new cs("token_refresh_error",o)),i(o)})})}removeSilentRefreshEventListener(){this.silentRefreshPostMessageEventListener&&(window.removeEventListener("message",this.silentRefreshPostMessageEventListener),this.silentRefreshPostMessageEventListener=null)}setupSilentRefreshEventListener(){this.removeSilentRefreshEventListener(),this.silentRefreshPostMessageEventListener=t=>{const i=this.processMessageEventMessage(t);this.checkOrigin&&t.origin!==location.origin&&console.error("wrong origin requested silent refresh!"),this.tryLogin({customHashFragment:i,preventClearHashAfterLogin:!0,customRedirectUri:this.silentRefreshRedirectUri||this.redirectUri}).catch(r=>this.debug("tryLogin during silent refresh failed",r))},window.addEventListener("message",this.silentRefreshPostMessageEventListener)}silentRefresh(t={},i=!0){const r=this.getIdentityClaims()||{};if(this.useIdTokenHintForSilentRefresh&&this.hasValidIdToken()&&(t.id_token_hint=this.getIdToken()),!this.validateUrlForHttps(this.loginUrl))throw new Error("loginUrl must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).");if(typeof this.document>"u")throw new Error("silent refresh is not supported on this platform");const s=this.document.getElementById(this.silentRefreshIFrameName);s&&this.document.body.removeChild(s),this.silentRefreshSubject=r.sub;const o=this.document.createElement("iframe");return o.id=this.silentRefreshIFrameName,this.setupSilentRefreshEventListener(),this.createLoginUrl(null,null,this.silentRefreshRedirectUri||this.redirectUri,i,t).then(g=>{o.setAttribute("src",g),this.silentRefreshShowIFrame||(o.style.display="none"),this.document.body.appendChild(o)}),function VJ(...n){if(1===n.length){if(!_i(n[0]))return n[0];n=n[0]}return uc(n,void 0).lift(new HJ)}([this.events.pipe(Ui(g=>g instanceof cs),ml()),this.events.pipe(Ui(g=>"token_received"===g.type),ml()),Tt(new cs("silent_refresh_timeout",null)).pipe(IA(this.silentRefreshTimeout))]).pipe(_t(g=>{if(g instanceof cs)throw"silent_refresh_timeout"===g.type||(g=new cs("silent_refresh_error",g)),this.eventsSubject.next(g),g;return"token_received"===g.type&&(g=new tc("silently_refreshed"),this.eventsSubject.next(g)),g})).toPromise()}initImplicitFlowInPopup(t){return this.initLoginFlowInPopup(t)}initLoginFlowInPopup(t){return t=t||{},this.createLoginUrl(null,null,this.silentRefreshRedirectUri,!1,{display:"popup"}).then(i=>new Promise((r,s)=>{let c,a=null;t.windowRef?t.windowRef&&!t.windowRef.closed&&(a=t.windowRef,a.location.href=i):a=window.open(i,"ngx-oauth2-oidc-login",this.calculatePopupFeatures(t));const u=x=>{this.tryLogin({customHashFragment:x,preventClearHashAfterLogin:!0,customRedirectUri:this.silentRefreshRedirectUri}).then(()=>{g(),r(!0)},T=>{g(),s(T)})};a?c=window.setInterval(()=>{(!a||a.closed)&&(g(),s(new cs("popup_closed",{})))},500):s(new cs("popup_blocked",{}));const g=()=>{window.clearInterval(c),window.removeEventListener("storage",y),window.removeEventListener("message",v),null!==a&&a.close(),a=null},v=x=>{const T=this.processMessageEventMessage(x);T&&null!==T?(window.removeEventListener("storage",y),u(T)):console.log("false event firing")},y=x=>{"auth_hash"===x.key&&(window.removeEventListener("message",v),u(x.newValue))};window.addEventListener("message",v),window.addEventListener("storage",y)}))}calculatePopupFeatures(t){const i=t.height||470,r=t.width||500,s=window.screenLeft+(window.outerWidth-r)/2;return`location=no,toolbar=no,width=${r},height=${i},top=${window.screenTop+(window.outerHeight-i)/2},left=${s}`}processMessageEventMessage(t){let i="#";if(this.silentRefreshMessagePrefix&&(i+=this.silentRefreshMessagePrefix),!t||!t.data||"string"!=typeof t.data)return;const r=t.data;return r.startsWith(i)?"#"+r.substr(i.length):void 0}canPerformSessionCheck(){return!(!this.sessionChecksEnabled||(this.sessionCheckIFrameUrl?this.getSessionState()?typeof this.document>"u":(console.warn("sessionChecksEnabled is activated but there is no session_state"),1):(console.warn("sessionChecksEnabled is activated but there is no sessionCheckIFrameUrl"),1)))}setupSessionCheckEventListener(){this.removeSessionCheckEventListener(),this.sessionCheckEventListener=t=>{const i=t.origin.toLowerCase(),r=this.issuer.toLowerCase();if(this.debug("sessionCheckEventListener"),r.startsWith(i)){switch(t.data){case"unchanged":this.ngZone.run(()=>{this.handleSessionUnchanged()});break;case"changed":this.ngZone.run(()=>{this.handleSessionChange()});break;case"error":this.ngZone.run(()=>{this.handleSessionError()})}this.debug("got info from session check inframe",t)}else this.debug("sessionCheckEventListener","wrong origin",i,"expected",r,"event",t)},this.ngZone.runOutsideAngular(()=>{window.addEventListener("message",this.sessionCheckEventListener)})}handleSessionUnchanged(){this.debug("session check","session unchanged"),this.eventsSubject.next(new jd("session_unchanged"))}handleSessionChange(){this.eventsSubject.next(new jd("session_changed")),this.stopSessionCheckTimer(),this.useSilentRefresh||"code"!==this.responseType?this.silentRefreshRedirectUri?(this.silentRefresh().catch(t=>this.debug("silent refresh failed after session changed")),this.waitForSilentRefreshAfterSessionChange()):(this.eventsSubject.next(new jd("session_terminated")),this.logOut(!0)):this.refreshToken().then(t=>{this.debug("token refresh after session change worked")}).catch(t=>{this.debug("token refresh did not work after session changed"),this.eventsSubject.next(new jd("session_terminated")),this.logOut(!0)})}waitForSilentRefreshAfterSessionChange(){this.events.pipe(Ui(t=>"silently_refreshed"===t.type||"silent_refresh_timeout"===t.type||"silent_refresh_error"===t.type),ml()).subscribe(t=>{"silently_refreshed"!==t.type&&(this.debug("silent refresh did not work after session changed"),this.eventsSubject.next(new jd("session_terminated")),this.logOut(!0))})}handleSessionError(){this.stopSessionCheckTimer(),this.eventsSubject.next(new jd("session_error"))}removeSessionCheckEventListener(){this.sessionCheckEventListener&&(window.removeEventListener("message",this.sessionCheckEventListener),this.sessionCheckEventListener=null)}initSessionCheck(){if(!this.canPerformSessionCheck())return;const t=this.document.getElementById(this.sessionCheckIFrameName);t&&this.document.body.removeChild(t);const i=this.document.createElement("iframe");i.id=this.sessionCheckIFrameName,this.setupSessionCheckEventListener(),i.setAttribute("src",this.sessionCheckIFrameUrl),i.style.display="none",this.document.body.appendChild(i),this.startSessionCheckTimer()}startSessionCheckTimer(){this.stopSessionCheckTimer(),this.ngZone.runOutsideAngular(()=>{this.sessionCheckTimer=setInterval(this.checkSession.bind(this),this.sessionCheckIntervall)})}stopSessionCheckTimer(){this.sessionCheckTimer&&(clearInterval(this.sessionCheckTimer),this.sessionCheckTimer=null)}checkSession(){const t=this.document.getElementById(this.sessionCheckIFrameName);t||this.logger.warn("checkSession did not find iframe",this.sessionCheckIFrameName);const i=this.getSessionState();i||this.stopSessionCheckTimer(),t.contentWindow.postMessage(this.clientId+" "+i,this.issuer)}createLoginUrl(t="",i="",r="",s=!1,o={}){var a=this;return fl(function*(){const c=a;let u;u=r||a.redirectUri;const p=yield a.createAndSaveNonce();if(t=t?p+a.config.nonceStateSeparator+encodeURIComponent(t):p,!a.requestAccessToken&&!a.oidc)throw new Error("Either requestAccessToken or oidc or both must be true");a.responseType=a.config.responseType?a.config.responseType:a.oidc&&a.requestAccessToken?"id_token token":a.oidc&&!a.requestAccessToken?"id_token":"token";const g=c.loginUrl.indexOf("?")>-1?"&":"?";let v=c.scope;a.oidc&&!v.match(/(^|\s)openid($|\s)/)&&(v="openid "+v);let y=c.loginUrl+g+"response_type="+encodeURIComponent(c.responseType)+"&client_id="+encodeURIComponent(c.clientId)+"&state="+encodeURIComponent(t)+"&redirect_uri="+encodeURIComponent(u)+"&scope="+encodeURIComponent(v);if(a.responseType.includes("code")&&!a.disablePKCE){const[x,T]=yield a.createChallangeVerifierPairForPKCE();a.saveNoncesInLocalStorage&&typeof window.localStorage<"u"?localStorage.setItem("PKCE_verifier",T):a._storage.setItem("PKCE_verifier",T),y+="&code_challenge="+x,y+="&code_challenge_method=S256"}i&&(y+="&login_hint="+encodeURIComponent(i)),c.resource&&(y+="&resource="+encodeURIComponent(c.resource)),c.oidc&&(y+="&nonce="+encodeURIComponent(p)),s&&(y+="&prompt=none");for(const x of Object.keys(o))y+="&"+encodeURIComponent(x)+"="+encodeURIComponent(o[x]);if(a.customQueryParams)for(const x of Object.getOwnPropertyNames(a.customQueryParams))y+="&"+x+"="+encodeURIComponent(a.customQueryParams[x]);return y})()}initImplicitFlowInternal(t="",i=""){if(this.inImplicitFlow)return;if(this.inImplicitFlow=!0,!this.validateUrlForHttps(this.loginUrl))throw new Error("loginUrl must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).");let r={},s=null;"string"==typeof i?s=i:"object"==typeof i&&(r=i),this.createLoginUrl(t,s,null,!1,r).then(this.config.openUri).catch(o=>{console.error("Error in initImplicitFlow",o),this.inImplicitFlow=!1})}initImplicitFlow(t="",i=""){""!==this.loginUrl?this.initImplicitFlowInternal(t,i):this.events.pipe(Ui(r=>"discovery_document_loaded"===r.type)).subscribe(r=>this.initImplicitFlowInternal(t,i))}resetImplicitFlow(){this.inImplicitFlow=!1}callOnTokenReceivedIfExists(t){const i=this;if(t.onTokenReceived){const r={idClaims:i.getIdentityClaims(),idToken:i.getIdToken(),accessToken:i.getAccessToken(),state:i.state};t.onTokenReceived(r)}}storeAccessTokenResponse(t,i,r,s,o){if(this._storage.setItem("access_token",t),s&&!Array.isArray(s)?this._storage.setItem("granted_scopes",JSON.stringify(s.split(" "))):s&&Array.isArray(s)&&this._storage.setItem("granted_scopes",JSON.stringify(s)),this._storage.setItem("access_token_stored_at",""+this.dateTimeService.now()),r){const a=1e3*r,u=this.dateTimeService.new().getTime()+a;this._storage.setItem("expires_at",""+u)}i&&this._storage.setItem("refresh_token",i),o&&o.forEach((a,c)=>{this._storage.setItem(c,a)})}tryLogin(t=null){return"code"===this.config.responseType?this.tryLoginCodeFlow(t).then(i=>!0):this.tryLoginImplicitFlow(t)}parseQueryString(t){return t&&0!==t.length?("?"===t.charAt(0)&&(t=t.substr(1)),this.urlHelper.parseQueryString(t)):{}}tryLoginCodeFlow(t=null){var i=this;return fl(function*(){const r=(t=t||{}).customHashFragment?t.customHashFragment.substring(1):window.location.search,s=i.getCodePartsFromUrl(r),o=s.code,a=s.state,c=s.session_state;if(!t.preventClearHashAfterLogin){const g=location.origin+location.pathname+location.search.replace(/code=[^&\$]*/,"").replace(/scope=[^&\$]*/,"").replace(/state=[^&\$]*/,"").replace(/session_state=[^&\$]*/,"").replace(/^\?&/,"?").replace(/&$/,"").replace(/^\?$/,"").replace(/&+/g,"&").replace(/\?&/,"?").replace(/\?$/,"")+location.hash;history.replaceState(null,window.name,g)}let[u,p]=i.parseState(a);if(i.state=p,s.error){i.debug("error trying to login"),i.handleLoginError(t,s);const g=new cs("code_error",{},s);return i.eventsSubject.next(g),Promise.reject(g)}if(!t.disableNonceCheck){if(!u)return i.saveRequestedRoute(),Promise.resolve();if(!t.disableOAuth2StateCheck&&!i.validateNonce(u)){const v=new cs("invalid_nonce_in_state",null);return i.eventsSubject.next(v),Promise.reject(v)}}return i.storeSessionState(c),o&&(yield i.getTokenFromCode(o,t),i.restoreRequestedRoute()),Promise.resolve()})()}saveRequestedRoute(){this.config.preserveRequestedRoute&&this._storage.setItem("requested_route",window.location.pathname+window.location.search)}restoreRequestedRoute(){const t=this._storage.getItem("requested_route");t&&history.replaceState(null,"",window.location.origin+t)}getCodePartsFromUrl(t){return t&&0!==t.length?("?"===t.charAt(0)&&(t=t.substr(1)),this.urlHelper.parseQueryString(t)):this.urlHelper.getHashFragmentParams()}getTokenFromCode(t,i){let r=new Za({encoder:new sy}).set("grant_type","authorization_code").set("code",t).set("redirect_uri",i.customRedirectUri||this.redirectUri);if(!this.disablePKCE){let s;s=this.saveNoncesInLocalStorage&&typeof window.localStorage<"u"?localStorage.getItem("PKCE_verifier"):this._storage.getItem("PKCE_verifier"),s?r=r.set("code_verifier",s):console.warn("No PKCE verifier found in oauth storage!")}return this.fetchAndProcessToken(r,i)}fetchAndProcessToken(t,i){i=i||{},this.assertUrlNotNullAndCorrectProtocol(this.tokenEndpoint,"tokenEndpoint");let r=(new Ho).set("Content-Type","application/x-www-form-urlencoded");if(this.useHttpBasicAuth){const s=btoa(`${this.clientId}:${this.dummyClientSecret}`);r=r.set("Authorization","Basic "+s)}return this.useHttpBasicAuth||(t=t.set("client_id",this.clientId)),!this.useHttpBasicAuth&&this.dummyClientSecret&&(t=t.set("client_secret",this.dummyClientSecret)),new Promise((s,o)=>{if(this.customQueryParams)for(let a of Object.getOwnPropertyNames(this.customQueryParams))t=t.set(a,this.customQueryParams[a]);this.http.post(this.tokenEndpoint,t,{headers:r}).subscribe(a=>{this.debug("refresh tokenResponse",a),this.storeAccessTokenResponse(a.access_token,a.refresh_token,a.expires_in||this.fallbackAccessTokenExpirationTimeInSec,a.scope,this.extractRecognizedCustomParameters(a)),this.oidc&&a.id_token?this.processIdToken(a.id_token,a.access_token,i.disableNonceCheck).then(c=>{this.storeIdToken(c),this.eventsSubject.next(new tc("token_received")),this.eventsSubject.next(new tc("token_refreshed")),s(a)}).catch(c=>{this.eventsSubject.next(new cs("token_validation_error",c)),console.error("Error validating tokens"),console.error(c),o(c)}):(this.eventsSubject.next(new tc("token_received")),this.eventsSubject.next(new tc("token_refreshed")),s(a))},a=>{console.error("Error getting token",a),this.eventsSubject.next(new cs("token_refresh_error",a)),o(a)})})}tryLoginImplicitFlow(t=null){let i;i=(t=t||{}).customHashFragment?this.urlHelper.getHashFragmentParams(t.customHashFragment):this.urlHelper.getHashFragmentParams(),this.debug("parsed url",i);const r=i.state;let[s,o]=this.parseState(r);if(this.state=o,i.error){this.debug("error trying to login"),this.handleLoginError(t,i);const g=new cs("token_error",{},i);return this.eventsSubject.next(g),Promise.reject(g)}const a=i.access_token,c=i.id_token,u=i.session_state,p=i.scope;if(!this.requestAccessToken&&!this.oidc)return Promise.reject("Either requestAccessToken or oidc (or both) must be true.");if(this.requestAccessToken&&!a||this.requestAccessToken&&!t.disableOAuth2StateCheck&&!r||this.oidc&&!c)return Promise.resolve(!1);if(this.sessionChecksEnabled&&!u&&this.logger.warn("session checks (Session Status Change Notification) were activated in the configuration but the id_token does not contain a session_state claim"),this.requestAccessToken&&!t.disableNonceCheck&&!this.validateNonce(s)){const v=new cs("invalid_nonce_in_state",null);return this.eventsSubject.next(v),Promise.reject(v)}return this.requestAccessToken&&this.storeAccessTokenResponse(a,null,i.expires_in||this.fallbackAccessTokenExpirationTimeInSec,p),this.oidc?this.processIdToken(c,a,t.disableNonceCheck).then(g=>t.validationHandler?t.validationHandler({accessToken:a,idClaims:g.idTokenClaims,idToken:g.idToken,state:r}).then(v=>g):g).then(g=>(this.storeIdToken(g),this.storeSessionState(u),this.clearHashAfterLogin&&!t.preventClearHashAfterLogin&&this.clearLocationHash(),this.eventsSubject.next(new tc("token_received")),this.callOnTokenReceivedIfExists(t),this.inImplicitFlow=!1,!0)).catch(g=>(this.eventsSubject.next(new cs("token_validation_error",g)),this.logger.error("Error validating tokens"),this.logger.error(g),Promise.reject(g))):(this.eventsSubject.next(new tc("token_received")),this.clearHashAfterLogin&&!t.preventClearHashAfterLogin&&this.clearLocationHash(),this.callOnTokenReceivedIfExists(t),Promise.resolve(!0))}parseState(t){let i=t,r="";if(t){const s=t.indexOf(this.config.nonceStateSeparator);s>-1&&(i=t.substr(0,s),r=t.substr(s+this.config.nonceStateSeparator.length))}return[i,r]}validateNonce(t){let i;return i=this.saveNoncesInLocalStorage&&typeof window.localStorage<"u"?localStorage.getItem("nonce"):this._storage.getItem("nonce"),i===t||(console.error("Validating access_token failed, wrong state/nonce.",i,t),!1)}storeIdToken(t){this._storage.setItem("id_token",t.idToken),this._storage.setItem("id_token_claims_obj",t.idTokenClaimsJson),this._storage.setItem("id_token_expires_at",""+t.idTokenExpiresAt),this._storage.setItem("id_token_stored_at",""+this.dateTimeService.now())}storeSessionState(t){this._storage.setItem("session_state",t)}getSessionState(){return this._storage.getItem("session_state")}handleLoginError(t,i){t.onLoginError&&t.onLoginError(i),this.clearHashAfterLogin&&!t.preventClearHashAfterLogin&&this.clearLocationHash()}getClockSkewInMsec(t=6e5){return this.clockSkewInSec||0===this.clockSkewInSec?1e3*this.clockSkewInSec:t}processIdToken(t,i,r=!1){const s=t.split("."),a=f5(this.padBase64(s[0])),c=JSON.parse(a),p=f5(this.padBase64(s[1])),g=JSON.parse(p);let v;if(v=this.saveNoncesInLocalStorage&&typeof window.localStorage<"u"?localStorage.getItem("nonce"):this._storage.getItem("nonce"),Array.isArray(g.aud)){if(g.aud.every(A=>A!==this.clientId)){const A="Wrong audience: "+g.aud.join(",");return this.logger.warn(A),Promise.reject(A)}}else if(g.aud!==this.clientId){const A="Wrong audience: "+g.aud;return this.logger.warn(A),Promise.reject(A)}if(!g.sub){const A="No sub claim in id_token";return this.logger.warn(A),Promise.reject(A)}if(this.sessionChecksEnabled&&this.silentRefreshSubject&&this.silentRefreshSubject!==g.sub){const A=`After refreshing, we got an id_token for another user (sub). Expected sub: ${this.silentRefreshSubject}, received sub: ${g.sub}`;return this.logger.warn(A),Promise.reject(A)}if(!g.iat){const A="No iat claim in id_token";return this.logger.warn(A),Promise.reject(A)}if(!this.skipIssuerCheck&&g.iss!==this.issuer){const A="Wrong issuer: "+g.iss;return this.logger.warn(A),Promise.reject(A)}if(!r&&g.nonce!==v){const A="Wrong nonce: "+g.nonce;return this.logger.warn(A),Promise.reject(A)}if(this.hasOwnProperty("responseType")&&("code"===this.responseType||"id_token"===this.responseType)&&(this.disableAtHashCheck=!0),!this.disableAtHashCheck&&this.requestAccessToken&&!g.at_hash){const A="An at_hash is needed!";return this.logger.warn(A),Promise.reject(A)}const y=this.dateTimeService.now(),x=1e3*g.iat,T=1e3*g.exp,N=this.getClockSkewInMsec();if(x-N>=y||T+N-this.decreaseExpirationBySec<=y){const A="Token has expired";return console.error(A),console.error({now:y,issuedAtMSec:x,expiresAtMSec:T}),Promise.reject(A)}const k={accessToken:i,idToken:t,jwks:this.jwks,idTokenClaims:g,idTokenHeader:c,loadKeys:()=>this.loadJwks()};return this.disableAtHashCheck?this.checkSignature(k).then(A=>({idToken:t,idTokenClaims:g,idTokenClaimsJson:p,idTokenHeader:c,idTokenHeaderJson:a,idTokenExpiresAt:T})):this.checkAtHash(k).then(A=>{if(!this.disableAtHashCheck&&this.requestAccessToken&&!A){const H="Wrong at_hash";return this.logger.warn(H),Promise.reject(H)}return this.checkSignature(k).then(H=>{const X={idToken:t,idTokenClaims:g,idTokenClaimsJson:p,idTokenHeader:c,idTokenHeaderJson:a,idTokenExpiresAt:T};return this.disableAtHashCheck?X:this.checkAtHash(k).then(se=>{if(this.requestAccessToken&&!se){const K="Wrong at_hash";return this.logger.warn(K),Promise.reject(K)}return X})})})}getIdentityClaims(){const t=this._storage.getItem("id_token_claims_obj");return t?JSON.parse(t):null}getGrantedScopes(){const t=this._storage.getItem("granted_scopes");return t?JSON.parse(t):null}getIdToken(){return this._storage?this._storage.getItem("id_token"):null}padBase64(t){for(;t.length%4!=0;)t+="=";return t}getAccessToken(){return this._storage?this._storage.getItem("access_token"):null}getRefreshToken(){return this._storage?this._storage.getItem("refresh_token"):null}getAccessTokenExpiration(){return this._storage.getItem("expires_at")?parseInt(this._storage.getItem("expires_at"),10):null}getAccessTokenStoredAt(){return parseInt(this._storage.getItem("access_token_stored_at"),10)}getIdTokenStoredAt(){return parseInt(this._storage.getItem("id_token_stored_at"),10)}getIdTokenExpiration(){return this._storage.getItem("id_token_expires_at")?parseInt(this._storage.getItem("id_token_expires_at"),10):null}hasValidAccessToken(){if(this.getAccessToken()){const t=this._storage.getItem("expires_at"),i=this.dateTimeService.new();return!(t&&parseInt(t,10)-this.decreaseExpirationBySec=0&&null!==this._storage.getItem(t)?JSON.parse(this._storage.getItem(t)):null}authorizationHeader(){return"Bearer "+this.getAccessToken()}logOut(t={},i=""){let r=!1;"boolean"==typeof t&&(r=t,t={});const s=this.getIdToken();if(this._storage.removeItem("access_token"),this._storage.removeItem("id_token"),this._storage.removeItem("refresh_token"),this.saveNoncesInLocalStorage?(localStorage.removeItem("nonce"),localStorage.removeItem("PKCE_verifier")):(this._storage.removeItem("nonce"),this._storage.removeItem("PKCE_verifier")),this._storage.removeItem("expires_at"),this._storage.removeItem("id_token_claims_obj"),this._storage.removeItem("id_token_expires_at"),this._storage.removeItem("id_token_stored_at"),this._storage.removeItem("access_token_stored_at"),this._storage.removeItem("granted_scopes"),this._storage.removeItem("session_state"),this.config.customTokenParameters&&this.config.customTokenParameters.forEach(a=>this._storage.removeItem(a)),this.silentRefreshSubject=null,this.eventsSubject.next(new jd("logout")),!this.logoutUrl||r)return;let o;if(!this.validateUrlForHttps(this.logoutUrl))throw new Error("logoutUrl must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).");if(this.logoutUrl.indexOf("{{")>-1)o=this.logoutUrl.replace(/\{\{id_token\}\}/,encodeURIComponent(s)).replace(/\{\{client_id\}\}/,encodeURIComponent(this.clientId));else{let a=new Za({encoder:new sy});s&&(a=a.set("id_token_hint",s));const c=this.postLogoutRedirectUri||this.redirectUriAsPostLogoutRedirectUriFallback&&this.redirectUri||"";c&&(a=a.set("post_logout_redirect_uri",c),i&&(a=a.set("state",i)));for(let u in t)a=a.set(u,t[u]);o=this.logoutUrl+(this.logoutUrl.indexOf("?")>-1?"&":"?")+a.toString()}this.config.openUri(o)}createAndSaveNonce(){const t=this;return this.createNonce().then(function(i){return t.saveNoncesInLocalStorage&&typeof window.localStorage<"u"?localStorage.setItem("nonce",i):t._storage.setItem("nonce",i),i})}ngOnDestroy(){this.clearAccessTokenTimer(),this.clearIdTokenTimer(),this.removeSilentRefreshEventListener();const t=this.document.getElementById(this.silentRefreshIFrameName);t&&t.remove(),this.stopSessionCheckTimer(),this.removeSessionCheckEventListener();const i=this.document.getElementById(this.sessionCheckIFrameName);i&&i.remove()}createNonce(){return new Promise(t=>{if(this.rngUrl)throw new Error("createNonce with rng-web-api has not been implemented so far");const i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~";let r=45,s="";const o=typeof self>"u"?null:self.crypto||self.msCrypto;if(o){let a=new Uint8Array(r);o.getRandomValues(a),a.map||(a.map=Array.prototype.map),a=a.map(c=>i.charCodeAt(c%i.length)),s=String.fromCharCode.apply(null,a)}else for(;0"discovery_document_loaded"===r.type)).subscribe(r=>this.initCodeFlowInternal(t,i))}initCodeFlowInternal(t="",i={}){if(!this.validateUrlForHttps(this.loginUrl))throw new Error("loginUrl must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).");let r={},s=null;"string"==typeof i?s=i:"object"==typeof i&&(r=i),this.createLoginUrl(t,s,null,!1,r).then(this.config.openUri).catch(o=>{console.error("Error in initAuthorizationCodeFlow"),console.error(o)})}createChallangeVerifierPairForPKCE(){var t=this;return fl(function*(){if(!t.crypto)throw new Error("PKCE support for code flow needs a CryptoHander. Did you import the OAuthModule using forRoot() ?");const i=yield t.createNonce();return[NA(yield t.crypto.calcHash(i,"sha-256")),i]})()}extractRecognizedCustomParameters(t){let i=new Map;return this.config.customTokenParameters&&this.config.customTokenParameters.forEach(r=>{t[r]&&i.set(r,JSON.stringify(t[r]))}),i}revokeTokenAndLogout(t={},i=!1){let r=this.revocationEndpoint,s=this.getAccessToken(),o=this.getRefreshToken();if(!s)return Promise.resolve();let a=new Za({encoder:new sy}),c=(new Ho).set("Content-Type","application/x-www-form-urlencoded");if(this.useHttpBasicAuth){const u=btoa(`${this.clientId}:${this.dummyClientSecret}`);c=c.set("Authorization","Basic "+u)}if(this.useHttpBasicAuth||(a=a.set("client_id",this.clientId)),!this.useHttpBasicAuth&&this.dummyClientSecret&&(a=a.set("client_secret",this.dummyClientSecret)),this.customQueryParams)for(const u of Object.getOwnPropertyNames(this.customQueryParams))a=a.set(u,this.customQueryParams[u]);return new Promise((u,p)=>{let g,v;if(s){let y=a.set("token",s).set("token_type_hint","access_token");g=this.http.post(r,y,{headers:c})}else g=Tt(null);if(o){let y=a.set("token",o).set("token_type_hint","refresh_token");v=this.http.post(r,y,{headers:c})}else v=Tt(null);i&&(g=g.pipe(da(y=>0===y.status?Tt(null):Pc(y))),v=v.pipe(da(y=>0===y.status?Tt(null):Pc(y)))),Fw([g,v]).subscribe(y=>{this.logOut(t),u(y),this.logger.info("Token successfully revoked")},y=>{this.logger.error("Error revoking token",y),this.eventsSubject.next(new cs("token_revoke_error",y)),p(y)})})}clearLocationHash(){""!=location.hash&&(location.hash="")}}return n.\u0275fac=function(t){return new(t||n)(xe(Xt),xe(Ju),xe(OA,8),xe(p5,8),xe(wS,8),xe(m5),xe(h5),xe(_5,8),xe(Mn),xe(PA))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class v5{}class uQ{handleError(e){return Pc(e)}}let hQ=(()=>{class n{constructor(t,i,r){this.oAuthService=t,this.errorHandler=i,this.moduleConfig=r}checkUrl(t){return this.moduleConfig.resourceServer.customUrlValidation?this.moduleConfig.resourceServer.customUrlValidation(t):!this.moduleConfig.resourceServer.allowedUrls||!!this.moduleConfig.resourceServer.allowedUrls.find(i=>t.toLowerCase().startsWith(i.toLowerCase()))}intercept(t,i){const r=t.url.toLowerCase();return this.moduleConfig&&this.moduleConfig.resourceServer&&this.checkUrl(r)?this.moduleConfig.resourceServer.sendAccessToken?fa(Tt(this.oAuthService.getAccessToken()).pipe(Ui(o=>!!o)),this.oAuthService.events.pipe(Ui(o=>"token_received"===o.type),function JJ(n,e=ag){return function XJ(n,e,t=ag){return i=>{let r=c5(n),s=r?+n-t.now():Math.abs(n);return i.lift(new ZJ(s,r,e,t))}}(n,Pc(new YJ),e)}(this.oAuthService.waitForTokenInMsec||0),da(o=>Tt(null)),_t(o=>this.oAuthService.getAccessToken()))).pipe(Gr(1),ur(o=>{if(o){const c=t.headers.set("Authorization","Bearer "+o);t=t.clone({headers:c})}return i.handle(t).pipe(da(a=>this.errorHandler.handleError(a)))})):i.handle(t).pipe(da(o=>this.errorHandler.handleError(o))):i.handle(t)}}return n.\u0275fac=function(t){return new(t||n)(xe(HA),xe(v5),xe(u5,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();function fQ(){return console}function pQ(){return typeof sessionStorage<"u"?sessionStorage:new eQ}function mQ(n=null,e=d5){return Fx([HA,m5,{provide:h5,useFactory:fQ},{provide:OA,useFactory:pQ},{provide:p5,useClass:e},{provide:_5,useClass:dQ},{provide:v5,useClass:uQ},{provide:u5,useValue:n},{provide:tT,useClass:hQ,multi:!0},{provide:PA,useClass:QJ}])}let gQ=(()=>{class n{static forRoot(t=null,i=d5){return{ngModule:n,providers:[mQ(t,i)]}}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[ul]}),n})();new Ze("AUTH_CONFIG");class vQ extends tQ{constructor(){super(...arguments),this.allowedAlgorithms=["HS256","HS384","HS512","RS256","RS384","RS512","ES256","ES384","PS256","PS384","PS512"],this.gracePeriodInSec=600}validateSignature(e,t=!1){if(!e.idToken)throw new Error("Parameter idToken expected!");if(!e.idTokenHeader)throw new Error("Parameter idTokenHandler expected.");if(!e.jwks)throw new Error("Parameter jwks expected!");if(!e.jwks.keys||!Array.isArray(e.jwks.keys)||0===e.jwks.keys.length)throw new Error("Array keys in jwks missing!");let s,i=e.idTokenHeader.kid,r=e.jwks.keys,o=e.idTokenHeader.alg;if(i)s=r.find(p=>p.kid===i);else{let p=this.alg2kty(o),g=r.filter(v=>v.kty===p&&"sig"===v.use);if(g.length>1){let v="More than one matching key found. Please specify a kid in the id_token header.";return console.error(v),Promise.reject(v)}1===g.length&&(s=g[0])}if(!s&&!t&&e.loadKeys)return e.loadKeys().then(p=>e.jwks=p).then(p=>this.validateSignature(e,!0));if(!s&&t&&!i){let p="No matching key found.";return console.error(p),Promise.reject(p)}if(!s&&t&&i){let p="expected key not found in property jwks. This property is most likely loaded with the discovery document. Expected key id (kid): "+i;return console.error(p),Promise.reject(p)}let a=kA.KZ.getKey(s);return kA.fs.jws.JWS.verifyJWT(e.idToken,a,{alg:this.allowedAlgorithms,gracePeriod:this.gracePeriodInSec})?Promise.resolve():Promise.reject("Signature not valid")}alg2kty(e){switch(e.charAt(0)){case"R":return"RSA";case"E":return"EC";default:throw new Error("Cannot infer kty from alg: "+e)}}calcHash(e,t){let r=new kA.fs.crypto.MessageDigest({alg:t}).digestString(e),s=this.toByteArrayAsString(r);return Promise.resolve(s)}toByteArrayAsString(e){let t="";for(let i=0;ie.startsWith(r))}intercept(e,t){let i=e.url.toLowerCase();if(!this.checkUrl(i))return t.handle(e);let r=e.headers;return i.indexOf("common/destiny2_content")>0||(r=r.set("X-API-Key",oy_bungie_apiKey),"https://www.bungie.net/platform/app/oauth/token/"===i||i.indexOf("getmembershipsbyid")>0||this.authStorage.getItem("access_token")&&(r=r.set("Authorization",`Bearer ${this.authStorage.getItem("access_token")}`)),i.indexOf("/Stats/Activities/")>-1&&(i=i.replace("www.bungie","stats.bungie"))),e=e.clone({headers:r}),t.handle(e)}}mg.\u0275fac=function(e){return new(e||mg)(xe(Wd))},mg.\u0275prov=Je({token:mg,factory:mg.\u0275fac,providedIn:"root"});const y5=new Ze("bungie service");class gg{}function b5(n,e){let t=!1;return arguments.length>=2&&(t=!0),function(r){return r.lift(new yQ(n,e,t))}}gg.\u0275fac=function(e){return new(e||gg)},gg.\u0275mod=Mt({type:gg}),gg.\u0275inj=On({providers:[Wd,{provide:y5,useClass:HA},{provide:tT,useClass:mg,multi:!0}],imports:[ul,gQ.forRoot()]});class yQ{constructor(e,t,i=!1){this.accumulator=e,this.seed=t,this.hasSeed=i}call(e,t){return t.subscribe(new bQ(e,this.accumulator,this.seed,this.hasSeed))}}class bQ extends di{constructor(e,t,i,r){super(e),this.accumulator=t,this._seed=i,this.hasSeed=r,this.index=0}get seed(){return this._seed}set seed(e){this.hasSeed=!0,this._seed=e}_next(e){if(this.hasSeed)return this._tryNext(e);this.seed=e,this.destination.next(e)}_tryNext(e){const t=this.index++;let i;try{i=this.accumulator(this.seed,e,t)}catch(r){this.destination.error(r)}this.seed=i,this.destination.next(i)}}function UA(n){return function(t){return 0===n?kw():t.lift(new xQ(n))}}class xQ{constructor(e){if(this.total=e,this.total<0)throw new DL}call(e,t){return t.subscribe(new wQ(e,this.total))}}class wQ extends di{constructor(e,t){super(e),this.total=t,this.ring=new Array,this.count=0}_next(e){const t=this.ring,i=this.total,r=this.count++;t.length0){const i=this.count>=this.total?this.total:this.count,r=this.ring;for(let s=0;s=2;return i=>i.pipe(n?Ui((r,s)=>n(r,s,i)):Is,UA(1),t?xS(e):l5(()=>new bS))}class EQ{constructor(e){this.value=e}call(e,t){return t.subscribe(new MQ(e,this.value))}}class MQ extends di{constructor(e,t){super(e),this.value=t}_next(e){this.destination.next(this.value)}}const jn="primary",ay=Symbol("RouteTitle");class CQ{constructor(e){this.params=e||{}}has(e){return Object.prototype.hasOwnProperty.call(this.params,e)}get(e){if(this.has(e)){const t=this.params[e];return Array.isArray(t)?t[0]:t}return null}getAll(e){if(this.has(e)){const t=this.params[e];return Array.isArray(t)?t:[t]}return[]}get keys(){return Object.keys(this.params)}}function _g(n){return new CQ(n)}function DQ(n,e,t){const i=t.path.split("/");if(i.length>n.length||"full"===t.pathMatch&&(e.hasChildren()||i.lengthi[s]===r)}return n===e}function S5(n){return Array.prototype.concat.apply([],n)}function E5(n){return n.length>0?n[n.length-1]:null}function So(n,e){for(const t in n)n.hasOwnProperty(t)&&e(n[t],t)}function ch(n){return PC(n)?n:lv(n)?dr(Promise.resolve(n)):Tt(n)}const ES=!1,AQ={exact:function D5(n,e,t){if(!Wf(n.segments,e.segments)||!MS(n.segments,e.segments,t)||n.numberOfChildren!==e.numberOfChildren)return!1;for(const i in e.children)if(!n.children[i]||!D5(n.children[i],e.children[i],t))return!1;return!0},subset:T5},M5={exact:function kQ(n,e){return Jl(n,e)},subset:function IQ(n,e){return Object.keys(e).length<=Object.keys(n).length&&Object.keys(e).every(t=>w5(n[t],e[t]))},ignored:()=>!0};function C5(n,e,t){return AQ[t.paths](n.root,e.root,t.matrixParams)&&M5[t.queryParams](n.queryParams,e.queryParams)&&!("exact"===t.fragment&&n.fragment!==e.fragment)}function T5(n,e,t){return A5(n,e,e.segments,t)}function A5(n,e,t,i){if(n.segments.length>t.length){const r=n.segments.slice(0,t.length);return!(!Wf(r,t)||e.hasChildren()||!MS(r,t,i))}if(n.segments.length===t.length){if(!Wf(n.segments,t)||!MS(n.segments,t,i))return!1;for(const r in e.children)if(!n.children[r]||!T5(n.children[r],e.children[r],i))return!1;return!0}{const r=t.slice(0,n.segments.length),s=t.slice(n.segments.length);return!!(Wf(n.segments,r)&&MS(n.segments,r,i)&&n.children[jn])&&A5(n.children[jn],e,s,i)}}function MS(n,e,t){return e.every((i,r)=>M5[t](n[r].parameters,i.parameters))}class lh{constructor(e=new ai([],{}),t={},i=null){this.root=e,this.queryParams=t,this.fragment=i}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=_g(this.queryParams)),this._queryParamMap}toString(){return PQ.serialize(this)}}class ai{constructor(e,t){this.segments=e,this.children=t,this.parent=null,So(t,(i,r)=>i.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return CS(this)}}class cy{constructor(e,t){this.path=e,this.parameters=t}get parameterMap(){return this._parameterMap||(this._parameterMap=_g(this.parameters)),this._parameterMap}toString(){return F5(this)}}function Wf(n,e){return n.length===e.length&&n.every((t,i)=>t.path===e[i].path)}let ly=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return new zA},providedIn:"root"}),n})();class zA{parse(e){const t=new GQ(e);return new lh(t.parseRootSegment(),t.parseQueryParams(),t.parseFragment())}serialize(e){const t=`/${dy(e.root,!0)}`,i=function NQ(n){const e=Object.keys(n).map(t=>{const i=n[t];return Array.isArray(i)?i.map(r=>`${DS(t)}=${DS(r)}`).join("&"):`${DS(t)}=${DS(i)}`}).filter(t=>!!t);return e.length?`?${e.join("&")}`:""}(e.queryParams),r="string"==typeof e.fragment?`#${function OQ(n){return encodeURI(n)}(e.fragment)}`:"";return`${t}${i}${r}`}}const PQ=new zA;function CS(n){return n.segments.map(e=>F5(e)).join("/")}function dy(n,e){if(!n.hasChildren())return CS(n);if(e){const t=n.children[jn]?dy(n.children[jn],!1):"",i=[];return So(n.children,(r,s)=>{s!==jn&&i.push(`${s}:${dy(r,!1)}`)}),i.length>0?`${t}(${i.join("//")})`:t}{const t=function RQ(n,e){let t=[];return So(n.children,(i,r)=>{r===jn&&(t=t.concat(e(i,r)))}),So(n.children,(i,r)=>{r!==jn&&(t=t.concat(e(i,r)))}),t}(n,(i,r)=>r===jn?[dy(n.children[jn],!1)]:[`${r}:${dy(i,!1)}`]);return 1===Object.keys(n.children).length&&null!=n.children[jn]?`${CS(n)}/${t[0]}`:`${CS(n)}/(${t.join("//")})`}}function k5(n){return encodeURIComponent(n).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function DS(n){return k5(n).replace(/%3B/gi,";")}function GA(n){return k5(n).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function TS(n){return decodeURIComponent(n)}function I5(n){return TS(n.replace(/\+/g,"%20"))}function F5(n){return`${GA(n.path)}${function LQ(n){return Object.keys(n).map(e=>`;${GA(e)}=${GA(n[e])}`).join("")}(n.parameters)}`}const BQ=/^[^\/()?;=#]+/;function AS(n){const e=n.match(BQ);return e?e[0]:""}const VQ=/^[^=?&#]+/,UQ=/^[^&#]+/;class GQ{constructor(e){this.url=e,this.remaining=e}parseRootSegment(){return this.consumeOptional("/"),""===this.remaining||this.peekStartsWith("?")||this.peekStartsWith("#")?new ai([],{}):new ai([],this.parseChildren())}parseQueryParams(){const e={};if(this.consumeOptional("?"))do{this.parseQueryParam(e)}while(this.consumeOptional("&"));return e}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(""===this.remaining)return{};this.consumeOptional("/");const e=[];for(this.peekStartsWith("(")||e.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),e.push(this.parseSegment());let t={};this.peekStartsWith("/(")&&(this.capture("/"),t=this.parseParens(!0));let i={};return this.peekStartsWith("(")&&(i=this.parseParens(!1)),(e.length>0||Object.keys(t).length>0)&&(i[jn]=new ai(e,t)),i}parseSegment(){const e=AS(this.remaining);if(""===e&&this.peekStartsWith(";"))throw new Ue(4009,ES);return this.capture(e),new cy(TS(e),this.parseMatrixParams())}parseMatrixParams(){const e={};for(;this.consumeOptional(";");)this.parseParam(e);return e}parseParam(e){const t=AS(this.remaining);if(!t)return;this.capture(t);let i="";if(this.consumeOptional("=")){const r=AS(this.remaining);r&&(i=r,this.capture(i))}e[TS(t)]=TS(i)}parseQueryParam(e){const t=function HQ(n){const e=n.match(VQ);return e?e[0]:""}(this.remaining);if(!t)return;this.capture(t);let i="";if(this.consumeOptional("=")){const o=function zQ(n){const e=n.match(UQ);return e?e[0]:""}(this.remaining);o&&(i=o,this.capture(i))}const r=I5(t),s=I5(i);if(e.hasOwnProperty(r)){let o=e[r];Array.isArray(o)||(o=[o],e[r]=o),o.push(s)}else e[r]=s}parseParens(e){const t={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){const i=AS(this.remaining),r=this.remaining[i.length];if("/"!==r&&")"!==r&&";"!==r)throw new Ue(4010,ES);let s;i.indexOf(":")>-1?(s=i.slice(0,i.indexOf(":")),this.capture(s),this.capture(":")):e&&(s=jn);const o=this.parseChildren();t[s]=1===Object.keys(o).length?o[jn]:new ai([],o),this.consumeOptional("//")}return t}peekStartsWith(e){return this.remaining.startsWith(e)}consumeOptional(e){return!!this.peekStartsWith(e)&&(this.remaining=this.remaining.substring(e.length),!0)}capture(e){if(!this.consumeOptional(e))throw new Ue(4011,ES)}}function jA(n){return n.segments.length>0?new ai([],{[jn]:n}):n}function kS(n){const e={};for(const i of Object.keys(n.children)){const s=kS(n.children[i]);(s.segments.length>0||s.hasChildren())&&(e[i]=s)}return function jQ(n){if(1===n.numberOfChildren&&n.children[jn]){const e=n.children[jn];return new ai(n.segments.concat(e.segments),e.children)}return n}(new ai(n.segments,e))}function $f(n){return n instanceof lh}const WA=!1;function WQ(n,e,t,i,r){if(0===t.length)return vg(e.root,e.root,e.root,i,r);const s=function N5(n){if("string"==typeof n[0]&&1===n.length&&"/"===n[0])return new L5(!0,0,n);let e=0,t=!1;const i=n.reduce((r,s,o)=>{if("object"==typeof s&&null!=s){if(s.outlets){const a={};return So(s.outlets,(c,u)=>{a[u]="string"==typeof c?c.split("/"):c}),[...r,{outlets:a}]}if(s.segmentPath)return[...r,s.segmentPath]}return"string"!=typeof s?[...r,s]:0===o?(s.split("/").forEach((a,c)=>{0==c&&"."===a||(0==c&&""===a?t=!0:".."===a?e++:""!=a&&r.push(a))}),r):[...r,s]},[]);return new L5(t,e,i)}(t);return s.toRoot()?vg(e.root,e.root,new ai([],{}),i,r):function o(c){const u=function qQ(n,e,t,i){if(n.isAbsolute)return new yg(e.root,!0,0);if(-1===i)return new yg(t,t===e.root,0);return function B5(n,e,t){let i=n,r=e,s=t;for(;s>r;){if(s-=r,i=i.parent,!i)throw new Ue(4005,WA&&"Invalid number of '../'");r=i.segments.length}return new yg(i,!1,r-s)}(t,i+(uy(n.commands[0])?0:1),n.numberOfDoubleDots)}(s,e,n.snapshot?._urlSegment,c),p=u.processChildren?bg(u.segmentGroup,u.index,s.commands):$A(u.segmentGroup,u.index,s.commands);return vg(e.root,u.segmentGroup,p,i,r)}(n.snapshot?._lastPathIndex)}function uy(n){return"object"==typeof n&&null!=n&&!n.outlets&&!n.segmentPath}function hy(n){return"object"==typeof n&&null!=n&&n.outlets}function vg(n,e,t,i,r){let o,s={};i&&So(i,(c,u)=>{s[u]=Array.isArray(c)?c.map(p=>`${p}`):`${c}`}),o=n===e?t:O5(n,e,t);const a=jA(kS(o));return new lh(a,s,r)}function O5(n,e,t){const i={};return So(n.children,(r,s)=>{i[s]=r===e?t:O5(r,e,t)}),new ai(n.segments,i)}class L5{constructor(e,t,i){if(this.isAbsolute=e,this.numberOfDoubleDots=t,this.commands=i,e&&i.length>0&&uy(i[0]))throw new Ue(4003,WA&&"Root segment cannot have matrix parameters");const r=i.find(hy);if(r&&r!==E5(i))throw new Ue(4004,WA&&"{outlets:{}} has to be the last command")}toRoot(){return this.isAbsolute&&1===this.commands.length&&"/"==this.commands[0]}}class yg{constructor(e,t,i){this.segmentGroup=e,this.processChildren=t,this.index=i}}function $A(n,e,t){if(n||(n=new ai([],{})),0===n.segments.length&&n.hasChildren())return bg(n,e,t);const i=function YQ(n,e,t){let i=0,r=e;const s={match:!1,pathIndex:0,commandIndex:0};for(;r=t.length)return s;const o=n.segments[r],a=t[i];if(hy(a))break;const c=`${a}`,u=i0&&void 0===c)break;if(c&&u&&"object"==typeof u&&void 0===u.outlets){if(!H5(c,u,o))return s;i+=2}else{if(!H5(c,{},o))return s;i++}r++}return{match:!0,pathIndex:r,commandIndex:i}}(n,e,t),r=t.slice(i.commandIndex);if(i.match&&i.pathIndex{"string"==typeof s&&(s=[s]),null!==s&&(r[o]=$A(n.children[o],e,s))}),So(n.children,(s,o)=>{void 0===i[o]&&(r[o]=s)}),new ai(n.segments,r))}}function qA(n,e,t){const i=n.segments.slice(0,e);let r=0;for(;r{"string"==typeof t&&(t=[t]),null!==t&&(e[i]=qA(new ai([],{}),0,t))}),e}function V5(n){const e={};return So(n,(t,i)=>e[i]=`${t}`),e}function H5(n,e,t){return n==t.path&&Jl(e,t.parameters)}const fy="imperative";class Ql{constructor(e,t){this.id=e,this.url=t}}class KA extends Ql{constructor(e,t,i="imperative",r=null){super(e,t),this.type=0,this.navigationTrigger=i,this.restoredState=r}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}}class qf extends Ql{constructor(e,t,i){super(e,t),this.urlAfterRedirects=i,this.type=1}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}}class IS extends Ql{constructor(e,t,i,r){super(e,t),this.reason=i,this.code=r,this.type=2}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}}class FS extends Ql{constructor(e,t,i,r){super(e,t),this.reason=i,this.code=r,this.type=16}}class YA extends Ql{constructor(e,t,i,r){super(e,t),this.error=i,this.target=r,this.type=3}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}}class ZQ extends Ql{constructor(e,t,i,r){super(e,t),this.urlAfterRedirects=i,this.state=r,this.type=4}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class JQ extends Ql{constructor(e,t,i,r){super(e,t),this.urlAfterRedirects=i,this.state=r,this.type=7}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class QQ extends Ql{constructor(e,t,i,r,s){super(e,t),this.urlAfterRedirects=i,this.state=r,this.shouldActivate=s,this.type=8}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}}class eee extends Ql{constructor(e,t,i,r){super(e,t),this.urlAfterRedirects=i,this.state=r,this.type=5}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class tee extends Ql{constructor(e,t,i,r){super(e,t),this.urlAfterRedirects=i,this.state=r,this.type=6}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class nee{constructor(e){this.route=e,this.type=9}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}}class iee{constructor(e){this.route=e,this.type=10}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}}class ree{constructor(e){this.snapshot=e,this.type=11}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class see{constructor(e){this.snapshot=e,this.type=12}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class oee{constructor(e){this.snapshot=e,this.type=13}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class aee{constructor(e){this.snapshot=e,this.type=14}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class U5{constructor(e,t,i){this.routerEvent=e,this.position=t,this.anchor=i,this.type=15}toString(){return`Scroll(anchor: '${this.anchor}', position: '${this.position?`${this.position[0]}, ${this.position[1]}`:null}')`}}let dee=(()=>{class n{createUrlTree(t,i,r,s,o,a){return WQ(t||i.root,r,s,o,a)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),hee=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(e){return dee.\u0275fac(e)},providedIn:"root"}),n})();class z5{constructor(e){this._root=e}get root(){return this._root.value}parent(e){const t=this.pathFromRoot(e);return t.length>1?t[t.length-2]:null}children(e){const t=XA(e,this._root);return t?t.children.map(i=>i.value):[]}firstChild(e){const t=XA(e,this._root);return t&&t.children.length>0?t.children[0].value:null}siblings(e){const t=ZA(e,this._root);return t.length<2?[]:t[t.length-2].children.map(r=>r.value).filter(r=>r!==e)}pathFromRoot(e){return ZA(e,this._root).map(t=>t.value)}}function XA(n,e){if(n===e.value)return e;for(const t of e.children){const i=XA(n,t);if(i)return i}return null}function ZA(n,e){if(n===e.value)return[e];for(const t of e.children){const i=ZA(n,t);if(i.length)return i.unshift(e),i}return[]}class $d{constructor(e,t){this.value=e,this.children=t}toString(){return`TreeNode(${this.value})`}}function xg(n){const e={};return n&&n.children.forEach(t=>e[t.value.outlet]=t),e}class G5 extends z5{constructor(e,t){super(e),this.snapshot=t,JA(this,e)}toString(){return this.snapshot.toString()}}function j5(n,e){const t=function fee(n,e){const o=new RS([],{},{},"",{},jn,e,null,n.root,-1,{});return new $5("",new $d(o,[]))}(n,e),i=new er([new cy("",{})]),r=new er({}),s=new er({}),o=new er({}),a=new er(""),c=new Kf(i,r,o,a,s,jn,e,t.root);return c.snapshot=t.root,new G5(new $d(c,[]),t)}class Kf{constructor(e,t,i,r,s,o,a,c){this.url=e,this.params=t,this.queryParams=i,this.fragment=r,this.data=s,this.outlet=o,this.component=a,this.title=this.data?.pipe(_t(u=>u[ay]))??Tt(void 0),this._futureSnapshot=c}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap||(this._paramMap=this.params.pipe(_t(e=>_g(e)))),this._paramMap}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=this.queryParams.pipe(_t(e=>_g(e)))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}}function W5(n,e="emptyOnly"){const t=n.pathFromRoot;let i=0;if("always"!==e)for(i=t.length-1;i>=1;){const r=t[i],s=t[i-1];if(r.routeConfig&&""===r.routeConfig.path)i--;else{if(s.component)break;i--}}return function pee(n){return n.reduce((e,t)=>({params:{...e.params,...t.params},data:{...e.data,...t.data},resolve:{...t.data,...e.resolve,...t.routeConfig?.data,...t._resolvedData}}),{params:{},data:{},resolve:{}})}(t.slice(i))}class RS{get title(){return this.data?.[ay]}constructor(e,t,i,r,s,o,a,c,u,p,g){this.url=e,this.params=t,this.queryParams=i,this.fragment=r,this.data=s,this.outlet=o,this.component=a,this.routeConfig=c,this._urlSegment=u,this._lastPathIndex=p,this._resolve=g}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap||(this._paramMap=_g(this.params)),this._paramMap}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=_g(this.queryParams)),this._queryParamMap}toString(){return`Route(url:'${this.url.map(i=>i.toString()).join("/")}', path:'${this.routeConfig?this.routeConfig.path:""}')`}}class $5 extends z5{constructor(e,t){super(t),this.url=e,JA(this,t)}toString(){return q5(this._root)}}function JA(n,e){e.value._routerState=n,e.children.forEach(t=>JA(n,t))}function q5(n){const e=n.children.length>0?` { ${n.children.map(q5).join(", ")} } `:"";return`${n.value}${e}`}function QA(n){if(n.snapshot){const e=n.snapshot,t=n._futureSnapshot;n.snapshot=t,Jl(e.queryParams,t.queryParams)||n.queryParams.next(t.queryParams),e.fragment!==t.fragment&&n.fragment.next(t.fragment),Jl(e.params,t.params)||n.params.next(t.params),function TQ(n,e){if(n.length!==e.length)return!1;for(let t=0;tJl(t.parameters,e[i].parameters))}(n.url,e.url);return t&&!(!n.parent!=!e.parent)&&(!n.parent||ek(n.parent,e.parent))}function py(n,e,t){if(t&&n.shouldReuseRoute(e.value,t.value.snapshot)){const i=t.value;i._futureSnapshot=e.value;const r=function gee(n,e,t){return e.children.map(i=>{for(const r of t.children)if(n.shouldReuseRoute(i.value,r.value.snapshot))return py(n,i,r);return py(n,i)})}(n,e,t);return new $d(i,r)}{if(n.shouldAttach(e.value)){const s=n.retrieve(e.value);if(null!==s){const o=s.route;return o.value._futureSnapshot=e.value,o.children=e.children.map(a=>py(n,a)),o}}const i=function _ee(n){return new Kf(new er(n.url),new er(n.params),new er(n.queryParams),new er(n.fragment),new er(n.data),n.outlet,n.component,n)}(e.value),r=e.children.map(s=>py(n,s));return new $d(i,r)}}const tk="ngNavigationCancelingError";function K5(n,e){const{redirectTo:t,navigationBehaviorOptions:i}=$f(e)?{redirectTo:e,navigationBehaviorOptions:void 0}:e,r=Y5(!1,0,e);return r.url=t,r.navigationBehaviorOptions=i,r}function Y5(n,e,t){const i=new Error("NavigationCancelingError: "+(n||""));return i[tk]=!0,i.cancellationCode=e,t&&(i.url=t),i}function X5(n){return Z5(n)&&$f(n.url)}function Z5(n){return n&&n[tk]}class vee{constructor(){this.outlet=null,this.route=null,this.resolver=null,this.injector=null,this.children=new my,this.attachRef=null}}let my=(()=>{class n{constructor(){this.contexts=new Map}onChildOutletCreated(t,i){const r=this.getOrCreateContext(t);r.outlet=i,this.contexts.set(t,r)}onChildOutletDestroyed(t){const i=this.getContext(t);i&&(i.outlet=null,i.attachRef=null)}onOutletDeactivated(){const t=this.contexts;return this.contexts=new Map,t}onOutletReAttached(t){this.contexts=t}getOrCreateContext(t){let i=this.getContext(t);return i||(i=new vee,this.contexts.set(t,i)),i}getContext(t){return this.contexts.get(t)||null}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const PS=!1;let J5=(()=>{class n{constructor(){this.activated=null,this._activatedRoute=null,this.name=jn,this.activateEvents=new Pn,this.deactivateEvents=new Pn,this.attachEvents=new Pn,this.detachEvents=new Pn,this.parentContexts=hn(my),this.location=hn(Sa),this.changeDetector=hn(aa),this.environmentInjector=hn(na)}ngOnChanges(t){if(t.name){const{firstChange:i,previousValue:r}=t.name;if(i)return;this.isTrackedInParentContexts(r)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(r)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name)}isTrackedInParentContexts(t){return this.parentContexts.getContext(t)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;const t=this.parentContexts.getContext(this.name);t?.route&&(t.attachRef?this.attach(t.attachRef,t.route):this.activateWith(t.route,t.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new Ue(4012,PS);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new Ue(4012,PS);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new Ue(4012,PS);this.location.detach();const t=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(t.instance),t}attach(t,i){this.activated=t,this._activatedRoute=i,this.location.insert(t.hostView),this.attachEvents.emit(t.instance)}deactivate(){if(this.activated){const t=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(t)}}activateWith(t,i){if(this.isActivated)throw new Ue(4013,PS);this._activatedRoute=t;const r=this.location,o=t.snapshot.component,a=this.parentContexts.getOrCreateContext(this.name).children,c=new yee(t,a,r.injector);if(i&&function bee(n){return!!n.resolveComponentFactory}(i)){const u=i.resolveComponentFactory(o);this.activated=r.createComponent(u,r.length,c)}else this.activated=r.createComponent(o,{index:r.length,injector:c,environmentInjector:i??this.environmentInjector});this.changeDetector.markForCheck(),this.activateEvents.emit(this.activated.instance)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["router-outlet"]],inputs:{name:"name"},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],standalone:!0,features:[Cn]}),n})();class yee{constructor(e,t,i){this.route=e,this.childContexts=t,this.parent=i}get(e,t){return e===Kf?this.route:e===my?this.childContexts:this.parent.get(e,t)}}let nk=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275cmp=Ln({type:n,selectors:[["ng-component"]],standalone:!0,features:[_v],decls:1,vars:0,template:function(t,i){1&t&&qt(0,"router-outlet")},dependencies:[J5],encapsulation:2}),n})();function Q5(n,e){return n.providers&&!n._injector&&(n._injector=O1(n.providers,e,`Route: ${n.path}`)),n._injector??e}function rk(n){const e=n.children&&n.children.map(rk),t=e?{...n,children:e}:{...n};return!t.component&&!t.loadComponent&&(e||t.loadChildren)&&t.outlet&&t.outlet!==jn&&(t.component=nk),t}function Nc(n){return n.outlet||jn}function e8(n,e){const t=n.filter(i=>Nc(i)===e);return t.push(...n.filter(i=>Nc(i)!==e)),t}function gy(n){if(!n)return null;if(n.routeConfig?._injector)return n.routeConfig._injector;for(let e=n.parent;e;e=e.parent){const t=e.routeConfig;if(t?._loadedInjector)return t._loadedInjector;if(t?._injector)return t._injector}return null}class Mee{constructor(e,t,i,r){this.routeReuseStrategy=e,this.futureState=t,this.currState=i,this.forwardEvent=r}activate(e){const t=this.futureState._root,i=this.currState?this.currState._root:null;this.deactivateChildRoutes(t,i,e),QA(this.futureState.root),this.activateChildRoutes(t,i,e)}deactivateChildRoutes(e,t,i){const r=xg(t);e.children.forEach(s=>{const o=s.value.outlet;this.deactivateRoutes(s,r[o],i),delete r[o]}),So(r,(s,o)=>{this.deactivateRouteAndItsChildren(s,i)})}deactivateRoutes(e,t,i){const r=e.value,s=t?t.value:null;if(r===s)if(r.component){const o=i.getContext(r.outlet);o&&this.deactivateChildRoutes(e,t,o.children)}else this.deactivateChildRoutes(e,t,i);else s&&this.deactivateRouteAndItsChildren(t,i)}deactivateRouteAndItsChildren(e,t){e.value.component&&this.routeReuseStrategy.shouldDetach(e.value.snapshot)?this.detachAndStoreRouteSubtree(e,t):this.deactivateRouteAndOutlet(e,t)}detachAndStoreRouteSubtree(e,t){const i=t.getContext(e.value.outlet),r=i&&e.value.component?i.children:t,s=xg(e);for(const o of Object.keys(s))this.deactivateRouteAndItsChildren(s[o],r);if(i&&i.outlet){const o=i.outlet.detach(),a=i.children.onOutletDeactivated();this.routeReuseStrategy.store(e.value.snapshot,{componentRef:o,route:e,contexts:a})}}deactivateRouteAndOutlet(e,t){const i=t.getContext(e.value.outlet),r=i&&e.value.component?i.children:t,s=xg(e);for(const o of Object.keys(s))this.deactivateRouteAndItsChildren(s[o],r);i&&i.outlet&&(i.outlet.deactivate(),i.children.onOutletDeactivated(),i.attachRef=null,i.resolver=null,i.route=null)}activateChildRoutes(e,t,i){const r=xg(t);e.children.forEach(s=>{this.activateRoutes(s,r[s.value.outlet],i),this.forwardEvent(new aee(s.value.snapshot))}),e.children.length&&this.forwardEvent(new see(e.value.snapshot))}activateRoutes(e,t,i){const r=e.value,s=t?t.value:null;if(QA(r),r===s)if(r.component){const o=i.getOrCreateContext(r.outlet);this.activateChildRoutes(e,t,o.children)}else this.activateChildRoutes(e,t,i);else if(r.component){const o=i.getOrCreateContext(r.outlet);if(this.routeReuseStrategy.shouldAttach(r.snapshot)){const a=this.routeReuseStrategy.retrieve(r.snapshot);this.routeReuseStrategy.store(r.snapshot,null),o.children.onOutletReAttached(a.contexts),o.attachRef=a.componentRef,o.route=a.route.value,o.outlet&&o.outlet.attach(a.componentRef,a.route.value),QA(a.route.value),this.activateChildRoutes(e,null,o.children)}else{const a=gy(r.snapshot),c=a?.get(Fd)??null;o.attachRef=null,o.route=r,o.resolver=c,o.injector=a,o.outlet&&o.outlet.activateWith(r,o.injector),this.activateChildRoutes(e,null,o.children)}}else this.activateChildRoutes(e,null,i)}}class t8{constructor(e){this.path=e,this.route=this.path[this.path.length-1]}}class OS{constructor(e,t){this.component=e,this.route=t}}function Cee(n,e,t){const i=n._root;return _y(i,e?e._root:null,t,[i.value])}function wg(n,e){const t=Symbol(),i=e.get(n,t);return i===t?"function"!=typeof n||function B0(n){return null!==_u(n)}(n)?e.get(n):n:i}function _y(n,e,t,i,r={canDeactivateChecks:[],canActivateChecks:[]}){const s=xg(e);return n.children.forEach(o=>{(function Tee(n,e,t,i,r={canDeactivateChecks:[],canActivateChecks:[]}){const s=n.value,o=e?e.value:null,a=t?t.getContext(n.value.outlet):null;if(o&&s.routeConfig===o.routeConfig){const c=function Aee(n,e,t){if("function"==typeof t)return t(n,e);switch(t){case"pathParamsChange":return!Wf(n.url,e.url);case"pathParamsOrQueryParamsChange":return!Wf(n.url,e.url)||!Jl(n.queryParams,e.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!ek(n,e)||!Jl(n.queryParams,e.queryParams);default:return!ek(n,e)}}(o,s,s.routeConfig.runGuardsAndResolvers);c?r.canActivateChecks.push(new t8(i)):(s.data=o.data,s._resolvedData=o._resolvedData),_y(n,e,s.component?a?a.children:null:t,i,r),c&&a&&a.outlet&&a.outlet.isActivated&&r.canDeactivateChecks.push(new OS(a.outlet.component,o))}else o&&vy(e,a,r),r.canActivateChecks.push(new t8(i)),_y(n,null,s.component?a?a.children:null:t,i,r)})(o,s[o.value.outlet],t,i.concat([o.value]),r),delete s[o.value.outlet]}),So(s,(o,a)=>vy(o,t.getContext(a),r)),r}function vy(n,e,t){const i=xg(n),r=n.value;So(i,(s,o)=>{vy(s,r.component?e?e.children.getContext(o):null:e,t)}),t.canDeactivateChecks.push(new OS(r.component&&e&&e.outlet&&e.outlet.isActivated?e.outlet.component:null,r))}function yy(n){return"function"==typeof n}function sk(n){return n instanceof bS||"EmptyError"===n?.name}const LS=Symbol("INITIAL_VALUE");function Sg(){return wo(n=>Fw(n.map(e=>e.pipe(Gr(1),Bf(LS)))).pipe(_t(e=>{for(const t of e)if(!0!==t){if(t===LS)return LS;if(!1===t||t instanceof lh)return t}return!0}),Ui(e=>e!==LS),Gr(1)))}function n8(n){return function Yr(...n){return Sr(n)}(Dr(e=>{if($f(e))throw K5(0,e)}),_t(e=>!0===e))}const ok={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function i8(n,e,t,i,r){const s=ak(n,e,t);return s.matched?function $ee(n,e,t,i){const r=e.canMatch;return r&&0!==r.length?Tt(r.map(o=>{const a=wg(o,n);return ch(function Oee(n){return n&&yy(n.canMatch)}(a)?a.canMatch(e,t):n.runInContext(()=>a(e,t)))})).pipe(Sg(),n8()):Tt(!0)}(i=Q5(e,i),e,t).pipe(_t(o=>!0===o?s:{...ok})):Tt(s)}function ak(n,e,t){if(""===e.path)return"full"===e.pathMatch&&(n.hasChildren()||t.length>0)?{...ok}:{matched:!0,consumedSegments:[],remainingSegments:t,parameters:{},positionalParamSegments:{}};const r=(e.matcher||DQ)(t,n,e);if(!r)return{...ok};const s={};So(r.posParams,(a,c)=>{s[c]=a.path});const o=r.consumed.length>0?{...s,...r.consumed[r.consumed.length-1].parameters}:s;return{matched:!0,consumedSegments:r.consumed,remainingSegments:t.slice(r.consumed.length),parameters:o,positionalParamSegments:r.posParams??{}}}function NS(n,e,t,i){if(t.length>0&&function Yee(n,e,t){return t.some(i=>BS(n,e,i)&&Nc(i)!==jn)}(n,t,i)){const s=new ai(e,function Kee(n,e,t,i){const r={};r[jn]=i,i._sourceSegment=n,i._segmentIndexShift=e.length;for(const s of t)if(""===s.path&&Nc(s)!==jn){const o=new ai([],{});o._sourceSegment=n,o._segmentIndexShift=e.length,r[Nc(s)]=o}return r}(n,e,i,new ai(t,n.children)));return s._sourceSegment=n,s._segmentIndexShift=e.length,{segmentGroup:s,slicedSegments:[]}}if(0===t.length&&function Xee(n,e,t){return t.some(i=>BS(n,e,i))}(n,t,i)){const s=new ai(n.segments,function qee(n,e,t,i,r){const s={};for(const o of i)if(BS(n,t,o)&&!r[Nc(o)]){const a=new ai([],{});a._sourceSegment=n,a._segmentIndexShift=e.length,s[Nc(o)]=a}return{...r,...s}}(n,e,t,i,n.children));return s._sourceSegment=n,s._segmentIndexShift=e.length,{segmentGroup:s,slicedSegments:t}}const r=new ai(n.segments,n.children);return r._sourceSegment=n,r._segmentIndexShift=e.length,{segmentGroup:r,slicedSegments:t}}function BS(n,e,t){return(!(n.hasChildren()||e.length>0)||"full"!==t.pathMatch)&&""===t.path}function r8(n,e,t,i){return!!(Nc(n)===i||i!==jn&&BS(e,t,n))&&("**"===n.path||ak(e,n,t).matched)}function s8(n,e,t){return 0===e.length&&!n.children[t]}const VS=!1;class HS{constructor(e){this.segmentGroup=e||null}}class o8{constructor(e){this.urlTree=e}}function by(n){return Pc(new HS(n))}function a8(n){return Pc(new o8(n))}function Zee(n){return Pc(new Ue(4e3,VS&&`Only absolute redirects can have named outlets. redirectTo: '${n}'`))}class ete{constructor(e,t,i,r,s){this.injector=e,this.configLoader=t,this.urlSerializer=i,this.urlTree=r,this.config=s,this.allowRedirects=!0}apply(){const e=NS(this.urlTree.root,[],[],this.config).segmentGroup,t=new ai(e.segments,e.children);return this.expandSegmentGroup(this.injector,this.config,t,jn).pipe(_t(s=>this.createUrlTree(kS(s),this.urlTree.queryParams,this.urlTree.fragment))).pipe(da(s=>{if(s instanceof o8)return this.allowRedirects=!1,this.match(s.urlTree);throw s instanceof HS?this.noMatchError(s):s}))}match(e){return this.expandSegmentGroup(this.injector,this.config,e.root,jn).pipe(_t(r=>this.createUrlTree(kS(r),e.queryParams,e.fragment))).pipe(da(r=>{throw r instanceof HS?this.noMatchError(r):r}))}noMatchError(e){return new Ue(4002,VS&&`Cannot match any routes. URL Segment: '${e.segmentGroup}'`)}createUrlTree(e,t,i){const r=jA(e);return new lh(r,t,i)}expandSegmentGroup(e,t,i,r){return 0===i.segments.length&&i.hasChildren()?this.expandChildren(e,t,i).pipe(_t(s=>new ai([],s))):this.expandSegment(e,i,t,i.segments,r,!0)}expandChildren(e,t,i){const r=[];for(const s of Object.keys(i.children))"primary"===s?r.unshift(s):r.push(s);return dr(r).pipe(Zu(s=>{const o=i.children[s],a=e8(t,s);return this.expandSegmentGroup(e,a,o,s).pipe(_t(c=>({segment:c,outlet:s})))}),b5((s,o)=>(s[o.outlet]=o.segment,s),{}),x5())}expandSegment(e,t,i,r,s,o){return dr(i).pipe(Zu(a=>this.expandSegmentAgainstRoute(e,t,i,a,r,s,o).pipe(da(u=>{if(u instanceof HS)return Tt(null);throw u}))),ml(a=>!!a),da((a,c)=>{if(sk(a))return s8(t,r,s)?Tt(new ai([],{})):by(t);throw a}))}expandSegmentAgainstRoute(e,t,i,r,s,o,a){return r8(r,t,s,o)?void 0===r.redirectTo?this.matchSegmentAgainstRoute(e,t,r,s,o):a&&this.allowRedirects?this.expandSegmentAgainstRouteUsingRedirect(e,t,i,r,s,o):by(t):by(t)}expandSegmentAgainstRouteUsingRedirect(e,t,i,r,s,o){return"**"===r.path?this.expandWildCardWithParamsAgainstRouteUsingRedirect(e,i,r,o):this.expandRegularSegmentAgainstRouteUsingRedirect(e,t,i,r,s,o)}expandWildCardWithParamsAgainstRouteUsingRedirect(e,t,i,r){const s=this.applyRedirectCommands([],i.redirectTo,{});return i.redirectTo.startsWith("/")?a8(s):this.lineralizeSegments(i,s).pipe(ur(o=>{const a=new ai(o,{});return this.expandSegment(e,a,t,o,r,!1)}))}expandRegularSegmentAgainstRouteUsingRedirect(e,t,i,r,s,o){const{matched:a,consumedSegments:c,remainingSegments:u,positionalParamSegments:p}=ak(t,r,s);if(!a)return by(t);const g=this.applyRedirectCommands(c,r.redirectTo,p);return r.redirectTo.startsWith("/")?a8(g):this.lineralizeSegments(r,g).pipe(ur(v=>this.expandSegment(e,t,i,v.concat(u),o,!1)))}matchSegmentAgainstRoute(e,t,i,r,s){return"**"===i.path?(e=Q5(i,e),i.loadChildren?(i._loadedRoutes?Tt({routes:i._loadedRoutes,injector:i._loadedInjector}):this.configLoader.loadChildren(e,i)).pipe(_t(a=>(i._loadedRoutes=a.routes,i._loadedInjector=a.injector,new ai(r,{})))):Tt(new ai(r,{}))):i8(t,i,r,e).pipe(wo(({matched:o,consumedSegments:a,remainingSegments:c})=>o?this.getChildConfig(e=i._injector??e,i,r).pipe(ur(p=>{const g=p.injector??e,v=p.routes,{segmentGroup:y,slicedSegments:x}=NS(t,a,c,v),T=new ai(y.segments,y.children);if(0===x.length&&T.hasChildren())return this.expandChildren(g,v,T).pipe(_t(H=>new ai(a,H)));if(0===v.length&&0===x.length)return Tt(new ai(a,{}));const N=Nc(i)===s;return this.expandSegment(g,T,v,x,N?jn:s,!0).pipe(_t(A=>new ai(a.concat(A.segments),A.children)))})):by(t)))}getChildConfig(e,t,i){return t.children?Tt({routes:t.children,injector:e}):t.loadChildren?void 0!==t._loadedRoutes?Tt({routes:t._loadedRoutes,injector:t._loadedInjector}):function Wee(n,e,t,i){const r=e.canLoad;return void 0===r||0===r.length?Tt(!0):Tt(r.map(o=>{const a=wg(o,n);return ch(function Iee(n){return n&&yy(n.canLoad)}(a)?a.canLoad(e,t):n.runInContext(()=>a(e,t)))})).pipe(Sg(),n8())}(e,t,i).pipe(ur(r=>r?this.configLoader.loadChildren(e,t).pipe(Dr(s=>{t._loadedRoutes=s.routes,t._loadedInjector=s.injector})):function Jee(n){return Pc(Y5(VS&&`Cannot load children because the guard of the route "path: '${n.path}'" returned false`,3))}(t))):Tt({routes:[],injector:e})}lineralizeSegments(e,t){let i=[],r=t.root;for(;;){if(i=i.concat(r.segments),0===r.numberOfChildren)return Tt(i);if(r.numberOfChildren>1||!r.children[jn])return Zee(e.redirectTo);r=r.children[jn]}}applyRedirectCommands(e,t,i){return this.applyRedirectCreateUrlTree(t,this.urlSerializer.parse(t),e,i)}applyRedirectCreateUrlTree(e,t,i,r){const s=this.createSegmentGroup(e,t.root,i,r);return new lh(s,this.createQueryParams(t.queryParams,this.urlTree.queryParams),t.fragment)}createQueryParams(e,t){const i={};return So(e,(r,s)=>{if("string"==typeof r&&r.startsWith(":")){const a=r.substring(1);i[s]=t[a]}else i[s]=r}),i}createSegmentGroup(e,t,i,r){const s=this.createSegments(e,t.segments,i,r);let o={};return So(t.children,(a,c)=>{o[c]=this.createSegmentGroup(e,a,i,r)}),new ai(s,o)}createSegments(e,t,i,r){return t.map(s=>s.path.startsWith(":")?this.findPosParam(e,s,r):this.findOrReturn(s,i))}findPosParam(e,t,i){const r=i[t.path.substring(1)];if(!r)throw new Ue(4001,VS&&`Cannot redirect to '${e}'. Cannot find '${t.path}'.`);return r}findOrReturn(e,t){let i=0;for(const r of t){if(r.path===e.path)return t.splice(i),r;i++}return e}}class nte{}class ste{constructor(e,t,i,r,s,o,a){this.injector=e,this.rootComponentType=t,this.config=i,this.urlTree=r,this.url=s,this.paramsInheritanceStrategy=o,this.urlSerializer=a}recognize(){const e=NS(this.urlTree.root,[],[],this.config.filter(t=>void 0===t.redirectTo)).segmentGroup;return this.processSegmentGroup(this.injector,this.config,e,jn).pipe(_t(t=>{if(null===t)return null;const i=new RS([],Object.freeze({}),Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,{},jn,this.rootComponentType,null,this.urlTree.root,-1,{}),r=new $d(i,t),s=new $5(this.url,r);return this.inheritParamsAndData(s._root),s}))}inheritParamsAndData(e){const t=e.value,i=W5(t,this.paramsInheritanceStrategy);t.params=Object.freeze(i.params),t.data=Object.freeze(i.data),e.children.forEach(r=>this.inheritParamsAndData(r))}processSegmentGroup(e,t,i,r){return 0===i.segments.length&&i.hasChildren()?this.processChildren(e,t,i):this.processSegment(e,t,i,i.segments,r)}processChildren(e,t,i){return dr(Object.keys(i.children)).pipe(Zu(r=>{const s=i.children[r],o=e8(t,r);return this.processSegmentGroup(e,o,s,r)}),b5((r,s)=>r&&s?(r.push(...s),r):null),AN(r=>null!==r),xS(null),x5(),_t(r=>{if(null===r)return null;const s=l8(r);return function ote(n){n.sort((e,t)=>e.value.outlet===jn?-1:t.value.outlet===jn?1:e.value.outlet.localeCompare(t.value.outlet))}(s),s}))}processSegment(e,t,i,r,s){return dr(t).pipe(Zu(o=>this.processSegmentAgainstRoute(o._injector??e,o,i,r,s)),ml(o=>!!o),da(o=>{if(sk(o))return s8(i,r,s)?Tt([]):Tt(null);throw o}))}processSegmentAgainstRoute(e,t,i,r,s){if(t.redirectTo||!r8(t,i,r,s))return Tt(null);let o;if("**"===t.path){const a=r.length>0?E5(r).parameters:{},c=u8(i)+r.length;o=Tt({snapshot:new RS(r,a,Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,h8(t),Nc(t),t.component??t._loadedComponent??null,t,d8(i),c,f8(t)),consumedSegments:[],remainingSegments:[]})}else o=i8(i,t,r,e).pipe(_t(({matched:a,consumedSegments:c,remainingSegments:u,parameters:p})=>{if(!a)return null;const g=u8(i)+c.length;return{snapshot:new RS(c,p,Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,h8(t),Nc(t),t.component??t._loadedComponent??null,t,d8(i),g,f8(t)),consumedSegments:c,remainingSegments:u}}));return o.pipe(wo(a=>{if(null===a)return Tt(null);const{snapshot:c,consumedSegments:u,remainingSegments:p}=a;e=t._injector??e;const g=t._loadedInjector??e,v=function ate(n){return n.children?n.children:n.loadChildren?n._loadedRoutes:[]}(t),{segmentGroup:y,slicedSegments:x}=NS(i,u,p,v.filter(N=>void 0===N.redirectTo));if(0===x.length&&y.hasChildren())return this.processChildren(g,v,y).pipe(_t(N=>null===N?null:[new $d(c,N)]));if(0===v.length&&0===x.length)return Tt([new $d(c,[])]);const T=Nc(t)===s;return this.processSegment(g,v,y,x,T?jn:s).pipe(_t(N=>null===N?null:[new $d(c,N)]))}))}}function cte(n){const e=n.value.routeConfig;return e&&""===e.path&&void 0===e.redirectTo}function l8(n){const e=[],t=new Set;for(const i of n){if(!cte(i)){e.push(i);continue}const r=e.find(s=>i.value.routeConfig===s.value.routeConfig);void 0!==r?(r.children.push(...i.children),t.add(r)):e.push(i)}for(const i of t){const r=l8(i.children);e.push(new $d(i.value,r))}return e.filter(i=>!t.has(i))}function d8(n){let e=n;for(;e._sourceSegment;)e=e._sourceSegment;return e}function u8(n){let e=n,t=e._segmentIndexShift??0;for(;e._sourceSegment;)e=e._sourceSegment,t+=e._segmentIndexShift??0;return t-1}function h8(n){return n.data||{}}function f8(n){return n.resolve||{}}function p8(n){return"string"==typeof n.title||null===n.title}function ck(n){return wo(e=>{const t=n(e);return t?dr(t).pipe(_t(()=>e)):Tt(e)})}const Eg=new Ze("ROUTES");let lk=(()=>{class n{constructor(t,i){this.injector=t,this.compiler=i,this.componentLoaders=new WeakMap,this.childrenLoaders=new WeakMap}loadComponent(t){if(this.componentLoaders.get(t))return this.componentLoaders.get(t);if(t._loadedComponent)return Tt(t._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(t);const i=ch(t.loadComponent()).pipe(_t(g8),Dr(s=>{this.onLoadEndListener&&this.onLoadEndListener(t),t._loadedComponent=s}),Jw(()=>{this.componentLoaders.delete(t)})),r=new ld(i,()=>new cn).pipe(hc());return this.componentLoaders.set(t,r),r}loadChildren(t,i){if(this.childrenLoaders.get(i))return this.childrenLoaders.get(i);if(i._loadedRoutes)return Tt({routes:i._loadedRoutes,injector:i._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(i);const s=this.loadModuleFactoryOrRoutes(i.loadChildren).pipe(_t(a=>{this.onLoadEndListener&&this.onLoadEndListener(i);let c,u,p=!1;Array.isArray(a)?u=a:(c=a.create(t).injector,u=S5(c.get(Eg,[],tn.Self|tn.Optional)));return{routes:u.map(rk),injector:c}}),Jw(()=>{this.childrenLoaders.delete(i)})),o=new ld(s,()=>new cn).pipe(hc());return this.childrenLoaders.set(i,o),o}loadModuleFactoryOrRoutes(t){return ch(t()).pipe(_t(g8),ur(r=>r instanceof KR||Array.isArray(r)?Tt(r):dr(this.compiler.compileModuleAsync(r))))}}return n.\u0275fac=function(t){return new(t||n)(xe(ts),xe(LP))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function g8(n){return function _te(n){return n&&"object"==typeof n&&"default"in n}(n)?n.default:n}let zS=(()=>{class n{get hasRequestedNavigation(){return 0!==this.navigationId}constructor(){this.currentNavigation=null,this.lastSuccessfulNavigation=null,this.events=new cn,this.configLoader=hn(lk),this.environmentInjector=hn(na),this.urlSerializer=hn(ly),this.rootContexts=hn(my),this.navigationId=0,this.afterPreactivation=()=>Tt(void 0),this.rootComponentType=null,this.configLoader.onLoadEndListener=r=>this.events.next(new iee(r)),this.configLoader.onLoadStartListener=r=>this.events.next(new nee(r))}complete(){this.transitions?.complete()}handleNavigationRequest(t){const i=++this.navigationId;this.transitions?.next({...this.transitions.value,...t,id:i})}setupNavigations(t){return this.transitions=new er({id:0,targetPageId:0,currentUrlTree:t.currentUrlTree,currentRawUrl:t.currentUrlTree,extractedUrl:t.urlHandlingStrategy.extract(t.currentUrlTree),urlAfterRedirects:t.urlHandlingStrategy.extract(t.currentUrlTree),rawUrl:t.currentUrlTree,extras:{},resolve:null,reject:null,promise:Promise.resolve(!0),source:fy,restoredState:null,currentSnapshot:t.routerState.snapshot,targetSnapshot:null,currentRouterState:t.routerState,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.transitions.pipe(Ui(i=>0!==i.id),_t(i=>({...i,extractedUrl:t.urlHandlingStrategy.extract(i.rawUrl)})),wo(i=>{let r=!1,s=!1;return Tt(i).pipe(Dr(o=>{this.currentNavigation={id:o.id,initialUrl:o.rawUrl,extractedUrl:o.extractedUrl,trigger:o.source,extras:o.extras,previousNavigation:this.lastSuccessfulNavigation?{...this.lastSuccessfulNavigation,previousNavigation:null}:null}}),wo(o=>{const a=t.browserUrlTree.toString(),c=!t.navigated||o.extractedUrl.toString()!==a||a!==t.currentUrlTree.toString();if(!c&&"reload"!==(o.extras.onSameUrlNavigation??t.onSameUrlNavigation)){const p="";return this.events.next(new FS(o.id,t.serializeUrl(i.rawUrl),p,0)),t.rawUrlTree=o.rawUrl,o.resolve(null),Fc}if(t.urlHandlingStrategy.shouldProcessUrl(o.rawUrl))return _8(o.source)&&(t.browserUrlTree=o.extractedUrl),Tt(o).pipe(wo(p=>{const g=this.transitions?.getValue();return this.events.next(new KA(p.id,this.urlSerializer.serialize(p.extractedUrl),p.source,p.restoredState)),g!==this.transitions?.getValue()?Fc:Promise.resolve(p)}),function tte(n,e,t,i){return wo(r=>function Qee(n,e,t,i,r){return new ete(n,e,t,i,r).apply()}(n,e,t,r.extractedUrl,i).pipe(_t(s=>({...r,urlAfterRedirects:s}))))}(this.environmentInjector,this.configLoader,this.urlSerializer,t.config),Dr(p=>{this.currentNavigation={...this.currentNavigation,finalUrl:p.urlAfterRedirects},i.urlAfterRedirects=p.urlAfterRedirects}),function dte(n,e,t,i,r){return ur(s=>function rte(n,e,t,i,r,s,o="emptyOnly"){return new ste(n,e,t,i,r,o,s).recognize().pipe(wo(a=>null===a?function ite(n){return new un(e=>e.error(n))}(new nte):Tt(a)))}(n,e,t,s.urlAfterRedirects,i.serialize(s.urlAfterRedirects),i,r).pipe(_t(o=>({...s,targetSnapshot:o}))))}(this.environmentInjector,this.rootComponentType,t.config,this.urlSerializer,t.paramsInheritanceStrategy),Dr(p=>{if(i.targetSnapshot=p.targetSnapshot,"eager"===t.urlUpdateStrategy){if(!p.extras.skipLocationChange){const v=t.urlHandlingStrategy.merge(p.urlAfterRedirects,p.rawUrl);t.setBrowserUrl(v,p)}t.browserUrlTree=p.urlAfterRedirects}const g=new ZQ(p.id,this.urlSerializer.serialize(p.extractedUrl),this.urlSerializer.serialize(p.urlAfterRedirects),p.targetSnapshot);this.events.next(g)}));if(c&&t.urlHandlingStrategy.shouldProcessUrl(t.rawUrlTree)){const{id:p,extractedUrl:g,source:v,restoredState:y,extras:x}=o,T=new KA(p,this.urlSerializer.serialize(g),v,y);this.events.next(T);const N=j5(g,this.rootComponentType).snapshot;return Tt(i={...o,targetSnapshot:N,urlAfterRedirects:g,extras:{...x,skipLocationChange:!1,replaceUrl:!1}})}{const p="";return this.events.next(new FS(o.id,t.serializeUrl(i.extractedUrl),p,1)),t.rawUrlTree=o.rawUrl,o.resolve(null),Fc}}),Dr(o=>{const a=new JQ(o.id,this.urlSerializer.serialize(o.extractedUrl),this.urlSerializer.serialize(o.urlAfterRedirects),o.targetSnapshot);this.events.next(a)}),_t(o=>i={...o,guards:Cee(o.targetSnapshot,o.currentSnapshot,this.rootContexts)}),function Nee(n,e){return ur(t=>{const{targetSnapshot:i,currentSnapshot:r,guards:{canActivateChecks:s,canDeactivateChecks:o}}=t;return 0===o.length&&0===s.length?Tt({...t,guardsResult:!0}):function Bee(n,e,t,i){return dr(n).pipe(ur(r=>function jee(n,e,t,i,r){const s=e&&e.routeConfig?e.routeConfig.canDeactivate:null;return s&&0!==s.length?Tt(s.map(a=>{const c=gy(e)??r,u=wg(a,c);return ch(function Pee(n){return n&&yy(n.canDeactivate)}(u)?u.canDeactivate(n,e,t,i):c.runInContext(()=>u(n,e,t,i))).pipe(ml())})).pipe(Sg()):Tt(!0)}(r.component,r.route,t,e,i)),ml(r=>!0!==r,!0))}(o,i,r,n).pipe(ur(a=>a&&function kee(n){return"boolean"==typeof n}(a)?function Vee(n,e,t,i){return dr(e).pipe(Zu(r=>Rw(function Uee(n,e){return null!==n&&e&&e(new ree(n)),Tt(!0)}(r.route.parent,i),function Hee(n,e){return null!==n&&e&&e(new oee(n)),Tt(!0)}(r.route,i),function Gee(n,e,t){const i=e[e.length-1],s=e.slice(0,e.length-1).reverse().map(o=>function Dee(n){const e=n.routeConfig?n.routeConfig.canActivateChild:null;return e&&0!==e.length?{node:n,guards:e}:null}(o)).filter(o=>null!==o).map(o=>Yv(()=>Tt(o.guards.map(c=>{const u=gy(o.node)??t,p=wg(c,u);return ch(function Ree(n){return n&&yy(n.canActivateChild)}(p)?p.canActivateChild(i,n):u.runInContext(()=>p(i,n))).pipe(ml())})).pipe(Sg())));return Tt(s).pipe(Sg())}(n,r.path,t),function zee(n,e,t){const i=e.routeConfig?e.routeConfig.canActivate:null;if(!i||0===i.length)return Tt(!0);const r=i.map(s=>Yv(()=>{const o=gy(e)??t,a=wg(s,o);return ch(function Fee(n){return n&&yy(n.canActivate)}(a)?a.canActivate(e,n):o.runInContext(()=>a(e,n))).pipe(ml())}));return Tt(r).pipe(Sg())}(n,r.route,t))),ml(r=>!0!==r,!0))}(i,s,n,e):Tt(a)),_t(a=>({...t,guardsResult:a})))})}(this.environmentInjector,o=>this.events.next(o)),Dr(o=>{if(i.guardsResult=o.guardsResult,$f(o.guardsResult))throw K5(0,o.guardsResult);const a=new QQ(o.id,this.urlSerializer.serialize(o.extractedUrl),this.urlSerializer.serialize(o.urlAfterRedirects),o.targetSnapshot,!!o.guardsResult);this.events.next(a)}),Ui(o=>!!o.guardsResult||(t.restoreHistory(o),this.cancelNavigationTransition(o,"",3),!1)),ck(o=>{if(o.guards.canActivateChecks.length)return Tt(o).pipe(Dr(a=>{const c=new eee(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);this.events.next(c)}),wo(a=>{let c=!1;return Tt(a).pipe(function ute(n,e){return ur(t=>{const{targetSnapshot:i,guards:{canActivateChecks:r}}=t;if(!r.length)return Tt(t);let s=0;return dr(r).pipe(Zu(o=>function hte(n,e,t,i){const r=n.routeConfig,s=n._resolve;return void 0!==r?.title&&!p8(r)&&(s[ay]=r.title),function fte(n,e,t,i){const r=function pte(n){return[...Object.keys(n),...Object.getOwnPropertySymbols(n)]}(n);if(0===r.length)return Tt({});const s={};return dr(r).pipe(ur(o=>function mte(n,e,t,i){const r=gy(e)??i,s=wg(n,r);return ch(s.resolve?s.resolve(e,t):r.runInContext(()=>s(e,t)))}(n[o],e,t,i).pipe(ml(),Dr(a=>{s[o]=a}))),UA(1),function SQ(n){return e=>e.lift(new EQ(n))}(s),da(o=>sk(o)?Fc:Pc(o)))}(s,n,e,i).pipe(_t(o=>(n._resolvedData=o,n.data=W5(n,t).resolve,r&&p8(r)&&(n.data[ay]=r.title),null)))}(o.route,i,n,e)),Dr(()=>s++),UA(1),ur(o=>s===r.length?Tt(t):Fc))})}(t.paramsInheritanceStrategy,this.environmentInjector),Dr({next:()=>c=!0,complete:()=>{c||(t.restoreHistory(a),this.cancelNavigationTransition(a,"",2))}}))}),Dr(a=>{const c=new tee(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);this.events.next(c)}))}),ck(o=>{const a=c=>{const u=[];c.routeConfig?.loadComponent&&!c.routeConfig._loadedComponent&&u.push(this.configLoader.loadComponent(c.routeConfig).pipe(Dr(p=>{c.component=p}),_t(()=>{})));for(const p of c.children)u.push(...a(p));return u};return Fw(a(o.targetSnapshot.root)).pipe(xS(),Gr(1))}),ck(()=>this.afterPreactivation()),_t(o=>{const a=function mee(n,e,t){const i=py(n,e._root,t?t._root:void 0);return new G5(i,e)}(t.routeReuseStrategy,o.targetSnapshot,o.currentRouterState);return i={...o,targetRouterState:a}}),Dr(o=>{t.currentUrlTree=o.urlAfterRedirects,t.rawUrlTree=t.urlHandlingStrategy.merge(o.urlAfterRedirects,o.rawUrl),t.routerState=o.targetRouterState,"deferred"===t.urlUpdateStrategy&&(o.extras.skipLocationChange||t.setBrowserUrl(t.rawUrlTree,o),t.browserUrlTree=o.urlAfterRedirects)}),((n,e,t)=>_t(i=>(new Mee(e,i.targetRouterState,i.currentRouterState,t).activate(n),i)))(this.rootContexts,t.routeReuseStrategy,o=>this.events.next(o)),Dr({next:o=>{r=!0,this.lastSuccessfulNavigation=this.currentNavigation,t.navigated=!0,this.events.next(new qf(o.id,this.urlSerializer.serialize(o.extractedUrl),this.urlSerializer.serialize(t.currentUrlTree))),t.titleStrategy?.updateTitle(o.targetRouterState.snapshot),o.resolve(!0)},complete:()=>{r=!0}}),Jw(()=>{r||s||this.cancelNavigationTransition(i,"",1),this.currentNavigation?.id===i.id&&(this.currentNavigation=null)}),da(o=>{if(s=!0,Z5(o)){X5(o)||(t.navigated=!0,t.restoreHistory(i,!0));const a=new IS(i.id,this.urlSerializer.serialize(i.extractedUrl),o.message,o.cancellationCode);if(this.events.next(a),X5(o)){const c=t.urlHandlingStrategy.merge(o.url,t.rawUrlTree),u={skipLocationChange:i.extras.skipLocationChange,replaceUrl:"eager"===t.urlUpdateStrategy||_8(i.source)};t.scheduleNavigation(c,fy,null,u,{resolve:i.resolve,reject:i.reject,promise:i.promise})}else i.resolve(!1)}else{t.restoreHistory(i,!0);const a=new YA(i.id,this.urlSerializer.serialize(i.extractedUrl),o,i.targetSnapshot??void 0);this.events.next(a);try{i.resolve(t.errorHandler(o))}catch(c){i.reject(c)}}return Fc}))}))}cancelNavigationTransition(t,i,r){const s=new IS(t.id,this.urlSerializer.serialize(t.extractedUrl),i,r);this.events.next(s),t.resolve(!1)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function _8(n){return n!==fy}let v8=(()=>{class n{buildTitle(t){let i,r=t.root;for(;void 0!==r;)i=this.getResolvedTitleForRoute(r)??i,r=r.children.find(s=>s.outlet===jn);return i}getResolvedTitleForRoute(t){return t.data[ay]}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return hn(vte)},providedIn:"root"}),n})(),vte=(()=>{class n extends v8{constructor(t){super(),this.title=t}updateTitle(t){const i=this.buildTitle(t);void 0!==i&&this.title.setTitle(i)}}return n.\u0275fac=function(t){return new(t||n)(xe(iO))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),yte=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return hn(xte)},providedIn:"root"}),n})();class bte{shouldDetach(e){return!1}store(e,t){}shouldAttach(e){return!1}retrieve(e){return null}shouldReuseRoute(e,t){return e.routeConfig===t.routeConfig}}let xte=(()=>{class n extends bte{}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const GS=new Ze("",{providedIn:"root",factory:()=>({})});let Ste=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return hn(Ete)},providedIn:"root"}),n})(),Ete=(()=>{class n{shouldProcessUrl(t){return!0}extract(t){return t}merge(t,i){return t}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function Mte(n){throw n}function Cte(n,e,t){return e.parse("/")}const Dte={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},Tte={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"};let nc=(()=>{class n{get navigationId(){return this.navigationTransitions.navigationId}get browserPageId(){return this.location.getState()?.\u0275routerPageId}get events(){return this.navigationTransitions.events}constructor(){this.disposed=!1,this.currentPageId=0,this.console=hn(G9),this.isNgZoneEnabled=!1,this.options=hn(GS,{optional:!0})||{},this.errorHandler=this.options.errorHandler||Mte,this.malformedUriErrorHandler=this.options.malformedUriErrorHandler||Cte,this.navigated=!1,this.lastSuccessfulId=-1,this.urlHandlingStrategy=hn(Ste),this.routeReuseStrategy=hn(yte),this.urlCreationStrategy=hn(hee),this.titleStrategy=hn(v8),this.onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore",this.paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly",this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.canceledNavigationResolution=this.options.canceledNavigationResolution||"replace",this.config=S5(hn(Eg,{optional:!0})??[]),this.navigationTransitions=hn(zS),this.urlSerializer=hn(ly),this.location=hn(Mv),this.isNgZoneEnabled=hn(Xt)instanceof Xt&&Xt.isInAngularZone(),this.resetConfig(this.config),this.currentUrlTree=new lh,this.rawUrlTree=this.currentUrlTree,this.browserUrlTree=this.currentUrlTree,this.routerState=j5(this.currentUrlTree,null),this.navigationTransitions.setupNavigations(this).subscribe(t=>{this.lastSuccessfulId=t.id,this.currentPageId=t.targetPageId},t=>{this.console.warn(`Unhandled Navigation Error: ${t}`)})}resetRootComponentType(t){this.routerState.root.component=t,this.navigationTransitions.rootComponentType=t}initialNavigation(){if(this.setUpLocationChangeListener(),!this.navigationTransitions.hasRequestedNavigation){const t=this.location.getState();this.navigateToSyncWithBrowser(this.location.path(!0),fy,t)}}setUpLocationChangeListener(){this.locationSubscription||(this.locationSubscription=this.location.subscribe(t=>{const i="popstate"===t.type?"popstate":"hashchange";"popstate"===i&&setTimeout(()=>{this.navigateToSyncWithBrowser(t.url,i,t.state)},0)}))}navigateToSyncWithBrowser(t,i,r){const s={replaceUrl:!0},o=r?.navigationId?r:null;if(r){const c={...r};delete c.navigationId,delete c.\u0275routerPageId,0!==Object.keys(c).length&&(s.state=c)}const a=this.parseUrl(t);this.scheduleNavigation(a,i,o,s)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}resetConfig(t){this.config=t.map(rk),this.navigated=!1,this.lastSuccessfulId=-1}ngOnDestroy(){this.dispose()}dispose(){this.navigationTransitions.complete(),this.locationSubscription&&(this.locationSubscription.unsubscribe(),this.locationSubscription=void 0),this.disposed=!0}createUrlTree(t,i={}){const{relativeTo:r,queryParams:s,fragment:o,queryParamsHandling:a,preserveFragment:c}=i,u=c?this.currentUrlTree.fragment:o;let p=null;switch(a){case"merge":p={...this.currentUrlTree.queryParams,...s};break;case"preserve":p=this.currentUrlTree.queryParams;break;default:p=s||null}return null!==p&&(p=this.removeEmptyProps(p)),this.urlCreationStrategy.createUrlTree(r,this.routerState,this.currentUrlTree,t,p,u??null)}navigateByUrl(t,i={skipLocationChange:!1}){const r=$f(t)?t:this.parseUrl(t),s=this.urlHandlingStrategy.merge(r,this.rawUrlTree);return this.scheduleNavigation(s,fy,null,i)}navigate(t,i={skipLocationChange:!1}){return function Ate(n){for(let e=0;e{const s=t[r];return null!=s&&(i[r]=s),i},{})}scheduleNavigation(t,i,r,s,o){if(this.disposed)return Promise.resolve(!1);let a,c,u,p;return o?(a=o.resolve,c=o.reject,u=o.promise):u=new Promise((g,v)=>{a=g,c=v}),p="computed"===this.canceledNavigationResolution?r&&r.\u0275routerPageId?r.\u0275routerPageId:s.replaceUrl||s.skipLocationChange?this.browserPageId??0:(this.browserPageId??0)+1:0,this.navigationTransitions.handleNavigationRequest({targetPageId:p,source:i,restoredState:r,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:t,extras:s,resolve:a,reject:c,promise:u,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),u.catch(g=>Promise.reject(g))}setBrowserUrl(t,i){const r=this.urlSerializer.serialize(t),s={...i.extras.state,...this.generateNgRouterState(i.id,i.targetPageId)};this.location.isCurrentPathEqualTo(r)||i.extras.replaceUrl?this.location.replaceState(r,"",s):this.location.go(r,"",s)}restoreHistory(t,i=!1){if("computed"===this.canceledNavigationResolution){const r=this.currentPageId-t.targetPageId;"popstate"!==t.source&&"eager"!==this.urlUpdateStrategy&&this.currentUrlTree!==this.getCurrentNavigation()?.finalUrl||0===r?this.currentUrlTree===this.getCurrentNavigation()?.finalUrl&&0===r&&(this.resetState(t),this.browserUrlTree=t.currentUrlTree,this.resetUrlToCurrentUrlTree()):this.location.historyGo(r)}else"replace"===this.canceledNavigationResolution&&(i&&this.resetState(t),this.resetUrlToCurrentUrlTree())}resetState(t){this.routerState=t.currentRouterState,this.currentUrlTree=t.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,t.rawUrl)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(t,i){return"computed"===this.canceledNavigationResolution?{navigationId:t,\u0275routerPageId:i}:{navigationId:t}}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();class y8{}let Fte=(()=>{class n{constructor(t,i,r,s,o){this.router=t,this.injector=r,this.preloadingStrategy=s,this.loader=o}setUpPreloading(){this.subscription=this.router.events.pipe(Ui(t=>t instanceof qf),Zu(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(t,i){const r=[];for(const s of i){s.providers&&!s._injector&&(s._injector=O1(s.providers,t,`Route: ${s.path}`));const o=s._injector??t,a=s._loadedInjector??o;s.loadChildren&&!s._loadedRoutes&&void 0===s.canLoad||s.loadComponent&&!s._loadedComponent?r.push(this.preloadConfig(o,s)):(s.children||s._loadedRoutes)&&r.push(this.processRoutes(a,s.children??s._loadedRoutes))}return dr(r).pipe(Ml())}preloadConfig(t,i){return this.preloadingStrategy.preload(i,()=>{let r;r=i.loadChildren&&void 0===i.canLoad?this.loader.loadChildren(t,i):Tt(null);const s=r.pipe(ur(o=>null===o?Tt(void 0):(i._loadedRoutes=o.routes,i._loadedInjector=o.injector,this.processRoutes(o.injector??t,o.routes))));return i.loadComponent&&!i._loadedComponent?dr([s,this.loader.loadComponent(i)]).pipe(Ml()):s})}}return n.\u0275fac=function(t){return new(t||n)(xe(nc),xe(LP),xe(na),xe(y8),xe(lk))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const hk=new Ze("");let b8=(()=>{class n{constructor(t,i,r,s,o={}){this.urlSerializer=t,this.transitions=i,this.viewportScroller=r,this.zone=s,this.options=o,this.lastId=0,this.lastSource="imperative",this.restoredId=0,this.store={},o.scrollPositionRestoration=o.scrollPositionRestoration||"disabled",o.anchorScrolling=o.anchorScrolling||"disabled"}init(){"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.transitions.events.subscribe(t=>{t instanceof KA?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=t.navigationTrigger,this.restoredId=t.restoredState?t.restoredState.navigationId:0):t instanceof qf&&(this.lastId=t.id,this.scheduleScrollEvent(t,this.urlSerializer.parse(t.urlAfterRedirects).fragment))})}consumeScrollEvents(){return this.transitions.events.subscribe(t=>{t instanceof U5&&(t.position?"top"===this.options.scrollPositionRestoration?this.viewportScroller.scrollToPosition([0,0]):"enabled"===this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition(t.position):t.anchor&&"enabled"===this.options.anchorScrolling?this.viewportScroller.scrollToAnchor(t.anchor):"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(t,i){this.zone.runOutsideAngular(()=>{setTimeout(()=>{this.zone.run(()=>{this.transitions.events.next(new U5(t,"popstate"===this.lastSource?this.store[this.restoredId]:null,i))})},0)})}ngOnDestroy(){this.routerEventsSubscription?.unsubscribe(),this.scrollEventsSubscription?.unsubscribe()}}return n.\u0275fac=function(t){Gl()},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();var ic=(()=>((ic=ic||{})[ic.COMPLETE=0]="COMPLETE",ic[ic.FAILED=1]="FAILED",ic[ic.REDIRECTING=2]="REDIRECTING",ic))();const Mg=!1;function dh(n,e){return{\u0275kind:n,\u0275providers:e}}const fk=new Ze("",{providedIn:"root",factory:()=>!1});function w8(){const n=hn(ts);return e=>{const t=n.get(Jm);if(e!==t.components[0])return;const i=n.get(nc),r=n.get(S8);1===n.get(pk)&&i.initialNavigation(),n.get(E8,null,tn.Optional)?.setUpPreloading(),n.get(hk,null,tn.Optional)?.init(),i.resetRootComponentType(t.componentTypes[0]),r.closed||(r.next(),r.unsubscribe())}}const S8=new Ze(Mg?"bootstrap done indicator":"",{factory:()=>new cn}),pk=new Ze(Mg?"initial navigation":"",{providedIn:"root",factory:()=>1});function Nte(){let n=[];return n=Mg?[{provide:ym,multi:!0,useFactory:()=>{const e=hn(nc);return()=>e.events.subscribe(t=>{console.group?.(`Router Event: ${t.constructor.name}`),console.log(function cee(n){if(!("type"in n))return`Unknown Router Event: ${n.constructor.name}`;switch(n.type){case 14:return`ActivationEnd(path: '${n.snapshot.routeConfig?.path||""}')`;case 13:return`ActivationStart(path: '${n.snapshot.routeConfig?.path||""}')`;case 12:return`ChildActivationEnd(path: '${n.snapshot.routeConfig?.path||""}')`;case 11:return`ChildActivationStart(path: '${n.snapshot.routeConfig?.path||""}')`;case 8:return`GuardsCheckEnd(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}', state: ${n.state}, shouldActivate: ${n.shouldActivate})`;case 7:return`GuardsCheckStart(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}', state: ${n.state})`;case 2:return`NavigationCancel(id: ${n.id}, url: '${n.url}')`;case 16:return`NavigationSkipped(id: ${n.id}, url: '${n.url}')`;case 1:return`NavigationEnd(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}')`;case 3:return`NavigationError(id: ${n.id}, url: '${n.url}', error: ${n.error})`;case 0:return`NavigationStart(id: ${n.id}, url: '${n.url}')`;case 6:return`ResolveEnd(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}', state: ${n.state})`;case 5:return`ResolveStart(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}', state: ${n.state})`;case 10:return`RouteConfigLoadEnd(path: ${n.route.path})`;case 9:return`RouteConfigLoadStart(path: ${n.route.path})`;case 4:return`RoutesRecognized(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}', state: ${n.state})`;case 15:return`Scroll(anchor: '${n.anchor}', position: '${n.position?`${n.position[0]}, ${n.position[1]}`:null}')`}}(t)),console.log(t),console.groupEnd?.()})}}]:[],dh(1,n)}const E8=new Ze(Mg?"router preloader":"");function Bte(n){return dh(0,[{provide:E8,useExisting:Fte},{provide:y8,useExisting:n}])}const xy=!1,M8=new Ze(xy?"router duplicate forRoot guard":"ROUTER_FORROOT_GUARD"),Vte=[Mv,{provide:ly,useClass:zA},nc,my,{provide:Kf,useFactory:function x8(n){return n.routerState.root},deps:[nc]},lk,xy?{provide:fk,useValue:!0}:[]];function Hte(){return new GP("Router",nc)}let C8=(()=>{class n{constructor(t){}static forRoot(t,i){return{ngModule:n,providers:[Vte,xy&&i?.enableTracing?Nte().\u0275providers:[],{provide:Eg,multi:!0,useValue:t},{provide:M8,useFactory:jte,deps:[[nc,new ba,new Pl]]},{provide:GS,useValue:i||{}},i?.useHash?{provide:Ff,useClass:k7}:{provide:Ff,useClass:h3},{provide:hk,useFactory:()=>{const n=hn(jz),e=hn(Xt),t=hn(GS),i=hn(zS),r=hn(ly);return t.scrollOffset&&n.setOffset(t.scrollOffset),new b8(r,i,n,e,t)}},i?.preloadingStrategy?Bte(i.preloadingStrategy).\u0275providers:[],{provide:GP,multi:!0,useFactory:Hte},i?.initialNavigation?Wte(i):[],[{provide:D8,useFactory:w8},{provide:OP,multi:!0,useExisting:D8}]]}}static forChild(t){return{ngModule:n,providers:[{provide:Eg,multi:!0,useValue:t}]}}}return n.\u0275fac=function(t){return new(t||n)(xe(M8,8))},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[nk]}),n})();function jte(n){if(xy&&n)throw new Ue(4007,"The Router was provided more than once. This can happen if 'forRoot' is used outside of the root injector. Lazy loaded modules should use RouterModule.forChild() instead.");return"guarded"}function Wte(n){return["disabled"===n.initialNavigation?dh(3,[{provide:V1,multi:!0,useFactory:()=>{const e=hn(nc);return()=>{e.setUpLocationChangeListener()}}},{provide:pk,useValue:2}]).\u0275providers:[],"enabledBlocking"===n.initialNavigation?dh(2,[{provide:pk,useValue:0},{provide:V1,multi:!0,deps:[ts],useFactory:e=>{const t=e.get(T7,Promise.resolve());return()=>t.then(()=>new Promise(i=>{const r=e.get(nc),s=e.get(S8);(function Rte(n,e){n.events.pipe(Ui(t=>t instanceof qf||t instanceof IS||t instanceof YA||t instanceof FS),_t(t=>t instanceof qf||t instanceof FS?ic.COMPLETE:t instanceof IS&&(0===t.code||1===t.code)?ic.REDIRECTING:ic.FAILED),Ui(t=>t!==ic.REDIRECTING),Gr(1)).subscribe(()=>{e()})})(r,()=>{i(!0)}),e.get(zS).afterPreactivation=()=>(i(!0),s.closed?Tt(void 0):s),r.initialNavigation()}))}}]).\u0275providers:[]]}const D8=new Ze(xy?"Router Initializer":"");class qd{constructor(e,t,i){this.document=e,this.oAuthService=t,this.route=i,this.hasValidAccessToken$=new er(!1),this.oAuthService.setStorage(new Wd),this.oAuthService.configure({issuer:"https://www.bungie.net/en/OAuth/Authorize",loginUrl:"https://www.bungie.net/en/OAuth/Authorize",tokenEndpoint:"https://www.bungie.net/Platform/App/OAuth/token/",redirectUri:oy_bungie_redirect,clientId:oy_bungie_clientId,responseType:"code",scope:""}),this.oAuthService.tokenValidationHandler=new vQ,this.tryLogin()}tryLogin(){var e=this;return fl(function*(){e.route.queryParams.subscribe(function(){var t=fl(function*(i){i.state&&i.state===localStorage.getItem("bungie-nonce")&&(yield e.oAuthService.tryLoginCodeFlow()),e.oAuthService.hasValidAccessToken()&&(e.oAuthService.setupAutomaticSilentRefresh(),e.hasValidAccessToken$.next(!0))});return function(i){return t.apply(this,arguments)}}())})()}login(){var e=this;return fl(function*(){yield e.oAuthService.createAndSaveNonce(),e.document.location.href=`https://www.bungie.net/en/OAuth/Authorize?response_type=code&client_id=${oy_bungie_clientId}&state=${localStorage.getItem("bungie-nonce")}`})()}logout(){this.oAuthService.logOut(),this.hasValidAccessToken$.next(!1)}}function qte(n,e){}qd.\u0275fac=function(e){return new(e||qd)(xe(Mn),xe(y5),xe(Kf))},qd.\u0275prov=Je({token:qd,factory:qd.\u0275fac,providedIn:"root"});const Kte={bottomSheetState:fg("state",[sh("void, hidden",la({transform:"translateY(100%)"})),sh("visible",la({transform:"translateY(0%)"})),Xl("visible => void, visible => hidden",Yw([zd(`${XL.COMPLEX} ${YL.ACCELERATION_CURVE}`),Jv("@*",Zv(),{optional:!0})])),Xl("void => visible",Yw([zd(`${XL.EXITING} ${YL.DECELERATION_CURVE}`),Jv("@*",Zv(),{optional:!0})]))])};let Yte=(()=>{class n extends JT{constructor(t,i,r,s,o,a,c,u,p,g){super(t,i,r,s,o,a,c,g),this._changeDetectorRef=p,this._animationState="void",this._animationStateChanged=new Pn,this._breakpointSubscription=u.observe([lg_Medium,lg_Large,"(min-width: 1920px)"]).subscribe(()=>{this._toggleClass("mat-bottom-sheet-container-medium",u.isMatched(lg_Medium)),this._toggleClass("mat-bottom-sheet-container-large",u.isMatched(lg_Large)),this._toggleClass("mat-bottom-sheet-container-xlarge",u.isMatched("(min-width: 1920px)"))})}enter(){this._destroyed||(this._animationState="visible",this._changeDetectorRef.detectChanges())}exit(){this._destroyed||(this._animationState="hidden",this._changeDetectorRef.markForCheck())}ngOnDestroy(){super.ngOnDestroy(),this._breakpointSubscription.unsubscribe(),this._destroyed=!0}_onAnimationDone(t){"visible"===t.toState&&this._trapFocus(),this._animationStateChanged.emit(t)}_onAnimationStart(t){this._animationStateChanged.emit(t)}_captureInitialFocus(){}_toggleClass(t,i){this._elementRef.nativeElement.classList.toggle(t,i)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Lw),ie(Mn,8),ie(Xv),ie(Gv),ie(Xt),ie(hg),ie(FL),ie(aa),ie(Vf))},n.\u0275cmp=Ln({type:n,selectors:[["mat-bottom-sheet-container"]],hostAttrs:["tabindex","-1",1,"mat-bottom-sheet-container"],hostVars:4,hostBindings:function(t,i){1&t&&OC("@state.start",function(s){return i._onAnimationStart(s)})("@state.done",function(s){return i._onAnimationDone(s)}),2&t&&(Di("role",i._config.role)("aria-modal",i._config.ariaModal)("aria-label",i._config.ariaLabel),UC("@state",i._animationState))},features:[Z],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(t,i){1&t&&mt(0,qte,0,0,"ng-template",0)},dependencies:[$w],styles:[".mat-bottom-sheet-container{padding:8px 16px;min-width:100vw;box-sizing:border-box;display:block;outline:0;max-height:80vh;overflow:auto}.cdk-high-contrast-active .mat-bottom-sheet-container{outline:1px solid}.mat-bottom-sheet-container-xlarge,.mat-bottom-sheet-container-large,.mat-bottom-sheet-container-medium{border-top-left-radius:4px;border-top-right-radius:4px}.mat-bottom-sheet-container-medium{min-width:384px;max-width:calc(100vw - 128px)}.mat-bottom-sheet-container-large{min-width:512px;max-width:calc(100vw - 256px)}.mat-bottom-sheet-container-xlarge{min-width:576px;max-width:calc(100vw - 384px)}"],encapsulation:2,data:{animation:[Kte.bottomSheetState]}}),n})(),T8=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[UN,rr,Kv,rr]}),n})();const Xte=new Ze("MatBottomSheetData");class Zte{constructor(){this.data=null,this.hasBackdrop=!0,this.disableClose=!1,this.ariaLabel=null,this.ariaModal=!0,this.closeOnNavigation=!0,this.autoFocus="dialog",this.restoreFocus=!0}}class mk{get instance(){return this._ref.componentInstance}constructor(e,t,i){this._ref=e,this._afterOpened=new cn,this.containerInstance=i,this.disableClose=t.disableClose,i._animationStateChanged.pipe(Ui(r=>"done"===r.phaseName&&"visible"===r.toState),Gr(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),i._animationStateChanged.pipe(Ui(r=>"done"===r.phaseName&&"hidden"===r.toState),Gr(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._ref.close(this._result)}),e.overlayRef.detachments().subscribe(()=>{this._ref.close(this._result)}),fa(this.backdropClick(),this.keydownEvents().pipe(Ui(r=>27===r.keyCode))).subscribe(r=>{!this.disableClose&&("keydown"!==r.type||!ql(r))&&(r.preventDefault(),this.dismiss())})}dismiss(e){this.containerInstance&&(this.containerInstance._animationStateChanged.pipe(Ui(t=>"start"===t.phaseName),Gr(1)).subscribe(t=>{this._closeFallbackTimeout=setTimeout(()=>{this._ref.close(this._result)},t.totalTime+100),this._ref.overlayRef.detachBackdrop()}),this._result=e,this.containerInstance.exit(),this.containerInstance=null)}afterDismissed(){return this._ref.closed}afterOpened(){return this._afterOpened}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}}const Jte=new Ze("mat-bottom-sheet-default-options");let Qte=(()=>{class n{get _openedBottomSheetRef(){const t=this._parentBottomSheet;return t?t._openedBottomSheetRef:this._bottomSheetRefAtThisLevel}set _openedBottomSheetRef(t){this._parentBottomSheet?this._parentBottomSheet._openedBottomSheetRef=t:this._bottomSheetRefAtThisLevel=t}constructor(t,i,r,s){this._overlay=t,this._parentBottomSheet=r,this._defaultOptions=s,this._bottomSheetRefAtThisLevel=null,this._dialog=i.get(eA)}open(t,i){const r={...this._defaultOptions||new Zte,...i};let s;return this._dialog.open(t,{...r,disableClose:!0,closeOnOverlayDetachments:!1,maxWidth:"100%",container:Yte,scrollStrategy:r.scrollStrategy||this._overlay.scrollStrategies.block(),positionStrategy:this._overlay.position().global().centerHorizontally().bottom("0"),templateContext:()=>({bottomSheetRef:s}),providers:(o,a,c)=>(s=new mk(o,r,c),[{provide:mk,useValue:s},{provide:Xte,useValue:r.data}])}),s.afterDismissed().subscribe(()=>{this._openedBottomSheetRef===s&&(this._openedBottomSheetRef=null)}),this._openedBottomSheetRef?(this._openedBottomSheetRef.afterDismissed().subscribe(()=>s.containerInstance?.enter()),this._openedBottomSheetRef.dismiss()):s.containerInstance.enter(),this._openedBottomSheetRef=s,s}dismiss(t){this._openedBottomSheetRef&&this._openedBottomSheetRef.dismiss(t)}ngOnDestroy(){this._bottomSheetRefAtThisLevel&&this._bottomSheetRefAtThisLevel.dismiss()}}return n.\u0275fac=function(t){return new(t||n)(xe(hl),xe(ts),xe(n,12),xe(Jte,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:T8}),n})(),ene=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,rr]}),n})();const A8=["*"],I8=["unscopedContent"],tne=["text"],nne=[[["","matListItemAvatar",""],["","matListItemIcon",""]],[["","matListItemTitle",""]],[["","matListItemLine",""]],"*",[["","matListItemMeta",""]],[["mat-divider"]]],ine=["[matListItemAvatar],[matListItemIcon]","[matListItemTitle]","[matListItemLine]","*","[matListItemMeta]","mat-divider"],F8=new Ze("ListOption");let gk=(()=>{class n{constructor(t){this._elementRef=t}}return n.\u0275fac=function(t){return new(t||n)(ie(_n))},n.\u0275dir=ut({type:n,selectors:[["","matListItemTitle",""]],hostAttrs:[1,"mat-mdc-list-item-title","mdc-list-item__primary-text"]}),n})(),_k=(()=>{class n{constructor(t){this._elementRef=t}}return n.\u0275fac=function(t){return new(t||n)(ie(_n))},n.\u0275dir=ut({type:n,selectors:[["","matListItemLine",""]],hostAttrs:[1,"mat-mdc-list-item-line","mdc-list-item__secondary-text"]}),n})(),xne=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["","matListItemMeta",""]],hostAttrs:[1,"mat-mdc-list-item-meta","mdc-list-item__end"]}),n})(),R8=(()=>{class n{constructor(t){this._listOption=t}_isAlignedAtStart(){return!this._listOption||"after"===this._listOption?._getTogglePosition()}}return n.\u0275fac=function(t){return new(t||n)(ie(F8,8))},n.\u0275dir=ut({type:n,hostVars:4,hostBindings:function(t,i){2&t&&hi("mdc-list-item__start",i._isAlignedAtStart())("mdc-list-item__end",!i._isAlignedAtStart())}}),n})(),P8=(()=>{class n extends R8{}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275dir=ut({type:n,selectors:[["","matListItemAvatar",""]],hostAttrs:[1,"mat-mdc-list-item-avatar"],features:[Z]}),n})(),wne=(()=>{class n extends R8{}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275dir=ut({type:n,selectors:[["","matListItemIcon",""]],hostAttrs:[1,"mat-mdc-list-item-icon"],features:[Z]}),n})();const Sne=new Ze("MAT_LIST_CONFIG");let Cg=(()=>{class n{constructor(){this._isNonInteractive=!0,this._disableRipple=!1,this._disabled=!1,this._defaultOptions=hn(Sne,{optional:!0})}get disableRipple(){return this._disableRipple}set disableRipple(t){this._disableRipple=bi(t)}get disabled(){return this._disabled}set disabled(t){this._disabled=bi(t)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,hostVars:1,hostBindings:function(t,i){2&t&&Di("aria-disabled",i.disabled)},inputs:{disableRipple:"disableRipple",disabled:"disabled"}}),n})(),vk=(()=>{class n{set lines(t){this._explicitLines=ih(t,null),this._updateItemLines(!1)}get disableRipple(){return this.disabled||this._disableRipple||this._noopAnimations||!!this._listBase?.disableRipple}set disableRipple(t){this._disableRipple=bi(t)}get disabled(){return this._disabled||!!this._listBase?.disabled}set disabled(t){this._disabled=bi(t)}get rippleDisabled(){return this.disableRipple||!!this.rippleConfig.disabled}constructor(t,i,r,s,o,a){this._elementRef=t,this._ngZone=i,this._listBase=r,this._platform=s,this._explicitLines=null,this._disableRipple=!1,this._disabled=!1,this._subscriptions=new Tn,this._rippleRenderer=null,this._hasUnscopedTextContent=!1,this.rippleConfig=o||{},this._hostElement=this._elementRef.nativeElement,this._isButtonElement="button"===this._hostElement.nodeName.toLowerCase(),this._noopAnimations="NoopAnimations"===a,r&&!r._isNonInteractive&&this._initInteractiveListItem(),this._isButtonElement&&!this._hostElement.hasAttribute("type")&&this._hostElement.setAttribute("type","button")}ngAfterViewInit(){this._monitorProjectedLinesAndTitle(),this._updateItemLines(!0)}ngOnDestroy(){this._subscriptions.unsubscribe(),null!==this._rippleRenderer&&this._rippleRenderer._removeTriggerEvents()}_hasIconOrAvatar(){return!(!this._avatars.length&&!this._icons.length)}_initInteractiveListItem(){this._hostElement.classList.add("mat-mdc-list-item-interactive"),this._rippleRenderer=new ug(this,this._ngZone,this._hostElement,this._platform),this._rippleRenderer.setupTriggerEvents(this._hostElement)}_monitorProjectedLinesAndTitle(){this._ngZone.runOutsideAngular(()=>{this._subscriptions.add(fa(this._lines.changes,this._titles.changes).subscribe(()=>this._updateItemLines(!1)))})}_updateItemLines(t){if(!this._lines||!this._titles||!this._unscopedContent)return;t&&this._checkDomForUnscopedTextContent();const i=this._explicitLines??this._inferLinesFromContent(),r=this._unscopedContent.nativeElement;if(this._hostElement.classList.toggle("mat-mdc-list-item-single-line",i<=1),this._hostElement.classList.toggle("mdc-list-item--with-one-line",i<=1),this._hostElement.classList.toggle("mdc-list-item--with-two-lines",2===i),this._hostElement.classList.toggle("mdc-list-item--with-three-lines",3===i),this._hasUnscopedTextContent){const s=0===this._titles.length&&1===i;r.classList.toggle("mdc-list-item__primary-text",s),r.classList.toggle("mdc-list-item__secondary-text",!s)}else r.classList.remove("mdc-list-item__primary-text"),r.classList.remove("mdc-list-item__secondary-text")}_inferLinesFromContent(){let t=this._titles.length+this._lines.length;return this._hasUnscopedTextContent&&(t+=1),t}_checkDomForUnscopedTextContent(){this._hasUnscopedTextContent=Array.from(this._unscopedContent.nativeElement.childNodes).filter(t=>t.nodeType!==t.COMMENT_NODE).some(t=>!(!t.textContent||!t.textContent.trim()))}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Xt),ie(Cg,8),ie(as),ie(Vw,8),ie(bo,8))},n.\u0275dir=ut({type:n,contentQueries:function(t,i,r){if(1&t&&(is(r,P8,4),is(r,wne,4)),2&t){let s;Yn(s=Xn())&&(i._avatars=s),Yn(s=Xn())&&(i._icons=s)}},hostVars:4,hostBindings:function(t,i){2&t&&(Di("aria-disabled",i.disabled)("disabled",i._isButtonElement&&i.disabled||null),hi("mdc-list-item--disabled",i.disabled))},inputs:{lines:"lines",disableRipple:"disableRipple",disabled:"disabled"}}),n})(),Ene=(()=>{class n extends vk{get activated(){return this._activated}set activated(t){this._activated=bi(t)}constructor(t,i,r,s,o,a){super(t,i,r,s,o,a),this._activated=!1}_getAriaCurrent(){return"A"===this._hostElement.nodeName&&this._activated?"page":null}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Xt),ie(Cg,8),ie(as),ie(Vw,8),ie(bo,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-list-item"],["a","mat-list-item",""],["button","mat-list-item",""]],contentQueries:function(t,i,r){if(1&t&&(is(r,_k,5),is(r,gk,5),is(r,xne,5)),2&t){let s;Yn(s=Xn())&&(i._lines=s),Yn(s=Xn())&&(i._titles=s),Yn(s=Xn())&&(i._meta=s)}},viewQuery:function(t,i){if(1&t&&(zr(I8,5),zr(tne,5)),2&t){let r;Yn(r=Xn())&&(i._unscopedContent=r.first),Yn(r=Xn())&&(i._itemText=r.first)}},hostAttrs:[1,"mat-mdc-list-item","mdc-list-item"],hostVars:11,hostBindings:function(t,i){2&t&&(Di("aria-current",i._getAriaCurrent()),hi("mdc-list-item--activated",i.activated)("mdc-list-item--with-leading-avatar",0!==i._avatars.length)("mdc-list-item--with-leading-icon",0!==i._icons.length)("mdc-list-item--with-trailing-meta",0!==i._meta.length)("_mat-animation-noopable",i._noopAnimations))},inputs:{activated:"activated"},exportAs:["matListItem"],features:[Z],ngContentSelectors:ine,decls:10,vars:0,consts:[[1,"mdc-list-item__content"],[1,"mat-mdc-list-item-unscoped-content",3,"cdkObserveContent"],["unscopedContent",""],[1,"mat-mdc-focus-indicator"]],template:function(t,i){1&t&&(Hs(nne),En(0),ke(1,"span",0),En(2,1),En(3,2),ke(4,"span",1,2),Gn("cdkObserveContent",function(){return i._updateItemLines(!0)}),En(6,3),Ne()(),En(7,4),En(8,5),qt(9,"div",3))},dependencies:[IT],encapsulation:2,changeDetection:0}),n})(),Cne=(()=>{class n extends Cg{constructor(){super(...arguments),this._isNonInteractive=!1}}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275cmp=Ln({type:n,selectors:[["mat-nav-list"]],hostAttrs:["role","navigation",1,"mat-mdc-nav-list","mat-mdc-list-base","mdc-list"],exportAs:["matNavList"],features:[Oi([{provide:Cg,useExisting:n}]),Z],ngContentSelectors:A8,decls:1,vars:0,template:function(t,i){1&t&&(Hs(),En(0))},styles:['@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-list-divider::after{content:"";display:block;border-bottom-width:1px;border-bottom-style:solid}}.mdc-list{margin:0;padding:8px 0;list-style-type:none}.mdc-list:focus{outline:none}.mdc-list-item__wrapper{display:block}.mdc-list-item{display:flex;position:relative;align-items:center;justify-content:flex-start;overflow:hidden;padding:0;align-items:stretch;cursor:pointer}.mdc-list-item:focus{outline:none}.mdc-list-item.mdc-list-item--with-one-line{height:48px}.mdc-list-item.mdc-list-item--with-two-lines{height:64px}.mdc-list-item.mdc-list-item--with-three-lines{height:88px}.mdc-list-item.mdc-list-item--with-one-line .mdc-list-item__start{align-self:center;margin-top:0}.mdc-list-item.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:16px}.mdc-list-item.mdc-list-item--with-three-lines .mdc-list-item__start{align-self:flex-start;margin-top:16px}.mdc-list-item.mdc-list-item--with-one-line .mdc-list-item__end{align-self:center;margin-top:0}.mdc-list-item.mdc-list-item--with-two-lines .mdc-list-item__end{align-self:center;margin-top:0}.mdc-list-item.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:16px}.mdc-list-item.mdc-list-item--disabled,.mdc-list-item.mdc-list-item--non-interactive{cursor:auto}.mdc-list-item:not(.mdc-list-item--selected):focus::before,.mdc-list-item.mdc-ripple-upgraded--background-focused::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-list-item:not(.mdc-list-item--selected):focus::before,.mdc-list-item.mdc-ripple-upgraded--background-focused::before{border-color:CanvasText}}.mdc-list-item.mdc-list-item--selected::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:3px double rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-list-item.mdc-list-item--selected::before{border-color:CanvasText}}.mdc-list-item.mdc-list-item--selected:focus::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:3px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-list-item.mdc-list-item--selected:focus::before{border-color:CanvasText}}a.mdc-list-item{color:inherit;text-decoration:none}.mdc-list-item__start{fill:currentColor;flex-shrink:0;pointer-events:none}.mdc-list-item__end{flex-shrink:0;pointer-events:none}.mdc-list-item__content{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;align-self:center;flex:1;pointer-events:none}.mdc-list-item--with-two-lines .mdc-list-item__content,.mdc-list-item--with-three-lines .mdc-list-item__content{align-self:stretch}.mdc-list-item__content[for]{pointer-events:none}.mdc-list-item__primary-text{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.mdc-list-item--with-two-lines .mdc-list-item__primary-text,.mdc-list-item--with-three-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before,.mdc-list-item--with-three-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after,.mdc-list-item--with-three-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item__secondary-text{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;display:block;margin-top:0;line-height:normal}.mdc-list-item__secondary-text::before{display:inline-block;width:0;height:20px;content:"";vertical-align:0}.mdc-list-item--with-three-lines .mdc-list-item__secondary-text{white-space:normal;line-height:20px}.mdc-list-item--with-overline .mdc-list-item__secondary-text{white-space:nowrap;line-height:auto}.mdc-list-item__overline-text{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:24px;content:"";vertical-align:0}.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-three-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-three-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-three-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-avatar.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-avatar.mdc-list-item,.mdc-list-item--with-leading-avatar.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-avatar .mdc-list-item__start{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-leading-avatar .mdc-list-item__start,.mdc-list-item--with-leading-avatar .mdc-list-item__start[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-avatar.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-avatar .mdc-list-item__start{border-radius:50%}.mdc-list-item--with-leading-icon.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-icon.mdc-list-item,.mdc-list-item--with-leading-icon.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-icon .mdc-list-item__start{margin-left:16px;margin-right:32px}[dir=rtl] .mdc-list-item--with-leading-icon .mdc-list-item__start,.mdc-list-item--with-leading-icon .mdc-list-item__start[dir=rtl]{margin-left:32px;margin-right:16px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-icon.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-thumbnail.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-thumbnail.mdc-list-item,.mdc-list-item--with-leading-thumbnail.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-thumbnail .mdc-list-item__start{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-leading-thumbnail .mdc-list-item__start,.mdc-list-item--with-leading-thumbnail .mdc-list-item__start[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-image.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-image.mdc-list-item,.mdc-list-item--with-leading-image.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-image .mdc-list-item__start{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-leading-image .mdc-list-item__start,.mdc-list-item--with-leading-image .mdc-list-item__start[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-image.mdc-list-item--with-one-line{height:72px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:8px}.mdc-list-item--with-leading-video.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-video.mdc-list-item,.mdc-list-item--with-leading-video.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-video .mdc-list-item__start{margin-left:0;margin-right:16px}[dir=rtl] .mdc-list-item--with-leading-video .mdc-list-item__start,.mdc-list-item--with-leading-video .mdc-list-item__start[dir=rtl]{margin-left:16px;margin-right:0}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-video.mdc-list-item--with-one-line{height:72px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-checkbox.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-checkbox.mdc-list-item,.mdc-list-item--with-leading-checkbox.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-checkbox .mdc-list-item__start{margin-left:8px;margin-right:24px}[dir=rtl] .mdc-list-item--with-leading-checkbox .mdc-list-item__start,.mdc-list-item--with-leading-checkbox .mdc-list-item__start[dir=rtl]{margin-left:24px;margin-right:8px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:8px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-radio.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-radio.mdc-list-item,.mdc-list-item--with-leading-radio.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-radio .mdc-list-item__start{margin-left:8px;margin-right:24px}[dir=rtl] .mdc-list-item--with-leading-radio .mdc-list-item__start,.mdc-list-item--with-leading-radio .mdc-list-item__start[dir=rtl]{margin-left:24px;margin-right:8px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:8px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-radio.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-switch.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-switch.mdc-list-item,.mdc-list-item--with-leading-switch.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-switch .mdc-list-item__start{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-leading-switch .mdc-list-item__start,.mdc-list-item--with-leading-switch .mdc-list-item__start[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:16px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-switch.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-trailing-icon.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-icon.mdc-list-item,.mdc-list-item--with-trailing-icon.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-list-item--with-trailing-icon .mdc-list-item__end{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-trailing-icon .mdc-list-item__end,.mdc-list-item--with-trailing-icon .mdc-list-item__end[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-trailing-meta.mdc-list-item--with-two-lines .mdc-list-item__end{align-self:flex-start;margin-top:0}.mdc-list-item--with-trailing-meta.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:0}.mdc-list-item--with-trailing-meta.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-meta.mdc-list-item,.mdc-list-item--with-trailing-meta.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-list-item--with-trailing-meta .mdc-list-item__end{margin-left:28px;margin-right:16px}[dir=rtl] .mdc-list-item--with-trailing-meta .mdc-list-item__end,.mdc-list-item--with-trailing-meta .mdc-list-item__end[dir=rtl]{margin-left:16px;margin-right:28px}.mdc-list-item--with-trailing-meta.mdc-list-item--with-two-lines .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-trailing-meta.mdc-list-item--with-two-lines .mdc-list-item__end::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-trailing-meta.mdc-list-item--with-three-lines .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-trailing-meta.mdc-list-item--with-three-lines .mdc-list-item__end::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-trailing-meta .mdc-list-item__end{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--mdc-typography-caption-font-family);font-size:var(--mdc-typography-caption-font-size);line-height:var(--mdc-typography-caption-line-height);font-weight:var(--mdc-typography-caption-font-weight);letter-spacing:var(--mdc-typography-caption-letter-spacing);text-decoration:var(--mdc-typography-caption-text-decoration);text-transform:var(--mdc-typography-caption-text-transform)}.mdc-list-item--with-trailing-checkbox.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-checkbox.mdc-list-item,.mdc-list-item--with-trailing-checkbox.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-list-item--with-trailing-checkbox .mdc-list-item__end{margin-left:24px;margin-right:8px}[dir=rtl] .mdc-list-item--with-trailing-checkbox .mdc-list-item__end,.mdc-list-item--with-trailing-checkbox .mdc-list-item__end[dir=rtl]{margin-left:8px;margin-right:24px}.mdc-list-item--with-trailing-checkbox.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:8px}.mdc-list-item--with-trailing-radio.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-radio.mdc-list-item,.mdc-list-item--with-trailing-radio.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-list-item--with-trailing-radio .mdc-list-item__end{margin-left:24px;margin-right:8px}[dir=rtl] .mdc-list-item--with-trailing-radio .mdc-list-item__end,.mdc-list-item--with-trailing-radio .mdc-list-item__end[dir=rtl]{margin-left:8px;margin-right:24px}.mdc-list-item--with-trailing-radio.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:8px}.mdc-list-item--with-trailing-switch.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-switch.mdc-list-item,.mdc-list-item--with-trailing-switch.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-list-item--with-trailing-switch .mdc-list-item__end{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-trailing-switch .mdc-list-item__end,.mdc-list-item--with-trailing-switch .mdc-list-item__end[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-trailing-switch.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:16px}.mdc-list-item--with-overline.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-overline.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:20px;content:"";vertical-align:0}.mdc-list-item--with-overline.mdc-list-item--with-three-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-overline.mdc-list-item--with-three-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:20px;content:"";vertical-align:0}.mdc-list-item{padding-left:16px;padding-right:16px}[dir=rtl] .mdc-list-item,.mdc-list-item[dir=rtl]{padding-left:16px;padding-right:16px}.mdc-list-group .mdc-deprecated-list{padding:0}.mdc-list-group__subheader{margin:calc((3rem - 1.5rem)/2) 16px}.mdc-list-divider{padding:0;background-clip:content-box}.mdc-list-divider.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-text.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-icon.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-image.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-avatar.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-switch.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-radio.mdc-list-divider--with-leading-inset{padding-left:16px;padding-right:auto}[dir=rtl] .mdc-list-divider.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-text.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-icon.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-image.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-avatar.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-switch.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-radio.mdc-list-divider--with-leading-inset,.mdc-list-divider.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-text.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-icon.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-image.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-avatar.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-switch.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-radio.mdc-list-divider--with-leading-inset[dir=rtl]{padding-left:auto;padding-right:16px}.mdc-list-divider.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-text.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-icon.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-image.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-avatar.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-switch.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-radio.mdc-list-divider--with-trailing-inset{padding-left:auto;padding-right:16px}[dir=rtl] .mdc-list-divider.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-text.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-icon.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-image.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-avatar.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-switch.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-radio.mdc-list-divider--with-trailing-inset,.mdc-list-divider.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-text.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-icon.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-image.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-avatar.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-switch.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-radio.mdc-list-divider--with-trailing-inset[dir=rtl]{padding-left:16px;padding-right:auto}.mdc-list-divider--with-leading-video.mdc-list-divider--with-leading-inset{padding-left:0px;padding-right:auto}[dir=rtl] .mdc-list-divider--with-leading-video.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-video.mdc-list-divider--with-leading-inset[dir=rtl]{padding-left:auto;padding-right:0px}[dir=rtl] .mdc-list-divider,.mdc-list-divider[dir=rtl]{padding:0}.mdc-list-item{background-color:var(--mdc-list-list-item-container-color)}.mdc-list-item.mdc-list-item--selected{background-color:var(--mdc-list-list-item-selected-container-color)}.mdc-list-item--with-one-line{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item--with-one-line.mdc-list-item--with-leading-avatar,.mdc-list-item--with-one-line.mdc-list-item--with-leading-icon,.mdc-list-item--with-one-line.mdc-list-item--with-leading-thumbnail,.mdc-list-item--with-one-line.mdc-list-item--with-leading-checkbox,.mdc-list-item--with-one-line.mdc-list-item--with-leading-radio,.mdc-list-item--with-one-line.mdc-list-item--with-leading-switch{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item--with-one-line.mdc-list-item--with-leading-image,.mdc-list-item--with-one-line.mdc-list-item--with-leading-video{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item--with-two-lines{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item--with-two-lines.mdc-list-item--with-leading-avatar,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-icon,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-thumbnail,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-checkbox,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-radio,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-switch,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-image,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-video{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item--with-three-lines{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item.mdc-list-item--with-one-line{height:var(--mdc-list-list-item-one-line-container-height)}.mdc-list-item.mdc-list-item--with-two-lines{height:var(--mdc-list-list-item-two-line-container-height)}.mdc-list-item.mdc-list-item--with-three-lines{height:var(--mdc-list-list-item-three-line-container-height)}.mdc-list-item__primary-text{color:var(--mdc-list-list-item-label-text-color)}.mdc-list-item__primary-text{font-family:var(--mdc-list-list-item-label-text-font);line-height:var(--mdc-list-list-item-label-text-line-height);font-size:var(--mdc-list-list-item-label-text-size);font-weight:var(--mdc-list-list-item-label-text-weight);letter-spacing:var(--mdc-list-list-item-label-text-tracking)}.mdc-list-item__secondary-text{color:var(--mdc-list-list-item-supporting-text-color)}.mdc-list-item__secondary-text{font-family:var(--mdc-list-list-item-supporting-text-font);line-height:var(--mdc-list-list-item-supporting-text-line-height);font-size:var(--mdc-list-list-item-supporting-text-size);font-weight:var(--mdc-list-list-item-supporting-text-weight);letter-spacing:var(--mdc-list-list-item-supporting-text-tracking)}.mdc-list-item--with-leading-icon .mdc-list-item__start{color:var(--mdc-list-list-item-leading-icon-color)}.mdc-list-item--with-leading-icon .mdc-list-item__start{width:var(--mdc-list-list-item-leading-icon-size);height:var(--mdc-list-list-item-leading-icon-size)}.mdc-list-item--with-leading-icon .mdc-list-item__start>i{font-size:var(--mdc-list-list-item-leading-icon-size)}.mdc-list-item--with-leading-icon .mdc-list-item__start .mdc-list-item__icon{font-size:var(--mdc-list-list-item-leading-icon-size);width:var(--mdc-list-list-item-leading-icon-size);height:var(--mdc-list-list-item-leading-icon-size)}.mdc-list-item--with-leading-avatar .mdc-list-item__start{width:var(--mdc-list-list-item-leading-avatar-size);height:var(--mdc-list-list-item-leading-avatar-size)}.mdc-list-item.mdc-list-item--with-trailing-meta .mdc-list-item__end{color:var(--mdc-list-list-item-trailing-supporting-text-color)}.mdc-list-item--with-trailing-meta .mdc-list-item__end{font-family:var(--mdc-list-list-item-trailing-supporting-text-font);line-height:var(--mdc-list-list-item-trailing-supporting-text-line-height);font-size:var(--mdc-list-list-item-trailing-supporting-text-size);font-weight:var(--mdc-list-list-item-trailing-supporting-text-weight);letter-spacing:var(--mdc-list-list-item-trailing-supporting-text-tracking)}.mdc-list-item--with-trailing-icon .mdc-list-item__end{color:var(--mdc-list-list-item-trailing-icon-color)}.mdc-list-item--with-trailing-icon .mdc-list-item__end{width:var(--mdc-list-list-item-trailing-icon-size);height:var(--mdc-list-list-item-trailing-icon-size)}.mdc-list-item--with-trailing-icon .mdc-list-item__end>i{font-size:var(--mdc-list-list-item-trailing-icon-size)}.mdc-list-item--with-trailing-icon .mdc-list-item__end .mdc-list-item__icon{font-size:var(--mdc-list-list-item-trailing-icon-size);width:var(--mdc-list-list-item-trailing-icon-size);height:var(--mdc-list-list-item-trailing-icon-size)}.mdc-list-item--selected.mdc-list-item--with-trailing-icon .mdc-list-item__end{color:var(--mdc-list-list-item-selected-trailing-icon-color)}.mdc-list-item--disabled .mdc-list-item__start,.mdc-list-item--disabled .mdc-list-item__content,.mdc-list-item--disabled .mdc-list-item__end{opacity:1}.mdc-list-item--disabled .mdc-list-item__primary-text,.mdc-list-item--disabled .mdc-list-item__secondary-text,.mdc-list-item--disabled .mdc-list-item__overline-text{opacity:var(--mdc-list-list-item-disabled-label-text-opacity)}.mdc-list-item--disabled.mdc-list-item--with-leading-icon .mdc-list-item__start{color:var(--mdc-list-list-item-disabled-leading-icon-color)}.mdc-list-item--disabled.mdc-list-item--with-leading-icon .mdc-list-item__start{opacity:var(--mdc-list-list-item-disabled-leading-icon-opacity)}.mdc-list-item--disabled.mdc-list-item--with-trailing-icon .mdc-list-item__end{color:var(--mdc-list-list-item-disabled-trailing-icon-color)}.mdc-list-item--disabled.mdc-list-item--with-trailing-icon .mdc-list-item__end{opacity:var(--mdc-list-list-item-disabled-trailing-icon-opacity)}.mdc-list-item:hover .mdc-list-item__primary-text{color:var(--mdc-list-list-item-hover-label-text-color)}.mdc-list-item--with-leading-icon:hover .mdc-list-item__start{color:var(--mdc-list-list-item-hover-leading-icon-color)}.mdc-list-item--with-trailing-icon:hover .mdc-list-item__end{color:var(--mdc-list-list-item-hover-trailing-icon-color)}.mdc-list-item:focus .mdc-list-item__primary-text{color:var(--mdc-list-list-item-focus-label-text-color)}.mdc-list-item.mdc-list-item--disabled .mdc-list-item__primary-text{color:var(--mdc-list-list-item-disabled-label-text-color)}.mdc-list-item:hover::before{background-color:var(--mdc-list-list-item-hover-state-layer-color);opacity:var(--mdc-list-list-item-hover-state-layer-opacity)}.mdc-list-item.mdc-list-item--disabled::before{background-color:var(--mdc-list-list-item-disabled-state-layer-color);opacity:var(--mdc-list-list-item-disabled-state-layer-opacity)}.mdc-list-item:focus::before{background-color:var(--mdc-list-list-item-focus-state-layer-color);opacity:var(--mdc-list-list-item-focus-state-layer-opacity)}.mdc-list-item--disabled .mdc-radio,.mdc-list-item--disabled .mdc-checkbox{opacity:var(--mdc-list-list-item-disabled-label-text-opacity)}.mdc-list-item--with-leading-avatar .mat-mdc-list-item-avatar{border-radius:var(--mdc-list-list-item-leading-avatar-shape);background-color:var(--mdc-list-list-item-leading-avatar-color)}.mat-mdc-list-base{--mdc-list-list-item-container-shape:0;--mdc-list-list-item-leading-avatar-shape:50%;--mdc-list-list-item-container-color:transparent;--mdc-list-list-item-selected-container-color:transparent;--mdc-list-list-item-leading-avatar-color:transparent;--mdc-list-list-item-leading-icon-size:24px;--mdc-list-list-item-leading-avatar-size:40px;--mdc-list-list-item-trailing-icon-size:24px;--mdc-list-list-item-disabled-state-layer-color:transparent;--mdc-list-list-item-disabled-state-layer-opacity:0;--mdc-list-list-item-disabled-label-text-opacity:0.38;--mdc-list-list-item-disabled-leading-icon-opacity:0.38;--mdc-list-list-item-disabled-trailing-icon-opacity:0.38}.cdk-high-contrast-active a.mdc-list-item--activated::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}.cdk-high-contrast-active a.mdc-list-item--activated [dir=rtl]::after{right:auto;left:16px}.mat-mdc-list-base{display:block}.mat-mdc-list-base .mdc-list-item__start,.mat-mdc-list-base .mdc-list-item__end,.mat-mdc-list-base .mdc-list-item__content{pointer-events:auto}.mat-mdc-list-item,.mat-mdc-list-option{width:100%;box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-list-item:not(.mat-mdc-list-item-interactive),.mat-mdc-list-option:not(.mat-mdc-list-item-interactive){cursor:default}.mat-mdc-list-item .mat-divider-inset,.mat-mdc-list-option .mat-divider-inset{position:absolute;left:0;right:0;bottom:0}.mat-mdc-list-item .mat-mdc-list-item-avatar~.mat-divider-inset,.mat-mdc-list-option .mat-mdc-list-item-avatar~.mat-divider-inset{margin-left:72px}[dir=rtl] .mat-mdc-list-item .mat-mdc-list-item-avatar~.mat-divider-inset,[dir=rtl] .mat-mdc-list-option .mat-mdc-list-item-avatar~.mat-divider-inset{margin-right:72px}.mat-mdc-list-item-interactive::before{top:0;left:0;right:0;bottom:0;position:absolute;content:"";opacity:0;pointer-events:none}.mat-mdc-list-item>.mat-mdc-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-mdc-list-item:focus>.mat-mdc-focus-indicator::before{content:""}.mat-mdc-list-item.mdc-list-item--with-three-lines .mat-mdc-list-item-line.mdc-list-item__secondary-text{white-space:nowrap;line-height:normal}.mat-mdc-list-item.mdc-list-item--with-three-lines .mat-mdc-list-item-unscoped-content.mdc-list-item__secondary-text{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}mat-action-list button{background:none;color:inherit;border:none;font:inherit;outline:inherit;-webkit-tap-highlight-color:rgba(0,0,0,0);text-align:left}[dir=rtl] mat-action-list button{text-align:right}mat-action-list button::-moz-focus-inner{border:0}'],encapsulation:2,changeDetection:0}),n})(),kne=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[FT,ul,rr,$v,iN,ene]}),n})();function Ine(n,e){if(1&n&&(ke(0,"a",1),qt(1,"img",2),ke(2,"h3",3),it(3),Ne(),ke(4,"p",4)(5,"span"),it(6),Ne()()()),2&n){const t=e.$implicit;$e("href",t.url,Id),Le(1),$e("src",t.icon,Id)("alt",t.name),Le(2),Hi(t.name),Le(3),Hi(t.description)}}class Dg{constructor(e){this._bottomSheet=e}openBottomSheet(){this._bottomSheet.open(wy)}}Dg.\u0275fac=function(e){return new(e||Dg)(ie(Qte))},Dg.\u0275cmp=Ln({type:Dg,selectors:[["destiny-webring"]],standalone:!0,features:[_v],decls:3,vars:0,consts:[["mat-mini-fab","","color","accent","aria-label","More from Chris Fried",3,"click"]],template:function(e,t){1&e&&(ke(0,"button",0),Gn("click",function(){return t.openBottomSheet()}),ke(1,"mat-icon"),it(2,"apps"),Ne()())},dependencies:[ul,s4,nS,uN,pq,T8],styles:["button[_ngcontent-%COMP%]{position:fixed;top:1em;right:1em;z-index:20}"]});class wy{constructor(e){this._bottomSheetRef=e,this.links=[{url:"https://guardian.theater/",name:"Guardian Theater",description:"Find yourself in Twitch and Xbox videos",icon:"./assets/webring/gt.png"},{url:"https://d2srl.club/",name:"SRL\xb2",description:"2: Synchronized Random Loadouts",icon:"./assets/webring/srl2.png"},{url:"https://github.com/chrisfried/secret-scrublandeux",name:"Scrublandeux on GitHub",description:"The source isn't pretty, but it's open",icon:"./assets/webring/github-mark-white.png"},{url:"https://mastodon.chateaude.luxe/@chrisfried",name:"Chris Fried",description:"Follow me on Mastodon",icon:"./assets/webring/logo-purple.svg"}]}openLink(e){this._bottomSheetRef.dismiss(),e.preventDefault()}}function Fne(n,e){if(1&n){const t=Df();ke(0,"button",9),Gn("click",function(){return R(t),V(Jt().login())}),it(1," Login with Bungie "),ke(2,"mat-icon",10),it(3,"login"),Ne()()}}function Rne(n,e){if(1&n){const t=Df();ke(0,"button",11),Gn("click",function(){return R(t),V(Jt().logout())}),it(1," Logout "),ke(2,"mat-icon",12),it(3,"logout"),Ne()()}}wy.\u0275fac=function(e){return new(e||wy)(ie(mk))},wy.\u0275cmp=Ln({type:wy,selectors:[["destiny-webring-sheet"]],standalone:!0,features:[_v],decls:2,vars:1,consts:[["mat-list-item","","rel","me","target","_blank",3,"href",4,"ngFor","ngForOf"],["mat-list-item","","rel","me","target","_blank",3,"href"],["matListItemAvatar","",3,"src","alt"],["matListItemTitle",""],["matListItemLine",""]],template:function(e,t){1&e&&(ke(0,"mat-nav-list"),mt(1,Ine,7,5,"a",0),Ne()),2&e&&(Le(1),$e("ngForOf",t.links))},dependencies:[ul,tg,kne,Cne,Ene,P8,_k,gk],encapsulation:2});class Sy{constructor(e){this.bungieAuth=e,this.calendarChange=new Pn}ngOnInit(){this.searchString=""}login(){this.bungieAuth.login()}logout(){this.bungieAuth.logout()}}function Ey(n,e,t){return n(t?{method:"GET",url:e,params:t}:{method:"GET",url:e})}Sy.\u0275fac=function(e){return new(e||Sy)(ie(qd))},Sy.\u0275cmp=Ln({type:Sy,selectors:[["app-nav"]],inputs:{calendar:"calendar"},outputs:{calendarChange:"calendarChange"},decls:18,vars:6,consts:[[1,"mat-headline-5","headline"],["mat-raised-button","","href","https://chrisfried.github.io/secret-scrubland/",1,"switch-game"],[2,"margin-bottom","1em"],["mat-raised-button","","color","primary","class","button",3,"click",4,"ngIf"],["mat-raised-button","","class","button",3,"click",4,"ngIf"],[1,"mat-body-2"],["name","calendar","aria-label","Calendar"],["value","gregorian",3,"click"],["value","bungie",3,"click"],["mat-raised-button","","color","primary",1,"button",3,"click"],["aria-label","Login with Bungie"],["mat-raised-button","",1,"button",3,"click"],["aria-label","Logout"]],template:function(e,t){1&e&&(ke(0,"span",0),it(1,"Destiny 2 Historical Heatmap"),Ne(),ke(2,"a",1),it(3,"Switch to Destiny 1"),Ne(),ke(4,"div",2),mt(5,Fne,4,0,"button",3),ft(6,"async"),mt(7,Rne,4,0,"button",4),ft(8,"async"),Ne(),ke(9,"div",5),it(10," Calendar Type:"),qt(11,"br"),ke(12,"mat-button-toggle-group",6)(13,"mat-button-toggle",7),Gn("click",function(){return t.calendarChange.emit("gregorian")}),it(14,"Gregorian"),Ne(),ke(15,"mat-button-toggle",8),Gn("click",function(){return t.calendarChange.emit("bungie")}),it(16,"Bungie"),Ne()()(),qt(17,"br")),2&e&&(Le(5),$e("ngIf",!1===vn(6,2,t.bungieAuth.hasValidAccessToken$)),Le(2),$e("ngIf",vn(8,4,t.bungieAuth.hasValidAccessToken$)))},dependencies:[Yu,hq,cN,gN,_N,nS,Rf],styles:[".switch-game[_ngcontent-%COMP%]{margin-bottom:1em}.headline[_ngcontent-%COMP%]{margin-right:1em}"]});const Jn="https://www.bungie.net/Platform/Destiny2/";function L8(n,e){return Ey(n,`${Jn}${e.membershipType}/Profile/${e.destinyMembershipId}/Character/${e.characterId}/`,{components:e.components?e.components.join(","):void 0})}function N8(n,e){return Ey(n,`${Jn}${e.membershipType}/Account/${e.destinyMembershipId}/Stats/`,{groups:e.groups?e.groups.join(","):void 0})}function B8(n,e){return Ey(n,`${Jn}${e.membershipType}/Account/${e.destinyMembershipId}/Character/${e.characterId}/Stats/Activities/`,{count:e.count,mode:e.mode,page:e.page})}const Kd="https://www.bungie.net/Platform/User/";function V8(n){return Ey(n,`${Kd}GetMembershipsForCurrentUser/`)}class Yf{transform(e,t){let i=0;return e.forEach(r=>{(!t||0===t||"0"===t||t===r.activityDetails.mode||r.activityDetails.modes.indexOf(+t)>-1)&&(i+=r.values.timePlayedSeconds.basic.value)}),i}}Yf.\u0275fac=function(e){return new(e||Yf)},Yf.\u0275pipe=Yi({name:"addTime",type:Yf,pure:!1});var One=dt(8410);class Lne{constructor(e="keyval-store",t="keyval"){this.storeName=t,this._dbp=new Promise((i,r)=>{const s=indexedDB.open(e,1);s.onerror=()=>r(s.error),s.onsuccess=()=>i(s.result),s.onupgradeneeded=()=>{s.result.createObjectStore(t)}})}_withIDBStore(e,t){return this._dbp.then(i=>new Promise((r,s)=>{const o=i.transaction(this.storeName,e);o.oncomplete=()=>r(),o.onabort=o.onerror=()=>s(o.error),t(o.objectStore(this.storeName))}))}}let yk;function My(){return yk||(yk=new Lne),yk}var Hne=dt(7489),Une=dt.n(Hne);class uh{constructor(e){this.http=e,this.alwaysLoadRemote=!1,this.version=null,this.state={loaded:!1},this.state$=new er(this.state),this.newManifest$=new cn,this.localStorageKey="d2-manifest-version",this.idbKey="d2-manifest";const t=["Activity","ActivityMode"];dr(function Pne(n){return Ey(n,`${Jn}Manifest/`)}(i=>this.http.request(i.method,i.url,{params:i.params,body:i.body}).toPromise())).pipe(wo(i=>{const r=i.Response,o=r.jsonWorldContentPaths.en||r.jsonWorldContentPaths.en,a=o;this.version=a;try{if(this.alwaysLoadRemote)throw new Error("Testing - always load remote");const c=localStorage.getItem(this.localStorageKey),u=JSON.parse(localStorage.getItem(this.localStorageKey+"-whitelist")||"[]");if(c===a&&(0,One.deepEqual)(u,t)){const p=function Nne(n,e=My()){let t;return e._withIDBStore("readonly",i=>{t=i.get(n)}).then(()=>t.result)}(this.idbKey);if(!p)throw new Error("Empty cached manifest file");return p}throw new Error(`version mismatch: ${a} ${c}`)}catch{return this.http.get(`https://www.bungie.net${o}`,{withCredentials:!1}).pipe(_t(u=>{const p=Une().pick(u,...t.map(g=>`Destiny${g}Definition`));return this.saveManifestToIndexedDB(p,a,t),this.newManifest$.next(),p}))}}),_t(i=>{if(!i.DestinyActivityDefinition)throw new Error("Manifest corrupted, please reload");this.defs={},t.forEach(r=>{const s=`Destiny${r}Definition`;this.defs[r]="ActivityMode"===r?{get(o){const a=i[s];if(!a)throw new Error(`Table ${s} does not exist in the manifest`);for(const c in a)if(a[c].modeType===o)return a[c];throw new Error(`ModeType ${o} does not exist in the manifest`)},dbTable:i[s]}:{get(o){const a=i[s];if(!a)throw new Error(`Table ${s} does not exist in the manifest`);return a[o]},dbTable:i[s]}}),this.loaded=!0}),da((i,r)=>(console.error(i.message||i),i instanceof TypeError||-1===i.status||503===i.status||522===i.status||i.status<200||i.status>=400||this.deleteManifestFile(),Fc))).subscribe()}set loaded(e){this.setState({loaded:e,error:void 0})}set statusText(e){this.setState({statusText:e})}saveManifestToIndexedDB(e,t,i){var r=this;return fl(function*(){try{yield function Bne(n,e,t=My()){return t._withIDBStore("readwrite",i=>{i.put(e,n)})}(r.idbKey,e),localStorage.setItem(r.localStorageKey,t),localStorage.setItem(r.localStorageKey+"-whitelist",JSON.stringify(i))}catch(s){console.error("Error saving manifest file",s)}})()}deleteManifestFile(){localStorage.removeItem(this.localStorageKey),function Vne(n,e=My()){e._withIDBStore("readwrite",t=>{t.delete(n)})}(this.idbKey)}setState(e){this.state={...this.state,...e},this.state$.next(this.state)}}uh.\u0275fac=function(e){return new(e||uh)(xe(Ju))},uh.\u0275prov=Je({token:uh,factory:uh.\u0275fac,providedIn:"root"});class Xf{constructor(e){this.manifestService=e}transform(e,t){return this.manifestService.state$.pipe(_t(i=>{if(i.loaded)switch(t){case"activityName":return this.manifestService.defs.Activity.get(e)?.displayProperties.name;case"activityMode":return this.manifestService.defs.ActivityMode.get(e)?.displayProperties.name;case"activityIcon":return this.manifestService.defs.Activity.get(e)?.displayProperties.hasIcon?`https://bungie.net${this.manifestService.defs.Activity.get(e).displayProperties.icon}`:"";case"activityModeIcon":return this.manifestService.defs.ActivityMode.get(e)?.displayProperties.hasIcon?`https://bungie.net${this.manifestService.defs.ActivityMode.get(e).displayProperties.icon}`:"";default:return""}}))}}Xf.\u0275fac=function(e){return new(e||Xf)(ie(uh,16))},Xf.\u0275pipe=Yi({name:"manifest",type:Xf,pure:!0});class Zf{transform(e,t){switch(t){case"class":switch(e){case"2017-9-6":case"2017-09-06":case"2017-10-24":case"2017-12-5":case"2017-12-05":case"2018-5-8":case"2018-05-08":case"2018-9-4":case"2018-09-04":case"2018-12-4":case"2018-12-04":case"2019-3-5":case"2019-03-05":case"2019-6-4":case"2019-06-04":case"2019-10-1":case"2019-10-01":case"2019-12-10":case"2020-3-10":case"2020-03-10":case"2020-6-9":case"2020-06-09":case"2020-11-10":case"2021-2-9":case"2021-02-09":case"2021-5-11":case"2021-05-11":case"2021-8-24":case"2021-08-24":case"2021-12-7":case"2021-12-07":case"2022-2-22":case"2022-02-22":case"2022-5-24":case"2022-05-24":case"2022-8-23":case"2022-08-23":case"2022-12-6":case"2022-12-06":case"2023-2-28":case"2023-02-28":case"2023-5-23":case"2023-05-23":return"release";case"2017-9-13":case"2017-09-13":case"2017-12-6":case"2017-12-06":case"2018-5-11":case"2018-05-11":case"2018-9-14":case"2018-09-14":case"2018-12-7":case"2018-12-07":case"2019-6-4":case"2019-06-04":case"2019-10-5":case"2019-10-05":case"2020-11-21":case"2021-5-22":case"2021-05-22":case"2022-3-5":case"2022-03-05":case"2022-8-26":case"2022-08-26":case"2023-3-10":case"2023-03-10":return"raid";case"2017-12-19":case"2018-2-13":case"2018-02-13":case"2018-7-8":case"2018-07-08":case"2018-7-20":case"2018-07-20":case"2018-7-31":case"2018-07-31":case"2018-9-25":case"2018-09-25":case"2018-10-16":case"2018-12-4":case"2018-12-04":case"2018-12-7":case"2018-12-07":case"2018-12-11":case"2018-12-18":case"2019-1-8":case"2019-01-08":case"2019-1-29":case"2019-01-29":case"2019-2-5":case"2019-02-05":case"2019-3-5":case"2019-03-05":case"2019-3-8":case"2019-03-08":case"2019-3-12":case"2019-03-12":case"2019-3-15":case"2019-03-15":case"2019-3-19":case"2019-03-19":case"2019-3-26":case"2019-03-26":case"2019-4-2":case"2019-04-02":case"2019-4-9":case"2019-04-09":case"2019-4-16":case"2019-04-16":case"2019-6-4":case"2019-06-04":case"2019-6-11":case"2019-06-11":case"2019-6-18":case"2019-06-18":case"2019-6-25":case"2019-06-25":case"2019-7-2":case"2019-07-02":case"2019-7-9":case"2019-07-09":case"2019-7-30":case"2019-07-30":case"2019-10-5":case"2019-10-05":case"2019-10-22":case"2019-10-29":case"2019-11-19":case"2019-12-17":case"2020-1-7":case"2020-01-07":case"2020-1-28":case"2020-01-28":case"2020-2-4":case"2020-02-04":case"2020-2-11":case"2020-02-11":case"2020-3-13":case"2020-03-13":case"2020-3-17":case"2020-03-17":case"2020-3-24":case"2020-03-24":case"2020-4-7":case"2020-04-07":case"2020-4-21":case"2020-04-21":case"2020-6-6":case"2020-06-06":case"2020-7-7":case"2020-07-07":case"2020-8-11":case"2020-08-11":case"2020-9-8":case"2020-09-08":case"2020-10-6":case"2020-10-06":case"2020-11-9":case"2020-11-09":case"2020-11-17":case"2020-12-15":case"2021-2-16":case"2021-02-16":case"2021-2-23":case"2021-02-23":case"2021-3-23":case"2021-03-23":case"2021-4-20":case"2021-04-20":case"2021-5-7":case"2021-05-07":case"2021-5-18":case"2021-05-18":case"2021-5-25":case"2021-05-25":case"2021-6-1":case"2021-06-01":case"2021-6-8":case"2021-06-08":case"2021-6-29":case"2021-06-29":case"2021-7-6":case"2021-07-06":case"2021-8-10":case"2021-08-10":case"2021-8-31":case"2021-08-31":case"2021-9-7":case"2021-09-07":case"2021-10-12":case"2021-12-14":case"2022-2-15":case"2022-02-15":case"2022-3-1":case"2022-03-01":case"2022-3-22":case"2022-03-22":case"2022-5-3":case"2022-05-03":case"2022-5-27":case"2022-05-27":case"2022-5-31":case"2022-05-31":case"2022-7-12":case"2022-07-12":case"2022-7-19":case"2022-07-19":case"2022-9-6":case"2022-09-06":case"2022-11-15":case"2022-10-18":case"2022-12-9":case"2022-12-09":case"2022-12-13":case"2023-1-3":case"2023-01-03":case"2023-1-31":case"2023-01-31":case"2023-3-7":case"2023-03-07":case"2023-3-14":case"2023-03-14":case"2023-4-4":case"2023-04-04":case"2023-4-25":case"2023-04-25":case"2023-5-2":case"2023-05-02":return"event";default:return""}case"text":switch(e){case"2017-9-6":case"2017-09-06":return" | Destiny 2 Console";case"2017-9-13":case"2017-09-13":return" | Leviathan Raid";case"2017-10-24":return" | Destiny 2 PC";case"2017-12-5":case"2017-12-05":return" | Launch: Curse of Osiris";case"2017-12-6":case"2017-12-06":return" | Eater of Worlds Raid Lair";case"2017-12-19":case"2018-12-11":case"2019-12-17":case"2020-12-15":case"2021-12-14":case"2022-12-13":case"2023-12-12":return" | The Dawning";case"2018-2-13":case"2018-02-13":case"2019-2-5":case"2019-02-05":case"2020-2-11":case"2020-02-11":return" | Crimson Days";case"2018-5-8":case"2018-05-08":return" | Launch: Warmind";case"2018-5-11":case"2018-05-11":return" | Spire of Stars Raid Lair";case"2018-7-8":case"2018-07-08":return" | Moments of Triumph";case"2018-7-20":case"2018-07-20":return" | The Whisper";case"2018-7-31":case"2018-07-31":case"2019-7-30":case"2019-07-30":case"2020-8-11":case"2020-08-11":case"2021-7-6":case"2021-07-06":return" | Solstice of Heroes";case"2018-9-4":case"2018-09-04":return" | Launch: Forsaken | Season of the Outlaw";case"2018-9-14":case"2018-09-14":return" | Last Wish Raid";case"2018-9-25":case"2018-09-25":return" | Shattered Throne Dungeon";case"2018-10-16":case"2020-10-6":case"2020-10-06":case"2021-10-12":case"2022-10-18":return" | Festival of the Lost";case"2018-12-4":case"2018-12-04":return" | Season of the Forge | Volundr Forge";case"2018-12-7":case"2018-12-07":return" | Scourge of the Past Raid | Gofannon Forge";case"2018-12-18":return" | Izanami Forge";case"2019-1-8":case"2019-01-08":return" | Niobe Labs";case"2019-1-29":case"2019-01-29":return" | Exotic Quest: The Last Word";case"2019-3-5":case"2019-03-05":return" | Season of the Drifter | Gambit Prime: New Arcadia & Reckoning Tier 1";case"2019-3-8":case"2019-03-08":return" | Reckoning Tier 2";case"2019-3-12":case"2019-03-12":return" | Gambit Prime: Deep Six | Exotic Quest: Thorn";case"2019-3-15":case"2019-03-15":return" | Invitations of the Nine | Reckoning Tier 3";case"2019-3-19":case"2019-03-19":return" | Gambit Prime: Legion's Folly";case"2019-3-26":case"2019-03-26":return" | Gambit Prime: Emerald Coast";case"2019-4-2":case"2019-04-02":return" | Gambit Prime: All Maps";case"2019-4-9":case"2019-04-09":return" | Arc Week";case"2019-4-16":case"2019-04-16":return" | The Revelry";case"2019-6-4":case"2019-06-04":return" | Season of Opulence | Menagerie & Crown of Sorrow Raid";case"2019-6-11":case"2019-06-11":return" | New Menagerie Boss | Exotic Quest: Truth";case"2019-6-18":case"2019-06-18":return" | New Menagerie Boss | Iron Banner Quest";case"2019-6-25":case"2019-06-25":return" | Menagerie Heroic Mode";case"2019-7-2":case"2019-07-02":return" | Exotic Quest: Lumina";case"2019-7-9":case"2019-07-09":return" | Tribute Hall | Moments of Triumph";case"2019-10-1":case"2019-10-01":return" | Launch: Shadowkeep | Season of Undying";case"2019-10-5":case"2019-10-05":return" | Garden of Salvation Raid | Vex Offensive";case"2019-10-22":return" | Exotic Quest: Leviathan's Breath | Master Nightmare Hunts";case"2019-10-29":return" | Festival of the Lost | Pit of Heresy Dungeon | Exotic Quest: Xenophage";case"2019-11-19":return" | Vex Offensive: Final Assault";case"2019-12-10":return" | Season of Dawn";case"2020-1-7":case"2020-01-07":return" | Exotic Quest: Devil's Ruin";case"2020-1-28":case"2020-01-28":return" | Exotic Quest: Bastion";case"2020-2-4":case"2020-02-04":return" | Empyrean Foundation";case"2020-3-10":case"2020-03-10":return" | Season of the Worthy | Seraph Bunker: EDZ";case"2020-3-13":case"2020-03-13":return" | Trials of Osiris Returns";case"2020-3-17":case"2020-03-17":return" | Exotic Quest: The Fourth Horseman";case"2020-3-24":case"2020-03-24":return" | Seraph Bunker: Moon";case"2020-4-7":case"2020-04-07":return" | Seraph Bunker: Io";case"2020-4-21":case"2020-04-21":return" | Guardian Games | Grandmaster Nightfalls";case"2020-6-6":case"2020-06-06":return" | Live Event: Almighty's Destruction";case"2020-6-9":case"2020-06-09":return" | Season of Arrivals | Contact Event: Io | Prophecy Dungeon";case"2020-7-7":case"2020-07-07":return" | Moments of Triumph | Exotic Quest: Ruinous Effigy | Contact Event: Titan";case"2020-9-8":case"2020-09-08":return" | Exotic Quest: Traveler's Chosen";case"2020-11-9":case"2020-11-09":return" | Live Event: Traveler Reforged";case"2020-11-10":return" | Launch: Beyond Light | Season of the Hunt";case"2020-11-17":return" | Wrathborn Hunts";case"2020-11-21":return" | Deep Stone Crypt Raid";case"2020-12-8":case"2020-12-08":return" | Exotic Quest: Hawkmoon";case"2021-2-9":case"2021-02-09":return" | Season of the Chosen | H.E.L.M. Opens | Behemoth & Hailstone Battlegrounds";case"2021-2-16":case"2021-02-16":return" | Foothold Battleground | Exotic Quest: Dead Man's Tale";case"2021-2-23":case"2021-02-23":return" | Oracle Battleground";case"2021-3-23":case"2021-03-23":return" | Proving Grounds Strike";case"2021-4-20":case"2021-04-20":case"2022-5-3":case"2022-05-03":case"2023-5-2":case"2023-05-02":return" | Guardian Games";case"2021-5-7":case"2021-05-07":return" | Guardian Games Closing Ceremony";case"2021-5-11":case"2021-05-11":return" | Season of the Splicer | Override: Europa";case"2021-5-18":case"2021-05-18":return" | Override: Moon";case"2021-5-22":case"2021-05-22":return" | Vault of Glass Raid";case"2021-5-25":case"2021-05-25":return" | Override: Tangled Shore | Expunge: Labyrinth";case"2021-6-1":case"2021-06-01":return" | Expunge: Styx";case"2021-6-8":case"2021-06-08":return" | Expunge: Tartarus";case"2021-6-29":case"2021-06-29":return" | Expunge: Delphi";case"2021-8-10":case"2021-08-10":return" | Season of the Splicer Epilogue";case"2021-8-24":case"2021-08-24":return" | Season of the Lost | Exotic Quest: Ager's Scepter | Shattered Realm: Forest of Echoes";case"2021-8-31":case"2021-08-31":return" | Shattered Realm: Debris of Dreams";case"2021-9-7":case"2021-09-07":return" | Shattered Realm: Ruins of Wrath";case"2021-12-7":case"2021-12-07":return" | Bungie 30th Anniversary | Grasp of Avarice Dungeon | Moments of Triumph | Exotic Quest: Gjallarhorn";case"2022-2-15":case"2022-02-15":return" | The Exorcism";case"2022-2-22":case"2022-02-22":return" | Launch: The Witch Queen | Season of the Risen | Exotic Quest: Dead Messenger | PsiOps Battleground: EDZ";case"2022-3-1":case"2022-03-01":return" | PsiOps Battleground: Cosmodrome";case"2022-3-5":case"2022-03-05":return" | Vow of the Disciple Raid";case"2022-3-22":case"2022-03-22":return" | PsiOps Battleground: Moon";case"2022-5-24":case"2022-05-24":return" | Season of the Haunted";case"2022-5-27":case"2022-05-27":return" | Duality Dungeon";case"2022-5-31":case"2022-05-31":case"2022-7-12":case"2022-07-12":case"2022-9-6":case"2022-09-06":case"2022-11-15":case"2023-1-3":case"2023-01-03":case"2023-1-31":case"2023-01-31":case"2023-3-14":case"2023-03-14":case"2023-4-4":case"2023-04-04":case"2023-4-25":case"2023-04-25":case"2023-5-30":case"2023-05-30":case"2023-6-20":case"2023-06-20":case"2023-7-11":case"2023-07-11":case"2023-9-5":case"2023-09-05":case"2023-10-10":case"2023-11-14":case"2023-12-5":case"2023-12-05":case"2024-1-2":case"2024-01-02":case"2024-1-23":case"2024-01-23":case"2024-04-02":case"2024-4-2":return" | Iron Banner";case"2022-7-19":case"2022-07-19":case"2023-7-18":case"2023-07-18":return" | Solstice";case"2022-8-23":case"2022-08-23":return" | Season of Plunder";case"2022-8-26":case"2022-08-26":return" | King's Fall Raid";case"2022-11-27":return" | Eliksni Quarter Community Event";case"2022-12-6":case"2022-12-06":return" | Season of the Seraph | Moments of Triumph";case"2022-12-9":case"2022-12-09":return" | Spire of the Watcher Dungeon";case"2022-12-20":return" | Exotic Quest: Revision Zero";case"2023-2-28":case"2023-02-28":return" | Launch: Lightfall | Season of Defiance";case"2023-3-7":case"2023-03-07":return" | Exotic Quest: Vexcalibur";case"2023-03-10":case"2023-3-10":return" | Root of Nightmares Raid";case"2023-5-23":case"2023-05-23":return" | Season of the Deep";case"2023-5-26":case"2023-05-26":return" | Ghosts of the Deep Dungeon";case"2023-7-4":case"2023-07-04":return" | Exotic Quest: Wicked Implement";case"2023-8-22":case"2023-08-22":return" | Season of the Witch";case"2023-9-1":case"2023-09-01":return" | Crota's End Raid";case"2023-11-28":return" | Season of the Wish";case"2023-12-1":case"2023-12-01":return" | Warlord's Ruin Dungeon";case"2023-12-19":return" | Exotic Quest: Wish-Keeper";case"2024-1-30":case"2024-01-30":return" | Riven's Wishes";case"2024-3-5":case"2024-03-05":return" | Guardian Games All-Stars";default:return""}case"icon":let i="icon ";switch(e){case"2017-9-6":case"2017-09-06":case"2017-10-24":return i+="red-war";case"2017-12-5":case"2017-12-05":return i+="curse-of-osiris";case"2017-12-19":case"2018-12-11":case"2019-12-17":case"2020-12-15":case"2021-12-14":case"2022-12-13":case"2023-12-12":return i+="dawning";case"2018-2-13":case"2018-02-13":case"2019-2-5":case"2019-02-05":case"2020-2-11":case"2020-02-11":return i+="crimson-days";case"2018-5-8":case"2018-05-08":return i+="warmind";case"2018-7-8":case"2018-07-08":case"2019-7-9":case"2019-07-09":case"2020-7-7":case"2020-07-07":return i+="moments-of-triumph";case"2018-7-31":case"2018-07-31":case"2019-7-30":case"2019-07-30":case"2020-8-11":case"2020-08-11":case"2021-7-6":case"2021-07-06":return i+="solstice";case"2018-9-4":case"2018-09-04":return i+="forsaken";case"2018-10-16":case"2019-10-29":case"2020-10-6":case"2020-10-06":case"2021-10-12":case"2022-10-18":return i+="festival-of-the-lost";case"2018-12-4":case"2018-12-04":return i+="season-of-the-forge";case"2019-3-5":case"2019-03-05":return i+="season-of-the-drifter";case"2019-4-16":case"2019-04-16":return i+="revelry";case"2019-6-4":case"2019-06-04":return i+="season-of-opulence";case"2019-10-1":case"2019-10-01":return i+="shadowkeep";case"2019-10-5":case"2019-10-05":return i+="season-of-the-undying";case"2019-12-10":return i+="season-of-dawn";case"2020-3-10":case"2020-03-10":return i+="season-of-the-worthy";case"2020-4-21":case"2020-04-21":case"2021-4-20":case"2021-04-20":case"2022-5-3":case"2022-05-03":case"2023-5-2":case"2023-05-02":case"2024-3-5":case"2024-03-05":return i+="guardian-games";case"2020-6-9":case"2020-06-09":return i+="season-of-arrivals";case"2020-11-10":return i+="beyond-light";case"2020-11-17":return i+="season-of-the-hunt";case"2021-2-9":case"2021-02-09":return i+="season-of-the-chosen";case"2021-5-11":case"2021-05-11":return i+="season-of-the-splicer";case"2021-8-24":case"2021-08-24":return i+="season-of-the-lost";case"2021-12-7":case"2021-12-07":return i+="thirtieth-anniversary";case"2022-2-22":case"2022-02-22":return i+="witch-queen";case"2022-5-24":case"2022-05-24":return i+="season-of-the-haunted";case"2022-5-31":case"2022-05-31":case"2022-7-12":case"2022-07-12":case"2022-9-6":case"2022-09-06":case"2022-11-15":case"2023-1-3":case"2023-01-03":case"2023-1-31":case"2023-01-31":case"2023-3-14":case"2023-03-14":case"2023-4-4":case"2023-04-04":case"2023-4-25":case"2023-04-25":case"2023-5-30":case"2023-05-30":case"2023-6-20":case"2023-06-20":case"2023-7-11":case"2023-07-11":case"2023-9-5":case"2023-09-05":case"2023-10-10":case"2023-11-14":case"2023-12-5":case"2023-12-05":case"2024-1-2":case"2024-01-02":case"2024-1-23":case"2024-01-23":case"2024-04-02":case"2024-4-2":return i+="iron-banner";case"2022-7-19":case"2022-07-19":case"2023-7-18":case"2023-07-18":return i+="solstice2022";case"2017-9-13":case"2017-09-13":case"2017-12-6":case"2017-12-06":case"2018-5-11":case"2018-05-11":case"2018-9-14":case"2018-09-14":case"2018-12-7":case"2018-12-07":case"2020-11-21":case"2021-5-22":case"2021-05-22":case"2022-3-5":case"2022-03-05":case"2022-8-26":case"2022-08-26":case"2023-3-10":case"2023-03-10":case"2023-9-1":case"2023-09-01":return i+="raid";case"2022-8-23":case"2022-08-23":return i+="season-of-plunder";case"2018-9-25":case"2018-09-25":case"2022-5-27":case"2022-05-27":case"2022-12-9":case"2022-12-09":case"2023-5-26":case"2023-05-26":case"2023-12-1":case"2023-12-01":return i+="dungeon";case"2022-12-6":case"2022-12-06":return i+="season-of-the-seraph";case"2023-2-28":case"2023-02-28":return i+="lightfall";case"2023-5-23":case"2023-05-23":return i+="season-of-the-deep";case"2019-1-29":case"2019-01-29":case"2019-3-12":case"2019-03-12":case"2019-6-11":case"2019-06-11":case"2019-7-2":case"2019-07-02":case"2019-10-22":case"2019-10-29":case"2020-1-7":case"2020-01-07":case"2020-1-28":case"2020-01-28":case"2020-3-17":case"2020-03-17":case"2020-7-7":case"2020-07-07":case"2020-9-8":case"2020-09-08":case"2020-12-8":case"2020-12-08":case"2021-2-16":case"2021-02-16":case"2021-8-24":case"2021-08-24":case"2021-12-7":case"2021-12-07":case"2022-2-22":case"2022-02-22":case"2022-12-20":case"2023-3-7":case"2023-03-07":case"2023-7-4":case"2023-07-04":case"2023-12-19":return i+="exotic-quest";case"2023-8-22":case"2023-08-22":return i+="season-of-the-witch";case"2023-11-28":return i+="season-of-the-wish";default:return""}default:return""}}}Zf.\u0275fac=function(e){return new(e||Zf)},Zf.\u0275pipe=Yi({name:"milestone",type:Zf,pure:!0});const zne=function(n){return{top:n}};function Gne(n,e){if(1&n&&(ke(0,"div",4)(1,"span",5),it(2),Ne()()),2&n){const t=e.$implicit,i=Jt();$e("ngStyle",qu(2,zne,i.gameHours[t].offset+"px")),Le(2),Hi(i.gameHours[t].display)}}const jne=function(n,e){return{height:n,top:e}};function Wne(n,e){if(1&n&&(qt(0,"a",6),ft(1,"async"),ft(2,"manifest"),ft(3,"async"),ft(4,"manifest")),2&n){const t=e.$implicit,i=Jt();$e("ngClass","mode-"+t.activityDetails.mode)("ngStyle",function nP(n,e,t,i,r){return rP(C(),ee(),n,e,t,i,r)}(14,jne,(i.Math.floor(t.values.timePlayedSeconds.basic.value/60)||1)+"px",t.offset+"px"))("matTooltip",vn(1,4,Ti(2,6,t.activityDetails.mode,"activityMode"))+" | "+vn(3,9,Ti(4,11,t.activityDetails.referenceId,"activityName")))("href","https://www.bungie.net/en/PGCR/"+t.activityDetails.instanceId+"?character="+t.characterId,Id)}}const $ne=function(n){return{height:n}};class Cy{constructor(e){this.data=e,this.allHours=[],this.gameHours={},this.gameHourKeys=[],this.Math=Math}ngOnInit(){this.dayStart=new Date(this.data.date+"T00:00:00");const e=new Date(this.dayStart.getTime());for(let r=0;r<24;r++){const s=e.getTime(),o=e.toLocaleTimeString(void 0,{hour:"numeric"});e.setHours(r+1);const a=e.getTime();this.allHours.push({id:r,display:o,start:s,stop:a})}for(const r of this.data.activities)for(const s of this.allHours)r.startDate.getTime()=s.start&&(this.gameHours[s.id]=s);let i,t=0;for(const r of Object.keys(this.gameHours))i&&this.gameHours[r].id-i>1&&(t+=10),this.gameHours[r].offset=t,t+=60,i=this.gameHours[r].id,this.modalHeight=t;this.gameHourKeys=Object.keys(this.gameHours);for(const r of this.data.activities)r.offset=this.gameHours[r.startDate.getHours()].offset+r.startDate.getMinutes()}}Cy.\u0275fac=function(e){return new(e||Cy)(ie(ZN))},Cy.\u0275cmp=Ln({type:Cy,selectors:[["app-day-modal"]],decls:9,vars:15,consts:[["mat-dialog-title",""],[1,"timelineBase",3,"ngStyle"],["class","timelineLabels",3,"ngStyle",4,"ngFor","ngForOf"],["class","timelineActivity","matTooltipPosition","after","target","_blank",3,"ngClass","ngStyle","matTooltip","href",4,"ngFor","ngForOf"],[1,"timelineLabels",3,"ngStyle"],[1,"time","mat-caption"],["matTooltipPosition","after","target","_blank",1,"timelineActivity",3,"ngClass","ngStyle","matTooltip","href"]],template:function(e,t){1&e&&(ke(0,"h2",0),it(1),ft(2,"milestone"),ft(3,"addTime"),ft(4,"addTime"),Ne(),ke(5,"mat-dialog-content")(6,"div",1),mt(7,Gne,3,4,"div",2),mt(8,Wne,5,17,"a",3),Ne()()),2&e&&(Le(1),xs(" ",t.data.date+Ti(2,4,t.data.date,"text")+": "+t.Math.floor(Ti(3,7,t.data.activities,"0")/86400*24)+"h "+t.Math.floor(Ti(4,10,t.data.activities,"0")%3600/60)+"m","\n"),Le(5),$e("ngStyle",qu(13,$ne,t.modalHeight+"px")),Le(1),$e("ngForOf",t.gameHourKeys),Le(1),$e("ngForOf",t.data.activities))},dependencies:[eg,tg,nw,rA,sY,oY,Rf,Yf,Xf,Zf],styles:[".timelineBase[_ngcontent-%COMP%]{width:59px;display:block;position:relative;margin-left:3em}.timelineLabels[_ngcontent-%COMP%]{display:block;position:absolute;height:59px;width:60px;background-color:#e6e6e6}.timelineLabels[_ngcontent-%COMP%] .time[_ngcontent-%COMP%]{margin-left:-3.5em;width:3em;display:block;text-align:right}.timelineActivity[_ngcontent-%COMP%]{display:block;width:60px;position:absolute;left:.5em;background-color:#323296}.mode-42[_ngcontent-%COMP%], .mode-39[_ngcontent-%COMP%], .mode-41[_ngcontent-%COMP%]{background-color:#00ded1}.mode-31[_ngcontent-%COMP%], .mode-5[_ngcontent-%COMP%], .mode-38[_ngcontent-%COMP%], .mode-12[_ngcontent-%COMP%], .mode-37[_ngcontent-%COMP%], .mode-10[_ngcontent-%COMP%]{background-color:#ca1c1b}.mode-45[_ngcontent-%COMP%], .mode-44[_ngcontent-%COMP%], .mode-43[_ngcontent-%COMP%], .mode-19[_ngcontent-%COMP%]{background-color:#485537}.mode-3[_ngcontent-%COMP%], .mode-18[_ngcontent-%COMP%]{background-color:#3d526f}.mode-17[_ngcontent-%COMP%], .mode-16[_ngcontent-%COMP%]{background-color:#1f3043}.mode-2[_ngcontent-%COMP%]{background-color:#ed8129}.mode-40[_ngcontent-%COMP%]{background-color:#fff}.mode-6[_ngcontent-%COMP%]{background-color:#cacaca}.mode-4[_ngcontent-%COMP%]{background-color:#461044}.mode-63[_ngcontent-%COMP%]{background-color:#2b8e69}@media (prefers-color-scheme: dark){.mode-40[_ngcontent-%COMP%]{background-color:#000}.mode-6[_ngcontent-%COMP%]{background-color:#888}}"]});class Jf{constructor(e){this.http=e,this.queue$=new er({getGlobalAlerts:[],getDestinyManifest:[],getMembershipDataForCurrentUser:[],getMembershipDataById:[],getProfile:[],getActivityHistory:[],getPostGameCarnageReport:[]}),this.actionPriority=["getGlobalAlerts","getDestinyManifest","getMembershipDataForCurrentUser","getMembershipDataById","getProfile","getActivityHistory","getPostGameCarnageReport"],this.queueCount={getGlobalAlerts:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getDestinyManifest:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getMembershipDataForCurrentUser:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getMembershipDataById:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getProfile:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getActivityHistory:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getPostGameCarnageReport:{queued:0,completed:0,errors:0,percentage:0,color:"primary"}},this.queue$.pipe(zv(40)).subscribe(t=>{for(const i of this.actionPriority){const r=t[i];if("getPostGameCarnageReport"===i&&r.sort((s,o)=>parseInt(o.params.activityId,10)-parseInt(s.params.activityId,10)),r.length){const s=r.shift();this.queue$.next(t),s&&s.actionFunction(o=>this.http.request(o.method,o.url,{params:o.params,body:o.body}).toPromise(),s.params).then(o=>{s.callback(o),this.queueCount[i].completed++,this.updateQueue(this.queueCount[i])}).catch(o=>{s.callback(o),this.queueCount[i].errors++,this.updateQueue(this.queueCount[i])});break}}})}addToQueue(e,t,i,r){this.queue$.pipe(Gr(1)).subscribe(s=>{s[e]=[...s[e],{actionFunction:t,callback:i,params:r}],this.queue$.next(s),this.queueCount[e].queued++,this.updateQueue(this.queueCount[e])})}updateQueue(e){e.percentage=e.queued?(e.completed+e.errors)/e.queued*100:100;let t=!1;for(const i of this.actionPriority)this.queueCount[i].color=t||0===this.queueCount[i].queued||100===this.queueCount[i].percentage?"primary":"accent",this.queueCount[i].percentage>0&&this.queueCount[i].percentage<100&&(t=!0)}}Jf.\u0275fac=function(e){return new(e||Jf)(xe(Ju))},Jf.\u0275prov=Je({token:Jf,factory:Jf.\u0275fac,providedIn:"root"});class Tg{transform(e,t){const i=e.reduce(function(a,c){return a+ +c.values.timePlayedSeconds.basic.value},0);return Math.floor(i/86400)+"d "+Math.floor(i%86400/3600)+"h "+Math.floor(i%86400%3600/60)+"m"}}Tg.\u0275fac=function(e){return new(e||Tg)},Tg.\u0275pipe=Yi({name:"activitiesTotalTime",type:Tg,pure:!1});class Ag{transform(e,t){return Math.floor(e/1440)+"d "+Math.floor(e%1440/60)+"h "+Math.floor(e%1440%60)+"m"}}Ag.\u0275fac=function(e){return new(e||Ag)},Ag.\u0275pipe=Yi({name:"parseMinutesPlayed",type:Ag,pure:!0});class kg{transform(e,t){const i=e.reduce(function(s,o){return s+ +o.values.timePlayedSeconds.basic.value},0);return Math.floor(i/3600)+"h"}}kg.\u0275fac=function(e){return new(e||kg)},kg.\u0275pipe=Yi({name:"activitiesTotalHours",type:kg,pure:!1});class Ig{transform(e,t){return Math.floor(e/60)+"h"}}Ig.\u0275fac=function(e){return new(e||Ig)},Ig.\u0275pipe=Yi({name:"hoursPlayed",type:Ig,pure:!0});class Fg{transform(e,t){return e.some(function(i,r,s){return i.loading})}}Fg.\u0275fac=function(e){return new(e||Fg)},Fg.\u0275pipe=Yi({name:"loadingReduce",type:Fg,pure:!1});class Rg{transform(e,t){let i="inactive",r=1;e[e.length-1].length>0&&(i="active");for(let s=e.length-2;s>-1&&("active"===i&&e[s].length>0||"inactive"===i&&e[s].length<1);s--)r++;return r+" days "+i}}Rg.\u0275fac=function(e){return new(e||Rg)},Rg.\u0275pipe=Yi({name:"currentStreak",type:Rg,pure:!1});class Pg{transform(e,t){let i=0,r=0,s=0,o=0;for(let a=0;a0?(r=0,i++,i>s&&(s=i)):s>0&&(i=0,r++,r>o&&(o=r));return s+" days active | "+o+" days inactive"}}function qne(n,e){if(1&n&&(ke(0,"mat-card",10)(1,"mat-card-title"),it(2),Ne(),ke(3,"mat-card-subtitle"),it(4),Ne()()),2&n){const t=Jt();Le(2),Hi(t.errorStatus),Le(2),Hi(t.errorMessage)}}function Kne(n,e){1&n&&(ke(0,"mat-icon",11),it(1,"refresh"),Ne())}function Yne(n,e){if(1&n&&(ke(0,"mat-option",12),it(1),ft(2,"async"),ft(3,"manifest"),Ne()),2&n){const t=e.$implicit;$e("value",t),Le(1),xs("",vn(2,2,Ti(3,4,t,"activityMode"))," ")}}Pg.\u0275fac=function(e){return new(e||Pg)},Pg.\u0275pipe=Yi({name:"longestStreaks",type:Pg,pure:!1});const Xne=function(n,e,t){return[n,e,t]},Zne=function(n){return{"background-color":n}};function Jne(n,e){if(1&n){const t=Df();ke(0,"div",21),Gn("click",function(){const s=R(t).$implicit,o=Jt().$implicit,a=Jt().$implicit,c=Jt();return V(c.openDay(a+"-"+(o<10?"0":"")+o+"-"+(s<10?"0":"")+s,c.days[a][o][s]))}),ft(1,"milestone"),ft(2,"addTime"),ft(3,"milestone"),ft(4,"addTime"),ft(5,"addTime"),ft(6,"addTime"),ft(7,"addTime"),ft(8,"addTime"),ft(9,"milestone"),ft(10,"addTime"),ft(11,"addTime"),Ne()}if(2&n){const t=e.$implicit,i=Jt().$implicit,r=Jt().$implicit,s=Jt();$e("ngClass",XC(35,Xne,Ti(1,3,r+"-"+i+"-"+t,"class"),Ti(2,6,s.days[r][i][t],s.calendarFilter)>0?"active":"inactive",Ti(3,9,r+"-"+i+"-"+t,"icon")))("ngStyle",qu(39,Zne,"hsl("+(120*(100-Ti(4,12,s.days[r][i][t],s.calendarFilter)/864)/50-120)+", "+(Ti(5,15,s.days[r][i][t],s.calendarFilter)>0?"100%":"0%")+", "+(Ti(6,18,s.days[r][i][t],s.calendarFilter)>0?Ti(7,21,s.days[r][i][t],s.calendarFilter)/864>50?100-vn(8,24,s.days[r][i][t])/864+"%":"50%":"90%")+")"))("matTooltip",r+"-"+i+"-"+t+Ti(9,26,r+"-"+i+"-"+t,"text")+": "+s.Math.floor(Ti(10,29,s.days[r][i][t],s.calendarFilter)/86400*24)+"h "+s.Math.floor(Ti(11,32,s.days[r][i][t],s.calendarFilter)%3600/60)+"m")}}const Qne=function(n){return{width:n}},eie=function(n){return{height:n}};function tie(n,e){if(1&n&&(ke(0,"div",16)(1,"div",17),it(2),Ne(),ke(3,"div",18),ft(4,"loadingReduce"),qt(5,"div",19),mt(6,Jne,12,41,"div",20),Ne()()),2&n){const t=e.$implicit,i=Jt().$implicit,r=Jt();$e("ngStyle",qu(7,Qne,r.Math.ceil((r.dayKeys[i][t].length+r.monthOffsets[i][t])/7)+"em")),Le(2),Hi(t),Le(1),$e("ngClass",vn(4,5,r.loadingArray)?"loading":""),Le(2),$e("ngStyle",qu(9,eie,r.monthOffsets[i][t]+"em")),Le(1),$e("ngForOf",r.dayKeys[i][t])}}function nie(n,e){if(1&n&&(ke(0,"div",13)(1,"div",14)(2,"span"),it(3),Ne()(),mt(4,tie,7,11,"div",15),Ne()),2&n){const t=e.$implicit,i=Jt();Le(3),Hi(t),Le(1),$e("ngForOf",i.monthKeys[t])}}function iie(n,e){1&n&&(ke(0,"mat-icon",22),it(1,"refresh"),Ne())}function rie(n,e){1&n&&(ke(0,"mat-icon",37),it(1," trending_up "),Ne())}function sie(n,e){1&n&&(ke(0,"mat-icon",38),it(1," trending_flat "),Ne())}function oie(n,e){1&n&&(ke(0,"mat-icon",39),it(1," trending_down "),Ne())}function aie(n,e){1&n&&(ke(0,"mat-icon",37),it(1," trending_up "),Ne())}function cie(n,e){1&n&&(ke(0,"mat-icon",38),it(1," trending_flat "),Ne())}function lie(n,e){1&n&&(ke(0,"mat-icon",39),it(1," trending_down "),Ne())}function die(n,e){if(1&n&&(ke(0,"div",24),mt(1,aie,2,0,"mat-icon",25),mt(2,cie,2,0,"mat-icon",26),mt(3,lie,2,0,"mat-icon",27),ke(4,"div",28)(5,"div",29)(6,"div",30),it(7),ft(8,"async"),ft(9,"manifest"),Ne(),qt(10,"img",41),ft(11,"async"),ft(12,"manifest"),ft(13,"async"),ft(14,"manifest"),Ne(),ke(15,"div",31)(16,"div",32)(17,"div",33),it(18),Ne(),ke(19,"div",34),it(20,"13 week avg"),Ne()(),ke(21,"div",35)(22,"div",33),it(23),Ne(),ke(24,"div",34),it(25,"52 week avg"),Ne()()()()()),2&n){const t=Jt().$implicit,i=Jt(2);Le(1),$e("ngIf",t.quarter>t.year),Le(1),$e("ngIf",t.quarter===t.year),Le(1),$e("ngIf",t.quarter60?i.Math.floor(t.quarter/60)+"h"+t.quarter%60:t.quarter,"m/week"),Le(5),xs("",t.year>60?i.Math.floor(t.year/60)+"h"+t.year%60:t.year,"m/week")}}function uie(n,e){if(1&n&&(av(0),mt(1,die,26,23,"div",40),cv()),2&n){const t=e.$implicit;Le(1),$e("ngIf",t.quarter>0||t.year>0)}}function hie(n,e){if(1&n&&(ke(0,"div",23)(1,"div",24),mt(2,rie,2,0,"mat-icon",25),ft(3,"loadingReduce"),mt(4,sie,2,0,"mat-icon",26),ft(5,"loadingReduce"),mt(6,oie,2,0,"mat-icon",27),ft(7,"loadingReduce"),ke(8,"div",28)(9,"div",29)(10,"div",30),it(11,"All Activities"),Ne()(),ke(12,"div",31)(13,"div",32)(14,"div",33),it(15),Ne(),ke(16,"div",34),it(17,"13 week avg"),Ne()(),ke(18,"div",35)(19,"div",33),it(20),Ne(),ke(21,"div",34),it(22,"52 week avg"),Ne()()()()(),mt(23,uie,2,1,"ng-container",36),Ne()),2&n){const t=Jt();Le(2),$e("ngIf",!vn(3,6,t.loadingArray)&&t.getOverallTrend().quarter>t.getOverallTrend().year),Le(2),$e("ngIf",!vn(5,8,t.loadingArray)&&t.getOverallTrend().quarter===t.getOverallTrend().year),Le(2),$e("ngIf",!vn(7,10,t.loadingArray)&&t.getOverallTrend().quarter60?t.Math.floor(t.getOverallTrend().quarter/60)+"h"+t.getOverallTrend().quarter%60:t.getOverallTrend().quarter,"m/week"),Le(5),xs("",t.getOverallTrend().year>60?t.Math.floor(t.getOverallTrend().year/60)+"h"+t.getOverallTrend().year%60:t.getOverallTrend().year,"m/week"),Le(3),$e("ngForOf",t.getModeTrends())}}class Dy{constructor(e,t,i,r,s){this.http=e,this.dialog=t,this.manifestService=i,this.bungieQueue=r,this.bungieAuth=s,this.membershipDataForCurrentUser$=new er(void 0),this.accountResponse$=new er([]),this.displayName="",this.Math=Math}addDay(e){this.days[e.getFullYear()]||(this.days[e.getFullYear()]={}),this.days[e.getFullYear()][e.getMonth()+1]||(this.days[e.getFullYear()][e.getMonth()+1]={}),this.days[e.getFullYear()][e.getMonth()+1][e.getDate()]||(this.days[e.getFullYear()][e.getMonth()+1][e.getDate()]=[]),this.flatDays.push(this.days[e.getFullYear()][e.getMonth()+1][e.getDate()])}ngOnInit(){this.loadingArray=[],this.calendarFilter="0",this.subs=[],this.activities=[],this.days={},this.flatDays=[],this.oneQuarterAgo=new Date((new Date).setDate((new Date).getDate()-91)),this.oneYearAgo=new Date((new Date).setDate((new Date).getDate()-364)),this.modeTrends={},this.overallTrend={quarter:[],year:[]},this.flatDaysBS=new er([]),this.manifestService.state$.subscribe(s=>{s.loaded&&(this.modeOptions=Object.keys(this.manifestService.defs.ActivityMode.dbTable).map(o=>this.manifestService.defs.ActivityMode.dbTable[o].modeType).sort())}),this.errorStatus="",this.errorMessage="";const e=new Date("Sept 1, 2017"),t=new Date;for(;e<=t;)this.addDay(e),e.setDate(e.getDate()+1);this.flatDaysBS.next(this.flatDays),this.yearKeys=Object.keys(this.days),this.monthKeys={},this.monthOffsets={2017:{9:5}};let i=5,r=30;this.dayKeys={},this.yearKeys.forEach(s=>{this.monthKeys[s]=Object.keys(this.days[s]),this.monthOffsets[s]||(this.monthOffsets[s]={}),this.dayKeys[s]={},this.monthKeys[s].forEach(o=>{this.monthOffsets[s][o]||(this.monthOffsets[s][o]=(r+i)%7,r=Object.keys(this.days[s][o]).length,i=this.monthOffsets[s][o]),this.dayKeys[s][o]=Object.keys(this.days[s][o])})}),this.subs.push(this.bungieAuth.hasValidAccessToken$.pipe(Rc(),Dr(s=>{s&&this.bungieQueue.addToQueue("getProfile",V8,c=>{this.membershipDataForCurrentUser$.next(c)})})).subscribe()),this.subs.push(this.membershipDataForCurrentUser$.pipe(Rc(),wo(s=>ig(s?.Response?.destinyMemberships.map(o=>{const a={loading:!0};this.loadingArray.push(a);const c=new er(void 0),{membershipId:u,membershipType:p}=o;return this.bungieQueue.addToQueue("getProfile",N8,x=>{x&&1===x.ErrorCode&&x?.Response?.characters?.length>0?ig(x?.Response?.characters.map(T=>{const N={loading:!0};this.loadingArray.push(N);const k=new er(void 0),{characterId:A}=T,H=T.merged?.allTime?.secondsPlayed?.basic?.value;return this.bungieQueue.addToQueue("getProfile",L8,K=>{if(1===K.ErrorCode){const he=K;he.Response.character=K.Response.character??{data:{characterId:A,membershipId:u,membershipType:p,minutesPlayedTotal:H?this.Math.floor(H/60):0}},k.next(he)}N.loading=!1,k.complete()},{characterId:A,destinyMembershipId:u,membershipType:p,components:[200]}),k})??Fc).pipe(Gr(1)).subscribe(T=>{c.next(T),a.loading=!1,c.complete()}):(a.loading=!1,c.complete())},{destinyMembershipId:u,membershipType:p,groups:[1]}),c})??Fc)),_t(s=>this.accountResponse$.next(s))).subscribe()),this.membershipDataForCurrentUser$.pipe(Rc(),_t(s=>{this.displayName=s?.Response?.bungieNetUser?.displayName})).subscribe(),this.characters$=this.accountResponse$.pipe(Rc(),_t(s=>{const o=[];for(const a of s)if(a)for(const c of a)try{o.push(c.Response.character.data)}catch{}return o})),this.minutesPlayedTotal=this.characters$.pipe(_t(s=>{let o=0;return s.forEach(a=>{o+=+a.minutesPlayedTotal}),o})),this.subs.push(this.characters$.pipe(Rc()).subscribe(s=>{this.activities=[],s.forEach(o=>{const a={destinyMembershipId:o.membershipId,membershipType:o.membershipType,characterId:o.characterId,mode:0,count:250};this.addHistorySub({...a,page:0}),this.addHistorySub({...a,page:1}),this.addHistorySub({...a,page:2})})}))}addHistorySub(e){const t={loading:!0};this.loadingArray.push(t);const{page:i}=e,r=new er(void 0);this.bungieQueue.addToQueue("getActivityHistory",B8,a=>{r.next(a)},e),this.subs.push(r.subscribe(a=>{1!==a?.ErrorCode&&a?.ErrorStatus&&(this.errorStatus=a.ErrorStatus,this.errorMessage=a.Message),a?.Response.activities&&a?.Response.activities.length&&(this.addHistorySub({...e,page:i+3}),a.Response.activities.forEach(c=>{c.characterId=e.characterId;const p=new Date(c.period).getTime()/1e3+c.values.startSeconds.basic.value,g=p+c.values.timePlayedSeconds.basic.value;c.startDate=new Date(1e3*p),c.endDate=new Date(1e3*g),this.activities.push(c);try{this.days[c.startDate.getFullYear()][c.startDate.getMonth()+1][c.startDate.getDate()].push(c),c.endDate>this.oneYearAgo&&(c.activityDetails.modes.forEach(v=>{this.modeTrends[v]||(this.modeTrends[v]={quarter:[],year:[]}),this.modeTrends[v].year.push(c),c.endDate>this.oneQuarterAgo&&this.modeTrends[v].quarter.push(c)}),this.overallTrend.year.push(c),c.endDate>this.oneQuarterAgo&&this.overallTrend.quarter.push(c))}catch{}this.flatDaysBS.next(this.flatDays)})),a&&(t.loading=!1)}))}openDay(e,t){this.loadingArray.length&&!this.loadingArray.some(i=>i.loading)&&this.dialog.open(Cy,{data:{date:e,activities:t},width:"300px"})}ngOnDestroy(){this.subs.forEach(e=>e.unsubscribe())}getModeTrends(){return Object.keys(this.modeTrends).map(e=>({mode:Number(e),quarter:Math.round(this.modeTrends[Number(e)].quarter.reduce((t,i)=>t+(i.endDate-i.startDate),0)/13),year:Math.round(this.modeTrends[Number(e)].year.reduce((t,i)=>t+(i.endDate-i.startDate),0)/52)})).sort((e,t)=>t.year-e.year).sort((e,t)=>t.quarter-e.quarter).map(e=>({...e,quarter:Math.round(e.quarter/6e4),year:Math.round(e.year/6e4)}))}getOverallTrend(){return{quarter:Math.round(this.overallTrend.quarter.reduce((e,t)=>e+(t.endDate-t.startDate),0)/13/6e4),year:Math.round(this.overallTrend.year.reduce((e,t)=>e+(t.endDate-t.startDate),0)/52/6e4)}}}Dy.\u0275fac=function(e){return new(e||Dy)(ie(Ju),ie(Zw),ie(uh),ie(Jf),ie(qd))},Dy.\u0275cmp=Ln({type:Dy,selectors:[["app-guardian"]],decls:49,vars:37,consts:[["appearance","outlined","class","errorStatus",4,"ngIf"],[1,"mat-body-2"],[1,"mat-subtitle-2"],["aria-label","Search for Guardian","class","spinner",4,"ngIf"],[3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["class","calYear",4,"ngFor","ngForOf"],[1,"trends-header"],["class","trending_loading",4,"ngIf"],["class","trends",4,"ngIf"],["appearance","outlined",1,"errorStatus"],["aria-label","Search for Guardian",1,"spinner"],[3,"value"],[1,"calYear"],[1,"yearLabel","mat-caption"],["class","calMonth",3,"ngStyle",4,"ngFor","ngForOf"],[1,"calMonth",3,"ngStyle"],[1,"monthLabel","mat-caption"],[1,"dayWrapper",3,"ngClass"],[1,"monthSpacer",3,"ngStyle"],["class","calDay","matTooltipPosition","after",3,"ngClass","ngStyle","matTooltip","click",4,"ngFor","ngForOf"],["matTooltipPosition","after",1,"calDay",3,"ngClass","ngStyle","matTooltip","click"],[1,"trending_loading"],[1,"trends"],[1,"trend"],["class","trend-up",4,"ngIf"],["class","trend-flat",4,"ngIf"],["class","trend-down",4,"ngIf"],[1,"trend-main"],[1,"trend-header"],[1,"trend-name"],[1,"trend-values"],[1,"trend-quarter"],[1,"trend-value"],[1,"trend-time"],[1,"trend-year"],[4,"ngFor","ngForOf"],[1,"trend-up"],[1,"trend-flat"],[1,"trend-down"],["class","trend",4,"ngIf"],[1,"trend-icon",3,"src","alt"]],template:function(e,t){1&e&&(mt(0,qne,5,2,"mat-card",0),ke(1,"div",1),it(2," Name: "),ke(3,"span",2),it(4),Ne(),qt(5,"br"),it(6," Total Time in Destiny 2: "),ke(7,"span",2),it(8),ft(9,"hoursPlayed"),ft(10,"async"),Ne(),it(11," = "),ke(12,"span",2),it(13),ft(14,"parseMinutesPlayed"),ft(15,"async"),Ne(),qt(16,"br"),it(17," Total Time in Activities: "),ke(18,"span",2),it(19),ft(20,"activitiesTotalHours"),Ne(),it(21," = "),ke(22,"span",2),it(23),ft(24,"activitiesTotalTime"),Ne(),qt(25,"br"),it(26," Destiny 2 Activity Count: "),ke(27,"span",2),it(28),Ne(),mt(29,Kne,2,0,"mat-icon",3),ft(30,"loadingReduce"),qt(31,"br"),it(32),ft(33,"currentStreak"),qt(34,"br"),it(35),ft(36,"longestStreaks"),qt(37,"br"),it(38," Filter Heatmap: "),ke(39,"mat-form-field")(40,"mat-select",4),Gn("ngModelChange",function(r){return t.calendarFilter=r}),mt(41,Yne,4,7,"mat-option",5),Ne()()(),mt(42,nie,5,2,"div",6),ke(43,"h3",7),it(44,"Trends"),Ne(),mt(45,iie,2,0,"mat-icon",8),ft(46,"loadingReduce"),mt(47,hie,24,12,"div",9),ft(48,"loadingReduce")),2&e&&($e("ngIf",t.errorStatus),Le(4),Hi(t.displayName),Le(4),Hi(vn(9,15,vn(10,17,t.minutesPlayedTotal))),Le(5),Hi(vn(14,19,vn(15,21,t.minutesPlayedTotal))),Le(6),Hi(vn(20,23,t.activities)),Le(4),Hi(vn(24,25,t.activities)),Le(5),Hi(t.activities.length),Le(1),$e("ngIf",vn(30,27,t.loadingArray)),Le(3),xs(" Current Streak: ",vn(33,29,t.flatDays),""),Le(3),xs(" Longest Streaks: ",vn(36,31,t.flatDays),""),Le(5),$e("ngModel",t.calendarFilter),Le(1),$e("ngForOf",t.modeOptions),Le(1),$e("ngForOf",t.yearKeys),Le(3),$e("ngIf",vn(46,33,t.loadingArray)),Le(2),$e("ngIf",!vn(48,35,t.loadingArray)))},dependencies:[eg,tg,Yu,nw,nS,rA,_4,b4,BT,Uw,GT,zT,aT,Ew,Rf,Yf,Xf,Tg,Ag,kg,Ig,Zf,Fg,Rg,Pg],styles:['.calYear[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;margin-top:1em}.calMonth[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin-right:.5em;margin-bottom:.5em}.dayWrapper[_ngcontent-%COMP%]{display:flex;flex-direction:column;height:7em;flex-wrap:wrap}.calDay[_ngcontent-%COMP%]{display:block;width:1em;height:1em;box-sizing:border-box;cursor:pointer;transition:transform .2s;background-position:center;background-size:16px}.calDay[_ngcontent-%COMP%]:hover.icon{transform:scale(1.5);z-index:999;box-shadow:0 0 8px 3px #696969;opacity:1}.calDay[_ngcontent-%COMP%]:before{content:" ";top:0;left:0;width:100%;height:100%;filter:invert(1);display:block;-webkit-mask-size:contain;mask-size:contain}.calDay.red-war[_ngcontent-%COMP%]:before{-webkit-mask-image:url(red-war.3eff2acca21c93ca.png);mask-image:url(red-war.3eff2acca21c93ca.png);background-color:inherit}.calDay.curse-of-osiris[_ngcontent-%COMP%]:before{-webkit-mask-image:url(curse-of-osiris.6c410487c8c1193b.png);mask-image:url(curse-of-osiris.6c410487c8c1193b.png);background-color:inherit}.calDay.dawning[_ngcontent-%COMP%]:before{-webkit-mask-image:url(dawning.645be67ef31d090a.png);mask-image:url(dawning.645be67ef31d090a.png);background-color:inherit}.calDay.crimson-days[_ngcontent-%COMP%]:before{-webkit-mask-image:url(crimson-days.aa88f4d939be6b4f.png);mask-image:url(crimson-days.aa88f4d939be6b4f.png);background-color:inherit}.calDay.warmind[_ngcontent-%COMP%]:before{-webkit-mask-image:url(warmind.af5f3877c551d0a9.png);mask-image:url(warmind.af5f3877c551d0a9.png);background-color:inherit}.calDay.moments-of-triumph[_ngcontent-%COMP%]:before{-webkit-mask-image:url(moments-of-triumph.3dd2b9684009007a.png);mask-image:url(moments-of-triumph.3dd2b9684009007a.png);background-color:inherit}.calDay.solstice[_ngcontent-%COMP%]:before{-webkit-mask-image:url(solstice.cb7917ad27da3310.png);mask-image:url(solstice.cb7917ad27da3310.png);background-color:inherit}.calDay.forsaken[_ngcontent-%COMP%]:before{-webkit-mask-image:url(forsaken.f61a352f91528263.png);mask-image:url(forsaken.f61a352f91528263.png);background-color:inherit}.calDay.festival-of-the-lost[_ngcontent-%COMP%]:before{-webkit-mask-image:url(festival-of-the-lost.656fb66ff23db261.png);mask-image:url(festival-of-the-lost.656fb66ff23db261.png);background-color:inherit}.calDay.season-of-the-forge[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-forge.a88ddb98b2a97a0e.png);mask-image:url(season-of-the-forge.a88ddb98b2a97a0e.png);background-color:inherit}.calDay.season-of-the-drifter[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-drifter.1867ff7e8c88eda5.png);mask-image:url(season-of-the-drifter.1867ff7e8c88eda5.png);background-color:inherit}.calDay.revelry[_ngcontent-%COMP%]:before{-webkit-mask-image:url(revelry.4a84f0f680e2599d.png);mask-image:url(revelry.4a84f0f680e2599d.png);background-color:inherit}.calDay.season-of-opulence[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-opulence.3b878d66365d9cc6.png);mask-image:url(season-of-opulence.3b878d66365d9cc6.png);background-color:inherit}.calDay.shadowkeep[_ngcontent-%COMP%]:before{-webkit-mask-image:url(shadowkeep.2412f7e9615345e8.png);mask-image:url(shadowkeep.2412f7e9615345e8.png);background-color:inherit}.calDay.season-of-the-undying[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-undying.a0948d4e1e5532ab.png);mask-image:url(season-of-the-undying.a0948d4e1e5532ab.png);background-color:inherit}.calDay.season-of-dawn[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-dawn.152fa5fa97203b11.png);mask-image:url(season-of-dawn.152fa5fa97203b11.png);background-color:inherit}.calDay.season-of-the-worthy[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-worthy.97fe2af14ad98313.png);mask-image:url(season-of-the-worthy.97fe2af14ad98313.png);background-color:inherit}.calDay.guardian-games[_ngcontent-%COMP%]:before{-webkit-mask-image:url(guardian-games.1458a297ee32ae52.png);mask-image:url(guardian-games.1458a297ee32ae52.png);background-color:inherit}.calDay.season-of-arrivals[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-arrivals.649a4db068c154bf.png);mask-image:url(season-of-arrivals.649a4db068c154bf.png);background-color:inherit}.calDay.beyond-light[_ngcontent-%COMP%]:before{-webkit-mask-image:url(beyond-light.8fb053c5e78ee3c1.png);mask-image:url(beyond-light.8fb053c5e78ee3c1.png);background-color:inherit}.calDay.season-of-the-hunt[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-hunt.23c0a09811c2dd46.png);mask-image:url(season-of-the-hunt.23c0a09811c2dd46.png);background-color:inherit}.calDay.season-of-the-chosen[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-chosen.9d73f0c6a48c8b28.png);mask-image:url(season-of-the-chosen.9d73f0c6a48c8b28.png);background-color:inherit}.calDay.season-of-the-splicer[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-splicer.5cff32b822f61b20.png);mask-image:url(season-of-the-splicer.5cff32b822f61b20.png);background-color:inherit}.calDay.season-of-the-lost[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-lost.10a416eb34d1915e.png);mask-image:url(season-of-the-lost.10a416eb34d1915e.png);background-color:inherit}.calDay.thirtieth-anniversary[_ngcontent-%COMP%]:before{-webkit-mask-image:url(thirtieth-anniversary.3aa725ceedf9157d.png);mask-image:url(thirtieth-anniversary.3aa725ceedf9157d.png);background-color:inherit}.calDay.witch-queen[_ngcontent-%COMP%]:before{-webkit-mask-image:url(witch-queen.4fdd67baed2eb636.png);mask-image:url(witch-queen.4fdd67baed2eb636.png);background-color:inherit}.calDay.season-of-the-haunted[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-haunted.d4556f3df7022cf7.png);mask-image:url(season-of-the-haunted.d4556f3df7022cf7.png);background-color:inherit}.calDay.iron-banner[_ngcontent-%COMP%]:before{-webkit-mask-image:url(iron-banner.0cccf5ef6d1f8153.png);mask-image:url(iron-banner.0cccf5ef6d1f8153.png);background-color:inherit}.calDay.solstice2022[_ngcontent-%COMP%]:before{-webkit-mask-image:url(solstice2022.4129b7a862b1dd62.png);mask-image:url(solstice2022.4129b7a862b1dd62.png);background-color:inherit}.calDay.raid[_ngcontent-%COMP%]:before{-webkit-mask-image:url(raid.c24a762febb5d48f.png);mask-image:url(raid.c24a762febb5d48f.png);background-color:inherit}.calDay.season-of-plunder[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-plunder.a82a4f350d3ff629.png);mask-image:url(season-of-plunder.a82a4f350d3ff629.png);background-color:inherit}.calDay.dungeon[_ngcontent-%COMP%]:before{-webkit-mask-image:url(dungeon.1e3bb371bcf5c37b.png);mask-image:url(dungeon.1e3bb371bcf5c37b.png);background-color:inherit}.calDay.season-of-the-seraph[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-seraph.30ab5d205a09f6c4.png);mask-image:url(season-of-the-seraph.30ab5d205a09f6c4.png);background-color:inherit}.calDay.lightfall[_ngcontent-%COMP%]:before{-webkit-mask-image:url(lightfall.cbc105e4dbc42ae7.png);mask-image:url(lightfall.cbc105e4dbc42ae7.png);background-color:inherit}.calDay.season-of-the-deep[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-deep.c79c733175700d33.png);mask-image:url(season-of-the-deep.c79c733175700d33.png);background-color:inherit}.calDay.exotic-quest[_ngcontent-%COMP%]:before{-webkit-mask-image:url(exotic-quest.bb278fc19eb3104c.png);mask-image:url(exotic-quest.bb278fc19eb3104c.png);background-color:inherit}.calDay.season-of-the-witch[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-witch.7978d2dee322e4cf.png);mask-image:url(season-of-the-witch.7978d2dee322e4cf.png);background-color:inherit}.calDay.season-of-the-wish[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-wish.97577548fcd7897c.png);mask-image:url(season-of-the-wish.97577548fcd7897c.png);background-color:inherit}@media (prefers-reduced-motion){.calDay[_ngcontent-%COMP%]{transition:none}.calDay[_ngcontent-%COMP%]:hover{transform:none;box-shadow:none;background-image:none}}.loading[_ngcontent-%COMP%] > .calDay[_ngcontent-%COMP%]{cursor:progress}.yearLabel[_ngcontent-%COMP%]{display:flex;align-items:center}.yearLabel[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:.75em;display:block;transform:rotate(-90deg)}.monthSpacer[_ngcontent-%COMP%]{width:1em}.monthLabel[_ngcontent-%COMP%]{font-size:.75em;text-align:center}.release[_ngcontent-%COMP%]:before{width:100%;height:100%}.raid[_ngcontent-%COMP%]:before, .event[_ngcontent-%COMP%]:before{width:100%;height:100%}@media (prefers-color-scheme: dark){.release[_ngcontent-%COMP%], .raid[_ngcontent-%COMP%], .event[_ngcontent-%COMP%]{border-color:#333}.inactive[_ngcontent-%COMP%]{opacity:.15}}.spinner[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_spin 3s infinite linear;height:1em;width:1em;display:inline-block;line-height:1em;font-size:.75em}@keyframes _ngcontent-%COMP%_spin{0%{-webkit-transform:rotate(0deg)}to{-webkit-transform:rotate(360deg)}}@keyframes _ngcontent-%COMP%_spinX{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.errorStatus[_ngcontent-%COMP%]{margin-bottom:.5em}.trends-header[_ngcontent-%COMP%]{font-family:Roboto,Helvetica Neue,sans-serif}.trending_loading[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_spin 3s infinite linear}.trends[_ngcontent-%COMP%]{font-family:Roboto,Helvetica Neue,sans-serif;display:flex;flex-wrap:wrap;gap:1em}.trends[_ngcontent-%COMP%] .trend-up[_ngcontent-%COMP%]{color:green}.trends[_ngcontent-%COMP%] .trend-down[_ngcontent-%COMP%]{color:red}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.75em;min-width:17em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-header[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{height:1em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-time[_ngcontent-%COMP%]{font-size:.75em;opacity:.6}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-values[_ngcontent-%COMP%]{display:flex;gap:.75em}']});const bk="135",fie=0,H8=1,pie=2,U8=1,mie=2,Ty=3,Og=0,Ds=1,Lg=2,hh=0,Ay=1,G8=2,j8=3,W8=4,gie=5,Ng=100,_ie=101,vie=102,$8=103,q8=104,yie=200,bie=201,xie=202,wie=203,K8=204,Y8=205,Sie=206,Eie=207,Mie=208,Cie=209,Die=210,Tie=0,Aie=1,kie=2,xk=3,Iie=4,Fie=5,Rie=6,Pie=7,jS=0,Oie=1,Lie=2,Qf=0,Nie=1,Bie=2,Vie=3,Hie=4,Uie=5,Bg=301,Vg=302,WS=303,$S=304,ky=306,qS=307,KS=1e3,Uo=1001,YS=1002,Gs=1003,Sk=1004,Ek=1005,no=1006,X8=1007,Hg=1008,fh=1009,zie=1010,Gie=1011,Iy=1012,jie=1013,XS=1014,Yd=1015,Ug=1016,Wie=1017,$ie=1018,qie=1019,zg=1020,Kie=1021,ep=1022,zo=1023,Yie=1024,Xie=1025,Zie=zo,tp=1026,Gg=1027,Jie=1028,Qie=1029,ere=1030,tre=1031,nre=1032,ire=1033,Z8=33776,J8=33777,Q8=33778,eB=33779,tB=35840,nB=35841,iB=35842,rB=35843,rre=36196,sB=37492,oB=37496,sre=37808,ore=37809,are=37810,cre=37811,lre=37812,dre=37813,ure=37814,hre=37815,fre=37816,pre=37817,mre=37818,gre=37819,_re=37820,vre=37821,yre=36492,bre=37840,xre=37841,wre=37842,Sre=37843,Ere=37844,Mre=37845,Cre=37846,Dre=37847,Tre=37848,Are=37849,kre=37850,Ire=37851,Fre=37852,Rre=37853,jg=2400,Wg=2401,Ma=3e3,e2=3001,Dk=3007,Tk=3002,cB=3004,lB=3005,dB=3006,Vre=3201,$g=0,Hre=1,Fy=35044,Ry=35048,uB="300 es";class np{addEventListener(e,t){void 0===this._listeners&&(this._listeners={});const i=this._listeners;void 0===i[e]&&(i[e]=[]),-1===i[e].indexOf(t)&&i[e].push(t)}hasEventListener(e,t){if(void 0===this._listeners)return!1;const i=this._listeners;return void 0!==i[e]&&-1!==i[e].indexOf(t)}removeEventListener(e,t){if(void 0===this._listeners)return;const r=this._listeners[e];if(void 0!==r){const s=r.indexOf(t);-1!==s&&r.splice(s,1)}}dispatchEvent(e){if(void 0===this._listeners)return;const i=this._listeners[e.type];if(void 0!==i){e.target=this;const r=i.slice(0);for(let s=0,o=r.length;s>8&255]+Eo[n>>16&255]+Eo[n>>24&255]+"-"+Eo[255&e]+Eo[e>>8&255]+"-"+Eo[e>>16&15|64]+Eo[e>>24&255]+"-"+Eo[63&t|128]+Eo[t>>8&255]+"-"+Eo[t>>16&255]+Eo[t>>24&255]+Eo[255&i]+Eo[i>>8&255]+Eo[i>>16&255]+Eo[i>>24&255]).toUpperCase()}function Mo(n,e,t){return Math.max(e,Math.min(t,n))}function Oy(n,e,t){return(1-t)*n+t*e}function Ik(n){return 0==(n&n-1)&&0!==n}function fB(n){return Math.pow(2,Math.floor(Math.log(n)/Math.LN2))}class tt{constructor(e=0,t=0){this.x=e,this.y=t}get width(){return this.x}set width(e){this.x=e}get height(){return this.y}set height(e){this.y=e}set(e,t){return this.x=e,this.y=t,this}setScalar(e){return this.x=e,this.y=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y)}copy(e){return this.x=e.x,this.y=e.y,this}add(e,t){return void 0!==t?(console.warn("THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this)}addScalar(e){return this.x+=e,this.y+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this}sub(e,t){return void 0!==t?(console.warn("THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this)}subScalar(e){return this.x-=e,this.y-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this}multiply(e){return this.x*=e.x,this.y*=e.y,this}multiplyScalar(e){return this.x*=e,this.y*=e,this}divide(e){return this.x/=e.x,this.y/=e.y,this}divideScalar(e){return this.multiplyScalar(1/e)}applyMatrix3(e){const t=this.x,i=this.y,r=e.elements;return this.x=r[0]*t+r[3]*i+r[6],this.y=r[1]*t+r[4]*i+r[7],this}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this}clampLength(e,t){const i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(e,Math.min(t,i)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this}negate(){return this.x=-this.x,this.y=-this.y,this}dot(e){return this.x*e.x+this.y*e.y}cross(e){return this.x*e.y-this.y*e.x}lengthSq(){return this.x*this.x+this.y*this.y}length(){return Math.sqrt(this.x*this.x+this.y*this.y)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)}normalize(){return this.divideScalar(this.length()||1)}angle(){return Math.atan2(-this.y,-this.x)+Math.PI}distanceTo(e){return Math.sqrt(this.distanceToSquared(e))}distanceToSquared(e){const t=this.x-e.x,i=this.y-e.y;return t*t+i*i}manhattanDistanceTo(e){return Math.abs(this.x-e.x)+Math.abs(this.y-e.y)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this}lerpVectors(e,t,i){return this.x=e.x+(t.x-e.x)*i,this.y=e.y+(t.y-e.y)*i,this}equals(e){return e.x===this.x&&e.y===this.y}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e}fromBufferAttribute(e,t,i){return void 0!==i&&console.warn("THREE.Vector2: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this}rotateAround(e,t){const i=Math.cos(t),r=Math.sin(t),s=this.x-e.x,o=this.y-e.y;return this.x=s*i-o*r+e.x,this.y=s*r+o*i+e.y,this}random(){return this.x=Math.random(),this.y=Math.random(),this}*[Symbol.iterator](){yield this.x,yield this.y}}tt.prototype.isVector2=!0;class js{constructor(){this.elements=[1,0,0,0,1,0,0,0,1],arguments.length>0&&console.error("THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.")}set(e,t,i,r,s,o,a,c,u){const p=this.elements;return p[0]=e,p[1]=r,p[2]=a,p[3]=t,p[4]=s,p[5]=c,p[6]=i,p[7]=o,p[8]=u,this}identity(){return this.set(1,0,0,0,1,0,0,0,1),this}copy(e){const t=this.elements,i=e.elements;return t[0]=i[0],t[1]=i[1],t[2]=i[2],t[3]=i[3],t[4]=i[4],t[5]=i[5],t[6]=i[6],t[7]=i[7],t[8]=i[8],this}extractBasis(e,t,i){return e.setFromMatrix3Column(this,0),t.setFromMatrix3Column(this,1),i.setFromMatrix3Column(this,2),this}setFromMatrix4(e){const t=e.elements;return this.set(t[0],t[4],t[8],t[1],t[5],t[9],t[2],t[6],t[10]),this}multiply(e){return this.multiplyMatrices(this,e)}premultiply(e){return this.multiplyMatrices(e,this)}multiplyMatrices(e,t){const i=e.elements,r=t.elements,s=this.elements,o=i[0],a=i[3],c=i[6],u=i[1],p=i[4],g=i[7],v=i[2],y=i[5],x=i[8],T=r[0],N=r[3],k=r[6],A=r[1],H=r[4],G=r[7],X=r[2],se=r[5],K=r[8];return s[0]=o*T+a*A+c*X,s[3]=o*N+a*H+c*se,s[6]=o*k+a*G+c*K,s[1]=u*T+p*A+g*X,s[4]=u*N+p*H+g*se,s[7]=u*k+p*G+g*K,s[2]=v*T+y*A+x*X,s[5]=v*N+y*H+x*se,s[8]=v*k+y*G+x*K,this}multiplyScalar(e){const t=this.elements;return t[0]*=e,t[3]*=e,t[6]*=e,t[1]*=e,t[4]*=e,t[7]*=e,t[2]*=e,t[5]*=e,t[8]*=e,this}determinant(){const e=this.elements,t=e[0],i=e[1],r=e[2],s=e[3],o=e[4],a=e[5],c=e[6],u=e[7],p=e[8];return t*o*p-t*a*u-i*s*p+i*a*c+r*s*u-r*o*c}invert(){const e=this.elements,t=e[0],i=e[1],r=e[2],s=e[3],o=e[4],a=e[5],c=e[6],u=e[7],p=e[8],g=p*o-a*u,v=a*c-p*s,y=u*s-o*c,x=t*g+i*v+r*y;if(0===x)return this.set(0,0,0,0,0,0,0,0,0);const T=1/x;return e[0]=g*T,e[1]=(r*u-p*i)*T,e[2]=(a*i-r*o)*T,e[3]=v*T,e[4]=(p*t-r*c)*T,e[5]=(r*s-a*t)*T,e[6]=y*T,e[7]=(i*c-u*t)*T,e[8]=(o*t-i*s)*T,this}transpose(){let e;const t=this.elements;return e=t[1],t[1]=t[3],t[3]=e,e=t[2],t[2]=t[6],t[6]=e,e=t[5],t[5]=t[7],t[7]=e,this}getNormalMatrix(e){return this.setFromMatrix4(e).invert().transpose()}transposeIntoArray(e){const t=this.elements;return e[0]=t[0],e[1]=t[3],e[2]=t[6],e[3]=t[1],e[4]=t[4],e[5]=t[7],e[6]=t[2],e[7]=t[5],e[8]=t[8],this}setUvTransform(e,t,i,r,s,o,a){const c=Math.cos(s),u=Math.sin(s);return this.set(i*c,i*u,-i*(c*o+u*a)+o+e,-r*u,r*c,-r*(-u*o+c*a)+a+t,0,0,1),this}scale(e,t){const i=this.elements;return i[0]*=e,i[3]*=e,i[6]*=e,i[1]*=t,i[4]*=t,i[7]*=t,this}rotate(e){const t=Math.cos(e),i=Math.sin(e),r=this.elements,s=r[0],o=r[3],a=r[6],c=r[1],u=r[4],p=r[7];return r[0]=t*s+i*c,r[3]=t*o+i*u,r[6]=t*a+i*p,r[1]=-i*s+t*c,r[4]=-i*o+t*u,r[7]=-i*a+t*p,this}translate(e,t){const i=this.elements;return i[0]+=e*i[2],i[3]+=e*i[5],i[6]+=e*i[8],i[1]+=t*i[2],i[4]+=t*i[5],i[7]+=t*i[8],this}equals(e){const t=this.elements,i=e.elements;for(let r=0;r<9;r++)if(t[r]!==i[r])return!1;return!0}fromArray(e,t=0){for(let i=0;i<9;i++)this.elements[i]=e[i+t];return this}toArray(e=[],t=0){const i=this.elements;return e[t]=i[0],e[t+1]=i[1],e[t+2]=i[2],e[t+3]=i[3],e[t+4]=i[4],e[t+5]=i[5],e[t+6]=i[6],e[t+7]=i[7],e[t+8]=i[8],e}clone(){return(new this.constructor).fromArray(this.elements)}}function pB(n){if(0===n.length)return-1/0;let e=n[0];for(let t=1,i=n.length;te&&(e=n[t]);return e}function n2(n){return document.createElementNS("http://www.w3.org/1999/xhtml",n)}function mB(n,e=0){let t=3735928559^e,i=1103547991^e;for(let s,r=0;r>>16,2246822507)^Math.imul(i^i>>>13,3266489909),i=Math.imul(i^i>>>16,2246822507)^Math.imul(t^t>>>13,3266489909),4294967296*(2097151&i)+(t>>>0)}let Kg;js.prototype.isMatrix3=!0,Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array;class Yg{static getDataURL(e){if(/^data:/i.test(e.src)||typeof HTMLCanvasElement>"u")return e.src;let t;if(e instanceof HTMLCanvasElement)t=e;else{void 0===Kg&&(Kg=n2("canvas")),Kg.width=e.width,Kg.height=e.height;const i=Kg.getContext("2d");e instanceof ImageData?i.putImageData(e,0,0):i.drawImage(e,0,0,e.width,e.height),t=Kg}return t.width>2048||t.height>2048?(console.warn("THREE.ImageUtils.getDataURL: Image converted to jpg for performance reasons",e),t.toDataURL("image/jpeg",.6)):t.toDataURL("image/png")}}let nse=0;class io extends np{constructor(e=io.DEFAULT_IMAGE,t=io.DEFAULT_MAPPING,i=Uo,r=Uo,s=no,o=Hg,a=zo,c=fh,u=1,p=Ma){super(),Object.defineProperty(this,"id",{value:nse++}),this.uuid=rc(),this.name="",this.image=e,this.mipmaps=[],this.mapping=t,this.wrapS=i,this.wrapT=r,this.magFilter=s,this.minFilter=o,this.anisotropy=u,this.format=a,this.internalFormat=null,this.type=c,this.offset=new tt(0,0),this.repeat=new tt(1,1),this.center=new tt(0,0),this.rotation=0,this.matrixAutoUpdate=!0,this.matrix=new js,this.generateMipmaps=!0,this.premultiplyAlpha=!1,this.flipY=!0,this.unpackAlignment=4,this.encoding=p,this.userData={},this.version=0,this.onUpdate=null,this.isRenderTargetTexture=!1}updateMatrix(){this.matrix.setUvTransform(this.offset.x,this.offset.y,this.repeat.x,this.repeat.y,this.rotation,this.center.x,this.center.y)}clone(){return(new this.constructor).copy(this)}copy(e){return this.name=e.name,this.image=e.image,this.mipmaps=e.mipmaps.slice(0),this.mapping=e.mapping,this.wrapS=e.wrapS,this.wrapT=e.wrapT,this.magFilter=e.magFilter,this.minFilter=e.minFilter,this.anisotropy=e.anisotropy,this.format=e.format,this.internalFormat=e.internalFormat,this.type=e.type,this.offset.copy(e.offset),this.repeat.copy(e.repeat),this.center.copy(e.center),this.rotation=e.rotation,this.matrixAutoUpdate=e.matrixAutoUpdate,this.matrix.copy(e.matrix),this.generateMipmaps=e.generateMipmaps,this.premultiplyAlpha=e.premultiplyAlpha,this.flipY=e.flipY,this.unpackAlignment=e.unpackAlignment,this.encoding=e.encoding,this.userData=JSON.parse(JSON.stringify(e.userData)),this}toJSON(e){const t=void 0===e||"string"==typeof e;if(!t&&void 0!==e.textures[this.uuid])return e.textures[this.uuid];const i={metadata:{version:4.5,type:"Texture",generator:"Texture.toJSON"},uuid:this.uuid,name:this.name,mapping:this.mapping,repeat:[this.repeat.x,this.repeat.y],offset:[this.offset.x,this.offset.y],center:[this.center.x,this.center.y],rotation:this.rotation,wrap:[this.wrapS,this.wrapT],format:this.format,type:this.type,encoding:this.encoding,minFilter:this.minFilter,magFilter:this.magFilter,anisotropy:this.anisotropy,flipY:this.flipY,premultiplyAlpha:this.premultiplyAlpha,unpackAlignment:this.unpackAlignment};if(void 0!==this.image){const r=this.image;if(void 0===r.uuid&&(r.uuid=rc()),!t&&void 0===e.images[r.uuid]){let s;if(Array.isArray(r)){s=[];for(let o=0,a=r.length;o1)switch(this.wrapS){case KS:e.x=e.x-Math.floor(e.x);break;case Uo:e.x=e.x<0?0:1;break;case YS:e.x=1===Math.abs(Math.floor(e.x)%2)?Math.ceil(e.x)-e.x:e.x-Math.floor(e.x)}if(e.y<0||e.y>1)switch(this.wrapT){case KS:e.y=e.y-Math.floor(e.y);break;case Uo:e.y=e.y<0?0:1;break;case YS:e.y=1===Math.abs(Math.floor(e.y)%2)?Math.ceil(e.y)-e.y:e.y-Math.floor(e.y)}return this.flipY&&(e.y=1-e.y),e}set needsUpdate(e){!0===e&&this.version++}}function Fk(n){return typeof HTMLImageElement<"u"&&n instanceof HTMLImageElement||typeof HTMLCanvasElement<"u"&&n instanceof HTMLCanvasElement||typeof ImageBitmap<"u"&&n instanceof ImageBitmap?Yg.getDataURL(n):n.data?{data:Array.prototype.slice.call(n.data),width:n.width,height:n.height,type:n.data.constructor.name}:(console.warn("THREE.Texture: Unable to serialize Texture."),{})}io.DEFAULT_IMAGE=void 0,io.DEFAULT_MAPPING=300,io.prototype.isTexture=!0;class tr{constructor(e=0,t=0,i=0,r=1){this.x=e,this.y=t,this.z=i,this.w=r}get width(){return this.z}set width(e){this.z=e}get height(){return this.w}set height(e){this.w=e}set(e,t,i,r){return this.x=e,this.y=t,this.z=i,this.w=r,this}setScalar(e){return this.x=e,this.y=e,this.z=e,this.w=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setZ(e){return this.z=e,this}setW(e){return this.w=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;case 2:this.z=t;break;case 3:this.w=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;case 2:return this.z;case 3:return this.w;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y,this.z,this.w)}copy(e){return this.x=e.x,this.y=e.y,this.z=e.z,this.w=void 0!==e.w?e.w:1,this}add(e,t){return void 0!==t?(console.warn("THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this.z+=e.z,this.w+=e.w,this)}addScalar(e){return this.x+=e,this.y+=e,this.z+=e,this.w+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this.z=e.z+t.z,this.w=e.w+t.w,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this.z+=e.z*t,this.w+=e.w*t,this}sub(e,t){return void 0!==t?(console.warn("THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this.z-=e.z,this.w-=e.w,this)}subScalar(e){return this.x-=e,this.y-=e,this.z-=e,this.w-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this.z=e.z-t.z,this.w=e.w-t.w,this}multiply(e){return this.x*=e.x,this.y*=e.y,this.z*=e.z,this.w*=e.w,this}multiplyScalar(e){return this.x*=e,this.y*=e,this.z*=e,this.w*=e,this}applyMatrix4(e){const t=this.x,i=this.y,r=this.z,s=this.w,o=e.elements;return this.x=o[0]*t+o[4]*i+o[8]*r+o[12]*s,this.y=o[1]*t+o[5]*i+o[9]*r+o[13]*s,this.z=o[2]*t+o[6]*i+o[10]*r+o[14]*s,this.w=o[3]*t+o[7]*i+o[11]*r+o[15]*s,this}divideScalar(e){return this.multiplyScalar(1/e)}setAxisAngleFromQuaternion(e){this.w=2*Math.acos(e.w);const t=Math.sqrt(1-e.w*e.w);return t<1e-4?(this.x=1,this.y=0,this.z=0):(this.x=e.x/t,this.y=e.y/t,this.z=e.z/t),this}setAxisAngleFromRotationMatrix(e){let t,i,r,s;const c=e.elements,u=c[0],p=c[4],g=c[8],v=c[1],y=c[5],x=c[9],T=c[2],N=c[6],k=c[10];if(Math.abs(p-v)<.01&&Math.abs(g-T)<.01&&Math.abs(x-N)<.01){if(Math.abs(p+v)<.1&&Math.abs(g+T)<.1&&Math.abs(x+N)<.1&&Math.abs(u+y+k-3)<.1)return this.set(1,0,0,0),this;t=Math.PI;const H=(u+1)/2,G=(y+1)/2,X=(k+1)/2,se=(p+v)/4,K=(g+T)/4,he=(x+N)/4;return H>G&&H>X?H<.01?(i=0,r=.707106781,s=.707106781):(i=Math.sqrt(H),r=se/i,s=K/i):G>X?G<.01?(i=.707106781,r=0,s=.707106781):(r=Math.sqrt(G),i=se/r,s=he/r):X<.01?(i=.707106781,r=.707106781,s=0):(s=Math.sqrt(X),i=K/s,r=he/s),this.set(i,r,s,t),this}let A=Math.sqrt((N-x)*(N-x)+(g-T)*(g-T)+(v-p)*(v-p));return Math.abs(A)<.001&&(A=1),this.x=(N-x)/A,this.y=(g-T)/A,this.z=(v-p)/A,this.w=Math.acos((u+y+k-1)/2),this}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this.z=Math.min(this.z,e.z),this.w=Math.min(this.w,e.w),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this.z=Math.max(this.z,e.z),this.w=Math.max(this.w,e.w),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this.z=Math.max(e.z,Math.min(t.z,this.z)),this.w=Math.max(e.w,Math.min(t.w,this.w)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this.z=Math.max(e,Math.min(t,this.z)),this.w=Math.max(e,Math.min(t,this.w)),this}clampLength(e,t){const i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(e,Math.min(t,i)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this.w=Math.floor(this.w),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this.w=Math.ceil(this.w),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this.w=Math.round(this.w),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this.w=this.w<0?Math.ceil(this.w):Math.floor(this.w),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this.w=-this.w,this}dot(e){return this.x*e.x+this.y*e.y+this.z*e.z+this.w*e.w}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)+Math.abs(this.w)}normalize(){return this.divideScalar(this.length()||1)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this.z+=(e.z-this.z)*t,this.w+=(e.w-this.w)*t,this}lerpVectors(e,t,i){return this.x=e.x+(t.x-e.x)*i,this.y=e.y+(t.y-e.y)*i,this.z=e.z+(t.z-e.z)*i,this.w=e.w+(t.w-e.w)*i,this}equals(e){return e.x===this.x&&e.y===this.y&&e.z===this.z&&e.w===this.w}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this.z=e[t+2],this.w=e[t+3],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e[t+2]=this.z,e[t+3]=this.w,e}fromBufferAttribute(e,t,i){return void 0!==i&&console.warn("THREE.Vector4: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this.z=e.getZ(t),this.w=e.getW(t),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this.w=Math.random(),this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z,yield this.w}}tr.prototype.isVector4=!0;class Bc extends np{constructor(e,t,i={}){super(),this.width=e,this.height=t,this.depth=1,this.scissor=new tr(0,0,e,t),this.scissorTest=!1,this.viewport=new tr(0,0,e,t),this.texture=new io(void 0,i.mapping,i.wrapS,i.wrapT,i.magFilter,i.minFilter,i.format,i.type,i.anisotropy,i.encoding),this.texture.isRenderTargetTexture=!0,this.texture.image={width:e,height:t,depth:1},this.texture.generateMipmaps=void 0!==i.generateMipmaps&&i.generateMipmaps,this.texture.internalFormat=void 0!==i.internalFormat?i.internalFormat:null,this.texture.minFilter=void 0!==i.minFilter?i.minFilter:no,this.depthBuffer=void 0===i.depthBuffer||i.depthBuffer,this.stencilBuffer=void 0!==i.stencilBuffer&&i.stencilBuffer,this.depthTexture=void 0!==i.depthTexture?i.depthTexture:null}setTexture(e){e.image={width:this.width,height:this.height,depth:this.depth},this.texture=e}setSize(e,t,i=1){(this.width!==e||this.height!==t||this.depth!==i)&&(this.width=e,this.height=t,this.depth=i,this.texture.image.width=e,this.texture.image.height=t,this.texture.image.depth=i,this.dispose()),this.viewport.set(0,0,e,t),this.scissor.set(0,0,e,t)}clone(){return(new this.constructor).copy(this)}copy(e){return this.width=e.width,this.height=e.height,this.depth=e.depth,this.viewport.copy(e.viewport),this.texture=e.texture.clone(),this.texture.image={...this.texture.image},this.depthBuffer=e.depthBuffer,this.stencilBuffer=e.stencilBuffer,this.depthTexture=e.depthTexture,this}dispose(){this.dispatchEvent({type:"dispose"})}}Bc.prototype.isWebGLRenderTarget=!0,class ise extends Bc{constructor(e,t,i){super(e,t);const r=this.texture;this.texture=[];for(let s=0;s=0?1:-1,H=1-k*k;if(H>Number.EPSILON){const X=Math.sqrt(H),se=Math.atan2(X,k*A);N=Math.sin(N*se)/X,a=Math.sin(a*se)/X}const G=a*A;if(c=c*N+v*G,u=u*N+y*G,p=p*N+x*G,g=g*N+T*G,N===1-a){const X=1/Math.sqrt(c*c+u*u+p*p+g*g);c*=X,u*=X,p*=X,g*=X}}e[t]=c,e[t+1]=u,e[t+2]=p,e[t+3]=g}static multiplyQuaternionsFlat(e,t,i,r,s,o){const a=i[r],c=i[r+1],u=i[r+2],p=i[r+3],g=s[o],v=s[o+1],y=s[o+2],x=s[o+3];return e[t]=a*x+p*g+c*y-u*v,e[t+1]=c*x+p*v+u*g-a*y,e[t+2]=u*x+p*y+a*v-c*g,e[t+3]=p*x-a*g-c*v-u*y,e}get x(){return this._x}set x(e){this._x=e,this._onChangeCallback()}get y(){return this._y}set y(e){this._y=e,this._onChangeCallback()}get z(){return this._z}set z(e){this._z=e,this._onChangeCallback()}get w(){return this._w}set w(e){this._w=e,this._onChangeCallback()}set(e,t,i,r){return this._x=e,this._y=t,this._z=i,this._w=r,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._w)}copy(e){return this._x=e.x,this._y=e.y,this._z=e.z,this._w=e.w,this._onChangeCallback(),this}setFromEuler(e,t){if(!e||!e.isEuler)throw new Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");const i=e._x,r=e._y,s=e._z,o=e._order,a=Math.cos,c=Math.sin,u=a(i/2),p=a(r/2),g=a(s/2),v=c(i/2),y=c(r/2),x=c(s/2);switch(o){case"XYZ":this._x=v*p*g+u*y*x,this._y=u*y*g-v*p*x,this._z=u*p*x+v*y*g,this._w=u*p*g-v*y*x;break;case"YXZ":this._x=v*p*g+u*y*x,this._y=u*y*g-v*p*x,this._z=u*p*x-v*y*g,this._w=u*p*g+v*y*x;break;case"ZXY":this._x=v*p*g-u*y*x,this._y=u*y*g+v*p*x,this._z=u*p*x+v*y*g,this._w=u*p*g-v*y*x;break;case"ZYX":this._x=v*p*g-u*y*x,this._y=u*y*g+v*p*x,this._z=u*p*x-v*y*g,this._w=u*p*g+v*y*x;break;case"YZX":this._x=v*p*g+u*y*x,this._y=u*y*g+v*p*x,this._z=u*p*x-v*y*g,this._w=u*p*g-v*y*x;break;case"XZY":this._x=v*p*g-u*y*x,this._y=u*y*g-v*p*x,this._z=u*p*x+v*y*g,this._w=u*p*g+v*y*x;break;default:console.warn("THREE.Quaternion: .setFromEuler() encountered an unknown order: "+o)}return!1!==t&&this._onChangeCallback(),this}setFromAxisAngle(e,t){const i=t/2,r=Math.sin(i);return this._x=e.x*r,this._y=e.y*r,this._z=e.z*r,this._w=Math.cos(i),this._onChangeCallback(),this}setFromRotationMatrix(e){const t=e.elements,i=t[0],r=t[4],s=t[8],o=t[1],a=t[5],c=t[9],u=t[2],p=t[6],g=t[10],v=i+a+g;if(v>0){const y=.5/Math.sqrt(v+1);this._w=.25/y,this._x=(p-c)*y,this._y=(s-u)*y,this._z=(o-r)*y}else if(i>a&&i>g){const y=2*Math.sqrt(1+i-a-g);this._w=(p-c)/y,this._x=.25*y,this._y=(r+o)/y,this._z=(s+u)/y}else if(a>g){const y=2*Math.sqrt(1+a-i-g);this._w=(s-u)/y,this._x=(r+o)/y,this._y=.25*y,this._z=(c+p)/y}else{const y=2*Math.sqrt(1+g-i-a);this._w=(o-r)/y,this._x=(s+u)/y,this._y=(c+p)/y,this._z=.25*y}return this._onChangeCallback(),this}setFromUnitVectors(e,t){let i=e.dot(t)+1;return iMath.abs(e.z)?(this._x=-e.y,this._y=e.x,this._z=0,this._w=i):(this._x=0,this._y=-e.z,this._z=e.y,this._w=i)):(this._x=e.y*t.z-e.z*t.y,this._y=e.z*t.x-e.x*t.z,this._z=e.x*t.y-e.y*t.x,this._w=i),this.normalize()}angleTo(e){return 2*Math.acos(Math.abs(Mo(this.dot(e),-1,1)))}rotateTowards(e,t){const i=this.angleTo(e);if(0===i)return this;const r=Math.min(1,t/i);return this.slerp(e,r),this}identity(){return this.set(0,0,0,1)}invert(){return this.conjugate()}conjugate(){return this._x*=-1,this._y*=-1,this._z*=-1,this._onChangeCallback(),this}dot(e){return this._x*e._x+this._y*e._y+this._z*e._z+this._w*e._w}lengthSq(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w}length(){return Math.sqrt(this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w)}normalize(){let e=this.length();return 0===e?(this._x=0,this._y=0,this._z=0,this._w=1):(e=1/e,this._x=this._x*e,this._y=this._y*e,this._z=this._z*e,this._w=this._w*e),this._onChangeCallback(),this}multiply(e,t){return void 0!==t?(console.warn("THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead."),this.multiplyQuaternions(e,t)):this.multiplyQuaternions(this,e)}premultiply(e){return this.multiplyQuaternions(e,this)}multiplyQuaternions(e,t){const i=e._x,r=e._y,s=e._z,o=e._w,a=t._x,c=t._y,u=t._z,p=t._w;return this._x=i*p+o*a+r*u-s*c,this._y=r*p+o*c+s*a-i*u,this._z=s*p+o*u+i*c-r*a,this._w=o*p-i*a-r*c-s*u,this._onChangeCallback(),this}slerp(e,t){if(0===t)return this;if(1===t)return this.copy(e);const i=this._x,r=this._y,s=this._z,o=this._w;let a=o*e._w+i*e._x+r*e._y+s*e._z;if(a<0?(this._w=-e._w,this._x=-e._x,this._y=-e._y,this._z=-e._z,a=-a):this.copy(e),a>=1)return this._w=o,this._x=i,this._y=r,this._z=s,this;const c=1-a*a;if(c<=Number.EPSILON){const y=1-t;return this._w=y*o+t*this._w,this._x=y*i+t*this._x,this._y=y*r+t*this._y,this._z=y*s+t*this._z,this.normalize(),this._onChangeCallback(),this}const u=Math.sqrt(c),p=Math.atan2(u,a),g=Math.sin((1-t)*p)/u,v=Math.sin(t*p)/u;return this._w=o*g+this._w*v,this._x=i*g+this._x*v,this._y=r*g+this._y*v,this._z=s*g+this._z*v,this._onChangeCallback(),this}slerpQuaternions(e,t,i){this.copy(e).slerp(t,i)}random(){const e=Math.random(),t=Math.sqrt(1-e),i=Math.sqrt(e),r=2*Math.PI*Math.random(),s=2*Math.PI*Math.random();return this.set(t*Math.cos(r),i*Math.sin(s),i*Math.cos(s),t*Math.sin(r))}equals(e){return e._x===this._x&&e._y===this._y&&e._z===this._z&&e._w===this._w}fromArray(e,t=0){return this._x=e[t],this._y=e[t+1],this._z=e[t+2],this._w=e[t+3],this._onChangeCallback(),this}toArray(e=[],t=0){return e[t]=this._x,e[t+1]=this._y,e[t+2]=this._z,e[t+3]=this._w,e}fromBufferAttribute(e,t){return this._x=e.getX(t),this._y=e.getY(t),this._z=e.getZ(t),this._w=e.getW(t),this}_onChange(e){return this._onChangeCallback=e,this}_onChangeCallback(){}}Go.prototype.isQuaternion=!0;class ne{constructor(e=0,t=0,i=0){this.x=e,this.y=t,this.z=i}set(e,t,i){return void 0===i&&(i=this.z),this.x=e,this.y=t,this.z=i,this}setScalar(e){return this.x=e,this.y=e,this.z=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setZ(e){return this.z=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;case 2:this.z=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y,this.z)}copy(e){return this.x=e.x,this.y=e.y,this.z=e.z,this}add(e,t){return void 0!==t?(console.warn("THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this.z+=e.z,this)}addScalar(e){return this.x+=e,this.y+=e,this.z+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this.z=e.z+t.z,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this.z+=e.z*t,this}sub(e,t){return void 0!==t?(console.warn("THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this.z-=e.z,this)}subScalar(e){return this.x-=e,this.y-=e,this.z-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this.z=e.z-t.z,this}multiply(e,t){return void 0!==t?(console.warn("THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead."),this.multiplyVectors(e,t)):(this.x*=e.x,this.y*=e.y,this.z*=e.z,this)}multiplyScalar(e){return this.x*=e,this.y*=e,this.z*=e,this}multiplyVectors(e,t){return this.x=e.x*t.x,this.y=e.y*t.y,this.z=e.z*t.z,this}applyEuler(e){return e&&e.isEuler||console.error("THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order."),this.applyQuaternion(gB.setFromEuler(e))}applyAxisAngle(e,t){return this.applyQuaternion(gB.setFromAxisAngle(e,t))}applyMatrix3(e){const t=this.x,i=this.y,r=this.z,s=e.elements;return this.x=s[0]*t+s[3]*i+s[6]*r,this.y=s[1]*t+s[4]*i+s[7]*r,this.z=s[2]*t+s[5]*i+s[8]*r,this}applyNormalMatrix(e){return this.applyMatrix3(e).normalize()}applyMatrix4(e){const t=this.x,i=this.y,r=this.z,s=e.elements,o=1/(s[3]*t+s[7]*i+s[11]*r+s[15]);return this.x=(s[0]*t+s[4]*i+s[8]*r+s[12])*o,this.y=(s[1]*t+s[5]*i+s[9]*r+s[13])*o,this.z=(s[2]*t+s[6]*i+s[10]*r+s[14])*o,this}applyQuaternion(e){const t=this.x,i=this.y,r=this.z,s=e.x,o=e.y,a=e.z,c=e.w,u=c*t+o*r-a*i,p=c*i+a*t-s*r,g=c*r+s*i-o*t,v=-s*t-o*i-a*r;return this.x=u*c+v*-s+p*-a-g*-o,this.y=p*c+v*-o+g*-s-u*-a,this.z=g*c+v*-a+u*-o-p*-s,this}project(e){return this.applyMatrix4(e.matrixWorldInverse).applyMatrix4(e.projectionMatrix)}unproject(e){return this.applyMatrix4(e.projectionMatrixInverse).applyMatrix4(e.matrixWorld)}transformDirection(e){const t=this.x,i=this.y,r=this.z,s=e.elements;return this.x=s[0]*t+s[4]*i+s[8]*r,this.y=s[1]*t+s[5]*i+s[9]*r,this.z=s[2]*t+s[6]*i+s[10]*r,this.normalize()}divide(e){return this.x/=e.x,this.y/=e.y,this.z/=e.z,this}divideScalar(e){return this.multiplyScalar(1/e)}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this.z=Math.min(this.z,e.z),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this.z=Math.max(this.z,e.z),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this.z=Math.max(e.z,Math.min(t.z,this.z)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this.z=Math.max(e,Math.min(t,this.z)),this}clampLength(e,t){const i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(e,Math.min(t,i)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this}dot(e){return this.x*e.x+this.y*e.y+this.z*e.z}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)}normalize(){return this.divideScalar(this.length()||1)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this.z+=(e.z-this.z)*t,this}lerpVectors(e,t,i){return this.x=e.x+(t.x-e.x)*i,this.y=e.y+(t.y-e.y)*i,this.z=e.z+(t.z-e.z)*i,this}cross(e,t){return void 0!==t?(console.warn("THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead."),this.crossVectors(e,t)):this.crossVectors(this,e)}crossVectors(e,t){const i=e.x,r=e.y,s=e.z,o=t.x,a=t.y,c=t.z;return this.x=r*c-s*a,this.y=s*o-i*c,this.z=i*a-r*o,this}projectOnVector(e){const t=e.lengthSq();if(0===t)return this.set(0,0,0);const i=e.dot(this)/t;return this.copy(e).multiplyScalar(i)}projectOnPlane(e){return Pk.copy(this).projectOnVector(e),this.sub(Pk)}reflect(e){return this.sub(Pk.copy(e).multiplyScalar(2*this.dot(e)))}angleTo(e){const t=Math.sqrt(this.lengthSq()*e.lengthSq());if(0===t)return Math.PI/2;const i=this.dot(e)/t;return Math.acos(Mo(i,-1,1))}distanceTo(e){return Math.sqrt(this.distanceToSquared(e))}distanceToSquared(e){const t=this.x-e.x,i=this.y-e.y,r=this.z-e.z;return t*t+i*i+r*r}manhattanDistanceTo(e){return Math.abs(this.x-e.x)+Math.abs(this.y-e.y)+Math.abs(this.z-e.z)}setFromSpherical(e){return this.setFromSphericalCoords(e.radius,e.phi,e.theta)}setFromSphericalCoords(e,t,i){const r=Math.sin(t)*e;return this.x=r*Math.sin(i),this.y=Math.cos(t)*e,this.z=r*Math.cos(i),this}setFromCylindrical(e){return this.setFromCylindricalCoords(e.radius,e.theta,e.y)}setFromCylindricalCoords(e,t,i){return this.x=e*Math.sin(t),this.y=i,this.z=e*Math.cos(t),this}setFromMatrixPosition(e){const t=e.elements;return this.x=t[12],this.y=t[13],this.z=t[14],this}setFromMatrixScale(e){const t=this.setFromMatrixColumn(e,0).length(),i=this.setFromMatrixColumn(e,1).length(),r=this.setFromMatrixColumn(e,2).length();return this.x=t,this.y=i,this.z=r,this}setFromMatrixColumn(e,t){return this.fromArray(e.elements,4*t)}setFromMatrix3Column(e,t){return this.fromArray(e.elements,3*t)}equals(e){return e.x===this.x&&e.y===this.y&&e.z===this.z}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this.z=e[t+2],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e[t+2]=this.z,e}fromBufferAttribute(e,t,i){return void 0!==i&&console.warn("THREE.Vector3: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this.z=e.getZ(t),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this}randomDirection(){const e=2*(Math.random()-.5),t=Math.random()*Math.PI*2,i=Math.sqrt(1-e**2);return this.x=i*Math.cos(t),this.y=i*Math.sin(t),this.z=e,this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z}}ne.prototype.isVector3=!0;const Pk=new ne,gB=new Go;class Vc{constructor(e=new ne(1/0,1/0,1/0),t=new ne(-1/0,-1/0,-1/0)){this.min=e,this.max=t}set(e,t){return this.min.copy(e),this.max.copy(t),this}setFromArray(e){let t=1/0,i=1/0,r=1/0,s=-1/0,o=-1/0,a=-1/0;for(let c=0,u=e.length;cs&&(s=p),g>o&&(o=g),v>a&&(a=v)}return this.min.set(t,i,r),this.max.set(s,o,a),this}setFromBufferAttribute(e){let t=1/0,i=1/0,r=1/0,s=-1/0,o=-1/0,a=-1/0;for(let c=0,u=e.count;cs&&(s=p),g>o&&(o=g),v>a&&(a=v)}return this.min.set(t,i,r),this.max.set(s,o,a),this}setFromPoints(e){this.makeEmpty();for(let t=0,i=e.length;tthis.max.x||e.ythis.max.y||e.zthis.max.z)}containsBox(e){return this.min.x<=e.min.x&&e.max.x<=this.max.x&&this.min.y<=e.min.y&&e.max.y<=this.max.y&&this.min.z<=e.min.z&&e.max.z<=this.max.z}getParameter(e,t){return t.set((e.x-this.min.x)/(this.max.x-this.min.x),(e.y-this.min.y)/(this.max.y-this.min.y),(e.z-this.min.z)/(this.max.z-this.min.z))}intersectsBox(e){return!(e.max.xthis.max.x||e.max.ythis.max.y||e.max.zthis.max.z)}intersectsSphere(e){return this.clampPoint(e.center,Ly),Ly.distanceToSquared(e.center)<=e.radius*e.radius}intersectsPlane(e){let t,i;return e.normal.x>0?(t=e.normal.x*this.min.x,i=e.normal.x*this.max.x):(t=e.normal.x*this.max.x,i=e.normal.x*this.min.x),e.normal.y>0?(t+=e.normal.y*this.min.y,i+=e.normal.y*this.max.y):(t+=e.normal.y*this.max.y,i+=e.normal.y*this.min.y),e.normal.z>0?(t+=e.normal.z*this.min.z,i+=e.normal.z*this.max.z):(t+=e.normal.z*this.max.z,i+=e.normal.z*this.min.z),t<=-e.constant&&i>=-e.constant}intersectsTriangle(e){if(this.isEmpty())return!1;this.getCenter(Ny),r2.subVectors(this.max,Ny),Xg.subVectors(e.a,Ny),Zg.subVectors(e.b,Ny),Jg.subVectors(e.c,Ny),ph.subVectors(Zg,Xg),mh.subVectors(Jg,Zg),rp.subVectors(Xg,Jg);let t=[0,-ph.z,ph.y,0,-mh.z,mh.y,0,-rp.z,rp.y,ph.z,0,-ph.x,mh.z,0,-mh.x,rp.z,0,-rp.x,-ph.y,ph.x,0,-mh.y,mh.x,0,-rp.y,rp.x,0];return!(!Lk(t,Xg,Zg,Jg,r2)||(t=[1,0,0,0,1,0,0,0,1],!Lk(t,Xg,Zg,Jg,r2)))&&(s2.crossVectors(ph,mh),t=[s2.x,s2.y,s2.z],Lk(t,Xg,Zg,Jg,r2))}clampPoint(e,t){return t.copy(e).clamp(this.min,this.max)}distanceToPoint(e){return Ly.copy(e).clamp(this.min,this.max).sub(e).length()}getBoundingSphere(e){return this.getCenter(e.center),e.radius=.5*this.getSize(Ly).length(),e}intersect(e){return this.min.max(e.min),this.max.min(e.max),this.isEmpty()&&this.makeEmpty(),this}union(e){return this.min.min(e.min),this.max.max(e.max),this}applyMatrix4(e){return this.isEmpty()||(Xd[0].set(this.min.x,this.min.y,this.min.z).applyMatrix4(e),Xd[1].set(this.min.x,this.min.y,this.max.z).applyMatrix4(e),Xd[2].set(this.min.x,this.max.y,this.min.z).applyMatrix4(e),Xd[3].set(this.min.x,this.max.y,this.max.z).applyMatrix4(e),Xd[4].set(this.max.x,this.min.y,this.min.z).applyMatrix4(e),Xd[5].set(this.max.x,this.min.y,this.max.z).applyMatrix4(e),Xd[6].set(this.max.x,this.max.y,this.min.z).applyMatrix4(e),Xd[7].set(this.max.x,this.max.y,this.max.z).applyMatrix4(e),this.setFromPoints(Xd)),this}translate(e){return this.min.add(e),this.max.add(e),this}equals(e){return e.min.equals(this.min)&&e.max.equals(this.max)}}Vc.prototype.isBox3=!0;const Xd=[new ne,new ne,new ne,new ne,new ne,new ne,new ne,new ne],Ly=new ne,Ok=new Vc,Xg=new ne,Zg=new ne,Jg=new ne,ph=new ne,mh=new ne,rp=new ne,Ny=new ne,r2=new ne,s2=new ne,sp=new ne;function Lk(n,e,t,i,r){for(let s=0,o=n.length-3;s<=o;s+=3){sp.fromArray(n,s);const a=r.x*Math.abs(sp.x)+r.y*Math.abs(sp.y)+r.z*Math.abs(sp.z),c=e.dot(sp),u=t.dot(sp),p=i.dot(sp);if(Math.max(-Math.max(c,u,p),Math.min(c,u,p))>a)return!1}return!0}const rse=new Vc,_B=new ne,Nk=new ne,Bk=new ne;class op{constructor(e=new ne,t=-1){this.center=e,this.radius=t}set(e,t){return this.center.copy(e),this.radius=t,this}setFromPoints(e,t){const i=this.center;void 0!==t?i.copy(t):rse.setFromPoints(e).getCenter(i);let r=0;for(let s=0,o=e.length;sthis.radius*this.radius&&(t.sub(this.center).normalize(),t.multiplyScalar(this.radius).add(this.center)),t}getBoundingBox(e){return this.isEmpty()?(e.makeEmpty(),e):(e.set(this.center,this.center),e.expandByScalar(this.radius),e)}applyMatrix4(e){return this.center.applyMatrix4(e),this.radius=this.radius*e.getMaxScaleOnAxis(),this}translate(e){return this.center.add(e),this}expandByPoint(e){Bk.subVectors(e,this.center);const t=Bk.lengthSq();if(t>this.radius*this.radius){const i=Math.sqrt(t),r=.5*(i-this.radius);this.center.add(Bk.multiplyScalar(r/i)),this.radius+=r}return this}union(e){return Nk.subVectors(e.center,this.center).normalize().multiplyScalar(e.radius),this.expandByPoint(_B.copy(e.center).add(Nk)),this.expandByPoint(_B.copy(e.center).sub(Nk)),this}equals(e){return e.center.equals(this.center)&&e.radius===this.radius}clone(){return(new this.constructor).copy(this)}}const Zd=new ne,Vk=new ne,o2=new ne,gh=new ne,Hk=new ne,a2=new ne,Uk=new ne;class ap{constructor(e=new ne,t=new ne(0,0,-1)){this.origin=e,this.direction=t}set(e,t){return this.origin.copy(e),this.direction.copy(t),this}copy(e){return this.origin.copy(e.origin),this.direction.copy(e.direction),this}at(e,t){return t.copy(this.direction).multiplyScalar(e).add(this.origin)}lookAt(e){return this.direction.copy(e).sub(this.origin).normalize(),this}recast(e){return this.origin.copy(this.at(e,Zd)),this}closestPointToPoint(e,t){t.subVectors(e,this.origin);const i=t.dot(this.direction);return i<0?t.copy(this.origin):t.copy(this.direction).multiplyScalar(i).add(this.origin)}distanceToPoint(e){return Math.sqrt(this.distanceSqToPoint(e))}distanceSqToPoint(e){const t=Zd.subVectors(e,this.origin).dot(this.direction);return t<0?this.origin.distanceToSquared(e):(Zd.copy(this.direction).multiplyScalar(t).add(this.origin),Zd.distanceToSquared(e))}distanceSqToSegment(e,t,i,r){Vk.copy(e).add(t).multiplyScalar(.5),o2.copy(t).sub(e).normalize(),gh.copy(this.origin).sub(Vk);const s=.5*e.distanceTo(t),o=-this.direction.dot(o2),a=gh.dot(this.direction),c=-gh.dot(o2),u=gh.lengthSq(),p=Math.abs(1-o*o);let g,v,y,x;if(p>0)if(g=o*c-a,v=o*a-c,x=s*p,g>=0)if(v>=-x)if(v<=x){const T=1/p;g*=T,v*=T,y=g*(g+o*v+2*a)+v*(o*g+v+2*c)+u}else v=s,g=Math.max(0,-(o*v+a)),y=-g*g+v*(v+2*c)+u;else v=-s,g=Math.max(0,-(o*v+a)),y=-g*g+v*(v+2*c)+u;else v<=-x?(g=Math.max(0,-(-o*s+a)),v=g>0?-s:Math.min(Math.max(-s,-c),s),y=-g*g+v*(v+2*c)+u):v<=x?(g=0,v=Math.min(Math.max(-s,-c),s),y=v*(v+2*c)+u):(g=Math.max(0,-(o*s+a)),v=g>0?s:Math.min(Math.max(-s,-c),s),y=-g*g+v*(v+2*c)+u);else v=o>0?-s:s,g=Math.max(0,-(o*v+a)),y=-g*g+v*(v+2*c)+u;return i&&i.copy(this.direction).multiplyScalar(g).add(this.origin),r&&r.copy(o2).multiplyScalar(v).add(Vk),y}intersectSphere(e,t){Zd.subVectors(e.center,this.origin);const i=Zd.dot(this.direction),r=Zd.dot(Zd)-i*i,s=e.radius*e.radius;if(r>s)return null;const o=Math.sqrt(s-r),a=i-o,c=i+o;return a<0&&c<0?null:this.at(a<0?c:a,t)}intersectsSphere(e){return this.distanceSqToPoint(e.center)<=e.radius*e.radius}distanceToPlane(e){const t=e.normal.dot(this.direction);if(0===t)return 0===e.distanceToPoint(this.origin)?0:null;const i=-(this.origin.dot(e.normal)+e.constant)/t;return i>=0?i:null}intersectPlane(e,t){const i=this.distanceToPlane(e);return null===i?null:this.at(i,t)}intersectsPlane(e){const t=e.distanceToPoint(this.origin);return 0===t||e.normal.dot(this.direction)*t<0}intersectBox(e,t){let i,r,s,o,a,c;const u=1/this.direction.x,p=1/this.direction.y,g=1/this.direction.z,v=this.origin;return u>=0?(i=(e.min.x-v.x)*u,r=(e.max.x-v.x)*u):(i=(e.max.x-v.x)*u,r=(e.min.x-v.x)*u),p>=0?(s=(e.min.y-v.y)*p,o=(e.max.y-v.y)*p):(s=(e.max.y-v.y)*p,o=(e.min.y-v.y)*p),i>o||s>r||((s>i||i!=i)&&(i=s),(o=0?(a=(e.min.z-v.z)*g,c=(e.max.z-v.z)*g):(a=(e.max.z-v.z)*g,c=(e.min.z-v.z)*g),i>c||a>r)||((a>i||i!=i)&&(i=a),(c=0?i:r,t)}intersectsBox(e){return null!==this.intersectBox(e,Zd)}intersectTriangle(e,t,i,r,s){Hk.subVectors(t,e),a2.subVectors(i,e),Uk.crossVectors(Hk,a2);let a,o=this.direction.dot(Uk);if(o>0){if(r)return null;a=1}else{if(!(o<0))return null;a=-1,o=-o}gh.subVectors(this.origin,e);const c=a*this.direction.dot(a2.crossVectors(gh,a2));if(c<0)return null;const u=a*this.direction.dot(Hk.cross(gh));if(u<0||c+u>o)return null;const p=-a*gh.dot(Uk);return p<0?null:this.at(p/o,s)}applyMatrix4(e){return this.origin.applyMatrix4(e),this.direction.transformDirection(e),this}equals(e){return e.origin.equals(this.origin)&&e.direction.equals(this.direction)}clone(){return(new this.constructor).copy(this)}}class Gt{constructor(){this.elements=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],arguments.length>0&&console.error("THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.")}set(e,t,i,r,s,o,a,c,u,p,g,v,y,x,T,N){const k=this.elements;return k[0]=e,k[4]=t,k[8]=i,k[12]=r,k[1]=s,k[5]=o,k[9]=a,k[13]=c,k[2]=u,k[6]=p,k[10]=g,k[14]=v,k[3]=y,k[7]=x,k[11]=T,k[15]=N,this}identity(){return this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1),this}clone(){return(new Gt).fromArray(this.elements)}copy(e){const t=this.elements,i=e.elements;return t[0]=i[0],t[1]=i[1],t[2]=i[2],t[3]=i[3],t[4]=i[4],t[5]=i[5],t[6]=i[6],t[7]=i[7],t[8]=i[8],t[9]=i[9],t[10]=i[10],t[11]=i[11],t[12]=i[12],t[13]=i[13],t[14]=i[14],t[15]=i[15],this}copyPosition(e){const t=this.elements,i=e.elements;return t[12]=i[12],t[13]=i[13],t[14]=i[14],this}setFromMatrix3(e){const t=e.elements;return this.set(t[0],t[3],t[6],0,t[1],t[4],t[7],0,t[2],t[5],t[8],0,0,0,0,1),this}extractBasis(e,t,i){return e.setFromMatrixColumn(this,0),t.setFromMatrixColumn(this,1),i.setFromMatrixColumn(this,2),this}makeBasis(e,t,i){return this.set(e.x,t.x,i.x,0,e.y,t.y,i.y,0,e.z,t.z,i.z,0,0,0,0,1),this}extractRotation(e){const t=this.elements,i=e.elements,r=1/Qg.setFromMatrixColumn(e,0).length(),s=1/Qg.setFromMatrixColumn(e,1).length(),o=1/Qg.setFromMatrixColumn(e,2).length();return t[0]=i[0]*r,t[1]=i[1]*r,t[2]=i[2]*r,t[3]=0,t[4]=i[4]*s,t[5]=i[5]*s,t[6]=i[6]*s,t[7]=0,t[8]=i[8]*o,t[9]=i[9]*o,t[10]=i[10]*o,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,this}makeRotationFromEuler(e){e&&e.isEuler||console.error("THREE.Matrix4: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.");const t=this.elements,i=e.x,r=e.y,s=e.z,o=Math.cos(i),a=Math.sin(i),c=Math.cos(r),u=Math.sin(r),p=Math.cos(s),g=Math.sin(s);if("XYZ"===e.order){const v=o*p,y=o*g,x=a*p,T=a*g;t[0]=c*p,t[4]=-c*g,t[8]=u,t[1]=y+x*u,t[5]=v-T*u,t[9]=-a*c,t[2]=T-v*u,t[6]=x+y*u,t[10]=o*c}else if("YXZ"===e.order){const v=c*p,y=c*g,x=u*p,T=u*g;t[0]=v+T*a,t[4]=x*a-y,t[8]=o*u,t[1]=o*g,t[5]=o*p,t[9]=-a,t[2]=y*a-x,t[6]=T+v*a,t[10]=o*c}else if("ZXY"===e.order){const v=c*p,y=c*g,x=u*p,T=u*g;t[0]=v-T*a,t[4]=-o*g,t[8]=x+y*a,t[1]=y+x*a,t[5]=o*p,t[9]=T-v*a,t[2]=-o*u,t[6]=a,t[10]=o*c}else if("ZYX"===e.order){const v=o*p,y=o*g,x=a*p,T=a*g;t[0]=c*p,t[4]=x*u-y,t[8]=v*u+T,t[1]=c*g,t[5]=T*u+v,t[9]=y*u-x,t[2]=-u,t[6]=a*c,t[10]=o*c}else if("YZX"===e.order){const v=o*c,y=o*u,x=a*c,T=a*u;t[0]=c*p,t[4]=T-v*g,t[8]=x*g+y,t[1]=g,t[5]=o*p,t[9]=-a*p,t[2]=-u*p,t[6]=y*g+x,t[10]=v-T*g}else if("XZY"===e.order){const v=o*c,y=o*u,x=a*c,T=a*u;t[0]=c*p,t[4]=-g,t[8]=u*p,t[1]=v*g+T,t[5]=o*p,t[9]=y*g-x,t[2]=x*g-y,t[6]=a*p,t[10]=T*g+v}return t[3]=0,t[7]=0,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,this}makeRotationFromQuaternion(e){return this.compose(sse,e,ose)}lookAt(e,t,i){const r=this.elements;return sc.subVectors(e,t),0===sc.lengthSq()&&(sc.z=1),sc.normalize(),_h.crossVectors(i,sc),0===_h.lengthSq()&&(1===Math.abs(i.z)?sc.x+=1e-4:sc.z+=1e-4,sc.normalize(),_h.crossVectors(i,sc)),_h.normalize(),c2.crossVectors(sc,_h),r[0]=_h.x,r[4]=c2.x,r[8]=sc.x,r[1]=_h.y,r[5]=c2.y,r[9]=sc.y,r[2]=_h.z,r[6]=c2.z,r[10]=sc.z,this}multiply(e,t){return void 0!==t?(console.warn("THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead."),this.multiplyMatrices(e,t)):this.multiplyMatrices(this,e)}premultiply(e){return this.multiplyMatrices(e,this)}multiplyMatrices(e,t){const i=e.elements,r=t.elements,s=this.elements,o=i[0],a=i[4],c=i[8],u=i[12],p=i[1],g=i[5],v=i[9],y=i[13],x=i[2],T=i[6],N=i[10],k=i[14],A=i[3],H=i[7],G=i[11],X=i[15],se=r[0],K=r[4],he=r[8],De=r[12],Te=r[1],ge=r[5],Qe=r[9],Pe=r[13],Oe=r[2],Ve=r[6],ye=r[10],Me=r[14],je=r[3],lt=r[7],ze=r[11],Ke=r[15];return s[0]=o*se+a*Te+c*Oe+u*je,s[4]=o*K+a*ge+c*Ve+u*lt,s[8]=o*he+a*Qe+c*ye+u*ze,s[12]=o*De+a*Pe+c*Me+u*Ke,s[1]=p*se+g*Te+v*Oe+y*je,s[5]=p*K+g*ge+v*Ve+y*lt,s[9]=p*he+g*Qe+v*ye+y*ze,s[13]=p*De+g*Pe+v*Me+y*Ke,s[2]=x*se+T*Te+N*Oe+k*je,s[6]=x*K+T*ge+N*Ve+k*lt,s[10]=x*he+T*Qe+N*ye+k*ze,s[14]=x*De+T*Pe+N*Me+k*Ke,s[3]=A*se+H*Te+G*Oe+X*je,s[7]=A*K+H*ge+G*Ve+X*lt,s[11]=A*he+H*Qe+G*ye+X*ze,s[15]=A*De+H*Pe+G*Me+X*Ke,this}multiplyScalar(e){const t=this.elements;return t[0]*=e,t[4]*=e,t[8]*=e,t[12]*=e,t[1]*=e,t[5]*=e,t[9]*=e,t[13]*=e,t[2]*=e,t[6]*=e,t[10]*=e,t[14]*=e,t[3]*=e,t[7]*=e,t[11]*=e,t[15]*=e,this}determinant(){const e=this.elements,t=e[0],i=e[4],r=e[8],s=e[12],o=e[1],a=e[5],c=e[9],u=e[13],p=e[2],g=e[6],v=e[10],y=e[14];return e[3]*(+s*c*g-r*u*g-s*a*v+i*u*v+r*a*y-i*c*y)+e[7]*(+t*c*y-t*u*v+s*o*v-r*o*y+r*u*p-s*c*p)+e[11]*(+t*u*g-t*a*y-s*o*g+i*o*y+s*a*p-i*u*p)+e[15]*(-r*a*p-t*c*g+t*a*v+r*o*g-i*o*v+i*c*p)}transpose(){const e=this.elements;let t;return t=e[1],e[1]=e[4],e[4]=t,t=e[2],e[2]=e[8],e[8]=t,t=e[6],e[6]=e[9],e[9]=t,t=e[3],e[3]=e[12],e[12]=t,t=e[7],e[7]=e[13],e[13]=t,t=e[11],e[11]=e[14],e[14]=t,this}setPosition(e,t,i){const r=this.elements;return e.isVector3?(r[12]=e.x,r[13]=e.y,r[14]=e.z):(r[12]=e,r[13]=t,r[14]=i),this}invert(){const e=this.elements,t=e[0],i=e[1],r=e[2],s=e[3],o=e[4],a=e[5],c=e[6],u=e[7],p=e[8],g=e[9],v=e[10],y=e[11],x=e[12],T=e[13],N=e[14],k=e[15],A=g*N*u-T*v*u+T*c*y-a*N*y-g*c*k+a*v*k,H=x*v*u-p*N*u-x*c*y+o*N*y+p*c*k-o*v*k,G=p*T*u-x*g*u+x*a*y-o*T*y-p*a*k+o*g*k,X=x*g*c-p*T*c-x*a*v+o*T*v+p*a*N-o*g*N,se=t*A+i*H+r*G+s*X;if(0===se)return this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);const K=1/se;return e[0]=A*K,e[1]=(T*v*s-g*N*s-T*r*y+i*N*y+g*r*k-i*v*k)*K,e[2]=(a*N*s-T*c*s+T*r*u-i*N*u-a*r*k+i*c*k)*K,e[3]=(g*c*s-a*v*s-g*r*u+i*v*u+a*r*y-i*c*y)*K,e[4]=H*K,e[5]=(p*N*s-x*v*s+x*r*y-t*N*y-p*r*k+t*v*k)*K,e[6]=(x*c*s-o*N*s-x*r*u+t*N*u+o*r*k-t*c*k)*K,e[7]=(o*v*s-p*c*s+p*r*u-t*v*u-o*r*y+t*c*y)*K,e[8]=G*K,e[9]=(x*g*s-p*T*s-x*i*y+t*T*y+p*i*k-t*g*k)*K,e[10]=(o*T*s-x*a*s+x*i*u-t*T*u-o*i*k+t*a*k)*K,e[11]=(p*a*s-o*g*s-p*i*u+t*g*u+o*i*y-t*a*y)*K,e[12]=X*K,e[13]=(p*T*r-x*g*r+x*i*v-t*T*v-p*i*N+t*g*N)*K,e[14]=(x*a*r-o*T*r-x*i*c+t*T*c+o*i*N-t*a*N)*K,e[15]=(o*g*r-p*a*r+p*i*c-t*g*c-o*i*v+t*a*v)*K,this}scale(e){const t=this.elements,i=e.x,r=e.y,s=e.z;return t[0]*=i,t[4]*=r,t[8]*=s,t[1]*=i,t[5]*=r,t[9]*=s,t[2]*=i,t[6]*=r,t[10]*=s,t[3]*=i,t[7]*=r,t[11]*=s,this}getMaxScaleOnAxis(){const e=this.elements;return Math.sqrt(Math.max(e[0]*e[0]+e[1]*e[1]+e[2]*e[2],e[4]*e[4]+e[5]*e[5]+e[6]*e[6],e[8]*e[8]+e[9]*e[9]+e[10]*e[10]))}makeTranslation(e,t,i){return this.set(1,0,0,e,0,1,0,t,0,0,1,i,0,0,0,1),this}makeRotationX(e){const t=Math.cos(e),i=Math.sin(e);return this.set(1,0,0,0,0,t,-i,0,0,i,t,0,0,0,0,1),this}makeRotationY(e){const t=Math.cos(e),i=Math.sin(e);return this.set(t,0,i,0,0,1,0,0,-i,0,t,0,0,0,0,1),this}makeRotationZ(e){const t=Math.cos(e),i=Math.sin(e);return this.set(t,-i,0,0,i,t,0,0,0,0,1,0,0,0,0,1),this}makeRotationAxis(e,t){const i=Math.cos(t),r=Math.sin(t),s=1-i,o=e.x,a=e.y,c=e.z,u=s*o,p=s*a;return this.set(u*o+i,u*a-r*c,u*c+r*a,0,u*a+r*c,p*a+i,p*c-r*o,0,u*c-r*a,p*c+r*o,s*c*c+i,0,0,0,0,1),this}makeScale(e,t,i){return this.set(e,0,0,0,0,t,0,0,0,0,i,0,0,0,0,1),this}makeShear(e,t,i,r,s,o){return this.set(1,i,s,0,e,1,o,0,t,r,1,0,0,0,0,1),this}compose(e,t,i){const r=this.elements,s=t._x,o=t._y,a=t._z,c=t._w,u=s+s,p=o+o,g=a+a,v=s*u,y=s*p,x=s*g,T=o*p,N=o*g,k=a*g,A=c*u,H=c*p,G=c*g,X=i.x,se=i.y,K=i.z;return r[0]=(1-(T+k))*X,r[1]=(y+G)*X,r[2]=(x-H)*X,r[3]=0,r[4]=(y-G)*se,r[5]=(1-(v+k))*se,r[6]=(N+A)*se,r[7]=0,r[8]=(x+H)*K,r[9]=(N-A)*K,r[10]=(1-(v+T))*K,r[11]=0,r[12]=e.x,r[13]=e.y,r[14]=e.z,r[15]=1,this}decompose(e,t,i){const r=this.elements;let s=Qg.set(r[0],r[1],r[2]).length();const o=Qg.set(r[4],r[5],r[6]).length(),a=Qg.set(r[8],r[9],r[10]).length();this.determinant()<0&&(s=-s),e.x=r[12],e.y=r[13],e.z=r[14],gl.copy(this);const u=1/s,p=1/o,g=1/a;return gl.elements[0]*=u,gl.elements[1]*=u,gl.elements[2]*=u,gl.elements[4]*=p,gl.elements[5]*=p,gl.elements[6]*=p,gl.elements[8]*=g,gl.elements[9]*=g,gl.elements[10]*=g,t.setFromRotationMatrix(gl),i.x=s,i.y=o,i.z=a,this}makePerspective(e,t,i,r,s,o){void 0===o&&console.warn("THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.");const a=this.elements,u=2*s/(i-r),p=(t+e)/(t-e),g=(i+r)/(i-r),v=-(o+s)/(o-s),y=-2*o*s/(o-s);return a[0]=2*s/(t-e),a[4]=0,a[8]=p,a[12]=0,a[1]=0,a[5]=u,a[9]=g,a[13]=0,a[2]=0,a[6]=0,a[10]=v,a[14]=y,a[3]=0,a[7]=0,a[11]=-1,a[15]=0,this}makeOrthographic(e,t,i,r,s,o){const a=this.elements,c=1/(t-e),u=1/(i-r),p=1/(o-s),g=(t+e)*c,v=(i+r)*u,y=(o+s)*p;return a[0]=2*c,a[4]=0,a[8]=0,a[12]=-g,a[1]=0,a[5]=2*u,a[9]=0,a[13]=-v,a[2]=0,a[6]=0,a[10]=-2*p,a[14]=-y,a[3]=0,a[7]=0,a[11]=0,a[15]=1,this}equals(e){const t=this.elements,i=e.elements;for(let r=0;r<16;r++)if(t[r]!==i[r])return!1;return!0}fromArray(e,t=0){for(let i=0;i<16;i++)this.elements[i]=e[i+t];return this}toArray(e=[],t=0){const i=this.elements;return e[t]=i[0],e[t+1]=i[1],e[t+2]=i[2],e[t+3]=i[3],e[t+4]=i[4],e[t+5]=i[5],e[t+6]=i[6],e[t+7]=i[7],e[t+8]=i[8],e[t+9]=i[9],e[t+10]=i[10],e[t+11]=i[11],e[t+12]=i[12],e[t+13]=i[13],e[t+14]=i[14],e[t+15]=i[15],e}}Gt.prototype.isMatrix4=!0;const Qg=new ne,gl=new Gt,sse=new ne(0,0,0),ose=new ne(1,1,1),_h=new ne,c2=new ne,sc=new ne,vB=new Gt,yB=new Go;class e0{constructor(e=0,t=0,i=0,r=e0.DefaultOrder){this._x=e,this._y=t,this._z=i,this._order=r}get x(){return this._x}set x(e){this._x=e,this._onChangeCallback()}get y(){return this._y}set y(e){this._y=e,this._onChangeCallback()}get z(){return this._z}set z(e){this._z=e,this._onChangeCallback()}get order(){return this._order}set order(e){this._order=e,this._onChangeCallback()}set(e,t,i,r=this._order){return this._x=e,this._y=t,this._z=i,this._order=r,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._order)}copy(e){return this._x=e._x,this._y=e._y,this._z=e._z,this._order=e._order,this._onChangeCallback(),this}setFromRotationMatrix(e,t=this._order,i=!0){const r=e.elements,s=r[0],o=r[4],a=r[8],c=r[1],u=r[5],p=r[9],g=r[2],v=r[6],y=r[10];switch(t){case"XYZ":this._y=Math.asin(Mo(a,-1,1)),Math.abs(a)<.9999999?(this._x=Math.atan2(-p,y),this._z=Math.atan2(-o,s)):(this._x=Math.atan2(v,u),this._z=0);break;case"YXZ":this._x=Math.asin(-Mo(p,-1,1)),Math.abs(p)<.9999999?(this._y=Math.atan2(a,y),this._z=Math.atan2(c,u)):(this._y=Math.atan2(-g,s),this._z=0);break;case"ZXY":this._x=Math.asin(Mo(v,-1,1)),Math.abs(v)<.9999999?(this._y=Math.atan2(-g,y),this._z=Math.atan2(-o,u)):(this._y=0,this._z=Math.atan2(c,s));break;case"ZYX":this._y=Math.asin(-Mo(g,-1,1)),Math.abs(g)<.9999999?(this._x=Math.atan2(v,y),this._z=Math.atan2(c,s)):(this._x=0,this._z=Math.atan2(-o,u));break;case"YZX":this._z=Math.asin(Mo(c,-1,1)),Math.abs(c)<.9999999?(this._x=Math.atan2(-p,u),this._y=Math.atan2(-g,s)):(this._x=0,this._y=Math.atan2(a,y));break;case"XZY":this._z=Math.asin(-Mo(o,-1,1)),Math.abs(o)<.9999999?(this._x=Math.atan2(v,u),this._y=Math.atan2(a,s)):(this._x=Math.atan2(-p,y),this._y=0);break;default:console.warn("THREE.Euler: .setFromRotationMatrix() encountered an unknown order: "+t)}return this._order=t,!0===i&&this._onChangeCallback(),this}setFromQuaternion(e,t,i){return vB.makeRotationFromQuaternion(e),this.setFromRotationMatrix(vB,t,i)}setFromVector3(e,t=this._order){return this.set(e.x,e.y,e.z,t)}reorder(e){return yB.setFromEuler(this),this.setFromQuaternion(yB,e)}equals(e){return e._x===this._x&&e._y===this._y&&e._z===this._z&&e._order===this._order}fromArray(e){return this._x=e[0],this._y=e[1],this._z=e[2],void 0!==e[3]&&(this._order=e[3]),this._onChangeCallback(),this}toArray(e=[],t=0){return e[t]=this._x,e[t+1]=this._y,e[t+2]=this._z,e[t+3]=this._order,e}toVector3(e){return e?e.set(this._x,this._y,this._z):new ne(this._x,this._y,this._z)}_onChange(e){return this._onChangeCallback=e,this}_onChangeCallback(){}}e0.prototype.isEuler=!0,e0.DefaultOrder="XYZ",e0.RotationOrders=["XYZ","YZX","ZXY","XZY","YXZ","ZYX"];class bB{constructor(){this.mask=1}set(e){this.mask=(1<>>0}enable(e){this.mask|=1<1){for(let t=0;t1){for(let i=0;i0){r.children=[];for(let a=0;a0){r.animations=[];for(let a=0;a0&&(i.geometries=a),c.length>0&&(i.materials=c),u.length>0&&(i.textures=u),p.length>0&&(i.images=p),g.length>0&&(i.shapes=g),v.length>0&&(i.skeletons=v),y.length>0&&(i.animations=y)}return i.object=r,i;function o(a){const c=[];for(const u in a){const p=a[u];delete p.metadata,c.push(p)}return c}}clone(e){return(new this.constructor).copy(this,e)}copy(e,t=!0){if(this.name=e.name,this.up.copy(e.up),this.position.copy(e.position),this.rotation.order=e.rotation.order,this.quaternion.copy(e.quaternion),this.scale.copy(e.scale),this.matrix.copy(e.matrix),this.matrixWorld.copy(e.matrixWorld),this.matrixAutoUpdate=e.matrixAutoUpdate,this.matrixWorldNeedsUpdate=e.matrixWorldNeedsUpdate,this.layers.mask=e.layers.mask,this.visible=e.visible,this.castShadow=e.castShadow,this.receiveShadow=e.receiveShadow,this.frustumCulled=e.frustumCulled,this.renderOrder=e.renderOrder,this.userData=JSON.parse(JSON.stringify(e.userData)),!0===t)for(let i=0;i0?r.multiplyScalar(1/Math.sqrt(s)):r.set(0,0,0)}static getBarycoord(e,t,i,r,s){_l.subVectors(r,t),Qd.subVectors(i,t),zk.subVectors(e,t);const o=_l.dot(_l),a=_l.dot(Qd),c=_l.dot(zk),u=Qd.dot(Qd),p=Qd.dot(zk),g=o*u-a*a;if(0===g)return s.set(-2,-1,-1);const v=1/g,y=(u*c-a*p)*v,x=(o*p-a*c)*v;return s.set(1-y-x,x,y)}static containsPoint(e,t,i,r){return this.getBarycoord(e,t,i,r,eu),eu.x>=0&&eu.y>=0&&eu.x+eu.y<=1}static getUV(e,t,i,r,s,o,a,c){return this.getBarycoord(e,t,i,r,eu),c.set(0,0),c.addScaledVector(s,eu.x),c.addScaledVector(o,eu.y),c.addScaledVector(a,eu.z),c}static isFrontFacing(e,t,i,r){return _l.subVectors(i,t),Qd.subVectors(e,t),_l.cross(Qd).dot(r)<0}set(e,t,i){return this.a.copy(e),this.b.copy(t),this.c.copy(i),this}setFromPointsAndIndices(e,t,i,r){return this.a.copy(e[t]),this.b.copy(e[i]),this.c.copy(e[r]),this}setFromAttributeAndIndices(e,t,i,r){return this.a.fromBufferAttribute(e,t),this.b.fromBufferAttribute(e,i),this.c.fromBufferAttribute(e,r),this}clone(){return(new this.constructor).copy(this)}copy(e){return this.a.copy(e.a),this.b.copy(e.b),this.c.copy(e.c),this}getArea(){return _l.subVectors(this.c,this.b),Qd.subVectors(this.a,this.b),.5*_l.cross(Qd).length()}getMidpoint(e){return e.addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)}getNormal(e){return Ts.getNormal(this.a,this.b,this.c,e)}getPlane(e){return e.setFromCoplanarPoints(this.a,this.b,this.c)}getBarycoord(e,t){return Ts.getBarycoord(e,this.a,this.b,this.c,t)}getUV(e,t,i,r,s){return Ts.getUV(e,this.a,this.b,this.c,t,i,r,s)}containsPoint(e){return Ts.containsPoint(e,this.a,this.b,this.c)}isFrontFacing(e){return Ts.isFrontFacing(this.a,this.b,this.c,e)}intersectsBox(e){return e.intersectsTriangle(this)}closestPointToPoint(e,t){const i=this.a,r=this.b,s=this.c;let o,a;n0.subVectors(r,i),r0.subVectors(s,i),Gk.subVectors(e,i);const c=n0.dot(Gk),u=r0.dot(Gk);if(c<=0&&u<=0)return t.copy(i);jk.subVectors(e,r);const p=n0.dot(jk),g=r0.dot(jk);if(p>=0&&g<=p)return t.copy(r);const v=c*g-p*u;if(v<=0&&c>=0&&p<=0)return o=c/(c-p),t.copy(i).addScaledVector(n0,o);Wk.subVectors(e,s);const y=n0.dot(Wk),x=r0.dot(Wk);if(x>=0&&y<=x)return t.copy(s);const T=y*u-c*x;if(T<=0&&u>=0&&x<=0)return a=u/(u-x),t.copy(i).addScaledVector(r0,a);const N=p*x-y*g;if(N<=0&&g-p>=0&&y-x>=0)return CB.subVectors(s,r),a=(g-p)/(g-p+(y-x)),t.copy(r).addScaledVector(CB,a);const k=1/(N+T+v);return o=T*k,a=v*k,t.copy(i).addScaledVector(n0,o).addScaledVector(r0,a)}equals(e){return e.a.equals(this.a)&&e.b.equals(this.b)&&e.c.equals(this.c)}}let use=0;class Co extends np{constructor(){super(),Object.defineProperty(this,"id",{value:use++}),this.uuid=rc(),this.name="",this.type="Material",this.fog=!0,this.blending=Ay,this.side=Og,this.vertexColors=!1,this.opacity=1,this.format=zo,this.transparent=!1,this.blendSrc=K8,this.blendDst=Y8,this.blendEquation=Ng,this.blendSrcAlpha=null,this.blendDstAlpha=null,this.blendEquationAlpha=null,this.depthFunc=xk,this.depthTest=!0,this.depthWrite=!0,this.stencilWriteMask=255,this.stencilFunc=519,this.stencilRef=0,this.stencilFuncMask=255,this.stencilFail=7680,this.stencilZFail=7680,this.stencilZPass=7680,this.stencilWrite=!1,this.clippingPlanes=null,this.clipIntersection=!1,this.clipShadows=!1,this.shadowSide=null,this.colorWrite=!0,this.precision=null,this.polygonOffset=!1,this.polygonOffsetFactor=0,this.polygonOffsetUnits=0,this.dithering=!1,this.alphaToCoverage=!1,this.premultipliedAlpha=!1,this.visible=!0,this.toneMapped=!0,this.userData={},this.version=0,this._alphaTest=0}get alphaTest(){return this._alphaTest}set alphaTest(e){this._alphaTest>0!=e>0&&this.version++,this._alphaTest=e}onBuild(){}onBeforeRender(){}onBeforeCompile(){}customProgramCacheKey(){return this.onBeforeCompile.toString()}setValues(e){if(void 0!==e)for(const t in e){const i=e[t];if(void 0===i){console.warn("THREE.Material: '"+t+"' parameter is undefined.");continue}if("shading"===t){console.warn("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead."),this.flatShading=1===i;continue}const r=this[t];void 0!==r?r&&r.isColor?r.set(i):r&&r.isVector3&&i&&i.isVector3?r.copy(i):this[t]=i:console.warn("THREE."+this.type+": '"+t+"' is not a property of this material.")}}toJSON(e){const t=void 0===e||"string"==typeof e;t&&(e={textures:{},images:{}});const i={metadata:{version:4.5,type:"Material",generator:"Material.toJSON"}};function r(s){const o=[];for(const a in s){const c=s[a];delete c.metadata,o.push(c)}return o}if(i.uuid=this.uuid,i.type=this.type,""!==this.name&&(i.name=this.name),this.color&&this.color.isColor&&(i.color=this.color.getHex()),void 0!==this.roughness&&(i.roughness=this.roughness),void 0!==this.metalness&&(i.metalness=this.metalness),void 0!==this.sheen&&(i.sheen=this.sheen),this.sheenColor&&this.sheenColor.isColor&&(i.sheenColor=this.sheenColor.getHex()),void 0!==this.sheenRoughness&&(i.sheenRoughness=this.sheenRoughness),this.emissive&&this.emissive.isColor&&(i.emissive=this.emissive.getHex()),this.emissiveIntensity&&1!==this.emissiveIntensity&&(i.emissiveIntensity=this.emissiveIntensity),this.specular&&this.specular.isColor&&(i.specular=this.specular.getHex()),void 0!==this.specularIntensity&&(i.specularIntensity=this.specularIntensity),this.specularColor&&this.specularColor.isColor&&(i.specularColor=this.specularColor.getHex()),void 0!==this.shininess&&(i.shininess=this.shininess),void 0!==this.clearcoat&&(i.clearcoat=this.clearcoat),void 0!==this.clearcoatRoughness&&(i.clearcoatRoughness=this.clearcoatRoughness),this.clearcoatMap&&this.clearcoatMap.isTexture&&(i.clearcoatMap=this.clearcoatMap.toJSON(e).uuid),this.clearcoatRoughnessMap&&this.clearcoatRoughnessMap.isTexture&&(i.clearcoatRoughnessMap=this.clearcoatRoughnessMap.toJSON(e).uuid),this.clearcoatNormalMap&&this.clearcoatNormalMap.isTexture&&(i.clearcoatNormalMap=this.clearcoatNormalMap.toJSON(e).uuid,i.clearcoatNormalScale=this.clearcoatNormalScale.toArray()),this.map&&this.map.isTexture&&(i.map=this.map.toJSON(e).uuid),this.matcap&&this.matcap.isTexture&&(i.matcap=this.matcap.toJSON(e).uuid),this.alphaMap&&this.alphaMap.isTexture&&(i.alphaMap=this.alphaMap.toJSON(e).uuid),this.lightMap&&this.lightMap.isTexture&&(i.lightMap=this.lightMap.toJSON(e).uuid,i.lightMapIntensity=this.lightMapIntensity),this.aoMap&&this.aoMap.isTexture&&(i.aoMap=this.aoMap.toJSON(e).uuid,i.aoMapIntensity=this.aoMapIntensity),this.bumpMap&&this.bumpMap.isTexture&&(i.bumpMap=this.bumpMap.toJSON(e).uuid,i.bumpScale=this.bumpScale),this.normalMap&&this.normalMap.isTexture&&(i.normalMap=this.normalMap.toJSON(e).uuid,i.normalMapType=this.normalMapType,i.normalScale=this.normalScale.toArray()),this.displacementMap&&this.displacementMap.isTexture&&(i.displacementMap=this.displacementMap.toJSON(e).uuid,i.displacementScale=this.displacementScale,i.displacementBias=this.displacementBias),this.roughnessMap&&this.roughnessMap.isTexture&&(i.roughnessMap=this.roughnessMap.toJSON(e).uuid),this.metalnessMap&&this.metalnessMap.isTexture&&(i.metalnessMap=this.metalnessMap.toJSON(e).uuid),this.emissiveMap&&this.emissiveMap.isTexture&&(i.emissiveMap=this.emissiveMap.toJSON(e).uuid),this.specularMap&&this.specularMap.isTexture&&(i.specularMap=this.specularMap.toJSON(e).uuid),this.specularIntensityMap&&this.specularIntensityMap.isTexture&&(i.specularIntensityMap=this.specularIntensityMap.toJSON(e).uuid),this.specularColorMap&&this.specularColorMap.isTexture&&(i.specularColorMap=this.specularColorMap.toJSON(e).uuid),this.envMap&&this.envMap.isTexture&&(i.envMap=this.envMap.toJSON(e).uuid,void 0!==this.combine&&(i.combine=this.combine)),void 0!==this.envMapIntensity&&(i.envMapIntensity=this.envMapIntensity),void 0!==this.reflectivity&&(i.reflectivity=this.reflectivity),void 0!==this.refractionRatio&&(i.refractionRatio=this.refractionRatio),this.gradientMap&&this.gradientMap.isTexture&&(i.gradientMap=this.gradientMap.toJSON(e).uuid),void 0!==this.transmission&&(i.transmission=this.transmission),this.transmissionMap&&this.transmissionMap.isTexture&&(i.transmissionMap=this.transmissionMap.toJSON(e).uuid),void 0!==this.thickness&&(i.thickness=this.thickness),this.thicknessMap&&this.thicknessMap.isTexture&&(i.thicknessMap=this.thicknessMap.toJSON(e).uuid),void 0!==this.attenuationDistance&&(i.attenuationDistance=this.attenuationDistance),void 0!==this.attenuationColor&&(i.attenuationColor=this.attenuationColor.getHex()),void 0!==this.size&&(i.size=this.size),null!==this.shadowSide&&(i.shadowSide=this.shadowSide),void 0!==this.sizeAttenuation&&(i.sizeAttenuation=this.sizeAttenuation),this.blending!==Ay&&(i.blending=this.blending),this.side!==Og&&(i.side=this.side),this.vertexColors&&(i.vertexColors=!0),this.opacity<1&&(i.opacity=this.opacity),this.format!==zo&&(i.format=this.format),!0===this.transparent&&(i.transparent=this.transparent),i.depthFunc=this.depthFunc,i.depthTest=this.depthTest,i.depthWrite=this.depthWrite,i.colorWrite=this.colorWrite,i.stencilWrite=this.stencilWrite,i.stencilWriteMask=this.stencilWriteMask,i.stencilFunc=this.stencilFunc,i.stencilRef=this.stencilRef,i.stencilFuncMask=this.stencilFuncMask,i.stencilFail=this.stencilFail,i.stencilZFail=this.stencilZFail,i.stencilZPass=this.stencilZPass,this.rotation&&0!==this.rotation&&(i.rotation=this.rotation),!0===this.polygonOffset&&(i.polygonOffset=!0),0!==this.polygonOffsetFactor&&(i.polygonOffsetFactor=this.polygonOffsetFactor),0!==this.polygonOffsetUnits&&(i.polygonOffsetUnits=this.polygonOffsetUnits),this.linewidth&&1!==this.linewidth&&(i.linewidth=this.linewidth),void 0!==this.dashSize&&(i.dashSize=this.dashSize),void 0!==this.gapSize&&(i.gapSize=this.gapSize),void 0!==this.scale&&(i.scale=this.scale),!0===this.dithering&&(i.dithering=!0),this.alphaTest>0&&(i.alphaTest=this.alphaTest),!0===this.alphaToCoverage&&(i.alphaToCoverage=this.alphaToCoverage),!0===this.premultipliedAlpha&&(i.premultipliedAlpha=this.premultipliedAlpha),!0===this.wireframe&&(i.wireframe=this.wireframe),this.wireframeLinewidth>1&&(i.wireframeLinewidth=this.wireframeLinewidth),"round"!==this.wireframeLinecap&&(i.wireframeLinecap=this.wireframeLinecap),"round"!==this.wireframeLinejoin&&(i.wireframeLinejoin=this.wireframeLinejoin),!0===this.flatShading&&(i.flatShading=this.flatShading),!1===this.visible&&(i.visible=!1),!1===this.toneMapped&&(i.toneMapped=!1),"{}"!==JSON.stringify(this.userData)&&(i.userData=this.userData),t){const s=r(e.textures),o=r(e.images);s.length>0&&(i.textures=s),o.length>0&&(i.images=o)}return i}clone(){return(new this.constructor).copy(this)}copy(e){this.name=e.name,this.fog=e.fog,this.blending=e.blending,this.side=e.side,this.vertexColors=e.vertexColors,this.opacity=e.opacity,this.format=e.format,this.transparent=e.transparent,this.blendSrc=e.blendSrc,this.blendDst=e.blendDst,this.blendEquation=e.blendEquation,this.blendSrcAlpha=e.blendSrcAlpha,this.blendDstAlpha=e.blendDstAlpha,this.blendEquationAlpha=e.blendEquationAlpha,this.depthFunc=e.depthFunc,this.depthTest=e.depthTest,this.depthWrite=e.depthWrite,this.stencilWriteMask=e.stencilWriteMask,this.stencilFunc=e.stencilFunc,this.stencilRef=e.stencilRef,this.stencilFuncMask=e.stencilFuncMask,this.stencilFail=e.stencilFail,this.stencilZFail=e.stencilZFail,this.stencilZPass=e.stencilZPass,this.stencilWrite=e.stencilWrite;const t=e.clippingPlanes;let i=null;if(null!==t){const r=t.length;i=new Array(r);for(let s=0;s!==r;++s)i[s]=t[s].clone()}return this.clippingPlanes=i,this.clipIntersection=e.clipIntersection,this.clipShadows=e.clipShadows,this.shadowSide=e.shadowSide,this.colorWrite=e.colorWrite,this.precision=e.precision,this.polygonOffset=e.polygonOffset,this.polygonOffsetFactor=e.polygonOffsetFactor,this.polygonOffsetUnits=e.polygonOffsetUnits,this.dithering=e.dithering,this.alphaTest=e.alphaTest,this.alphaToCoverage=e.alphaToCoverage,this.premultipliedAlpha=e.premultipliedAlpha,this.visible=e.visible,this.toneMapped=e.toneMapped,this.userData=JSON.parse(JSON.stringify(e.userData)),this}dispose(){this.dispatchEvent({type:"dispose"})}set needsUpdate(e){!0===e&&this.version++}}Co.prototype.isMaterial=!0;const DB={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074},vl={h:0,s:0,l:0},d2={h:0,s:0,l:0};function $k(n,e,t){return t<0&&(t+=1),t>1&&(t-=1),t<1/6?n+6*(e-n)*t:t<.5?e:t<2/3?n+6*(e-n)*(2/3-t):n}function qk(n){return n<.04045?.0773993808*n:Math.pow(.9478672986*n+.0521327014,2.4)}function Kk(n){return n<.0031308?12.92*n:1.055*Math.pow(n,.41666)-.055}let Rt=(()=>{class n{constructor(t,i,r){return void 0===i&&void 0===r?this.set(t):this.setRGB(t,i,r)}set(t){return t&&t.isColor?this.copy(t):"number"==typeof t?this.setHex(t):"string"==typeof t&&this.setStyle(t),this}setScalar(t){return this.r=t,this.g=t,this.b=t,this}setHex(t){return t=Math.floor(t),this.r=(t>>16&255)/255,this.g=(t>>8&255)/255,this.b=(255&t)/255,this}setRGB(t,i,r){return this.r=t,this.g=i,this.b=r,this}setHSL(t,i,r){if(t=function kk(n,e){return(n%e+e)%e}(t,1),i=Mo(i,0,1),r=Mo(r,0,1),0===i)this.r=this.g=this.b=r;else{const s=r<=.5?r*(1+i):r+i-r*i,o=2*r-s;this.r=$k(o,s,t+1/3),this.g=$k(o,s,t),this.b=$k(o,s,t-1/3)}return this}setStyle(t){function i(s){void 0!==s&&parseFloat(s)<1&&console.warn("THREE.Color: Alpha component of "+t+" will be ignored.")}let r;if(r=/^((?:rgb|hsl)a?)\(([^\)]*)\)/.exec(t)){let s;const a=r[2];switch(r[1]){case"rgb":case"rgba":if(s=/^\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(a))return this.r=Math.min(255,parseInt(s[1],10))/255,this.g=Math.min(255,parseInt(s[2],10))/255,this.b=Math.min(255,parseInt(s[3],10))/255,i(s[4]),this;if(s=/^\s*(\d+)\%\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(a))return this.r=Math.min(100,parseInt(s[1],10))/100,this.g=Math.min(100,parseInt(s[2],10))/100,this.b=Math.min(100,parseInt(s[3],10))/100,i(s[4]),this;break;case"hsl":case"hsla":if(s=/^\s*(\d*\.?\d+)\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(a)){const c=parseFloat(s[1])/360,u=parseInt(s[2],10)/100,p=parseInt(s[3],10)/100;return i(s[4]),this.setHSL(c,u,p)}}}else if(r=/^\#([A-Fa-f\d]+)$/.exec(t)){const s=r[1],o=s.length;if(3===o)return this.r=parseInt(s.charAt(0)+s.charAt(0),16)/255,this.g=parseInt(s.charAt(1)+s.charAt(1),16)/255,this.b=parseInt(s.charAt(2)+s.charAt(2),16)/255,this;if(6===o)return this.r=parseInt(s.charAt(0)+s.charAt(1),16)/255,this.g=parseInt(s.charAt(2)+s.charAt(3),16)/255,this.b=parseInt(s.charAt(4)+s.charAt(5),16)/255,this}return t&&t.length>0?this.setColorName(t):this}setColorName(t){const i=DB[t.toLowerCase()];return void 0!==i?this.setHex(i):console.warn("THREE.Color: Unknown color "+t),this}clone(){return new this.constructor(this.r,this.g,this.b)}copy(t){return this.r=t.r,this.g=t.g,this.b=t.b,this}copyGammaToLinear(t,i=2){return this.r=Math.pow(t.r,i),this.g=Math.pow(t.g,i),this.b=Math.pow(t.b,i),this}copyLinearToGamma(t,i=2){const r=i>0?1/i:1;return this.r=Math.pow(t.r,r),this.g=Math.pow(t.g,r),this.b=Math.pow(t.b,r),this}convertGammaToLinear(t){return this.copyGammaToLinear(this,t),this}convertLinearToGamma(t){return this.copyLinearToGamma(this,t),this}copySRGBToLinear(t){return this.r=qk(t.r),this.g=qk(t.g),this.b=qk(t.b),this}copyLinearToSRGB(t){return this.r=Kk(t.r),this.g=Kk(t.g),this.b=Kk(t.b),this}convertSRGBToLinear(){return this.copySRGBToLinear(this),this}convertLinearToSRGB(){return this.copyLinearToSRGB(this),this}getHex(){return 255*this.r<<16^255*this.g<<8^255*this.b<<0}getHexString(){return("000000"+this.getHex().toString(16)).slice(-6)}getHSL(t){const i=this.r,r=this.g,s=this.b,o=Math.max(i,r,s),a=Math.min(i,r,s);let c,u;const p=(a+o)/2;if(a===o)c=0,u=0;else{const g=o-a;switch(u=p<=.5?g/(o+a):g/(2-o-a),o){case i:c=(r-s)/g+(r65535?Xk:Yk)(e,1):e,this}getAttribute(e){return this.attributes[e]}setAttribute(e,t){return this.attributes[e]=t,this}deleteAttribute(e){return delete this.attributes[e],this}hasAttribute(e){return void 0!==this.attributes[e]}addGroup(e,t,i=0){this.groups.push({start:e,count:t,materialIndex:i})}clearGroups(){this.groups=[]}setDrawRange(e,t){this.drawRange.start=e,this.drawRange.count=t}applyMatrix4(e){const t=this.attributes.position;void 0!==t&&(t.applyMatrix4(e),t.needsUpdate=!0);const i=this.attributes.normal;if(void 0!==i){const s=(new js).getNormalMatrix(e);i.applyNormalMatrix(s),i.needsUpdate=!0}const r=this.attributes.tangent;return void 0!==r&&(r.transformDirection(e),r.needsUpdate=!0),null!==this.boundingBox&&this.computeBoundingBox(),null!==this.boundingSphere&&this.computeBoundingSphere(),this}applyQuaternion(e){return Hc.makeRotationFromQuaternion(e),this.applyMatrix4(Hc),this}rotateX(e){return Hc.makeRotationX(e),this.applyMatrix4(Hc),this}rotateY(e){return Hc.makeRotationY(e),this.applyMatrix4(Hc),this}rotateZ(e){return Hc.makeRotationZ(e),this.applyMatrix4(Hc),this}translate(e,t,i){return Hc.makeTranslation(e,t,i),this.applyMatrix4(Hc),this}scale(e,t,i){return Hc.makeScale(e,t,i),this.applyMatrix4(Hc),this}lookAt(e){return Zk.lookAt(e),Zk.updateMatrix(),this.applyMatrix4(Zk.matrix),this}center(){return this.computeBoundingBox(),this.boundingBox.getCenter(s0).negate(),this.translate(s0.x,s0.y,s0.z),this}setFromPoints(e){const t=[];for(let i=0,r=e.length;i0&&(e.userData=this.userData),void 0!==this.parameters){const c=this.parameters;for(const u in c)void 0!==c[u]&&(e[u]=c[u]);return e}e.data={attributes:{}};const t=this.index;null!==t&&(e.data.index={type:t.array.constructor.name,array:Array.prototype.slice.call(t.array)});const i=this.attributes;for(const c in i)e.data.attributes[c]=i[c].toJSON(e.data);const r={};let s=!1;for(const c in this.morphAttributes){const u=this.morphAttributes[c],p=[];for(let g=0,v=u.length;g0&&(r[c]=p,s=!0)}s&&(e.data.morphAttributes=r,e.data.morphTargetsRelative=this.morphTargetsRelative);const o=this.groups;o.length>0&&(e.data.groups=JSON.parse(JSON.stringify(o)));const a=this.boundingSphere;return null!==a&&(e.data.boundingSphere={center:a.center.toArray(),radius:a.radius}),e}clone(){return(new this.constructor).copy(this)}copy(e){this.index=null,this.attributes={},this.morphAttributes={},this.groups=[],this.boundingBox=null,this.boundingSphere=null;const t={};this.name=e.name;const i=e.index;null!==i&&this.setIndex(i.clone(t));const r=e.attributes;for(const u in r)this.setAttribute(u,r[u].clone(t));const s=e.morphAttributes;for(const u in s){const p=[],g=s[u];for(let v=0,y=g.length;v0){const r=t[i[0]];if(void 0!==r){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Mesh.updateMorphTargets() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}}raycast(e,t){const i=this.geometry,r=this.material,s=this.matrixWorld;if(void 0===r||(null===i.boundingSphere&&i.computeBoundingSphere(),Jk.copy(i.boundingSphere),Jk.applyMatrix4(s),!1===e.ray.intersectsSphere(Jk))||(TB.copy(s).invert(),o0.copy(e.ray).applyMatrix4(TB),null!==i.boundingBox&&!1===o0.intersectsBox(i.boundingBox)))return;let o;if(i.isBufferGeometry){const a=i.index,c=i.attributes.position,u=i.morphAttributes.position,p=i.morphTargetsRelative,g=i.attributes.uv,v=i.attributes.uv2,y=i.groups,x=i.drawRange;if(null!==a)if(Array.isArray(r))for(let T=0,N=y.length;Tt.far?null:{distance:u,point:v2.clone(),object:n}}(n,e,t,i,yh,bh,xh,nI);if(y){a&&(m2.fromBufferAttribute(a,u),g2.fromBufferAttribute(a,p),_2.fromBufferAttribute(a,g),y.uv=Ts.getUV(nI,yh,bh,xh,m2,g2,_2,new tt)),c&&(m2.fromBufferAttribute(c,u),g2.fromBufferAttribute(c,p),_2.fromBufferAttribute(c,g),y.uv2=Ts.getUV(nI,yh,bh,xh,m2,g2,_2,new tt));const x={a:u,b:p,c:g,normal:new ne,materialIndex:0};Ts.getNormal(yh,bh,xh,x.normal),y.face=x}return y}vr.prototype.isMesh=!0;class tu extends gn{constructor(e=1,t=1,i=1,r=1,s=1,o=1){super(),this.type="BoxGeometry",this.parameters={width:e,height:t,depth:i,widthSegments:r,heightSegments:s,depthSegments:o};const a=this;r=Math.floor(r),s=Math.floor(s),o=Math.floor(o);const c=[],u=[],p=[],g=[];let v=0,y=0;function x(T,N,k,A,H,G,X,se,K,he,De){const Te=G/K,ge=X/he,Qe=G/2,Pe=X/2,Oe=se/2,Ve=K+1,ye=he+1;let Me=0,je=0;const lt=new ne;for(let ze=0;ze0?1:-1,p.push(lt.x,lt.y,lt.z),g.push(vt/K),g.push(1-ze/he),Me+=1}for(let ze=0;ze0&&(t.defines=this.defines),t.vertexShader=this.vertexShader,t.fragmentShader=this.fragmentShader;const i={};for(const r in this.extensions)!0===this.extensions[r]&&(i[r]=!0);return Object.keys(i).length>0&&(t.extensions=i),t}}wh.prototype.isShaderMaterial=!0;class b2 extends qi{constructor(){super(),this.type="Camera",this.matrixWorldInverse=new Gt,this.projectionMatrix=new Gt,this.projectionMatrixInverse=new Gt}copy(e,t){return super.copy(e,t),this.matrixWorldInverse.copy(e.matrixWorldInverse),this.projectionMatrix.copy(e.projectionMatrix),this.projectionMatrixInverse.copy(e.projectionMatrixInverse),this}getWorldDirection(e){this.updateWorldMatrix(!0,!1);const t=this.matrixWorld.elements;return e.set(-t[8],-t[9],-t[10]).normalize()}updateMatrixWorld(e){super.updateMatrixWorld(e),this.matrixWorldInverse.copy(this.matrixWorld).invert()}updateWorldMatrix(e,t){super.updateWorldMatrix(e,t),this.matrixWorldInverse.copy(this.matrixWorld).invert()}clone(){return(new this.constructor).copy(this)}}b2.prototype.isCamera=!0;class Do extends b2{constructor(e=50,t=1,i=.1,r=2e3){super(),this.type="PerspectiveCamera",this.fov=e,this.zoom=1,this.near=i,this.far=r,this.focus=10,this.aspect=t,this.view=null,this.filmGauge=35,this.filmOffset=0,this.updateProjectionMatrix()}copy(e,t){return super.copy(e,t),this.fov=e.fov,this.zoom=e.zoom,this.near=e.near,this.far=e.far,this.focus=e.focus,this.aspect=e.aspect,this.view=null===e.view?null:Object.assign({},e.view),this.filmGauge=e.filmGauge,this.filmOffset=e.filmOffset,this}setFocalLength(e){const t=.5*this.getFilmHeight()/e;this.fov=2*Py*Math.atan(t),this.updateProjectionMatrix()}getFocalLength(){const e=Math.tan(.5*ip*this.fov);return.5*this.getFilmHeight()/e}getEffectiveFOV(){return 2*Py*Math.atan(Math.tan(.5*ip*this.fov)/this.zoom)}getFilmWidth(){return this.filmGauge*Math.min(this.aspect,1)}getFilmHeight(){return this.filmGauge/Math.max(this.aspect,1)}setViewOffset(e,t,i,r,s,o){this.aspect=e/t,null===this.view&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=e,this.view.fullHeight=t,this.view.offsetX=i,this.view.offsetY=r,this.view.width=s,this.view.height=o,this.updateProjectionMatrix()}clearViewOffset(){null!==this.view&&(this.view.enabled=!1),this.updateProjectionMatrix()}updateProjectionMatrix(){const e=this.near;let t=e*Math.tan(.5*ip*this.fov)/this.zoom,i=2*t,r=this.aspect*i,s=-.5*r;const o=this.view;if(null!==this.view&&this.view.enabled){const c=o.fullWidth,u=o.fullHeight;s+=o.offsetX*r/c,t-=o.offsetY*i/u,r*=o.width/c,i*=o.height/u}const a=this.filmOffset;0!==a&&(s+=e*a/this.getFilmWidth()),this.projectionMatrix.makePerspective(s,s+r,t,t-i,e,this.far),this.projectionMatrixInverse.copy(this.projectionMatrix).invert()}toJSON(e){const t=super.toJSON(e);return t.object.fov=this.fov,t.object.zoom=this.zoom,t.object.near=this.near,t.object.far=this.far,t.object.focus=this.focus,t.object.aspect=this.aspect,null!==this.view&&(t.object.view=Object.assign({},this.view)),t.object.filmGauge=this.filmGauge,t.object.filmOffset=this.filmOffset,t}}Do.prototype.isPerspectiveCamera=!0;class iI extends qi{constructor(e,t,i){if(super(),this.type="CubeCamera",!0!==i.isWebGLCubeRenderTarget)return void console.error("THREE.CubeCamera: The constructor now expects an instance of WebGLCubeRenderTarget as third parameter.");this.renderTarget=i;const r=new Do(90,1,e,t);r.layers=this.layers,r.up.set(0,-1,0),r.lookAt(new ne(1,0,0)),this.add(r);const s=new Do(90,1,e,t);s.layers=this.layers,s.up.set(0,-1,0),s.lookAt(new ne(-1,0,0)),this.add(s);const o=new Do(90,1,e,t);o.layers=this.layers,o.up.set(0,0,1),o.lookAt(new ne(0,1,0)),this.add(o);const a=new Do(90,1,e,t);a.layers=this.layers,a.up.set(0,0,-1),a.lookAt(new ne(0,-1,0)),this.add(a);const c=new Do(90,1,e,t);c.layers=this.layers,c.up.set(0,-1,0),c.lookAt(new ne(0,0,1)),this.add(c);const u=new Do(90,1,e,t);u.layers=this.layers,u.up.set(0,-1,0),u.lookAt(new ne(0,0,-1)),this.add(u)}update(e,t){null===this.parent&&this.updateMatrixWorld();const i=this.renderTarget,[r,s,o,a,c,u]=this.children,p=e.xr.enabled,g=e.getRenderTarget();e.xr.enabled=!1;const v=i.texture.generateMipmaps;i.texture.generateMipmaps=!1,e.setRenderTarget(i,0),e.render(t,r),e.setRenderTarget(i,1),e.render(t,s),e.setRenderTarget(i,2),e.render(t,o),e.setRenderTarget(i,3),e.render(t,a),e.setRenderTarget(i,4),e.render(t,c),i.texture.generateMipmaps=v,e.setRenderTarget(i,5),e.render(t,u),e.setRenderTarget(g),e.xr.enabled=p}}class Hy extends io{constructor(e,t,i,r,s,o,a,c,u,p){super(e=void 0!==e?e:[],t=void 0!==t?t:Bg,i,r,s,o,a,c,u,p),this.flipY=!1}get images(){return this.image}set images(e){this.image=e}}Hy.prototype.isCubeTexture=!0;class rI extends Bc{constructor(e,t,i){Number.isInteger(t)&&(console.warn("THREE.WebGLCubeRenderTarget: constructor signature is now WebGLCubeRenderTarget( size, options )"),t=i),super(e,e,t),this.texture=new Hy(void 0,(t=t||{}).mapping,t.wrapS,t.wrapT,t.magFilter,t.minFilter,t.format,t.type,t.anisotropy,t.encoding),this.texture.isRenderTargetTexture=!0,this.texture.generateMipmaps=void 0!==t.generateMipmaps&&t.generateMipmaps,this.texture.minFilter=void 0!==t.minFilter?t.minFilter:no,this.texture._needsFlipEnvMap=!1}fromEquirectangularTexture(e,t){this.texture.type=t.type,this.texture.format=zo,this.texture.encoding=t.encoding,this.texture.generateMipmaps=t.generateMipmaps,this.texture.minFilter=t.minFilter,this.texture.magFilter=t.magFilter;const i_uniforms={tEquirect:{value:null}},i_vertexShader="\n\n\t\t\t\tvarying vec3 vWorldDirection;\n\n\t\t\t\tvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\n\t\t\t\t\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n\n\t\t\t\t}\n\n\t\t\t\tvoid main() {\n\n\t\t\t\t\tvWorldDirection = transformDirection( position, modelMatrix );\n\n\t\t\t\t\t#include \n\t\t\t\t\t#include \n\n\t\t\t\t}\n\t\t\t",i_fragmentShader="\n\n\t\t\t\tuniform sampler2D tEquirect;\n\n\t\t\t\tvarying vec3 vWorldDirection;\n\n\t\t\t\t#include \n\n\t\t\t\tvoid main() {\n\n\t\t\t\t\tvec3 direction = normalize( vWorldDirection );\n\n\t\t\t\t\tvec2 sampleUV = equirectUv( direction );\n\n\t\t\t\t\tgl_FragColor = texture2D( tEquirect, sampleUV );\n\n\t\t\t\t}\n\t\t\t",r=new tu(5,5,5),s=new wh({name:"CubemapFromEquirect",uniforms:a0(i_uniforms),vertexShader:i_vertexShader,fragmentShader:i_fragmentShader,side:Ds,blending:hh});s.uniforms.tEquirect.value=t;const o=new vr(r,s),a=t.minFilter;return t.minFilter===Hg&&(t.minFilter=no),new iI(1,10,this).update(e,o),t.minFilter=a,o.geometry.dispose(),o.material.dispose(),this}clear(e,t,i,r){const s=e.getRenderTarget();for(let o=0;o<6;o++)e.setRenderTarget(this,o),e.clear(t,i,r);e.setRenderTarget(s)}}rI.prototype.isWebGLCubeRenderTarget=!0;const sI=new ne,Ese=new ne,Mse=new js;class nu{constructor(e=new ne(1,0,0),t=0){this.normal=e,this.constant=t}set(e,t){return this.normal.copy(e),this.constant=t,this}setComponents(e,t,i,r){return this.normal.set(e,t,i),this.constant=r,this}setFromNormalAndCoplanarPoint(e,t){return this.normal.copy(e),this.constant=-t.dot(this.normal),this}setFromCoplanarPoints(e,t,i){const r=sI.subVectors(i,t).cross(Ese.subVectors(e,t)).normalize();return this.setFromNormalAndCoplanarPoint(r,e),this}copy(e){return this.normal.copy(e.normal),this.constant=e.constant,this}normalize(){const e=1/this.normal.length();return this.normal.multiplyScalar(e),this.constant*=e,this}negate(){return this.constant*=-1,this.normal.negate(),this}distanceToPoint(e){return this.normal.dot(e)+this.constant}distanceToSphere(e){return this.distanceToPoint(e.center)-e.radius}projectPoint(e,t){return t.copy(this.normal).multiplyScalar(-this.distanceToPoint(e)).add(e)}intersectLine(e,t){const i=e.delta(sI),r=this.normal.dot(i);if(0===r)return 0===this.distanceToPoint(e.start)?t.copy(e.start):null;const s=-(e.start.dot(this.normal)+this.constant)/r;return s<0||s>1?null:t.copy(i).multiplyScalar(s).add(e.start)}intersectsLine(e){const t=this.distanceToPoint(e.start),i=this.distanceToPoint(e.end);return t<0&&i>0||i<0&&t>0}intersectsBox(e){return e.intersectsPlane(this)}intersectsSphere(e){return e.intersectsPlane(this)}coplanarPoint(e){return e.copy(this.normal).multiplyScalar(-this.constant)}applyMatrix4(e,t){const i=t||Mse.getNormalMatrix(e),r=this.coplanarPoint(sI).applyMatrix4(e),s=this.normal.applyMatrix3(i).normalize();return this.constant=-r.dot(s),this}translate(e){return this.constant-=e.dot(this.normal),this}equals(e){return e.normal.equals(this.normal)&&e.constant===this.constant}clone(){return(new this.constructor).copy(this)}}nu.prototype.isPlane=!0;const d0=new op,x2=new ne;class w2{constructor(e=new nu,t=new nu,i=new nu,r=new nu,s=new nu,o=new nu){this.planes=[e,t,i,r,s,o]}set(e,t,i,r,s,o){const a=this.planes;return a[0].copy(e),a[1].copy(t),a[2].copy(i),a[3].copy(r),a[4].copy(s),a[5].copy(o),this}copy(e){const t=this.planes;for(let i=0;i<6;i++)t[i].copy(e.planes[i]);return this}setFromProjectionMatrix(e){const t=this.planes,i=e.elements,r=i[0],s=i[1],o=i[2],a=i[3],c=i[4],u=i[5],p=i[6],g=i[7],v=i[8],y=i[9],x=i[10],T=i[11],N=i[12],k=i[13],A=i[14],H=i[15];return t[0].setComponents(a-r,g-c,T-v,H-N).normalize(),t[1].setComponents(a+r,g+c,T+v,H+N).normalize(),t[2].setComponents(a+s,g+u,T+y,H+k).normalize(),t[3].setComponents(a-s,g-u,T-y,H-k).normalize(),t[4].setComponents(a-o,g-p,T-x,H-A).normalize(),t[5].setComponents(a+o,g+p,T+x,H+A).normalize(),this}intersectsObject(e){const t=e.geometry;return null===t.boundingSphere&&t.computeBoundingSphere(),d0.copy(t.boundingSphere).applyMatrix4(e.matrixWorld),this.intersectsSphere(d0)}intersectsSprite(e){return d0.center.set(0,0,0),d0.radius=.7071067811865476,d0.applyMatrix4(e.matrixWorld),this.intersectsSphere(d0)}intersectsSphere(e){const t=this.planes,i=e.center,r=-e.radius;for(let s=0;s<6;s++)if(t[s].distanceToPoint(i)0?e.max.x:e.min.x,x2.y=r.normal.y>0?e.max.y:e.min.y,x2.z=r.normal.z>0?e.max.z:e.min.z,r.distanceToPoint(x2)<0)return!1}return!0}containsPoint(e){const t=this.planes;for(let i=0;i<6;i++)if(t[i].distanceToPoint(e)<0)return!1;return!0}clone(){return(new this.constructor).copy(this)}}function AB(){let n=null,e=!1,t=null,i=null;function r(s,o){t(s,o),i=n.requestAnimationFrame(r)}return{start:function(){!0!==e&&null!==t&&(i=n.requestAnimationFrame(r),e=!0)},stop:function(){n.cancelAnimationFrame(i),e=!1},setAnimationLoop:function(s){t=s},setContext:function(s){n=s}}}function Cse(n,e){const t=e.isWebGL2,i=new WeakMap;return{get:function o(u){return u.isInterleavedBufferAttribute&&(u=u.data),i.get(u)},remove:function a(u){u.isInterleavedBufferAttribute&&(u=u.data);const p=i.get(u);p&&(n.deleteBuffer(p.buffer),i.delete(u))},update:function c(u,p){if(u.isGLBufferAttribute){const v=i.get(u);return void((!v||v.version 0.0 ) ? v : 0.5 * inversesqrt( max( 1.0 - x * x, 1e-7 ) ) - v;\n\treturn cross( v1, v2 ) * theta_sintheta;\n}\nvec3 LTC_Evaluate( const in vec3 N, const in vec3 V, const in vec3 P, const in mat3 mInv, const in vec3 rectCoords[ 4 ] ) {\n\tvec3 v1 = rectCoords[ 1 ] - rectCoords[ 0 ];\n\tvec3 v2 = rectCoords[ 3 ] - rectCoords[ 0 ];\n\tvec3 lightNormal = cross( v1, v2 );\n\tif( dot( lightNormal, P - rectCoords[ 0 ] ) < 0.0 ) return vec3( 0.0 );\n\tvec3 T1, T2;\n\tT1 = normalize( V - N * dot( V, N ) );\n\tT2 = - cross( N, T1 );\n\tmat3 mat = mInv * transposeMat3( mat3( T1, T2, N ) );\n\tvec3 coords[ 4 ];\n\tcoords[ 0 ] = mat * ( rectCoords[ 0 ] - P );\n\tcoords[ 1 ] = mat * ( rectCoords[ 1 ] - P );\n\tcoords[ 2 ] = mat * ( rectCoords[ 2 ] - P );\n\tcoords[ 3 ] = mat * ( rectCoords[ 3 ] - P );\n\tcoords[ 0 ] = normalize( coords[ 0 ] );\n\tcoords[ 1 ] = normalize( coords[ 1 ] );\n\tcoords[ 2 ] = normalize( coords[ 2 ] );\n\tcoords[ 3 ] = normalize( coords[ 3 ] );\n\tvec3 vectorFormFactor = vec3( 0.0 );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 0 ], coords[ 1 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 1 ], coords[ 2 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 2 ], coords[ 3 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 3 ], coords[ 0 ] );\n\tfloat result = LTC_ClippedSphereFormFactor( vectorFormFactor );\n\treturn vec3( result );\n}\nfloat G_BlinnPhong_Implicit( ) {\n\treturn 0.25;\n}\nfloat D_BlinnPhong( const in float shininess, const in float dotNH ) {\n\treturn RECIPROCAL_PI * ( shininess * 0.5 + 1.0 ) * pow( dotNH, shininess );\n}\nvec3 BRDF_BlinnPhong( const in vec3 lightDir, const in vec3 viewDir, const in vec3 normal, const in vec3 specularColor, const in float shininess ) {\n\tvec3 halfDir = normalize( lightDir + viewDir );\n\tfloat dotNH = saturate( dot( normal, halfDir ) );\n\tfloat dotVH = saturate( dot( viewDir, halfDir ) );\n\tvec3 F = F_Schlick( specularColor, 1.0, dotVH );\n\tfloat G = G_BlinnPhong_Implicit( );\n\tfloat D = D_BlinnPhong( shininess, dotNH );\n\treturn F * ( G * D );\n}\n#if defined( USE_SHEEN )\nfloat D_Charlie( float roughness, float dotNH ) {\n\tfloat alpha = pow2( roughness );\n\tfloat invAlpha = 1.0 / alpha;\n\tfloat cos2h = dotNH * dotNH;\n\tfloat sin2h = max( 1.0 - cos2h, 0.0078125 );\n\treturn ( 2.0 + invAlpha ) * pow( sin2h, invAlpha * 0.5 ) / ( 2.0 * PI );\n}\nfloat V_Neubelt( float dotNV, float dotNL ) {\n\treturn saturate( 1.0 / ( 4.0 * ( dotNL + dotNV - dotNL * dotNV ) ) );\n}\nvec3 BRDF_Sheen( const in vec3 lightDir, const in vec3 viewDir, const in vec3 normal, vec3 sheenColor, const in float sheenRoughness ) {\n\tvec3 halfDir = normalize( lightDir + viewDir );\n\tfloat dotNL = saturate( dot( normal, lightDir ) );\n\tfloat dotNV = saturate( dot( normal, viewDir ) );\n\tfloat dotNH = saturate( dot( normal, halfDir ) );\n\tfloat D = D_Charlie( sheenRoughness, dotNH );\n\tfloat V = V_Neubelt( dotNV, dotNL );\n\treturn sheenColor * ( D * V );\n}\n#endif",bumpmap_pars_fragment:"#ifdef USE_BUMPMAP\n\tuniform sampler2D bumpMap;\n\tuniform float bumpScale;\n\tvec2 dHdxy_fwd() {\n\t\tvec2 dSTdx = dFdx( vUv );\n\t\tvec2 dSTdy = dFdy( vUv );\n\t\tfloat Hll = bumpScale * texture2D( bumpMap, vUv ).x;\n\t\tfloat dBx = bumpScale * texture2D( bumpMap, vUv + dSTdx ).x - Hll;\n\t\tfloat dBy = bumpScale * texture2D( bumpMap, vUv + dSTdy ).x - Hll;\n\t\treturn vec2( dBx, dBy );\n\t}\n\tvec3 perturbNormalArb( vec3 surf_pos, vec3 surf_norm, vec2 dHdxy, float faceDirection ) {\n\t\tvec3 vSigmaX = vec3( dFdx( surf_pos.x ), dFdx( surf_pos.y ), dFdx( surf_pos.z ) );\n\t\tvec3 vSigmaY = vec3( dFdy( surf_pos.x ), dFdy( surf_pos.y ), dFdy( surf_pos.z ) );\n\t\tvec3 vN = surf_norm;\n\t\tvec3 R1 = cross( vSigmaY, vN );\n\t\tvec3 R2 = cross( vN, vSigmaX );\n\t\tfloat fDet = dot( vSigmaX, R1 ) * faceDirection;\n\t\tvec3 vGrad = sign( fDet ) * ( dHdxy.x * R1 + dHdxy.y * R2 );\n\t\treturn normalize( abs( fDet ) * surf_norm - vGrad );\n\t}\n#endif",clipping_planes_fragment:"#if NUM_CLIPPING_PLANES > 0\n\tvec4 plane;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < UNION_CLIPPING_PLANES; i ++ ) {\n\t\tplane = clippingPlanes[ i ];\n\t\tif ( dot( vClipPosition, plane.xyz ) > plane.w ) discard;\n\t}\n\t#pragma unroll_loop_end\n\t#if UNION_CLIPPING_PLANES < NUM_CLIPPING_PLANES\n\t\tbool clipped = true;\n\t\t#pragma unroll_loop_start\n\t\tfor ( int i = UNION_CLIPPING_PLANES; i < NUM_CLIPPING_PLANES; i ++ ) {\n\t\t\tplane = clippingPlanes[ i ];\n\t\t\tclipped = ( dot( vClipPosition, plane.xyz ) > plane.w ) && clipped;\n\t\t}\n\t\t#pragma unroll_loop_end\n\t\tif ( clipped ) discard;\n\t#endif\n#endif",clipping_planes_pars_fragment:"#if NUM_CLIPPING_PLANES > 0\n\tvarying vec3 vClipPosition;\n\tuniform vec4 clippingPlanes[ NUM_CLIPPING_PLANES ];\n#endif",clipping_planes_pars_vertex:"#if NUM_CLIPPING_PLANES > 0\n\tvarying vec3 vClipPosition;\n#endif",clipping_planes_vertex:"#if NUM_CLIPPING_PLANES > 0\n\tvClipPosition = - mvPosition.xyz;\n#endif",color_fragment:"#if defined( USE_COLOR_ALPHA )\n\tdiffuseColor *= vColor;\n#elif defined( USE_COLOR )\n\tdiffuseColor.rgb *= vColor;\n#endif",color_pars_fragment:"#if defined( USE_COLOR_ALPHA )\n\tvarying vec4 vColor;\n#elif defined( USE_COLOR )\n\tvarying vec3 vColor;\n#endif",color_pars_vertex:"#if defined( USE_COLOR_ALPHA )\n\tvarying vec4 vColor;\n#elif defined( USE_COLOR ) || defined( USE_INSTANCING_COLOR )\n\tvarying vec3 vColor;\n#endif",color_vertex:"#if defined( USE_COLOR_ALPHA )\n\tvColor = vec4( 1.0 );\n#elif defined( USE_COLOR ) || defined( USE_INSTANCING_COLOR )\n\tvColor = vec3( 1.0 );\n#endif\n#ifdef USE_COLOR\n\tvColor *= color;\n#endif\n#ifdef USE_INSTANCING_COLOR\n\tvColor.xyz *= instanceColor.xyz;\n#endif",common:"#define PI 3.141592653589793\n#define PI2 6.283185307179586\n#define PI_HALF 1.5707963267948966\n#define RECIPROCAL_PI 0.3183098861837907\n#define RECIPROCAL_PI2 0.15915494309189535\n#define EPSILON 1e-6\n#ifndef saturate\n#define saturate( a ) clamp( a, 0.0, 1.0 )\n#endif\n#define whiteComplement( a ) ( 1.0 - saturate( a ) )\nfloat pow2( const in float x ) { return x*x; }\nfloat pow3( const in float x ) { return x*x*x; }\nfloat pow4( const in float x ) { float x2 = x*x; return x2*x2; }\nfloat max3( const in vec3 v ) { return max( max( v.x, v.y ), v.z ); }\nfloat average( const in vec3 color ) { return dot( color, vec3( 0.3333 ) ); }\nhighp float rand( const in vec2 uv ) {\n\tconst highp float a = 12.9898, b = 78.233, c = 43758.5453;\n\thighp float dt = dot( uv.xy, vec2( a,b ) ), sn = mod( dt, PI );\n\treturn fract( sin( sn ) * c );\n}\n#ifdef HIGH_PRECISION\n\tfloat precisionSafeLength( vec3 v ) { return length( v ); }\n#else\n\tfloat precisionSafeLength( vec3 v ) {\n\t\tfloat maxComponent = max3( abs( v ) );\n\t\treturn length( v / maxComponent ) * maxComponent;\n\t}\n#endif\nstruct IncidentLight {\n\tvec3 color;\n\tvec3 direction;\n\tbool visible;\n};\nstruct ReflectedLight {\n\tvec3 directDiffuse;\n\tvec3 directSpecular;\n\tvec3 indirectDiffuse;\n\tvec3 indirectSpecular;\n};\nstruct GeometricContext {\n\tvec3 position;\n\tvec3 normal;\n\tvec3 viewDir;\n#ifdef USE_CLEARCOAT\n\tvec3 clearcoatNormal;\n#endif\n};\nvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n}\nvec3 inverseTransformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( vec4( dir, 0.0 ) * matrix ).xyz );\n}\nmat3 transposeMat3( const in mat3 m ) {\n\tmat3 tmp;\n\ttmp[ 0 ] = vec3( m[ 0 ].x, m[ 1 ].x, m[ 2 ].x );\n\ttmp[ 1 ] = vec3( m[ 0 ].y, m[ 1 ].y, m[ 2 ].y );\n\ttmp[ 2 ] = vec3( m[ 0 ].z, m[ 1 ].z, m[ 2 ].z );\n\treturn tmp;\n}\nfloat linearToRelativeLuminance( const in vec3 color ) {\n\tvec3 weights = vec3( 0.2126, 0.7152, 0.0722 );\n\treturn dot( weights, color.rgb );\n}\nbool isPerspectiveMatrix( mat4 m ) {\n\treturn m[ 2 ][ 3 ] == - 1.0;\n}\nvec2 equirectUv( in vec3 dir ) {\n\tfloat u = atan( dir.z, dir.x ) * RECIPROCAL_PI2 + 0.5;\n\tfloat v = asin( clamp( dir.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;\n\treturn vec2( u, v );\n}",cube_uv_reflection_fragment:"#ifdef ENVMAP_TYPE_CUBE_UV\n\t#define cubeUV_maxMipLevel 8.0\n\t#define cubeUV_minMipLevel 4.0\n\t#define cubeUV_maxTileSize 256.0\n\t#define cubeUV_minTileSize 16.0\n\tfloat getFace( vec3 direction ) {\n\t\tvec3 absDirection = abs( direction );\n\t\tfloat face = - 1.0;\n\t\tif ( absDirection.x > absDirection.z ) {\n\t\t\tif ( absDirection.x > absDirection.y )\n\t\t\t\tface = direction.x > 0.0 ? 0.0 : 3.0;\n\t\t\telse\n\t\t\t\tface = direction.y > 0.0 ? 1.0 : 4.0;\n\t\t} else {\n\t\t\tif ( absDirection.z > absDirection.y )\n\t\t\t\tface = direction.z > 0.0 ? 2.0 : 5.0;\n\t\t\telse\n\t\t\t\tface = direction.y > 0.0 ? 1.0 : 4.0;\n\t\t}\n\t\treturn face;\n\t}\n\tvec2 getUV( vec3 direction, float face ) {\n\t\tvec2 uv;\n\t\tif ( face == 0.0 ) {\n\t\t\tuv = vec2( direction.z, direction.y ) / abs( direction.x );\n\t\t} else if ( face == 1.0 ) {\n\t\t\tuv = vec2( - direction.x, - direction.z ) / abs( direction.y );\n\t\t} else if ( face == 2.0 ) {\n\t\t\tuv = vec2( - direction.x, direction.y ) / abs( direction.z );\n\t\t} else if ( face == 3.0 ) {\n\t\t\tuv = vec2( - direction.z, direction.y ) / abs( direction.x );\n\t\t} else if ( face == 4.0 ) {\n\t\t\tuv = vec2( - direction.x, direction.z ) / abs( direction.y );\n\t\t} else {\n\t\t\tuv = vec2( direction.x, direction.y ) / abs( direction.z );\n\t\t}\n\t\treturn 0.5 * ( uv + 1.0 );\n\t}\n\tvec3 bilinearCubeUV( sampler2D envMap, vec3 direction, float mipInt ) {\n\t\tfloat face = getFace( direction );\n\t\tfloat filterInt = max( cubeUV_minMipLevel - mipInt, 0.0 );\n\t\tmipInt = max( mipInt, cubeUV_minMipLevel );\n\t\tfloat faceSize = exp2( mipInt );\n\t\tfloat texelSize = 1.0 / ( 3.0 * cubeUV_maxTileSize );\n\t\tvec2 uv = getUV( direction, face ) * ( faceSize - 1.0 );\n\t\tvec2 f = fract( uv );\n\t\tuv += 0.5 - f;\n\t\tif ( face > 2.0 ) {\n\t\t\tuv.y += faceSize;\n\t\t\tface -= 3.0;\n\t\t}\n\t\tuv.x += face * faceSize;\n\t\tif ( mipInt < cubeUV_maxMipLevel ) {\n\t\t\tuv.y += 2.0 * cubeUV_maxTileSize;\n\t\t}\n\t\tuv.y += filterInt * 2.0 * cubeUV_minTileSize;\n\t\tuv.x += 3.0 * max( 0.0, cubeUV_maxTileSize - 2.0 * faceSize );\n\t\tuv *= texelSize;\n\t\tvec3 tl = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tuv.x += texelSize;\n\t\tvec3 tr = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tuv.y += texelSize;\n\t\tvec3 br = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tuv.x -= texelSize;\n\t\tvec3 bl = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tvec3 tm = mix( tl, tr, f.x );\n\t\tvec3 bm = mix( bl, br, f.x );\n\t\treturn mix( tm, bm, f.y );\n\t}\n\t#define r0 1.0\n\t#define v0 0.339\n\t#define m0 - 2.0\n\t#define r1 0.8\n\t#define v1 0.276\n\t#define m1 - 1.0\n\t#define r4 0.4\n\t#define v4 0.046\n\t#define m4 2.0\n\t#define r5 0.305\n\t#define v5 0.016\n\t#define m5 3.0\n\t#define r6 0.21\n\t#define v6 0.0038\n\t#define m6 4.0\n\tfloat roughnessToMip( float roughness ) {\n\t\tfloat mip = 0.0;\n\t\tif ( roughness >= r1 ) {\n\t\t\tmip = ( r0 - roughness ) * ( m1 - m0 ) / ( r0 - r1 ) + m0;\n\t\t} else if ( roughness >= r4 ) {\n\t\t\tmip = ( r1 - roughness ) * ( m4 - m1 ) / ( r1 - r4 ) + m1;\n\t\t} else if ( roughness >= r5 ) {\n\t\t\tmip = ( r4 - roughness ) * ( m5 - m4 ) / ( r4 - r5 ) + m4;\n\t\t} else if ( roughness >= r6 ) {\n\t\t\tmip = ( r5 - roughness ) * ( m6 - m5 ) / ( r5 - r6 ) + m5;\n\t\t} else {\n\t\t\tmip = - 2.0 * log2( 1.16 * roughness );\t\t}\n\t\treturn mip;\n\t}\n\tvec4 textureCubeUV( sampler2D envMap, vec3 sampleDir, float roughness ) {\n\t\tfloat mip = clamp( roughnessToMip( roughness ), m0, cubeUV_maxMipLevel );\n\t\tfloat mipF = fract( mip );\n\t\tfloat mipInt = floor( mip );\n\t\tvec3 color0 = bilinearCubeUV( envMap, sampleDir, mipInt );\n\t\tif ( mipF == 0.0 ) {\n\t\t\treturn vec4( color0, 1.0 );\n\t\t} else {\n\t\t\tvec3 color1 = bilinearCubeUV( envMap, sampleDir, mipInt + 1.0 );\n\t\t\treturn vec4( mix( color0, color1, mipF ), 1.0 );\n\t\t}\n\t}\n#endif",defaultnormal_vertex:"vec3 transformedNormal = objectNormal;\n#ifdef USE_INSTANCING\n\tmat3 m = mat3( instanceMatrix );\n\ttransformedNormal /= vec3( dot( m[ 0 ], m[ 0 ] ), dot( m[ 1 ], m[ 1 ] ), dot( m[ 2 ], m[ 2 ] ) );\n\ttransformedNormal = m * transformedNormal;\n#endif\ntransformedNormal = normalMatrix * transformedNormal;\n#ifdef FLIP_SIDED\n\ttransformedNormal = - transformedNormal;\n#endif\n#ifdef USE_TANGENT\n\tvec3 transformedTangent = ( modelViewMatrix * vec4( objectTangent, 0.0 ) ).xyz;\n\t#ifdef FLIP_SIDED\n\t\ttransformedTangent = - transformedTangent;\n\t#endif\n#endif",displacementmap_pars_vertex:"#ifdef USE_DISPLACEMENTMAP\n\tuniform sampler2D displacementMap;\n\tuniform float displacementScale;\n\tuniform float displacementBias;\n#endif",displacementmap_vertex:"#ifdef USE_DISPLACEMENTMAP\n\ttransformed += normalize( objectNormal ) * ( texture2D( displacementMap, vUv ).x * displacementScale + displacementBias );\n#endif",emissivemap_fragment:"#ifdef USE_EMISSIVEMAP\n\tvec4 emissiveColor = texture2D( emissiveMap, vUv );\n\temissiveColor.rgb = emissiveMapTexelToLinear( emissiveColor ).rgb;\n\ttotalEmissiveRadiance *= emissiveColor.rgb;\n#endif",emissivemap_pars_fragment:"#ifdef USE_EMISSIVEMAP\n\tuniform sampler2D emissiveMap;\n#endif",encodings_fragment:"gl_FragColor = linearToOutputTexel( gl_FragColor );",encodings_pars_fragment:"\nvec4 LinearToLinear( in vec4 value ) {\n\treturn value;\n}\nvec4 GammaToLinear( in vec4 value, in float gammaFactor ) {\n\treturn vec4( pow( value.rgb, vec3( gammaFactor ) ), value.a );\n}\nvec4 LinearToGamma( in vec4 value, in float gammaFactor ) {\n\treturn vec4( pow( value.rgb, vec3( 1.0 / gammaFactor ) ), value.a );\n}\nvec4 sRGBToLinear( in vec4 value ) {\n\treturn vec4( mix( pow( value.rgb * 0.9478672986 + vec3( 0.0521327014 ), vec3( 2.4 ) ), value.rgb * 0.0773993808, vec3( lessThanEqual( value.rgb, vec3( 0.04045 ) ) ) ), value.a );\n}\nvec4 LinearTosRGB( in vec4 value ) {\n\treturn vec4( mix( pow( value.rgb, vec3( 0.41666 ) ) * 1.055 - vec3( 0.055 ), value.rgb * 12.92, vec3( lessThanEqual( value.rgb, vec3( 0.0031308 ) ) ) ), value.a );\n}\nvec4 RGBEToLinear( in vec4 value ) {\n\treturn vec4( value.rgb * exp2( value.a * 255.0 - 128.0 ), 1.0 );\n}\nvec4 LinearToRGBE( in vec4 value ) {\n\tfloat maxComponent = max( max( value.r, value.g ), value.b );\n\tfloat fExp = clamp( ceil( log2( maxComponent ) ), -128.0, 127.0 );\n\treturn vec4( value.rgb / exp2( fExp ), ( fExp + 128.0 ) / 255.0 );\n}\nvec4 RGBMToLinear( in vec4 value, in float maxRange ) {\n\treturn vec4( value.rgb * value.a * maxRange, 1.0 );\n}\nvec4 LinearToRGBM( in vec4 value, in float maxRange ) {\n\tfloat maxRGB = max( value.r, max( value.g, value.b ) );\n\tfloat M = clamp( maxRGB / maxRange, 0.0, 1.0 );\n\tM = ceil( M * 255.0 ) / 255.0;\n\treturn vec4( value.rgb / ( M * maxRange ), M );\n}\nvec4 RGBDToLinear( in vec4 value, in float maxRange ) {\n\treturn vec4( value.rgb * ( ( maxRange / 255.0 ) / value.a ), 1.0 );\n}\nvec4 LinearToRGBD( in vec4 value, in float maxRange ) {\n\tfloat maxRGB = max( value.r, max( value.g, value.b ) );\n\tfloat D = max( maxRange / maxRGB, 1.0 );\n\tD = clamp( floor( D ) / 255.0, 0.0, 1.0 );\n\treturn vec4( value.rgb * ( D * ( 255.0 / maxRange ) ), D );\n}",envmap_fragment:"#ifdef USE_ENVMAP\n\t#ifdef ENV_WORLDPOS\n\t\tvec3 cameraToFrag;\n\t\tif ( isOrthographic ) {\n\t\t\tcameraToFrag = normalize( vec3( - viewMatrix[ 0 ][ 2 ], - viewMatrix[ 1 ][ 2 ], - viewMatrix[ 2 ][ 2 ] ) );\n\t\t} else {\n\t\t\tcameraToFrag = normalize( vWorldPosition - cameraPosition );\n\t\t}\n\t\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvec3 reflectVec = reflect( cameraToFrag, worldNormal );\n\t\t#else\n\t\t\tvec3 reflectVec = refract( cameraToFrag, worldNormal, refractionRatio );\n\t\t#endif\n\t#else\n\t\tvec3 reflectVec = vReflect;\n\t#endif\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tvec4 envColor = textureCube( envMap, vec3( flipEnvMap * reflectVec.x, reflectVec.yz ) );\n\t\tenvColor = envMapTexelToLinear( envColor );\n\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\tvec4 envColor = textureCubeUV( envMap, reflectVec, 0.0 );\n\t#else\n\t\tvec4 envColor = vec4( 0.0 );\n\t#endif\n\t#ifdef ENVMAP_BLENDING_MULTIPLY\n\t\toutgoingLight = mix( outgoingLight, outgoingLight * envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_MIX )\n\t\toutgoingLight = mix( outgoingLight, envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_ADD )\n\t\toutgoingLight += envColor.xyz * specularStrength * reflectivity;\n\t#endif\n#endif",envmap_common_pars_fragment:"#ifdef USE_ENVMAP\n\tuniform float envMapIntensity;\n\tuniform float flipEnvMap;\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tuniform samplerCube envMap;\n\t#else\n\t\tuniform sampler2D envMap;\n\t#endif\n\t\n#endif",envmap_pars_fragment:"#ifdef USE_ENVMAP\n\tuniform float reflectivity;\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\t#define ENV_WORLDPOS\n\t#endif\n\t#ifdef ENV_WORLDPOS\n\t\tvarying vec3 vWorldPosition;\n\t\tuniform float refractionRatio;\n\t#else\n\t\tvarying vec3 vReflect;\n\t#endif\n#endif",envmap_pars_vertex:"#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) ||defined( PHONG )\n\t\t#define ENV_WORLDPOS\n\t#endif\n\t#ifdef ENV_WORLDPOS\n\t\t\n\t\tvarying vec3 vWorldPosition;\n\t#else\n\t\tvarying vec3 vReflect;\n\t\tuniform float refractionRatio;\n\t#endif\n#endif",envmap_physical_pars_fragment:"#if defined( USE_ENVMAP )\n\t#ifdef ENVMAP_MODE_REFRACTION\n\t\tuniform float refractionRatio;\n\t#endif\n\tvec3 getIBLIrradiance( const in vec3 normal ) {\n\t\t#if defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\n\t\t\tvec4 envMapColor = textureCubeUV( envMap, worldNormal, 1.0 );\n\t\t\treturn PI * envMapColor.rgb * envMapIntensity;\n\t\t#else\n\t\t\treturn vec3( 0.0 );\n\t\t#endif\n\t}\n\tvec3 getIBLRadiance( const in vec3 viewDir, const in vec3 normal, const in float roughness ) {\n\t\t#if defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec3 reflectVec;\n\t\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\t\treflectVec = reflect( - viewDir, normal );\n\t\t\t\treflectVec = normalize( mix( reflectVec, normal, roughness * roughness) );\n\t\t\t#else\n\t\t\t\treflectVec = refract( - viewDir, normal, refractionRatio );\n\t\t\t#endif\n\t\t\treflectVec = inverseTransformDirection( reflectVec, viewMatrix );\n\t\t\tvec4 envMapColor = textureCubeUV( envMap, reflectVec, roughness );\n\t\t\treturn envMapColor.rgb * envMapIntensity;\n\t\t#else\n\t\t\treturn vec3( 0.0 );\n\t\t#endif\n\t}\n#endif",envmap_vertex:"#ifdef USE_ENVMAP\n\t#ifdef ENV_WORLDPOS\n\t\tvWorldPosition = worldPosition.xyz;\n\t#else\n\t\tvec3 cameraToVertex;\n\t\tif ( isOrthographic ) {\n\t\t\tcameraToVertex = normalize( vec3( - viewMatrix[ 0 ][ 2 ], - viewMatrix[ 1 ][ 2 ], - viewMatrix[ 2 ][ 2 ] ) );\n\t\t} else {\n\t\t\tcameraToVertex = normalize( worldPosition.xyz - cameraPosition );\n\t\t}\n\t\tvec3 worldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvReflect = reflect( cameraToVertex, worldNormal );\n\t\t#else\n\t\t\tvReflect = refract( cameraToVertex, worldNormal, refractionRatio );\n\t\t#endif\n\t#endif\n#endif",fog_vertex:"#ifdef USE_FOG\n\tvFogDepth = - mvPosition.z;\n#endif",fog_pars_vertex:"#ifdef USE_FOG\n\tvarying float vFogDepth;\n#endif",fog_fragment:"#ifdef USE_FOG\n\t#ifdef FOG_EXP2\n\t\tfloat fogFactor = 1.0 - exp( - fogDensity * fogDensity * vFogDepth * vFogDepth );\n\t#else\n\t\tfloat fogFactor = smoothstep( fogNear, fogFar, vFogDepth );\n\t#endif\n\tgl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );\n#endif",fog_pars_fragment:"#ifdef USE_FOG\n\tuniform vec3 fogColor;\n\tvarying float vFogDepth;\n\t#ifdef FOG_EXP2\n\t\tuniform float fogDensity;\n\t#else\n\t\tuniform float fogNear;\n\t\tuniform float fogFar;\n\t#endif\n#endif",gradientmap_pars_fragment:"#ifdef USE_GRADIENTMAP\n\tuniform sampler2D gradientMap;\n#endif\nvec3 getGradientIrradiance( vec3 normal, vec3 lightDirection ) {\n\tfloat dotNL = dot( normal, lightDirection );\n\tvec2 coord = vec2( dotNL * 0.5 + 0.5, 0.0 );\n\t#ifdef USE_GRADIENTMAP\n\t\treturn texture2D( gradientMap, coord ).rgb;\n\t#else\n\t\treturn ( coord.x < 0.7 ) ? vec3( 0.7 ) : vec3( 1.0 );\n\t#endif\n}",lightmap_fragment:"#ifdef USE_LIGHTMAP\n\tvec4 lightMapTexel = texture2D( lightMap, vUv2 );\n\tvec3 lightMapIrradiance = lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tlightMapIrradiance *= PI;\n\t#endif\n\treflectedLight.indirectDiffuse += lightMapIrradiance;\n#endif",lightmap_pars_fragment:"#ifdef USE_LIGHTMAP\n\tuniform sampler2D lightMap;\n\tuniform float lightMapIntensity;\n#endif",lights_lambert_vertex:"vec3 diffuse = vec3( 1.0 );\nGeometricContext geometry;\ngeometry.position = mvPosition.xyz;\ngeometry.normal = normalize( transformedNormal );\ngeometry.viewDir = ( isOrthographic ) ? vec3( 0, 0, 1 ) : normalize( -mvPosition.xyz );\nGeometricContext backGeometry;\nbackGeometry.position = geometry.position;\nbackGeometry.normal = -geometry.normal;\nbackGeometry.viewDir = geometry.viewDir;\nvLightFront = vec3( 0.0 );\nvIndirectFront = vec3( 0.0 );\n#ifdef DOUBLE_SIDED\n\tvLightBack = vec3( 0.0 );\n\tvIndirectBack = vec3( 0.0 );\n#endif\nIncidentLight directLight;\nfloat dotNL;\nvec3 directLightColor_Diffuse;\nvIndirectFront += getAmbientLightIrradiance( ambientLightColor );\nvIndirectFront += getLightProbeIrradiance( lightProbe, geometry.normal );\n#ifdef DOUBLE_SIDED\n\tvIndirectBack += getAmbientLightIrradiance( ambientLightColor );\n\tvIndirectBack += getLightProbeIrradiance( lightProbe, backGeometry.normal );\n#endif\n#if NUM_POINT_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tgetPointLightInfo( pointLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( - dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tgetSpotLightInfo( spotLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( - dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if NUM_DIR_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tgetDirectionalLightInfo( directionalLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( - dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\tvIndirectFront += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry.normal );\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvIndirectBack += getHemisphereLightIrradiance( hemisphereLights[ i ], backGeometry.normal );\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif",lights_pars_begin:"uniform bool receiveShadow;\nuniform vec3 ambientLightColor;\nuniform vec3 lightProbe[ 9 ];\nvec3 shGetIrradianceAt( in vec3 normal, in vec3 shCoefficients[ 9 ] ) {\n\tfloat x = normal.x, y = normal.y, z = normal.z;\n\tvec3 result = shCoefficients[ 0 ] * 0.886227;\n\tresult += shCoefficients[ 1 ] * 2.0 * 0.511664 * y;\n\tresult += shCoefficients[ 2 ] * 2.0 * 0.511664 * z;\n\tresult += shCoefficients[ 3 ] * 2.0 * 0.511664 * x;\n\tresult += shCoefficients[ 4 ] * 2.0 * 0.429043 * x * y;\n\tresult += shCoefficients[ 5 ] * 2.0 * 0.429043 * y * z;\n\tresult += shCoefficients[ 6 ] * ( 0.743125 * z * z - 0.247708 );\n\tresult += shCoefficients[ 7 ] * 2.0 * 0.429043 * x * z;\n\tresult += shCoefficients[ 8 ] * 0.429043 * ( x * x - y * y );\n\treturn result;\n}\nvec3 getLightProbeIrradiance( const in vec3 lightProbe[ 9 ], const in vec3 normal ) {\n\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\n\tvec3 irradiance = shGetIrradianceAt( worldNormal, lightProbe );\n\treturn irradiance;\n}\nvec3 getAmbientLightIrradiance( const in vec3 ambientLightColor ) {\n\tvec3 irradiance = ambientLightColor;\n\treturn irradiance;\n}\nfloat getDistanceAttenuation( const in float lightDistance, const in float cutoffDistance, const in float decayExponent ) {\n\t#if defined ( PHYSICALLY_CORRECT_LIGHTS )\n\t\tfloat distanceFalloff = 1.0 / max( pow( lightDistance, decayExponent ), 0.01 );\n\t\tif ( cutoffDistance > 0.0 ) {\n\t\t\tdistanceFalloff *= pow2( saturate( 1.0 - pow4( lightDistance / cutoffDistance ) ) );\n\t\t}\n\t\treturn distanceFalloff;\n\t#else\n\t\tif ( cutoffDistance > 0.0 && decayExponent > 0.0 ) {\n\t\t\treturn pow( saturate( - lightDistance / cutoffDistance + 1.0 ), decayExponent );\n\t\t}\n\t\treturn 1.0;\n\t#endif\n}\nfloat getSpotAttenuation( const in float coneCosine, const in float penumbraCosine, const in float angleCosine ) {\n\treturn smoothstep( coneCosine, penumbraCosine, angleCosine );\n}\n#if NUM_DIR_LIGHTS > 0\n\tstruct DirectionalLight {\n\t\tvec3 direction;\n\t\tvec3 color;\n\t};\n\tuniform DirectionalLight directionalLights[ NUM_DIR_LIGHTS ];\n\tvoid getDirectionalLightInfo( const in DirectionalLight directionalLight, const in GeometricContext geometry, out IncidentLight light ) {\n\t\tlight.color = directionalLight.color;\n\t\tlight.direction = directionalLight.direction;\n\t\tlight.visible = true;\n\t}\n#endif\n#if NUM_POINT_LIGHTS > 0\n\tstruct PointLight {\n\t\tvec3 position;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t};\n\tuniform PointLight pointLights[ NUM_POINT_LIGHTS ];\n\tvoid getPointLightInfo( const in PointLight pointLight, const in GeometricContext geometry, out IncidentLight light ) {\n\t\tvec3 lVector = pointLight.position - geometry.position;\n\t\tlight.direction = normalize( lVector );\n\t\tfloat lightDistance = length( lVector );\n\t\tlight.color = pointLight.color;\n\t\tlight.color *= getDistanceAttenuation( lightDistance, pointLight.distance, pointLight.decay );\n\t\tlight.visible = ( light.color != vec3( 0.0 ) );\n\t}\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\tstruct SpotLight {\n\t\tvec3 position;\n\t\tvec3 direction;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t\tfloat coneCos;\n\t\tfloat penumbraCos;\n\t};\n\tuniform SpotLight spotLights[ NUM_SPOT_LIGHTS ];\n\tvoid getSpotLightInfo( const in SpotLight spotLight, const in GeometricContext geometry, out IncidentLight light ) {\n\t\tvec3 lVector = spotLight.position - geometry.position;\n\t\tlight.direction = normalize( lVector );\n\t\tfloat angleCos = dot( light.direction, spotLight.direction );\n\t\tfloat spotAttenuation = getSpotAttenuation( spotLight.coneCos, spotLight.penumbraCos, angleCos );\n\t\tif ( spotAttenuation > 0.0 ) {\n\t\t\tfloat lightDistance = length( lVector );\n\t\t\tlight.color = spotLight.color * spotAttenuation;\n\t\t\tlight.color *= getDistanceAttenuation( lightDistance, spotLight.distance, spotLight.decay );\n\t\t\tlight.visible = ( light.color != vec3( 0.0 ) );\n\t\t} else {\n\t\t\tlight.color = vec3( 0.0 );\n\t\t\tlight.visible = false;\n\t\t}\n\t}\n#endif\n#if NUM_RECT_AREA_LIGHTS > 0\n\tstruct RectAreaLight {\n\t\tvec3 color;\n\t\tvec3 position;\n\t\tvec3 halfWidth;\n\t\tvec3 halfHeight;\n\t};\n\tuniform sampler2D ltc_1;\tuniform sampler2D ltc_2;\n\tuniform RectAreaLight rectAreaLights[ NUM_RECT_AREA_LIGHTS ];\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\tstruct HemisphereLight {\n\t\tvec3 direction;\n\t\tvec3 skyColor;\n\t\tvec3 groundColor;\n\t};\n\tuniform HemisphereLight hemisphereLights[ NUM_HEMI_LIGHTS ];\n\tvec3 getHemisphereLightIrradiance( const in HemisphereLight hemiLight, const in vec3 normal ) {\n\t\tfloat dotNL = dot( normal, hemiLight.direction );\n\t\tfloat hemiDiffuseWeight = 0.5 * dotNL + 0.5;\n\t\tvec3 irradiance = mix( hemiLight.groundColor, hemiLight.skyColor, hemiDiffuseWeight );\n\t\treturn irradiance;\n\t}\n#endif",lights_toon_fragment:"ToonMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb;",lights_toon_pars_fragment:"varying vec3 vViewPosition;\nstruct ToonMaterial {\n\tvec3 diffuseColor;\n};\nvoid RE_Direct_Toon( const in IncidentLight directLight, const in GeometricContext geometry, const in ToonMaterial material, inout ReflectedLight reflectedLight ) {\n\tvec3 irradiance = getGradientIrradiance( geometry.normal, directLight.direction ) * directLight.color;\n\treflectedLight.directDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectDiffuse_Toon( const in vec3 irradiance, const in GeometricContext geometry, const in ToonMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n}\n#define RE_Direct\t\t\t\tRE_Direct_Toon\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_Toon\n#define Material_LightProbeLOD( material )\t(0)",lights_phong_fragment:"BlinnPhongMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb;\nmaterial.specularColor = specular;\nmaterial.specularShininess = shininess;\nmaterial.specularStrength = specularStrength;",lights_phong_pars_fragment:"varying vec3 vViewPosition;\nstruct BlinnPhongMaterial {\n\tvec3 diffuseColor;\n\tvec3 specularColor;\n\tfloat specularShininess;\n\tfloat specularStrength;\n};\nvoid RE_Direct_BlinnPhong( const in IncidentLight directLight, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\tvec3 irradiance = dotNL * directLight.color;\n\treflectedLight.directDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n\treflectedLight.directSpecular += irradiance * BRDF_BlinnPhong( directLight.direction, geometry.viewDir, geometry.normal, material.specularColor, material.specularShininess ) * material.specularStrength;\n}\nvoid RE_IndirectDiffuse_BlinnPhong( const in vec3 irradiance, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n}\n#define RE_Direct\t\t\t\tRE_Direct_BlinnPhong\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_BlinnPhong\n#define Material_LightProbeLOD( material )\t(0)",lights_physical_fragment:"PhysicalMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb * ( 1.0 - metalnessFactor );\nvec3 dxy = max( abs( dFdx( geometryNormal ) ), abs( dFdy( geometryNormal ) ) );\nfloat geometryRoughness = max( max( dxy.x, dxy.y ), dxy.z );\nmaterial.roughness = max( roughnessFactor, 0.0525 );material.roughness += geometryRoughness;\nmaterial.roughness = min( material.roughness, 1.0 );\n#ifdef IOR\n\t#ifdef SPECULAR\n\t\tfloat specularIntensityFactor = specularIntensity;\n\t\tvec3 specularColorFactor = specularColor;\n\t\t#ifdef USE_SPECULARINTENSITYMAP\n\t\t\tspecularIntensityFactor *= texture2D( specularIntensityMap, vUv ).a;\n\t\t#endif\n\t\t#ifdef USE_SPECULARCOLORMAP\n\t\t\tspecularColorFactor *= specularColorMapTexelToLinear( texture2D( specularColorMap, vUv ) ).rgb;\n\t\t#endif\n\t\tmaterial.specularF90 = mix( specularIntensityFactor, 1.0, metalnessFactor );\n\t#else\n\t\tfloat specularIntensityFactor = 1.0;\n\t\tvec3 specularColorFactor = vec3( 1.0 );\n\t\tmaterial.specularF90 = 1.0;\n\t#endif\n\tmaterial.specularColor = mix( min( pow2( ( ior - 1.0 ) / ( ior + 1.0 ) ) * specularColorFactor, vec3( 1.0 ) ) * specularIntensityFactor, diffuseColor.rgb, metalnessFactor );\n#else\n\tmaterial.specularColor = mix( vec3( 0.04 ), diffuseColor.rgb, metalnessFactor );\n\tmaterial.specularF90 = 1.0;\n#endif\n#ifdef USE_CLEARCOAT\n\tmaterial.clearcoat = clearcoat;\n\tmaterial.clearcoatRoughness = clearcoatRoughness;\n\tmaterial.clearcoatF0 = vec3( 0.04 );\n\tmaterial.clearcoatF90 = 1.0;\n\t#ifdef USE_CLEARCOATMAP\n\t\tmaterial.clearcoat *= texture2D( clearcoatMap, vUv ).x;\n\t#endif\n\t#ifdef USE_CLEARCOAT_ROUGHNESSMAP\n\t\tmaterial.clearcoatRoughness *= texture2D( clearcoatRoughnessMap, vUv ).y;\n\t#endif\n\tmaterial.clearcoat = saturate( material.clearcoat );\tmaterial.clearcoatRoughness = max( material.clearcoatRoughness, 0.0525 );\n\tmaterial.clearcoatRoughness += geometryRoughness;\n\tmaterial.clearcoatRoughness = min( material.clearcoatRoughness, 1.0 );\n#endif\n#ifdef USE_SHEEN\n\tmaterial.sheenColor = sheenColor;\n\t#ifdef USE_SHEENCOLORMAP\n\t\tmaterial.sheenColor *= sheenColorMapTexelToLinear( texture2D( sheenColorMap, vUv ) ).rgb;\n\t#endif\n\tmaterial.sheenRoughness = clamp( sheenRoughness, 0.07, 1.0 );\n\t#ifdef USE_SHEENROUGHNESSMAP\n\t\tmaterial.sheenRoughness *= texture2D( sheenRoughnessMap, vUv ).a;\n\t#endif\n#endif",lights_physical_pars_fragment:"struct PhysicalMaterial {\n\tvec3 diffuseColor;\n\tfloat roughness;\n\tvec3 specularColor;\n\tfloat specularF90;\n\t#ifdef USE_CLEARCOAT\n\t\tfloat clearcoat;\n\t\tfloat clearcoatRoughness;\n\t\tvec3 clearcoatF0;\n\t\tfloat clearcoatF90;\n\t#endif\n\t#ifdef USE_SHEEN\n\t\tvec3 sheenColor;\n\t\tfloat sheenRoughness;\n\t#endif\n};\nvec3 clearcoatSpecular = vec3( 0.0 );\nvec2 DFGApprox( const in vec3 normal, const in vec3 viewDir, const in float roughness ) {\n\tfloat dotNV = saturate( dot( normal, viewDir ) );\n\tconst vec4 c0 = vec4( - 1, - 0.0275, - 0.572, 0.022 );\n\tconst vec4 c1 = vec4( 1, 0.0425, 1.04, - 0.04 );\n\tvec4 r = roughness * c0 + c1;\n\tfloat a004 = min( r.x * r.x, exp2( - 9.28 * dotNV ) ) * r.x + r.y;\n\tvec2 fab = vec2( - 1.04, 1.04 ) * a004 + r.zw;\n\treturn fab;\n}\nvec3 EnvironmentBRDF( const in vec3 normal, const in vec3 viewDir, const in vec3 specularColor, const in float specularF90, const in float roughness ) {\n\tvec2 fab = DFGApprox( normal, viewDir, roughness );\n\treturn specularColor * fab.x + specularF90 * fab.y;\n}\nvoid computeMultiscattering( const in vec3 normal, const in vec3 viewDir, const in vec3 specularColor, const in float specularF90, const in float roughness, inout vec3 singleScatter, inout vec3 multiScatter ) {\n\tvec2 fab = DFGApprox( normal, viewDir, roughness );\n\tvec3 FssEss = specularColor * fab.x + specularF90 * fab.y;\n\tfloat Ess = fab.x + fab.y;\n\tfloat Ems = 1.0 - Ess;\n\tvec3 Favg = specularColor + ( 1.0 - specularColor ) * 0.047619;\tvec3 Fms = FssEss * Favg / ( 1.0 - Ems * Favg );\n\tsingleScatter += FssEss;\n\tmultiScatter += Fms * Ems;\n}\n#if NUM_RECT_AREA_LIGHTS > 0\n\tvoid RE_Direct_RectArea_Physical( const in RectAreaLight rectAreaLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\t\tvec3 normal = geometry.normal;\n\t\tvec3 viewDir = geometry.viewDir;\n\t\tvec3 position = geometry.position;\n\t\tvec3 lightPos = rectAreaLight.position;\n\t\tvec3 halfWidth = rectAreaLight.halfWidth;\n\t\tvec3 halfHeight = rectAreaLight.halfHeight;\n\t\tvec3 lightColor = rectAreaLight.color;\n\t\tfloat roughness = material.roughness;\n\t\tvec3 rectCoords[ 4 ];\n\t\trectCoords[ 0 ] = lightPos + halfWidth - halfHeight;\t\trectCoords[ 1 ] = lightPos - halfWidth - halfHeight;\n\t\trectCoords[ 2 ] = lightPos - halfWidth + halfHeight;\n\t\trectCoords[ 3 ] = lightPos + halfWidth + halfHeight;\n\t\tvec2 uv = LTC_Uv( normal, viewDir, roughness );\n\t\tvec4 t1 = texture2D( ltc_1, uv );\n\t\tvec4 t2 = texture2D( ltc_2, uv );\n\t\tmat3 mInv = mat3(\n\t\t\tvec3( t1.x, 0, t1.y ),\n\t\t\tvec3( 0, 1, 0 ),\n\t\t\tvec3( t1.z, 0, t1.w )\n\t\t);\n\t\tvec3 fresnel = ( material.specularColor * t2.x + ( vec3( 1.0 ) - material.specularColor ) * t2.y );\n\t\treflectedLight.directSpecular += lightColor * fresnel * LTC_Evaluate( normal, viewDir, position, mInv, rectCoords );\n\t\treflectedLight.directDiffuse += lightColor * material.diffuseColor * LTC_Evaluate( normal, viewDir, position, mat3( 1.0 ), rectCoords );\n\t}\n#endif\nvoid RE_Direct_Physical( const in IncidentLight directLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\tvec3 irradiance = dotNL * directLight.color;\n\t#ifdef USE_CLEARCOAT\n\t\tfloat dotNLcc = saturate( dot( geometry.clearcoatNormal, directLight.direction ) );\n\t\tvec3 ccIrradiance = dotNLcc * directLight.color;\n\t\tclearcoatSpecular += ccIrradiance * BRDF_GGX( directLight.direction, geometry.viewDir, geometry.clearcoatNormal, material.clearcoatF0, material.clearcoatF90, material.clearcoatRoughness );\n\t#endif\n\t#ifdef USE_SHEEN\n\t\treflectedLight.directSpecular += irradiance * BRDF_Sheen( directLight.direction, geometry.viewDir, geometry.normal, material.sheenColor, material.sheenRoughness );\n\t#endif\n\treflectedLight.directSpecular += irradiance * BRDF_GGX( directLight.direction, geometry.viewDir, geometry.normal, material.specularColor, material.specularF90, material.roughness );\n\treflectedLight.directDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectDiffuse_Physical( const in vec3 irradiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectSpecular_Physical( const in vec3 radiance, const in vec3 irradiance, const in vec3 clearcoatRadiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight) {\n\t#ifdef USE_CLEARCOAT\n\t\tclearcoatSpecular += clearcoatRadiance * EnvironmentBRDF( geometry.clearcoatNormal, geometry.viewDir, material.clearcoatF0, material.clearcoatF90, material.clearcoatRoughness );\n\t#endif\n\tvec3 singleScattering = vec3( 0.0 );\n\tvec3 multiScattering = vec3( 0.0 );\n\tvec3 cosineWeightedIrradiance = irradiance * RECIPROCAL_PI;\n\tcomputeMultiscattering( geometry.normal, geometry.viewDir, material.specularColor, material.specularF90, material.roughness, singleScattering, multiScattering );\n\tvec3 diffuse = material.diffuseColor * ( 1.0 - ( singleScattering + multiScattering ) );\n\treflectedLight.indirectSpecular += radiance * singleScattering;\n\treflectedLight.indirectSpecular += multiScattering * cosineWeightedIrradiance;\n\treflectedLight.indirectDiffuse += diffuse * cosineWeightedIrradiance;\n}\n#define RE_Direct\t\t\t\tRE_Direct_Physical\n#define RE_Direct_RectArea\t\tRE_Direct_RectArea_Physical\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_Physical\n#define RE_IndirectSpecular\t\tRE_IndirectSpecular_Physical\nfloat computeSpecularOcclusion( const in float dotNV, const in float ambientOcclusion, const in float roughness ) {\n\treturn saturate( pow( dotNV + ambientOcclusion, exp2( - 16.0 * roughness - 1.0 ) ) - 1.0 + ambientOcclusion );\n}",lights_fragment_begin:"\nGeometricContext geometry;\ngeometry.position = - vViewPosition;\ngeometry.normal = normal;\ngeometry.viewDir = ( isOrthographic ) ? vec3( 0, 0, 1 ) : normalize( vViewPosition );\n#ifdef USE_CLEARCOAT\n\tgeometry.clearcoatNormal = clearcoatNormal;\n#endif\nIncidentLight directLight;\n#if ( NUM_POINT_LIGHTS > 0 ) && defined( RE_Direct )\n\tPointLight pointLight;\n\t#if defined( USE_SHADOWMAP ) && NUM_POINT_LIGHT_SHADOWS > 0\n\tPointLightShadow pointLightShadow;\n\t#endif\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tpointLight = pointLights[ i ];\n\t\tgetPointLightInfo( pointLight, geometry, directLight );\n\t\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_POINT_LIGHT_SHADOWS )\n\t\tpointLightShadow = pointLightShadows[ i ];\n\t\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getPointShadow( pointShadowMap[ i ], pointLightShadow.shadowMapSize, pointLightShadow.shadowBias, pointLightShadow.shadowRadius, vPointShadowCoord[ i ], pointLightShadow.shadowCameraNear, pointLightShadow.shadowCameraFar ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if ( NUM_SPOT_LIGHTS > 0 ) && defined( RE_Direct )\n\tSpotLight spotLight;\n\t#if defined( USE_SHADOWMAP ) && NUM_SPOT_LIGHT_SHADOWS > 0\n\tSpotLightShadow spotLightShadow;\n\t#endif\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tspotLight = spotLights[ i ];\n\t\tgetSpotLightInfo( spotLight, geometry, directLight );\n\t\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_SPOT_LIGHT_SHADOWS )\n\t\tspotLightShadow = spotLightShadows[ i ];\n\t\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getShadow( spotShadowMap[ i ], spotLightShadow.shadowMapSize, spotLightShadow.shadowBias, spotLightShadow.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if ( NUM_DIR_LIGHTS > 0 ) && defined( RE_Direct )\n\tDirectionalLight directionalLight;\n\t#if defined( USE_SHADOWMAP ) && NUM_DIR_LIGHT_SHADOWS > 0\n\tDirectionalLightShadow directionalLightShadow;\n\t#endif\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tdirectionalLight = directionalLights[ i ];\n\t\tgetDirectionalLightInfo( directionalLight, geometry, directLight );\n\t\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_DIR_LIGHT_SHADOWS )\n\t\tdirectionalLightShadow = directionalLightShadows[ i ];\n\t\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getShadow( directionalShadowMap[ i ], directionalLightShadow.shadowMapSize, directionalLightShadow.shadowBias, directionalLightShadow.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if ( NUM_RECT_AREA_LIGHTS > 0 ) && defined( RE_Direct_RectArea )\n\tRectAreaLight rectAreaLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_RECT_AREA_LIGHTS; i ++ ) {\n\t\trectAreaLight = rectAreaLights[ i ];\n\t\tRE_Direct_RectArea( rectAreaLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if defined( RE_IndirectDiffuse )\n\tvec3 iblIrradiance = vec3( 0.0 );\n\tvec3 irradiance = getAmbientLightIrradiance( ambientLightColor );\n\tirradiance += getLightProbeIrradiance( lightProbe, geometry.normal );\n\t#if ( NUM_HEMI_LIGHTS > 0 )\n\t\t#pragma unroll_loop_start\n\t\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\t\tirradiance += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry.normal );\n\t\t}\n\t\t#pragma unroll_loop_end\n\t#endif\n#endif\n#if defined( RE_IndirectSpecular )\n\tvec3 radiance = vec3( 0.0 );\n\tvec3 clearcoatRadiance = vec3( 0.0 );\n#endif",lights_fragment_maps:"#if defined( RE_IndirectDiffuse )\n\t#ifdef USE_LIGHTMAP\n\t\tvec4 lightMapTexel = texture2D( lightMap, vUv2 );\n\t\tvec3 lightMapIrradiance = lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tlightMapIrradiance *= PI;\n\t\t#endif\n\t\tirradiance += lightMapIrradiance;\n\t#endif\n\t#if defined( USE_ENVMAP ) && defined( STANDARD ) && defined( ENVMAP_TYPE_CUBE_UV )\n\t\tiblIrradiance += getIBLIrradiance( geometry.normal );\n\t#endif\n#endif\n#if defined( USE_ENVMAP ) && defined( RE_IndirectSpecular )\n\tradiance += getIBLRadiance( geometry.viewDir, geometry.normal, material.roughness );\n\t#ifdef USE_CLEARCOAT\n\t\tclearcoatRadiance += getIBLRadiance( geometry.viewDir, geometry.clearcoatNormal, material.clearcoatRoughness );\n\t#endif\n#endif",lights_fragment_end:"#if defined( RE_IndirectDiffuse )\n\tRE_IndirectDiffuse( irradiance, geometry, material, reflectedLight );\n#endif\n#if defined( RE_IndirectSpecular )\n\tRE_IndirectSpecular( radiance, iblIrradiance, clearcoatRadiance, geometry, material, reflectedLight );\n#endif",logdepthbuf_fragment:"#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )\n\tgl_FragDepthEXT = vIsPerspective == 0.0 ? gl_FragCoord.z : log2( vFragDepth ) * logDepthBufFC * 0.5;\n#endif",logdepthbuf_pars_fragment:"#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )\n\tuniform float logDepthBufFC;\n\tvarying float vFragDepth;\n\tvarying float vIsPerspective;\n#endif",logdepthbuf_pars_vertex:"#ifdef USE_LOGDEPTHBUF\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvarying float vFragDepth;\n\t\tvarying float vIsPerspective;\n\t#else\n\t\tuniform float logDepthBufFC;\n\t#endif\n#endif",logdepthbuf_vertex:"#ifdef USE_LOGDEPTHBUF\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvFragDepth = 1.0 + gl_Position.w;\n\t\tvIsPerspective = float( isPerspectiveMatrix( projectionMatrix ) );\n\t#else\n\t\tif ( isPerspectiveMatrix( projectionMatrix ) ) {\n\t\t\tgl_Position.z = log2( max( EPSILON, gl_Position.w + 1.0 ) ) * logDepthBufFC - 1.0;\n\t\t\tgl_Position.z *= gl_Position.w;\n\t\t}\n\t#endif\n#endif",map_fragment:"#ifdef USE_MAP\n\tvec4 texelColor = texture2D( map, vUv );\n\ttexelColor = mapTexelToLinear( texelColor );\n\tdiffuseColor *= texelColor;\n#endif",map_pars_fragment:"#ifdef USE_MAP\n\tuniform sampler2D map;\n#endif",map_particle_fragment:"#if defined( USE_MAP ) || defined( USE_ALPHAMAP )\n\tvec2 uv = ( uvTransform * vec3( gl_PointCoord.x, 1.0 - gl_PointCoord.y, 1 ) ).xy;\n#endif\n#ifdef USE_MAP\n\tvec4 mapTexel = texture2D( map, uv );\n\tdiffuseColor *= mapTexelToLinear( mapTexel );\n#endif\n#ifdef USE_ALPHAMAP\n\tdiffuseColor.a *= texture2D( alphaMap, uv ).g;\n#endif",map_particle_pars_fragment:"#if defined( USE_MAP ) || defined( USE_ALPHAMAP )\n\tuniform mat3 uvTransform;\n#endif\n#ifdef USE_MAP\n\tuniform sampler2D map;\n#endif\n#ifdef USE_ALPHAMAP\n\tuniform sampler2D alphaMap;\n#endif",metalnessmap_fragment:"float metalnessFactor = metalness;\n#ifdef USE_METALNESSMAP\n\tvec4 texelMetalness = texture2D( metalnessMap, vUv );\n\tmetalnessFactor *= texelMetalness.b;\n#endif",metalnessmap_pars_fragment:"#ifdef USE_METALNESSMAP\n\tuniform sampler2D metalnessMap;\n#endif",morphnormal_vertex:"#ifdef USE_MORPHNORMALS\n\tobjectNormal *= morphTargetBaseInfluence;\n\t#ifdef MORPHTARGETS_TEXTURE\n\t\tfor ( int i = 0; i < MORPHTARGETS_COUNT; i ++ ) {\n\t\t\tif ( morphTargetInfluences[ i ] > 0.0 ) objectNormal += getMorph( gl_VertexID, i, 1, 2 ) * morphTargetInfluences[ i ];\n\t\t}\n\t#else\n\t\tobjectNormal += morphNormal0 * morphTargetInfluences[ 0 ];\n\t\tobjectNormal += morphNormal1 * morphTargetInfluences[ 1 ];\n\t\tobjectNormal += morphNormal2 * morphTargetInfluences[ 2 ];\n\t\tobjectNormal += morphNormal3 * morphTargetInfluences[ 3 ];\n\t#endif\n#endif",morphtarget_pars_vertex:"#ifdef USE_MORPHTARGETS\n\tuniform float morphTargetBaseInfluence;\n\t#ifdef MORPHTARGETS_TEXTURE\n\t\tuniform float morphTargetInfluences[ MORPHTARGETS_COUNT ];\n\t\tuniform sampler2DArray morphTargetsTexture;\n\t\tuniform vec2 morphTargetsTextureSize;\n\t\tvec3 getMorph( const in int vertexIndex, const in int morphTargetIndex, const in int offset, const in int stride ) {\n\t\t\tfloat texelIndex = float( vertexIndex * stride + offset );\n\t\t\tfloat y = floor( texelIndex / morphTargetsTextureSize.x );\n\t\t\tfloat x = texelIndex - y * morphTargetsTextureSize.x;\n\t\t\tvec3 morphUV = vec3( ( x + 0.5 ) / morphTargetsTextureSize.x, y / morphTargetsTextureSize.y, morphTargetIndex );\n\t\t\treturn texture( morphTargetsTexture, morphUV ).xyz;\n\t\t}\n\t#else\n\t\t#ifndef USE_MORPHNORMALS\n\t\t\tuniform float morphTargetInfluences[ 8 ];\n\t\t#else\n\t\t\tuniform float morphTargetInfluences[ 4 ];\n\t\t#endif\n\t#endif\n#endif",morphtarget_vertex:"#ifdef USE_MORPHTARGETS\n\ttransformed *= morphTargetBaseInfluence;\n\t#ifdef MORPHTARGETS_TEXTURE\n\t\tfor ( int i = 0; i < MORPHTARGETS_COUNT; i ++ ) {\n\t\t\t#ifndef USE_MORPHNORMALS\n\t\t\t\tif ( morphTargetInfluences[ i ] > 0.0 ) transformed += getMorph( gl_VertexID, i, 0, 1 ) * morphTargetInfluences[ i ];\n\t\t\t#else\n\t\t\t\tif ( morphTargetInfluences[ i ] > 0.0 ) transformed += getMorph( gl_VertexID, i, 0, 2 ) * morphTargetInfluences[ i ];\n\t\t\t#endif\n\t\t}\n\t#else\n\t\ttransformed += morphTarget0 * morphTargetInfluences[ 0 ];\n\t\ttransformed += morphTarget1 * morphTargetInfluences[ 1 ];\n\t\ttransformed += morphTarget2 * morphTargetInfluences[ 2 ];\n\t\ttransformed += morphTarget3 * morphTargetInfluences[ 3 ];\n\t\t#ifndef USE_MORPHNORMALS\n\t\t\ttransformed += morphTarget4 * morphTargetInfluences[ 4 ];\n\t\t\ttransformed += morphTarget5 * morphTargetInfluences[ 5 ];\n\t\t\ttransformed += morphTarget6 * morphTargetInfluences[ 6 ];\n\t\t\ttransformed += morphTarget7 * morphTargetInfluences[ 7 ];\n\t\t#endif\n\t#endif\n#endif",normal_fragment_begin:"float faceDirection = gl_FrontFacing ? 1.0 : - 1.0;\n#ifdef FLAT_SHADED\n\tvec3 fdx = vec3( dFdx( vViewPosition.x ), dFdx( vViewPosition.y ), dFdx( vViewPosition.z ) );\n\tvec3 fdy = vec3( dFdy( vViewPosition.x ), dFdy( vViewPosition.y ), dFdy( vViewPosition.z ) );\n\tvec3 normal = normalize( cross( fdx, fdy ) );\n#else\n\tvec3 normal = normalize( vNormal );\n\t#ifdef DOUBLE_SIDED\n\t\tnormal = normal * faceDirection;\n\t#endif\n\t#ifdef USE_TANGENT\n\t\tvec3 tangent = normalize( vTangent );\n\t\tvec3 bitangent = normalize( vBitangent );\n\t\t#ifdef DOUBLE_SIDED\n\t\t\ttangent = tangent * faceDirection;\n\t\t\tbitangent = bitangent * faceDirection;\n\t\t#endif\n\t\t#if defined( TANGENTSPACE_NORMALMAP ) || defined( USE_CLEARCOAT_NORMALMAP )\n\t\t\tmat3 vTBN = mat3( tangent, bitangent, normal );\n\t\t#endif\n\t#endif\n#endif\nvec3 geometryNormal = normal;",normal_fragment_maps:"#ifdef OBJECTSPACE_NORMALMAP\n\tnormal = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\n\t#ifdef FLIP_SIDED\n\t\tnormal = - normal;\n\t#endif\n\t#ifdef DOUBLE_SIDED\n\t\tnormal = normal * faceDirection;\n\t#endif\n\tnormal = normalize( normalMatrix * normal );\n#elif defined( TANGENTSPACE_NORMALMAP )\n\tvec3 mapN = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\n\tmapN.xy *= normalScale;\n\t#ifdef USE_TANGENT\n\t\tnormal = normalize( vTBN * mapN );\n\t#else\n\t\tnormal = perturbNormal2Arb( - vViewPosition, normal, mapN, faceDirection );\n\t#endif\n#elif defined( USE_BUMPMAP )\n\tnormal = perturbNormalArb( - vViewPosition, normal, dHdxy_fwd(), faceDirection );\n#endif",normal_pars_fragment:"#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n\t#ifdef USE_TANGENT\n\t\tvarying vec3 vTangent;\n\t\tvarying vec3 vBitangent;\n\t#endif\n#endif",normal_pars_vertex:"#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n\t#ifdef USE_TANGENT\n\t\tvarying vec3 vTangent;\n\t\tvarying vec3 vBitangent;\n\t#endif\n#endif",normal_vertex:"#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n\t#ifdef USE_TANGENT\n\t\tvTangent = normalize( transformedTangent );\n\t\tvBitangent = normalize( cross( vNormal, vTangent ) * tangent.w );\n\t#endif\n#endif",normalmap_pars_fragment:"#ifdef USE_NORMALMAP\n\tuniform sampler2D normalMap;\n\tuniform vec2 normalScale;\n#endif\n#ifdef OBJECTSPACE_NORMALMAP\n\tuniform mat3 normalMatrix;\n#endif\n#if ! defined ( USE_TANGENT ) && ( defined ( TANGENTSPACE_NORMALMAP ) || defined ( USE_CLEARCOAT_NORMALMAP ) )\n\tvec3 perturbNormal2Arb( vec3 eye_pos, vec3 surf_norm, vec3 mapN, float faceDirection ) {\n\t\tvec3 q0 = vec3( dFdx( eye_pos.x ), dFdx( eye_pos.y ), dFdx( eye_pos.z ) );\n\t\tvec3 q1 = vec3( dFdy( eye_pos.x ), dFdy( eye_pos.y ), dFdy( eye_pos.z ) );\n\t\tvec2 st0 = dFdx( vUv.st );\n\t\tvec2 st1 = dFdy( vUv.st );\n\t\tvec3 N = surf_norm;\n\t\tvec3 q1perp = cross( q1, N );\n\t\tvec3 q0perp = cross( N, q0 );\n\t\tvec3 T = q1perp * st0.x + q0perp * st1.x;\n\t\tvec3 B = q1perp * st0.y + q0perp * st1.y;\n\t\tfloat det = max( dot( T, T ), dot( B, B ) );\n\t\tfloat scale = ( det == 0.0 ) ? 0.0 : faceDirection * inversesqrt( det );\n\t\treturn normalize( T * ( mapN.x * scale ) + B * ( mapN.y * scale ) + N * mapN.z );\n\t}\n#endif",clearcoat_normal_fragment_begin:"#ifdef USE_CLEARCOAT\n\tvec3 clearcoatNormal = geometryNormal;\n#endif",clearcoat_normal_fragment_maps:"#ifdef USE_CLEARCOAT_NORMALMAP\n\tvec3 clearcoatMapN = texture2D( clearcoatNormalMap, vUv ).xyz * 2.0 - 1.0;\n\tclearcoatMapN.xy *= clearcoatNormalScale;\n\t#ifdef USE_TANGENT\n\t\tclearcoatNormal = normalize( vTBN * clearcoatMapN );\n\t#else\n\t\tclearcoatNormal = perturbNormal2Arb( - vViewPosition, clearcoatNormal, clearcoatMapN, faceDirection );\n\t#endif\n#endif",clearcoat_pars_fragment:"#ifdef USE_CLEARCOATMAP\n\tuniform sampler2D clearcoatMap;\n#endif\n#ifdef USE_CLEARCOAT_ROUGHNESSMAP\n\tuniform sampler2D clearcoatRoughnessMap;\n#endif\n#ifdef USE_CLEARCOAT_NORMALMAP\n\tuniform sampler2D clearcoatNormalMap;\n\tuniform vec2 clearcoatNormalScale;\n#endif",output_fragment:"#ifdef OPAQUE\ndiffuseColor.a = 1.0;\n#endif\n#ifdef USE_TRANSMISSION\ndiffuseColor.a *= transmissionAlpha + 0.1;\n#endif\ngl_FragColor = vec4( outgoingLight, diffuseColor.a );",packing:"vec3 packNormalToRGB( const in vec3 normal ) {\n\treturn normalize( normal ) * 0.5 + 0.5;\n}\nvec3 unpackRGBToNormal( const in vec3 rgb ) {\n\treturn 2.0 * rgb.xyz - 1.0;\n}\nconst float PackUpscale = 256. / 255.;const float UnpackDownscale = 255. / 256.;\nconst vec3 PackFactors = vec3( 256. * 256. * 256., 256. * 256., 256. );\nconst vec4 UnpackFactors = UnpackDownscale / vec4( PackFactors, 1. );\nconst float ShiftRight8 = 1. / 256.;\nvec4 packDepthToRGBA( const in float v ) {\n\tvec4 r = vec4( fract( v * PackFactors ), v );\n\tr.yzw -= r.xyz * ShiftRight8;\treturn r * PackUpscale;\n}\nfloat unpackRGBAToDepth( const in vec4 v ) {\n\treturn dot( v, UnpackFactors );\n}\nvec4 pack2HalfToRGBA( vec2 v ) {\n\tvec4 r = vec4( v.x, fract( v.x * 255.0 ), v.y, fract( v.y * 255.0 ) );\n\treturn vec4( r.x - r.y / 255.0, r.y, r.z - r.w / 255.0, r.w );\n}\nvec2 unpackRGBATo2Half( vec4 v ) {\n\treturn vec2( v.x + ( v.y / 255.0 ), v.z + ( v.w / 255.0 ) );\n}\nfloat viewZToOrthographicDepth( const in float viewZ, const in float near, const in float far ) {\n\treturn ( viewZ + near ) / ( near - far );\n}\nfloat orthographicDepthToViewZ( const in float linearClipZ, const in float near, const in float far ) {\n\treturn linearClipZ * ( near - far ) - near;\n}\nfloat viewZToPerspectiveDepth( const in float viewZ, const in float near, const in float far ) {\n\treturn ( ( near + viewZ ) * far ) / ( ( far - near ) * viewZ );\n}\nfloat perspectiveDepthToViewZ( const in float invClipZ, const in float near, const in float far ) {\n\treturn ( near * far ) / ( ( far - near ) * invClipZ - far );\n}",premultiplied_alpha_fragment:"#ifdef PREMULTIPLIED_ALPHA\n\tgl_FragColor.rgb *= gl_FragColor.a;\n#endif",project_vertex:"vec4 mvPosition = vec4( transformed, 1.0 );\n#ifdef USE_INSTANCING\n\tmvPosition = instanceMatrix * mvPosition;\n#endif\nmvPosition = modelViewMatrix * mvPosition;\ngl_Position = projectionMatrix * mvPosition;",dithering_fragment:"#ifdef DITHERING\n\tgl_FragColor.rgb = dithering( gl_FragColor.rgb );\n#endif",dithering_pars_fragment:"#ifdef DITHERING\n\tvec3 dithering( vec3 color ) {\n\t\tfloat grid_position = rand( gl_FragCoord.xy );\n\t\tvec3 dither_shift_RGB = vec3( 0.25 / 255.0, -0.25 / 255.0, 0.25 / 255.0 );\n\t\tdither_shift_RGB = mix( 2.0 * dither_shift_RGB, -2.0 * dither_shift_RGB, grid_position );\n\t\treturn color + dither_shift_RGB;\n\t}\n#endif",roughnessmap_fragment:"float roughnessFactor = roughness;\n#ifdef USE_ROUGHNESSMAP\n\tvec4 texelRoughness = texture2D( roughnessMap, vUv );\n\troughnessFactor *= texelRoughness.g;\n#endif",roughnessmap_pars_fragment:"#ifdef USE_ROUGHNESSMAP\n\tuniform sampler2D roughnessMap;\n#endif",shadowmap_pars_fragment:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\t\tuniform sampler2D directionalShadowMap[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tstruct DirectionalLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform DirectionalLightShadow directionalLightShadows[ NUM_DIR_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\t\tuniform sampler2D spotShadowMap[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tstruct SpotLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform SpotLightShadow spotLightShadows[ NUM_SPOT_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\t\tuniform sampler2D pointShadowMap[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tstruct PointLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t\tfloat shadowCameraNear;\n\t\t\tfloat shadowCameraFar;\n\t\t};\n\t\tuniform PointLightShadow pointLightShadows[ NUM_POINT_LIGHT_SHADOWS ];\n\t#endif\n\tfloat texture2DCompare( sampler2D depths, vec2 uv, float compare ) {\n\t\treturn step( compare, unpackRGBAToDepth( texture2D( depths, uv ) ) );\n\t}\n\tvec2 texture2DDistribution( sampler2D shadow, vec2 uv ) {\n\t\treturn unpackRGBATo2Half( texture2D( shadow, uv ) );\n\t}\n\tfloat VSMShadow (sampler2D shadow, vec2 uv, float compare ){\n\t\tfloat occlusion = 1.0;\n\t\tvec2 distribution = texture2DDistribution( shadow, uv );\n\t\tfloat hard_shadow = step( compare , distribution.x );\n\t\tif (hard_shadow != 1.0 ) {\n\t\t\tfloat distance = compare - distribution.x ;\n\t\t\tfloat variance = max( 0.00000, distribution.y * distribution.y );\n\t\t\tfloat softness_probability = variance / (variance + distance * distance );\t\t\tsoftness_probability = clamp( ( softness_probability - 0.3 ) / ( 0.95 - 0.3 ), 0.0, 1.0 );\t\t\tocclusion = clamp( max( hard_shadow, softness_probability ), 0.0, 1.0 );\n\t\t}\n\t\treturn occlusion;\n\t}\n\tfloat getShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord ) {\n\t\tfloat shadow = 1.0;\n\t\tshadowCoord.xyz /= shadowCoord.w;\n\t\tshadowCoord.z += shadowBias;\n\t\tbvec4 inFrustumVec = bvec4 ( shadowCoord.x >= 0.0, shadowCoord.x <= 1.0, shadowCoord.y >= 0.0, shadowCoord.y <= 1.0 );\n\t\tbool inFrustum = all( inFrustumVec );\n\t\tbvec2 frustumTestVec = bvec2( inFrustum, shadowCoord.z <= 1.0 );\n\t\tbool frustumTest = all( frustumTestVec );\n\t\tif ( frustumTest ) {\n\t\t#if defined( SHADOWMAP_TYPE_PCF )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx0 = - texelSize.x * shadowRadius;\n\t\t\tfloat dy0 = - texelSize.y * shadowRadius;\n\t\t\tfloat dx1 = + texelSize.x * shadowRadius;\n\t\t\tfloat dy1 = + texelSize.y * shadowRadius;\n\t\t\tfloat dx2 = dx0 / 2.0;\n\t\t\tfloat dy2 = dy0 / 2.0;\n\t\t\tfloat dx3 = dx1 / 2.0;\n\t\t\tfloat dy3 = dy1 / 2.0;\n\t\t\tshadow = (\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, dy2 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy2 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, dy2 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, dy3 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy3 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, dy3 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )\n\t\t\t) * ( 1.0 / 17.0 );\n\t\t#elif defined( SHADOWMAP_TYPE_PCF_SOFT )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx = texelSize.x;\n\t\t\tfloat dy = texelSize.y;\n\t\t\tvec2 uv = shadowCoord.xy;\n\t\t\tvec2 f = fract( uv * shadowMapSize + 0.5 );\n\t\t\tuv -= f * texelSize;\n\t\t\tshadow = (\n\t\t\t\ttexture2DCompare( shadowMap, uv, shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, uv + vec2( dx, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, uv + vec2( 0.0, dy ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, uv + texelSize, shadowCoord.z ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( -dx, 0.0 ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, 0.0 ), shadowCoord.z ),\n\t\t\t\t\t f.x ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( -dx, dy ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, dy ), shadowCoord.z ),\n\t\t\t\t\t f.x ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( 0.0, -dy ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 0.0, 2.0 * dy ), shadowCoord.z ),\n\t\t\t\t\t f.y ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( dx, -dy ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( dx, 2.0 * dy ), shadowCoord.z ),\n\t\t\t\t\t f.y ) +\n\t\t\t\tmix( mix( texture2DCompare( shadowMap, uv + vec2( -dx, -dy ), shadowCoord.z ), \n\t\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, -dy ), shadowCoord.z ),\n\t\t\t\t\t\t f.x ),\n\t\t\t\t\t mix( texture2DCompare( shadowMap, uv + vec2( -dx, 2.0 * dy ), shadowCoord.z ), \n\t\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, 2.0 * dy ), shadowCoord.z ),\n\t\t\t\t\t\t f.x ),\n\t\t\t\t\t f.y )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#elif defined( SHADOWMAP_TYPE_VSM )\n\t\t\tshadow = VSMShadow( shadowMap, shadowCoord.xy, shadowCoord.z );\n\t\t#else\n\t\t\tshadow = texture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z );\n\t\t#endif\n\t\t}\n\t\treturn shadow;\n\t}\n\tvec2 cubeToUV( vec3 v, float texelSizeY ) {\n\t\tvec3 absV = abs( v );\n\t\tfloat scaleToCube = 1.0 / max( absV.x, max( absV.y, absV.z ) );\n\t\tabsV *= scaleToCube;\n\t\tv *= scaleToCube * ( 1.0 - 2.0 * texelSizeY );\n\t\tvec2 planar = v.xy;\n\t\tfloat almostATexel = 1.5 * texelSizeY;\n\t\tfloat almostOne = 1.0 - almostATexel;\n\t\tif ( absV.z >= almostOne ) {\n\t\t\tif ( v.z > 0.0 )\n\t\t\t\tplanar.x = 4.0 - v.x;\n\t\t} else if ( absV.x >= almostOne ) {\n\t\t\tfloat signX = sign( v.x );\n\t\t\tplanar.x = v.z * signX + 2.0 * signX;\n\t\t} else if ( absV.y >= almostOne ) {\n\t\t\tfloat signY = sign( v.y );\n\t\t\tplanar.x = v.x + 2.0 * signY + 2.0;\n\t\t\tplanar.y = v.z * signY - 2.0;\n\t\t}\n\t\treturn vec2( 0.125, 0.25 ) * planar + vec2( 0.375, 0.75 );\n\t}\n\tfloat getPointShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord, float shadowCameraNear, float shadowCameraFar ) {\n\t\tvec2 texelSize = vec2( 1.0 ) / ( shadowMapSize * vec2( 4.0, 2.0 ) );\n\t\tvec3 lightToPosition = shadowCoord.xyz;\n\t\tfloat dp = ( length( lightToPosition ) - shadowCameraNear ) / ( shadowCameraFar - shadowCameraNear );\t\tdp += shadowBias;\n\t\tvec3 bd3D = normalize( lightToPosition );\n\t\t#if defined( SHADOWMAP_TYPE_PCF ) || defined( SHADOWMAP_TYPE_PCF_SOFT ) || defined( SHADOWMAP_TYPE_VSM )\n\t\t\tvec2 offset = vec2( - 1, 1 ) * shadowRadius * texelSize.y;\n\t\t\treturn (\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxx, texelSize.y ), dp )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#else\n\t\t\treturn texture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp );\n\t\t#endif\n\t}\n#endif",shadowmap_pars_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\t\tuniform mat4 directionalShadowMatrix[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tstruct DirectionalLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform DirectionalLightShadow directionalLightShadows[ NUM_DIR_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\t\tuniform mat4 spotShadowMatrix[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tstruct SpotLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform SpotLightShadow spotLightShadows[ NUM_SPOT_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\t\tuniform mat4 pointShadowMatrix[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tstruct PointLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t\tfloat shadowCameraNear;\n\t\t\tfloat shadowCameraFar;\n\t\t};\n\t\tuniform PointLightShadow pointLightShadows[ NUM_POINT_LIGHT_SHADOWS ];\n\t#endif\n#endif",shadowmap_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0 || NUM_SPOT_LIGHT_SHADOWS > 0 || NUM_POINT_LIGHT_SHADOWS > 0\n\t\tvec3 shadowWorldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\n\t\tvec4 shadowWorldPosition;\n\t#endif\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {\n\t\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * directionalLightShadows[ i ].shadowNormalBias, 0 );\n\t\tvDirectionalShadowCoord[ i ] = directionalShadowMatrix[ i ] * shadowWorldPosition;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {\n\t\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * spotLightShadows[ i ].shadowNormalBias, 0 );\n\t\tvSpotShadowCoord[ i ] = spotShadowMatrix[ i ] * shadowWorldPosition;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {\n\t\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * pointLightShadows[ i ].shadowNormalBias, 0 );\n\t\tvPointShadowCoord[ i ] = pointShadowMatrix[ i ] * shadowWorldPosition;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n#endif",shadowmask_pars_fragment:"float getShadowMask() {\n\tfloat shadow = 1.0;\n\t#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\tDirectionalLightShadow directionalLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {\n\t\tdirectionalLight = directionalLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\tSpotLightShadow spotLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {\n\t\tspotLight = spotLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\tPointLightShadow pointLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {\n\t\tpointLight = pointLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ], pointLight.shadowCameraNear, pointLight.shadowCameraFar ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#endif\n\treturn shadow;\n}",skinbase_vertex:"#ifdef USE_SKINNING\n\tmat4 boneMatX = getBoneMatrix( skinIndex.x );\n\tmat4 boneMatY = getBoneMatrix( skinIndex.y );\n\tmat4 boneMatZ = getBoneMatrix( skinIndex.z );\n\tmat4 boneMatW = getBoneMatrix( skinIndex.w );\n#endif",skinning_pars_vertex:"#ifdef USE_SKINNING\n\tuniform mat4 bindMatrix;\n\tuniform mat4 bindMatrixInverse;\n\t#ifdef BONE_TEXTURE\n\t\tuniform highp sampler2D boneTexture;\n\t\tuniform int boneTextureSize;\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tfloat j = i * 4.0;\n\t\t\tfloat x = mod( j, float( boneTextureSize ) );\n\t\t\tfloat y = floor( j / float( boneTextureSize ) );\n\t\t\tfloat dx = 1.0 / float( boneTextureSize );\n\t\t\tfloat dy = 1.0 / float( boneTextureSize );\n\t\t\ty = dy * ( y + 0.5 );\n\t\t\tvec4 v1 = texture2D( boneTexture, vec2( dx * ( x + 0.5 ), y ) );\n\t\t\tvec4 v2 = texture2D( boneTexture, vec2( dx * ( x + 1.5 ), y ) );\n\t\t\tvec4 v3 = texture2D( boneTexture, vec2( dx * ( x + 2.5 ), y ) );\n\t\t\tvec4 v4 = texture2D( boneTexture, vec2( dx * ( x + 3.5 ), y ) );\n\t\t\tmat4 bone = mat4( v1, v2, v3, v4 );\n\t\t\treturn bone;\n\t\t}\n\t#else\n\t\tuniform mat4 boneMatrices[ MAX_BONES ];\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tmat4 bone = boneMatrices[ int(i) ];\n\t\t\treturn bone;\n\t\t}\n\t#endif\n#endif",skinning_vertex:"#ifdef USE_SKINNING\n\tvec4 skinVertex = bindMatrix * vec4( transformed, 1.0 );\n\tvec4 skinned = vec4( 0.0 );\n\tskinned += boneMatX * skinVertex * skinWeight.x;\n\tskinned += boneMatY * skinVertex * skinWeight.y;\n\tskinned += boneMatZ * skinVertex * skinWeight.z;\n\tskinned += boneMatW * skinVertex * skinWeight.w;\n\ttransformed = ( bindMatrixInverse * skinned ).xyz;\n#endif",skinnormal_vertex:"#ifdef USE_SKINNING\n\tmat4 skinMatrix = mat4( 0.0 );\n\tskinMatrix += skinWeight.x * boneMatX;\n\tskinMatrix += skinWeight.y * boneMatY;\n\tskinMatrix += skinWeight.z * boneMatZ;\n\tskinMatrix += skinWeight.w * boneMatW;\n\tskinMatrix = bindMatrixInverse * skinMatrix * bindMatrix;\n\tobjectNormal = vec4( skinMatrix * vec4( objectNormal, 0.0 ) ).xyz;\n\t#ifdef USE_TANGENT\n\t\tobjectTangent = vec4( skinMatrix * vec4( objectTangent, 0.0 ) ).xyz;\n\t#endif\n#endif",specularmap_fragment:"float specularStrength;\n#ifdef USE_SPECULARMAP\n\tvec4 texelSpecular = texture2D( specularMap, vUv );\n\tspecularStrength = texelSpecular.r;\n#else\n\tspecularStrength = 1.0;\n#endif",specularmap_pars_fragment:"#ifdef USE_SPECULARMAP\n\tuniform sampler2D specularMap;\n#endif",tonemapping_fragment:"#if defined( TONE_MAPPING )\n\tgl_FragColor.rgb = toneMapping( gl_FragColor.rgb );\n#endif",tonemapping_pars_fragment:"#ifndef saturate\n#define saturate( a ) clamp( a, 0.0, 1.0 )\n#endif\nuniform float toneMappingExposure;\nvec3 LinearToneMapping( vec3 color ) {\n\treturn toneMappingExposure * color;\n}\nvec3 ReinhardToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\treturn saturate( color / ( vec3( 1.0 ) + color ) );\n}\nvec3 OptimizedCineonToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\tcolor = max( vec3( 0.0 ), color - 0.004 );\n\treturn pow( ( color * ( 6.2 * color + 0.5 ) ) / ( color * ( 6.2 * color + 1.7 ) + 0.06 ), vec3( 2.2 ) );\n}\nvec3 RRTAndODTFit( vec3 v ) {\n\tvec3 a = v * ( v + 0.0245786 ) - 0.000090537;\n\tvec3 b = v * ( 0.983729 * v + 0.4329510 ) + 0.238081;\n\treturn a / b;\n}\nvec3 ACESFilmicToneMapping( vec3 color ) {\n\tconst mat3 ACESInputMat = mat3(\n\t\tvec3( 0.59719, 0.07600, 0.02840 ),\t\tvec3( 0.35458, 0.90834, 0.13383 ),\n\t\tvec3( 0.04823, 0.01566, 0.83777 )\n\t);\n\tconst mat3 ACESOutputMat = mat3(\n\t\tvec3( 1.60475, -0.10208, -0.00327 ),\t\tvec3( -0.53108, 1.10813, -0.07276 ),\n\t\tvec3( -0.07367, -0.00605, 1.07602 )\n\t);\n\tcolor *= toneMappingExposure / 0.6;\n\tcolor = ACESInputMat * color;\n\tcolor = RRTAndODTFit( color );\n\tcolor = ACESOutputMat * color;\n\treturn saturate( color );\n}\nvec3 CustomToneMapping( vec3 color ) { return color; }",transmission_fragment:"#ifdef USE_TRANSMISSION\n\tfloat transmissionAlpha = 1.0;\n\tfloat transmissionFactor = transmission;\n\tfloat thicknessFactor = thickness;\n\t#ifdef USE_TRANSMISSIONMAP\n\t\ttransmissionFactor *= texture2D( transmissionMap, vUv ).r;\n\t#endif\n\t#ifdef USE_THICKNESSMAP\n\t\tthicknessFactor *= texture2D( thicknessMap, vUv ).g;\n\t#endif\n\tvec3 pos = vWorldPosition;\n\tvec3 v = normalize( cameraPosition - pos );\n\tvec3 n = inverseTransformDirection( normal, viewMatrix );\n\tvec4 transmission = getIBLVolumeRefraction(\n\t\tn, v, roughnessFactor, material.diffuseColor, material.specularColor, material.specularF90,\n\t\tpos, modelMatrix, viewMatrix, projectionMatrix, ior, thicknessFactor,\n\t\tattenuationColor, attenuationDistance );\n\ttotalDiffuse = mix( totalDiffuse, transmission.rgb, transmissionFactor );\n\ttransmissionAlpha = mix( transmissionAlpha, transmission.a, transmissionFactor );\n#endif",transmission_pars_fragment:"#ifdef USE_TRANSMISSION\n\tuniform float transmission;\n\tuniform float thickness;\n\tuniform float attenuationDistance;\n\tuniform vec3 attenuationColor;\n\t#ifdef USE_TRANSMISSIONMAP\n\t\tuniform sampler2D transmissionMap;\n\t#endif\n\t#ifdef USE_THICKNESSMAP\n\t\tuniform sampler2D thicknessMap;\n\t#endif\n\tuniform vec2 transmissionSamplerSize;\n\tuniform sampler2D transmissionSamplerMap;\n\tuniform mat4 modelMatrix;\n\tuniform mat4 projectionMatrix;\n\tvarying vec3 vWorldPosition;\n\tvec3 getVolumeTransmissionRay( vec3 n, vec3 v, float thickness, float ior, mat4 modelMatrix ) {\n\t\tvec3 refractionVector = refract( - v, normalize( n ), 1.0 / ior );\n\t\tvec3 modelScale;\n\t\tmodelScale.x = length( vec3( modelMatrix[ 0 ].xyz ) );\n\t\tmodelScale.y = length( vec3( modelMatrix[ 1 ].xyz ) );\n\t\tmodelScale.z = length( vec3( modelMatrix[ 2 ].xyz ) );\n\t\treturn normalize( refractionVector ) * thickness * modelScale;\n\t}\n\tfloat applyIorToRoughness( float roughness, float ior ) {\n\t\treturn roughness * clamp( ior * 2.0 - 2.0, 0.0, 1.0 );\n\t}\n\tvec4 getTransmissionSample( vec2 fragCoord, float roughness, float ior ) {\n\t\tfloat framebufferLod = log2( transmissionSamplerSize.x ) * applyIorToRoughness( roughness, ior );\n\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\treturn texture2DLodEXT( transmissionSamplerMap, fragCoord.xy, framebufferLod );\n\t\t#else\n\t\t\treturn texture2D( transmissionSamplerMap, fragCoord.xy, framebufferLod );\n\t\t#endif\n\t}\n\tvec3 applyVolumeAttenuation( vec3 radiance, float transmissionDistance, vec3 attenuationColor, float attenuationDistance ) {\n\t\tif ( attenuationDistance == 0.0 ) {\n\t\t\treturn radiance;\n\t\t} else {\n\t\t\tvec3 attenuationCoefficient = -log( attenuationColor ) / attenuationDistance;\n\t\t\tvec3 transmittance = exp( - attenuationCoefficient * transmissionDistance );\t\t\treturn transmittance * radiance;\n\t\t}\n\t}\n\tvec4 getIBLVolumeRefraction( vec3 n, vec3 v, float roughness, vec3 diffuseColor, vec3 specularColor, float specularF90,\n\t\tvec3 position, mat4 modelMatrix, mat4 viewMatrix, mat4 projMatrix, float ior, float thickness,\n\t\tvec3 attenuationColor, float attenuationDistance ) {\n\t\tvec3 transmissionRay = getVolumeTransmissionRay( n, v, thickness, ior, modelMatrix );\n\t\tvec3 refractedRayExit = position + transmissionRay;\n\t\tvec4 ndcPos = projMatrix * viewMatrix * vec4( refractedRayExit, 1.0 );\n\t\tvec2 refractionCoords = ndcPos.xy / ndcPos.w;\n\t\trefractionCoords += 1.0;\n\t\trefractionCoords /= 2.0;\n\t\tvec4 transmittedLight = getTransmissionSample( refractionCoords, roughness, ior );\n\t\tvec3 attenuatedColor = applyVolumeAttenuation( transmittedLight.rgb, length( transmissionRay ), attenuationColor, attenuationDistance );\n\t\tvec3 F = EnvironmentBRDF( n, v, specularColor, specularF90, roughness );\n\t\treturn vec4( ( 1.0 - F ) * attenuatedColor * diffuseColor, transmittedLight.a );\n\t}\n#endif",uv_pars_fragment:"#if ( defined( USE_UV ) && ! defined( UVS_VERTEX_ONLY ) )\n\tvarying vec2 vUv;\n#endif",uv_pars_vertex:"#ifdef USE_UV\n\t#ifdef UVS_VERTEX_ONLY\n\t\tvec2 vUv;\n\t#else\n\t\tvarying vec2 vUv;\n\t#endif\n\tuniform mat3 uvTransform;\n#endif",uv_vertex:"#ifdef USE_UV\n\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\n#endif",uv2_pars_fragment:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvarying vec2 vUv2;\n#endif",uv2_pars_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tattribute vec2 uv2;\n\tvarying vec2 vUv2;\n\tuniform mat3 uv2Transform;\n#endif",uv2_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvUv2 = ( uv2Transform * vec3( uv2, 1 ) ).xy;\n#endif",worldpos_vertex:"#if defined( USE_ENVMAP ) || defined( DISTANCE ) || defined ( USE_SHADOWMAP ) || defined ( USE_TRANSMISSION )\n\tvec4 worldPosition = vec4( transformed, 1.0 );\n\t#ifdef USE_INSTANCING\n\t\tworldPosition = instanceMatrix * worldPosition;\n\t#endif\n\tworldPosition = modelMatrix * worldPosition;\n#endif",background_vert:"varying vec2 vUv;\nuniform mat3 uvTransform;\nvoid main() {\n\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\n\tgl_Position = vec4( position.xy, 1.0, 1.0 );\n}",background_frag:"uniform sampler2D t2D;\nvarying vec2 vUv;\nvoid main() {\n\tvec4 texColor = texture2D( t2D, vUv );\n\tgl_FragColor = mapTexelToLinear( texColor );\n\t#include \n\t#include \n}",cube_vert:"varying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvWorldDirection = transformDirection( position, modelMatrix );\n\t#include \n\t#include \n\tgl_Position.z = gl_Position.w;\n}",cube_frag:"#include \nuniform float opacity;\nvarying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvec3 vReflect = vWorldDirection;\n\t#include \n\tgl_FragColor = envColor;\n\tgl_FragColor.a *= opacity;\n\t#include \n\t#include \n}",depth_vert:"#include \n#include \n#include \n#include \n#include \n#include \n#include \nvarying vec2 vHighPrecisionZW;\nvoid main() {\n\t#include \n\t#include \n\t#ifdef USE_DISPLACEMENTMAP\n\t\t#include \n\t\t#include \n\t\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvHighPrecisionZW = gl_Position.zw;\n}",depth_frag:"#if DEPTH_PACKING == 3200\n\tuniform float opacity;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvarying vec2 vHighPrecisionZW;\nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( 1.0 );\n\t#if DEPTH_PACKING == 3200\n\t\tdiffuseColor.a = opacity;\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\tfloat fragCoordZ = 0.5 * vHighPrecisionZW[0] / vHighPrecisionZW[1] + 0.5;\n\t#if DEPTH_PACKING == 3200\n\t\tgl_FragColor = vec4( vec3( 1.0 - fragCoordZ ), opacity );\n\t#elif DEPTH_PACKING == 3201\n\t\tgl_FragColor = packDepthToRGBA( fragCoordZ );\n\t#endif\n}",distanceRGBA_vert:"#define DISTANCE\nvarying vec3 vWorldPosition;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#ifdef USE_DISPLACEMENTMAP\n\t\t#include \n\t\t#include \n\t\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvWorldPosition = worldPosition.xyz;\n}",distanceRGBA_frag:"#define DISTANCE\nuniform vec3 referencePosition;\nuniform float nearDistance;\nuniform float farDistance;\nvarying vec3 vWorldPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main () {\n\t#include \n\tvec4 diffuseColor = vec4( 1.0 );\n\t#include \n\t#include \n\t#include \n\tfloat dist = length( vWorldPosition - referencePosition );\n\tdist = ( dist - nearDistance ) / ( farDistance - nearDistance );\n\tdist = saturate( dist );\n\tgl_FragColor = packDepthToRGBA( dist );\n}",equirect_vert:"varying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvWorldDirection = transformDirection( position, modelMatrix );\n\t#include \n\t#include \n}",equirect_frag:"uniform sampler2D tEquirect;\nvarying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvec3 direction = normalize( vWorldDirection );\n\tvec2 sampleUV = equirectUv( direction );\n\tvec4 texColor = texture2D( tEquirect, sampleUV );\n\tgl_FragColor = mapTexelToLinear( texColor );\n\t#include \n\t#include \n}",linedashed_vert:"uniform float scale;\nattribute float lineDistance;\nvarying float vLineDistance;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\tvLineDistance = scale * lineDistance;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",linedashed_frag:"uniform vec3 diffuse;\nuniform float opacity;\nuniform float dashSize;\nuniform float totalSize;\nvarying float vLineDistance;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tif ( mod( vLineDistance, totalSize ) > dashSize ) {\n\t\tdiscard;\n\t}\n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshbasic_vert:"#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#if defined ( USE_ENVMAP ) || defined ( USE_SKINNING )\n\t\t#include \n\t\t#include \n\t\t#include \n\t\t#include \n\t\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshbasic_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\t#ifdef USE_LIGHTMAP\n\t\tvec4 lightMapTexel= texture2D( lightMap, vUv2 );\n\t\treflectedLight.indirectDiffuse += lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\n\t#else\n\t\treflectedLight.indirectDiffuse += vec3( 1.0 );\n\t#endif\n\t#include \n\treflectedLight.indirectDiffuse *= diffuseColor.rgb;\n\tvec3 outgoingLight = reflectedLight.indirectDiffuse;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshlambert_vert:"#define LAMBERT\nvarying vec3 vLightFront;\nvarying vec3 vIndirectFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n\tvarying vec3 vIndirectBack;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshlambert_frag:"uniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float opacity;\nvarying vec3 vLightFront;\nvarying vec3 vIndirectFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n\tvarying vec3 vIndirectBack;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#ifdef DOUBLE_SIDED\n\t\treflectedLight.indirectDiffuse += ( gl_FrontFacing ) ? vIndirectFront : vIndirectBack;\n\t#else\n\t\treflectedLight.indirectDiffuse += vIndirectFront;\n\t#endif\n\t#include \n\treflectedLight.indirectDiffuse *= BRDF_Lambert( diffuseColor.rgb );\n\t#ifdef DOUBLE_SIDED\n\t\treflectedLight.directDiffuse = ( gl_FrontFacing ) ? vLightFront : vLightBack;\n\t#else\n\t\treflectedLight.directDiffuse = vLightFront;\n\t#endif\n\treflectedLight.directDiffuse *= BRDF_Lambert( diffuseColor.rgb ) * getShadowMask();\n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshmatcap_vert:"#define MATCAP\nvarying vec3 vViewPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n}",meshmatcap_frag:"#define MATCAP\nuniform vec3 diffuse;\nuniform float opacity;\nuniform sampler2D matcap;\nvarying vec3 vViewPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 viewDir = normalize( vViewPosition );\n\tvec3 x = normalize( vec3( viewDir.z, 0.0, - viewDir.x ) );\n\tvec3 y = cross( viewDir, x );\n\tvec2 uv = vec2( dot( x, normal ), dot( y, normal ) ) * 0.495 + 0.5;\n\t#ifdef USE_MATCAP\n\t\tvec4 matcapColor = texture2D( matcap, uv );\n\t\tmatcapColor = matcapTexelToLinear( matcapColor );\n\t#else\n\t\tvec4 matcapColor = vec4( 1.0 );\n\t#endif\n\tvec3 outgoingLight = diffuseColor.rgb * matcapColor.rgb;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshnormal_vert:"#define NORMAL\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\n\tvViewPosition = - mvPosition.xyz;\n#endif\n}",meshnormal_frag:"#define NORMAL\nuniform float opacity;\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\tgl_FragColor = vec4( packNormalToRGB( normal ), opacity );\n}",meshphong_vert:"#define PHONG\nvarying vec3 vViewPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n\t#include \n}",meshphong_frag:"#define PHONG\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform vec3 specular;\nuniform float shininess;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshphysical_vert:"#define STANDARD\nvarying vec3 vViewPosition;\n#ifdef USE_TRANSMISSION\n\tvarying vec3 vWorldPosition;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n#ifdef USE_TRANSMISSION\n\tvWorldPosition = worldPosition.xyz;\n#endif\n}",meshphysical_frag:"#define STANDARD\n#ifdef PHYSICAL\n\t#define IOR\n\t#define SPECULAR\n#endif\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float roughness;\nuniform float metalness;\nuniform float opacity;\n#ifdef IOR\n\tuniform float ior;\n#endif\n#ifdef SPECULAR\n\tuniform float specularIntensity;\n\tuniform vec3 specularColor;\n\t#ifdef USE_SPECULARINTENSITYMAP\n\t\tuniform sampler2D specularIntensityMap;\n\t#endif\n\t#ifdef USE_SPECULARCOLORMAP\n\t\tuniform sampler2D specularColorMap;\n\t#endif\n#endif\n#ifdef USE_CLEARCOAT\n\tuniform float clearcoat;\n\tuniform float clearcoatRoughness;\n#endif\n#ifdef USE_SHEEN\n\tuniform vec3 sheenColor;\n\tuniform float sheenRoughness;\n\t#ifdef USE_SHEENCOLORMAP\n\t\tuniform sampler2D sheenColorMap;\n\t#endif\n\t#ifdef USE_SHEENROUGHNESSMAP\n\t\tuniform sampler2D sheenRoughnessMap;\n\t#endif\n#endif\nvarying vec3 vViewPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 totalDiffuse = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse;\n\tvec3 totalSpecular = reflectedLight.directSpecular + reflectedLight.indirectSpecular;\n\t#include \n\tvec3 outgoingLight = totalDiffuse + totalSpecular + totalEmissiveRadiance;\n\t#ifdef USE_CLEARCOAT\n\t\tfloat dotNVcc = saturate( dot( geometry.clearcoatNormal, geometry.viewDir ) );\n\t\tvec3 Fcc = F_Schlick( material.clearcoatF0, material.clearcoatF90, dotNVcc );\n\t\toutgoingLight = outgoingLight * ( 1.0 - material.clearcoat * Fcc ) + clearcoatSpecular * material.clearcoat;\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshtoon_vert:"#define TOON\nvarying vec3 vViewPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n}",meshtoon_frag:"#define TOON\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",points_vert:"uniform float size;\nuniform float scale;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\tgl_PointSize = size;\n\t#ifdef USE_SIZEATTENUATION\n\t\tbool isPerspective = isPerspectiveMatrix( projectionMatrix );\n\t\tif ( isPerspective ) gl_PointSize *= ( scale / - mvPosition.z );\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n}",points_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",shadow_vert:"#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",shadow_frag:"uniform vec3 color;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\tgl_FragColor = vec4( color, opacity * ( 1.0 - getShadowMask() ) );\n\t#include \n\t#include \n\t#include \n}",sprite_vert:"uniform float rotation;\nuniform vec2 center;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 mvPosition = modelViewMatrix * vec4( 0.0, 0.0, 0.0, 1.0 );\n\tvec2 scale;\n\tscale.x = length( vec3( modelMatrix[ 0 ].x, modelMatrix[ 0 ].y, modelMatrix[ 0 ].z ) );\n\tscale.y = length( vec3( modelMatrix[ 1 ].x, modelMatrix[ 1 ].y, modelMatrix[ 1 ].z ) );\n\t#ifndef USE_SIZEATTENUATION\n\t\tbool isPerspective = isPerspectiveMatrix( projectionMatrix );\n\t\tif ( isPerspective ) scale *= - mvPosition.z;\n\t#endif\n\tvec2 alignedPosition = ( position.xy - ( center - vec2( 0.5 ) ) ) * scale;\n\tvec2 rotatedPosition;\n\trotatedPosition.x = cos( rotation ) * alignedPosition.x - sin( rotation ) * alignedPosition.y;\n\trotatedPosition.y = sin( rotation ) * alignedPosition.x + cos( rotation ) * alignedPosition.y;\n\tmvPosition.xy += rotatedPosition;\n\tgl_Position = projectionMatrix * mvPosition;\n\t#include \n\t#include \n\t#include \n}",sprite_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\t#include \n\t#include \n\t#include \n\t#include \n}"},Ct={common:{diffuse:{value:new Rt(16777215)},opacity:{value:1},map:{value:null},uvTransform:{value:new js},uv2Transform:{value:new js},alphaMap:{value:null},alphaTest:{value:0}},specularmap:{specularMap:{value:null}},envmap:{envMap:{value:null},flipEnvMap:{value:-1},reflectivity:{value:1},ior:{value:1.5},refractionRatio:{value:.98}},aomap:{aoMap:{value:null},aoMapIntensity:{value:1}},lightmap:{lightMap:{value:null},lightMapIntensity:{value:1}},emissivemap:{emissiveMap:{value:null}},bumpmap:{bumpMap:{value:null},bumpScale:{value:1}},normalmap:{normalMap:{value:null},normalScale:{value:new tt(1,1)}},displacementmap:{displacementMap:{value:null},displacementScale:{value:1},displacementBias:{value:0}},roughnessmap:{roughnessMap:{value:null}},metalnessmap:{metalnessMap:{value:null}},gradientmap:{gradientMap:{value:null}},fog:{fogDensity:{value:25e-5},fogNear:{value:1},fogFar:{value:2e3},fogColor:{value:new Rt(16777215)}},lights:{ambientLightColor:{value:[]},lightProbe:{value:[]},directionalLights:{value:[],properties:{direction:{},color:{}}},directionalLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{}}},directionalShadowMap:{value:[]},directionalShadowMatrix:{value:[]},spotLights:{value:[],properties:{color:{},position:{},direction:{},distance:{},coneCos:{},penumbraCos:{},decay:{}}},spotLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{}}},spotShadowMap:{value:[]},spotShadowMatrix:{value:[]},pointLights:{value:[],properties:{color:{},position:{},decay:{},distance:{}}},pointLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{},shadowCameraNear:{},shadowCameraFar:{}}},pointShadowMap:{value:[]},pointShadowMatrix:{value:[]},hemisphereLights:{value:[],properties:{direction:{},skyColor:{},groundColor:{}}},rectAreaLights:{value:[],properties:{color:{},position:{},width:{},height:{}}},ltc_1:{value:null},ltc_2:{value:null}},points:{diffuse:{value:new Rt(16777215)},opacity:{value:1},size:{value:1},scale:{value:1},map:{value:null},alphaMap:{value:null},alphaTest:{value:0},uvTransform:{value:new js}},sprite:{diffuse:{value:new Rt(16777215)},opacity:{value:1},center:{value:new tt(.5,.5)},rotation:{value:0},map:{value:null},alphaMap:{value:null},alphaTest:{value:0},uvTransform:{value:new js}}},ed={basic:{uniforms:jo([Ct.common,Ct.specularmap,Ct.envmap,Ct.aomap,Ct.lightmap,Ct.fog]),vertexShader:pi.meshbasic_vert,fragmentShader:pi.meshbasic_frag},lambert:{uniforms:jo([Ct.common,Ct.specularmap,Ct.envmap,Ct.aomap,Ct.lightmap,Ct.emissivemap,Ct.fog,Ct.lights,{emissive:{value:new Rt(0)}}]),vertexShader:pi.meshlambert_vert,fragmentShader:pi.meshlambert_frag},phong:{uniforms:jo([Ct.common,Ct.specularmap,Ct.envmap,Ct.aomap,Ct.lightmap,Ct.emissivemap,Ct.bumpmap,Ct.normalmap,Ct.displacementmap,Ct.fog,Ct.lights,{emissive:{value:new Rt(0)},specular:{value:new Rt(1118481)},shininess:{value:30}}]),vertexShader:pi.meshphong_vert,fragmentShader:pi.meshphong_frag},standard:{uniforms:jo([Ct.common,Ct.envmap,Ct.aomap,Ct.lightmap,Ct.emissivemap,Ct.bumpmap,Ct.normalmap,Ct.displacementmap,Ct.roughnessmap,Ct.metalnessmap,Ct.fog,Ct.lights,{emissive:{value:new Rt(0)},roughness:{value:1},metalness:{value:0},envMapIntensity:{value:1}}]),vertexShader:pi.meshphysical_vert,fragmentShader:pi.meshphysical_frag},toon:{uniforms:jo([Ct.common,Ct.aomap,Ct.lightmap,Ct.emissivemap,Ct.bumpmap,Ct.normalmap,Ct.displacementmap,Ct.gradientmap,Ct.fog,Ct.lights,{emissive:{value:new Rt(0)}}]),vertexShader:pi.meshtoon_vert,fragmentShader:pi.meshtoon_frag},matcap:{uniforms:jo([Ct.common,Ct.bumpmap,Ct.normalmap,Ct.displacementmap,Ct.fog,{matcap:{value:null}}]),vertexShader:pi.meshmatcap_vert,fragmentShader:pi.meshmatcap_frag},points:{uniforms:jo([Ct.points,Ct.fog]),vertexShader:pi.points_vert,fragmentShader:pi.points_frag},dashed:{uniforms:jo([Ct.common,Ct.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:pi.linedashed_vert,fragmentShader:pi.linedashed_frag},depth:{uniforms:jo([Ct.common,Ct.displacementmap]),vertexShader:pi.depth_vert,fragmentShader:pi.depth_frag},normal:{uniforms:jo([Ct.common,Ct.bumpmap,Ct.normalmap,Ct.displacementmap,{opacity:{value:1}}]),vertexShader:pi.meshnormal_vert,fragmentShader:pi.meshnormal_frag},sprite:{uniforms:jo([Ct.sprite,Ct.fog]),vertexShader:pi.sprite_vert,fragmentShader:pi.sprite_frag},background:{uniforms:{uvTransform:{value:new js},t2D:{value:null}},vertexShader:pi.background_vert,fragmentShader:pi.background_frag},cube:{uniforms:jo([Ct.envmap,{opacity:{value:1}}]),vertexShader:pi.cube_vert,fragmentShader:pi.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:pi.equirect_vert,fragmentShader:pi.equirect_frag},distanceRGBA:{uniforms:jo([Ct.common,Ct.displacementmap,{referencePosition:{value:new ne},nearDistance:{value:1},farDistance:{value:1e3}}]),vertexShader:pi.distanceRGBA_vert,fragmentShader:pi.distanceRGBA_frag},shadow:{uniforms:jo([Ct.lights,Ct.fog,{color:{value:new Rt(0)},opacity:{value:1}}]),vertexShader:pi.shadow_vert,fragmentShader:pi.shadow_frag}};function xae(n,e,t,i,r){const s=new Rt(0);let a,c,o=0,u=null,p=0,g=null;function y(x,T){t.buffers.color.setClear(x.r,x.g,x.b,T,r)}return{getClearColor:function(){return s},setClearColor:function(x,T=1){s.set(x),o=T,y(s,o)},getClearAlpha:function(){return o},setClearAlpha:function(x){o=x,y(s,o)},render:function v(x,T){let N=!1,k=!0===T.isScene?T.background:null;k&&k.isTexture&&(k=e.get(k));const A=n.xr,H=A.getSession&&A.getSession();H&&"additive"===H.environmentBlendMode&&(k=null),null===k?y(s,o):k&&k.isColor&&(y(k,1),N=!0),(n.autoClear||N)&&n.clear(n.autoClearColor,n.autoClearDepth,n.autoClearStencil),k&&(k.isCubeTexture||k.mapping===ky)?(void 0===c&&(c=new vr(new tu(1,1,1),new wh({name:"BackgroundCubeMaterial",uniforms:a0(ed.cube.uniforms),vertexShader:ed.cube.vertexShader,fragmentShader:ed.cube.fragmentShader,side:Ds,depthTest:!1,depthWrite:!1,fog:!1})),c.geometry.deleteAttribute("normal"),c.geometry.deleteAttribute("uv"),c.onBeforeRender=function(G,X,se){this.matrixWorld.copyPosition(se.matrixWorld)},Object.defineProperty(c.material,"envMap",{get:function(){return this.uniforms.envMap.value}}),i.update(c)),c.material.uniforms.envMap.value=k,c.material.uniforms.flipEnvMap.value=k.isCubeTexture&&!1===k.isRenderTargetTexture?-1:1,(u!==k||p!==k.version||g!==n.toneMapping)&&(c.material.needsUpdate=!0,u=k,p=k.version,g=n.toneMapping),x.unshift(c,c.geometry,c.material,0,0,null)):k&&k.isTexture&&(void 0===a&&(a=new vr(new Uy(2,2),new wh({name:"BackgroundMaterial",uniforms:a0(ed.background.uniforms),vertexShader:ed.background.vertexShader,fragmentShader:ed.background.fragmentShader,side:Og,depthTest:!1,depthWrite:!1,fog:!1})),a.geometry.deleteAttribute("normal"),Object.defineProperty(a.material,"map",{get:function(){return this.uniforms.t2D.value}}),i.update(a)),a.material.uniforms.t2D.value=k,!0===k.matrixAutoUpdate&&k.updateMatrix(),a.material.uniforms.uvTransform.value.copy(k.matrix),(u!==k||p!==k.version||g!==n.toneMapping)&&(a.material.needsUpdate=!0,u=k,p=k.version,g=n.toneMapping),x.unshift(a,a.geometry,a.material,0,0,null))}}}function wae(n,e,t,i){const r=n.getParameter(34921),s=i.isWebGL2?null:e.get("OES_vertex_array_object"),o=i.isWebGL2||null!==s,a={},c=T(null);let u=c;function v(Pe){return i.isWebGL2?n.bindVertexArray(Pe):s.bindVertexArrayOES(Pe)}function y(Pe){return i.isWebGL2?n.deleteVertexArray(Pe):s.deleteVertexArrayOES(Pe)}function T(Pe){const Oe=[],Ve=[],ye=[];for(let Me=0;Me=0){let vt=Me[ze];if(void 0===vt&&("instanceMatrix"===ze&&Pe.instanceMatrix&&(vt=Pe.instanceMatrix),"instanceColor"===ze&&Pe.instanceColor&&(vt=Pe.instanceColor)),void 0!==vt){const yt=vt.normalized,gt=vt.itemSize,mi=t.get(vt);if(void 0===mi)continue;const ct=mi.buffer,Qt=mi.type,sn=mi.bytesPerElement;if(vt.isInterleavedBufferAttribute){const It=vt.data,on=It.stride,gi=vt.offset;if(It&&It.isInstancedInterleavedBuffer){for(let Xe=0;Xe0&&n.getShaderPrecisionFormat(35632,36338).precision>0)return"highp";K="mediump"}return"mediump"===K&&n.getShaderPrecisionFormat(35633,36337).precision>0&&n.getShaderPrecisionFormat(35632,36337).precision>0?"mediump":"lowp"}const o=typeof WebGL2RenderingContext<"u"&&n instanceof WebGL2RenderingContext||typeof WebGL2ComputeRenderingContext<"u"&&n instanceof WebGL2ComputeRenderingContext;let a=void 0!==t.precision?t.precision:"highp";const c=s(a);c!==a&&(console.warn("THREE.WebGLRenderer:",a,"not supported, using",c,"instead."),a=c);const u=o||e.has("WEBGL_draw_buffers"),p=!0===t.logarithmicDepthBuffer,g=n.getParameter(34930),v=n.getParameter(35660),y=n.getParameter(3379),x=n.getParameter(34076),T=n.getParameter(34921),N=n.getParameter(36347),k=n.getParameter(36348),A=n.getParameter(36349),H=v>0,G=o||e.has("OES_texture_float");return{isWebGL2:o,drawBuffers:u,getMaxAnisotropy:function r(){if(void 0!==i)return i;if(!0===e.has("EXT_texture_filter_anisotropic")){const K=e.get("EXT_texture_filter_anisotropic");i=n.getParameter(K.MAX_TEXTURE_MAX_ANISOTROPY_EXT)}else i=0;return i},getMaxPrecision:s,precision:a,logarithmicDepthBuffer:p,maxTextures:g,maxVertexTextures:v,maxTextureSize:y,maxCubemapSize:x,maxAttributes:T,maxVertexUniforms:N,maxVaryings:k,maxFragmentUniforms:A,vertexTextures:H,floatFragmentTextures:G,floatVertexTextures:H&&G,maxSamples:o?n.getParameter(36183):0}}function Mae(n){const e=this;let t=null,i=0,r=!1,s=!1;const o=new nu,a=new js,c={value:null,needsUpdate:!1};function u(){c.value!==t&&(c.value=t,c.needsUpdate=i>0),e.numPlanes=i,e.numIntersection=0}function p(g,v,y,x){const T=null!==g?g.length:0;let N=null;if(0!==T){if(N=c.value,!0!==x||null===N){const k=y+4*T,A=v.matrixWorldInverse;a.getNormalMatrix(A),(null===N||N.length0){const u=n.getRenderTarget(),p=new rI(c.height/2);return p.fromEquirectangularTexture(n,o),e.set(o,p),n.setRenderTarget(u),o.addEventListener("dispose",r),t(p.texture,o.mapping)}return null}}}return o},dispose:function s(){e=new WeakMap}}}ed.physical={uniforms:jo([ed.standard.uniforms,{clearcoat:{value:0},clearcoatMap:{value:null},clearcoatRoughness:{value:0},clearcoatRoughnessMap:{value:null},clearcoatNormalScale:{value:new tt(1,1)},clearcoatNormalMap:{value:null},sheen:{value:0},sheenColor:{value:new Rt(0)},sheenColorMap:{value:null},sheenRoughness:{value:0},sheenRoughnessMap:{value:null},transmission:{value:0},transmissionMap:{value:null},transmissionSamplerSize:{value:new tt},transmissionSamplerMap:{value:null},thickness:{value:0},thicknessMap:{value:null},attenuationDistance:{value:0},attenuationColor:{value:new Rt(0)},specularIntensity:{value:0},specularIntensityMap:{value:null},specularColor:{value:new Rt(1,1,1)},specularColorMap:{value:null}}]),vertexShader:pi.meshphysical_vert,fragmentShader:pi.meshphysical_frag};class S2 extends b2{constructor(e=-1,t=1,i=1,r=-1,s=.1,o=2e3){super(),this.type="OrthographicCamera",this.zoom=1,this.view=null,this.left=e,this.right=t,this.top=i,this.bottom=r,this.near=s,this.far=o,this.updateProjectionMatrix()}copy(e,t){return super.copy(e,t),this.left=e.left,this.right=e.right,this.top=e.top,this.bottom=e.bottom,this.near=e.near,this.far=e.far,this.zoom=e.zoom,this.view=null===e.view?null:Object.assign({},e.view),this}setViewOffset(e,t,i,r,s,o){null===this.view&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=e,this.view.fullHeight=t,this.view.offsetX=i,this.view.offsetY=r,this.view.width=s,this.view.height=o,this.updateProjectionMatrix()}clearViewOffset(){null!==this.view&&(this.view.enabled=!1),this.updateProjectionMatrix()}updateProjectionMatrix(){const e=(this.right-this.left)/(2*this.zoom),t=(this.top-this.bottom)/(2*this.zoom),i=(this.right+this.left)/2,r=(this.top+this.bottom)/2;let s=i-e,o=i+e,a=r+t,c=r-t;if(null!==this.view&&this.view.enabled){const u=(this.right-this.left)/this.view.fullWidth/this.zoom,p=(this.top-this.bottom)/this.view.fullHeight/this.zoom;s+=u*this.view.offsetX,o=s+u*this.view.width,a-=p*this.view.offsetY,c=a-p*this.view.height}this.projectionMatrix.makeOrthographic(s,o,a,c,this.near,this.far),this.projectionMatrixInverse.copy(this.projectionMatrix).invert()}toJSON(e){const t=super.toJSON(e);return t.object.zoom=this.zoom,t.object.left=this.left,t.object.right=this.right,t.object.top=this.top,t.object.bottom=this.bottom,t.object.near=this.near,t.object.far=this.far,null!==this.view&&(t.object.view=Object.assign({},this.view)),t}}S2.prototype.isOrthographicCamera=!0;class zy extends wh{constructor(e){super(e),this.type="RawShaderMaterial"}}zy.prototype.isRawShaderMaterial=!0;const u0=4,Sh=8,td=Math.pow(2,Sh),kB=[.125,.215,.35,.446,.526,.582],IB=Sh-u0+1+kB.length,cp={[Ma]:0,[e2]:1,[Tk]:2,[cB]:3,[lB]:4,[dB]:5,[Dk]:6},oI=new S2,{_lodPlanes:Gy,_sizeLods:FB,_sigmas:E2}=Aae(),RB=new Rt;let aI=null;const lp=(1+Math.sqrt(5))/2,f0=1/lp,PB=[new ne(1,1,1),new ne(-1,1,1),new ne(1,1,-1),new ne(-1,1,-1),new ne(0,lp,f0),new ne(0,lp,-f0),new ne(f0,0,lp),new ne(-f0,0,lp),new ne(lp,f0,0),new ne(-lp,f0,0)];class Dae{constructor(e){this._renderer=e,this._pingPongRenderTarget=null,this._blurMaterial=function kae(n){const e=new Float32Array(n),t=new ne(0,1,0);return new zy({name:"SphericalGaussianBlur",defines:{n},uniforms:{envMap:{value:null},samples:{value:1},weights:{value:e},latitudinal:{value:!1},dTheta:{value:0},mipInt:{value:0},poleAxis:{value:t},inputEncoding:{value:cp[Ma]},outputEncoding:{value:cp[Ma]}},vertexShader:"\n\n\t\tprecision mediump float;\n\t\tprecision mediump int;\n\n\t\tattribute vec3 position;\n\t\tattribute vec2 uv;\n\t\tattribute float faceIndex;\n\n\t\tvarying vec3 vOutputDirection;\n\n\t\t// RH coordinate system; PMREM face-indexing convention\n\t\tvec3 getDirection( vec2 uv, float face ) {\n\n\t\t\tuv = 2.0 * uv - 1.0;\n\n\t\t\tvec3 direction = vec3( uv, 1.0 );\n\n\t\t\tif ( face == 0.0 ) {\n\n\t\t\t\tdirection = direction.zyx; // ( 1, v, u ) pos x\n\n\t\t\t} else if ( face == 1.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xz *= -1.0; // ( -u, 1, -v ) pos y\n\n\t\t\t} else if ( face == 2.0 ) {\n\n\t\t\t\tdirection.x *= -1.0; // ( -u, v, 1 ) pos z\n\n\t\t\t} else if ( face == 3.0 ) {\n\n\t\t\t\tdirection = direction.zyx;\n\t\t\t\tdirection.xz *= -1.0; // ( -1, v, -u ) neg x\n\n\t\t\t} else if ( face == 4.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xy *= -1.0; // ( -u, -1, v ) neg y\n\n\t\t\t} else if ( face == 5.0 ) {\n\n\t\t\t\tdirection.z *= -1.0; // ( u, v, -1 ) neg z\n\n\t\t\t}\n\n\t\t\treturn direction;\n\n\t\t}\n\n\t\tvoid main() {\n\n\t\t\tvOutputDirection = getDirection( uv, faceIndex );\n\t\t\tgl_Position = vec4( position, 1.0 );\n\n\t\t}\n\t",fragmentShader:"\n\n\t\t\tprecision mediump float;\n\t\t\tprecision mediump int;\n\n\t\t\tvarying vec3 vOutputDirection;\n\n\t\t\tuniform sampler2D envMap;\n\t\t\tuniform int samples;\n\t\t\tuniform float weights[ n ];\n\t\t\tuniform bool latitudinal;\n\t\t\tuniform float dTheta;\n\t\t\tuniform float mipInt;\n\t\t\tuniform vec3 poleAxis;\n\n\t\t\t\n\n\t\tuniform int inputEncoding;\n\t\tuniform int outputEncoding;\n\n\t\t#include \n\n\t\tvec4 inputTexelToLinear( vec4 value ) {\n\n\t\t\tif ( inputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( inputEncoding == 1 ) {\n\n\t\t\t\treturn sRGBToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 2 ) {\n\n\t\t\t\treturn RGBEToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 3 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 7.0 );\n\n\t\t\t} else if ( inputEncoding == 4 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 16.0 );\n\n\t\t\t} else if ( inputEncoding == 5 ) {\n\n\t\t\t\treturn RGBDToLinear( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn GammaToLinear( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 linearToOutputTexel( vec4 value ) {\n\n\t\t\tif ( outputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( outputEncoding == 1 ) {\n\n\t\t\t\treturn LinearTosRGB( value );\n\n\t\t\t} else if ( outputEncoding == 2 ) {\n\n\t\t\t\treturn LinearToRGBE( value );\n\n\t\t\t} else if ( outputEncoding == 3 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 7.0 );\n\n\t\t\t} else if ( outputEncoding == 4 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 16.0 );\n\n\t\t\t} else if ( outputEncoding == 5 ) {\n\n\t\t\t\treturn LinearToRGBD( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn LinearToGamma( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 envMapTexelToLinear( vec4 color ) {\n\n\t\t\treturn inputTexelToLinear( color );\n\n\t\t}\n\t\n\n\t\t\t#define ENVMAP_TYPE_CUBE_UV\n\t\t\t#include \n\n\t\t\tvec3 getSample( float theta, vec3 axis ) {\n\n\t\t\t\tfloat cosTheta = cos( theta );\n\t\t\t\t// Rodrigues' axis-angle rotation\n\t\t\t\tvec3 sampleDirection = vOutputDirection * cosTheta\n\t\t\t\t\t+ cross( axis, vOutputDirection ) * sin( theta )\n\t\t\t\t\t+ axis * dot( axis, vOutputDirection ) * ( 1.0 - cosTheta );\n\n\t\t\t\treturn bilinearCubeUV( envMap, sampleDirection, mipInt );\n\n\t\t\t}\n\n\t\t\tvoid main() {\n\n\t\t\t\tvec3 axis = latitudinal ? poleAxis : cross( poleAxis, vOutputDirection );\n\n\t\t\t\tif ( all( equal( axis, vec3( 0.0 ) ) ) ) {\n\n\t\t\t\t\taxis = vec3( vOutputDirection.z, 0.0, - vOutputDirection.x );\n\n\t\t\t\t}\n\n\t\t\t\taxis = normalize( axis );\n\n\t\t\t\tgl_FragColor = vec4( 0.0, 0.0, 0.0, 1.0 );\n\t\t\t\tgl_FragColor.rgb += weights[ 0 ] * getSample( 0.0, axis );\n\n\t\t\t\tfor ( int i = 1; i < n; i++ ) {\n\n\t\t\t\t\tif ( i >= samples ) {\n\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t}\n\n\t\t\t\t\tfloat theta = dTheta * float( i );\n\t\t\t\t\tgl_FragColor.rgb += weights[ i ] * getSample( -1.0 * theta, axis );\n\t\t\t\t\tgl_FragColor.rgb += weights[ i ] * getSample( theta, axis );\n\n\t\t\t\t}\n\n\t\t\t\tgl_FragColor = linearToOutputTexel( gl_FragColor );\n\n\t\t\t}\n\t\t",blending:hh,depthTest:!1,depthWrite:!1})}(20),this._equirectShader=null,this._cubemapShader=null,this._compileMaterial(this._blurMaterial)}fromScene(e,t=0,i=.1,r=100){aI=this._renderer.getRenderTarget();const s=this._allocateTargets();return this._sceneToCubeUV(e,i,r,s),t>0&&this._blur(s,0,0,t),this._applyPMREM(s),this._cleanup(s),s}fromEquirectangular(e){return this._fromTexture(e)}fromCubemap(e){return this._fromTexture(e)}compileCubemapShader(){null===this._cubemapShader&&(this._cubemapShader=NB(),this._compileMaterial(this._cubemapShader))}compileEquirectangularShader(){null===this._equirectShader&&(this._equirectShader=LB(),this._compileMaterial(this._equirectShader))}dispose(){this._blurMaterial.dispose(),null!==this._cubemapShader&&this._cubemapShader.dispose(),null!==this._equirectShader&&this._equirectShader.dispose();for(let e=0;e2?td:0,td,td),p.setRenderTarget(r),N&&p.render(T,a),p.render(e,a)}T.geometry.dispose(),T.material.dispose(),p.toneMapping=y,p.outputEncoding=v,p.autoClear=g,e.background=k}_setEncoding(e,t){e.value=cp[t.encoding]}_textureToCubeUV(e,t){const i=this._renderer,r=e.mapping===Bg||e.mapping===Vg;r?null==this._cubemapShader&&(this._cubemapShader=NB()):null==this._equirectShader&&(this._equirectShader=LB());const s=r?this._cubemapShader:this._equirectShader,o=new vr(Gy[0],s),a=s.uniforms;a.envMap.value=e,r||a.texelSize.value.set(1/e.image.width,1/e.image.height),this._setEncoding(a.inputEncoding,e),this._setEncoding(a.outputEncoding,t.texture),M2(t,0,0,3*td,2*td),i.setRenderTarget(t),i.render(o,oI)}_applyPMREM(e){const t=this._renderer,i=t.autoClear;t.autoClear=!1;for(let r=1;r20&&console.warn(`sigmaRadians, ${s}, is too large and will clip, as it requested ${N} samples when the maximum is set to 20`);const k=[];let A=0;for(let se=0;se<20;++se){const K=se/T,he=Math.exp(-K*K/2);k.push(he),0==se?A+=he:seSh-u0?r-Sh+u0:0),3*H,2*H),c.setRenderTarget(t),c.render(g,oI)}}function Tae(n){return void 0!==n&&n.type===fh&&(n.encoding===Ma||n.encoding===e2||n.encoding===Dk)}function Aae(){const n=[],e=[],t=[];let i=Sh;for(let r=0;rSh-u0?o=kB[r-Sh+u0-1]:0==r&&(o=0),t.push(o);const a=1/(s-1),c=-a/2,u=1+a/2,p=[c,c,u,c,u,u,c,c,u,u,c,u],g=6,v=6,y=3,x=2,T=1,N=new Float32Array(y*v*g),k=new Float32Array(x*v*g),A=new Float32Array(T*v*g);for(let G=0;G2?0:-1;N.set([X,se,0,X+2/3,se,0,X+2/3,se+1,0,X,se,0,X+2/3,se+1,0,X,se+1,0],y*v*G),k.set(p,x*v*G),A.set([G,G,G,G,G,G],T*v*G)}const H=new gn;H.setAttribute("position",new zi(N,y)),H.setAttribute("uv",new zi(k,x)),H.setAttribute("faceIndex",new zi(A,T)),n.push(H),i>u0&&i--}return{_lodPlanes:n,_sizeLods:e,_sigmas:t}}function OB(n){const e=new Bc(3*td,3*td,n);return e.texture.mapping=ky,e.texture.name="PMREM.cubeUv",e.scissorTest=!0,e}function M2(n,e,t,i,r){n.viewport.set(e,t,i,r),n.scissor.set(e,t,i,r)}function LB(){const n=new tt(1,1);return new zy({name:"EquirectangularToCubeUV",uniforms:{envMap:{value:null},texelSize:{value:n},inputEncoding:{value:cp[Ma]},outputEncoding:{value:cp[Ma]}},vertexShader:"\n\n\t\tprecision mediump float;\n\t\tprecision mediump int;\n\n\t\tattribute vec3 position;\n\t\tattribute vec2 uv;\n\t\tattribute float faceIndex;\n\n\t\tvarying vec3 vOutputDirection;\n\n\t\t// RH coordinate system; PMREM face-indexing convention\n\t\tvec3 getDirection( vec2 uv, float face ) {\n\n\t\t\tuv = 2.0 * uv - 1.0;\n\n\t\t\tvec3 direction = vec3( uv, 1.0 );\n\n\t\t\tif ( face == 0.0 ) {\n\n\t\t\t\tdirection = direction.zyx; // ( 1, v, u ) pos x\n\n\t\t\t} else if ( face == 1.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xz *= -1.0; // ( -u, 1, -v ) pos y\n\n\t\t\t} else if ( face == 2.0 ) {\n\n\t\t\t\tdirection.x *= -1.0; // ( -u, v, 1 ) pos z\n\n\t\t\t} else if ( face == 3.0 ) {\n\n\t\t\t\tdirection = direction.zyx;\n\t\t\t\tdirection.xz *= -1.0; // ( -1, v, -u ) neg x\n\n\t\t\t} else if ( face == 4.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xy *= -1.0; // ( -u, -1, v ) neg y\n\n\t\t\t} else if ( face == 5.0 ) {\n\n\t\t\t\tdirection.z *= -1.0; // ( u, v, -1 ) neg z\n\n\t\t\t}\n\n\t\t\treturn direction;\n\n\t\t}\n\n\t\tvoid main() {\n\n\t\t\tvOutputDirection = getDirection( uv, faceIndex );\n\t\t\tgl_Position = vec4( position, 1.0 );\n\n\t\t}\n\t",fragmentShader:"\n\n\t\t\tprecision mediump float;\n\t\t\tprecision mediump int;\n\n\t\t\tvarying vec3 vOutputDirection;\n\n\t\t\tuniform sampler2D envMap;\n\t\t\tuniform vec2 texelSize;\n\n\t\t\t\n\n\t\tuniform int inputEncoding;\n\t\tuniform int outputEncoding;\n\n\t\t#include \n\n\t\tvec4 inputTexelToLinear( vec4 value ) {\n\n\t\t\tif ( inputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( inputEncoding == 1 ) {\n\n\t\t\t\treturn sRGBToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 2 ) {\n\n\t\t\t\treturn RGBEToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 3 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 7.0 );\n\n\t\t\t} else if ( inputEncoding == 4 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 16.0 );\n\n\t\t\t} else if ( inputEncoding == 5 ) {\n\n\t\t\t\treturn RGBDToLinear( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn GammaToLinear( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 linearToOutputTexel( vec4 value ) {\n\n\t\t\tif ( outputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( outputEncoding == 1 ) {\n\n\t\t\t\treturn LinearTosRGB( value );\n\n\t\t\t} else if ( outputEncoding == 2 ) {\n\n\t\t\t\treturn LinearToRGBE( value );\n\n\t\t\t} else if ( outputEncoding == 3 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 7.0 );\n\n\t\t\t} else if ( outputEncoding == 4 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 16.0 );\n\n\t\t\t} else if ( outputEncoding == 5 ) {\n\n\t\t\t\treturn LinearToRGBD( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn LinearToGamma( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 envMapTexelToLinear( vec4 color ) {\n\n\t\t\treturn inputTexelToLinear( color );\n\n\t\t}\n\t\n\n\t\t\t#include \n\n\t\t\tvoid main() {\n\n\t\t\t\tgl_FragColor = vec4( 0.0, 0.0, 0.0, 1.0 );\n\n\t\t\t\tvec3 outputDirection = normalize( vOutputDirection );\n\t\t\t\tvec2 uv = equirectUv( outputDirection );\n\n\t\t\t\tvec2 f = fract( uv / texelSize - 0.5 );\n\t\t\t\tuv -= f * texelSize;\n\t\t\t\tvec3 tl = envMapTexelToLinear( texture2D ( envMap, uv ) ).rgb;\n\t\t\t\tuv.x += texelSize.x;\n\t\t\t\tvec3 tr = envMapTexelToLinear( texture2D ( envMap, uv ) ).rgb;\n\t\t\t\tuv.y += texelSize.y;\n\t\t\t\tvec3 br = envMapTexelToLinear( texture2D ( envMap, uv ) ).rgb;\n\t\t\t\tuv.x -= texelSize.x;\n\t\t\t\tvec3 bl = envMapTexelToLinear( texture2D ( envMap, uv ) ).rgb;\n\n\t\t\t\tvec3 tm = mix( tl, tr, f.x );\n\t\t\t\tvec3 bm = mix( bl, br, f.x );\n\t\t\t\tgl_FragColor.rgb = mix( tm, bm, f.y );\n\n\t\t\t\tgl_FragColor = linearToOutputTexel( gl_FragColor );\n\n\t\t\t}\n\t\t",blending:hh,depthTest:!1,depthWrite:!1})}function NB(){return new zy({name:"CubemapToCubeUV",uniforms:{envMap:{value:null},inputEncoding:{value:cp[Ma]},outputEncoding:{value:cp[Ma]}},vertexShader:"\n\n\t\tprecision mediump float;\n\t\tprecision mediump int;\n\n\t\tattribute vec3 position;\n\t\tattribute vec2 uv;\n\t\tattribute float faceIndex;\n\n\t\tvarying vec3 vOutputDirection;\n\n\t\t// RH coordinate system; PMREM face-indexing convention\n\t\tvec3 getDirection( vec2 uv, float face ) {\n\n\t\t\tuv = 2.0 * uv - 1.0;\n\n\t\t\tvec3 direction = vec3( uv, 1.0 );\n\n\t\t\tif ( face == 0.0 ) {\n\n\t\t\t\tdirection = direction.zyx; // ( 1, v, u ) pos x\n\n\t\t\t} else if ( face == 1.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xz *= -1.0; // ( -u, 1, -v ) pos y\n\n\t\t\t} else if ( face == 2.0 ) {\n\n\t\t\t\tdirection.x *= -1.0; // ( -u, v, 1 ) pos z\n\n\t\t\t} else if ( face == 3.0 ) {\n\n\t\t\t\tdirection = direction.zyx;\n\t\t\t\tdirection.xz *= -1.0; // ( -1, v, -u ) neg x\n\n\t\t\t} else if ( face == 4.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xy *= -1.0; // ( -u, -1, v ) neg y\n\n\t\t\t} else if ( face == 5.0 ) {\n\n\t\t\t\tdirection.z *= -1.0; // ( u, v, -1 ) neg z\n\n\t\t\t}\n\n\t\t\treturn direction;\n\n\t\t}\n\n\t\tvoid main() {\n\n\t\t\tvOutputDirection = getDirection( uv, faceIndex );\n\t\t\tgl_Position = vec4( position, 1.0 );\n\n\t\t}\n\t",fragmentShader:"\n\n\t\t\tprecision mediump float;\n\t\t\tprecision mediump int;\n\n\t\t\tvarying vec3 vOutputDirection;\n\n\t\t\tuniform samplerCube envMap;\n\n\t\t\t\n\n\t\tuniform int inputEncoding;\n\t\tuniform int outputEncoding;\n\n\t\t#include \n\n\t\tvec4 inputTexelToLinear( vec4 value ) {\n\n\t\t\tif ( inputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( inputEncoding == 1 ) {\n\n\t\t\t\treturn sRGBToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 2 ) {\n\n\t\t\t\treturn RGBEToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 3 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 7.0 );\n\n\t\t\t} else if ( inputEncoding == 4 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 16.0 );\n\n\t\t\t} else if ( inputEncoding == 5 ) {\n\n\t\t\t\treturn RGBDToLinear( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn GammaToLinear( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 linearToOutputTexel( vec4 value ) {\n\n\t\t\tif ( outputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( outputEncoding == 1 ) {\n\n\t\t\t\treturn LinearTosRGB( value );\n\n\t\t\t} else if ( outputEncoding == 2 ) {\n\n\t\t\t\treturn LinearToRGBE( value );\n\n\t\t\t} else if ( outputEncoding == 3 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 7.0 );\n\n\t\t\t} else if ( outputEncoding == 4 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 16.0 );\n\n\t\t\t} else if ( outputEncoding == 5 ) {\n\n\t\t\t\treturn LinearToRGBD( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn LinearToGamma( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 envMapTexelToLinear( vec4 color ) {\n\n\t\t\treturn inputTexelToLinear( color );\n\n\t\t}\n\t\n\n\t\t\tvoid main() {\n\n\t\t\t\tgl_FragColor = vec4( 0.0, 0.0, 0.0, 1.0 );\n\t\t\t\tgl_FragColor.rgb = envMapTexelToLinear( textureCube( envMap, vec3( - vOutputDirection.x, vOutputDirection.yz ) ) ).rgb;\n\t\t\t\tgl_FragColor = linearToOutputTexel( gl_FragColor );\n\n\t\t\t}\n\t\t",blending:hh,depthTest:!1,depthWrite:!1})}function Iae(n){let e=new WeakMap,t=null;function s(a){const c=a.target;c.removeEventListener("dispose",s);const u=e.get(c);void 0!==u&&(e.delete(c),u.dispose())}return{get:function i(a){if(a&&a.isTexture&&!1===a.isRenderTargetTexture){const c=a.mapping,u=c===WS||c===$S,p=c===Bg||c===Vg;if(u||p){if(e.has(a))return e.get(a).texture;{const g=a.image;if(u&&g&&g.height>0||p&&g&&function r(a){let c=0;for(let p=0;p<6;p++)void 0!==a[p]&&c++;return 6===c}(g)){const v=n.getRenderTarget();null===t&&(t=new Dae(n));const y=u?t.fromEquirectangular(a):t.fromCubemap(a);return e.set(a,y),n.setRenderTarget(v),a.addEventListener("dispose",s),y.texture}return null}}}return a},dispose:function o(){e=new WeakMap,null!==t&&(t.dispose(),t=null)}}}function Fae(n){const e={};function t(i){if(void 0!==e[i])return e[i];let r;switch(i){case"WEBGL_depth_texture":r=n.getExtension("WEBGL_depth_texture")||n.getExtension("MOZ_WEBGL_depth_texture")||n.getExtension("WEBKIT_WEBGL_depth_texture");break;case"EXT_texture_filter_anisotropic":r=n.getExtension("EXT_texture_filter_anisotropic")||n.getExtension("MOZ_EXT_texture_filter_anisotropic")||n.getExtension("WEBKIT_EXT_texture_filter_anisotropic");break;case"WEBGL_compressed_texture_s3tc":r=n.getExtension("WEBGL_compressed_texture_s3tc")||n.getExtension("MOZ_WEBGL_compressed_texture_s3tc")||n.getExtension("WEBKIT_WEBGL_compressed_texture_s3tc");break;case"WEBGL_compressed_texture_pvrtc":r=n.getExtension("WEBGL_compressed_texture_pvrtc")||n.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc");break;default:r=n.getExtension(i)}return e[i]=r,r}return{has:function(i){return null!==t(i)},init:function(i){i.isWebGL2?t("EXT_color_buffer_float"):(t("WEBGL_depth_texture"),t("OES_texture_float"),t("OES_texture_half_float"),t("OES_texture_half_float_linear"),t("OES_standard_derivatives"),t("OES_element_index_uint"),t("OES_vertex_array_object"),t("ANGLE_instanced_arrays")),t("OES_texture_float_linear"),t("EXT_color_buffer_half_float"),t("WEBGL_multisampled_render_to_texture")},get:function(i){const r=t(i);return null===r&&console.warn("THREE.WebGLRenderer: "+i+" extension not supported."),r}}}function Rae(n,e,t,i){const r={},s=new WeakMap;function o(g){const v=g.target;null!==v.index&&e.remove(v.index);for(const x in v.attributes)e.remove(v.attributes[x]);v.removeEventListener("dispose",o),delete r[v.id];const y=s.get(v);y&&(e.remove(y),s.delete(v)),i.releaseStatesOfGeometry(v),!0===v.isInstancedBufferGeometry&&delete v._maxInstanceCount,t.memory.geometries--}function u(g){const v=[],y=g.index,x=g.attributes.position;let T=0;if(null!==y){const A=y.array;T=y.version;for(let H=0,G=A.length;H65535?Xk:Yk)(v,1);N.version=T;const k=s.get(g);k&&e.remove(k),s.set(g,N)}return{get:function a(g,v){return!0===r[v.id]||(v.addEventListener("dispose",o),r[v.id]=!0,t.memory.geometries++),v},update:function c(g){const v=g.attributes;for(const x in v)e.update(v[x],34962);const y=g.morphAttributes;for(const x in y){const T=y[x];for(let N=0,k=T.length;Ne.maxTextureSize&&(he=Math.ceil(K/e.maxTextureSize),K=e.maxTextureSize);const De=new Float32Array(K*he*4*x),Te=new dI(De,K,he,x);Te.format=zo,Te.type=Yd;const ge=4*se;for(let Qe=0;Qe0)return n;const r=e*t;let s=jB[r];if(void 0===s&&(s=new Float32Array(r),jB[r]=s),0!==e){i.toArray(s,0);for(let o=1,a=0;o!==e;++o)a+=t,n[o].toArray(s,a)}return s}function ua(n,e){if(n.length!==e.length)return!1;for(let t=0,i=n.length;t/gm;function hI(n){return n.replace(Oce,Lce)}function Lce(n,e){const t=pi[e];if(void 0===t)throw new Error("Can not resolve #include <"+e+">");return hI(t)}const Nce=/#pragma unroll_loop[\s]+?for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g,Bce=/#pragma unroll_loop_start\s+for\s*\(\s*int\s+i\s*=\s*(\d+)\s*;\s*i\s*<\s*(\d+)\s*;\s*i\s*\+\+\s*\)\s*{([\s\S]+?)}\s+#pragma unroll_loop_end/g;function i6(n){return n.replace(Bce,r6).replace(Nce,Vce)}function Vce(n,e,t,i){return console.warn("WebGLProgram: #pragma unroll_loop shader syntax is deprecated. Please use #pragma unroll_loop_start syntax instead."),r6(0,e,t,i)}function r6(n,e,t,i){let r="";for(let s=parseInt(e);s0?n.gammaFactor:1,y=t.isWebGL2?"":function Fce(n){return[n.extensionDerivatives||n.envMapCubeUV||n.bumpMap||n.tangentSpaceNormalMap||n.clearcoatNormalMap||n.flatShading||"physical"===n.shaderID?"#extension GL_OES_standard_derivatives : enable":"",(n.extensionFragDepth||n.logarithmicDepthBuffer)&&n.rendererExtensionFragDepth?"#extension GL_EXT_frag_depth : enable":"",n.extensionDrawBuffers&&n.rendererExtensionDrawBuffers?"#extension GL_EXT_draw_buffers : require":"",(n.extensionShaderTextureLOD||n.envMap||n.transmission)&&n.rendererExtensionShaderTextureLod?"#extension GL_EXT_shader_texture_lod : enable":""].filter(jy).join("\n")}(t),x=function Rce(n){const e=[];for(const t in n){const i=n[t];!1!==i&&e.push("#define "+t+" "+i)}return e.join("\n")}(s),T=r.createProgram();let N,k,A=t.glslVersion?"#version "+t.glslVersion+"\n":"";t.isRawShaderMaterial?(N=[x].filter(jy).join("\n"),N.length>0&&(N+="\n"),k=[y,x].filter(jy).join("\n"),k.length>0&&(k+="\n")):(N=[s6(t),"#define SHADER_NAME "+t.shaderName,x,t.instancing?"#define USE_INSTANCING":"",t.instancingColor?"#define USE_INSTANCING_COLOR":"",t.supportsVertexTextures?"#define VERTEX_TEXTURES":"","#define GAMMA_FACTOR "+v,"#define MAX_BONES "+t.maxBones,t.useFog&&t.fog?"#define USE_FOG":"",t.useFog&&t.fogExp2?"#define FOG_EXP2":"",t.map?"#define USE_MAP":"",t.envMap?"#define USE_ENVMAP":"",t.envMap?"#define "+p:"",t.lightMap?"#define USE_LIGHTMAP":"",t.aoMap?"#define USE_AOMAP":"",t.emissiveMap?"#define USE_EMISSIVEMAP":"",t.bumpMap?"#define USE_BUMPMAP":"",t.normalMap?"#define USE_NORMALMAP":"",t.normalMap&&t.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",t.normalMap&&t.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",t.clearcoatMap?"#define USE_CLEARCOATMAP":"",t.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",t.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",t.displacementMap&&t.supportsVertexTextures?"#define USE_DISPLACEMENTMAP":"",t.specularMap?"#define USE_SPECULARMAP":"",t.specularIntensityMap?"#define USE_SPECULARINTENSITYMAP":"",t.specularColorMap?"#define USE_SPECULARCOLORMAP":"",t.roughnessMap?"#define USE_ROUGHNESSMAP":"",t.metalnessMap?"#define USE_METALNESSMAP":"",t.alphaMap?"#define USE_ALPHAMAP":"",t.transmission?"#define USE_TRANSMISSION":"",t.transmissionMap?"#define USE_TRANSMISSIONMAP":"",t.thicknessMap?"#define USE_THICKNESSMAP":"",t.sheenColorMap?"#define USE_SHEENCOLORMAP":"",t.sheenRoughnessMap?"#define USE_SHEENROUGHNESSMAP":"",t.vertexTangents?"#define USE_TANGENT":"",t.vertexColors?"#define USE_COLOR":"",t.vertexAlphas?"#define USE_COLOR_ALPHA":"",t.vertexUvs?"#define USE_UV":"",t.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",t.flatShading?"#define FLAT_SHADED":"",t.skinning?"#define USE_SKINNING":"",t.useVertexTexture?"#define BONE_TEXTURE":"",t.morphTargets?"#define USE_MORPHTARGETS":"",t.morphNormals&&!1===t.flatShading?"#define USE_MORPHNORMALS":"",t.morphTargets&&t.isWebGL2?"#define MORPHTARGETS_TEXTURE":"",t.morphTargets&&t.isWebGL2?"#define MORPHTARGETS_COUNT "+t.morphTargetsCount:"",t.doubleSided?"#define DOUBLE_SIDED":"",t.flipSided?"#define FLIP_SIDED":"",t.shadowMapEnabled?"#define USE_SHADOWMAP":"",t.shadowMapEnabled?"#define "+c:"",t.sizeAttenuation?"#define USE_SIZEATTENUATION":"",t.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",t.logarithmicDepthBuffer&&t.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"","uniform mat4 modelMatrix;","uniform mat4 modelViewMatrix;","uniform mat4 projectionMatrix;","uniform mat4 viewMatrix;","uniform mat3 normalMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;","#ifdef USE_INSTANCING","\tattribute mat4 instanceMatrix;","#endif","#ifdef USE_INSTANCING_COLOR","\tattribute vec3 instanceColor;","#endif","attribute vec3 position;","attribute vec3 normal;","attribute vec2 uv;","#ifdef USE_TANGENT","\tattribute vec4 tangent;","#endif","#if defined( USE_COLOR_ALPHA )","\tattribute vec4 color;","#elif defined( USE_COLOR )","\tattribute vec3 color;","#endif","#if ( defined( USE_MORPHTARGETS ) && ! defined( MORPHTARGETS_TEXTURE ) )","\tattribute vec3 morphTarget0;","\tattribute vec3 morphTarget1;","\tattribute vec3 morphTarget2;","\tattribute vec3 morphTarget3;","\t#ifdef USE_MORPHNORMALS","\t\tattribute vec3 morphNormal0;","\t\tattribute vec3 morphNormal1;","\t\tattribute vec3 morphNormal2;","\t\tattribute vec3 morphNormal3;","\t#else","\t\tattribute vec3 morphTarget4;","\t\tattribute vec3 morphTarget5;","\t\tattribute vec3 morphTarget6;","\t\tattribute vec3 morphTarget7;","\t#endif","#endif","#ifdef USE_SKINNING","\tattribute vec4 skinIndex;","\tattribute vec4 skinWeight;","#endif","\n"].filter(jy).join("\n"),k=[y,s6(t),"#define SHADER_NAME "+t.shaderName,x,"#define GAMMA_FACTOR "+v,t.useFog&&t.fog?"#define USE_FOG":"",t.useFog&&t.fogExp2?"#define FOG_EXP2":"",t.map?"#define USE_MAP":"",t.matcap?"#define USE_MATCAP":"",t.envMap?"#define USE_ENVMAP":"",t.envMap?"#define "+u:"",t.envMap?"#define "+p:"",t.envMap?"#define "+g:"",t.lightMap?"#define USE_LIGHTMAP":"",t.aoMap?"#define USE_AOMAP":"",t.emissiveMap?"#define USE_EMISSIVEMAP":"",t.bumpMap?"#define USE_BUMPMAP":"",t.normalMap?"#define USE_NORMALMAP":"",t.normalMap&&t.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",t.normalMap&&t.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",t.clearcoat?"#define USE_CLEARCOAT":"",t.clearcoatMap?"#define USE_CLEARCOATMAP":"",t.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",t.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",t.specularMap?"#define USE_SPECULARMAP":"",t.specularIntensityMap?"#define USE_SPECULARINTENSITYMAP":"",t.specularColorMap?"#define USE_SPECULARCOLORMAP":"",t.roughnessMap?"#define USE_ROUGHNESSMAP":"",t.metalnessMap?"#define USE_METALNESSMAP":"",t.alphaMap?"#define USE_ALPHAMAP":"",t.alphaTest?"#define USE_ALPHATEST":"",t.sheen?"#define USE_SHEEN":"",t.sheenColorMap?"#define USE_SHEENCOLORMAP":"",t.sheenRoughnessMap?"#define USE_SHEENROUGHNESSMAP":"",t.transmission?"#define USE_TRANSMISSION":"",t.transmissionMap?"#define USE_TRANSMISSIONMAP":"",t.thicknessMap?"#define USE_THICKNESSMAP":"",t.vertexTangents?"#define USE_TANGENT":"",t.vertexColors||t.instancingColor?"#define USE_COLOR":"",t.vertexAlphas?"#define USE_COLOR_ALPHA":"",t.vertexUvs?"#define USE_UV":"",t.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",t.gradientMap?"#define USE_GRADIENTMAP":"",t.flatShading?"#define FLAT_SHADED":"",t.doubleSided?"#define DOUBLE_SIDED":"",t.flipSided?"#define FLIP_SIDED":"",t.shadowMapEnabled?"#define USE_SHADOWMAP":"",t.shadowMapEnabled?"#define "+c:"",t.premultipliedAlpha?"#define PREMULTIPLIED_ALPHA":"",t.physicallyCorrectLights?"#define PHYSICALLY_CORRECT_LIGHTS":"",t.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",t.logarithmicDepthBuffer&&t.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"",(t.extensionShaderTextureLOD||t.envMap)&&t.rendererExtensionShaderTextureLod?"#define TEXTURE_LOD_EXT":"","uniform mat4 viewMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;",t.toneMapping!==Qf?"#define TONE_MAPPING":"",t.toneMapping!==Qf?pi.tonemapping_pars_fragment:"",t.toneMapping!==Qf?Ice("toneMapping",t.toneMapping):"",t.dithering?"#define DITHERING":"",t.format===ep?"#define OPAQUE":"",pi.encodings_pars_fragment,t.map?dp("mapTexelToLinear",t.mapEncoding):"",t.matcap?dp("matcapTexelToLinear",t.matcapEncoding):"",t.envMap?dp("envMapTexelToLinear",t.envMapEncoding):"",t.emissiveMap?dp("emissiveMapTexelToLinear",t.emissiveMapEncoding):"",t.specularColorMap?dp("specularColorMapTexelToLinear",t.specularColorMapEncoding):"",t.sheenColorMap?dp("sheenColorMapTexelToLinear",t.sheenColorMapEncoding):"",t.lightMap?dp("lightMapTexelToLinear",t.lightMapEncoding):"",kce("linearToOutputTexel",t.outputEncoding),t.depthPacking?"#define DEPTH_PACKING "+t.depthPacking:"","\n"].filter(jy).join("\n")),o=hI(o),o=t6(o,t),o=n6(o,t),a=hI(a),a=t6(a,t),a=n6(a,t),o=i6(o),a=i6(a),t.isWebGL2&&!0!==t.isRawShaderMaterial&&(A="#version 300 es\n",N=["precision mediump sampler2DArray;","#define attribute in","#define varying out","#define texture2D texture"].join("\n")+"\n"+N,k=["#define varying in",t.glslVersion===uB?"":"out highp vec4 pc_fragColor;",t.glslVersion===uB?"":"#define gl_FragColor pc_fragColor","#define gl_FragDepthEXT gl_FragDepth","#define texture2D texture","#define textureCube texture","#define texture2DProj textureProj","#define texture2DLodEXT textureLod","#define texture2DProjLodEXT textureProjLod","#define textureCubeLodEXT textureLod","#define texture2DGradEXT textureGrad","#define texture2DProjGradEXT textureProjGrad","#define textureCubeGradEXT textureGrad"].join("\n")+"\n"+k);const G=A+k+a,X=JB(r,35633,A+N+o),se=JB(r,35632,G);if(r.attachShader(T,X),r.attachShader(T,se),void 0!==t.index0AttributeName?r.bindAttribLocation(T,0,t.index0AttributeName):!0===t.morphTargets&&r.bindAttribLocation(T,0,"position"),r.linkProgram(T),n.debug.checkShaderErrors){const De=r.getProgramInfoLog(T).trim(),Te=r.getShaderInfoLog(X).trim(),ge=r.getShaderInfoLog(se).trim();let Qe=!0,Pe=!0;if(!1===r.getProgramParameter(T,35714)){Qe=!1;const Oe=e6(r,X,"vertex"),Ve=e6(r,se,"fragment");console.error("THREE.WebGLProgram: Shader Error "+r.getError()+" - VALIDATE_STATUS "+r.getProgramParameter(T,35715)+"\n\nProgram Info Log: "+De+"\n"+Oe+"\n"+Ve)}else""!==De?console.warn("THREE.WebGLProgram: Program Info Log:",De):(""===Te||""===ge)&&(Pe=!1);Pe&&(this.diagnostics={runnable:Qe,programLog:De,vertexShader:{log:Te,prefix:N},fragmentShader:{log:ge,prefix:k}})}let K,he;return r.deleteShader(X),r.deleteShader(se),this.getUniforms=function(){return void 0===K&&(K=new Eh(r,T)),K},this.getAttributes=function(){return void 0===he&&(he=function Pce(n,e){const t={},i=n.getProgramParameter(e,35721);for(let r=0;r0,Ke=K.clearcoat>0;return{isWebGL2:c,shaderID:Ve,shaderName:K.type,vertexShader:Me,fragmentShader:je,defines:K.defines,isRawShaderMaterial:!0===K.isRawShaderMaterial,glslVersion:K.glslVersion,precision:y,instancing:!0===ge.isInstancedMesh,instancingColor:!0===ge.isInstancedMesh&&null!==ge.instanceColor,supportsVertexTextures:v,outputEncoding:null!==lt?k(lt.texture):n.outputEncoding,map:!!K.map,mapEncoding:k(K.map),matcap:!!K.matcap,matcapEncoding:k(K.matcap),envMap:!!Oe,envMapMode:Oe&&Oe.mapping,envMapEncoding:k(Oe),envMapCubeUV:!!Oe&&(Oe.mapping===ky||Oe.mapping===qS),lightMap:!!K.lightMap,lightMapEncoding:k(K.lightMap),aoMap:!!K.aoMap,emissiveMap:!!K.emissiveMap,emissiveMapEncoding:k(K.emissiveMap),bumpMap:!!K.bumpMap,normalMap:!!K.normalMap,objectSpaceNormalMap:K.normalMapType===Hre,tangentSpaceNormalMap:K.normalMapType===$g,clearcoat:Ke,clearcoatMap:Ke&&!!K.clearcoatMap,clearcoatRoughnessMap:Ke&&!!K.clearcoatRoughnessMap,clearcoatNormalMap:Ke&&!!K.clearcoatNormalMap,displacementMap:!!K.displacementMap,roughnessMap:!!K.roughnessMap,metalnessMap:!!K.metalnessMap,specularMap:!!K.specularMap,specularIntensityMap:!!K.specularIntensityMap,specularColorMap:!!K.specularColorMap,specularColorMapEncoding:k(K.specularColorMap),alphaMap:!!K.alphaMap,alphaTest:ze,gradientMap:!!K.gradientMap,sheen:K.sheen>0,sheenColorMap:!!K.sheenColorMap,sheenColorMapEncoding:k(K.sheenColorMap),sheenRoughnessMap:!!K.sheenRoughnessMap,transmission:K.transmission>0,transmissionMap:!!K.transmissionMap,thicknessMap:!!K.thicknessMap,combine:K.combine,vertexTangents:!!K.normalMap&&!!ge.geometry&&!!ge.geometry.attributes.tangent,vertexColors:K.vertexColors,vertexAlphas:!0===K.vertexColors&&!!ge.geometry&&!!ge.geometry.attributes.color&&4===ge.geometry.attributes.color.itemSize,vertexUvs:!!K.map||!!K.bumpMap||!!K.normalMap||!!K.specularMap||!!K.alphaMap||!!K.emissiveMap||!!K.roughnessMap||!!K.metalnessMap||!!K.clearcoatMap||!!K.clearcoatRoughnessMap||!!K.clearcoatNormalMap||!!K.displacementMap||!!K.transmissionMap||!!K.thicknessMap||!!K.specularIntensityMap||!!K.specularColorMap||!!K.sheenColorMap||K.sheenRoughnessMap,uvsVertexOnly:!(K.map||K.bumpMap||K.normalMap||K.specularMap||K.alphaMap||K.emissiveMap||K.roughnessMap||K.metalnessMap||K.clearcoatNormalMap||K.transmission>0||K.transmissionMap||K.thicknessMap||K.specularIntensityMap||K.specularColorMap||K.sheen>0||K.sheenColorMap||K.sheenRoughnessMap||!K.displacementMap),fog:!!Qe,useFog:K.fog,fogExp2:Qe&&Qe.isFogExp2,flatShading:!!K.flatShading,sizeAttenuation:K.sizeAttenuation,logarithmicDepthBuffer:u,skinning:!0===ge.isSkinnedMesh&&ye>0,maxBones:ye,useVertexTexture:p,morphTargets:!!ge.geometry&&!!ge.geometry.morphAttributes.position,morphNormals:!!ge.geometry&&!!ge.geometry.morphAttributes.normal,morphTargetsCount:ge.geometry&&ge.geometry.morphAttributes.position?ge.geometry.morphAttributes.position.length:0,numDirLights:he.directional.length,numPointLights:he.point.length,numSpotLights:he.spot.length,numRectAreaLights:he.rectArea.length,numHemiLights:he.hemi.length,numDirLightShadows:he.directionalShadowMap.length,numPointLightShadows:he.pointShadowMap.length,numSpotLightShadows:he.spotShadowMap.length,numClippingPlanes:o.numPlanes,numClipIntersection:o.numIntersection,format:K.format,dithering:K.dithering,shadowMapEnabled:n.shadowMap.enabled&&De.length>0,shadowMapType:n.shadowMap.type,toneMapping:K.toneMapped?n.toneMapping:Qf,physicallyCorrectLights:n.physicallyCorrectLights,premultipliedAlpha:K.premultipliedAlpha,doubleSided:K.side===Lg,flipSided:K.side===Ds,depthPacking:void 0!==K.depthPacking&&K.depthPacking,index0AttributeName:K.index0AttributeName,extensionDerivatives:K.extensions&&K.extensions.derivatives,extensionFragDepth:K.extensions&&K.extensions.fragDepth,extensionDrawBuffers:K.extensions&&K.extensions.drawBuffers,extensionShaderTextureLOD:K.extensions&&K.extensions.shaderTextureLOD,rendererExtensionFragDepth:c||i.has("EXT_frag_depth"),rendererExtensionDrawBuffers:c||i.has("WEBGL_draw_buffers"),rendererExtensionShaderTextureLod:c||i.has("EXT_shader_texture_lod"),customProgramCacheKey:K.customProgramCacheKey()}},getProgramCacheKey:function H(K){const he=[];if(K.shaderID?he.push(K.shaderID):(he.push(mB(K.fragmentShader)),he.push(mB(K.vertexShader))),void 0!==K.defines)for(const De in K.defines)he.push(De),he.push(K.defines[De]);if(!1===K.isRawShaderMaterial){for(let De=0;De0?r.push(H):!0===T.transparent?s.push(H):i.push(H)},unshift:function p(y,x,T,N,k,A){const H=c(y,x,T,N,k,A);T.transmission>0?r.unshift(H):!0===T.transparent?s.unshift(H):i.unshift(H)},finish:function v(){for(let y=t,x=e.length;y1&&i.sort(y||qce),r.length>1&&r.sort(x||o6),s.length>1&&s.sort(x||o6)}}}function Kce(n){let e=new WeakMap;return{get:function t(r,s){let o;return!1===e.has(r)?(o=new a6(n),e.set(r,[o])):s>=e.get(r).length?(o=new a6(n),e.get(r).push(o)):o=e.get(r)[s],o},dispose:function i(){e=new WeakMap}}}function Yce(){const n={};return{get:function(e){if(void 0!==n[e.id])return n[e.id];let t;switch(e.type){case"DirectionalLight":t={direction:new ne,color:new Rt};break;case"SpotLight":t={position:new ne,direction:new ne,color:new Rt,distance:0,coneCos:0,penumbraCos:0,decay:0};break;case"PointLight":t={position:new ne,color:new Rt,distance:0,decay:0};break;case"HemisphereLight":t={direction:new ne,skyColor:new Rt,groundColor:new Rt};break;case"RectAreaLight":t={color:new Rt,position:new ne,halfWidth:new ne,halfHeight:new ne}}return n[e.id]=t,t}}}let Zce=0;function Jce(n,e){return(e.castShadow?1:0)-(n.castShadow?1:0)}function Qce(n,e){const t=new Yce,i=function Xce(){const n={};return{get:function(e){if(void 0!==n[e.id])return n[e.id];let t;switch(e.type){case"DirectionalLight":case"SpotLight":t={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new tt};break;case"PointLight":t={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new tt,shadowCameraNear:1,shadowCameraFar:1e3}}return n[e.id]=t,t}}}(),r={version:0,hash:{directionalLength:-1,pointLength:-1,spotLength:-1,rectAreaLength:-1,hemiLength:-1,numDirectionalShadows:-1,numPointShadows:-1,numSpotShadows:-1},ambient:[0,0,0],probe:[],directional:[],directionalShadow:[],directionalShadowMap:[],directionalShadowMatrix:[],spot:[],spotShadow:[],spotShadowMap:[],spotShadowMatrix:[],rectArea:[],rectAreaLTC1:null,rectAreaLTC2:null,point:[],pointShadow:[],pointShadowMap:[],pointShadowMatrix:[],hemi:[]};for(let p=0;p<9;p++)r.probe.push(new ne);const s=new ne,o=new Gt,a=new Gt;return{setup:function c(p,g){let v=0,y=0,x=0;for(let De=0;De<9;De++)r.probe[De].set(0,0,0);let T=0,N=0,k=0,A=0,H=0,G=0,X=0,se=0;p.sort(Jce);const K=!0!==g?Math.PI:1;for(let De=0,Te=p.length;De0&&(e.isWebGL2||!0===n.has("OES_texture_float_linear")?(r.rectAreaLTC1=Ct.LTC_FLOAT_1,r.rectAreaLTC2=Ct.LTC_FLOAT_2):!0===n.has("OES_texture_half_float_linear")?(r.rectAreaLTC1=Ct.LTC_HALF_1,r.rectAreaLTC2=Ct.LTC_HALF_2):console.error("THREE.WebGLRenderer: Unable to use RectAreaLight. Missing WebGL extensions.")),r.ambient[0]=v,r.ambient[1]=y,r.ambient[2]=x;const he=r.hash;(he.directionalLength!==T||he.pointLength!==N||he.spotLength!==k||he.rectAreaLength!==A||he.hemiLength!==H||he.numDirectionalShadows!==G||he.numPointShadows!==X||he.numSpotShadows!==se)&&(r.directional.length=T,r.spot.length=k,r.rectArea.length=A,r.point.length=N,r.hemi.length=H,r.directionalShadow.length=G,r.directionalShadowMap.length=G,r.pointShadow.length=X,r.pointShadowMap.length=X,r.spotShadow.length=se,r.spotShadowMap.length=se,r.directionalShadowMatrix.length=G,r.pointShadowMatrix.length=X,r.spotShadowMatrix.length=se,he.directionalLength=T,he.pointLength=N,he.spotLength=k,he.rectAreaLength=A,he.hemiLength=H,he.numDirectionalShadows=G,he.numPointShadows=X,he.numSpotShadows=se,r.version=Zce++)},setupView:function u(p,g){let v=0,y=0,x=0,T=0,N=0;const k=g.matrixWorldInverse;for(let A=0,H=p.length;A=t.get(s).length?(a=new c6(n,e),t.get(s).push(a)):a=t.get(s)[o],a},dispose:function r(){t=new WeakMap}}}class fI extends Co{constructor(e){super(),this.type="MeshDepthMaterial",this.depthPacking=3200,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.setValues(e)}copy(e){return super.copy(e),this.depthPacking=e.depthPacking,this.map=e.map,this.alphaMap=e.alphaMap,this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this}}fI.prototype.isMeshDepthMaterial=!0;class pI extends Co{constructor(e){super(),this.type="MeshDistanceMaterial",this.referencePosition=new ne,this.nearDistance=1,this.farDistance=1e3,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.fog=!1,this.setValues(e)}copy(e){return super.copy(e),this.referencePosition.copy(e.referencePosition),this.nearDistance=e.nearDistance,this.farDistance=e.farDistance,this.map=e.map,this.alphaMap=e.alphaMap,this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this}}pI.prototype.isMeshDistanceMaterial=!0;const tle="void main() {\n\tgl_Position = vec4( position, 1.0 );\n}",nle="uniform sampler2D shadow_pass;\nuniform vec2 resolution;\nuniform float radius;\n#include \nvoid main() {\n\tconst float samples = float( VSM_SAMPLES );\n\tfloat mean = 0.0;\n\tfloat squared_mean = 0.0;\n\tfloat uvStride = samples <= 1.0 ? 0.0 : 2.0 / ( samples - 1.0 );\n\tfloat uvStart = samples <= 1.0 ? 0.0 : - 1.0;\n\tfor ( float i = 0.0; i < samples; i ++ ) {\n\t\tfloat uvOffset = uvStart + i * uvStride;\n\t\t#ifdef HORIZONTAL_PASS\n\t\t\tvec2 distribution = unpackRGBATo2Half( texture2D( shadow_pass, ( gl_FragCoord.xy + vec2( uvOffset, 0.0 ) * radius ) / resolution ) );\n\t\t\tmean += distribution.x;\n\t\t\tsquared_mean += distribution.y * distribution.y + distribution.x * distribution.x;\n\t\t#else\n\t\t\tfloat depth = unpackRGBAToDepth( texture2D( shadow_pass, ( gl_FragCoord.xy + vec2( 0.0, uvOffset ) * radius ) / resolution ) );\n\t\t\tmean += depth;\n\t\t\tsquared_mean += depth * depth;\n\t\t#endif\n\t}\n\tmean = mean / samples;\n\tsquared_mean = squared_mean / samples;\n\tfloat std_dev = sqrt( squared_mean - mean * mean );\n\tgl_FragColor = pack2HalfToRGBA( vec2( mean, std_dev ) );\n}";function l6(n,e,t){let i=new w2;const r=new tt,s=new tt,o=new tr,a=new fI({depthPacking:Vre}),c=new pI,u={},p=t.maxTextureSize,g={0:Ds,1:Og,2:Lg},v=new wh({defines:{VSM_SAMPLES:8},uniforms:{shadow_pass:{value:null},resolution:{value:new tt},radius:{value:4}},vertexShader:tle,fragmentShader:nle}),y=v.clone();y.defines.HORIZONTAL_PASS=1;const x=new gn;x.setAttribute("position",new zi(new Float32Array([-1,-1,.5,3,-1,.5,-1,3,.5]),3));const T=new vr(x,v),N=this;function k(G,X){const se=e.update(T);v.defines.VSM_SAMPLES!==G.blurSamples&&(v.defines.VSM_SAMPLES=G.blurSamples,y.defines.VSM_SAMPLES=G.blurSamples,v.needsUpdate=!0,y.needsUpdate=!0),v.uniforms.shadow_pass.value=G.map.texture,v.uniforms.resolution.value=G.mapSize,v.uniforms.radius.value=G.radius,n.setRenderTarget(G.mapPass),n.clear(),n.renderBufferDirect(X,null,se,v,T,null),y.uniforms.shadow_pass.value=G.mapPass.texture,y.uniforms.resolution.value=G.mapSize,y.uniforms.radius.value=G.radius,n.setRenderTarget(G.map),n.clear(),n.renderBufferDirect(X,null,se,y,T,null)}function A(G,X,se,K,he,De,Te){let ge=null;const Qe=!0===K.isPointLight?G.customDistanceMaterial:G.customDepthMaterial;if(ge=void 0!==Qe?Qe:!0===K.isPointLight?c:a,n.localClippingEnabled&&!0===se.clipShadows&&0!==se.clippingPlanes.length||se.displacementMap&&0!==se.displacementScale||se.alphaMap&&se.alphaTest>0){const Pe=ge.uuid,Oe=se.uuid;let Ve=u[Pe];void 0===Ve&&(Ve={},u[Pe]=Ve);let ye=Ve[Oe];void 0===ye&&(ye=ge.clone(),Ve[Oe]=ye),ge=ye}return ge.visible=se.visible,ge.wireframe=se.wireframe,ge.side=Te===Ty?null!==se.shadowSide?se.shadowSide:se.side:null!==se.shadowSide?se.shadowSide:g[se.side],ge.alphaMap=se.alphaMap,ge.alphaTest=se.alphaTest,ge.clipShadows=se.clipShadows,ge.clippingPlanes=se.clippingPlanes,ge.clipIntersection=se.clipIntersection,ge.displacementMap=se.displacementMap,ge.displacementScale=se.displacementScale,ge.displacementBias=se.displacementBias,ge.wireframeLinewidth=se.wireframeLinewidth,ge.linewidth=se.linewidth,!0===K.isPointLight&&!0===ge.isMeshDistanceMaterial&&(ge.referencePosition.setFromMatrixPosition(K.matrixWorld),ge.nearDistance=he,ge.farDistance=De),ge}function H(G,X,se,K,he){if(!1===G.visible)return;if(G.layers.test(X.layers)&&(G.isMesh||G.isLine||G.isPoints)&&(G.castShadow||G.receiveShadow&&he===Ty)&&(!G.frustumCulled||i.intersectsObject(G))){G.modelViewMatrix.multiplyMatrices(se.matrixWorldInverse,G.matrixWorld);const ge=e.update(G),Qe=G.material;if(Array.isArray(Qe)){const Pe=ge.groups;for(let Oe=0,Ve=Pe.length;Oep||r.y>p)&&(r.x>p&&(s.x=Math.floor(p/Ve.x),r.x=s.x*Ve.x,Oe.mapSize.x=s.x),r.y>p&&(s.y=Math.floor(p/Ve.y),r.y=s.y*Ve.y,Oe.mapSize.y=s.y)),null===Oe.map&&!Oe.isPointLightShadow&&this.type===Ty){const Me={minFilter:no,magFilter:no,format:zo};Oe.map=new Bc(r.x,r.y,Me),Oe.map.texture.name=Pe.name+".shadowMap",Oe.mapPass=new Bc(r.x,r.y,Me),Oe.camera.updateProjectionMatrix()}null===Oe.map&&(Oe.map=new Bc(r.x,r.y,{minFilter:Gs,magFilter:Gs,format:zo}),Oe.map.texture.name=Pe.name+".shadowMap",Oe.camera.updateProjectionMatrix()),n.setRenderTarget(Oe.map),n.clear();const ye=Oe.getViewportCount();for(let Me=0;Me=1):-1!==Oe.indexOf("OpenGL ES")&&(Pe=parseFloat(/^OpenGL ES (\d)/.exec(Oe)[1]),Qe=Pe>=2);let Ve=null,ye={};const Me=n.getParameter(3088),je=n.getParameter(2978),lt=(new tr).fromArray(Me),ze=(new tr).fromArray(je);function Ke(Ce,St,at){const kt=new Uint8Array(4),Et=n.createTexture();n.bindTexture(Ce,Et),n.texParameteri(Ce,10241,9728),n.texParameteri(Ce,10240,9728);for(let zt=0;ztst||fe.height>st)&&(Kt=st/Math.max(fe.width,fe.height)),Kt<1||!0===ae){if(typeof HTMLImageElement<"u"&&fe instanceof HTMLImageElement||typeof HTMLCanvasElement<"u"&&fe instanceof HTMLCanvasElement||typeof ImageBitmap<"u"&&fe instanceof ImageBitmap){const Wt=ae?fB:Math.floor,Ce=Wt(Kt*fe.width),St=Wt(Kt*fe.height);void 0===T&&(T=k(Ce,St));const at=ot?k(Ce,St):T;return at.width=Ce,at.height=St,at.getContext("2d").drawImage(fe,0,0,Ce,St),console.warn("THREE.WebGLRenderer: Texture has been resized from ("+fe.width+"x"+fe.height+") to ("+Ce+"x"+St+")."),at}return"data"in fe&&console.warn("THREE.WebGLRenderer: Image in DataTexture is too big ("+fe.width+"x"+fe.height+")."),fe}return fe}function H(fe){return Ik(fe.width)&&Ik(fe.height)}function X(fe,ae){return fe.generateMipmaps&&ae&&fe.minFilter!==Gs&&fe.minFilter!==no}function se(fe){n.generateMipmap(fe)}function K(fe,ae,ot){if(!1===a)return ae;if(null!==fe){if(void 0!==n[fe])return n[fe];console.warn("THREE.WebGLRenderer: Attempt to use non-existing WebGL internal format '"+fe+"'")}let st=ae;return 6403===ae&&(5126===ot&&(st=33326),5131===ot&&(st=33325),5121===ot&&(st=33321)),6407===ae&&(5126===ot&&(st=34837),5131===ot&&(st=34843),5121===ot&&(st=32849)),6408===ae&&(5126===ot&&(st=34836),5131===ot&&(st=34842),5121===ot&&(st=32856)),(33325===st||33326===st||34842===st||34836===st)&&e.get("EXT_color_buffer_float"),st}function De(fe){return fe===Gs||fe===Sk||fe===Ek?9728:9729}function Te(fe){const ae=fe.target;ae.removeEventListener("dispose",Te),function Qe(fe){const ae=i.get(fe);void 0!==ae.__webglInit&&(n.deleteTexture(ae.__webglTexture),i.remove(fe))}(ae),ae.isVideoTexture&&x.delete(ae),o.memory.textures--}function ge(fe){const ae=fe.target;ae.removeEventListener("dispose",ge),function Pe(fe){const ae=fe.texture,ot=i.get(fe),st=i.get(ae);if(fe){if(void 0!==st.__webglTexture&&(n.deleteTexture(st.__webglTexture),o.memory.textures--),fe.depthTexture&&fe.depthTexture.dispose(),fe.isWebGLCubeRenderTarget)for(let Kt=0;Kt<6;Kt++)n.deleteFramebuffer(ot.__webglFramebuffer[Kt]),ot.__webglDepthbuffer&&n.deleteRenderbuffer(ot.__webglDepthbuffer[Kt]);else n.deleteFramebuffer(ot.__webglFramebuffer),ot.__webglDepthbuffer&&n.deleteRenderbuffer(ot.__webglDepthbuffer),ot.__webglMultisampledFramebuffer&&n.deleteFramebuffer(ot.__webglMultisampledFramebuffer),ot.__webglColorRenderbuffer&&n.deleteRenderbuffer(ot.__webglColorRenderbuffer),ot.__webglDepthRenderbuffer&&n.deleteRenderbuffer(ot.__webglDepthRenderbuffer);if(fe.isWebGLMultipleRenderTargets)for(let Kt=0,Wt=ae.length;Kt0&&ot.__version!==fe.version){const st=fe.image;if(void 0===st)console.warn("THREE.WebGLRenderer: Texture marked for update but image is undefined");else{if(!1!==st.complete)return void mi(ot,fe,ae);console.warn("THREE.WebGLRenderer: Texture marked for update but image is incomplete")}}t.activeTexture(33984+ae),t.bindTexture(3553,ot.__webglTexture)}function ze(fe,ae){const ot=i.get(fe);fe.version>0&&ot.__version!==fe.version?function ct(fe,ae,ot){if(6!==ae.image.length)return;gt(fe,ae),t.activeTexture(33984+ot),t.bindTexture(34067,fe.__webglTexture),n.pixelStorei(37440,ae.flipY),n.pixelStorei(37441,ae.premultiplyAlpha),n.pixelStorei(3317,ae.unpackAlignment),n.pixelStorei(37443,0);const st=ae&&(ae.isCompressedTexture||ae.image[0].isCompressedTexture),Kt=ae.image[0]&&ae.image[0].isDataTexture,Wt=[];for(let Yt=0;Yt<6;Yt++)Wt[Yt]=st||Kt?Kt?ae.image[Yt].image:ae.image[Yt]:A(ae.image[Yt],!1,!0,u);const St=H(Wt[0])||a,at=s.convert(ae.format),kt=s.convert(ae.type),Et=K(ae.internalFormat,at,kt);let zt;if(yt(34067,ae,St),st)for(let Yt=0;Yt<6;Yt++){zt=Wt[Yt].mipmaps;for(let ni=0;ni1||i.get(ae).__currentAnisotropy)&&(n.texParameterf(fe,st.TEXTURE_MAX_ANISOTROPY_EXT,Math.min(ae.anisotropy,r.getMaxAnisotropy())),i.get(ae).__currentAnisotropy=ae.anisotropy)}}function gt(fe,ae){void 0===fe.__webglInit&&(fe.__webglInit=!0,ae.addEventListener("dispose",Te),fe.__webglTexture=n.createTexture(),o.memory.textures++)}function mi(fe,ae,ot){let st=3553;ae.isDataTexture2DArray&&(st=35866),ae.isDataTexture3D&&(st=32879),gt(fe,ae),t.activeTexture(33984+ot),t.bindTexture(st,fe.__webglTexture),n.pixelStorei(37440,ae.flipY),n.pixelStorei(37441,ae.premultiplyAlpha),n.pixelStorei(3317,ae.unpackAlignment),n.pixelStorei(37443,0);const Kt=function G(fe){return!a&&(fe.wrapS!==Uo||fe.wrapT!==Uo||fe.minFilter!==Gs&&fe.minFilter!==no)}(ae)&&!1===H(ae.image),Wt=A(ae.image,Kt,!1,p),Ce=H(Wt)||a,St=s.convert(ae.format);let Et,at=s.convert(ae.type),kt=K(ae.internalFormat,St,at);yt(st,ae,Ce);const zt=ae.mipmaps;if(ae.isDepthTexture)kt=6402,a?kt=ae.type===Yd?36012:ae.type===XS?33190:ae.type===zg?35056:33189:ae.type===Yd&&console.error("WebGLRenderer: Floating point depth texture requires WebGL2."),ae.format===tp&&6402===kt&&ae.type!==Iy&&ae.type!==XS&&(console.warn("THREE.WebGLRenderer: Use UnsignedShortType or UnsignedIntType for DepthFormat DepthTexture."),ae.type=Iy,at=s.convert(ae.type)),ae.format===Gg&&6402===kt&&(kt=34041,ae.type!==zg&&(console.warn("THREE.WebGLRenderer: Use UnsignedInt248Type for DepthStencilFormat DepthTexture."),ae.type=zg,at=s.convert(ae.type))),t.texImage2D(3553,0,kt,Wt.width,Wt.height,0,St,at,null);else if(ae.isDataTexture)if(zt.length>0&&Ce){for(let Yt=0,ni=zt.length;Yt0?fe.mipmaps.length:1}(ae,Wt,Ce),ni=a&&!0!==ae.isVideoTexture,fs=void 0===fe.__version;if(zt.length>0&&Ce){ni&&fs&&t.texStorage2D(3553,Yt,kt,zt[0].width,zt[0].height);for(let Gi=0,bl=zt.length;Gi=c&&console.warn("THREE.WebGLTextures: Trying to use "+fe+" texture units while this GPU supports only "+c),Oe+=1,fe},this.resetTextureUnits=function Ve(){Oe=0},this.setTexture2D=Me,this.setTexture2DArray=function je(fe,ae){const ot=i.get(fe);fe.version>0&&ot.__version!==fe.version?mi(ot,fe,ae):(t.activeTexture(33984+ae),t.bindTexture(35866,ot.__webglTexture))},this.setTexture3D=function lt(fe,ae){const ot=i.get(fe);fe.version>0&&ot.__version!==fe.version?mi(ot,fe,ae):(t.activeTexture(33984+ae),t.bindTexture(32879,ot.__webglTexture))},this.setTextureCube=ze,this.rebindTextures=function gi(fe,ae,ot){const st=i.get(fe);void 0!==ae&&Qt(st.__webglFramebuffer,fe,fe.texture,36064,3553),void 0!==ot&&on(fe)},this.setupRenderTarget=function Xe(fe){const ae=fe.texture,ot=i.get(fe),st=i.get(ae);fe.addEventListener("dispose",ge),!0!==fe.isWebGLMultipleRenderTargets&&(void 0===st.__webglTexture&&(st.__webglTexture=n.createTexture()),st.__version=ae.version,o.memory.textures++);const Kt=!0===fe.isWebGLCubeRenderTarget,Wt=!0===fe.isWebGLMultipleRenderTargets,Ce=ae.isDataTexture3D||ae.isDataTexture2DArray,St=H(fe)||a;if(a&&ae.format===ep&&(ae.type===Yd||ae.type===Ug)&&(ae.format=zo,console.warn("THREE.WebGLRenderer: Rendering to textures with RGB format is not supported. Using RGBA format instead.")),Kt){ot.__webglFramebuffer=[];for(let at=0;at<6;at++)ot.__webglFramebuffer[at]=n.createFramebuffer()}else if(ot.__webglFramebuffer=n.createFramebuffer(),Wt)if(r.drawBuffers){const at=fe.texture;for(let kt=0,Et=at.length;kty+x?(u.inputState.pinching=!1,this.dispatchEvent({type:"pinchend",handedness:e.handedness,target:this})):!u.inputState.pinching&&v<=y-x&&(u.inputState.pinching=!0,this.dispatchEvent({type:"pinchstart",handedness:e.handedness,target:this}))}else null!==c&&e.gripSpace&&(s=t.getPose(e.gripSpace,i),null!==s&&(c.matrix.fromArray(s.transform.matrix),c.matrix.decompose(c.position,c.rotation,c.scale),s.linearVelocity?(c.hasLinearVelocity=!0,c.linearVelocity.copy(s.linearVelocity)):c.hasLinearVelocity=!1,s.angularVelocity?(c.hasAngularVelocity=!0,c.angularVelocity.copy(s.angularVelocity)):c.hasAngularVelocity=!1));return null!==a&&(a.visible=null!==r),null!==c&&(c.visible=null!==s),null!==u&&(u.visible=null!==o),this}}class gI extends io{constructor(e,t,i,r,s,o,a,c,u,p){if((p=void 0!==p?p:tp)!==tp&&p!==Gg)throw new Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");void 0===i&&p===tp&&(i=Iy),void 0===i&&p===Gg&&(i=zg),super(null,r,s,o,a,c,p,i,u),this.image={width:e,height:t},this.magFilter=void 0!==a?a:Gs,this.minFilter=void 0!==c?c:Gs,this.flipY=!1,this.generateMipmaps=!1}}gI.prototype.isDepthTexture=!0;class ale extends np{constructor(e,t){super();const i=this;let r=null,s=1,o=null,a="local-floor";const c=e.extensions.has("WEBGL_multisampled_render_to_texture");let u=null,p=null,g=null,v=null,y=!1,x=null;const T=t.getContextAttributes();let N=null,k=null;const A=[],H=new Map,G=new Do;G.layers.enable(1),G.viewport=new tr;const X=new Do;X.layers.enable(2),X.viewport=new tr;const se=[G,X],K=new d6;K.layers.enable(1),K.layers.enable(2);let he=null,De=null;function Te(ze){const Ke=H.get(ze.inputSource);Ke&&Ke.dispatchEvent({type:ze.type,data:ze.inputSource})}function ge(){H.forEach(function(ze,Ke){ze.disconnect(Ke)}),H.clear(),he=null,De=null,e.setRenderTarget(N),v=null,g=null,p=null,r=null,k=null,lt.stop(),i.isPresenting=!1,i.dispatchEvent({type:"sessionend"})}function Qe(ze){const Ke=r.inputSources;for(let vt=0;vt0&&(k.alphaTest.value=A.alphaTest);const H=n.get(A).envMap;let G,X;H&&(k.envMap.value=H,k.flipEnvMap.value=H.isCubeTexture&&!1===H.isRenderTargetTexture?-1:1,k.reflectivity.value=A.reflectivity,k.ior.value=A.ior,k.refractionRatio.value=A.refractionRatio),A.lightMap&&(k.lightMap.value=A.lightMap,k.lightMapIntensity.value=A.lightMapIntensity),A.aoMap&&(k.aoMap.value=A.aoMap,k.aoMapIntensity.value=A.aoMapIntensity),A.map?G=A.map:A.specularMap?G=A.specularMap:A.displacementMap?G=A.displacementMap:A.normalMap?G=A.normalMap:A.bumpMap?G=A.bumpMap:A.roughnessMap?G=A.roughnessMap:A.metalnessMap?G=A.metalnessMap:A.alphaMap?G=A.alphaMap:A.emissiveMap?G=A.emissiveMap:A.clearcoatMap?G=A.clearcoatMap:A.clearcoatNormalMap?G=A.clearcoatNormalMap:A.clearcoatRoughnessMap?G=A.clearcoatRoughnessMap:A.specularIntensityMap?G=A.specularIntensityMap:A.specularColorMap?G=A.specularColorMap:A.transmissionMap?G=A.transmissionMap:A.thicknessMap?G=A.thicknessMap:A.sheenColorMap?G=A.sheenColorMap:A.sheenRoughnessMap&&(G=A.sheenRoughnessMap),void 0!==G&&(G.isWebGLRenderTarget&&(G=G.texture),!0===G.matrixAutoUpdate&&G.updateMatrix(),k.uvTransform.value.copy(G.matrix)),A.aoMap?X=A.aoMap:A.lightMap&&(X=A.lightMap),void 0!==X&&(X.isWebGLRenderTarget&&(X=X.texture),!0===X.matrixAutoUpdate&&X.updateMatrix(),k.uv2Transform.value.copy(X.matrix))}function g(k,A){k.roughness.value=A.roughness,k.metalness.value=A.metalness,A.roughnessMap&&(k.roughnessMap.value=A.roughnessMap),A.metalnessMap&&(k.metalnessMap.value=A.metalnessMap),A.emissiveMap&&(k.emissiveMap.value=A.emissiveMap),A.bumpMap&&(k.bumpMap.value=A.bumpMap,k.bumpScale.value=A.bumpScale,A.side===Ds&&(k.bumpScale.value*=-1)),A.normalMap&&(k.normalMap.value=A.normalMap,k.normalScale.value.copy(A.normalScale),A.side===Ds&&k.normalScale.value.negate()),A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias),n.get(A).envMap&&(k.envMapIntensity.value=A.envMapIntensity)}return{refreshFogUniforms:function e(k,A){k.fogColor.value.copy(A.color),A.isFog?(k.fogNear.value=A.near,k.fogFar.value=A.far):A.isFogExp2&&(k.fogDensity.value=A.density)},refreshMaterialUniforms:function t(k,A,H,G,X){A.isMeshBasicMaterial?i(k,A):A.isMeshLambertMaterial?(i(k,A),function c(k,A){A.emissiveMap&&(k.emissiveMap.value=A.emissiveMap)}(k,A)):A.isMeshToonMaterial?(i(k,A),function p(k,A){A.gradientMap&&(k.gradientMap.value=A.gradientMap),A.emissiveMap&&(k.emissiveMap.value=A.emissiveMap),A.bumpMap&&(k.bumpMap.value=A.bumpMap,k.bumpScale.value=A.bumpScale,A.side===Ds&&(k.bumpScale.value*=-1)),A.normalMap&&(k.normalMap.value=A.normalMap,k.normalScale.value.copy(A.normalScale),A.side===Ds&&k.normalScale.value.negate()),A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias)}(k,A)):A.isMeshPhongMaterial?(i(k,A),function u(k,A){k.specular.value.copy(A.specular),k.shininess.value=Math.max(A.shininess,1e-4),A.emissiveMap&&(k.emissiveMap.value=A.emissiveMap),A.bumpMap&&(k.bumpMap.value=A.bumpMap,k.bumpScale.value=A.bumpScale,A.side===Ds&&(k.bumpScale.value*=-1)),A.normalMap&&(k.normalMap.value=A.normalMap,k.normalScale.value.copy(A.normalScale),A.side===Ds&&k.normalScale.value.negate()),A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias)}(k,A)):A.isMeshStandardMaterial?(i(k,A),A.isMeshPhysicalMaterial?function v(k,A,H){g(k,A),k.ior.value=A.ior,A.sheen>0&&(k.sheenColor.value.copy(A.sheenColor).multiplyScalar(A.sheen),k.sheenRoughness.value=A.sheenRoughness,A.sheenColorMap&&(k.sheenColorMap.value=A.sheenColorMap),A.sheenRoughnessMap&&(k.sheenRoughnessMap.value=A.sheenRoughnessMap)),A.clearcoat>0&&(k.clearcoat.value=A.clearcoat,k.clearcoatRoughness.value=A.clearcoatRoughness,A.clearcoatMap&&(k.clearcoatMap.value=A.clearcoatMap),A.clearcoatRoughnessMap&&(k.clearcoatRoughnessMap.value=A.clearcoatRoughnessMap),A.clearcoatNormalMap&&(k.clearcoatNormalScale.value.copy(A.clearcoatNormalScale),k.clearcoatNormalMap.value=A.clearcoatNormalMap,A.side===Ds&&k.clearcoatNormalScale.value.negate())),A.transmission>0&&(k.transmission.value=A.transmission,k.transmissionSamplerMap.value=H.texture,k.transmissionSamplerSize.value.set(H.width,H.height),A.transmissionMap&&(k.transmissionMap.value=A.transmissionMap),k.thickness.value=A.thickness,A.thicknessMap&&(k.thicknessMap.value=A.thicknessMap),k.attenuationDistance.value=A.attenuationDistance,k.attenuationColor.value.copy(A.attenuationColor)),k.specularIntensity.value=A.specularIntensity,k.specularColor.value.copy(A.specularColor),A.specularIntensityMap&&(k.specularIntensityMap.value=A.specularIntensityMap),A.specularColorMap&&(k.specularColorMap.value=A.specularColorMap)}(k,A,X):g(k,A)):A.isMeshMatcapMaterial?(i(k,A),function y(k,A){A.matcap&&(k.matcap.value=A.matcap),A.bumpMap&&(k.bumpMap.value=A.bumpMap,k.bumpScale.value=A.bumpScale,A.side===Ds&&(k.bumpScale.value*=-1)),A.normalMap&&(k.normalMap.value=A.normalMap,k.normalScale.value.copy(A.normalScale),A.side===Ds&&k.normalScale.value.negate()),A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias)}(k,A)):A.isMeshDepthMaterial?(i(k,A),function x(k,A){A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias)}(k,A)):A.isMeshDistanceMaterial?(i(k,A),function T(k,A){A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias),k.referencePosition.value.copy(A.referencePosition),k.nearDistance.value=A.nearDistance,k.farDistance.value=A.farDistance}(k,A)):A.isMeshNormalMaterial?(i(k,A),function N(k,A){A.bumpMap&&(k.bumpMap.value=A.bumpMap,k.bumpScale.value=A.bumpScale,A.side===Ds&&(k.bumpScale.value*=-1)),A.normalMap&&(k.normalMap.value=A.normalMap,k.normalScale.value.copy(A.normalScale),A.side===Ds&&k.normalScale.value.negate()),A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias)}(k,A)):A.isLineBasicMaterial?(function r(k,A){k.diffuse.value.copy(A.color),k.opacity.value=A.opacity}(k,A),A.isLineDashedMaterial&&function s(k,A){k.dashSize.value=A.dashSize,k.totalSize.value=A.dashSize+A.gapSize,k.scale.value=A.scale}(k,A)):A.isPointsMaterial?function o(k,A,H,G){let X;k.diffuse.value.copy(A.color),k.opacity.value=A.opacity,k.size.value=A.size*H,k.scale.value=.5*G,A.map&&(k.map.value=A.map),A.alphaMap&&(k.alphaMap.value=A.alphaMap),A.alphaTest>0&&(k.alphaTest.value=A.alphaTest),A.map?X=A.map:A.alphaMap&&(X=A.alphaMap),void 0!==X&&(!0===X.matrixAutoUpdate&&X.updateMatrix(),k.uvTransform.value.copy(X.matrix))}(k,A,H,G):A.isSpriteMaterial?function a(k,A){let H;k.diffuse.value.copy(A.color),k.opacity.value=A.opacity,k.rotation.value=A.rotation,A.map&&(k.map.value=A.map),A.alphaMap&&(k.alphaMap.value=A.alphaMap),A.alphaTest>0&&(k.alphaTest.value=A.alphaTest),A.map?H=A.map:A.alphaMap&&(H=A.alphaMap),void 0!==H&&(!0===H.matrixAutoUpdate&&H.updateMatrix(),k.uvTransform.value.copy(H.matrix))}(k,A):A.isShadowMaterial?(k.color.value.copy(A.color),k.opacity.value=A.opacity):A.isShaderMaterial&&(A.uniformsNeedUpdate=!1)}}}function nr(n={}){const e=void 0!==n.canvas?n.canvas:function lle(){const n=n2("canvas");return n.style.display="block",n}(),t=void 0!==n.context?n.context:null,i=void 0!==n.alpha&&n.alpha,r=void 0===n.depth||n.depth,s=void 0===n.stencil||n.stencil,o=void 0!==n.antialias&&n.antialias,a=void 0===n.premultipliedAlpha||n.premultipliedAlpha,c=void 0!==n.preserveDrawingBuffer&&n.preserveDrawingBuffer,u=void 0!==n.powerPreference?n.powerPreference:"default",p=void 0!==n.failIfMajorPerformanceCaveat&&n.failIfMajorPerformanceCaveat;let g=null,v=null;const y=[],x=[];this.domElement=e,this.debug={checkShaderErrors:!0},this.autoClear=!0,this.autoClearColor=!0,this.autoClearDepth=!0,this.autoClearStencil=!0,this.sortObjects=!0,this.clippingPlanes=[],this.localClippingEnabled=!1,this.gammaFactor=2,this.outputEncoding=Ma,this.physicallyCorrectLights=!1,this.toneMapping=Qf,this.toneMappingExposure=1;const T=this;let N=!1,k=0,A=0,H=null,G=-1,X=null;const se=new tr,K=new tr;let he=null,De=e.width,Te=e.height,ge=1,Qe=null,Pe=null;const Oe=new tr(0,0,De,Te),Ve=new tr(0,0,De,Te);let ye=!1;const Me=[],je=new w2;let lt=!1,ze=!1,Ke=null;const vt=new Gt,yt=new ne,gt={background:null,fog:null,environment:null,overrideMaterial:null,isScene:!0};function mi(){return null===H?ge:1}let sn,It,on,gi,Xe,ht,bt,Vt,At,Wn,$n,xi,xr,fe,ae,ot,st,Kt,Wt,Ce,St,at,kt,ct=t;function Qt(oe,Re){for(let We=0;We0&&function Cue(oe,Re,We){null===Ke&&(Ke=new(!0===o&&!0===It.isWebGL2?Rk:Bc)(1024,1024,{generateMipmaps:!0,type:null!==at.convert(Ug)?Ug:fh,minFilter:Hg,magFilter:Gs,wrapS:Uo,wrapT:Uo,useRenderToTexture:sn.has("WEBGL_multisampled_render_to_texture")}));const Be=T.getRenderTarget();T.setRenderTarget(Ke),T.clear();const et=T.toneMapping;T.toneMapping=Qf,bE(oe,Re,We),T.toneMapping=et,ht.updateMultisampleRenderTarget(Ke),ht.updateRenderTargetMipmap(Ke),T.setRenderTarget(Be)}(et,Re,We),Be&&on.viewport(se.copy(Be)),et.length>0&&bE(et,Re,We),Bn.length>0&&bE(Bn,Re,We),xn.length>0&&bE(xn,Re,We)}function bE(oe,Re,We){const Be=!0===Re.isScene?Re.overrideMaterial:null;for(let et=0,Bn=oe.length;et0?x[x.length-1]:null,y.pop(),g=y.length>0?y[y.length-1]:null}}else console.error("THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.")},this.getActiveCubeFace=function(){return k},this.getActiveMipmapLevel=function(){return A},this.getRenderTarget=function(){return H},this.setRenderTargetTextures=function(oe,Re,We){Xe.get(oe.texture).__webglTexture=Re,Xe.get(oe.depthTexture).__webglTexture=We;const Be=Xe.get(oe);Be.__hasExternalTextures=!0,Be.__hasExternalTextures&&(Be.__autoAllocateDepthBuffer=void 0===We,Be.__autoAllocateDepthBuffer||oe.useRenderToTexture&&(console.warn("render-to-texture extension was disabled because an external texture was provided"),oe.useRenderToTexture=!1,oe.useRenderbuffer=!0))},this.setRenderTargetFramebuffer=function(oe,Re){const We=Xe.get(oe);We.__webglFramebuffer=Re,We.__useDefaultFramebuffer=void 0===Re},this.setRenderTarget=function(oe,Re=0,We=0){H=oe,k=Re,A=We;let Be=!0;if(oe){const Vn=Xe.get(oe);void 0!==Vn.__useDefaultFramebuffer?(on.bindFramebuffer(36160,null),Be=!1):void 0===Vn.__webglFramebuffer?ht.setupRenderTarget(oe):Vn.__hasExternalTextures&&ht.rebindTextures(oe,Xe.get(oe.texture).__webglTexture,Xe.get(oe.depthTexture).__webglTexture)}let et=null,Bn=!1,xn=!1;if(oe){const Vn=oe.texture;(Vn.isDataTexture3D||Vn.isDataTexture2DArray)&&(xn=!0);const Li=Xe.get(oe).__webglFramebuffer;oe.isWebGLCubeRenderTarget?(et=Li[Re],Bn=!0):et=oe.useRenderbuffer?Xe.get(oe).__webglMultisampledFramebuffer:Li,se.copy(oe.viewport),K.copy(oe.scissor),he=oe.scissorTest}else se.copy(Oe).multiplyScalar(ge).floor(),K.copy(Ve).multiplyScalar(ge).floor(),he=ye;if(on.bindFramebuffer(36160,et)&&It.drawBuffers&&Be){let Vn=!1;if(oe)if(oe.isWebGLMultipleRenderTargets){const Li=oe.texture;if(Me.length!==Li.length||36064!==Me[0]){for(let li=0,Ai=Li.length;li=0&&Re<=oe.width-Be&&We>=0&&We<=oe.height-et&&ct.readPixels(Re,We,Be,et,at.convert(Li),at.convert(li),Bn):console.error("THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete.")}finally{const Vn=null!==H?Xe.get(H).__webglFramebuffer:null;on.bindFramebuffer(36160,Vn)}}},this.copyFramebufferToTexture=function(oe,Re,We=0){const Be=Math.pow(2,-We),et=Math.floor(Re.image.width*Be),Bn=Math.floor(Re.image.height*Be);let xn=at.convert(Re.format);It.isWebGL2&&(6407===xn&&(xn=32849),6408===xn&&(xn=32856)),ht.setTexture2D(Re,0),ct.copyTexImage2D(3553,We,xn,oe.x,oe.y,et,Bn,0),on.unbindTexture()},this.copyTextureToTexture=function(oe,Re,We,Be=0){const et=Re.image.width,Bn=Re.image.height,xn=at.convert(We.format),ci=at.convert(We.type);ht.setTexture2D(We,0),ct.pixelStorei(37440,We.flipY),ct.pixelStorei(37441,We.premultiplyAlpha),ct.pixelStorei(3317,We.unpackAlignment),Re.isDataTexture?ct.texSubImage2D(3553,Be,oe.x,oe.y,et,Bn,xn,ci,Re.image.data):Re.isCompressedTexture?ct.compressedTexSubImage2D(3553,Be,oe.x,oe.y,Re.mipmaps[0].width,Re.mipmaps[0].height,xn,Re.mipmaps[0].data):ct.texSubImage2D(3553,Be,oe.x,oe.y,xn,ci,Re.image),0===Be&&We.generateMipmaps&&ct.generateMipmap(3553),on.unbindTexture()},this.copyTextureToTexture3D=function(oe,Re,We,Be,et=0){if(T.isWebGL1Renderer)return void console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: can only be used with WebGL2.");const Bn=oe.max.x-oe.min.x+1,xn=oe.max.y-oe.min.y+1,ci=oe.max.z-oe.min.z+1,Vn=at.convert(Be.format),Li=at.convert(Be.type);let li;if(Be.isDataTexture3D)ht.setTexture3D(Be,0),li=32879;else{if(!Be.isDataTexture2DArray)return void console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: only supports THREE.DataTexture3D and THREE.DataTexture2DArray.");ht.setTexture2DArray(Be,0),li=35866}ct.pixelStorei(37440,Be.flipY),ct.pixelStorei(37441,Be.premultiplyAlpha),ct.pixelStorei(3317,Be.unpackAlignment);const Ai=ct.getParameter(3314),Wr=ct.getParameter(32878),bp=ct.getParameter(3316),ji=ct.getParameter(3315),db=ct.getParameter(32877),wr=We.isCompressedTexture?We.mipmaps[0]:We.image;ct.pixelStorei(3314,wr.width),ct.pixelStorei(32878,wr.height),ct.pixelStorei(3316,oe.min.x),ct.pixelStorei(3315,oe.min.y),ct.pixelStorei(32877,oe.min.z),We.isDataTexture||We.isDataTexture3D?ct.texSubImage3D(li,et,Re.x,Re.y,Re.z,Bn,xn,ci,Vn,Li,wr.data):We.isCompressedTexture?(console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: untested support for compressed srcTexture."),ct.compressedTexSubImage3D(li,et,Re.x,Re.y,Re.z,Bn,xn,ci,Vn,wr.data)):ct.texSubImage3D(li,et,Re.x,Re.y,Re.z,Bn,xn,ci,Vn,Li,wr),ct.pixelStorei(3314,Ai),ct.pixelStorei(32878,Wr),ct.pixelStorei(3316,bp),ct.pixelStorei(3315,ji),ct.pixelStorei(32877,db),0===et&&Be.generateMipmaps&&ct.generateMipmap(li),on.unbindTexture()},this.initTexture=function(oe){ht.setTexture2D(oe,0),on.unbindTexture()},this.resetState=function(){k=0,A=0,H=null,on.reset(),kt.reset()},typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}nr.prototype.isWebGLRenderer=!0,class dle extends nr{}.prototype.isWebGL1Renderer=!0;class D2{constructor(e,t=25e-5){this.name="",this.color=new Rt(e),this.density=t}clone(){return new D2(this.color,this.density)}toJSON(){return{type:"FogExp2",color:this.color.getHex(),density:this.density}}}D2.prototype.isFogExp2=!0;class T2{constructor(e,t=1,i=1e3){this.name="",this.color=new Rt(e),this.near=t,this.far=i}clone(){return new T2(this.color,this.near,this.far)}toJSON(){return{type:"Fog",color:this.color.getHex(),near:this.near,far:this.far}}}T2.prototype.isFog=!0;class A2 extends qi{constructor(){super(),this.type="Scene",this.background=null,this.environment=null,this.fog=null,this.overrideMaterial=null,this.autoUpdate=!0,typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}copy(e,t){return super.copy(e,t),null!==e.background&&(this.background=e.background.clone()),null!==e.environment&&(this.environment=e.environment.clone()),null!==e.fog&&(this.fog=e.fog.clone()),null!==e.overrideMaterial&&(this.overrideMaterial=e.overrideMaterial.clone()),this.autoUpdate=e.autoUpdate,this.matrixAutoUpdate=e.matrixAutoUpdate,this}toJSON(e){const t=super.toJSON(e);return null!==this.fog&&(t.object.fog=this.fog.toJSON()),t}}A2.prototype.isScene=!0;class g0{constructor(e,t){this.array=e,this.stride=t,this.count=void 0!==e?e.length/t:0,this.usage=Fy,this.updateRange={offset:0,count:-1},this.version=0,this.uuid=rc()}onUploadCallback(){}set needsUpdate(e){!0===e&&this.version++}setUsage(e){return this.usage=e,this}copy(e){return this.array=new e.array.constructor(e.array),this.count=e.count,this.stride=e.stride,this.usage=e.usage,this}copyAt(e,t,i){e*=this.stride,i*=t.stride;for(let r=0,s=this.stride;re.far||t.push({distance:c,point:Wy.clone(),uv:Ts.getUV(Wy,k2,qy,I2,h6,vI,f6,new tt),face:null,object:this})}copy(e){return super.copy(e),void 0!==e.center&&this.center.copy(e.center),this.material=e.material,this}}).prototype.isSprite=!0;const m6=new ne,g6=new tr,_6=new tr,hle=new ne,v6=new Gt;class bI extends vr{constructor(e,t){super(e,t),this.type="SkinnedMesh",this.bindMode="attached",this.bindMatrix=new Gt,this.bindMatrixInverse=new Gt}copy(e){return super.copy(e),this.bindMode=e.bindMode,this.bindMatrix.copy(e.bindMatrix),this.bindMatrixInverse.copy(e.bindMatrixInverse),this.skeleton=e.skeleton,this}bind(e,t){this.skeleton=e,void 0===t&&(this.updateMatrixWorld(!0),this.skeleton.calculateInverses(),t=this.matrixWorld),this.bindMatrix.copy(t),this.bindMatrixInverse.copy(t).invert()}pose(){this.skeleton.pose()}normalizeSkinWeights(){const e=new tr,t=this.geometry.attributes.skinWeight;for(let i=0,r=t.count;ic)continue;v.applyMatrix4(this.matrixWorld);const he=e.ray.origin.distanceTo(v);hee.far||t.push({distance:he,point:g.clone().applyMatrix4(this.matrixWorld),index:H,face:null,faceIndex:null,object:this})}else for(let H=Math.max(0,o.start),G=Math.min(N.count,o.start+o.count)-1;Hc)continue;v.applyMatrix4(this.matrixWorld);const se=e.ray.origin.distanceTo(v);see.far||t.push({distance:se,point:g.clone().applyMatrix4(this.matrixWorld),index:H,face:null,faceIndex:null,object:this})}}else i.isGeometry&&console.error("THREE.Line.raycast() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}updateMorphTargets(){const e=this.geometry;if(e.isBufferGeometry){const t=e.morphAttributes,i=Object.keys(t);if(i.length>0){const r=t[i[0]];if(void 0!==r){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Line.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}}}hp.prototype.isLine=!0;const C6=new ne,D6=new ne;class Mh extends hp{constructor(e,t){super(e,t),this.type="LineSegments"}computeLineDistances(){const e=this.geometry;if(e.isBufferGeometry)if(null===e.index){const t=e.attributes.position,i=[];for(let r=0,s=t.count;rr.far)return;s.push({distance:u,distanceToRay:Math.sqrt(a),point:c,index:e,face:null,object:o})}}(class B2 extends qi{constructor(e=new gn,t=new S0){super(),this.type="Points",this.geometry=e,this.material=t,this.updateMorphTargets()}copy(e){return super.copy(e),this.material=e.material,this.geometry=e.geometry,this}raycast(e,t){const i=this.geometry,r=this.matrixWorld,s=e.params.Points.threshold,o=i.drawRange;if(null===i.boundingSphere&&i.computeBoundingSphere(),L2.copy(i.boundingSphere),L2.applyMatrix4(r),L2.radius+=s,!1===e.ray.intersectsSphere(L2))return;A6.copy(r).invert(),EI.copy(e.ray).applyMatrix4(A6);const a=s/((this.scale.x+this.scale.y+this.scale.z)/3),c=a*a;if(i.isBufferGeometry){const u=i.index,g=i.attributes.position;if(null!==u)for(let x=Math.max(0,o.start),T=Math.min(u.count,o.start+o.count);x0){const r=t[i[0]];if(void 0!==r){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Points.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}}}).prototype.isPoints=!0,class ple extends io{constructor(e,t,i,r,s,o,a,c,u){super(e,t,i,r,s,o,a,c,u),this.format=void 0!==a?a:ep,this.minFilter=void 0!==o?o:no,this.magFilter=void 0!==s?s:no,this.generateMipmaps=!1;const p=this;"requestVideoFrameCallback"in e&&e.requestVideoFrameCallback(function g(){p.needsUpdate=!0,e.requestVideoFrameCallback(g)})}clone(){return new this.constructor(this.image).copy(this)}update(){const e=this.image;"requestVideoFrameCallback"in e==0&&e.readyState>=e.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}}.prototype.isVideoTexture=!0;(class I6 extends io{constructor(e,t,i,r,s,o,a,c,u,p,g,v){super(null,o,a,c,u,p,r,s,g,v),this.image={width:t,height:i},this.mipmaps=e,this.flipY=!1,this.generateMipmaps=!1}}).prototype.isCompressedTexture=!0,class mle extends io{constructor(e,t,i,r,s,o,a,c,u){super(e,t,i,r,s,o,a,c,u),this.needsUpdate=!0}}.prototype.isCanvasTexture=!0,new ne,new ne,new ne,new Ts;class Uc{constructor(){this.type="Curve",this.arcLengthDivisions=200}getPoint(){return console.warn("THREE.Curve: .getPoint() not implemented."),null}getPointAt(e,t){const i=this.getUtoTmapping(e);return this.getPoint(i,t)}getPoints(e=5){const t=[];for(let i=0;i<=e;i++)t.push(this.getPoint(i/e));return t}getSpacedPoints(e=5){const t=[];for(let i=0;i<=e;i++)t.push(this.getPointAt(i/e));return t}getLength(){const e=this.getLengths();return e[e.length-1]}getLengths(e=this.arcLengthDivisions){if(this.cacheArcLengths&&this.cacheArcLengths.length===e+1&&!this.needsUpdate)return this.cacheArcLengths;this.needsUpdate=!1;const t=[];let i,r=this.getPoint(0),s=0;t.push(0);for(let o=1;o<=e;o++)i=this.getPoint(o/e),s+=i.distanceTo(r),t.push(s),r=i;return this.cacheArcLengths=t,t}updateArcLengths(){this.needsUpdate=!0,this.getLengths()}getUtoTmapping(e,t){const i=this.getLengths();let r=0;const s=i.length;let o;o=t||e*i[s-1];let u,a=0,c=s-1;for(;a<=c;)if(r=Math.floor(a+(c-a)/2),u=i[r]-o,u<0)a=r+1;else{if(!(u>0)){c=r;break}c=r-1}if(r=c,i[r]===o)return r/(s-1);const p=i[r];return(r+(o-p)/(i[r+1]-p))/(s-1)}getTangent(e,t){let r=e-1e-4,s=e+1e-4;r<0&&(r=0),s>1&&(s=1);const o=this.getPoint(r),a=this.getPoint(s),c=t||(o.isVector2?new tt:new ne);return c.copy(a).sub(o).normalize(),c}getTangentAt(e,t){const i=this.getUtoTmapping(e);return this.getTangent(i,t)}computeFrenetFrames(e,t){const i=new ne,r=[],s=[],o=[],a=new ne,c=new Gt;for(let y=0;y<=e;y++)r[y]=this.getTangentAt(y/e,new ne);s[0]=new ne,o[0]=new ne;let u=Number.MAX_VALUE;const p=Math.abs(r[0].x),g=Math.abs(r[0].y),v=Math.abs(r[0].z);p<=u&&(u=p,i.set(1,0,0)),g<=u&&(u=g,i.set(0,1,0)),v<=u&&i.set(0,0,1),a.crossVectors(r[0],i).normalize(),s[0].crossVectors(r[0],a),o[0].crossVectors(r[0],s[0]);for(let y=1;y<=e;y++){if(s[y]=s[y-1].clone(),o[y]=o[y-1].clone(),a.crossVectors(r[y-1],r[y]),a.length()>Number.EPSILON){a.normalize();const x=Math.acos(Mo(r[y-1].dot(r[y]),-1,1));s[y].applyMatrix4(c.makeRotationAxis(a,x))}o[y].crossVectors(r[y],s[y])}if(!0===t){let y=Math.acos(Mo(s[0].dot(s[e]),-1,1));y/=e,r[0].dot(a.crossVectors(s[0],s[e]))>0&&(y=-y);for(let x=1;x<=e;x++)s[x].applyMatrix4(c.makeRotationAxis(r[x],y*x)),o[x].crossVectors(r[x],s[x])}return{tangents:r,normals:s,binormals:o}}clone(){return(new this.constructor).copy(this)}copy(e){return this.arcLengthDivisions=e.arcLengthDivisions,this}toJSON(){const e={metadata:{version:4.5,type:"Curve",generator:"Curve.toJSON"}};return e.arcLengthDivisions=this.arcLengthDivisions,e.type=this.type,e}fromJSON(e){return this.arcLengthDivisions=e.arcLengthDivisions,this}}class W2 extends Uc{constructor(e=0,t=0,i=1,r=1,s=0,o=2*Math.PI,a=!1,c=0){super(),this.type="EllipseCurve",this.aX=e,this.aY=t,this.xRadius=i,this.yRadius=r,this.aStartAngle=s,this.aEndAngle=o,this.aClockwise=a,this.aRotation=c}getPoint(e,t){const i=t||new tt,r=2*Math.PI;let s=this.aEndAngle-this.aStartAngle;const o=Math.abs(s)r;)s-=r;s0?0:(Math.floor(Math.abs(a)/s)+1)*s:0===c&&a===s-1&&(a=s-2,c=1),this.closed||a>0?u=r[(a-1)%s]:($2.subVectors(r[0],r[1]).add(r[0]),u=$2);const g=r[a%s],v=r[(a+1)%s];if(this.closed||a+2r.length-2?r.length-1:o+1],g=r[o>r.length-3?r.length-1:o+2];return i.set(O6(a,c.x,u.x,p.x,g.x),O6(a,c.y,u.y,p.y,g.y)),i}copy(e){super.copy(e),this.points=[];for(let t=0,i=e.points.length;t=i){const o=r[s]-i,a=this.curves[s],c=a.getLength();return a.getPointAt(0===c?0:1-o/c,t)}s++}return null}getLength(){const e=this.getCurveLengths();return e[e.length-1]}updateArcLengths(){this.needsUpdate=!0,this.cacheLengths=null,this.getCurveLengths()}getCurveLengths(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;const e=[];let t=0;for(let i=0,r=this.curves.length;i1&&!t[t.length-1].equals(t[0])&&t.push(t[0]),t}copy(e){super.copy(e),this.curves=[];for(let t=0,i=e.curves.length;t0){const g=u.getPoint(0);g.equals(this.currentPoint)||this.lineTo(g.x,g.y)}this.curves.push(u);const p=u.getPoint(1);return this.currentPoint.copy(p),this}copy(e){return super.copy(e),this.currentPoint.copy(e.currentPoint),this}toJSON(){const e=super.toJSON();return e.currentPoint=this.currentPoint.toArray(),e}fromJSON(e){return super.fromJSON(e),this.currentPoint.fromArray(e.currentPoint),this}}class iu extends K2{constructor(e){super(e),this.uuid=rc(),this.type="Shape",this.holes=[]}getPointsHoles(e){const t=[];for(let i=0,r=this.holes.length;i0)for(s=e;s=e;s-=i)o=H6(s,n[s],n[s+1],o);return o&&Y2(o,o.next)&&(Qy(o),o=o.next),o}function Dh(n,e){if(!n)return n;e||(e=n);let i,t=n;do{if(i=!1,t.steiner||!Y2(t,t.next)&&0!==Lr(t.prev,t,t.next))t=t.next;else{if(Qy(t),t=e=t.prev,t===t.next)break;i=!0}}while(i||t!==e);return e}function Zy(n,e,t,i,r,s,o){if(!n)return;!o&&s&&function Ole(n,e,t,i){let r=n;do{null===r.z&&(r.z=OI(r.x,r.y,e,t,i)),r.prevZ=r.prev,r.nextZ=r.next,r=r.next}while(r!==n);r.prevZ.nextZ=null,r.prevZ=null,function Lle(n){let e,t,i,r,s,o,a,c,u=1;do{for(t=n,n=null,s=null,o=0;t;){for(o++,i=t,a=0,e=0;e0||c>0&&i;)0!==a&&(0===c||!i||t.z<=i.z)?(r=t,t=t.nextZ,a--):(r=i,i=i.nextZ,c--),s?s.nextZ=r:n=r,r.prevZ=s,s=r;t=i}s.nextZ=null,u*=2}while(o>1)}(r)}(n,i,r,s);let c,u,a=n;for(;n.prev!==n.next;)if(c=n.prev,u=n.next,s?Dle(n,i,r,s):Cle(n))e.push(c.i/t),e.push(n.i/t),e.push(u.i/t),Qy(n),n=u.next,a=u.next;else if((n=u)===a){o?1===o?Zy(n=Tle(Dh(n),e,t),e,t,i,r,s,2):2===o&&Ale(n,e,t,i,r,s):Zy(Dh(n),e,t,i,r,s,1);break}}function Cle(n){const e=n.prev,t=n,i=n.next;if(Lr(e,t,i)>=0)return!1;let r=n.next.next;for(;r!==n.prev;){if(M0(e.x,e.y,t.x,t.y,i.x,i.y,r.x,r.y)&&Lr(r.prev,r,r.next)>=0)return!1;r=r.next}return!0}function Dle(n,e,t,i){const r=n.prev,s=n,o=n.next;if(Lr(r,s,o)>=0)return!1;const u=r.x>s.x?r.x>o.x?r.x:o.x:s.x>o.x?s.x:o.x,p=r.y>s.y?r.y>o.y?r.y:o.y:s.y>o.y?s.y:o.y,g=OI(r.x=g&&x&&x.z<=v;){if(y!==n.prev&&y!==n.next&&M0(r.x,r.y,s.x,s.y,o.x,o.y,y.x,y.y)&&Lr(y.prev,y,y.next)>=0||(y=y.prevZ,x!==n.prev&&x!==n.next&&M0(r.x,r.y,s.x,s.y,o.x,o.y,x.x,x.y)&&Lr(x.prev,x,x.next)>=0))return!1;x=x.nextZ}for(;y&&y.z>=g;){if(y!==n.prev&&y!==n.next&&M0(r.x,r.y,s.x,s.y,o.x,o.y,y.x,y.y)&&Lr(y.prev,y,y.next)>=0)return!1;y=y.prevZ}for(;x&&x.z<=v;){if(x!==n.prev&&x!==n.next&&M0(r.x,r.y,s.x,s.y,o.x,o.y,x.x,x.y)&&Lr(x.prev,x,x.next)>=0)return!1;x=x.nextZ}return!0}function Tle(n,e,t){let i=n;do{const r=i.prev,s=i.next.next;!Y2(r,s)&&B6(r,i,i.next,s)&&Jy(r,s)&&Jy(s,r)&&(e.push(r.i/t),e.push(i.i/t),e.push(s.i/t),Qy(i),Qy(i.next),i=n=s),i=i.next}while(i!==n);return Dh(i)}function Ale(n,e,t,i,r,s){let o=n;do{let a=o.next.next;for(;a!==o.prev;){if(o.i!==a.i&&Ble(o,a)){let c=V6(o,a);return o=Dh(o,o.next),c=Dh(c,c.next),Zy(o,e,t,i,r,s),void Zy(c,e,t,i,r,s)}a=a.next}o=o.next}while(o!==n)}function Ile(n,e){return n.x-e.x}function Fle(n,e){if(e=function Rle(n,e){let t=e;const i=n.x,r=n.y;let o,s=-1/0;do{if(r<=t.y&&r>=t.next.y&&t.next.y!==t.y){const v=t.x+(r-t.y)*(t.next.x-t.x)/(t.next.y-t.y);if(v<=i&&v>s){if(s=v,v===i){if(r===t.y)return t;if(r===t.next.y)return t.next}o=t.x=t.x&&t.x>=c&&i!==t.x&&M0(ro.x||t.x===o.x&&Ple(o,t)))&&(o=t,p=g)),t=t.next}while(t!==a);return o}(n,e),e){const t=V6(e,n);Dh(e,e.next),Dh(t,t.next)}}function Ple(n,e){return Lr(n.prev,n,e.prev)<0&&Lr(e.next,n,n.next)<0}function OI(n,e,t,i,r){return(n=1431655765&((n=858993459&((n=252645135&((n=16711935&((n=32767*(n-t)*r)|n<<8))|n<<4))|n<<2))|n<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-i)*r)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function Nle(n){let e=n,t=n;do{(e.x=0&&(n-o)*(i-a)-(t-o)*(e-a)>=0&&(t-o)*(s-a)-(r-o)*(i-a)>=0}function Ble(n,e){return n.next.i!==e.i&&n.prev.i!==e.i&&!function Vle(n,e){let t=n;do{if(t.i!==n.i&&t.next.i!==n.i&&t.i!==e.i&&t.next.i!==e.i&&B6(t,t.next,n,e))return!0;t=t.next}while(t!==n);return!1}(n,e)&&(Jy(n,e)&&Jy(e,n)&&function Hle(n,e){let t=n,i=!1;const r=(n.x+e.x)/2,s=(n.y+e.y)/2;do{t.y>s!=t.next.y>s&&t.next.y!==t.y&&r<(t.next.x-t.x)*(s-t.y)/(t.next.y-t.y)+t.x&&(i=!i),t=t.next}while(t!==n);return i}(n,e)&&(Lr(n.prev,n,e.prev)||Lr(n,e.prev,e))||Y2(n,e)&&Lr(n.prev,n,n.next)>0&&Lr(e.prev,e,e.next)>0)}function Lr(n,e,t){return(e.y-n.y)*(t.x-e.x)-(e.x-n.x)*(t.y-e.y)}function Y2(n,e){return n.x===e.x&&n.y===e.y}function B6(n,e,t,i){const r=Z2(Lr(n,e,t)),s=Z2(Lr(n,e,i)),o=Z2(Lr(t,i,n)),a=Z2(Lr(t,i,e));return!!(r!==s&&o!==a||0===r&&X2(n,t,e)||0===s&&X2(n,i,e)||0===o&&X2(t,n,i)||0===a&&X2(t,e,i))}function X2(n,e,t){return e.x<=Math.max(n.x,t.x)&&e.x>=Math.min(n.x,t.x)&&e.y<=Math.max(n.y,t.y)&&e.y>=Math.min(n.y,t.y)}function Z2(n){return n>0?1:n<0?-1:0}function Jy(n,e){return Lr(n.prev,n,n.next)<0?Lr(n,e,n.next)>=0&&Lr(n,n.prev,e)>=0:Lr(n,e,n.prev)<0||Lr(n,n.next,e)<0}function V6(n,e){const t=new LI(n.i,n.x,n.y),i=new LI(e.i,e.x,e.y),r=n.next,s=e.prev;return n.next=e,e.prev=n,t.next=r,r.prev=t,i.next=t,t.prev=i,s.next=i,i.prev=s,i}function H6(n,e,t,i){const r=new LI(n,e,t);return i?(r.next=i.next,r.prev=i,i.next.prev=r,i.next=r):(r.prev=r,r.next=r),r}function Qy(n){n.next.prev=n.prev,n.prev.next=n.next,n.prevZ&&(n.prevZ.nextZ=n.nextZ),n.nextZ&&(n.nextZ.prevZ=n.prevZ)}function LI(n,e,t){this.i=n,this.x=e,this.y=t,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}class ru{static area(e){const t=e.length;let i=0;for(let r=t-1,s=0;s80*t){a=u=n[0],c=p=n[1];for(let x=t;xu&&(u=g),v>p&&(p=v);y=Math.max(u-a,p-c),y=0!==y?1/y:0}return Zy(s,o,t,a,c,y),o}(i,r);for(let c=0;c2&&n[e-1].equals(n[0])&&n.pop()}function z6(n,e){for(let t=0;tNumber.EPSILON){const st=Math.sqrt(ae),Kt=Math.sqrt(xr*xr+fe*fe),Wt=ht.x-xi/st,Ce=ht.y+$n/st,kt=((bt.x-fe/Kt-Wt)*fe-(bt.y+xr/Kt-Ce)*xr)/($n*fe-xi*xr);Vt=Wt+$n*kt-Xe.x,At=Ce+xi*kt-Xe.y;const Et=Vt*Vt+At*At;if(Et<=2)return new tt(Vt,At);Wn=Math.sqrt(Et/2)}else{let st=!1;$n>Number.EPSILON?xr>Number.EPSILON&&(st=!0):$n<-Number.EPSILON?xr<-Number.EPSILON&&(st=!0):Math.sign(xi)===Math.sign(fe)&&(st=!0),st?(Vt=-xi,At=$n,Wn=Math.sqrt(ae)):(Vt=$n,At=xi,Wn=Math.sqrt(ae/2))}return new tt(Vt/Wn,At/Wn)}const lt=[];for(let Xe=0,ht=Oe.length,bt=ht-1,Vt=Xe+1;Xe=0;Xe--){const ht=Xe/N,bt=y*Math.cos(ht*Math.PI/2),Vt=x*Math.sin(ht*Math.PI/2)+T;for(let At=0,Wn=Oe.length;At=0;){const Vt=bt;let At=bt-1;At<0&&(At=Xe.length-1);for(let Wn=0,$n=p+2*N;Wn<$n;Wn++){const xi=ye*Wn,xr=ye*(Wn+1);It(ht+Vt+xi,ht+At+xi,ht+At+xr,ht+Vt+xr)}}}function Qt(Xe,ht,bt){c.push(Xe),c.push(ht),c.push(bt)}function sn(Xe,ht,bt){on(Xe),on(ht),on(bt);const Vt=r.length/3,At=A.generateTopUV(i,r,Vt-3,Vt-2,Vt-1);gi(At[0]),gi(At[1]),gi(At[2])}function It(Xe,ht,bt,Vt){on(Xe),on(ht),on(Vt),on(ht),on(bt),on(Vt);const At=r.length/3,Wn=A.generateSideWallUV(i,r,At-6,At-3,At-2,At-1);gi(Wn[0]),gi(Wn[1]),gi(Wn[3]),gi(Wn[1]),gi(Wn[2]),gi(Wn[3])}function on(Xe){r.push(c[3*Xe+0]),r.push(c[3*Xe+1]),r.push(c[3*Xe+2])}function gi(Xe){s.push(Xe.x),s.push(Xe.y)}(function gt(){const Xe=r.length/3;if(v){let ht=0,bt=ye*ht;for(let Vt=0;Vt0!=e>0&&this.version++,this._sheen=e}get clearcoat(){return this._clearcoat}set clearcoat(e){this._clearcoat>0!=e>0&&this.version++,this._clearcoat=e}get transmission(){return this._transmission}set transmission(e){this._transmission>0!=e>0&&this.version++,this._transmission=e}copy(e){return super.copy(e),this.defines={STANDARD:"",PHYSICAL:""},this.clearcoat=e.clearcoat,this.clearcoatMap=e.clearcoatMap,this.clearcoatRoughness=e.clearcoatRoughness,this.clearcoatRoughnessMap=e.clearcoatRoughnessMap,this.clearcoatNormalMap=e.clearcoatNormalMap,this.clearcoatNormalScale.copy(e.clearcoatNormalScale),this.ior=e.ior,this.sheen=e.sheen,this.sheenColor.copy(e.sheenColor),this.sheenColorMap=e.sheenColorMap,this.sheenRoughness=e.sheenRoughness,this.sheenRoughnessMap=e.sheenRoughnessMap,this.transmission=e.transmission,this.transmissionMap=e.transmissionMap,this.thickness=e.thickness,this.thicknessMap=e.thicknessMap,this.attenuationDistance=e.attenuationDistance,this.attenuationColor.copy(e.attenuationColor),this.specularIntensity=e.specularIntensity,this.specularIntensityMap=e.specularIntensityMap,this.specularColor.copy(e.specularColor),this.specularColorMap=e.specularColorMap,this}}).prototype.isMeshPhysicalMaterial=!0;(class K6 extends Co{constructor(e){super(),this.type="MeshPhongMaterial",this.color=new Rt(16777215),this.specular=new Rt(1118481),this.shininess=30,this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new Rt(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=$g,this.normalScale=new tt(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=jS,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.specular.copy(e.specular),this.shininess=e.shininess,this.map=e.map,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.specularMap=e.specularMap,this.alphaMap=e.alphaMap,this.envMap=e.envMap,this.combine=e.combine,this.reflectivity=e.reflectivity,this.refractionRatio=e.refractionRatio,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this.flatShading=e.flatShading,this}}).prototype.isMeshPhongMaterial=!0;(class Y6 extends Co{constructor(e){super(),this.defines={TOON:""},this.type="MeshToonMaterial",this.color=new Rt(16777215),this.map=null,this.gradientMap=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new Rt(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=$g,this.normalScale=new tt(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.map=e.map,this.gradientMap=e.gradientMap,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.alphaMap=e.alphaMap,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this}}).prototype.isMeshToonMaterial=!0;(class X6 extends Co{constructor(e){super(),this.type="MeshNormalMaterial",this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=$g,this.normalScale=new tt(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.flatShading=e.flatShading,this}}).prototype.isMeshNormalMaterial=!0;(class Z6 extends Co{constructor(e){super(),this.type="MeshLambertMaterial",this.color=new Rt(16777215),this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new Rt(0),this.emissiveIntensity=1,this.emissiveMap=null,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=jS,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.map=e.map,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.specularMap=e.specularMap,this.alphaMap=e.alphaMap,this.envMap=e.envMap,this.combine=e.combine,this.reflectivity=e.reflectivity,this.refractionRatio=e.refractionRatio,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this}}).prototype.isMeshLambertMaterial=!0;(class J6 extends Co{constructor(e){super(),this.defines={MATCAP:""},this.type="MeshMatcapMaterial",this.color=new Rt(16777215),this.matcap=null,this.map=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=$g,this.normalScale=new tt(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.defines={MATCAP:""},this.color.copy(e.color),this.matcap=e.matcap,this.map=e.map,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.alphaMap=e.alphaMap,this.flatShading=e.flatShading,this}}).prototype.isMeshMatcapMaterial=!0;(class Q6 extends To{constructor(e){super(),this.type="LineDashedMaterial",this.scale=1,this.dashSize=3,this.gapSize=1,this.setValues(e)}copy(e){return super.copy(e),this.scale=e.scale,this.dashSize=e.dashSize,this.gapSize=e.gapSize,this}}).prototype.isLineDashedMaterial=!0;const Ar={arraySlice:function(n,e,t){return Ar.isTypedArray(n)?new n.constructor(n.subarray(e,void 0!==t?t:n.length)):n.slice(e,t)},convertArray:function(n,e,t){return!n||!t&&n.constructor===e?n:"number"==typeof e.BYTES_PER_ELEMENT?new e(n):Array.prototype.slice.call(n)},isTypedArray:function(n){return ArrayBuffer.isView(n)&&!(n instanceof DataView)},getKeyframeOrder:function(n){const t=n.length,i=new Array(t);for(let r=0;r!==t;++r)i[r]=r;return i.sort(function e(r,s){return n[r]-n[s]}),i},sortedArray:function(n,e,t){const i=n.length,r=new n.constructor(i);for(let s=0,o=0;o!==i;++s){const a=t[s]*e;for(let c=0;c!==e;++c)r[o++]=n[a+c]}return r},flattenJSON:function(n,e,t,i){let r=1,s=n[0];for(;void 0!==s&&void 0===s[i];)s=n[r++];if(void 0===s)return;let o=s[i];if(void 0!==o)if(Array.isArray(o))do{o=s[i],void 0!==o&&(e.push(s.time),t.push.apply(t,o)),s=n[r++]}while(void 0!==s);else if(void 0!==o.toArray)do{o=s[i],void 0!==o&&(e.push(s.time),o.toArray(t,t.length)),s=n[r++]}while(void 0!==s);else do{o=s[i],void 0!==o&&(e.push(s.time),t.push(o)),s=n[r++]}while(void 0!==s)},subclip:function(n,e,t,i,r=30){const s=n.clone();s.name=e;const o=[];for(let c=0;c=i)){g.push(u.times[y]);for(let T=0;Ts.tracks[c].times[0]&&(a=s.tracks[c].times[0]);for(let c=0;c=a.times[x]){const k=x*g+p;T=Ar.arraySlice(a.values,k,k+g-p)}else{const k=a.createInterpolant(),A=p,H=g-p;k.evaluate(s),T=Ar.arraySlice(k.resultBuffer,A,H)}"quaternion"===c&&(new Go).fromArray(T).normalize().conjugate().toArray(T);const N=u.times.length;for(let k=0;k=s)break e;{const a=t[1];e=s)break t}o=i,i=0}}for(;i>>1;et;)--o;if(++o,0!==s||o!==r){s>=o&&(o=Math.max(o,1),s=o-1);const a=this.getValueSize();this.times=Ar.arraySlice(i,s,o),this.values=Ar.arraySlice(this.values,s*a,o*a)}return this}validate(){let e=!0;const t=this.getValueSize();t-Math.floor(t)!=0&&(console.error("THREE.KeyframeTrack: Invalid value size in track.",this),e=!1);const i=this.times,r=this.values,s=i.length;0===s&&(console.error("THREE.KeyframeTrack: Track is empty.",this),e=!1);let o=null;for(let a=0;a!==s;a++){const c=i[a];if("number"==typeof c&&isNaN(c)){console.error("THREE.KeyframeTrack: Time is not a valid number.",this,a,c),e=!1;break}if(null!==o&&o>c){console.error("THREE.KeyframeTrack: Out of order keys.",this,a,c,o),e=!1;break}o=c}if(void 0!==r&&Ar.isTypedArray(r))for(let a=0,c=r.length;a!==c;++a){const u=r[a];if(isNaN(u)){console.error("THREE.KeyframeTrack: Value is not a valid number.",this,a,u),e=!1;break}}return e}optimize(){const e=Ar.arraySlice(this.times),t=Ar.arraySlice(this.values),i=this.getValueSize(),r=2302===this.getInterpolation(),s=e.length-1;let o=1;for(let a=1;a0){e[o]=e[s];for(let a=s*i,c=o*i,u=0;u!==i;++u)t[c+u]=t[a+u];++o}return o!==e.length?(this.times=Ar.arraySlice(e,0,o),this.values=Ar.arraySlice(t,0,o*i)):(this.times=e,this.values=t),this}clone(){const e=Ar.arraySlice(this.times,0),t=Ar.arraySlice(this.values,0),r=new(0,this.constructor)(this.name,e,t);return r.createInterpolant=this.createInterpolant,r}}nd.prototype.TimeBufferType=Float32Array,nd.prototype.ValueBufferType=Float32Array,nd.prototype.DefaultInterpolation=2301;class C0 extends nd{}C0.prototype.ValueTypeName="bool",C0.prototype.ValueBufferType=Array,C0.prototype.DefaultInterpolation=2300,C0.prototype.InterpolantFactoryMethodLinear=void 0,C0.prototype.InterpolantFactoryMethodSmooth=void 0;class tV extends nd{}tV.prototype.ValueTypeName="color";class oE extends nd{}oE.prototype.ValueTypeName="number";class Kle extends Th{constructor(e,t,i,r){super(e,t,i,r)}interpolate_(e,t,i,r){const s=this.resultBuffer,o=this.sampleValues,a=this.valueSize,c=(i-t)/(r-t);let u=e*a;for(let p=u+a;u!==p;u+=4)Go.slerpFlat(s,0,o,u-a,o,u,c);return s}}class ib extends nd{InterpolantFactoryMethodLinear(e){return new Kle(this.times,this.values,this.getValueSize(),e)}}ib.prototype.ValueTypeName="quaternion",ib.prototype.DefaultInterpolation=2301,ib.prototype.InterpolantFactoryMethodSmooth=void 0;class D0 extends nd{}D0.prototype.ValueTypeName="string",D0.prototype.ValueBufferType=Array,D0.prototype.DefaultInterpolation=2300,D0.prototype.InterpolantFactoryMethodLinear=void 0,D0.prototype.InterpolantFactoryMethodSmooth=void 0;class aE extends nd{}aE.prototype.ValueTypeName="vector";class cE{constructor(e,t=-1,i,r=2500){this.name=e,this.tracks=i,this.duration=t,this.blendMode=r,this.uuid=rc(),this.duration<0&&this.resetDuration()}static parse(e){const t=[],i=e.tracks,r=1/(e.fps||1);for(let o=0,a=i.length;o!==a;++o)t.push(Xle(i[o]).scale(r));const s=new this(e.name,e.duration,t,e.blendMode);return s.uuid=e.uuid,s}static toJSON(e){const t=[],i=e.tracks,r={name:e.name,duration:e.duration,tracks:t,uuid:e.uuid,blendMode:e.blendMode};for(let s=0,o=i.length;s!==o;++s)t.push(nd.toJSON(i[s]));return r}static CreateFromMorphTargetSequence(e,t,i,r){const s=t.length,o=[];for(let a=0;a1){const g=p[1];let v=r[g];v||(r[g]=v=[]),v.push(u)}}const o=[];for(const a in r)o.push(this.CreateFromMorphTargetSequence(a,r[a],t,i));return o}static parseAnimation(e,t){if(!e)return console.error("THREE.AnimationClip: No animation in JSONLoader data."),null;const i=function(g,v,y,x,T){if(0!==y.length){const N=[],k=[];Ar.flattenJSON(y,N,k,x),0!==N.length&&T.push(new g(v,N,k))}},r=[],s=e.name||"default",o=e.fps||30,a=e.blendMode;let c=e.length||-1;const u=e.hierarchy||[];for(let g=0;g{t&&t(s),this.manager.itemEnd(e)},0),s;if(void 0!==au[e])return void au[e].push({onLoad:t,onProgress:i,onError:r});au[e]=[],au[e].push({onLoad:t,onProgress:i,onError:r});const o=new Request(e,{headers:new Headers(this.requestHeader),credentials:this.withCredentials?"include":"same-origin"});fetch(o).then(a=>{if(200===a.status||0===a.status){0===a.status&&console.warn("THREE.FileLoader: HTTP Status 0 received.");const c=au[e],u=a.body.getReader(),p=a.headers.get("Content-Length"),g=p?parseInt(p):0,v=0!==g;let y=0;return new ReadableStream({start(x){!function T(){u.read().then(({done:N,value:k})=>{if(N)x.close();else{y+=k.byteLength;const A=new ProgressEvent("progress",{lengthComputable:v,loaded:y,total:g});for(let H=0,G=c.length;H{const c=new Response(a);switch(this.responseType){case"arraybuffer":return c.arrayBuffer();case"blob":return c.blob();case"document":return c.text().then(u=>(new DOMParser).parseFromString(u,this.mimeType));case"json":return c.json();default:return c.text()}}).then(a=>{T0.add(e,a);const c=au[e];delete au[e];for(let u=0,p=c.length;u{const c=au[e];delete au[e];for(let u=0,p=c.length;u"u"&&console.warn("THREE.ImageBitmapLoader: createImageBitmap() not supported."),typeof fetch>"u"&&console.warn("THREE.ImageBitmapLoader: fetch() not supported."),this.options={premultiplyAlpha:"none"}}setOptions(e){return this.options=e,this}load(e,t,i,r){void 0===e&&(e=""),void 0!==this.path&&(e=this.path+e),e=this.manager.resolveURL(e);const s=this,o=T0.get(e);if(void 0!==o)return s.manager.itemStart(e),setTimeout(function(){t&&t(o),s.manager.itemEnd(e)},0),o;const a={};a.credentials="anonymous"===this.crossOrigin?"same-origin":"include",a.headers=this.requestHeader,fetch(e,a).then(function(c){return c.blob()}).then(function(c){return createImageBitmap(c,Object.assign(s.options,{colorSpaceConversion:"none"}))}).then(function(c){T0.add(e,c),t&&t(c),s.manager.itemEnd(e)}).catch(function(c){r&&r(c),s.manager.itemError(e),s.manager.itemEnd(e)}),s.manager.itemStart(e)}}.prototype.isImageBitmapLoader=!0;class sde extends ou{constructor(e){super(e)}load(e,t,i,r){const s=this,o=new id(this.manager);o.setResponseType("arraybuffer"),o.setPath(this.path),o.setRequestHeader(this.requestHeader),o.setWithCredentials(this.withCredentials),o.load(e,function(a){try{const c=a.slice(0);(void 0===uE&&(uE=new(window.AudioContext||window.webkitAudioContext)),uE).decodeAudioData(c,function(p){t(p)})}catch(c){r?r(c):console.error(c),s.manager.itemError(e)}},i,r)}}(class ode extends dE{constructor(e,t,i=1){super(void 0,i);const r=(new Rt).set(e),s=(new Rt).set(t),o=new ne(r.r,r.g,r.b),a=new ne(s.r,s.g,s.b),c=Math.sqrt(Math.PI),u=c*Math.sqrt(.75);this.sh.coefficients[0].copy(o).add(a).multiplyScalar(c),this.sh.coefficients[1].copy(o).sub(a).multiplyScalar(u)}}).prototype.isHemisphereLightProbe=!0,class ade extends dE{constructor(e,t=1){super(void 0,t);const i=(new Rt).set(e);this.sh.coefficients[0].set(i.r,i.g,i.b).multiplyScalar(2*Math.sqrt(Math.PI))}}.prototype.isAmbientLightProbe=!0;class fde{constructor(e,t,i){let r,s,o;switch(this.binding=e,this.valueSize=i,t){case"quaternion":r=this._slerp,s=this._slerpAdditive,o=this._setAdditiveIdentityQuaternion,this.buffer=new Float64Array(6*i),this._workIndex=5;break;case"string":case"bool":r=this._select,s=this._select,o=this._setAdditiveIdentityOther,this.buffer=new Array(5*i);break;default:r=this._lerp,s=this._lerpAdditive,o=this._setAdditiveIdentityNumeric,this.buffer=new Float64Array(5*i)}this._mixBufferRegion=r,this._mixBufferRegionAdditive=s,this._setIdentity=o,this._origIndex=3,this._addIndex=4,this.cumulativeWeight=0,this.cumulativeWeightAdditive=0,this.useCount=0,this.referenceCount=0}accumulate(e,t){const i=this.buffer,r=this.valueSize,s=e*r+r;let o=this.cumulativeWeight;if(0===o){for(let a=0;a!==r;++a)i[s+a]=i[a];o=t}else o+=t,this._mixBufferRegion(i,s,0,t/o,r);this.cumulativeWeight=o}accumulateAdditive(e){const t=this.buffer,i=this.valueSize,r=i*this._addIndex;0===this.cumulativeWeightAdditive&&this._setIdentity(),this._mixBufferRegionAdditive(t,r,0,e,i),this.cumulativeWeightAdditive+=e}apply(e){const t=this.valueSize,i=this.buffer,r=e*t+t,s=this.cumulativeWeight,o=this.cumulativeWeightAdditive,a=this.binding;this.cumulativeWeight=0,this.cumulativeWeightAdditive=0,s<1&&this._mixBufferRegion(i,r,t*this._origIndex,1-s,t),o>0&&this._mixBufferRegionAdditive(i,r,this._addIndex*t,1,t);for(let c=t,u=t+t;c!==u;++c)if(i[c]!==i[c+t]){a.setValue(i,r);break}}saveOriginalState(){const t=this.buffer,i=this.valueSize,r=i*this._origIndex;this.binding.getValue(t,r);for(let s=i,o=r;s!==o;++s)t[s]=t[r+s%i];this._setIdentity(),this.cumulativeWeight=0,this.cumulativeWeightAdditive=0}restoreOriginalState(){this.binding.setValue(this.buffer,3*this.valueSize)}_setAdditiveIdentityNumeric(){const e=this._addIndex*this.valueSize,t=e+this.valueSize;for(let i=e;i=.5)for(let o=0;o!==s;++o)e[t+o]=e[i+o]}_slerp(e,t,i,r){Go.slerpFlat(e,t,e,t,e,i,r)}_slerpAdditive(e,t,i,r,s){const o=this._workIndex*s;Go.multiplyQuaternionsFlat(e,o,e,t,e,i),Go.slerpFlat(e,t,e,t,e,o,r)}_lerp(e,t,i,r,s){const o=1-r;for(let a=0;a!==s;++a){const c=t+a;e[c]=e[c]*o+e[i+a]*r}}_lerpAdditive(e,t,i,r,s){for(let o=0;o!==s;++o){const a=t+o;e[a]=e[a]+e[i+o]*r}}}const HI="\\[\\]\\.:\\/",pde=new RegExp("["+HI+"]","g"),UI="[^"+HI+"]",mde="[^"+HI.replace("\\.","")+"]",gde=/((?:WC+[\/:])*)/.source.replace("WC",UI),_de=/(WCOD+)?/.source.replace("WCOD",mde),vde=/(?:\.(WC+)(?:\[(.+)\])?)?/.source.replace("WC",UI),yde=/\.(WC+)(?:\[(.+)\])?/.source.replace("WC",UI),bde=new RegExp("^"+gde+_de+vde+yde+"$"),xde=["material","materials","bones"];class wde{constructor(e,t,i){const r=i||yr.parseTrackName(t);this._targetGroup=e,this._bindings=e.subscribe_(t,r)}getValue(e,t){this.bind();const r=this._bindings[this._targetGroup.nCachedObjects_];void 0!==r&&r.getValue(e,t)}setValue(e,t){const i=this._bindings;for(let r=this._targetGroup.nCachedObjects_,s=i.length;r!==s;++r)i[r].setValue(e,t)}bind(){const e=this._bindings;for(let t=this._targetGroup.nCachedObjects_,i=e.length;t!==i;++t)e[t].bind()}unbind(){const e=this._bindings;for(let t=this._targetGroup.nCachedObjects_,i=e.length;t!==i;++t)e[t].unbind()}}let yr=(()=>{class n{constructor(t,i,r){this.path=i,this.parsedPath=r||n.parseTrackName(i),this.node=n.findNode(t,this.parsedPath.nodeName)||t,this.rootNode=t,this.getValue=this._getValue_unbound,this.setValue=this._setValue_unbound}static create(t,i,r){return t&&t.isAnimationObjectGroup?new n.Composite(t,i,r):new n(t,i,r)}static sanitizeNodeName(t){return t.replace(/\s/g,"_").replace(pde,"")}static parseTrackName(t){const i=bde.exec(t);if(!i)throw new Error("PropertyBinding: Cannot parse trackName: "+t);const r={nodeName:i[2],objectName:i[3],objectIndex:i[4],propertyName:i[5],propertyIndex:i[6]},s=r.nodeName&&r.nodeName.lastIndexOf(".");if(void 0!==s&&-1!==s){const o=r.nodeName.substring(s+1);-1!==xde.indexOf(o)&&(r.nodeName=r.nodeName.substring(0,s),r.objectName=o)}if(null===r.propertyName||0===r.propertyName.length)throw new Error("PropertyBinding: can not parse propertyName from trackName: "+t);return r}static findNode(t,i){if(!i||""===i||"."===i||-1===i||i===t.name||i===t.uuid)return t;if(t.skeleton){const r=t.skeleton.getBoneByName(i);if(void 0!==r)return r}if(t.children){const r=function(o){for(let a=0;a0){const c=this._interpolants,u=this._propertyBindings;if(2501===this.blendMode)for(let p=0,g=c.length;p!==g;++p)c[p].evaluate(o),u[p].accumulateAdditive(a);else for(let p=0,g=c.length;p!==g;++p)c[p].evaluate(o),u[p].accumulate(r,a)}}_updateWeight(e){let t=0;if(this.enabled){t=this.weight;const i=this._weightInterpolant;if(null!==i){const r=i.evaluate(e)[0];t*=r,e>i.parameterPositions[1]&&(this.stopFading(),0===r&&(this.enabled=!1))}}return this._effectiveWeight=t,t}_updateTimeScale(e){let t=0;if(!this.paused){t=this.timeScale;const i=this._timeScaleInterpolant;null!==i&&(t*=i.evaluate(e)[0],e>i.parameterPositions[1]&&(this.stopWarping(),0===t?this.paused=!0:this.timeScale=t))}return this._effectiveTimeScale=t,t}_updateTime(e){const t=this._clip.duration,i=this.loop;let r=this.time+e,s=this._loopCount;const o=2202===i;if(0===e)return-1===s?r:o&&1==(1&s)?t-r:r;if(2200===i){-1===s&&(this._loopCount=0,this._setEndings(!0,!0,!1));e:{if(r>=t)r=t;else{if(!(r<0)){this.time=r;break e}r=0}this.clampWhenFinished?this.paused=!0:this.enabled=!1,this.time=r,this._mixer.dispatchEvent({type:"finished",action:this,direction:e<0?-1:1})}}else{if(-1===s&&(e>=0?(s=0,this._setEndings(!0,0===this.repetitions,o)):this._setEndings(0===this.repetitions,!0,o)),r>=t||r<0){const a=Math.floor(r/t);r-=t*a,s+=Math.abs(a);const c=this.repetitions-s;if(c<=0)this.clampWhenFinished?this.paused=!0:this.enabled=!1,r=e>0?t:0,this.time=r,this._mixer.dispatchEvent({type:"finished",action:this,direction:e>0?1:-1});else{if(1===c){const u=e<0;this._setEndings(u,!u,o)}else this._setEndings(!1,!1,o);this._loopCount=s,this.time=r,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:a})}}else this.time=r;if(o&&1==(1&s))return t-r}return r}_setEndings(e,t,i){const r=this._interpolantSettings;i?(r.endingStart=Wg,r.endingEnd=Wg):(r.endingStart=e?this.zeroSlopeAtStart?Wg:jg:2402,r.endingEnd=t?this.zeroSlopeAtEnd?Wg:jg:2402)}_scheduleFading(e,t,i){const r=this._mixer,s=r.time;let o=this._weightInterpolant;null===o&&(o=r._lendControlInterpolant(),this._weightInterpolant=o);const a=o.parameterPositions,c=o.sampleValues;return a[0]=s,c[0]=t,a[1]=s+e,c[1]=i,this}}(class Mde extends np{constructor(e){super(),this._root=e,this._initMemoryManager(),this._accuIndex=0,this.time=0,this.timeScale=1}_bindAction(e,t){const i=e._localRoot||this._root,r=e._clip.tracks,s=r.length,o=e._propertyBindings,a=e._interpolants,c=i.uuid,u=this._bindingsByRootAndName;let p=u[c];void 0===p&&(p={},u[c]=p);for(let g=0;g!==s;++g){const v=r[g],y=v.name;let x=p[y];if(void 0!==x)o[g]=x;else{if(x=o[g],void 0!==x){null===x._cacheIndex&&(++x.referenceCount,this._addInactiveBinding(x,c,y));continue}x=new fde(yr.create(i,y,t&&t._propertyBindings[g].binding.parsedPath),v.ValueTypeName,v.getValueSize()),++x.referenceCount,this._addInactiveBinding(x,c,y),o[g]=x}a[g].resultBuffer=x.buffer}}_activateAction(e){if(!this._isActiveAction(e)){if(null===e._cacheIndex){const i=(e._localRoot||this._root).uuid,r=e._clip.uuid,s=this._actionsByClip[r];this._bindAction(e,s&&s.knownActions[0]),this._addInactiveAction(e,r,i)}const t=e._propertyBindings;for(let i=0,r=t.length;i!==r;++i){const s=t[i];0==s.useCount++&&(this._lendBinding(s),s.saveOriginalState())}this._lendAction(e)}}_deactivateAction(e){if(this._isActiveAction(e)){const t=e._propertyBindings;for(let i=0,r=t.length;i!==r;++i){const s=t[i];0==--s.useCount&&(s.restoreOriginalState(),this._takeBackBinding(s))}this._takeBackAction(e)}}_initMemoryManager(){this._actions=[],this._nActiveActions=0,this._actionsByClip={},this._bindings=[],this._nActiveBindings=0,this._bindingsByRootAndName={},this._controlInterpolants=[],this._nActiveControlInterpolants=0;const e=this;this.stats={actions:{get total(){return e._actions.length},get inUse(){return e._nActiveActions}},bindings:{get total(){return e._bindings.length},get inUse(){return e._nActiveBindings}},controlInterpolants:{get total(){return e._controlInterpolants.length},get inUse(){return e._nActiveControlInterpolants}}}}_isActiveAction(e){const t=e._cacheIndex;return null!==t&&t=0;--i)e[i].stop();return this}update(e){const t=this._actions,i=this._nActiveActions,r=this.time+=e*=this.timeScale,s=Math.sign(e),o=this._accuIndex^=1;for(let u=0;u!==i;++u)t[u]._update(r,e,s,o);const a=this._bindings,c=this._nActiveBindings;for(let u=0;u!==c;++u)a[u].apply(o);return this}setTime(e){this.time=0;for(let t=0;tthis.max.x||e.ythis.max.y)}containsBox(e){return this.min.x<=e.min.x&&e.max.x<=this.max.x&&this.min.y<=e.min.y&&e.max.y<=this.max.y}getParameter(e,t){return t.set((e.x-this.min.x)/(this.max.x-this.min.x),(e.y-this.min.y)/(this.max.y-this.min.y))}intersectsBox(e){return!(e.max.xthis.max.x||e.max.ythis.max.y)}clampPoint(e,t){return t.copy(e).clamp(this.min,this.max)}distanceToPoint(e){return DV.copy(e).clamp(this.min,this.max).sub(e).length()}intersect(e){return this.min.max(e.min),this.max.min(e.max),this}union(e){return this.min.min(e.min),this.max.max(e.max),this}translate(e){return this.min.add(e),this.max.add(e),this}equals(e){return e.min.equals(this.min)&&e.max.equals(this.max)}}sb.prototype.isBox2=!0;const Ah=new ne,fE=new Gt,jI=new Gt;function kV(n){const e=[];n&&n.isBone&&e.push(n);for(let t=0;tNumber.EPSILON){if(ge<0&&(he=H[K],Te=-Te,De=H[se],ge=-ge),A.yDe.y)continue;if(A.y===he.y){if(A.x===he.x)return!0}else{const Qe=ge*(A.x-he.x)-Te*(A.y-he.y);if(0===Qe)return!0;if(Qe<0)continue;X=!X}}else{if(A.y!==he.y)continue;if(De.x<=A.x&&A.x<=he.x||he.x<=A.x&&A.x<=De.x)return!0}}return X}const s=ru.isClockWise,o=this.subPaths;if(0===o.length)return[];if(!0===t)return i(o);let a,c,u;const p=[];if(1===o.length)return c=o[0],u=new iu,u.curves=c.curves,p.push(u),p;let g=!s(o[0].getPoints());g=e?!g:g;const v=[],y=[];let N,k,x=[],T=0;y[T]=void 0,x[T]=[];for(let A=0,H=o.length;A1){let A=!1;const H=[];for(let G=0,X=y.length;G0&&(A||(x=v))}for(let A=0,H=y.length;A0){this.source.connect(this.filters[0]);for(let e=1,t=this.filters.length;e0){this.source.disconnect(this.filters[0]);for(let e=1,t=this.filters.length;et.clone()),e}invert(){for(let t=0;t{class n{constructor(t,i){this.normal=t,this.w=i,this.normal=t,this.w=i}clone(){return new n(this.normal.clone(),this.w)}flip(){this.normal.negate(),this.w=-this.w}splitPolygon(t,i,r,s,o){let g=0;const v=[];for(let y=0;yn.EPSILON?1:0;g|=T,v.push(T)}switch(g){case 0:(this.normal.dot(t.plane.normal)>0?i:r).push(t);break;case 1:s.push(t);break;case 2:o.push(t);break;case 3:{const y=[],x=[];for(let T=0;T=3&&s.push(new A0(y,t.shared)),x.length>=3&&o.push(new A0(x,t.shared));break}}}static fromPoints(t,i,r){const s=(new Ca).copy(i).sub(t).cross((new Ca).copy(r).sub(t)).normalize();return new n(s.clone(),s.dot(t))}}return n.EPSILON=1e-5,n})();class A0{constructor(e,t){this.vertices=e,this.shared=t,this.plane=Nde.fromPoints(e[0].pos,e[1].pos,e[2].pos)}clone(){return new A0(this.vertices.map(e=>e.clone()),this.shared)}flip(){this.vertices.reverse().map(e=>e.flip()),this.plane.flip()}}class vE{constructor(e,t,i,r){this.pos=(new Ca).copy(e),this.normal=(new Ca).copy(t),this.uv=(new Ca).copy(i),this.uv.z=0,r&&(this.color=(new Ca).copy(r))}clone(){return new vE(this.pos,this.normal,this.uv,this.color)}flip(){this.normal.negate()}interpolate(e,t){return new vE(this.pos.clone().lerp(e.pos,t),this.normal.clone().lerp(e.normal,t),this.uv.clone().lerp(e.uv,t),this.color&&e.color&&this.color.clone().lerp(e.color,t))}}class br{constructor(){this.polygons=new Array}static fromPolygons(e){const t=new br;return t.polygons=e,t}static fromGeometry(e,t){let i=[];const r=e.attributes.position,s=e.attributes.normal,o=e.attributes.uv,a=e.attributes.color,c=e.groups;let u;if(e.index)u=e.index.array;else{u=new Array(r.array.length/r.itemSize|0);for(let g=0;g0)for(const T of c)u[g]>=T.start&&u[g]!isNaN(g.plane.normal.x)))}static toGeometry(e,t){let i=0;const r=e.polygons;for(const y of r)i+=y.vertices.length-2;const s=new gn,o=new $I(3*i*3),a=new $I(3*i*3),c=new Lde(2*i*3);let u;const p=[],g=[];for(const y of r){const x=y.vertices,T=x.length;void 0!==y.shared&&(p[y.shared]||(p[y.shared]=[])),T&&void 0!==x[0].color&&(u||(u=new $I(3*i*3)));for(let N=3;N<=T;N++)(void 0===y.shared?g:p[y.shared]).push(o.top/3,o.top/3+1,o.top/3+2),o.write(x[0].pos),o.write(x[N-2].pos),o.write(x[N-1].pos),a.write(x[0].normal),a.write(x[N-2].normal),a.write(x[N-1].normal),c&&(c.write(x[0].uv),c.write(x[N-2].uv),c.write(x[N-1].uv)),u&&(u.write(x[0].color),u.write(x[N-2].color),u.write(x[N-1].color))}s.setAttribute("position",new zi(o.array,3)),s.setAttribute("normal",new zi(a.array,3)),c&&s.setAttribute("uv",new zi(c.array,2)),u&&s.setAttribute("color",new zi(u.array,3));for(let y=0;yt.clone()).filter(t=>Number.isFinite(t.plane.w)),e}toPolygons(){return this.polygons}union(e){const t=new sd(this.clone().polygons),i=new sd(e.clone().polygons);return t.clipTo(i),i.clipTo(t),i.invert(),i.clipTo(t),i.invert(),t.build(i.allPolygons()),br.fromPolygons(t.allPolygons())}subtract(e){const t=new sd(this.clone().polygons),i=new sd(e.clone().polygons);return t.invert(),t.clipTo(i),i.clipTo(t),i.invert(),i.clipTo(t),i.invert(),t.build(i.allPolygons()),t.invert(),br.fromPolygons(t.allPolygons())}intersect(e){const t=new sd(this.clone().polygons),i=new sd(e.clone().polygons);return t.invert(),i.clipTo(t),i.invert(),t.clipTo(i),i.clipTo(t),t.build(i.allPolygons()),t.invert(),br.fromPolygons(t.allPolygons())}inverse(){const e=this.clone();for(const t of e.polygons)t.flip();return e}toMesh(e,t){return br.toMesh(this,e,t)}toGeometry(e){return br.toGeometry(this,e)}}class Bde{parse(e,t={}){const i=void 0!==t.binary&&t.binary,r=[];let s=0;e.traverse(function(k){if(k.isMesh){const A=k.geometry;if(!0!==A.isBufferGeometry)throw new Error("THREE.STLExporter: Geometry is not of type THREE.BufferGeometry.");const H=A.index,G=A.getAttribute("position");s+=null!==H?H.count/3:G.count/3,r.push({object3d:k,geometry:A})}});let o,a=80;if(!0===i){const A=new ArrayBuffer(2*s+3*s*4*4+80+4);o=new DataView(A),o.setUint32(a,s,!0),a+=4}else o="",o+="solid exported\n";const c=new ne,u=new ne,p=new ne,g=new ne,v=new ne,y=new ne;for(let k=0,A=r.length;k0?"active":"inactive",i.poi?Ti(4,13,yv(5,16,t.date,"y-M-d","GMT"),"icon"):""))("ngStyle",qu(55,qde,"hsl("+(120*(100-Ti(6,20,t.activities,i.calendarFilter)/864)/50-120)+", "+(Ti(7,23,t.activities,i.calendarFilter)>0?"100%":"0%")+", "+(Ti(8,26,t.activities,i.calendarFilter)>0?Ti(9,29,t.activities,i.calendarFilter)/864>50?100-vn(10,32,t.activities)/864+"%":"50%":"90%")+")"))("matTooltip",yv(11,34,t.date,"shortDate","GMT")+Ti(12,38,yv(13,41,t.date,"y-M-d","GMT"),"text")+": "+i.Math.floor(Ti(14,45,t.activities,i.calendarFilter)/86400*24)+"h "+i.Math.floor(Ti(15,48,t.activities,i.calendarFilter)%3600/60)+"m")}}function Yde(n,e){if(1&n){const t=Df();ke(0,"button",21),Gn("click",function(){R(t);const r=Jt().$implicit,s=Jt();return V(s.three(r,s.displayName,s.seasons.length))}),ft(1,"loadingReduce"),it(2,"Download STL"),Ne()}if(2&n){const t=Jt().$implicit;$e("disabled",vn(1,2,Jt().loadingArray))("id","download"+t.number)}}const Xde=function(n){return{width:n}};function Zde(n,e){if(1&n&&(ke(0,"div",14)(1,"div",15),it(2),Ne(),mt(3,Wde,3,3,"div",16),ke(4,"div",17),ft(5,"loadingReduce"),mt(6,Kde,16,57,"div",18),Ne(),mt(7,Yde,3,4,"button",19),Ne()),2&n){const t=e.$implicit,i=Jt();$e("ngStyle",qu(8,Xde,i.Math.ceil(t.days.length/7)+"em")),Le(2),Hi(t.name),Le(1),$e("ngIf",i.seasonTimes),Le(1),$e("ngClass",vn(5,6,i.loadingArray)?"loading":""),Le(2),$e("ngForOf",t.days),Le(1),$e("ngIf",i.downloadButtons)}}function Jde(n,e){1&n&&(ke(0,"mat-icon",22),it(1,"refresh"),Ne())}function Qde(n,e){1&n&&(ke(0,"mat-icon",37),it(1," trending_up "),Ne())}function eue(n,e){1&n&&(ke(0,"mat-icon",38),it(1," trending_flat "),Ne())}function tue(n,e){1&n&&(ke(0,"mat-icon",39),it(1," trending_down "),Ne())}function nue(n,e){1&n&&(ke(0,"mat-icon",37),it(1," trending_up "),Ne())}function iue(n,e){1&n&&(ke(0,"mat-icon",38),it(1," trending_flat "),Ne())}function rue(n,e){1&n&&(ke(0,"mat-icon",39),it(1," trending_down "),Ne())}function sue(n,e){if(1&n&&(ke(0,"div",24),mt(1,nue,2,0,"mat-icon",25),mt(2,iue,2,0,"mat-icon",26),mt(3,rue,2,0,"mat-icon",27),ke(4,"div",28)(5,"div",29)(6,"div",30),it(7),ft(8,"async"),ft(9,"manifest"),Ne(),qt(10,"img",41),ft(11,"async"),ft(12,"manifest"),ft(13,"async"),ft(14,"manifest"),Ne(),ke(15,"div",31)(16,"div",32)(17,"div",33),it(18),Ne(),ke(19,"div",34),it(20,"13 week avg"),Ne()(),ke(21,"div",35)(22,"div",33),it(23),Ne(),ke(24,"div",34),it(25,"52 week avg"),Ne()()()()()),2&n){const t=Jt().$implicit,i=Jt(2);Le(1),$e("ngIf",t.quarter>t.year),Le(1),$e("ngIf",t.quarter===t.year),Le(1),$e("ngIf",t.quarter60?i.Math.floor(t.quarter/60)+"h"+t.quarter%60:t.quarter,"m/week"),Le(5),xs("",t.year>60?i.Math.floor(t.year/60)+"h"+t.year%60:t.year,"m/week")}}function oue(n,e){if(1&n&&(av(0),mt(1,sue,26,23,"div",40),cv()),2&n){const t=e.$implicit;Le(1),$e("ngIf",t.quarter>0||t.year>0)}}function aue(n,e){if(1&n&&(ke(0,"div",23)(1,"div",24),mt(2,Qde,2,0,"mat-icon",25),ft(3,"loadingReduce"),mt(4,eue,2,0,"mat-icon",26),ft(5,"loadingReduce"),mt(6,tue,2,0,"mat-icon",27),ft(7,"loadingReduce"),ke(8,"div",28)(9,"div",29)(10,"div",30),it(11,"All Activities"),Ne()(),ke(12,"div",31)(13,"div",32)(14,"div",33),it(15),Ne(),ke(16,"div",34),it(17,"13 week avg"),Ne()(),ke(18,"div",35)(19,"div",33),it(20),Ne(),ke(21,"div",34),it(22,"52 week avg"),Ne()()()()(),mt(23,oue,2,1,"ng-container",36),Ne()),2&n){const t=Jt();Le(2),$e("ngIf",!vn(3,6,t.loadingArray)&&t.getOverallTrend().quarter>t.getOverallTrend().year),Le(2),$e("ngIf",!vn(5,8,t.loadingArray)&&t.getOverallTrend().quarter===t.getOverallTrend().year),Le(2),$e("ngIf",!vn(7,10,t.loadingArray)&&t.getOverallTrend().quarter60?t.Math.floor(t.getOverallTrend().quarter/60)+"h"+t.getOverallTrend().quarter%60:t.getOverallTrend().quarter,"m/week"),Le(5),xs("",t.getOverallTrend().year>60?t.Math.floor(t.getOverallTrend().year/60)+"h"+t.getOverallTrend().year%60:t.getOverallTrend().year,"m/week"),Le(3),$e("ngForOf",t.getModeTrends())}}class ob{constructor(e,t,i,r,s,o){this.dialog=t,this.manifestService=i,this.bungieQueue=r,this.bungieAuth=s,this.zone=o,this.membershipDataForCurrentUser$=new er(void 0),this.accountResponse$=new er([]),this.displayName="",this.downloadLink="",this.downloadButtons=!0,this.seasonTimes=!0,this.poi=!0,this.Math=Math,this.locale=e}addDay(e){this.days[e.getUTCFullYear()]||(this.days[e.getUTCFullYear()]={}),this.days[e.getUTCFullYear()][e.getUTCMonth()+1]||(this.days[e.getUTCFullYear()][e.getUTCMonth()+1]={}),this.days[e.getUTCFullYear()][e.getUTCMonth()+1][e.getUTCDate()]||(this.days[e.getUTCFullYear()][e.getUTCMonth()+1][e.getUTCDate()]={date:new Date(e),activities:[]}),this.seasons.some(t=>{if(e>=t.startDate)return t.days.push(this.days[e.getUTCFullYear()][e.getUTCMonth()+1][e.getUTCDate()]),!0}),this.flatDays.push(this.days[e.getUTCFullYear()][e.getUTCMonth()+1][e.getUTCDate()].activities)}ngOnInit(){this.loadingArray=[],this.calendarFilter="0",this.subs=[],this.activities=[],this.days={},this.flatDays=[],this.oneQuarterAgo=new Date((new Date).setDate((new Date).getDate()-91)),this.oneYearAgo=new Date((new Date).setDate((new Date).getDate()-364)),this.modeTrends={},this.overallTrend={quarter:[],year:[]},this.seasons=[{number:23,name:"Season of the Wish",days:[],startDate:new Date("2023-11-28")},{number:22,name:"Season of the Witch",days:[],startDate:new Date("2023-08-22")},{number:21,name:"Season of the Deep",days:[],startDate:new Date("2023-05-23")},{number:20,name:"Season of Defiance",days:[],startDate:new Date("2023-02-28")},{number:19,name:"Season of the Seraph",days:[],startDate:new Date("2022-12-06")},{number:18,name:"Season of Plunder",days:[],startDate:new Date("2022-08-23")},{number:17,name:"Season of the Haunted",days:[],startDate:new Date("2022-05-24")},{number:16,name:"Season of the Risen",days:[],startDate:new Date("2022-02-22")},{number:15,name:"Season of the Lost",days:[],startDate:new Date("2021-08-24")},{number:14,name:"Season of the Splicer",days:[],startDate:new Date("2021-05-11")},{number:13,name:"Season of the Chosen",days:[],startDate:new Date("2021-02-09")},{number:12,name:"Season of the Hunt",days:[],startDate:new Date("2020-11-10")},{number:11,name:"Season of Arrivals",days:[],startDate:new Date("2020-06-09")},{number:10,name:"Season of the Worthy",days:[],startDate:new Date("2020-03-10")},{number:9,name:"Season of Dawn",days:[],startDate:new Date("2019-12-10")},{number:8,name:"Season of Undying",days:[],startDate:new Date("2019-10-01")},{number:7,name:"Season of Opulence",days:[],startDate:new Date("2019-06-04")},{number:6,name:"Season of the Drifter",days:[],startDate:new Date("2019-03-05")},{number:5,name:"Season of the Forge",days:[],startDate:new Date("2018-12-04")},{number:4,name:"Season of the Outlaw",days:[],startDate:new Date("2018-09-04")},{number:3,name:"Warmind",days:[],startDate:new Date("2018-05-08")},{number:2,name:"Curse of Osiris",days:[],startDate:new Date("2017-12-05")},{number:1,name:"The Red War",days:[],startDate:new Date("2017-09-05")}],this.flatDaysBS=new er([]),this.manifestService.state$.subscribe(s=>{s.loaded&&(this.modeOptions=Object.keys(this.manifestService.defs.ActivityMode.dbTable).map(o=>this.manifestService.defs.ActivityMode.dbTable[o].modeType).sort())}),this.errorStatus="",this.errorMessage="";const e=new Date("2017-09-05T00:00:00Z"),t=new Date;for(;e<=t;)this.addDay(e),e.setDate(e.getDate()+1);this.seasons.reverse(),this.seasons.forEach((s,o)=>{s.startDateString=DD(s.startDate,"shortDate",this.locale||"en-US"),this.seasons[o+1]&&(s.endDateString=DD(this.seasons[o+1].startDate,"shortDate",this.locale||"en-US"))}),this.flatDaysBS.next(this.flatDays),this.yearKeys=Object.keys(this.days),this.monthKeys={},this.monthOffsets={2017:{9:0}};let i=0,r=28;this.dayKeys={},this.yearKeys.forEach(s=>{this.monthKeys[s]=Object.keys(this.days[s]),this.monthOffsets[s]||(this.monthOffsets[s]={}),this.dayKeys[s]={},this.monthKeys[s].forEach(o=>{this.monthOffsets[s][o]||(this.monthOffsets[s][o]=(r+i)%7,r=Object.keys(this.days[s][o]).length,i=this.monthOffsets[s][o]),this.dayKeys[s][o]=Object.keys(this.days[s][o])})}),this.subs.push(this.bungieAuth.hasValidAccessToken$.pipe(Rc(),Dr(s=>{s&&this.bungieQueue.addToQueue("getProfile",V8,c=>{this.membershipDataForCurrentUser$.next(c)})})).subscribe()),this.subs.push(this.membershipDataForCurrentUser$.pipe(Rc(),wo(s=>ig(s?.Response?.destinyMemberships.map(o=>{const a={loading:!0};this.loadingArray.push(a);const c=new er(void 0),{membershipId:u,membershipType:p}=o;return this.bungieQueue.addToQueue("getProfile",N8,x=>{x&&1===x.ErrorCode&&x?.Response?.characters?.length>0?ig(x?.Response?.characters.map(T=>{const N={loading:!0};this.loadingArray.push(N);const k=new er(void 0),{characterId:A}=T,H=T.merged?.allTime?.secondsPlayed?.basic?.value;return this.bungieQueue.addToQueue("getProfile",L8,K=>{if(1===K.ErrorCode){const he=K;he.Response.character=K.Response.character??{data:{characterId:A,membershipId:u,membershipType:p,minutesPlayedTotal:H?this.Math.floor(H/60):0}},k.next(he)}N.loading=!1,k.complete()},{characterId:A,destinyMembershipId:u,membershipType:p,components:[200]}),k})??Fc).pipe(Gr(1)).subscribe(T=>{c.next(T),a.loading=!1,c.complete()}):(a.loading=!1,c.complete())},{destinyMembershipId:u,membershipType:p,groups:[1]}),c})??Fc)),_t(s=>this.accountResponse$.next(s))).subscribe()),this.membershipDataForCurrentUser$.pipe(Rc(),_t(s=>{this.displayName=s?.Response?.bungieNetUser?.displayName})).subscribe(),this.characters$=this.accountResponse$.pipe(Rc(),_t(s=>{const o=[];for(const a of s)if(a)for(const c of a)try{o.push(c.Response.character.data)}catch{}return o})),this.minutesPlayedTotal=this.characters$.pipe(_t(s=>{let o=0;return s.forEach(a=>{o+=+a.minutesPlayedTotal}),o})),this.subs.push(this.characters$.pipe(Rc()).subscribe(s=>{this.activities=[],s.forEach(o=>{const a={destinyMembershipId:o.membershipId,membershipType:o.membershipType,characterId:o.characterId,mode:0,count:250};this.addHistorySub({...a,page:0}),this.addHistorySub({...a,page:1}),this.addHistorySub({...a,page:2})})}))}addHistorySub(e){const t={loading:!0};this.loadingArray.push(t);const{page:i}=e,r=new er(void 0);this.bungieQueue.addToQueue("getActivityHistory",B8,a=>{r.next(a)},e),this.subs.push(r.subscribe(a=>{1!==a?.ErrorCode&&a?.ErrorStatus&&(this.errorStatus=a.ErrorStatus,this.errorMessage=a.Message),a?.Response.activities&&a?.Response.activities.length&&(this.addHistorySub({...e,page:i+3}),a.Response.activities.forEach(c=>{c.characterId=e.characterId;const p=(new Date(c.period).getTime()-612e5)/1e3+c.values.startSeconds.basic.value,g=p+c.values.timePlayedSeconds.basic.value;c.startDate=new Date(1e3*p),c.endDate=new Date(1e3*g),this.activities.push(c);try{this.days[c.startDate.getUTCFullYear()][c.startDate.getUTCMonth()+1][c.startDate.getUTCDate()].activities.push(c),c.endDate>this.oneYearAgo&&(c.activityDetails.modes.forEach(v=>{this.modeTrends[v]||(this.modeTrends[v]={quarter:[],year:[]}),this.modeTrends[v].year.push(c),c.endDate>this.oneQuarterAgo&&this.modeTrends[v].quarter.push(c)}),this.overallTrend.year.push(c),c.endDate>this.oneQuarterAgo&&this.overallTrend.quarter.push(c))}catch{}this.flatDaysBS.next(this.flatDays)})),a&&(t.loading=!1,this.flatDaysBS.next(this.flatDays))}))}ngOnDestroy(){this.subs.forEach(e=>e.unsubscribe())}seasonActivities(e){return e.reduce((t,i)=>t.concat(i.activities),[])}three(e,t,i){this.zone.runOutsideAngular(r=>{let s,o,a,c,u,p,g,v,y;for(let N=1;N<=i;N++)s=document.getElementById("download"+N),s.setAttribute("disabled","true");s=document.getElementById("download"+e.number),s.innerHTML="Generating...";const x=2.5;!function T(){const N=new A2,k=2.5,A=Math.sqrt(7.25-5*Math.cos(Math.PI/2)),H=Math.acos((A*A+k*k-1)/(2*A*k));u=Math.ceil(e.days.length/7+2)*x,p=k*x,g=9*x,o=new tu(u,p,g);const G=new sE;a=new vr(o,G);const X=a.geometry.getAttribute("position");X.setXYZ(2,X.getX(2)+x,X.getY(2),X.getZ(2)+x),X.setXYZ(3,X.getX(3)+x,X.getY(3),X.getZ(3)-x),X.setXYZ(6,X.getX(6)-x,X.getY(6),X.getZ(6)-x),X.setXYZ(7,X.getX(7)-x,X.getY(7),X.getZ(7)+x),X.setXYZ(12,X.getX(12)-x,X.getY(12),X.getZ(12)+x),X.setXYZ(13,X.getX(13)+x,X.getY(13),X.getZ(13)+x),X.setXYZ(14,X.getX(14)-x,X.getY(14),X.getZ(14)-x),X.setXYZ(15,X.getX(15)+x,X.getY(15),X.getZ(15)-x),X.setXYZ(18,X.getX(18)-x,X.getY(18),X.getZ(18)+x),X.setXYZ(19,X.getX(19)+x,X.getY(19),X.getZ(19)+x),X.setXYZ(22,X.getX(22)+x,X.getY(22),X.getZ(22)-x),X.setXYZ(23,X.getX(23)-x,X.getY(23),X.getZ(23)-x),u=(Math.ceil(e.days.length/7+2)/2-1.5)*x,p=-p/2,g=7.5,a.position.set(u,p,g),a.updateMatrix();for(let K=0;KQe+Pe.values.timePlayedSeconds.basic.value,0)/86400*24;u=2.5,p=ge*x,g=2.5,o=new tu(u,p,g),c=new vr(o,G),u=(Math.floor(he/7)-52*Math.floor(he/364))*x,p=ge/2*x,g=(he%7+7*Math.floor(he/364))*x,c.position.set(u,p,g),c.updateMatrix(),a=br.union(a,c)}}(new Vde).load("assets/fonts/helvetiker_bold.typeface.json",function(K){v=2.5,y=.625,o=new yE(e.name,{font:K,size:v,height:y}),o.computeBoundingBox(),u=((Math.ceil(e.days.length/7)-o.boundingBox.max.x/x)/2-.5)*x,p=-4.375,g=20.5,c=new vr(o,G),c.position.set(u,p,g),c.rotateX(-H),c.updateMatrix(),a=br.union(a,c),c.geometry.dispose(),o=new yE(t,{font:K,size:v,height:y}),c=new vr(o,G),o.computeBoundingBox(),u=((Math.ceil(e.days.length/7)-o.boundingBox.max.x/x)/2-.5+o.boundingBox.max.x/x)*x,p=-4.375,g=-5.5,c.position.set(u,p,g),c.rotateX(H),c.rotateY(Math.PI),c.updateMatrix(),a=br.union(a,c),e.startDateString&&(o=new yE(e.startDateString,{font:K,size:v,height:y}),c=new vr(o,G),o.computeBoundingBox(),u=-5.5,p=-4.375,g=((7-o.boundingBox.max.x/x)/2-.5)*x,c.position.set(u,p,g),c.rotateZ(-H),c.rotateY(-Math.PI/2),c.updateMatrix(),a=br.union(a,c)),e.endDateString&&(o=new yE(e.endDateString,{font:K,size:v,height:y,curveSegments:12,bevelEnabled:!0,bevelThickness:0,bevelSize:0,bevelOffset:0,bevelSegments:0}),c=new vr(o,G),o.computeBoundingBox(),u=(Math.ceil(e.days.length/7)+1.2)*x,p=-4.375,g=((7-o.boundingBox.max.x/x)/2-.5+o.boundingBox.max.x/x)*x,c.position.set(u,p,g),c.rotateZ(H),c.rotateY(Math.PI/2),c.updateMatrix(),a=br.union(a,c)),a.geometry.rotateX(Math.PI/2),a.updateMatrix(),N.add(a);const he=new Bde,De=document.createElement("a");De.style.display="none",document.body.appendChild(De);const Te=he.parse(N);De.href=URL.createObjectURL(new Blob([Te],{type:"text/plain"})),De.download=`${e.name}.stl`,De.click(),N.remove(a),a.geometry.dispose(),s.innerHTML="Download STL";for(let ge=1;ge<=i;ge++)s=document.getElementById("download"+ge),s.removeAttribute("disabled")})}()})}getModeTrends(){return Object.keys(this.modeTrends).map(e=>({mode:Number(e),quarter:Math.round(this.modeTrends[Number(e)].quarter.reduce((t,i)=>t+(i.endDate-i.startDate),0)/13),year:Math.round(this.modeTrends[Number(e)].year.reduce((t,i)=>t+(i.endDate-i.startDate),0)/52)})).sort((e,t)=>t.year-e.year).sort((e,t)=>t.quarter-e.quarter).map(e=>({...e,quarter:Math.round(e.quarter/6e4),year:Math.round(e.year/6e4)}))}getOverallTrend(){return{quarter:Math.round(this.overallTrend.quarter.reduce((e,t)=>e+(t.endDate-t.startDate),0)/13/6e4),year:Math.round(this.overallTrend.year.reduce((e,t)=>e+(t.endDate-t.startDate),0)/52/6e4)}}}function cue(n,e){if(1&n&&(ke(0,"mat-card",1),it(1),Ne()),2&n){const t=e.$implicit;Le(1),xs(" ",t.AlertHtml,"\n")}}ob.\u0275fac=function(e){return new(e||ob)(ie(Ac),ie(Zw),ie(uh),ie(Jf),ie(qd),ie(Xt))},ob.\u0275cmp=Ln({type:ob,selectors:[["app-guardian-3d"]],decls:59,vars:40,consts:[["appearance","outlined","class","errorStatus",4,"ngIf"],[1,"mat-body-2"],[1,"mat-subtitle-2"],["aria-label","Search for Guardian","class","spinner",4,"ngIf"],[3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[1,"calYear"],["class","calMonth",3,"ngStyle",4,"ngFor","ngForOf"],[1,"trends-header"],["class","trending_loading",4,"ngIf"],["class","trends",4,"ngIf"],["appearance","outlined",1,"errorStatus"],["aria-label","Search for Guardian",1,"spinner"],[3,"value"],[1,"calMonth",3,"ngStyle"],[1,"monthLabel","mat-caption"],["class","monthLabel mat-caption",4,"ngIf"],[1,"dayWrapper",3,"ngClass"],["class","calDay",3,"ngClass","ngStyle","matTooltip",4,"ngFor","ngForOf"],["mat-button","","class","downloadButtons",3,"disabled","id","click",4,"ngIf"],[1,"calDay",3,"ngClass","ngStyle","matTooltip"],["mat-button","",1,"downloadButtons",3,"disabled","id","click"],[1,"trending_loading"],[1,"trends"],[1,"trend"],["class","trend-up",4,"ngIf"],["class","trend-flat",4,"ngIf"],["class","trend-down",4,"ngIf"],[1,"trend-main"],[1,"trend-header"],[1,"trend-name"],[1,"trend-values"],[1,"trend-quarter"],[1,"trend-value"],[1,"trend-time"],[1,"trend-year"],[4,"ngFor","ngForOf"],[1,"trend-up"],[1,"trend-flat"],[1,"trend-down"],["class","trend",4,"ngIf"],[1,"trend-icon",3,"src","alt"]],template:function(e,t){1&e&&(mt(0,zde,5,2,"mat-card",0),ke(1,"div",1),it(2," Name: "),ke(3,"span",2),it(4),Ne(),qt(5,"br"),it(6," Total Time in Destiny 2: "),ke(7,"span",2),it(8),ft(9,"hoursPlayed"),ft(10,"async"),Ne(),it(11," = "),ke(12,"span",2),it(13),ft(14,"parseMinutesPlayed"),ft(15,"async"),Ne(),qt(16,"br"),it(17," Total Time in Activities: "),ke(18,"span",2),it(19),ft(20,"activitiesTotalHours"),Ne(),it(21," = "),ke(22,"span",2),it(23),ft(24,"activitiesTotalTime"),Ne(),qt(25,"br"),it(26," Destiny 2 Activity Count: "),ke(27,"span",2),it(28),Ne(),mt(29,Gde,2,0,"mat-icon",3),ft(30,"loadingReduce"),qt(31,"br"),it(32),ft(33,"currentStreak"),qt(34,"br"),it(35),ft(36,"longestStreaks"),qt(37,"br"),it(38," STL Download Buttons: "),ke(39,"mat-checkbox",4),Gn("ngModelChange",function(r){return t.downloadButtons=r}),Ne(),qt(40,"br"),it(41," Points of Interest: "),ke(42,"mat-checkbox",4),Gn("ngModelChange",function(r){return t.poi=r}),Ne(),qt(43,"br"),it(44," Seasonal Times: "),ke(45,"mat-checkbox",4),Gn("ngModelChange",function(r){return t.seasonTimes=r}),Ne(),qt(46,"br"),it(47," Filter Heatmap: "),ke(48,"mat-form-field")(49,"mat-select",4),Gn("ngModelChange",function(r){return t.calendarFilter=r}),mt(50,jde,4,7,"mat-option",5),Ne()()(),ke(51,"div",6),mt(52,Zde,8,10,"div",7),Ne(),ke(53,"h3",8),it(54,"Trends"),Ne(),mt(55,Jde,2,0,"mat-icon",9),ft(56,"loadingReduce"),mt(57,aue,24,12,"div",10),ft(58,"loadingReduce")),2&e&&($e("ngIf",t.errorStatus),Le(4),Hi(t.displayName),Le(4),Hi(vn(9,18,vn(10,20,t.minutesPlayedTotal))),Le(5),Hi(vn(14,22,vn(15,24,t.minutesPlayedTotal))),Le(6),Hi(vn(20,26,t.activities)),Le(4),Hi(vn(24,28,t.activities)),Le(5),Hi(t.activities.length),Le(1),$e("ngIf",vn(30,30,t.loadingArray)),Le(3),xs(" Current Streak: ",vn(33,32,t.flatDays),""),Le(3),xs(" Longest Streaks: ",vn(36,34,t.flatDays),""),Le(4),$e("ngModel",t.downloadButtons),Le(3),$e("ngModel",t.poi),Le(3),$e("ngModel",t.seasonTimes),Le(4),$e("ngModel",t.calendarFilter),Le(1),$e("ngForOf",t.modeOptions),Le(2),$e("ngForOf",t.seasons),Le(3),$e("ngIf",vn(56,36,t.loadingArray)),Le(2),$e("ngIf",!vn(58,38,t.loadingArray)))},dependencies:[eg,tg,Yu,nw,cN,bN,nS,rA,_4,b4,BT,Uw,GT,zT,aT,Ew,Rf,k3,Yf,Xf,Tg,Ag,kg,Ig,Zf,Fg,Rg,Pg],styles:['.calYear[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;margin-top:1em}.calMonth[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin-right:.5em;margin-bottom:.5em}.dayWrapper[_ngcontent-%COMP%]{display:flex;flex-direction:column;height:7em;flex-wrap:wrap}.calDay[_ngcontent-%COMP%]{display:block;width:1em;height:1em;box-sizing:border-box;cursor:pointer;transition:transform .2s;background-position:center;background-size:16px}.calDay[_ngcontent-%COMP%]:hover.icon{transform:scale(1.5);z-index:999;box-shadow:0 0 8px 3px #696969;opacity:1}.calDay[_ngcontent-%COMP%]:before{content:" ";top:0;left:0;width:100%;height:100%;filter:invert(1);display:block;-webkit-mask-size:contain;mask-size:contain}.calDay.red-war[_ngcontent-%COMP%]:before{-webkit-mask-image:url(red-war.3eff2acca21c93ca.png);mask-image:url(red-war.3eff2acca21c93ca.png);background-color:inherit}.calDay.curse-of-osiris[_ngcontent-%COMP%]:before{-webkit-mask-image:url(curse-of-osiris.6c410487c8c1193b.png);mask-image:url(curse-of-osiris.6c410487c8c1193b.png);background-color:inherit}.calDay.dawning[_ngcontent-%COMP%]:before{-webkit-mask-image:url(dawning.645be67ef31d090a.png);mask-image:url(dawning.645be67ef31d090a.png);background-color:inherit}.calDay.crimson-days[_ngcontent-%COMP%]:before{-webkit-mask-image:url(crimson-days.aa88f4d939be6b4f.png);mask-image:url(crimson-days.aa88f4d939be6b4f.png);background-color:inherit}.calDay.warmind[_ngcontent-%COMP%]:before{-webkit-mask-image:url(warmind.af5f3877c551d0a9.png);mask-image:url(warmind.af5f3877c551d0a9.png);background-color:inherit}.calDay.moments-of-triumph[_ngcontent-%COMP%]:before{-webkit-mask-image:url(moments-of-triumph.3dd2b9684009007a.png);mask-image:url(moments-of-triumph.3dd2b9684009007a.png);background-color:inherit}.calDay.solstice[_ngcontent-%COMP%]:before{-webkit-mask-image:url(solstice.cb7917ad27da3310.png);mask-image:url(solstice.cb7917ad27da3310.png);background-color:inherit}.calDay.forsaken[_ngcontent-%COMP%]:before{-webkit-mask-image:url(forsaken.f61a352f91528263.png);mask-image:url(forsaken.f61a352f91528263.png);background-color:inherit}.calDay.festival-of-the-lost[_ngcontent-%COMP%]:before{-webkit-mask-image:url(festival-of-the-lost.656fb66ff23db261.png);mask-image:url(festival-of-the-lost.656fb66ff23db261.png);background-color:inherit}.calDay.season-of-the-forge[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-forge.a88ddb98b2a97a0e.png);mask-image:url(season-of-the-forge.a88ddb98b2a97a0e.png);background-color:inherit}.calDay.season-of-the-drifter[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-drifter.1867ff7e8c88eda5.png);mask-image:url(season-of-the-drifter.1867ff7e8c88eda5.png);background-color:inherit}.calDay.revelry[_ngcontent-%COMP%]:before{-webkit-mask-image:url(revelry.4a84f0f680e2599d.png);mask-image:url(revelry.4a84f0f680e2599d.png);background-color:inherit}.calDay.season-of-opulence[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-opulence.3b878d66365d9cc6.png);mask-image:url(season-of-opulence.3b878d66365d9cc6.png);background-color:inherit}.calDay.shadowkeep[_ngcontent-%COMP%]:before{-webkit-mask-image:url(shadowkeep.2412f7e9615345e8.png);mask-image:url(shadowkeep.2412f7e9615345e8.png);background-color:inherit}.calDay.season-of-the-undying[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-undying.a0948d4e1e5532ab.png);mask-image:url(season-of-the-undying.a0948d4e1e5532ab.png);background-color:inherit}.calDay.season-of-dawn[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-dawn.152fa5fa97203b11.png);mask-image:url(season-of-dawn.152fa5fa97203b11.png);background-color:inherit}.calDay.season-of-the-worthy[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-worthy.97fe2af14ad98313.png);mask-image:url(season-of-the-worthy.97fe2af14ad98313.png);background-color:inherit}.calDay.guardian-games[_ngcontent-%COMP%]:before{-webkit-mask-image:url(guardian-games.1458a297ee32ae52.png);mask-image:url(guardian-games.1458a297ee32ae52.png);background-color:inherit}.calDay.season-of-arrivals[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-arrivals.649a4db068c154bf.png);mask-image:url(season-of-arrivals.649a4db068c154bf.png);background-color:inherit}.calDay.beyond-light[_ngcontent-%COMP%]:before{-webkit-mask-image:url(beyond-light.8fb053c5e78ee3c1.png);mask-image:url(beyond-light.8fb053c5e78ee3c1.png);background-color:inherit}.calDay.season-of-the-hunt[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-hunt.23c0a09811c2dd46.png);mask-image:url(season-of-the-hunt.23c0a09811c2dd46.png);background-color:inherit}.calDay.season-of-the-chosen[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-chosen.9d73f0c6a48c8b28.png);mask-image:url(season-of-the-chosen.9d73f0c6a48c8b28.png);background-color:inherit}.calDay.season-of-the-splicer[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-splicer.5cff32b822f61b20.png);mask-image:url(season-of-the-splicer.5cff32b822f61b20.png);background-color:inherit}.calDay.season-of-the-lost[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-lost.10a416eb34d1915e.png);mask-image:url(season-of-the-lost.10a416eb34d1915e.png);background-color:inherit}.calDay.thirtieth-anniversary[_ngcontent-%COMP%]:before{-webkit-mask-image:url(thirtieth-anniversary.3aa725ceedf9157d.png);mask-image:url(thirtieth-anniversary.3aa725ceedf9157d.png);background-color:inherit}.calDay.witch-queen[_ngcontent-%COMP%]:before{-webkit-mask-image:url(witch-queen.4fdd67baed2eb636.png);mask-image:url(witch-queen.4fdd67baed2eb636.png);background-color:inherit}.calDay.season-of-the-haunted[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-haunted.d4556f3df7022cf7.png);mask-image:url(season-of-the-haunted.d4556f3df7022cf7.png);background-color:inherit}.calDay.iron-banner[_ngcontent-%COMP%]:before{-webkit-mask-image:url(iron-banner.0cccf5ef6d1f8153.png);mask-image:url(iron-banner.0cccf5ef6d1f8153.png);background-color:inherit}.calDay.solstice2022[_ngcontent-%COMP%]:before{-webkit-mask-image:url(solstice2022.4129b7a862b1dd62.png);mask-image:url(solstice2022.4129b7a862b1dd62.png);background-color:inherit}.calDay.raid[_ngcontent-%COMP%]:before{-webkit-mask-image:url(raid.c24a762febb5d48f.png);mask-image:url(raid.c24a762febb5d48f.png);background-color:inherit}.calDay.season-of-plunder[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-plunder.a82a4f350d3ff629.png);mask-image:url(season-of-plunder.a82a4f350d3ff629.png);background-color:inherit}.calDay.dungeon[_ngcontent-%COMP%]:before{-webkit-mask-image:url(dungeon.1e3bb371bcf5c37b.png);mask-image:url(dungeon.1e3bb371bcf5c37b.png);background-color:inherit}.calDay.season-of-the-seraph[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-seraph.30ab5d205a09f6c4.png);mask-image:url(season-of-the-seraph.30ab5d205a09f6c4.png);background-color:inherit}.calDay.lightfall[_ngcontent-%COMP%]:before{-webkit-mask-image:url(lightfall.cbc105e4dbc42ae7.png);mask-image:url(lightfall.cbc105e4dbc42ae7.png);background-color:inherit}.calDay.season-of-the-deep[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-deep.c79c733175700d33.png);mask-image:url(season-of-the-deep.c79c733175700d33.png);background-color:inherit}.calDay.exotic-quest[_ngcontent-%COMP%]:before{-webkit-mask-image:url(exotic-quest.bb278fc19eb3104c.png);mask-image:url(exotic-quest.bb278fc19eb3104c.png);background-color:inherit}.calDay.season-of-the-witch[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-witch.7978d2dee322e4cf.png);mask-image:url(season-of-the-witch.7978d2dee322e4cf.png);background-color:inherit}.calDay.season-of-the-wish[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-wish.97577548fcd7897c.png);mask-image:url(season-of-the-wish.97577548fcd7897c.png);background-color:inherit}@media (prefers-reduced-motion){.calDay[_ngcontent-%COMP%]{transition:none}.calDay[_ngcontent-%COMP%]:hover{transform:none;box-shadow:none;background-image:none}}.loading[_ngcontent-%COMP%] > .calDay[_ngcontent-%COMP%]{cursor:progress}.yearLabel[_ngcontent-%COMP%]{display:flex;align-items:center}.yearLabel[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{display:block;transform:rotate(-90deg)}.monthSpacer[_ngcontent-%COMP%]{width:1em}.monthLabel[_ngcontent-%COMP%]{font-size:.75em;min-width:13em;text-align:center}.downloadButtons[_ngcontent-%COMP%]{font-size:.75em;min-width:12em}.release[_ngcontent-%COMP%]:before{width:100%;height:100%}.raid[_ngcontent-%COMP%]:before, .event[_ngcontent-%COMP%]:before{width:100%;height:100%}@media (prefers-color-scheme: dark){.inactive[_ngcontent-%COMP%]{opacity:.15}}.spinner[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_spin 3s infinite linear;height:1em;width:1em;display:inline-block;line-height:1em;font-size:.75em}@keyframes _ngcontent-%COMP%_spin{0%{-webkit-transform:rotate(0deg)}to{-webkit-transform:rotate(360deg)}}@keyframes _ngcontent-%COMP%_spinX{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.errorStatus[_ngcontent-%COMP%]{margin-bottom:.5em}.trends-header[_ngcontent-%COMP%]{font-family:Roboto,Helvetica Neue,sans-serif}.trending_loading[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_spin 3s infinite linear}.trends[_ngcontent-%COMP%]{font-family:Roboto,Helvetica Neue,sans-serif;display:flex;flex-wrap:wrap;gap:1em}.trends[_ngcontent-%COMP%] .trend-up[_ngcontent-%COMP%]{color:green}.trends[_ngcontent-%COMP%] .trend-down[_ngcontent-%COMP%]{color:red}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.75em;min-width:17em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-header[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{height:1em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-time[_ngcontent-%COMP%]{font-size:.75em;opacity:.6}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-values[_ngcontent-%COMP%]{display:flex;gap:.75em}']});class ab{constructor(e){this.http=e}ngOnInit(){this.bungieStatus=new er([]),this.bungieSub=this.http.get("https://www.bungie.net/Platform/GlobalAlerts/").pipe(da(e=>Pc(e.error||"Server error"))).subscribe(e=>{try{this.bungieStatus.next(e.Response)}catch{}})}}function lue(n,e){1&n&&qt(0,"app-guardian")}function due(n,e){1&n&&qt(0,"app-guardian-3d")}ab.\u0275fac=function(e){return new(e||ab)(ie(Ju))},ab.\u0275cmp=Ln({type:ab,selectors:[["app-bungie-status"]],decls:2,vars:3,consts:[["appearance","outlined",4,"ngFor","ngForOf"],["appearance","outlined"]],template:function(e,t){1&e&&(mt(0,cue,2,1,"mat-card",0),ft(1,"async")),2&e&&$e("ngForOf",vn(1,1,t.bungieStatus))},dependencies:[tg,Uw,Rf]});class cb{calendarChange(e){this.calendar=e}constructor(e){this.bungieAuth=e}}cb.\u0275fac=function(e){return new(e||cb)(ie(qd))},cb.\u0275cmp=Ln({type:cb,selectors:[["app-root"]],decls:8,vars:7,consts:[[1,"appWrapper"],[1,"bungieStatus"],[1,"nav",3,"calendar","calendarChange"],[4,"ngIf"]],template:function(e,t){1&e&&(qt(0,"destiny-webring"),ke(1,"div",0),qt(2,"app-bungie-status",1),ke(3,"app-nav",2),Gn("calendarChange",function(r){return t.calendarChange(r)}),Ne(),mt(4,lue,1,0,"app-guardian",3),ft(5,"async"),mt(6,due,1,0,"app-guardian-3d",3),ft(7,"async"),Ne()),2&e&&(Le(3),$e("calendar",t.calendar),Le(1),$e("ngIf",vn(5,3,"gregorian"===t.calendar&&t.bungieAuth.hasValidAccessToken$)),Le(2),$e("ngIf",vn(7,5,"bungie"===t.calendar&&t.bungieAuth.hasValidAccessToken$)))},dependencies:[Yu,Dg,Sy,Dy,ob,ab,Rf],styles:[".appWrapper[_ngcontent-%COMP%]{display:flex;flex-direction:column;position:absolute;min-height:100%;top:0;left:.5em}.bungieStatus[_ngcontent-%COMP%], .nav[_ngcontent-%COMP%]{margin-top:.5em}.content[_ngcontent-%COMP%]{flex-grow:1}.footer[_ngcontent-%COMP%]{margin-bottom:.5em}"]});class lb{constructor(){}ngOnInit(){}}lb.\u0275fac=function(e){return new(e||lb)},lb.\u0275cmp=Ln({type:lb,selectors:[["app-front-page"]],decls:2,vars:0,consts:[[1,"mat-body-2"]],template:function(e,t){1&e&&(ke(0,"p",0),it(1,"Welcome back, Guardian."),Ne())}});const uue=[{path:"",component:lb},{path:"**",redirectTo:"",pathMatch:"full"}];class k0{}k0.\u0275fac=function(e){return new(e||k0)},k0.\u0275mod=Mt({type:k0}),k0.\u0275inj=On({imports:[C8.forRoot(uue,{}),C8]});const vp=void 0,fue=["en",[["a","p"],["AM","PM"],vp],[["AM","PM"],vp,vp],[["S","M","T","W","T","F","S"],["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],["Su","Mo","Tu","We","Th","Fr","Sa"]],vp,[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],["January","February","March","April","May","June","July","August","September","October","November","December"]],vp,[["B","A"],["BC","AD"],["Before Christ","Anno Domini"]],0,[6,0],["M/d/yy","MMM d, y","MMMM d, y","EEEE, MMMM d, y"],["h:mm a","h:mm:ss a","h:mm:ss a z","h:mm:ss a zzzz"],["{1}, {0}",vp,"{1} 'at' {0}",vp],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"USD","$","US Dollar",{},"ltr",function hue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length;return 1===t&&0===i?1:5}],us=void 0,BV=["fr",[["AM","PM"],us,us],us,[["D","L","M","M","J","V","S"],["dim.","lun.","mar.","mer.","jeu.","ven.","sam."],["dimanche","lundi","mardi","mercredi","jeudi","vendredi","samedi"],["di","lu","ma","me","je","ve","sa"]],us,[["J","F","M","A","M","J","J","A","S","O","N","D"],["janv.","f\xe9vr.","mars","avr.","mai","juin","juil.","ao\xfbt","sept.","oct.","nov.","d\xe9c."],["janvier","f\xe9vrier","mars","avril","mai","juin","juillet","ao\xfbt","septembre","octobre","novembre","d\xe9cembre"]],us,[["av. J.-C.","ap. J.-C."],us,["avant J\xe9sus-Christ","apr\xe8s J\xe9sus-Christ"]],1,[6,0],["dd/MM/y","d MMM y","d MMMM y","EEEE d MMMM y"],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1} {0}","{1}, {0}","{1} '\xe0' {0}",us],[",","\u202f",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0\xa0%","#,##0.00\xa0\xa4","#E0"],"EUR","\u20ac","euro",{ARS:["$AR","$"],AUD:["$AU","$"],BEF:["FB"],BMD:["$BM","$"],BND:["$BN","$"],BYN:[us,"\u0440."],BZD:["$BZ","$"],CAD:["$CA","$"],CLP:["$CL","$"],CNY:[us,"\xa5"],COP:["$CO","$"],CYP:["\xa3CY"],EGP:[us,"\xa3E"],FJD:["$FJ","$"],FKP:["\xa3FK","\xa3"],FRF:["F"],GBP:["\xa3GB","\xa3"],GIP:["\xa3GI","\xa3"],HKD:[us,"$"],IEP:["\xa3IE"],ILP:["\xa3IL"],ITL:["\u20a4IT"],JPY:[us,"\xa5"],KMF:[us,"FC"],LBP:["\xa3LB","\xa3L"],MTP:["\xa3MT"],MXN:["$MX","$"],NAD:["$NA","$"],NIO:[us,"$C"],NZD:["$NZ","$"],PHP:[us,"\u20b1"],RHD:["$RH"],RON:[us,"L"],RWF:[us,"FR"],SBD:["$SB","$"],SGD:["$SG","$"],SRD:["$SR","$"],TOP:[us,"$T"],TTD:["$TT","$"],TWD:[us,"NT$"],USD:["$US","$"],UYU:["$UY","$"],WST:["$WS"],XCD:[us,"$"],XPF:["FCFP"],ZMW:[us,"Kw"]},"ltr",function pue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length,r=parseInt(n.toString().replace(/^[^e]*(e([-+]?\d+))?/,"$2"))||0;return 0===t||1===t?1:0===r&&0!==t&&t%1e6==0&&0===i||!(r>=0&&r<=5)?4:5}],lr=void 0,VV=["es",[["a.\xa0m.","p.\xa0m."],lr,lr],lr,[["D","L","M","X","J","V","S"],["dom","lun","mar","mi\xe9","jue","vie","s\xe1b"],["domingo","lunes","martes","mi\xe9rcoles","jueves","viernes","s\xe1bado"],["DO","LU","MA","MI","JU","VI","SA"]],lr,[["E","F","M","A","M","J","J","A","S","O","N","D"],["ene","feb","mar","abr","may","jun","jul","ago","sept","oct","nov","dic"],["enero","febrero","marzo","abril","mayo","junio","julio","agosto","septiembre","octubre","noviembre","diciembre"]],lr,[["a. C.","d. C."],lr,["antes de Cristo","despu\xe9s de Cristo"]],1,[6,0],["d/M/yy","d MMM y","d 'de' MMMM 'de' y","EEEE, d 'de' MMMM 'de' y"],["H:mm","H:mm:ss","H:mm:ss z","H:mm:ss (zzzz)"],["{1}, {0}",lr,lr,lr],[",",".",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0\xa0%","#,##0.00\xa0\xa4","#E0"],"EUR","\u20ac","euro",{AUD:[lr,"$"],BRL:[lr,"R$"],BYN:[lr,"\u0440."],CAD:[lr,"$"],CNY:[lr,"\xa5"],EGP:[],ESP:["\u20a7"],GBP:[lr,"\xa3"],HKD:[lr,"$"],ILS:[lr,"\u20aa"],INR:[lr,"\u20b9"],JPY:[lr,"\xa5"],KRW:[lr,"\u20a9"],MXN:[lr,"$"],NZD:[lr,"$"],PHP:[lr,"\u20b1"],RON:[lr,"L"],THB:["\u0e3f"],TWD:[lr,"NT$"],USD:["US$","$"],XAF:[],XCD:[lr,"$"],XOF:[]},"ltr",function mue(n){const e=n,t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length,r=parseInt(n.toString().replace(/^[^e]*(e([-+]?\d+))?/,"$2"))||0;return 1===e?1:0===r&&0!==t&&t%1e6==0&&0===i||!(r>=0&&r<=5)?4:5}],ac=void 0,_ue=["pt",[["AM","PM"],ac,ac],ac,[["D","S","T","Q","Q","S","S"],["dom.","seg.","ter.","qua.","qui.","sex.","s\xe1b."],["domingo","segunda-feira","ter\xe7a-feira","quarta-feira","quinta-feira","sexta-feira","s\xe1bado"],["dom.","seg.","ter.","qua.","qui.","sex.","s\xe1b."]],ac,[["J","F","M","A","M","J","J","A","S","O","N","D"],["jan.","fev.","mar.","abr.","mai.","jun.","jul.","ago.","set.","out.","nov.","dez."],["janeiro","fevereiro","mar\xe7o","abril","maio","junho","julho","agosto","setembro","outubro","novembro","dezembro"]],ac,[["a.C.","d.C."],ac,["antes de Cristo","depois de Cristo"]],0,[6,0],["dd/MM/y","d 'de' MMM 'de' y","d 'de' MMMM 'de' y","EEEE, d 'de' MMMM 'de' y"],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1} {0}",ac,ac,ac],[",",".",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4\xa0#,##0.00","#E0"],"BRL","R$","Real brasileiro",{AUD:["AU$","$"],BYN:[ac,"\u0440."],JPY:["JP\xa5","\xa5"],PHP:[ac,"\u20b1"],PTE:["Esc."],RON:[ac,"L"],SYP:[ac,"S\xa3"],THB:["\u0e3f"],TWD:["NT$"],USD:["US$","$"]},"ltr",function gue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length,r=parseInt(n.toString().replace(/^[^e]*(e([-+]?\d+))?/,"$2"))||0;return t===Math.floor(t)&&t>=0&&t<=1?1:0===r&&0!==t&&t%1e6==0&&0===i||!(r>=0&&r<=5)?4:5}],Da=void 0,HV=["zh",[["\u4e0a\u5348","\u4e0b\u5348"],Da,Da],Da,[["\u65e5","\u4e00","\u4e8c","\u4e09","\u56db","\u4e94","\u516d"],["\u5468\u65e5","\u5468\u4e00","\u5468\u4e8c","\u5468\u4e09","\u5468\u56db","\u5468\u4e94","\u5468\u516d"],["\u661f\u671f\u65e5","\u661f\u671f\u4e00","\u661f\u671f\u4e8c","\u661f\u671f\u4e09","\u661f\u671f\u56db","\u661f\u671f\u4e94","\u661f\u671f\u516d"],["\u5468\u65e5","\u5468\u4e00","\u5468\u4e8c","\u5468\u4e09","\u5468\u56db","\u5468\u4e94","\u5468\u516d"]],Da,[["1","2","3","4","5","6","7","8","9","10","11","12"],["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],["\u4e00\u6708","\u4e8c\u6708","\u4e09\u6708","\u56db\u6708","\u4e94\u6708","\u516d\u6708","\u4e03\u6708","\u516b\u6708","\u4e5d\u6708","\u5341\u6708","\u5341\u4e00\u6708","\u5341\u4e8c\u6708"]],Da,[["\u516c\u5143\u524d","\u516c\u5143"],Da,Da],0,[6,0],["y/M/d","y\u5e74M\u6708d\u65e5",Da,"y\u5e74M\u6708d\u65e5EEEE"],["HH:mm","HH:mm:ss","z HH:mm:ss","zzzz HH:mm:ss"],["{1} {0}",Da,Da,Da],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"CNY","\xa5","\u4eba\u6c11\u5e01",{AUD:["AU$","$"],BYN:[Da,"\u0440."],CNY:["\xa5"],ILR:["ILS"],JPY:["JP\xa5","\xa5"],KRW:["\uffe6","\u20a9"],PHP:[Da,"\u20b1"],RUR:[Da,"\u0440."],TWD:["NT$"],USD:["US$","$"],XXX:[]},"ltr",function vue(n){return 5}],so=void 0,UV=["de",[["AM","PM"],so,so],so,[["S","M","D","M","D","F","S"],["So.","Mo.","Di.","Mi.","Do.","Fr.","Sa."],["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],["So.","Mo.","Di.","Mi.","Do.","Fr.","Sa."]],[["S","M","D","M","D","F","S"],["So","Mo","Di","Mi","Do","Fr","Sa"],["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],["So.","Mo.","Di.","Mi.","Do.","Fr.","Sa."]],[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan.","Feb.","M\xe4rz","Apr.","Mai","Juni","Juli","Aug.","Sept.","Okt.","Nov.","Dez."],["Januar","Februar","M\xe4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]],[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","M\xe4r","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"],["Januar","Februar","M\xe4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]],[["v. Chr.","n. Chr."],so,so],1,[6,0],["dd.MM.yy","dd.MM.y","d. MMMM y","EEEE, d. MMMM y"],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1}, {0}",so,"{1} 'um' {0}",so],[",",".",";","%","+","-","E","\xb7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0\xa0%","#,##0.00\xa0\xa4","#E0"],"EUR","\u20ac","Euro",{ATS:["\xf6S"],AUD:["AU$","$"],BGM:["BGK"],BGO:["BGJ"],BYN:[so,"\u0440."],CUC:[so,"Cub$"],DEM:["DM"],FKP:[so,"Fl\xa3"],GHS:[so,"\u20b5"],GNF:[so,"F.G."],KMF:[so,"FC"],PHP:[so,"\u20b1"],RON:[so,"L"],RUR:[so,"\u0440."],RWF:[so,"F.Rw"],SYP:[],THB:["\u0e3f"],TWD:["NT$"],XXX:[],ZMW:[so,"K"]},"ltr",function yue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length;return 1===t&&0===i?1:5}],ha=void 0,zV=["ja",[["\u5348\u524d","\u5348\u5f8c"],ha,ha],ha,[["\u65e5","\u6708","\u706b","\u6c34","\u6728","\u91d1","\u571f"],ha,["\u65e5\u66dc\u65e5","\u6708\u66dc\u65e5","\u706b\u66dc\u65e5","\u6c34\u66dc\u65e5","\u6728\u66dc\u65e5","\u91d1\u66dc\u65e5","\u571f\u66dc\u65e5"],["\u65e5","\u6708","\u706b","\u6c34","\u6728","\u91d1","\u571f"]],ha,[["1","2","3","4","5","6","7","8","9","10","11","12"],["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],ha],ha,[["BC","AD"],["\u7d00\u5143\u524d","\u897f\u66a6"],ha],0,[6,0],["y/MM/dd",ha,"y\u5e74M\u6708d\u65e5","y\u5e74M\u6708d\u65e5EEEE"],["H:mm","H:mm:ss","H:mm:ss z","H\u6642mm\u5206ss\u79d2 zzzz"],["{1} {0}",ha,ha,ha],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"JPY","\uffe5","\u65e5\u672c\u5186",{BYN:[ha,"\u0440."],CNY:["\u5143","\uffe5"],JPY:["\uffe5"],PHP:[ha,"\u20b1"],RON:[ha,"\u30ec\u30a4"],XXX:[]},"ltr",function bue(n){return 5}],Ta=void 0,GV=["ko",[["AM","PM"],Ta,["\uc624\uc804","\uc624\ud6c4"]],Ta,[["\uc77c","\uc6d4","\ud654","\uc218","\ubaa9","\uae08","\ud1a0"],Ta,["\uc77c\uc694\uc77c","\uc6d4\uc694\uc77c","\ud654\uc694\uc77c","\uc218\uc694\uc77c","\ubaa9\uc694\uc77c","\uae08\uc694\uc77c","\ud1a0\uc694\uc77c"],["\uc77c","\uc6d4","\ud654","\uc218","\ubaa9","\uae08","\ud1a0"]],Ta,[["1\uc6d4","2\uc6d4","3\uc6d4","4\uc6d4","5\uc6d4","6\uc6d4","7\uc6d4","8\uc6d4","9\uc6d4","10\uc6d4","11\uc6d4","12\uc6d4"],Ta,Ta],Ta,[["BC","AD"],Ta,["\uae30\uc6d0\uc804","\uc11c\uae30"]],0,[6,0],["yy. M. d.","y. M. d.","y\ub144 M\uc6d4 d\uc77c","y\ub144 M\uc6d4 d\uc77c EEEE"],["a h:mm","a h:mm:ss","a h\uc2dc m\ubd84 s\ucd08 z","a h\uc2dc m\ubd84 s\ucd08 zzzz"],["{1} {0}",Ta,Ta,Ta],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"KRW","\u20a9","\ub300\ud55c\ubbfc\uad6d \uc6d0",{AUD:["AU$","$"],BYN:[Ta,"\u0440."],JPY:["JP\xa5","\xa5"],PHP:[Ta,"\u20b1"],RON:[Ta,"L"],TWD:["NT$"],USD:["US$","$"]},"ltr",function xue(n){return 5}],oo=void 0,jV=["it",[["m.","p."],["AM","PM"],oo],oo,[["D","L","M","M","G","V","S"],["dom","lun","mar","mer","gio","ven","sab"],["domenica","luned\xec","marted\xec","mercoled\xec","gioved\xec","venerd\xec","sabato"],["dom","lun","mar","mer","gio","ven","sab"]],oo,[["G","F","M","A","M","G","L","A","S","O","N","D"],["gen","feb","mar","apr","mag","giu","lug","ago","set","ott","nov","dic"],["gennaio","febbraio","marzo","aprile","maggio","giugno","luglio","agosto","settembre","ottobre","novembre","dicembre"]],oo,[["aC","dC"],["a.C.","d.C."],["avanti Cristo","dopo Cristo"]],1,[6,0],["dd/MM/yy","d MMM y","d MMMM y","EEEE d MMMM y"],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1}, {0}",oo,"{1} {0}",oo],[",",".",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","#,##0.00\xa0\xa4","#E0"],"EUR","\u20ac","euro",{BRL:[oo,"R$"],BYN:[oo,"Br"],EGP:[oo,"\xa3E"],HKD:[oo,"$"],INR:[oo,"\u20b9"],JPY:[oo,"\xa5"],KRW:[oo,"\u20a9"],MXN:[oo,"$"],NOK:[oo,"NKr"],THB:["\u0e3f"],TWD:[oo,"NT$"],USD:[oo,"$"],VND:[oo,"\u20ab"]},"ltr",function wue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length,r=parseInt(n.toString().replace(/^[^e]*(e([-+]?\d+))?/,"$2"))||0;return 1===t&&0===i?1:0===r&&0!==t&&t%1e6==0&&0===i||!(r>=0&&r<=5)?4:5}],yl=void 0,WV=["ru",[["AM","PM"],yl,yl],yl,[["\u0412","\u041f","\u0412","\u0421","\u0427","\u041f","\u0421"],["\u0432\u0441","\u043f\u043d","\u0432\u0442","\u0441\u0440","\u0447\u0442","\u043f\u0442","\u0441\u0431"],["\u0432\u043e\u0441\u043a\u0440\u0435\u0441\u0435\u043d\u044c\u0435","\u043f\u043e\u043d\u0435\u0434\u0435\u043b\u044c\u043d\u0438\u043a","\u0432\u0442\u043e\u0440\u043d\u0438\u043a","\u0441\u0440\u0435\u0434\u0430","\u0447\u0435\u0442\u0432\u0435\u0440\u0433","\u043f\u044f\u0442\u043d\u0438\u0446\u0430","\u0441\u0443\u0431\u0431\u043e\u0442\u0430"],["\u0432\u0441","\u043f\u043d","\u0432\u0442","\u0441\u0440","\u0447\u0442","\u043f\u0442","\u0441\u0431"]],yl,[["\u042f","\u0424","\u041c","\u0410","\u041c","\u0418","\u0418","\u0410","\u0421","\u041e","\u041d","\u0414"],["\u044f\u043d\u0432.","\u0444\u0435\u0432\u0440.","\u043c\u0430\u0440.","\u0430\u043f\u0440.","\u043c\u0430\u044f","\u0438\u044e\u043d.","\u0438\u044e\u043b.","\u0430\u0432\u0433.","\u0441\u0435\u043d\u0442.","\u043e\u043a\u0442.","\u043d\u043e\u044f\u0431.","\u0434\u0435\u043a."],["\u044f\u043d\u0432\u0430\u0440\u044f","\u0444\u0435\u0432\u0440\u0430\u043b\u044f","\u043c\u0430\u0440\u0442\u0430","\u0430\u043f\u0440\u0435\u043b\u044f","\u043c\u0430\u044f","\u0438\u044e\u043d\u044f","\u0438\u044e\u043b\u044f","\u0430\u0432\u0433\u0443\u0441\u0442\u0430","\u0441\u0435\u043d\u0442\u044f\u0431\u0440\u044f","\u043e\u043a\u0442\u044f\u0431\u0440\u044f","\u043d\u043e\u044f\u0431\u0440\u044f","\u0434\u0435\u043a\u0430\u0431\u0440\u044f"]],[["\u042f","\u0424","\u041c","\u0410","\u041c","\u0418","\u0418","\u0410","\u0421","\u041e","\u041d","\u0414"],["\u044f\u043d\u0432.","\u0444\u0435\u0432\u0440.","\u043c\u0430\u0440\u0442","\u0430\u043f\u0440.","\u043c\u0430\u0439","\u0438\u044e\u043d\u044c","\u0438\u044e\u043b\u044c","\u0430\u0432\u0433.","\u0441\u0435\u043d\u0442.","\u043e\u043a\u0442.","\u043d\u043e\u044f\u0431.","\u0434\u0435\u043a."],["\u044f\u043d\u0432\u0430\u0440\u044c","\u0444\u0435\u0432\u0440\u0430\u043b\u044c","\u043c\u0430\u0440\u0442","\u0430\u043f\u0440\u0435\u043b\u044c","\u043c\u0430\u0439","\u0438\u044e\u043d\u044c","\u0438\u044e\u043b\u044c","\u0430\u0432\u0433\u0443\u0441\u0442","\u0441\u0435\u043d\u0442\u044f\u0431\u0440\u044c","\u043e\u043a\u0442\u044f\u0431\u0440\u044c","\u043d\u043e\u044f\u0431\u0440\u044c","\u0434\u0435\u043a\u0430\u0431\u0440\u044c"]],[["\u0434\u043e \u043d.\u044d.","\u043d.\u044d."],["\u0434\u043e \u043d. \u044d.","\u043d. \u044d."],["\u0434\u043e \u0420\u043e\u0436\u0434\u0435\u0441\u0442\u0432\u0430 \u0425\u0440\u0438\u0441\u0442\u043e\u0432\u0430","\u043e\u0442 \u0420\u043e\u0436\u0434\u0435\u0441\u0442\u0432\u0430 \u0425\u0440\u0438\u0441\u0442\u043e\u0432\u0430"]],1,[6,0],["dd.MM.y","d MMM y '\u0433'.","d MMMM y '\u0433'.","EEEE, d MMMM y '\u0433'."],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1}, {0}",yl,yl,yl],[",","\xa0",";","%","+","-","E","\xd7","\u2030","\u221e","\u043d\u0435\xa0\u0447\u0438\u0441\u043b\u043e",":"],["#,##0.###","#,##0\xa0%","#,##0.00\xa0\xa4","#E0"],"RUB","\u20bd","\u0440\u043e\u0441\u0441\u0438\u0439\u0441\u043a\u0438\u0439 \u0440\u0443\u0431\u043b\u044c",{BYN:[yl,"\u0440."],GEL:[yl,"\u10da"],PHP:[yl,"\u20b1"],RON:[yl,"L"],RUB:["\u20bd"],RUR:["\u0440."],THB:["\u0e3f"],TMT:["\u0422\u041c\u0422"],TWD:["NT$"],UAH:["\u20b4"],XXX:["XXXX"]},"ltr",function Sue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length;return 0===i&&t%10==1&&t%100!=11?1:0===i&&t%10===Math.floor(t%10)&&t%10>=2&&t%10<=4&&!(t%100>=12&&t%100<=14)?3:0===i&&t%10==0||0===i&&t%10===Math.floor(t%10)&&t%10>=5&&t%10<=9||0===i&&t%100===Math.floor(t%100)&&t%100>=11&&t%100<=14?4:5}],hs=void 0,$V=["pl",[["a","p"],["AM","PM"],hs],hs,[["n","p","w","\u015b","c","p","s"],["niedz.","pon.","wt.","\u015br.","czw.","pt.","sob."],["niedziela","poniedzia\u0142ek","wtorek","\u015broda","czwartek","pi\u0105tek","sobota"],["nie","pon","wto","\u015bro","czw","pi\u0105","sob"]],[["N","P","W","\u015a","C","P","S"],["niedz.","pon.","wt.","\u015br.","czw.","pt.","sob."],["niedziela","poniedzia\u0142ek","wtorek","\u015broda","czwartek","pi\u0105tek","sobota"],["nie","pon","wto","\u015bro","czw","pi\u0105","sob"]],[["s","l","m","k","m","c","l","s","w","p","l","g"],["sty","lut","mar","kwi","maj","cze","lip","sie","wrz","pa\u017a","lis","gru"],["stycznia","lutego","marca","kwietnia","maja","czerwca","lipca","sierpnia","wrze\u015bnia","pa\u017adziernika","listopada","grudnia"]],[["S","L","M","K","M","C","L","S","W","P","L","G"],["sty","lut","mar","kwi","maj","cze","lip","sie","wrz","pa\u017a","lis","gru"],["stycze\u0144","luty","marzec","kwiecie\u0144","maj","czerwiec","lipiec","sierpie\u0144","wrzesie\u0144","pa\u017adziernik","listopad","grudzie\u0144"]],[["p.n.e.","n.e."],hs,["przed nasz\u0105 er\u0105","naszej ery"]],1,[6,0],["d.MM.y","d MMM y","d MMMM y","EEEE, d MMMM y"],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1}, {0}",hs,"{1} {0}",hs],[",","\xa0",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","#,##0.00\xa0\xa4","#E0"],"PLN","z\u0142","z\u0142oty polski",{AUD:[hs,"$"],CAD:[hs,"$"],CNY:[hs,"\xa5"],GBP:[hs,"\xa3"],HKD:[hs,"$"],ILS:[hs,"\u20aa"],INR:[hs,"\u20b9"],JPY:[hs,"\xa5"],KRW:[hs,"\u20a9"],MXN:[hs,"$"],NZD:[hs,"$"],PHP:[hs,"\u20b1"],PLN:["z\u0142"],RON:[hs,"lej"],TWD:[hs,"NT$"],USD:[hs,"$"],VND:[hs,"\u20ab"]},"ltr",function Eue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length;return 1===t&&0===i?1:0===i&&t%10===Math.floor(t%10)&&t%10>=2&&t%10<=4&&!(t%100>=12&&t%100<=14)?3:0===i&&1!==t&&t%10===Math.floor(t%10)&&t%10>=0&&t%10<=1||0===i&&t%10===Math.floor(t%10)&&t%10>=5&&t%10<=9||0===i&&t%100===Math.floor(t%100)&&t%100>=12&&t%100<=14?4:5}];let As="en";Es(fue),navigator.languages.some(n=>{switch(n.toLowerCase()){case"pt-br":return Es(_ue),As=n,!0;case"zh-cht":case"zh-chs":return Es(HV),As=n,!0;case"fr":return Es(BV),As=n,!0;case"es":return Es(VV),As=n,!0;case"de":return Es(UV),As=n,!0;case"it":return Es(jV),As=n,!0;case"ja":return Es(zV),As="ja",!0;case"ru":return Es(WV),As=n,!0;case"pl":return Es($V),As=n,!0;case"ko":return Es(GV),As=n,!0}switch(n.toLowerCase().split("-")[0]){case"fr":return Es(BV),As=n,!0;case"es":return Es(VV),As=n,!0;case"de":return Es(UV),As=n,!0;case"it":return Es(jV),As=n,!0;case"ja":return Es(zV),As="ja",!0;case"ru":return Es(WV),As=n,!0;case"pl":return Es($V),As=n,!0;case"ko":return Es(GV),As=n,!0}});class I0{}I0.\u0275fac=function(e){return new(e||I0)},I0.\u0275mod=Mt({type:I0,bootstrap:[cb]}),I0.\u0275inj=On({providers:[{provide:Ac,useValue:As}],imports:[nO,BJ,uN,yq,Iq,s4,VX,cY,EX,Yq,wW,yj,k0,gg,Dg]}),HG().bootstrapModule(I0).catch(n=>console.log(n))},8410:function(Aa,ka){!function(dt){"use strict";var qr="function"==typeof WeakSet,le=Object.keys;function pt(Pt,$t){Pt&&"object"==typeof Pt&&$t.add(Pt)}function ps(Pt,$t,Qn,In){for(var Fn,fn=Pt.length,sr=0;sr{var l,f,_,b,E,M,D,F,P,U,I,h,qr={userAgent:!1},le={},pt=pt||(l=Math,_=(f={}).lib={},b=_.Base=function(){function C(){}return{extend:function(B){C.prototype=this;var R=new C;return B&&R.mixIn(B),R.hasOwnProperty("init")||(R.init=function(){R.$super.init.apply(this,arguments)}),R.init.prototype=R,R.$super=this,R},create:function(){var B=this.extend();return B.init.apply(B,arguments),B},init:function(){},mixIn:function(B){for(var R in B)B.hasOwnProperty(R)&&(this[R]=B[R]);B.hasOwnProperty("toString")&&(this.toString=B.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),E=_.WordArray=b.extend({init:function(C,B){C=this.words=C||[],this.sigBytes=null!=B?B:4*C.length},toString:function(C){return(C||D).stringify(this)},concat:function(C){var B=this.words,R=C.words,V=this.sigBytes,L=C.sigBytes;if(this.clamp(),V%4)for(var $=0;$>>2]|=(R[$>>>2]>>>24-$%4*8&255)<<24-(V+$)%4*8;else for($=0;$>>2]=R[$>>>2];return this.sigBytes+=L,this},clamp:function(){var C=this.words,B=this.sigBytes;C[B>>>2]&=4294967295<<32-B%4*8,C.length=l.ceil(B/4)},clone:function(){var C=b.clone.call(this);return C.words=this.words.slice(0),C},random:function(C){for(var B=[],R=0;R>>2]>>>24-L%4*8&255;V.push(($>>>4).toString(16)),V.push((15&$).toString(16))}return V.join("")},parse:function(C){for(var B=C.length,R=[],V=0;V>>3]|=parseInt(C.substr(V,2),16)<<24-V%8*4;return new E.init(R,B/2)}},F=M.Latin1={stringify:function(C){for(var B=C.words,R=C.sigBytes,V=[],L=0;L>>2]>>>24-L%4*8&255));return V.join("")},parse:function(C){for(var B=C.length,R=[],V=0;V>>2]|=(255&C.charCodeAt(V))<<24-V%4*8;return new E.init(R,B)}},P=M.Utf8={stringify:function(C){try{return decodeURIComponent(escape(F.stringify(C)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(C){return F.parse(unescape(encodeURIComponent(C)))}},U=_.BufferedBlockAlgorithm=b.extend({reset:function(){this._data=new E.init,this._nDataBytes=0},_append:function(C){"string"==typeof C&&(C=P.parse(C)),this._data.concat(C),this._nDataBytes+=C.sigBytes},_process:function(C){var B=this._data,R=B.words,V=B.sigBytes,L=this.blockSize,J=V/(4*L),Q=(J=C?l.ceil(J):l.max((0|J)-this._minBufferSize,0))*L,te=l.min(4*Q,V);if(Q){for(var Se=0;Se>>2]}},h.BlockCipher=D.extend({cfg:D.cfg.extend({mode:z,padding:P}),reset:function(){D.reset.call(this);var R=(V=this.cfg).iv,V=V.mode;if(this._xformMode==this._ENC_XFORM_MODE)var L=V.createEncryptor;else L=V.createDecryptor,this._minBufferSize=1;this._mode=L.call(V,this,R&&R.words)},_doProcessBlock:function(R,V){this._mode.processBlock(R,V)},_doFinalize:function(){var R=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){R.pad(this._data,this.blockSize);var V=this._process(!0)}else V=this._process(!0),R.unpad(V);return V},blockSize:4});var U=h.CipherParams=f.extend({init:function(R){this.mixIn(R)},toString:function(R){return(R||this.formatter).stringify(this)}}),I=(z=(C.format={}).OpenSSL={stringify:function(R){var V=R.ciphertext;return((R=R.salt)?_.create([1398893684,1701076831]).concat(R).concat(V):V).toString(E)},parse:function(R){var V=(R=E.parse(R)).words;if(1398893684==V[0]&&1701076831==V[1]){var L=_.create(V.slice(2,4));V.splice(0,4),R.sigBytes-=16}return U.create({ciphertext:R,salt:L})}},h.SerializableCipher=f.extend({cfg:f.extend({format:z}),encrypt:function(R,V,L,$){$=this.cfg.extend($);var J=R.createEncryptor(L,$);return V=J.finalize(V),U.create({ciphertext:V,key:L,iv:(J=J.cfg).iv,algorithm:R,mode:J.mode,padding:J.padding,blockSize:R.blockSize,formatter:$.format})},decrypt:function(R,V,L,$){return $=this.cfg.extend($),V=this._parse(V,$.format),R.createDecryptor(L,$).finalize(V.ciphertext)},_parse:function(R,V){return"string"==typeof R?V.parse(R,this):R}})),C=(C.kdf={}).OpenSSL={execute:function(R,V,L,$){return $||($=_.random(8)),R=M.create({keySize:V+L}).compute(R,$),L=_.create(R.words.slice(V),4*L),R.sigBytes=4*V,U.create({key:R,iv:L,salt:$})}},B=h.PasswordBasedCipher=I.extend({cfg:I.cfg.extend({kdf:C}),encrypt:function(R,V,L,$){return L=($=this.cfg.extend($)).kdf.execute(L,R.keySize,R.ivSize),$.iv=L.iv,(R=I.encrypt.call(this,R,V,L.key,$)).mixIn(L),R},decrypt:function(R,V,L,$){return $=this.cfg.extend($),V=this._parse(V,$.format),L=$.kdf.execute(L,R.keySize,R.ivSize,V.salt),$.iv=L.iv,I.decrypt.call(this,R,V,L.key,$)}})}(),function(){for(var l=pt,h=l.lib.BlockCipher,Se=l.algo,f=[],_=[],b=[],E=[],M=[],D=[],F=[],P=[],U=[],z=[],I=[],C=0;256>C;C++)I[C]=128>C?C<<1:C<<1^283;var B=0,R=0;for(C=0;256>C;C++){var V;f[B]=V=(V=R^R<<1^R<<2^R<<3^R<<4)>>>8^255&V^99,_[V]=B;var L=I[B],$=I[L],J=I[$],Q=257*I[V]^16843008*V;b[B]=Q<<24|Q>>>8,E[B]=Q<<16|Q>>>16,M[B]=Q<<8|Q>>>24,D[B]=Q,F[V]=(Q=16843009*J^65537*$^257*L^16843008*B)<<24|Q>>>8,P[V]=Q<<16|Q>>>16,U[V]=Q<<8|Q>>>24,z[V]=Q,B?(B=L^I[I[I[J^L]]],R^=I[I[R]]):B=R=1}var te=[0,1,2,4,8,16,32,64,128,27,54];Se=Se.AES=h.extend({_doReset:function(){for(var Ae=(q=this._key).words,j=q.sigBytes/4,q=4*((this._nRounds=j+6)+1),ee=this._keySchedule=[],re=0;re>>24]<<24|f[ue>>>16&255]<<16|f[ue>>>8&255]<<8|f[255&ue]):(ue=f[(ue=ue<<8|ue>>>24)>>>24]<<24|f[ue>>>16&255]<<16|f[ue>>>8&255]<<8|f[255&ue],ue^=te[re/j|0]<<24),ee[re]=ee[re-j]^ue}for(Ae=this._invKeySchedule=[],j=0;jj||4>=re?ue:F[f[ue>>>24]]^P[f[ue>>>16&255]]^U[f[ue>>>8&255]]^z[f[255&ue]]},encryptBlock:function(Ae,j){this._doCryptBlock(Ae,j,this._keySchedule,b,E,M,D,f)},decryptBlock:function(Ae,j){var q=Ae[j+1];Ae[j+1]=Ae[j+3],Ae[j+3]=q,this._doCryptBlock(Ae,j,this._invKeySchedule,F,P,U,z,_),q=Ae[j+1],Ae[j+1]=Ae[j+3],Ae[j+3]=q},_doCryptBlock:function(Ae,j,q,ee,re,ue,be,ce){for(var pe=this._nRounds,Y=Ae[j]^q[0],ui=Ae[j+1]^q[1],oi=Ae[j+2]^q[2],Rn=Ae[j+3]^q[3],ve=4,Ie=1;Ie>>24]^re[ui>>>16&255]^ue[oi>>>8&255]^be[255&Rn]^q[ve++],Nt=ee[ui>>>24]^re[oi>>>16&255]^ue[Rn>>>8&255]^be[255&Y]^q[ve++],Lt=ee[oi>>>24]^re[Rn>>>16&255]^ue[Y>>>8&255]^be[255&ui]^q[ve++];Rn=ee[Rn>>>24]^re[Y>>>16&255]^ue[ui>>>8&255]^be[255&oi]^q[ve++],Y=Bt,ui=Nt,oi=Lt}Bt=(ce[Y>>>24]<<24|ce[ui>>>16&255]<<16|ce[oi>>>8&255]<<8|ce[255&Rn])^q[ve++],Nt=(ce[ui>>>24]<<24|ce[oi>>>16&255]<<16|ce[Rn>>>8&255]<<8|ce[255&Y])^q[ve++],Lt=(ce[oi>>>24]<<24|ce[Rn>>>16&255]<<16|ce[Y>>>8&255]<<8|ce[255&ui])^q[ve++],Rn=(ce[Rn>>>24]<<24|ce[Y>>>16&255]<<16|ce[ui>>>8&255]<<8|ce[255&oi])^q[ve++],Ae[j]=Bt,Ae[j+1]=Nt,Ae[j+2]=Lt,Ae[j+3]=Rn},keySize:8}),l.AES=h._createHelper(Se)}(),function(){function l(I,C){var B=(this._lBlock>>>I^this._rBlock)&C;this._rBlock^=B,this._lBlock^=B<>>I^this._lBlock)&C;this._lBlock^=B,this._rBlock^=B<B;B++){var R=M[B]-1;C[B]=I[R>>>5]>>>31-R%32&1}for(I=this._subKeys=[],R=0;16>R;R++){var V=I[R]=[],L=F[R];for(B=0;24>B;B++)V[B/6|0]|=C[(D[B]-1+L)%28]<<31-B%6,V[4+(B/6|0)]|=C[28+(D[B+24]-1+L)%28]<<31-B%6;for(V[0]=V[0]<<1|V[0]>>>31,B=1;7>B;B++)V[B]>>>=4*(B-1)+3;V[7]=V[7]<<5|V[7]>>>27}for(C=this._invSubKeys=[],B=0;16>B;B++)C[B]=I[15-B]},encryptBlock:function(I,C){this._doCryptBlock(I,C,this._subKeys)},decryptBlock:function(I,C){this._doCryptBlock(I,C,this._invSubKeys)},_doCryptBlock:function(I,C,B){this._lBlock=I[C],this._rBlock=I[C+1],l.call(this,4,252645135),l.call(this,16,65535),h.call(this,2,858993459),h.call(this,8,16711935),l.call(this,1,1431655765);for(var R=0;16>R;R++){for(var V=B[R],L=this._lBlock,$=this._rBlock,J=0,Q=0;8>Q;Q++)J|=P[Q][(($^V[Q])&U[Q])>>>0];this._lBlock=$,this._rBlock=L^J}B=this._lBlock,this._lBlock=this._rBlock,this._rBlock=B,l.call(this,1,1431655765),h.call(this,8,16711935),h.call(this,2,858993459),l.call(this,16,65535),l.call(this,4,252645135),I[C]=this._lBlock,I[C+1]=this._rBlock},keySize:2,ivSize:2,blockSize:2});f.DES=b._createHelper(z),E=E.TripleDES=b.extend({_doReset:function(){var I=this._key.words;this._des1=z.createEncryptor(_.create(I.slice(0,2))),this._des2=z.createEncryptor(_.create(I.slice(2,4))),this._des3=z.createEncryptor(_.create(I.slice(4,6)))},encryptBlock:function(I,C){this._des1.encryptBlock(I,C),this._des2.decryptBlock(I,C),this._des3.encryptBlock(I,C)},decryptBlock:function(I,C){this._des3.decryptBlock(I,C),this._des2.encryptBlock(I,C),this._des1.decryptBlock(I,C)},keySize:6,ivSize:2,blockSize:2}),f.TripleDES=b._createHelper(E)}(),h=pt.lib.WordArray,pt.enc.Base64={stringify:function(f){var _=f.words,b=f.sigBytes,E=this._map;f.clamp(),f=[];for(var M=0;M>>2]>>>24-M%4*8&255)<<16|(_[M+1>>>2]>>>24-(M+1)%4*8&255)<<8|_[M+2>>>2]>>>24-(M+2)%4*8&255,F=0;4>F&&M+.75*F>>6*(3-F)&63));if(_=E.charAt(64))for(;f.length%4;)f.push(_);return f.join("")},parse:function(f){var _=f.length,b=this._map;(E=b.charAt(64))&&-1!=(E=f.indexOf(E))&&(_=E);for(var E=[],M=0,D=0;D<_;D++)if(D%4){var F=b.indexOf(f.charAt(D-1))<>>6-D%4*2;E[M>>>2]|=(F|P)<<24-M%4*8,M++}return h.create(E,M)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},function(l){function h(z,I,C,B,R,V,L){return((z=z+(I&C|~I&B)+R+L)<>>32-V)+I}function f(z,I,C,B,R,V,L){return((z=z+(I&B|C&~B)+R+L)<>>32-V)+I}function _(z,I,C,B,R,V,L){return((z=z+(I^C^B)+R+L)<>>32-V)+I}function b(z,I,C,B,R,V,L){return((z=z+(C^(I|~B))+R+L)<>>32-V)+I}for(var E=pt,M=(F=E.lib).WordArray,D=F.Hasher,F=E.algo,P=[],U=0;64>U;U++)P[U]=4294967296*l.abs(l.sin(U+1))|0;F=F.MD5=D.extend({_doReset:function(){this._hash=new M.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(z,I){for(var C=0;16>C;C++)z[B=I+C]=16711935&((R=z[B])<<8|R>>>24)|4278255360&(R<<24|R>>>8);var B,R=z[I+1],V=z[I+2],L=z[I+3],$=z[I+4],J=z[I+5],Q=z[I+6],te=z[I+7],Se=z[I+8],Ae=z[I+9],j=z[I+10],q=z[I+11],ee=z[I+12],re=z[I+13],ue=z[I+14],be=z[I+15],ce=h(ce=(C=this._hash.words)[0],Ie=C[1],ve=C[2],pe=C[3],B=z[I+0],7,P[0]),pe=h(pe,ce,Ie,ve,R,12,P[1]),ve=h(ve,pe,ce,Ie,V,17,P[2]),Ie=h(Ie,ve,pe,ce,L,22,P[3]);ce=h(ce,Ie,ve,pe,$,7,P[4]),pe=h(pe,ce,Ie,ve,J,12,P[5]),ve=h(ve,pe,ce,Ie,Q,17,P[6]),Ie=h(Ie,ve,pe,ce,te,22,P[7]),ce=h(ce,Ie,ve,pe,Se,7,P[8]),pe=h(pe,ce,Ie,ve,Ae,12,P[9]),ve=h(ve,pe,ce,Ie,j,17,P[10]),Ie=h(Ie,ve,pe,ce,q,22,P[11]),ce=h(ce,Ie,ve,pe,ee,7,P[12]),pe=h(pe,ce,Ie,ve,re,12,P[13]),ve=h(ve,pe,ce,Ie,ue,17,P[14]),ce=f(ce,Ie=h(Ie,ve,pe,ce,be,22,P[15]),ve,pe,R,5,P[16]),pe=f(pe,ce,Ie,ve,Q,9,P[17]),ve=f(ve,pe,ce,Ie,q,14,P[18]),Ie=f(Ie,ve,pe,ce,B,20,P[19]),ce=f(ce,Ie,ve,pe,J,5,P[20]),pe=f(pe,ce,Ie,ve,j,9,P[21]),ve=f(ve,pe,ce,Ie,be,14,P[22]),Ie=f(Ie,ve,pe,ce,$,20,P[23]),ce=f(ce,Ie,ve,pe,Ae,5,P[24]),pe=f(pe,ce,Ie,ve,ue,9,P[25]),ve=f(ve,pe,ce,Ie,L,14,P[26]),Ie=f(Ie,ve,pe,ce,Se,20,P[27]),ce=f(ce,Ie,ve,pe,re,5,P[28]),pe=f(pe,ce,Ie,ve,V,9,P[29]),ve=f(ve,pe,ce,Ie,te,14,P[30]),ce=_(ce,Ie=f(Ie,ve,pe,ce,ee,20,P[31]),ve,pe,J,4,P[32]),pe=_(pe,ce,Ie,ve,Se,11,P[33]),ve=_(ve,pe,ce,Ie,q,16,P[34]),Ie=_(Ie,ve,pe,ce,ue,23,P[35]),ce=_(ce,Ie,ve,pe,R,4,P[36]),pe=_(pe,ce,Ie,ve,$,11,P[37]),ve=_(ve,pe,ce,Ie,te,16,P[38]),Ie=_(Ie,ve,pe,ce,j,23,P[39]),ce=_(ce,Ie,ve,pe,re,4,P[40]),pe=_(pe,ce,Ie,ve,B,11,P[41]),ve=_(ve,pe,ce,Ie,L,16,P[42]),Ie=_(Ie,ve,pe,ce,Q,23,P[43]),ce=_(ce,Ie,ve,pe,Ae,4,P[44]),pe=_(pe,ce,Ie,ve,ee,11,P[45]),ve=_(ve,pe,ce,Ie,be,16,P[46]),ce=b(ce,Ie=_(Ie,ve,pe,ce,V,23,P[47]),ve,pe,B,6,P[48]),pe=b(pe,ce,Ie,ve,te,10,P[49]),ve=b(ve,pe,ce,Ie,ue,15,P[50]),Ie=b(Ie,ve,pe,ce,J,21,P[51]),ce=b(ce,Ie,ve,pe,ee,6,P[52]),pe=b(pe,ce,Ie,ve,L,10,P[53]),ve=b(ve,pe,ce,Ie,j,15,P[54]),Ie=b(Ie,ve,pe,ce,R,21,P[55]),ce=b(ce,Ie,ve,pe,Se,6,P[56]),pe=b(pe,ce,Ie,ve,be,10,P[57]),ve=b(ve,pe,ce,Ie,Q,15,P[58]),Ie=b(Ie,ve,pe,ce,re,21,P[59]),ce=b(ce,Ie,ve,pe,$,6,P[60]),pe=b(pe,ce,Ie,ve,q,10,P[61]),ve=b(ve,pe,ce,Ie,V,15,P[62]),Ie=b(Ie,ve,pe,ce,Ae,21,P[63]),C[0]=C[0]+ce|0,C[1]=C[1]+Ie|0,C[2]=C[2]+ve|0,C[3]=C[3]+pe|0},_doFinalize:function(){var z=this._data,I=z.words,C=8*this._nDataBytes,B=8*z.sigBytes;I[B>>>5]|=128<<24-B%32;var R=l.floor(C/4294967296);for(I[15+(B+64>>>9<<4)]=16711935&(R<<8|R>>>24)|4278255360&(R<<24|R>>>8),I[14+(B+64>>>9<<4)]=16711935&(C<<8|C>>>24)|4278255360&(C<<24|C>>>8),z.sigBytes=4*(I.length+1),this._process(),I=(z=this._hash).words,C=0;4>C;C++)I[C]=16711935&((B=I[C])<<8|B>>>24)|4278255360&(B<<24|B>>>8);return z},clone:function(){var z=D.clone.call(this);return z._hash=this._hash.clone(),z}}),E.MD5=D._createHelper(F),E.HmacMD5=D._createHmacHelper(F)}(Math),function(){var l=pt,h=(b=l.lib).WordArray,f=b.Hasher,_=[],b=l.algo.SHA1=f.extend({_doReset:function(){this._hash=new h.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(E,M){for(var D=this._hash.words,F=D[0],P=D[1],U=D[2],z=D[3],I=D[4],C=0;80>C;C++){if(16>C)_[C]=0|E[M+C];else{var B=_[C-3]^_[C-8]^_[C-14]^_[C-16];_[C]=B<<1|B>>>31}B=(F<<5|F>>>27)+I+_[C],B=20>C?B+(1518500249+(P&U|~P&z)):40>C?B+(1859775393+(P^U^z)):60>C?B+((P&U|P&z|U&z)-1894007588):B+((P^U^z)-899497514),I=z,z=U,U=P<<30|P>>>2,P=F,F=B}D[0]=D[0]+F|0,D[1]=D[1]+P|0,D[2]=D[2]+U|0,D[3]=D[3]+z|0,D[4]=D[4]+I|0},_doFinalize:function(){var E=this._data,M=E.words,D=8*this._nDataBytes,F=8*E.sigBytes;return M[F>>>5]|=128<<24-F%32,M[14+(F+64>>>9<<4)]=Math.floor(D/4294967296),M[15+(F+64>>>9<<4)]=D,E.sigBytes=4*M.length,this._process(),this._hash},clone:function(){var E=f.clone.call(this);return E._hash=this._hash.clone(),E}});l.SHA1=f._createHelper(b),l.HmacSHA1=f._createHmacHelper(b)}(),function(l){for(var h=pt,f=(C=h.lib).WordArray,_=C.Hasher,C=h.algo,b=[],E=[],M=function(R){return 4294967296*(R-(0|R))|0},D=2,F=0;64>F;){var P;e:{for(var U=l.sqrt(P=D),z=2;z<=U;z++)if(!(P%z)){P=!1;break e}P=!0}P&&(8>F&&(b[F]=M(l.pow(D,.5))),E[F]=M(l.pow(D,1/3)),F++),D++}var I=[];C=C.SHA256=_.extend({_doReset:function(){this._hash=new f.init(b.slice(0))},_doProcessBlock:function(B,R){for(var V=this._hash.words,L=V[0],$=V[1],J=V[2],Q=V[3],te=V[4],Se=V[5],Ae=V[6],j=V[7],q=0;64>q;q++){if(16>q)I[q]=0|B[R+q];else{var ee=I[q-15],re=I[q-2];I[q]=((ee<<25|ee>>>7)^(ee<<14|ee>>>18)^ee>>>3)+I[q-7]+((re<<15|re>>>17)^(re<<13|re>>>19)^re>>>10)+I[q-16]}ee=j+((te<<26|te>>>6)^(te<<21|te>>>11)^(te<<7|te>>>25))+(te&Se^~te&Ae)+E[q]+I[q],re=((L<<30|L>>>2)^(L<<19|L>>>13)^(L<<10|L>>>22))+(L&$^L&J^$&J),j=Ae,Ae=Se,Se=te,te=Q+ee|0,Q=J,J=$,$=L,L=ee+re|0}V[0]=V[0]+L|0,V[1]=V[1]+$|0,V[2]=V[2]+J|0,V[3]=V[3]+Q|0,V[4]=V[4]+te|0,V[5]=V[5]+Se|0,V[6]=V[6]+Ae|0,V[7]=V[7]+j|0},_doFinalize:function(){var B=this._data,R=B.words,V=8*this._nDataBytes,L=8*B.sigBytes;return R[L>>>5]|=128<<24-L%32,R[14+(L+64>>>9<<4)]=l.floor(V/4294967296),R[15+(L+64>>>9<<4)]=V,B.sigBytes=4*R.length,this._process(),this._hash},clone:function(){var B=_.clone.call(this);return B._hash=this._hash.clone(),B}}),h.SHA256=_._createHelper(C),h.HmacSHA256=_._createHmacHelper(C)}(Math),function(){var l=pt,h=l.lib.WordArray,f=(_=l.algo).SHA256,_=_.SHA224=f.extend({_doReset:function(){this._hash=new h.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var b=f._doFinalize.call(this);return b.sigBytes-=4,b}});l.SHA224=f._createHelper(_),l.HmacSHA224=f._createHmacHelper(_)}(),function(){function l(){return _.create.apply(_,arguments)}for(var h=pt,f=h.lib.Hasher,_=(E=h.x64).Word,b=E.WordArray,E=h.algo,M=[l(1116352408,3609767458),l(1899447441,602891725),l(3049323471,3964484399),l(3921009573,2173295548),l(961987163,4081628472),l(1508970993,3053834265),l(2453635748,2937671579),l(2870763221,3664609560),l(3624381080,2734883394),l(310598401,1164996542),l(607225278,1323610764),l(1426881987,3590304994),l(1925078388,4068182383),l(2162078206,991336113),l(2614888103,633803317),l(3248222580,3479774868),l(3835390401,2666613458),l(4022224774,944711139),l(264347078,2341262773),l(604807628,2007800933),l(770255983,1495990901),l(1249150122,1856431235),l(1555081692,3175218132),l(1996064986,2198950837),l(2554220882,3999719339),l(2821834349,766784016),l(2952996808,2566594879),l(3210313671,3203337956),l(3336571891,1034457026),l(3584528711,2466948901),l(113926993,3758326383),l(338241895,168717936),l(666307205,1188179964),l(773529912,1546045734),l(1294757372,1522805485),l(1396182291,2643833823),l(1695183700,2343527390),l(1986661051,1014477480),l(2177026350,1206759142),l(2456956037,344077627),l(2730485921,1290863460),l(2820302411,3158454273),l(3259730800,3505952657),l(3345764771,106217008),l(3516065817,3606008344),l(3600352804,1432725776),l(4094571909,1467031594),l(275423344,851169720),l(430227734,3100823752),l(506948616,1363258195),l(659060556,3750685593),l(883997877,3785050280),l(958139571,3318307427),l(1322822218,3812723403),l(1537002063,2003034995),l(1747873779,3602036899),l(1955562222,1575990012),l(2024104815,1125592928),l(2227730452,2716904306),l(2361852424,442776044),l(2428436474,593698344),l(2756734187,3733110249),l(3204031479,2999351573),l(3329325298,3815920427),l(3391569614,3928383900),l(3515267271,566280711),l(3940187606,3454069534),l(4118630271,4000239992),l(116418474,1914138554),l(174292421,2731055270),l(289380356,3203993006),l(460393269,320620315),l(685471733,587496836),l(852142971,1086792851),l(1017036298,365543100),l(1126000580,2618297676),l(1288033470,3409855158),l(1501505948,4234509866),l(1607167915,987167468),l(1816402316,1246189591)],D=[],F=0;80>F;F++)D[F]=l();E=E.SHA512=f.extend({_doReset:function(){this._hash=new b.init([new _.init(1779033703,4089235720),new _.init(3144134277,2227873595),new _.init(1013904242,4271175723),new _.init(2773480762,1595750129),new _.init(1359893119,2917565137),new _.init(2600822924,725511199),new _.init(528734635,4215389547),new _.init(1541459225,327033209)])},_doProcessBlock:function(P,U){for(var $,z=($=this._hash.words)[0],I=$[1],C=$[2],B=$[3],R=$[4],V=$[5],L=$[6],J=z.high,Q=z.low,te=I.high,Se=I.low,Ae=C.high,j=C.low,q=B.high,ee=B.low,re=R.high,ue=R.low,be=V.high,ce=V.low,pe=L.high,ve=L.low,Ie=($=$[7]).high,Bt=$.low,Nt=J,Lt=Q,Rn=te,Y=Se,ui=Ae,oi=j,Fi=q,ln=ee,es=re,vs=ue,Ls=be,Kn=ce,Mr=pe,Qi=ve,ii=Ie,gr=Bt,an=0;80>an;an++){var bc=D[an];if(16>an)var $i=bc.high=0|P[U+2*an],vi=bc.low=0|P[U+2*an+1];else{$i=((vi=($i=D[an-15]).high)>>>1|(_a=$i.low)<<31)^(vi>>>8|_a<<24)^vi>>>7;var _a=(_a>>>1|vi<<31)^(_a>>>8|vi<<24)^(_a>>>7|vi<<25),qc=((vi=(qc=D[an-2]).high)>>>19|(Bi=qc.low)<<13)^(vi<<3|Bi>>>29)^vi>>>6,Bi=(Bi>>>19|vi<<13)^(Bi<<3|vi>>>29)^(Bi>>>6|vi<<26);bc.high=$i=($i=($i=$i+(xd=(vi=D[an-7]).high)+((vi=_a+vi.low)>>>0<_a>>>0?1:0))+qc+((vi+=Bi)>>>0>>0?1:0))+(Po=(Xo=D[an-16]).high)+((vi+=Xo=Xo.low)>>>0>>0?1:0),bc.low=vi}var xd=es&Ls^~es&Mr,Xo=vs&Kn^~vs&Qi,W0=(bc=Nt&Rn^Nt&ui^Rn&ui,Lt&Y^Lt&oi^Y&oi),Ro=(Bi=M[an]).high,wd=Bi.low,Po=ii+((es>>>14|vs<<18)^(es>>>18|vs<<14)^(es<<23|vs>>>9))+((Bi=gr+((vs>>>14|es<<18)^(vs>>>18|es<<14)^(vs<<23|es>>>9)))>>>0>>0?1:0);ii=Mr,gr=Qi,Mr=Ls,Qi=Kn,Ls=es,Kn=vs,es=Fi+(Po=(Po=(Po=Po+xd+((Bi+=Xo)>>>0>>0?1:0))+Ro+((Bi+=wd)>>>0>>0?1:0))+$i+((Bi+=vi)>>>0>>0?1:0))+((vs=ln+Bi|0)>>>0>>0?1:0)|0,Fi=ui,ln=oi,ui=Rn,oi=Y,Rn=Nt,Y=Lt,Nt=Po+(bc=(_a=(Nt>>>28|Lt<<4)^(Nt<<30|Lt>>>2)^(Nt<<25|Lt>>>7))+bc+((vi=(qc=(Lt>>>28|Nt<<4)^(Lt<<30|Nt>>>2)^(Lt<<25|Nt>>>7))+W0)>>>0>>0?1:0))+((Lt=Bi+vi|0)>>>0>>0?1:0)|0}Q=z.low=Q+Lt,z.high=J+Nt+(Q>>>0>>0?1:0),Se=I.low=Se+Y,I.high=te+Rn+(Se>>>0>>0?1:0),j=C.low=j+oi,C.high=Ae+ui+(j>>>0>>0?1:0),ee=B.low=ee+ln,B.high=q+Fi+(ee>>>0>>0?1:0),ue=R.low=ue+vs,R.high=re+es+(ue>>>0>>0?1:0),ce=V.low=ce+Kn,V.high=be+Ls+(ce>>>0>>0?1:0),ve=L.low=ve+Qi,L.high=pe+Mr+(ve>>>0>>0?1:0),Bt=$.low=Bt+gr,$.high=Ie+ii+(Bt>>>0>>0?1:0)},_doFinalize:function(){var P=this._data,U=P.words,z=8*this._nDataBytes,I=8*P.sigBytes;return U[I>>>5]|=128<<24-I%32,U[30+(I+128>>>10<<5)]=Math.floor(z/4294967296),U[31+(I+128>>>10<<5)]=z,P.sigBytes=4*U.length,this._process(),this._hash.toX32()},clone:function(){var P=f.clone.call(this);return P._hash=this._hash.clone(),P},blockSize:32}),h.SHA512=f._createHelper(E),h.HmacSHA512=f._createHmacHelper(E)}(),function(){var l=pt,h=(b=l.x64).Word,f=b.WordArray,_=(b=l.algo).SHA512,b=b.SHA384=_.extend({_doReset:function(){this._hash=new f.init([new h.init(3418070365,3238371032),new h.init(1654270250,914150663),new h.init(2438529370,812702999),new h.init(355462360,4144912697),new h.init(1731405415,4290775857),new h.init(2394180231,1750603025),new h.init(3675008525,1694076839),new h.init(1203062813,3204075428)])},_doFinalize:function(){var E=_._doFinalize.call(this);return E.sigBytes-=16,E}});l.SHA384=_._createHelper(b),l.HmacSHA384=_._createHmacHelper(b)}(),function(){var l=pt,h=(P=l.lib).WordArray,f=P.Hasher,P=l.algo,_=h.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),b=h.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),E=h.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),M=h.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),D=h.create([0,1518500249,1859775393,2400959708,2840853838]),F=h.create([1352829926,1548603684,1836072691,2053994217,0]);P=P.RIPEMD160=f.extend({_doReset:function(){this._hash=h.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(U,z){for(var I=0;16>I;I++)U[C=z+I]=16711935&((B=U[C])<<8|B>>>24)|4278255360&(B<<24|B>>>8);var C,Q,te,Se,Ae,j,q,ee,re,ue,be,ce,B=D.words,R=F.words,V=_.words,L=b.words,$=E.words,J=M.words;for(q=Q=(C=this._hash.words)[0],ee=te=C[1],re=Se=C[2],ue=Ae=C[3],be=j=C[4],I=0;80>I;I+=1)ce=Q+U[z+V[I]]|0,ce=16>I?ce+((te^Se^Ae)+B[0]):32>I?ce+((te&Se|~te&Ae)+B[1]):48>I?ce+(((te|~Se)^Ae)+B[2]):64>I?ce+((te&Ae|Se&~Ae)+B[3]):ce+((te^(Se|~Ae))+B[4]),ce=(ce=(ce|=0)<<$[I]|ce>>>32-$[I])+j|0,Q=j,j=Ae,Ae=Se<<10|Se>>>22,Se=te,te=ce,ce=q+U[z+L[I]]|0,ce=16>I?ce+((ee^(re|~ue))+R[0]):32>I?ce+((ee&ue|re&~ue)+R[1]):48>I?ce+(((ee|~re)^ue)+R[2]):64>I?ce+((ee&re|~ee&ue)+R[3]):ce+((ee^re^ue)+R[4]),ce=(ce=(ce|=0)<>>32-J[I])+be|0,q=be,be=ue,ue=re<<10|re>>>22,re=ee,ee=ce;ce=C[1]+Se+ue|0,C[1]=C[2]+Ae+be|0,C[2]=C[3]+j+q|0,C[3]=C[4]+Q+ee|0,C[4]=C[0]+te+re|0,C[0]=ce},_doFinalize:function(){var U=this._data,z=U.words,I=8*this._nDataBytes,C=8*U.sigBytes;for(z[C>>>5]|=128<<24-C%32,z[14+(C+64>>>9<<4)]=16711935&(I<<8|I>>>24)|4278255360&(I<<24|I>>>8),U.sigBytes=4*(z.length+1),this._process(),z=(U=this._hash).words,I=0;5>I;I++)z[I]=16711935&((C=z[I])<<8|C>>>24)|4278255360&(C<<24|C>>>8);return U},clone:function(){var U=f.clone.call(this);return U._hash=this._hash.clone(),U}}),l.RIPEMD160=f._createHelper(P),l.HmacRIPEMD160=f._createHmacHelper(P)}(Math),function(){var h=pt.enc.Utf8;pt.algo.HMAC=pt.lib.Base.extend({init:function(f,_){f=this._hasher=new f.init,"string"==typeof _&&(_=h.parse(_));var b=f.blockSize,E=4*b;_.sigBytes>E&&(_=f.finalize(_)),_.clamp();for(var M=this._oKey=_.clone(),D=this._iKey=_.clone(),F=M.words,P=D.words,U=0;U>6)+ps.charAt(63&f);if(h+1==l.length?(f=parseInt(l.substring(h,h+1),16),_+=ps.charAt(f<<2)):h+2==l.length&&(f=parseInt(l.substring(h,h+2),16),_+=ps.charAt(f>>2)+ps.charAt((3&f)<<4)),Ia)for(;(3&_.length)>0;)_+=Ia;return _}function ao(l){var f,b,E,h="",_=0;for(f=0;f>2),b=3&E,_=1):1==_?(h+=un(b<<2|E>>4),b=15&E,_=2):2==_?(h+=un(b),h+=un(E>>2),b=3&E,_=3):(h+=un(b<<2|E>>4),h+=un(15&E),_=0));return 1==_&&(h+=un(b<<2)),h}function _e(l,h,f){null!=l&&("number"==typeof l?this.fromNumber(l,h,f):this.fromString(l,null==h&&"string"!=typeof l?256:h))}function An(){return new _e(null)}"Microsoft Internet Explorer"==qr.appName?(_e.prototype.am=function ks(l,h,f,_,b,E){for(var M=32767&h,D=h>>15;--E>=0;){var F=32767&this[l],P=this[l++]>>15,U=D*F+P*M;b=((F=M*F+((32767&U)<<15)+f[_]+(1073741823&b))>>>30)+(U>>>15)+D*P+(b>>>30),f[_++]=1073741823&F}return b},Kr=30):"Netscape"!=qr.appName?(_e.prototype.am=function di(l,h,f,_,b,E){for(;--E>=0;){var M=h*this[l++]+f[_]+b;b=Math.floor(M/67108864),f[_++]=67108863&M}return b},Kr=26):(_e.prototype.am=function Fa(l,h,f,_,b,E){for(var M=16383&h,D=h>>14;--E>=0;){var F=16383&this[l],P=this[l++]>>14,U=D*F+P*M;b=((F=M*F+((16383&U)<<14)+f[_]+b)>>28)+(U>>14)+D*P,f[_++]=268435455&F}return b},Kr=28),_e.prototype.DB=Kr,_e.prototype.DM=(1<>>16)&&(l=f,h+=16),0!=(f=l>>8)&&(l=f,h+=8),0!=(f=l>>4)&&(l=f,h+=4),0!=(f=l>>2)&&(l=f,h+=2),0!=(f=l>>1)&&(l=f,h+=1),h}function _t(l){this.m=l}function Gc(l){this.m=l,this.mp=l.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<>=16,h+=16),255&l||(l>>=8,h+=8),15&l||(l>>=4,h+=4),3&l||(l>>=2,h+=2),1&l||++h,h}function wn(l){for(var h=0;0!=l;)l&=l-1,++h;return h}function fc(){}function O0(l){return l}function Je(l){this.r2=An(),this.q3=An(),_e.ONE.dlShiftTo(2*l.t,this.r2),this.mu=this.r2.divide(l),this.m=l}_t.prototype.convert=function uu(l){return l.s<0||l.compareTo(this.m)>=0?l.mod(this.m):l},_t.prototype.revert=function zc(l){return l},_t.prototype.reduce=function hu(l){l.divRemTo(this.m,null,l)},_t.prototype.mulTo=function Ep(l,h,f){l.multiplyTo(h,f),this.reduce(f)},_t.prototype.sqrTo=function lo(l,h){l.squareTo(h),this.reduce(h)},Gc.prototype.convert=function Oa(l){var h=An();return l.abs().dlShiftTo(this.m.t,h),h.divRemTo(this.m,null,h),l.s<0&&h.compareTo(_e.ZERO)>0&&this.m.subTo(h,h),h},Gc.prototype.revert=function Mp(l){var h=An();return l.copyTo(h),this.reduce(h),h},Gc.prototype.reduce=function dr(l){for(;l.t<=this.mt2;)l[l.t++]=0;for(var h=0;h>15)*this.mpl&this.um)<<15)&l.DM;for(l[f=h+this.m.t]+=this.m.am(0,_,l,h,0,this.m.t);l[f]>=l.DV;)l[f]-=l.DV,l[++f]++}l.clamp(),l.drShiftTo(this.m.t,l),l.compareTo(this.m)>=0&&l.subTo(this.m,l)},Gc.prototype.mulTo=function qo(l,h,f){l.multiplyTo(h,f),this.reduce(f)},Gc.prototype.sqrTo=function ur(l,h){l.squareTo(h),this.reduce(h)},_e.prototype.copyTo=function lu(l){for(var h=this.t-1;h>=0;--h)l[h]=this[h];l.t=this.t,l.s=this.s},_e.prototype.fromInt=function Pa(l){this.t=1,this.s=l<0?-1:0,l>0?this[0]=l:l<-1?this[0]=l+this.DV:this.t=0},_e.prototype.fromString=function du(l,h){var f;if(16==h)f=4;else if(8==h)f=3;else if(256==h)f=8;else if(2==h)f=1;else if(32==h)f=5;else{if(4!=h)return void this.fromRadix(l,h);f=2}this.t=0,this.s=0;for(var _=l.length,b=!1,E=0;--_>=0;){var M=8==f?255&l[_]:Ra(l,_);M<0?"-"==l.charAt(_)&&(b=!0):(b=!1,0==E?this[this.t++]=M:E+f>this.DB?(this[this.t-1]|=(M&(1<>this.DB-E):this[this.t-1]|=M<=this.DB&&(E-=this.DB))}8==f&&128&l[0]&&(this.s=-1,E>0&&(this[this.t-1]|=(1<0&&this[this.t-1]==l;)--this.t},_e.prototype.dlShiftTo=function fn(l,h){var f;for(f=this.t-1;f>=0;--f)h[f+l]=this[f];for(f=l-1;f>=0;--f)h[f]=0;h.t=this.t+l,h.s=this.s},_e.prototype.drShiftTo=function Fn(l,h){for(var f=l;f=0;--D)h[D+E+1]=this[D]>>_|M,M=(this[D]&b)<=0;--D)h[D]=0;h[E]=M,h.t=this.t+E+1,h.s=this.s,h.clamp()},_e.prototype.rShiftTo=function Wi(l,h){h.s=this.s;var f=Math.floor(l/this.DB);if(f>=this.t)h.t=0;else{var _=l%this.DB,b=this.DB-_,E=(1<<_)-1;h[0]=this[f]>>_;for(var M=f+1;M>_;_>0&&(h[this.t-f-1]|=(this.s&E)<>=this.DB;if(l.t>=this.DB;_+=this.s}else{for(_+=this.s;f>=this.DB;_-=l.s}h.s=_<0?-1:0,_<-1?h[f++]=this.DV+_:_>0&&(h[f++]=_),h.t=f,h.clamp()},_e.prototype.multiplyTo=function co(l,h){var f=this.abs(),_=l.abs(),b=f.t;for(h.t=b+_.t;--b>=0;)h[b]=0;for(b=0;b<_.t;++b)h[b+f.t]=f.am(0,_[b],h,b,0,f.t);h.s=0,h.clamp(),this.s!=l.s&&_e.ZERO.subTo(h,h)},_e.prototype.squareTo=function dc(l){for(var h=this.abs(),f=l.t=2*h.t;--f>=0;)l[f]=0;for(f=0;f=h.DV&&(l[f+h.t]-=h.DV,l[f+h.t+1]=1)}l.t>0&&(l[l.t-1]+=h.am(f,h[f],l,2*f,0,1)),l.s=0,l.clamp()},_e.prototype.divRemTo=function $o(l,h,f){var _=l.abs();if(!(_.t<=0)){var b=this.abs();if(b.t<_.t)return h?.fromInt(0),void(null!=f&&this.copyTo(f));null==f&&(f=An());var E=An(),M=this.s,D=l.s,F=this.DB-Qn(_[_.t-1]);F>0?(_.lShiftTo(F,E),b.lShiftTo(F,f)):(_.copyTo(E),b.copyTo(f));var P=E.t,U=E[P-1];if(0!=U){var z=U*(1<1?E[P-2]>>this.F2:0),I=this.FV/z,C=(1<=0&&(f[f.t++]=1,f.subTo(L,f)),_e.ONE.dlShiftTo(P,L),L.subTo(E,E);E.t=0;){var $=f[--R]==U?this.DM:Math.floor(f[R]*I+(f[R-1]+B)*C);if((f[R]+=E.am(0,$,f,V,0,P))<$)for(E.dlShiftTo(V,L),f.subTo(L,f);f[R]<--$;)f.subTo(L,f)}null!=h&&(f.drShiftTo(P,h),M!=D&&_e.ZERO.subTo(h,h)),f.t=P,f.clamp(),F>0&&f.rShiftTo(F,f),M<0&&_e.ZERO.subTo(f,f)}}},_e.prototype.invDigit=function ad(){if(this.t<1)return 0;var l=this[0];if(!(1&l))return 0;var h=3&l;return(h=(h=(h=(h=h*(2-(15&l)*h)&15)*(2-(255&l)*h)&255)*(2-((65535&l)*h&65535))&65535)*(2-l*h%this.DV)%this.DV)>0?this.DV-h:-h},_e.prototype.isEven=function cd(){return 0==(this.t>0?1&this[0]:this.s)},_e.prototype.exp=function Ih(l,h){if(l>4294967295||l<1)return _e.ONE;var f=An(),_=An(),b=h.convert(this),E=Qn(l)-1;for(b.copyTo(f);--E>=0;)if(h.sqrTo(f,_),(l&1<0)h.mulTo(_,b,f);else{var M=f;f=_,_=M}return h.revert(f)},_e.prototype.toString=function od(l){if(this.s<0)return"-"+this.negate().toString(l);var h;if(16==l)h=4;else if(8==l)h=3;else if(2==l)h=1;else if(32==l)h=5;else{if(4!=l)return this.toRadix(l);h=2}var _,f=(1<0)for(D>D)>0&&(b=!0,E=un(_));M>=0;)D>(D+=this.DB-h)):(_=this[M]>>(D-=h)&f,D<=0&&(D+=this.DB,--M)),_>0&&(b=!0),b&&(E+=un(_));return b?E:"0"},_e.prototype.negate=function cc(){var l=An();return _e.ZERO.subTo(this,l),l},_e.prototype.abs=function Pt(){return this.s<0?this.negate():this},_e.prototype.compareTo=function $t(l){var h=this.s-l.s;if(0!=h)return h;var f=this.t;if(0!=(h=f-l.t))return this.s<0?-h:h;for(;--f>=0;)if(0!=(h=this[f]-l[f]))return h;return 0},_e.prototype.bitLength=function In(){return this.t<=0?0:this.DB*(this.t-1)+Qn(this[this.t-1]^this.s&this.DM)},_e.prototype.mod=function Fs(l){var h=An();return this.abs().divRemTo(l,null,h),this.s<0&&h.compareTo(_e.ZERO)>0&&l.subTo(h,h),h},_e.prototype.modPowInt=function Ml(l,h){var f;return f=l<256||h.isEven()?new _t(h):new Gc(h),this.exp(l,f)},_e.ZERO=Ws(0),_e.ONE=Ws(1),fc.prototype.convert=O0,fc.prototype.revert=O0,fc.prototype.mulTo=function Rs(l,h,f){l.multiplyTo(h,f)},fc.prototype.sqrTo=function Ci(l,h){l.squareTo(h)},Je.prototype.convert=function N0(l){if(l.s<0||l.t>2*this.m.t)return l.mod(this.m);if(l.compareTo(this.m)<0)return l;var h=An();return l.copyTo(h),this.reduce(h),h},Je.prototype.revert=function On(l){return l},Je.prototype.reduce=function _u(l){for(l.drShiftTo(this.m.t-1,this.r2),l.t>this.m.t+1&&(l.t=this.m.t+1,l.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);l.compareTo(this.r2)<0;)l.dAddOffset(1,this.m.t+1);for(l.subTo(this.r2,l);l.compareTo(this.m)>=0;)l.subTo(this.m,l)},Je.prototype.mulTo=function kp(l,h,f){l.multiplyTo(h,f),this.reduce(f)},Je.prototype.sqrTo=function B0(l,h){l.squareTo(h),this.reduce(h)};var Xr=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],zh=(1<<26)/Xr[Xr.length-1];function dd(){this.i=0,this.j=0,this.S=new Array}_e.prototype.chunkSize=function Fh(l){return Math.floor(Math.LN2*this.DB/Math.log(l))},_e.prototype.toRadix=function Rh(l){if(null==l&&(l=10),0==this.signum()||l<2||l>36)return"0";var h=this.chunkSize(l),f=Math.pow(l,h),_=Ws(f),b=An(),E=An(),M="";for(this.divRemTo(_,b,E);b.signum()>0;)M=(f+E.intValue()).toString(l).substr(1)+M,b.divRemTo(_,b,E);return E.intValue().toString(l)+M},_e.prototype.fromRadix=function Ph(l,h){this.fromInt(0),null==h&&(h=10);for(var f=this.chunkSize(h),_=Math.pow(h,f),b=!1,E=0,M=0,D=0;D=f&&(this.dMultiply(_),this.dAddOffset(M,0),E=0,M=0))}E>0&&(this.dMultiply(Math.pow(h,E)),this.dAddOffset(M,0)),b&&_e.ZERO.subTo(this,this)},_e.prototype.fromNumber=function Cp(l,h,f){if("number"==typeof h)if(l<2)this.fromInt(1);else for(this.fromNumber(l,f),this.testBit(l-1)||this.bitwiseTo(_e.ONE.shiftLeft(l-1),ki,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(h);)this.dAddOffset(2,0),this.bitLength()>l&&this.subTo(_e.ONE.shiftLeft(l-1),this);else{var _=new Array,b=7&l;_.length=1+(l>>3),h.nextBytes(_),b>0?_[0]&=(1<>=this.DB;if(l.t>=this.DB;_+=this.s}else{for(_+=this.s;f>=this.DB;_+=l.s}h.s=_<0?-1:0,_>0?h[f++]=_:_<-1&&(h[f++]=this.DV+_),h.t=f,h.clamp()},_e.prototype.dMultiply=function P0(l){this[this.t]=this.am(0,l-1,this,0,0,this.t),++this.t,this.clamp()},_e.prototype.dAddOffset=function bb(l,h){if(0!=l){for(;this.t<=h;)this[this.t++]=0;for(this[h]+=l;this[h]>=this.DV;)this[h]-=this.DV,++h>=this.t&&(this[this.t++]=0),++this[h]}},_e.prototype.multiplyLowerTo=function wb(l,h,f){var b,_=Math.min(this.t+l.t,h);for(f.s=0,f.t=_;_>0;)f[--_]=0;for(b=f.t-this.t;_=0;)f[_]=0;for(_=Math.max(h-this.t,0);_0)if(0==h)f=this[0]%l;else for(var _=this.t-1;_>=0;--_)f=(h*f+this[_])%l;return f},_e.prototype.millerRabin=function tn(l){var h=this.subtract(_e.ONE),f=h.getLowestSetBit();if(f<=0)return!1;var _=h.shiftRight(f);(l=l+1>>1)>Xr.length&&(l=Xr.length);for(var b=An(),E=0;E>24},_e.prototype.shortValue=function Cl(){return 0==this.t?this.s:this[0]<<16>>16},_e.prototype.signum=function ld(){return this.s<0?-1:this.t<=0||1==this.t&&this[0]<=0?0:1},_e.prototype.toByteArray=function Oh(){var l=this.t,h=new Array;h[0]=this.s;var _,f=this.DB-l*this.DB%8,b=0;if(l-- >0)for(f>f)!=(this.s&this.DM)>>f&&(h[b++]=_|this.s<=0;)f<8?(_=(this[l]&(1<>(f+=this.DB-8)):(_=this[l]>>(f-=8)&255,f<=0&&(f+=this.DB,--l)),128&_&&(_|=-256),0==b&&(128&this.s)!=(128&_)&&++b,(b>0||_!=this.s)&&(h[b++]=_);return h},_e.prototype.equals=function Lh(l){return 0==this.compareTo(l)},_e.prototype.min=function Nh(l){return this.compareTo(l)<0?this:l},_e.prototype.max=function Bh(l){return this.compareTo(l)>0?this:l},_e.prototype.and=function Vh(l){var h=An();return this.bitwiseTo(l,Vi,h),h},_e.prototype.or=function fu(l){var h=An();return this.bitwiseTo(l,ki,h),h},_e.prototype.xor=function Mi(l){var h=An();return this.bitwiseTo(l,Tp,h),h},_e.prototype.andNot=function Hh(l){var h=An();return this.bitwiseTo(l,en,h),h},_e.prototype.not=function pu(){for(var l=An(),h=0;h=this.t?0!=this.s:0!=(this[h]&1<1){var U=An();for(E.sqrTo(M[1],U);D<=P;)M[D]=An(),E.mulTo(U,M[D-2],M[D]),D+=2}var I,R,z=l.t-1,C=!0,B=An();for(f=Qn(l[z])-1;z>=0;){for(f>=F?I=l[z]>>f-F&P:(I=(l[z]&(1<0&&(I|=l[z-1]>>this.DB+f-F)),D=_;!(1&I);)I>>=1,--D;if((f-=D)<0&&(f+=this.DB,--z),C)M[I].copyTo(b),C=!1;else{for(;D>1;)E.sqrTo(b,B),E.sqrTo(B,b),D-=2;D>0?E.sqrTo(b,B):(R=b,b=B,B=R),E.mulTo(B,M[I],b)}for(;z>=0&&!(l[z]&1<=0?(f.subTo(_,f),h&&b.subTo(M,b),E.subTo(D,E)):(_.subTo(f,_),h&&M.subTo(b,M),D.subTo(E,D))}return 0!=_.compareTo(_e.ONE)?_e.ZERO:D.compareTo(l)>=0?D.subtract(l):D.signum()<0?(D.addTo(l,D),D.signum()<0?D.add(l):D):D},_e.prototype.pow=function xb(l){return this.exp(l,new fc)},_e.prototype.gcd=function Fp(l){var h=this.s<0?this.negate():this.clone(),f=l.s<0?l.negate():l.clone();if(h.compareTo(f)<0){var _=h;h=f,f=_}var b=h.getLowestSetBit(),E=f.getLowestSetBit();if(E<0)return h;for(b0&&(h.rShiftTo(E,h),f.rShiftTo(E,f));h.signum()>0;)(b=h.getLowestSetBit())>0&&h.rShiftTo(b,h),(b=f.getLowestSetBit())>0&&f.rShiftTo(b,f),h.compareTo(f)>=0?(h.subTo(f,h),h.rShiftTo(1,h)):(f.subTo(h,f),f.rShiftTo(1,f));return E>0&&f.lShiftTo(E,f),f},_e.prototype.isProbablePrime=function vu(l){var h,f=this.abs();if(1==f.t&&f[0]<=Xr[Xr.length-1]){for(h=0;h>8&255,$s[kr++]^=l>>16&255,$s[kr++]^=l>>24&255,kr>=Pp&&(kr-=Pp)}((new Date).getTime())}if(null==$s){var qs;if($s=new Array,kr=0,void 0!==le&&(void 0!==le.crypto||void 0!==le.msCrypto)){var hd=le.crypto||le.msCrypto;if(hd.getRandomValues){var Gh=new Uint8Array(32);for(hd.getRandomValues(Gh),qs=0;qs<32;++qs)$s[kr++]=Gh[qs]}else if("Netscape"==qr.appName&&qr.appVersion<"5"){var jh=le.crypto.random(32);for(qs=0;qs>>8,$s[kr++]=255&qs;kr=0,pc()}function Op(){if(null==Ii){for(pc(),(Ii=function yu(){return new dd}()).init($s),kr=0;kr<$s.length;++kr)$s[kr]=0;kr=0}return Ii.next()}function Ao(){}function hr(l,h){return new _e(l,h)}function hn(l,h,f){for(var _="",b=0;_.length>24,(16711680&b)>>16,(65280&b)>>8,255&b]))),b+=1;return _}function Ut(){this.n=null,this.e=0,this.d=null,this.p=null,this.q=null,this.dmp1=null,this.dmq1=null,this.coeff=null}function ko(l,h,f){for(var _="",b=0;_.length>24,(16711680&b)>>16,(65280&b)>>8,255&b])),b+=1;return _}function fr(l,h){this.x=h,this.q=l}function Mt(l,h,f,_){this.curve=l,this.x=h,this.y=f,this.z=null==_?_e.ONE:_,this.zinv=null}function Nr(l,h,f){this.q=l,this.a=this.fromBigInteger(h),this.b=this.fromBigInteger(f),this.infinity=new Mt(this,null,null)}Ao.prototype.nextBytes=function Wh(l){var h;for(h=0;h0&&h.length>0))throw"Invalid RSA public key";this.n=hr(l,16),this.e=parseInt(h,16)}},Ut.prototype.encrypt=function H0(l){var h=function Lp(l,h){if(h=0&&h>0;){var b=l.charCodeAt(_--);b<128?f[--h]=b:b>127&&b<2048?(f[--h]=63&b|128,f[--h]=b>>6|192):(f[--h]=63&b|128,f[--h]=b>>6&63|128,f[--h]=b>>12|224)}f[--h]=0;for(var E=new Ao,M=new Array;h>2;){for(M[0]=0;0==M[0];)E.nextBytes(M);f[--h]=M[0]}return f[--h]=2,f[--h]=0,new _e(f)}(l,this.n.bitLength()+7>>3);if(null==h)return null;var f=this.doPublic(h);if(null==f)return null;var _=f.toString(16);return 1&_.length?"0"+_:_},Ut.prototype.encryptOAEP=function U0(l,h,f){var _=function bu(l,h,f,_){var b=w.crypto.MessageDigest,E=w.crypto.Util,M=null;if(f||(f="sha1"),"string"==typeof f&&(M=b.getCanonicalAlgName(f),_=b.getHashLength(M),f=function(R){return Vr(E.hashHex(_s(R),M))}),l.length+2*_+2>h)throw"Message too long for RSA";var F,D="";for(F=0;F>3,h,f);if(null==_)return null;var b=this.doPublic(_);if(null==b)return null;var E=b.toString(16);return 1&E.length?"0"+E:E},Ut.prototype.type="RSA",Ut.prototype.doPrivate=function Si(l){if(null==this.p||null==this.q)return l.modPow(this.d,this.n);for(var h=l.mod(this.p).modPow(this.dmp1,this.p),f=l.mod(this.q).modPow(this.dmq1,this.q);h.compareTo(f)<0;)h=h.add(this.p);return h.subtract(f).multiply(this.coeff).mod(this.p).multiply(this.q).add(f)},Ut.prototype.setPrivate=function Ki(l,h,f){if(this.isPrivate=!0,"string"!=typeof l)this.n=l,this.e=h,this.d=f;else{if(!(null!=l&&null!=h&&l.length>0&&h.length>0))throw"Invalid RSA private key";this.n=hr(l,16),this.e=parseInt(h,16),this.d=hr(f,16)}},Ut.prototype.setPrivateEx=function Ko(l,h,f,_,b,E,M,D){if(this.isPrivate=!0,this.isPublic=!1,null==l)throw"RSASetPrivateEx N == null";if(null==h)throw"RSASetPrivateEx E == null";if(0==l.length)throw"RSASetPrivateEx N.length == 0";if(0==h.length)throw"RSASetPrivateEx E.length == 0";if(!(null!=l&&null!=h&&l.length>0&&h.length>0))throw"Invalid RSA private key in RSASetPrivateEx";this.n=hr(l,16),this.e=parseInt(h,16),this.d=hr(f,16),this.p=hr(_,16),this.q=hr(b,16),this.dmp1=hr(E,16),this.dmq1=hr(M,16),this.coeff=hr(D,16)},Ut.prototype.generate=function Na(l,h){var f=new Ao,_=l>>1;this.e=parseInt(h,16);for(var b=new _e(h,16),E=l/2-100,M=_e.ONE.shiftLeft(E);;){for(;this.p=new _e(l-_,1,f),0!=this.p.subtract(_e.ONE).gcd(b).compareTo(_e.ONE)||!this.p.isProbablePrime(10););for(;this.q=new _e(_,1,f),0!=this.q.subtract(_e.ONE).gcd(b).compareTo(_e.ONE)||!this.q.isProbablePrime(10););if(this.p.compareTo(this.q)<=0){var D=this.p;this.p=this.q,this.q=D}var F=this.q.subtract(this.p).abs();if(!(F.bitLength()=f.length)return null;for(var b="";++_191&&E<224?(b+=String.fromCharCode((31&E)<<6|63&f[_+1]),++_):(b+=String.fromCharCode((15&E)<<12|(63&f[_+1])<<6|63&f[_+2]),_+=2)}return b}(f,this.n.bitLength()+7>>3)},Ut.prototype.decryptOAEP=function $h(l,h,f){if(l.length!=Math.ceil(this.n.bitLength()/4))throw new Error("wrong ctext length");var _=hr(l,16),b=this.doPrivate(_);return null==b?null:function Xi(l,h,f,_){var b=w.crypto.MessageDigest,E=w.crypto.Util,M=null;for(f||(f="sha1"),"string"==typeof f&&(M=b.getCanonicalAlgName(f),_=b.getHashLength(M),f=function(V){return Vr(E.hashHex(_s(V),M))}),l=l.toByteArray(),z=0;z>3,h,f)},fr.prototype.equals=function qh(l){return l==this||this.q.equals(l.q)&&this.x.equals(l.x)},fr.prototype.toBigInteger=function Ba(){return this.x},fr.prototype.negate=function pr(){return new fr(this.q,this.x.negate().mod(this.q))},fr.prototype.add=function Np(l){return new fr(this.q,this.x.add(l.toBigInteger()).mod(this.q))},fr.prototype.subtract=function Ln(l){return new fr(this.q,this.x.subtract(l.toBigInteger()).mod(this.q))},fr.prototype.multiply=function Bp(l){return new fr(this.q,this.x.multiply(l.toBigInteger()).mod(this.q))},fr.prototype.square=function wu(){return new fr(this.q,this.x.square().mod(this.q))},fr.prototype.divide=function fo(l){return new fr(this.q,this.x.multiply(l.toBigInteger().modInverse(this.q)).mod(this.q))},fr.prototype.sqrt=function(){return new fr(this.q,this.x.sqrt().mod(this.q))},Mt.prototype.getX=function Vp(){return null==this.zinv&&(this.zinv=this.z.modInverse(this.curve.q)),this.curve.fromBigInteger(this.x.toBigInteger().multiply(this.zinv).mod(this.curve.q))},Mt.prototype.getY=function Kh(){return null==this.zinv&&(this.zinv=this.z.modInverse(this.curve.q)),this.curve.fromBigInteger(this.y.toBigInteger().multiply(this.zinv).mod(this.curve.q))},Mt.prototype.equals=function ut(l){return l==this||(this.isInfinity()?l.isInfinity():l.isInfinity()?this.isInfinity():!!l.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(l.z)).mod(this.curve.q).equals(_e.ZERO)&&l.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(l.z)).mod(this.curve.q).equals(_e.ZERO))},Mt.prototype.isInfinity=function Yi(){return null==this.x&&null==this.y||this.z.equals(_e.ZERO)&&!this.y.toBigInteger().equals(_e.ZERO)},Mt.prototype.negate=function Ei(){return new Mt(this.curve,this.x,this.y.negate(),this.z)},Mt.prototype.add=function Ni(l){if(this.isInfinity())return l;if(l.isInfinity())return this;var h=l.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(l.z)).mod(this.curve.q),f=l.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(l.z)).mod(this.curve.q);if(_e.ZERO.equals(f))return _e.ZERO.equals(h)?this.twice():this.curve.getInfinity();var _=new _e("3"),b=this.x.toBigInteger(),E=this.y.toBigInteger(),F=(l.x.toBigInteger(),l.y.toBigInteger(),f.square()),P=F.multiply(f),U=b.multiply(F),z=h.square().multiply(this.z),I=z.subtract(U.shiftLeft(1)).multiply(l.z).subtract(P).multiply(f).mod(this.curve.q),C=U.multiply(_).multiply(h).subtract(E.multiply(P)).subtract(z.multiply(h)).multiply(l.z).add(h.multiply(P)).mod(this.curve.q),B=P.multiply(this.z).multiply(l.z).mod(this.curve.q);return new Mt(this.curve,this.curve.fromBigInteger(I),this.curve.fromBigInteger(C),B)},Mt.prototype.twice=function Ps(){if(this.isInfinity())return this;if(0==this.y.toBigInteger().signum())return this.curve.getInfinity();var l=new _e("3"),h=this.x.toBigInteger(),f=this.y.toBigInteger(),_=f.multiply(this.z),b=_.multiply(f).mod(this.curve.q),E=this.curve.a.toBigInteger(),M=h.square().multiply(l);_e.ZERO.equals(E)||(M=M.add(this.z.square().multiply(E)));var D=(M=M.mod(this.curve.q)).square().subtract(h.shiftLeft(3).multiply(b)).shiftLeft(1).multiply(_).mod(this.curve.q),F=M.multiply(l).multiply(h).subtract(b.shiftLeft(1)).shiftLeft(2).multiply(b).subtract(M.square().multiply(M)).mod(this.curve.q),P=_.square().multiply(_).shiftLeft(3).mod(this.curve.q);return new Mt(this.curve,this.curve.fromBigInteger(D),this.curve.fromBigInteger(F),P)},Mt.prototype.multiply=function Zr(l){if(this.isInfinity())return this;if(0==l.signum())return this.curve.getInfinity();var P,h=l,f=h.multiply(new _e("3")),_=this.negate(),b=this,E=this.curve.q.subtract(l),M=E.multiply(new _e("3")),D=new Mt(this.curve,this.x,this.y),F=D.negate();for(P=f.bitLength()-2;P>0;--P){b=b.twice();var U=f.testBit(P);U!=h.testBit(P)&&(b=b.add(U?this:_))}for(P=M.bitLength()-2;P>0;--P){D=D.twice();var I=M.testBit(P);I!=E.testBit(P)&&(D=D.add(I?D:F))}return b},Mt.prototype.multiplyTwo=function po(l,h,f){var _;_=l.bitLength()>f.bitLength()?l.bitLength()-1:f.bitLength()-1;for(var b=this.curve.getInfinity(),E=this.add(h);_>=0;)b=b.twice(),l.testBit(_)?b=f.testBit(_)?b.add(E):b.add(this):f.testBit(_)&&(b=b.add(h)),--_;return b},Nr.prototype.getQ=function xt(){return this.q},Nr.prototype.getA=function Sn(){return this.a},Nr.prototype.getB=function Zi(){return this.b},Nr.prototype.equals=function si(l){return l==this||this.q.equals(l.q)&&this.a.equals(l.a)&&this.b.equals(l.b)},Nr.prototype.getInfinity=function Ks(){return this.infinity},Nr.prototype.fromBigInteger=function Br(l){return new fr(this.q,l)},Nr.prototype.decodePointHex=function Al(l){switch(parseInt(l.substr(0,2),16)){case 0:return this.infinity;case 2:case 3:var h=l.substr(0,2),_=(l.substr(2),this.fromBigInteger(new _e(P,16))),b=this.getA(),E=this.getB(),D=_.square().add(b).multiply(_).add(E).sqrt();return"03"==h&&(D=D.negate()),new Mt(this,_,D);case 4:case 6:case 7:var F=(l.length-2)/2,P=l.substr(2,F),U=l.substr(F+2,F);return new Mt(this,this.fromBigInteger(new _e(P,16)),this.fromBigInteger(new _e(U,16)));default:return null}},fr.prototype.getByteLength=function(){return Math.floor((this.toBigInteger().bitLength()+7)/8)},Mt.prototype.getEncoded=function(l){var h=function(E,M){var D=E.toByteArrayUnsigned();if(MD.length;)D.unshift(0);return D},f=this.getX().toBigInteger(),_=this.getY().toBigInteger(),b=h(f,32);return l?_.isEven()?b.unshift(2):b.unshift(3):(b.unshift(4),b=b.concat(h(_,32))),b},Mt.decodeFrom=function(l,h){var _=h.length-1,b=h.slice(1,1+_/2),E=h.slice(1+_/2,1+_);b.unshift(0),E.unshift(0);var M=new _e(b),D=new _e(E);return new Mt(l,l.fromBigInteger(M),l.fromBigInteger(D))},Mt.decodeFromHex=function(l,h){h.substr(0,2);var _=h.length-2,b=h.substr(2,_/2),E=h.substr(2+_/2,_/2),M=new _e(b,16),D=new _e(E,16);return new Mt(l,l.fromBigInteger(M),l.fromBigInteger(D))},Mt.prototype.add2D=function(l){if(this.isInfinity())return l;if(l.isInfinity())return this;if(this.x.equals(l.x))return this.y.equals(l.y)?this.twice():this.curve.getInfinity();var h=l.x.subtract(this.x),_=l.y.subtract(this.y).divide(h),b=_.square().subtract(this.x).subtract(l.x),E=_.multiply(this.x.subtract(b)).subtract(this.y);return new Mt(this.curve,b,E)},Mt.prototype.twice2D=function(){if(this.isInfinity())return this;if(0==this.y.toBigInteger().signum())return this.curve.getInfinity();var l=this.curve.fromBigInteger(_e.valueOf(2)),h=this.curve.fromBigInteger(_e.valueOf(3)),f=this.x.square().multiply(h).add(this.curve.a).divide(this.y.multiply(l)),_=f.square().subtract(this.x.multiply(l)),b=f.multiply(this.x.subtract(_)).subtract(this.y);return new Mt(this.curve,_,b)},Mt.prototype.multiply2D=function(l){if(this.isInfinity())return this;if(0==l.signum())return this.curve.getInfinity();var E,h=l,f=h.multiply(new _e("3")),_=this.negate(),b=this;for(E=f.bitLength()-2;E>0;--E){b=b.twice();var M=f.testBit(E);M!=h.testBit(E)&&(b=b.add2D(M?this:_))}return b},Mt.prototype.isOnCurve=function(){var l=this.getX().toBigInteger(),h=this.getY().toBigInteger(),f=this.curve.getA().toBigInteger(),_=this.curve.getB().toBigInteger(),b=this.curve.getQ(),E=h.multiply(h).mod(b),M=l.multiply(l).multiply(l).add(f.multiply(l)).add(_).mod(b);return E.equals(M)},Mt.prototype.toString=function(){return"("+this.getX().toBigInteger().toString()+","+this.getY().toBigInteger().toString()+")"},Mt.prototype.validate=function(){var l=this.curve.getQ();if(this.isInfinity())throw new Error("Point is at infinity.");var h=this.getX().toBigInteger(),f=this.getY().toBigInteger();if(h.compareTo(_e.ONE)<0||h.compareTo(l.subtract(_e.ONE))>0)throw new Error("x coordinate out of bounds");if(f.compareTo(_e.ONE)<0||f.compareTo(l.subtract(_e.ONE))>0)throw new Error("y coordinate out of bounds");if(!this.isOnCurve())throw new Error("Point is not on the curve.");if(this.multiply(l).isInfinity())throw new Error("Point is not a scalar multiple of G.");return!0};var Ji=function(){var _=new RegExp('(?:false|true|null|[\\{\\}\\[\\]]|(?:-?\\b(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?(?:[eE][+-]?[0-9]+)?\\b)|(?:"(?:[^\\0-\\x08\\x0a-\\x1f"\\\\]|\\\\(?:["/\\\\bfnrt]|u[0-9A-Fa-f]{4}))*"))',"g"),b=new RegExp("\\\\(?:([^u])|u(.{4}))","g"),E={'"':'"',"/":"/","\\":"\\",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"};function M(z,I,C){return I?E[I]:String.fromCharCode(parseInt(C,16))}var D=new String(""),U=Object.hasOwnProperty;return function(z,I){var B,C=z.match(_),R=C[0],V=!1;"{"===R?B={}:"["===R?B=[]:(B=[],V=!0);for(var L,$=[B],J=1-V,Q=C.length;J=0;)delete q[ee[be]]}return I.call(Ae,j,q)};B=Se({"":B},"")}return B}}();(typeof w>"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),w.asn1.ASN1Util=new function(){this.integerToByteHex=function(l){var h=l.toString(16);return h.length%2==1&&(h="0"+h),h},this.bigIntToMinTwosComplementsHex=function(l){var h=l.toString(16);if("-"!=h.substr(0,1))h.length%2==1?h="0"+h:h.match(/^[0-7]/)||(h="00"+h);else{var _=h.substr(1).length;_%2==1?_+=1:h.match(/^[0-7]/)||(_+=2);for(var b="",E=0;E<_;E++)b+="f";h=new _e(b,16).xor(l).add(_e.ONE).toString(16).replace(/^-/,"")}return h},this.getPEMStringFromHex=function(l,h){return Fr(l,h)},this.newObject=function(l){var f=w.asn1,_=f.ASN1Object,b=f.DERBoolean,E=f.DERInteger,M=f.DERBitString,D=f.DEROctetString,F=f.DERNull,P=f.DERObjectIdentifier,U=f.DEREnumerated,z=f.DERUTF8String,I=f.DERNumericString,C=f.DERPrintableString,B=f.DERTeletexString,R=f.DERIA5String,V=f.DERUTCTime,L=f.DERGeneralizedTime,$=f.DERVisibleString,J=f.DERBMPString,Q=f.DERSequence,te=f.DERSet,Se=f.DERTaggedObject,Ae=f.ASN1Util.newObject;if(l instanceof f.ASN1Object)return l;var j=Object.keys(l);if(1!=j.length)throw new Error("key of param shall be only one.");var q=j[0];if(-1==":asn1:bool:int:bitstr:octstr:null:oid:enum:utf8str:numstr:prnstr:telstr:ia5str:utctime:gentime:visstr:bmpstr:seq:set:tag:".indexOf(":"+q+":"))throw new Error("undefined key: "+q);if("bool"==q)return new b(l[q]);if("int"==q)return new E(l[q]);if("bitstr"==q)return new M(l[q]);if("octstr"==q)return new D(l[q]);if("null"==q)return new F(l[q]);if("oid"==q)return new P(l[q]);if("enum"==q)return new U(l[q]);if("utf8str"==q)return new z(l[q]);if("numstr"==q)return new I(l[q]);if("prnstr"==q)return new C(l[q]);if("telstr"==q)return new B(l[q]);if("ia5str"==q)return new R(l[q]);if("utctime"==q)return new V(l[q]);if("gentime"==q)return new L(l[q]);if("visstr"==q)return new $(l[q]);if("bmpstr"==q)return new J(l[q]);if("asn1"==q)return new _(l[q]);if("seq"==q){for(var ee=l[q],re=[],ue=0;ue"u"||null==this.hV)throw new Error("this.hV is null or undefined");if(this.hV.length%2==1)throw new Error("value hex must be even length: n="+"".length+",v="+this.hV);var M=this.hV.length/2,D=M.toString(16);if(D.length%2==1&&(D="0"+D),M<128)return D;var F=D.length/2;if(F>15)throw new Error("ASN.1 length too long to represent by 8x: n = "+M.toString(16));return(128+F).toString(16)+D},this.tohex=function(){return(null==this.hTLV||this.isModified)&&(this.hV=this.getFreshValueHex(),this.hL=this.getLengthHexFromValue(),this.hTLV=this.hT+this.hL+this.hV,this.isModified=!1),this.hTLV},this.getEncodedHex=function(){return this.tohex()},this.getValueHex=function(){return this.tohex(),this.hV},this.getFreshValueHex=function(){return""},this.setByParam=function(M){this.params=M},null!=l&&null!=l.tlv&&(this.hTLV=l.tlv,this.isModified=!1)},w.asn1.DERAbstractString=function(l){w.asn1.DERAbstractString.superclass.constructor.call(this),this.getString=function(){return this.s},this.setString=function(_){this.hTLV=null,this.isModified=!0,this.s=_,this.hV=Io(this.s).toLowerCase()},this.setStringHex=function(_){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=_},this.getFreshValueHex=function(){return this.hV},typeof l<"u"&&("string"==typeof l?this.setString(l):typeof l.str<"u"?this.setString(l.str):typeof l.hex<"u"&&this.setStringHex(l.hex))},He(w.asn1.DERAbstractString,w.asn1.ASN1Object),w.asn1.DERAbstractTime=function(l){w.asn1.DERAbstractTime.superclass.constructor.call(this),this.localDateToUTC=function(_){var b=_.getTime()+6e4*_.getTimezoneOffset();return new Date(b)},this.formatDate=function(_,b,E){var M=this.zeroPadding,D=this.localDateToUTC(_),F=String(D.getFullYear());"utc"==b&&(F=F.substr(2,2));var B=F+M(String(D.getMonth()+1),2)+M(String(D.getDate()),2)+M(String(D.getHours()),2)+M(String(D.getMinutes()),2)+M(String(D.getSeconds()),2);if(!0===E){var R=D.getMilliseconds();if(0!=R){var V=M(String(R),3);B=B+"."+(V=V.replace(/[0]+$/,""))}}return B+"Z"},this.zeroPadding=function(_,b){return _.length>=b?_:new Array(b-_.length+1).join("0")+_},this.setByParam=function(_){this.hV=null,this.hTLV=null,this.params=_},this.getString=function(){},this.setString=function(_){this.hTLV=null,this.isModified=!0,null==this.params&&(this.params={}),this.params.str=_},this.setByDate=function(_){this.hTLV=null,this.isModified=!0,null==this.params&&(this.params={}),this.params.date=_},this.setByDateValue=function(_,b,E,M,D,F){var P=new Date(Date.UTC(_,b-1,E,M,D,F,0));this.setByDate(P)},this.getFreshValueHex=function(){return this.hV}},He(w.asn1.DERAbstractTime,w.asn1.ASN1Object),w.asn1.DERAbstractStructured=function(l){w.asn1.DERAbstractString.superclass.constructor.call(this),this.setByASN1ObjectArray=function(f){this.hTLV=null,this.isModified=!0,this.asn1Array=f},this.appendASN1Object=function(f){this.hTLV=null,this.isModified=!0,this.asn1Array.push(f)},this.asn1Array=new Array,typeof l<"u"&&typeof l.array<"u"&&(this.asn1Array=l.array)},He(w.asn1.DERAbstractStructured,w.asn1.ASN1Object),w.asn1.DERBoolean=function(l){w.asn1.DERBoolean.superclass.constructor.call(this),this.hT="01",this.hTLV=0==l?"010100":"0101ff"},He(w.asn1.DERBoolean,w.asn1.ASN1Object),w.asn1.DERInteger=function(l){w.asn1.DERInteger.superclass.constructor.call(this),this.hT="02",this.setByBigInteger=function(h){this.hTLV=null,this.isModified=!0,this.hV=w.asn1.ASN1Util.bigIntToMinTwosComplementsHex(h)},this.setByInteger=function(h){var f=new _e(String(h),10);this.setByBigInteger(f)},this.setValueHex=function(h){this.hV=h},this.getFreshValueHex=function(){return this.hV},typeof l<"u"&&(typeof l.bigint<"u"?this.setByBigInteger(l.bigint):typeof l.int<"u"?this.setByInteger(l.int):"number"==typeof l?this.setByInteger(l):typeof l.hex<"u"&&this.setValueHex(l.hex))},He(w.asn1.DERInteger,w.asn1.ASN1Object),w.asn1.DERBitString=function(l){if(void 0!==l&&typeof l.obj<"u"){var h=w.asn1.ASN1Util.newObject(l.obj);l.hex="00"+h.tohex()}w.asn1.DERBitString.superclass.constructor.call(this),this.hT="03",this.setHexValueIncludingUnusedBits=function(f){this.hTLV=null,this.isModified=!0,this.hV=f},this.setUnusedBitsAndHexValue=function(f,_){if(f<0||7>6).toString(16)+F.toString(16))}F=128|(15&E)<<2|(192&M)>>6;var P=128|63&M;return ei((224|(240&E)>>4).toString(16)+F.toString(16)+P.toString(16))});return _.join("")}function Fe(l){for(var h=encodeURIComponent(l),f="",_=0;_"7"?"00"+l:l}function vc(l){if(!qn(l))return null;try{var h=[],f=l.substr(0,2),_=parseInt(f,16);h[0]=new String(Math.floor(_/40)),h[1]=new String(_%40);for(var b=l.substr(2),E=[],M=0;M0&&(P=P+"."+D.join(".")),P}catch{return null}}rt.getLblen=function(l,h){if("8"!=l.substr(h+2,1))return 1;var f=parseInt(l.substr(h+3,1));return 0==f?-1:0=E)break}return _},rt.getNthChildIdx=function(l,h,f){return rt.getChildIdx(l,h)[f]},rt.getIdxbyList=function(l,h,f,_){var E,M,b=rt;return 0==f.length?void 0!==_&&l.substr(h,2)!==_?-1:h:(E=f.shift())>=(M=b.getChildIdx(l,h)).length?-1:b.getIdxbyList(l,M[E],f,_)},rt.getIdxbyListEx=function(l,h,f,_){var E,M,b=rt;if(0==f.length)return void 0!==_&&l.substr(h,2)!==_?-1:h;E=f.shift(),M=b.getChildIdx(l,h);for(var D=0,F=0;F=l.length?null:b.getTLV(l,E)},rt.getTLVbyListEx=function(l,h,f,_){var b=rt,E=b.getIdxbyListEx(l,h,f,_);return-1==E?null:b.getTLV(l,E)},rt.getVbyList=function(l,h,f,_,b){var M,D,E=rt;return-1==(M=E.getIdxbyList(l,h,f,_))||M>=l.length?null:(D=E.getV(l,M),!0===b&&(D=D.substr(2)),D)},rt.getVbyListEx=function(l,h,f,_,b){var M,F,E=rt;return-1==(M=E.getIdxbyListEx(l,h,f,_))?null:(F=E.getV(l,M),"03"==l.substr(M,2)&&!1!==b&&(F=F.substr(2)),F)},rt.getInt=function(l,h,f){null==f&&(f=-1);try{var _=l.substr(h,2);if("02"!=_&&"03"!=_)return f;var b=rt.getV(l,h);return"02"==_?parseInt(b,16):function Wc(l){if(l.length%2!=0||null==(l=l.toLowerCase()).match(/^[0-9a-f]+$/))return-1;try{var h=l.substr(0,2);if("00"==h)return parseInt(l.substr(2),16);var f=parseInt(h,16);if(f>7)return-1;var _=l.substr(2),b=parseInt(_,16).toString(2);"0"==b&&(b="00000000"),b=b.slice(0,0-f);var E=parseInt(b,2);return NaN==E?-1:E}catch{return-1}}(b)}catch{return f}},rt.getOID=function(l,h,f){null==f&&(f=null);try{return"06"!=l.substr(h,2)?f:vc(rt.getV(l,h))}catch{return f}},rt.getOIDName=function(l,h,f){null==f&&(f=null);try{var _=rt.getOID(l,h,f);if(_==f)return f;var b=w.asn1.x509.OID.oid2name(_);return""==b?_:b}catch{return f}},rt.getString=function(l,h,f){null==f&&(f=null);try{return Vr(rt.getV(l,h))}catch{return f}},rt.hextooidstr=function(l){var h=function(z,I){return z.length>=I?z:new Array(I-z.length+1).join("0")+z},f=[],_=l.substr(0,2),b=parseInt(_,16);f[0]=new String(Math.floor(b/40)),f[1]=new String(b%40);for(var E=l.substr(2),M=[],D=0;D0&&(U=U+"."+F.join(".")),U},rt.dump=function(l,h,f,_){var b=rt,E=b.getV,M=b.dump,D=b.getChildIdx,F=l;l instanceof w.asn1.ASN1Object&&(F=l.tohex());var P=function(Ae,j){return Ae.length<=2*j?Ae:Ae.substr(0,j)+"..(total "+Ae.length/2+"bytes).."+Ae.substr(Ae.length-j,j)};void 0===h&&(h={ommit_long_octet:32}),void 0===f&&(f=0),void 0===_&&(_="");var te,U=h.ommit_long_octet;if("01"==(te=F.substr(f,2)))return"00"==(z=E(F,f))?_+"BOOLEAN FALSE\n":_+"BOOLEAN TRUE\n";if("02"==te)return _+"INTEGER "+P(z=E(F,f),U)+"\n";if("03"==te){var z=E(F,f);return b.isASN1HEX(z.substr(2))?(I=_+"BITSTRING, encapsulates\n")+M(z.substr(2),h,0,_+" "):_+"BITSTRING "+P(z,U)+"\n"}if("04"==te)return z=E(F,f),b.isASN1HEX(z)?(I=_+"OCTETSTRING, encapsulates\n")+M(z,h,0,_+" "):_+"OCTETSTRING "+P(z,U)+"\n";if("05"==te)return _+"NULL\n";if("06"==te){var C=E(F,f),B=w.asn1.ASN1Util.oidHexToInt(C),R=w.asn1.x509.OID.oid2name(B),V=B.replace(/\./g," ");return""!=R?_+"ObjectIdentifier "+R+" ("+V+")\n":_+"ObjectIdentifier ("+V+")\n"}if("0a"==te)return _+"ENUMERATED "+parseInt(E(F,f))+"\n";if("0c"==te)return _+"UTF8String '"+ei(E(F,f))+"'\n";if("13"==te)return _+"PrintableString '"+ei(E(F,f))+"'\n";if("14"==te)return _+"TeletexString '"+ei(E(F,f))+"'\n";if("16"==te)return _+"IA5String '"+ei(E(F,f))+"'\n";if("17"==te)return _+"UTCTime "+ei(E(F,f))+"\n";if("18"==te)return _+"GeneralizedTime "+ei(E(F,f))+"\n";if("1a"==te)return _+"VisualString '"+ei(E(F,f))+"'\n";if("1e"==te)return _+"BMPString '"+Ge(E(F,f))+"'\n";if("30"==te){if("3000"==F.substr(f,4))return _+"SEQUENCE {}\n";I=_+"SEQUENCE\n";var $=h;if((2==(L=D(F,f)).length||3==L.length)&&"06"==F.substr(L[0],2)&&"04"==F.substr(L[L.length-1],2)){R=b.oidname(E(F,L[0]));var J=JSON.parse(JSON.stringify(h));J.x509ExtName=R,$=J}for(var Q=0;Q4?{enum:{hex:L}}:{enum:parseInt(L,16)};if("30"==R||"31"==R)return V[C[R]]=function(q){for(var ee=[],re=M(q,0),ue=0;ue31))&&128==(192&f)&&(31&f)==_}catch{return!1}},rt.isASN1HEX=function(l){var h=rt;if(l.length%2==1)return!1;var f=h.getVblen(l,0),_=l.substr(0,2),b=h.getL(l,0);return l.length-_.length-b.length==2*f},rt.checkStrictDER=function(l,h,f,_,b){var E=rt;if(void 0===f){if("string"!=typeof l)throw new Error("not hex string");if(l=l.toLowerCase(),!w.lang.String.isHex(l))throw new Error("not hex string");f=l.length,b=(_=l.length/2)<128?1:Math.ceil(_.toString(16))+1}if(E.getL(l,h).length>2*b)throw new Error("L of TLV too long: idx="+h);var D=E.getVblen(l,h);if(D>_)throw new Error("value of L too long than hex: idx="+h);var F=E.getTLV(l,h),P=F.length-2-E.getL(l,h).length;if(P!==2*D)throw new Error("V string length and L's value not the same:"+P+"/"+2*D);if(0===h&&l.length!=F.length)throw new Error("total length and TLV length unmatch:"+l.length+"!="+F.length);var U=l.substr(h,2);if("02"===U){var z=E.getVidx(l,h);if("00"==l.substr(z,2)&&l.charCodeAt(z+2)<56)throw new Error("not least zeros for DER INTEGER")}if(32&parseInt(U,16)){for(var I=E.getVblen(l,h),C=0,B=E.getChildIdx(l,h),R=0;R"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),(typeof w.asn1.x509>"u"||!w.asn1.x509)&&(w.asn1.x509={}),w.asn1.x509.Certificate=function(l){w.asn1.x509.Certificate.superclass.constructor.call(this);var f=w.asn1,_=f.DERBitString,b=f.DERSequence,E=f.x509,M=E.TBSCertificate,D=E.AlgorithmIdentifier;this.params=void 0,this.setByParam=function(F){this.params=F},this.sign=function(){var F=this.params,P=F.sigalg;null!=F.sigalg.name&&(P=F.sigalg.name);var U=F.tbsobj.tohex(),z=new w.crypto.Signature({alg:P});z.init(F.cakey),z.updateHex(U),F.sighex=z.sign()},this.getPEM=function(){return Fr(this.tohex(),"CERTIFICATE")},this.tohex=function(){var F=this.params;if((null==F.tbsobj||null==F.tbsobj)&&(F.tbsobj=new M(F)),null==F.sighex&&null!=F.cakey&&this.sign(),null==F.sighex)throw new Error("sighex or cakey parameter not defined");var P=[];return P.push(F.tbsobj),P.push(new D({name:F.sigalg})),P.push(new _({hex:"00"+F.sighex})),new b({array:P}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&(this.params=l)},He(w.asn1.x509.Certificate,w.asn1.ASN1Object),w.asn1.x509.TBSCertificate=function(l){w.asn1.x509.TBSCertificate.superclass.constructor.call(this);var f=w.asn1,_=f.x509,b=f.DERTaggedObject,E=f.DERInteger,M=f.DERSequence,D=_.AlgorithmIdentifier,F=_.Time,P=_.X500Name,U=_.Extensions,z=_.SubjectPublicKeyInfo;this.params=null,this.setByParam=function(I){this.params=I},this.tohex=function(){var I=[],C=this.params;if(null!=C.version||1!=C.version){var B=2;null!=C.version&&(B=C.version-1);var R=new b({obj:new E({int:B})});I.push(R)}return I.push(new E(C.serial)),I.push(new D({name:C.sigalg})),I.push(new P(C.issuer)),I.push(new M({array:[new F(C.notbefore),new F(C.notafter)]})),I.push(new P(C.subject)),I.push(new z(Zt.getKey(C.sbjpubkey))),void 0!==C.ext&&C.ext.length>0&&I.push(new b({tag:"a3",obj:new U(C.ext)})),new w.asn1.DERSequence({array:I}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.x509.TBSCertificate,w.asn1.ASN1Object),w.asn1.x509.Extensions=function(l){w.asn1.x509.Extensions.superclass.constructor.call(this);var f=w.asn1,_=f.DERSequence,b=f.x509;this.aParam=[],this.setByParam=function(E){this.aParam=E},this.tohex=function(){for(var E=[],M=0;M-1&&D.push(new _({int:this.pathLen}));var F=new b({array:D});return this.asn1ExtnValue=F,this.asn1ExtnValue.tohex()},this.oid="2.5.29.19",this.cA=!1,this.pathLen=-1,void 0!==l&&(void 0!==l.cA&&(this.cA=l.cA),void 0!==l.pathLen&&(this.pathLen=l.pathLen))},He(w.asn1.x509.BasicConstraints,w.asn1.x509.Extension),w.asn1.x509.CRLDistributionPoints=function(l){w.asn1.x509.CRLDistributionPoints.superclass.constructor.call(this,l);var f=w.asn1,_=f.x509;this.getExtnValueHex=function(){return this.asn1ExtnValue.tohex()},this.setByDPArray=function(b){for(var E=[],M=0;M0&&E.push(new f({array:M}))}return new f({array:E}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&(this.params=l)},He(w.asn1.x509.PolicyInformation,w.asn1.ASN1Object),w.asn1.x509.PolicyQualifierInfo=function(l){w.asn1.x509.PolicyQualifierInfo.superclass.constructor.call(this,l);var h=w.asn1,f=h.DERSequence,_=h.DERIA5String,b=h.DERObjectIdentifier,E=h.x509.UserNotice;this.params=null,this.tohex=function(){return void 0!==this.params.cps?new f({array:[new b({oid:"1.3.6.1.5.5.7.2.1"}),new _({str:this.params.cps})]}).tohex():null!=this.params.unotice?new f({array:[new b({oid:"1.3.6.1.5.5.7.2.2"}),new E(this.params.unotice)]}).tohex():void 0},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&(this.params=l)},He(w.asn1.x509.PolicyQualifierInfo,w.asn1.ASN1Object),w.asn1.x509.UserNotice=function(l){w.asn1.x509.UserNotice.superclass.constructor.call(this,l);var h=w.asn1.DERSequence,_=w.asn1.x509.DisplayText,b=w.asn1.x509.NoticeReference;this.params=null,this.tohex=function(){var E=[];return void 0!==this.params.noticeref&&E.push(new b(this.params.noticeref)),void 0!==this.params.exptext&&E.push(new _(this.params.exptext)),new h({array:E}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&(this.params=l)},He(w.asn1.x509.UserNotice,w.asn1.ASN1Object),w.asn1.x509.NoticeReference=function(l){w.asn1.x509.NoticeReference.superclass.constructor.call(this,l);var h=w.asn1.DERSequence,f=w.asn1.DERInteger,_=w.asn1.x509.DisplayText;this.params=null,this.tohex=function(){var b=[];if(void 0!==this.params.org&&b.push(new _(this.params.org)),void 0!==this.params.noticenum){for(var E=[],M=this.params.noticenum,D=0;D0)for(var M=0;M0;b++){var E=h.shift();if(!0===f){var D=(_.pop()+","+E).replace(/\\,/g,",");_.push(D),f=!1}else _.push(E);"\\"===E.substr(-1,1)&&(f=!0)}return _=_.map(function(F){return F.replace("/","\\/")}),_.reverse(),"/"+_.join("/")},w.asn1.x509.X500Name.ldapToOneline=function(l){return w.asn1.x509.X500Name.ldapToCompat(l)},w.asn1.x509.RDN=function(l){w.asn1.x509.RDN.superclass.constructor.call(this),this.asn1Array=[],this.paramArray=[],this.sRule="utf8";var h=w.asn1.x509.AttributeTypeAndValue;this.setByParam=function(f){void 0!==f.rule&&(this.sRule=f.rule),void 0!==f.str&&this.addByMultiValuedString(f.str),void 0!==f.array&&(this.paramArray=f.array)},this.addByString=function(f){this.asn1Array.push(new w.asn1.x509.AttributeTypeAndValue({str:f,rule:this.sRule}))},this.addByMultiValuedString=function(f){for(var _=w.asn1.x509.RDN.parseString(f),b=0;b<_.length;b++)this.addByString(_[b])},this.tohex=function(){if(0==this.asn1Array.length&&this.paramArray.length>0)for(var f=0;f0;b++){var E=h.shift();if(!0===f){var D=(_.pop()+"+"+E).replace(/\\\+/g,"+");_.push(D),f=!1}else _.push(E);"\\"===E.substr(-1,1)&&(f=!0)}var F=!1,P=[];for(b=0;_.length>0;b++){if(E=_.shift(),!0===F){var U=P.pop();E.match(/"$/)?(D=(U+"+"+E).replace(/^([^=]+)="(.*)"$/,"$1=$2"),P.push(D),F=!1):P.push(U+"+"+E)}else P.push(E);E.match(/^[^=]+="/)&&(F=!0)}return P},w.asn1.x509.AttributeTypeAndValue=function(l){w.asn1.x509.AttributeTypeAndValue.superclass.constructor.call(this),this.sRule="utf8",this.sType=null,this.sValue=null,this.dsType=null;var f=w.asn1,_=f.DERSequence,b=f.DERUTF8String,E=f.DERPrintableString,M=f.DERTeletexString,D=f.DERIA5String,F=f.DERVisibleString,P=f.DERBMPString,U=w.lang.String.isMail,z=w.lang.String.isPrintable;this.setByParam=function(I){if(void 0!==I.rule&&(this.sRule=I.rule),void 0!==I.ds&&(this.dsType=I.ds),void 0===I.value&&void 0!==I.str){var B=I.str.match(/^([^=]+)=(.+)$/);if(!B)throw new Error("malformed attrTypeAndValueStr: "+attrTypeAndValueStr);this.sType=B[1],this.sValue=B[2]}else this.sType=I.type,this.sValue=I.value},this.setByString=function(I,C){void 0!==C&&(this.sRule=C);var B=I.match(/^([^=]+)=(.+)$/);if(!B)throw new Error("malformed attrTypeAndValueStr: "+attrTypeAndValueStr);this.setByAttrTypeAndValueStr(B[1],B[2])},this._getDsType=function(){var I=this.sType,C=this.sValue,B=this.sRule;return"prn"===B?"CN"==I&&U(C)?"ia5":z(C)?"prn":"utf8":"utf8"===B?"CN"==I&&U(C)?"ia5":"C"==I?"prn":"utf8":"utf8"},this.setByAttrTypeAndValueStr=function(I,C,B){void 0!==B&&(this.sRule=B),this.sType=I,this.sValue=C},this.getValueObj=function(I,C){if("utf8"==I)return new b({str:C});if("prn"==I)return new E({str:C});if("tel"==I)return new M({str:C});if("ia5"==I)return new D({str:C});if("vis"==I)return new F({str:C});if("bmp"==I)return new P({str:C});throw new Error("unsupported directory string type: type="+I+" value="+C)},this.tohex=function(){null==this.dsType&&(this.dsType=this._getDsType());var I=w.asn1.x509.OID.atype2obj(this.sType),C=this.getValueObj(this.dsType,this.sValue),B=new _({array:[I,C]});return this.TLV=B.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.x509.AttributeTypeAndValue,w.asn1.ASN1Object),w.asn1.x509.SubjectPublicKeyInfo=function(l){w.asn1.x509.SubjectPublicKeyInfo.superclass.constructor.call(this);var b=w.asn1,E=b.DERInteger,M=b.DERBitString,D=b.DERObjectIdentifier,F=b.DERSequence,P=b.ASN1Util.newObject,z=b.x509.AlgorithmIdentifier;this.getASN1Object=function(){if(null==this.asn1AlgId||null==this.asn1SubjPKey)throw"algId and/or subjPubKey not set";return new F({array:[this.asn1AlgId,this.asn1SubjPKey]})},this.tohex=function(){var R=this.getASN1Object();return this.hTLV=R.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},this.setPubKey=function(R){try{if(R instanceof Ut){var L=P({seq:[{int:{bigint:R.n}},{int:{int:R.e}}]}).tohex();this.asn1AlgId=new z({name:"rsaEncryption"}),this.asn1SubjPKey=new M({hex:"00"+L})}}catch{}try{if(R instanceof w.crypto.ECDSA){var $=new D({name:R.curveName});this.asn1AlgId=new z({name:"ecPublicKey",asn1params:$}),this.asn1SubjPKey=new M({hex:"00"+R.pubKeyHex})}}catch{}try{if(R instanceof w.crypto.DSA){$=new P({seq:[{int:{bigint:R.p}},{int:{bigint:R.q}},{int:{bigint:R.g}}]}),this.asn1AlgId=new z({name:"dsa",asn1params:$});var J=new E({bigint:R.y});this.asn1SubjPKey=new M({hex:"00"+J.tohex()})}}catch{}},void 0!==l&&this.setPubKey(l)},He(w.asn1.x509.SubjectPublicKeyInfo,w.asn1.ASN1Object),w.asn1.x509.Time=function(l){w.asn1.x509.Time.superclass.constructor.call(this);var b=w.asn1,E=b.DERUTCTime,M=b.DERGeneralizedTime;this.params=null,this.type=null,this.setTimeParams=function(D){this.timeParams=D},this.setByParam=function(D){this.params=D},this.getType=function(D){return D.match(/^[0-9]{12}Z$/)?"utc":D.match(/^[0-9]{14}Z$/)?"gen":D.match(/^[0-9]{12}\.[0-9]+Z$/)?"utc":D.match(/^[0-9]{14}\.[0-9]+Z$/)?"gen":null},this.tohex=function(){var D=this.params,F=null;if("string"==typeof D&&(D={str:D}),null!=D&&D.str&&(null==D.type||null==D.type)&&(D.type=this.getType(D.str)),null!=D&&D.str?("utc"==D.type&&(F=new E(D.str)),"gen"==D.type&&(F=new M(D.str))):F="gen"==this.type?new M:new E,null==F)throw new Error("wrong setting for Time");return this.TLV=F.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},w.asn1.x509.Time_bak=function(l){w.asn1.x509.Time_bak.superclass.constructor.call(this);var b=w.asn1,E=b.DERUTCTime,M=b.DERGeneralizedTime;this.setTimeParams=function(D){this.timeParams=D},this.tohex=function(){var D=null;return D=null!=this.timeParams?"utc"==this.type?new E(this.timeParams):new M(this.timeParams):"utc"==this.type?new E:new M,this.TLV=D.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},this.type="utc",void 0!==l&&(void 0!==l.type?this.type=l.type:void 0!==l.str&&(l.str.match(/^[0-9]{12}Z$/)&&(this.type="utc"),l.str.match(/^[0-9]{14}Z$/)&&(this.type="gen")),this.timeParams=l)},He(w.asn1.x509.Time,w.asn1.ASN1Object),w.asn1.x509.AlgorithmIdentifier=function(l){w.asn1.x509.AlgorithmIdentifier.superclass.constructor.call(this),this.nameAlg=null,this.asn1Alg=null,this.asn1Params=null,this.paramEmpty=!1;var f=w.asn1,_=f.x509.AlgorithmIdentifier.PSSNAME2ASN1TLV;if(this.tohex=function(){if(null===this.nameAlg&&null===this.asn1Alg)throw new Error("algorithm not specified");if(null!==this.nameAlg){var E=null;for(var M in _)M===this.nameAlg&&(E=_[M]);if(null!==E)return this.hTLV=E,this.hTLV}null!==this.nameAlg&&null===this.asn1Alg&&(this.asn1Alg=f.x509.OID.name2obj(this.nameAlg));var D=[this.asn1Alg];null!==this.asn1Params&&D.push(this.asn1Params);var F=new f.DERSequence({array:D});return this.hTLV=F.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&(void 0!==l.name&&(this.nameAlg=l.name),void 0!==l.asn1params&&(this.asn1Params=l.asn1params),void 0!==l.paramempty&&(this.paramEmpty=l.paramempty)),null===this.asn1Params&&!1===this.paramEmpty&&null!==this.nameAlg){void 0!==this.nameAlg.name&&(this.nameAlg=this.nameAlg.name);var b=this.nameAlg.toLowerCase();"withdsa"!==b.substr(-7,7)&&"withecdsa"!==b.substr(-9,9)&&(this.asn1Params=new f.DERNull)}},He(w.asn1.x509.AlgorithmIdentifier,w.asn1.ASN1Object),w.asn1.x509.AlgorithmIdentifier.PSSNAME2ASN1TLV={SHAwithRSAandMGF1:"300d06092a864886f70d01010a3000",SHA256withRSAandMGF1:"303d06092a864886f70d01010a3030a00d300b0609608648016503040201a11a301806092a864886f70d010108300b0609608648016503040201a203020120",SHA384withRSAandMGF1:"303d06092a864886f70d01010a3030a00d300b0609608648016503040202a11a301806092a864886f70d010108300b0609608648016503040202a203020130",SHA512withRSAandMGF1:"303d06092a864886f70d01010a3030a00d300b0609608648016503040203a11a301806092a864886f70d010108300b0609608648016503040203a203020140"},w.asn1.x509.GeneralName=function(l){w.asn1.x509.GeneralName.superclass.constructor.call(this);var _=w.asn1,b=_.x509,E=b.X500Name,M=b.OtherName,D=_.DERIA5String,P=_.DEROctetString,U=_.DERTaggedObject,z=_.ASN1Object,I=Error;this.params=null,this.setByParam=function(C){this.params=C},this.tohex=function(){var B,R,C=this.params,V=!1;if(void 0!==C.other)B="a0",R=new M(C.other);else if(void 0!==C.rfc822)B="81",R=new D({str:C.rfc822});else if(void 0!==C.dns)B="82",R=new D({str:C.dns});else if(void 0!==C.dn)B="a4",V=!0,R="string"==typeof C.dn?new E({str:C.dn}):C.dn instanceof w.asn1.x509.X500Name?C.dn:new E(C.dn);else if(void 0!==C.ldapdn)B="a4",V=!0,R=new E({ldapstr:C.ldapdn});else if(void 0!==C.certissuer||void 0!==C.certsubj){B="a4",V=!0;var L,$,J=null;if(void 0!==C.certsubj?(L=!1,$=C.certsubj):(L=!0,$=C.certissuer),$.match(/^[0-9A-Fa-f]+$/),-1!=$.indexOf("-----BEGIN ")&&(J=ir($)),null==J)throw new Error("certsubj/certissuer not cert");var te,Q=new rn;Q.hex=J,te=L?Q.getIssuerHex():Q.getSubjectHex(),(R=new z).hTLV=te}else if(void 0!==C.uri)B="86",R=new D({str:C.uri});else{if(void 0===C.ip)throw new I("improper params");B="87";var Se,Ae=C.ip;try{if(Ae.match(/^[0-9a-f]+$/)){var j=Ae.length;if(8!=j&&16!=j&&32!=j&&64!=j)throw"err";Se=Ae}else Se=md(Ae)}catch(ee){throw new I("malformed IP address: "+C.ip+":"+ee.message)}R=new P({hex:Se})}return new U({tag:B,explicit:V,obj:R}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.x509.GeneralName,w.asn1.ASN1Object),w.asn1.x509.GeneralNames=function(l){w.asn1.x509.GeneralNames.superclass.constructor.call(this);var _=w.asn1;this.setByParamArray=function(b){for(var E=0;E"u")throw"Name of ObjectIdentifier not defined: "+h;var _=new l({oid:this.name2oidList[h]});return this.objCache[h]=_,_},this.atype2obj=function(h){if(void 0!==this.objCache[h])return this.objCache[h];var f;if(h.match(/^\d+\.\d+\.[0-9.]+$/))f=h;else if(void 0!==this.atype2oidList[h])f=this.atype2oidList[h];else{if(void 0===this.name2oidList[h])throw new Error("AttributeType name undefined: "+h);f=this.name2oidList[h]}var _=new l({oid:f});return this.objCache[h]=_,_},this.registerOIDs=function(h){if(this.checkOIDs(h))for(var f in h)this.name2oidList[f]=h[f]},this.checkOIDs=function(h){try{var f=Object.keys(h);return 0!=f.length&&(f.map(function(_,b,E){if(!this[_].match(/^[0-2]\.[0-9.]+$/))throw new Error("value is not OID")},h),!0)}catch{return!1}}},w.asn1.x509.OID.oid2name=function(l){var h=w.asn1.x509.OID.name2oidList;for(var f in h)if(h[f]==l)return f;return""},w.asn1.x509.OID.oid2atype=function(l){var h=w.asn1.x509.OID.atype2oidList;for(var f in h)if(h[f]==l)return f;return l},w.asn1.x509.OID.name2oid=function(l){if(l.match(/^[0-9.]+$/))return l;var h=w.asn1.x509.OID.name2oidList;return void 0===h[l]?"":h[l]},w.asn1.x509.X509Util={},w.asn1.x509.X509Util.newCertPEM=function(l){return new(0,w.asn1.x509.Certificate)(l).getPEM()},(typeof w>"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),(typeof w.asn1.cms>"u"||!w.asn1.cms)&&(w.asn1.cms={}),w.asn1.cms.Attribute=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.DERSet,M=_.DERObjectIdentifier;this.params=null,this.typeOid=null,this.setByParam=function(D){this.params=D},this.getValueArray=function(){throw new h("not yet implemented abstract")},this.tohex=function(){var D=new M({oid:this.typeOid}),F=new E({array:this.getValueArray()});return new b({array:[D,F]}).tohex()},this.getEncodedHex=function(){return this.tohex()}},He(w.asn1.cms.Attribute,w.asn1.ASN1Object),w.asn1.cms.ContentType=function(l){var f=w.asn1;f.cms.ContentType.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.3",this.getValueArray=function(){return[new f.DERObjectIdentifier(this.params.type)]},null!=l&&this.setByParam(l)},He(w.asn1.cms.ContentType,w.asn1.cms.Attribute),w.asn1.cms.MessageDigest=function(l){var f=w.asn1,_=f.DEROctetString;f.cms.MessageDigest.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.4",this.getValueArray=function(){return[new _(this.params)]},null!=l&&this.setByParam(l)},He(w.asn1.cms.MessageDigest,w.asn1.cms.Attribute),w.asn1.cms.SigningTime=function(l){var f=w.asn1;f.cms.SigningTime.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.5",this.getValueArray=function(){return[new f.x509.Time(this.params)]},null!=l&&this.setByParam(l)},He(w.asn1.cms.SigningTime,w.asn1.cms.Attribute),w.asn1.cms.SigningCertificate=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.cms,M=E.ESSCertID;E.SigningCertificate.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.12",this.getValueArray=function(){if(null==this.params||null==this.params||null==this.params.array)throw new h("parameter 'array' not specified");for(var F=this.params.array,P=[],U=0;U0){for(var B=E(I.valhex,C[0]),R=z(B,0),V=[],L=0;L1){var Q=E(I.valhex,C[1]);I.polhex=Q}delete I.valhex},this.setSignaturePolicyIdentifier=function(I){var C=z(I.valhex,0);if(C.length>0){var B=_.getOID(I.valhex,C[0]);I.oid=B}if(C.length>1){var R=new h,V=z(I.valhex,C[1]),L=E(I.valhex,V[0]),$=R.getAlgorithmIdentifierName(L);I.alg=$;var J=b(I.valhex,V[1]);I.hash=J}delete I.valhex},this.setSigningCertificateV2=function(I){var C=z(I.valhex,0);if(C.length>0){for(var B=E(I.valhex,C[0]),R=z(B,0),V=[],L=0;L1){var Q=E(I.valhex,C[1]);I.polhex=Q}delete I.valhex},this.getESSCertID=function(I){var C={},B=z(I,0);if(B.length>0){var R=b(I,B[0]);C.hash=R}if(B.length>1){var V=E(I,B[1]),L=this.getIssuerSerial(V);null!=L.serial&&(C.serial=L.serial),null!=L.issuer&&(C.issuer=L.issuer)}return C},this.getESSCertIDv2=function(I){var C={},B=z(I,0);if(B.length<1||3R+1){var $=E(I,B[R+1]),J=this.getIssuerSerial($);C.issuer=J.issuer,C.serial=J.serial}return C},this.getIssuerSerial=function(I){var C={},B=z(I,0),R=E(I,B[0]),V=f.getGeneralNames(R);C.issuer=V[0].dn;var $=b(I,B[1]);return C.serial={hex:$},C},this.getCertificateSet=function(I){for(var C=z(I,0),B=[],R=0;R"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),(typeof w.asn1.tsp>"u"||!w.asn1.tsp)&&(w.asn1.tsp={}),w.asn1.tsp.TimeStampToken=function(l){var _=w.asn1.tsp;_.TimeStampToken.superclass.constructor.call(this),this.params=null,this.getEncodedHexPrepare=function(){var b=new _.TSTInfo(this.params.econtent.content);this.params.econtent.content.hex=b.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.TimeStampToken,w.asn1.cms.SignedData),w.asn1.tsp.TSTInfo=function(l){Error;var _=w.asn1,b=_.DERSequence,E=_.DERInteger,M=_.DERBoolean,D=_.DERGeneralizedTime,F=_.DERObjectIdentifier,P=_.DERTaggedObject,U=_.tsp,z=U.MessageImprint,I=U.Accuracy,B=_.x509.GeneralName;if(U.TSTInfo.superclass.constructor.call(this),this.dVersion=new E({int:1}),this.dPolicy=null,this.dMessageImprint=null,this.dSerial=null,this.dGenTime=null,this.dAccuracy=null,this.dOrdering=null,this.dNonce=null,this.dTsa=null,this.tohex=function(){var R=[this.dVersion];if(null==this.dPolicy)throw new Error("policy shall be specified.");if(R.push(this.dPolicy),null==this.dMessageImprint)throw new Error("messageImprint shall be specified.");if(R.push(this.dMessageImprint),null==this.dSerial)throw new Error("serialNumber shall be specified.");if(R.push(this.dSerial),null==this.dGenTime)throw new Error("genTime shall be specified.");R.push(this.dGenTime),null!=this.dAccuracy&&R.push(this.dAccuracy),null!=this.dOrdering&&R.push(this.dOrdering),null!=this.dNonce&&R.push(this.dNonce),null!=this.dTsa&&R.push(this.dTsa);var V=new b({array:R});return this.hTLV=V.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==l){if("string"==typeof l.policy){if(!l.policy.match(/^[0-9.]+$/))throw"policy shall be oid like 0.1.4.134";this.dPolicy=new F({oid:l.policy})}void 0!==l.messageImprint&&(this.dMessageImprint=new z(l.messageImprint)),void 0!==l.serial&&(this.dSerial=new E(l.serial)),void 0!==l.genTime&&(this.dGenTime=new D(l.genTime)),void 0!==l.accuracy&&(this.dAccuracy=new I(l.accuracy)),void 0!==l.ordering&&1==l.ordering&&(this.dOrdering=new M),void 0!==l.nonce&&(this.dNonce=new E(l.nonce)),void 0!==l.tsa&&(this.dTsa=new P({tag:"a0",explicit:!0,obj:new B({dn:l.tsa})}))}},He(w.asn1.tsp.TSTInfo,w.asn1.ASN1Object),w.asn1.tsp.Accuracy=function(l){var f=w.asn1,_=f.ASN1Util.newObject;f.tsp.Accuracy.superclass.constructor.call(this),this.params=null,this.tohex=function(){var b=this.params,E=[];return null!=b.seconds&&"number"==typeof b.seconds&&E.push({int:b.seconds}),null!=b.millis&&"number"==typeof b.millis&&E.push({tag:{tagi:"80",obj:{int:b.millis}}}),null!=b.micros&&"number"==typeof b.micros&&E.push({tag:{tagi:"81",obj:{int:b.micros}}}),_({seq:E}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.Accuracy,w.asn1.ASN1Object),w.asn1.tsp.MessageImprint=function(l){var f=w.asn1,_=f.DERSequence,b=f.DEROctetString,M=f.x509.AlgorithmIdentifier;f.tsp.MessageImprint.superclass.constructor.call(this),this.params=null,this.tohex=function(){var D=this.params,F=new M({name:D.alg}),P=new b({hex:D.hash});return new _({array:[F,P]}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.tsp.MessageImprint,w.asn1.ASN1Object),w.asn1.tsp.TimeStampReq=function(l){var f=w.asn1,_=f.DERSequence,b=f.DERInteger,E=f.DERBoolean,D=f.DERObjectIdentifier,F=f.tsp,P=F.MessageImprint;F.TimeStampReq.superclass.constructor.call(this),this.params=null,this.tohex=function(){var U=this.params,z=[];return z.push(new b({int:1})),z.push(U.messageImprint instanceof w.asn1.ASN1Object?U.messageImprint:new P(U.messageImprint)),null!=U.policy&&z.push(new D(U.policy)),null!=U.nonce&&z.push(new b(U.nonce)),1==U.certreq&&z.push(new E),new _({array:z}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.TimeStampReq,w.asn1.ASN1Object),w.asn1.tsp.TimeStampResp=function(l){var f=w.asn1,_=f.DERSequence,E=f.tsp,M=E.PKIStatusInfo;E.TimeStampResp.superclass.constructor.call(this),this.params=null,this.tohex=function(){var D=this.params,F=[];if(null!=D.econtent||null!=D.tst)if(F.push(new M(null!=D.statusinfo?D.statusinfo:"granted")),null!=D.econtent)F.push(new E.TimeStampToken(D).getContentInfo());else{if(!(D.tst instanceof f.ASN1Object))throw new Error("improper member tst value");F.push(D.tst)}else{if(null==D.statusinfo)throw new Error("parameter for token nor statusinfo not specified");F.push(new M(D.statusinfo))}return new _({array:F}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.TimeStampResp,w.asn1.ASN1Object),w.asn1.tsp.PKIStatusInfo=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.tsp,M=E.PKIStatus,D=E.PKIFreeText,F=E.PKIFailureInfo;E.PKIStatusInfo.superclass.constructor.call(this),this.params=null,this.tohex=function(){var P=this.params,U=[];if("string"==typeof P)U.push(new M(P));else{if(null==P.status)throw new h("property 'status' unspecified");U.push(new M(P.status)),null!=P.statusstr&&U.push(new D(P.statusstr)),null!=P.failinfo&&U.push(new F(P.failinfo))}return new b({array:U}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.PKIStatusInfo,w.asn1.ASN1Object),w.asn1.tsp.PKIStatus=function(l){var h=Error,_=w.asn1,b=_.DERInteger;_.tsp.PKIStatus.superclass.constructor.call(this);var M={granted:0,grantedWithMods:1,rejection:2,waiting:3,revocationWarning:4,revocationNotification:5};this.params=null,this.tohex=function(){var P,D=this.params;if("string"==typeof D)try{P=M[D]}catch{throw new h("undefined name: "+D)}else{if("number"!=typeof D)throw new h("unsupported params");P=D}return new b({int:P}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.PKIStatus,w.asn1.ASN1Object),w.asn1.tsp.PKIFreeText=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.DERUTF8String;_.tsp.PKIFreeText.superclass.constructor.call(this),this.params=null,this.tohex=function(){var D=this.params;if(!D instanceof Array)throw new h("wrong params: not array");for(var F=[],P=0;P=0;I--)z+=U[I];return z}if("string"==typeof F&&null!=D[F])return vd([F],D);if("object"==typeof F&&null!=F.length)return vd(F,D);throw new h("wrong params")},this.tohex=function(){var P=this.getBinValue();return new b({bin:P}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.PKIFailureInfo,w.asn1.ASN1Object),w.asn1.tsp.AbstractTSAAdapter=function(l){this.getTSTHex=function(h,f){throw"not implemented yet"}},w.asn1.tsp.SimpleTSAAdapter=function(l){var _=w.asn1.tsp,b=w.crypto.Util.hashHex;_.SimpleTSAAdapter.superclass.constructor.call(this),this.params=null,this.serial=0,this.getTSTHex=function(E,M){var D=b(E,M);this.params.econtent.content.messageImprint={alg:M,hash:D},this.params.econtent.content.serial={int:this.serial++};var F=Math.floor(1e9*Math.random());return this.params.econtent.content.nonce={int:F},new _.TimeStampToken(this.params).getContentInfoEncodedHex()},void 0!==l&&(this.params=l)},He(w.asn1.tsp.SimpleTSAAdapter,w.asn1.tsp.AbstractTSAAdapter),w.asn1.tsp.FixedTSAAdapter=function(l){var _=w.asn1.tsp,b=w.crypto.Util.hashHex;_.FixedTSAAdapter.superclass.constructor.call(this),this.params=null,this.getTSTHex=function(E,M){var D=b(E,M);return this.params.econtent.content.messageImprint={alg:M,hash:D},new _.TimeStampToken(this.params).getContentInfoEncodedHex()},void 0!==l&&(this.params=l)},He(w.asn1.tsp.FixedTSAAdapter,w.asn1.tsp.AbstractTSAAdapter),w.asn1.tsp.TSPUtil=new function(){},w.asn1.tsp.TSPUtil.newTimeStampToken=function(l){return new w.asn1.tsp.TimeStampToken(l)},w.asn1.tsp.TSPUtil.parseTimeStampReq=function(l){return(new w.asn1.tsp.TSPParser).getTimeStampReq(l)},w.asn1.tsp.TSPUtil.parseMessageImprint=function(l){return(new w.asn1.tsp.TSPParser).getMessageImprint(l)},w.asn1.tsp.TSPParser=function(){Error;var f=new rn,_=rt,b=_.getV,E=_.getTLV,M=_.getIdxbyList,F=_.getChildIdx,P=["granted","grantedWithMods","rejection","waiting","revocationWarning","revocationNotification"],U={0:"badAlg",2:"badRequest",5:"badDataFormat",14:"timeNotAvailable",15:"unacceptedPolicy",16:"unacceptedExtension",17:"addInfoNotAvailable",25:"systemFailure"};this.getResponse=function(z){var I=F(z,0);if(1==I.length)return this.getPKIStatusInfo(E(z,I[0]));if(I.length>1){var C=this.getPKIStatusInfo(E(z,I[0])),B=E(z,I[1]),R=this.getToken(B);return R.statusinfo=C,R}},this.getToken=function(z){var C=(new w.asn1.cms.CMSParser).getCMSSignedData(z);return this.setTSTInfo(C),C},this.setTSTInfo=function(z){var I=z.econtent;if("tstinfo"==I.type){var B=this.getTSTInfo(I.content.hex);I.content=B}},this.getTSTInfo=function(z){var I={},C=F(z,0),B=b(z,C[1]);I.policy=vc(B);var R=E(z,C[2]);I.messageImprint=this.getMessageImprint(R);var V=b(z,C[3]);I.serial={hex:V};var L=b(z,C[4]);I.genTime={str:ei(L)};var $=0;if(C.length>5&&"30"==z.substr(C[5],2)){var J=E(z,C[5]);I.accuracy=this.getAccuracy(J),$++}if(C.length>5+$&&"01"==z.substr(C[5+$],2)&&("ff"==b(z,C[5+$])&&(I.ordering=!0),$++),C.length>5+$&&"02"==z.substr(C[5+$],2)){var te=b(z,C[5+$]);I.nonce={hex:te},$++}if(C.length>5+$&&"a0"==z.substr(C[5+$],2)){var Se=E(z,C[5+$]);Se="30"+Se.substr(2),pGeneralNames=f.getGeneralNames(Se);var Ae=pGeneralNames[0].dn;I.tsa=Ae,$++}if(C.length>5+$&&"a1"==z.substr(C[5+$],2)){var j=E(z,C[5+$]);j="30"+j.substr(2);var q=f.getExtParamArray(j);I.ext=q,$++}return I},this.getAccuracy=function(z){for(var I={},C=F(z,0),B=0;B1&&"30"==z.substr(C[1],2)){var L=E(z,C[1]);I.statusstr=this.getPKIFreeText(L),B++}if(C.length>B&&"03"==z.substr(C[1+B],2)){var $=E(z,C[1+B]);I.failinfo=this.getPKIFailureInfo($)}return I},this.getPKIFreeText=function(z){for(var I=[],C=F(z,0),B=0;B"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),(typeof w.asn1.cades>"u"||!w.asn1.cades)&&(w.asn1.cades={}),w.asn1.cades.SignaturePolicyIdentifier=function(l){var _=w.asn1.cades,b=_.SignaturePolicyId;_.SignaturePolicyIdentifier.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.15",this.params=null,this.getValueArray=function(){return[new b(this.params)]},this.setByParam=function(E){this.params=E},null!=l&&this.setByParam(l)},He(w.asn1.cades.SignaturePolicyIdentifier,w.asn1.cms.Attribute),w.asn1.cades.SignaturePolicyId=function(l){var f=w.asn1,_=f.DERSequence,b=f.DERObjectIdentifier,D=f.cades,P=D.OtherHashAlgAndValue;D.SignaturePolicyId.superclass.constructor.call(this),this.params=null,this.tohex=function(){var U=this.params,z=[];return z.push(new b(U.oid)),z.push(new P(U)),new _({array:z}).tohex()},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(U){this.params=U},null!=l&&this.setByParam(l)},He(w.asn1.cades.SignaturePolicyId,w.asn1.ASN1Object),w.asn1.cades.OtherHashAlgAndValue=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.DEROctetString,D=_.x509.AlgorithmIdentifier;_.cades.OtherHashAlgAndValue.superclass.constructor.call(this),this.params=null,this.tohex=function(){var U=this.params;if(null==U.alg)throw new h("property 'alg' not specified");if(null==U.hash&&null==U.cert)throw new h("property 'hash' nor 'cert' not specified");var z=null;if(null!=U.hash)z=U.hash;else if(null!=U.cert){if("string"!=typeof U.cert)throw new h("cert not string");var I=U.cert;-1!=U.cert.indexOf("-----BEGIN")&&(I=ir(U.cert)),z=w.crypto.Util.hashHex(I,U.alg)}var C=[];return C.push(new D({name:U.alg})),C.push(new E({hex:z})),new b({array:C}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.cades.OtherHashAlgAndValue,w.asn1.ASN1Object),w.asn1.cades.OtherHashValue=function(l){w.asn1.cades.OtherHashValue.superclass.constructor.call(this);var h=Error,E=w.asn1.DEROctetString;this.params=null,this.tohex=function(){var D=this.params;if(null==D.hash&&null==D.cert)throw new h("hash or cert not specified");var F=null;if(null!=D.hash)F=D.hash;else if(null!=D.cert){if("string"!=typeof D.cert)throw new h("cert not string");var P=D.cert;-1!=D.cert.indexOf("-----BEGIN")&&(P=ir(D.cert)),F=w.crypto.Util.hashHex(P,"sha1")}return new E({hex:F}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.cades.OtherHashValue,w.asn1.ASN1Object),w.asn1.cades.SignatureTimeStamp=function(l){var h=Error,_=w.lang.String.isHex,b=w.asn1,E=b.ASN1Object;b.cades.SignatureTimeStamp.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.14",this.params=null,this.getValueArray=function(){var F=this.params;if(null!=F.tst){if(_(F.tst))return(P=new E).hTLV=F.tst,[P];if(F.tst instanceof E)return[F.tst];throw new h("params.tst has wrong value")}if(null!=F.res){var P,U=F.res;if(U instanceof E&&(U=U.tohex()),"string"!=typeof U||!_(U))throw new h("params.res has wrong value");return rt.getTLVbyList(U,0,[1]),(P=new E).hTLV=F.tst,[P]}},null!=l&&this.setByParam(l)},He(w.asn1.cades.SignatureTimeStamp,w.asn1.cms.Attribute),w.asn1.cades.CompleteCertificateRefs=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.cades,M=E.OtherCertID,D=w.lang.String.isHex;E.CompleteCertificateRefs.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.21",this.params=null,this.getValueArray=function(){for(var F=this.params,P=[],U=0;U"u"||!w.asn1.csr)&&(w.asn1.csr={}),w.asn1.csr.CertificationRequest=function(l){var f=w.asn1,_=f.DERBitString,b=f.DERSequence,E=f.csr,D=E.CertificationRequestInfo;E.CertificationRequest.superclass.constructor.call(this),this.setByParam=function(F){this.params=F},this.sign=function(){var F=new D(this.params).tohex(),P=new w.crypto.Signature({alg:this.params.sigalg});P.init(this.params.sbjprvkey),P.updateHex(F);var U=P.sign();this.params.sighex=U},this.getPEM=function(){return Fr(this.tohex(),"CERTIFICATE REQUEST")},this.tohex=function(){var F=this.params,P=new w.asn1.csr.CertificationRequestInfo(this.params),U=new w.asn1.x509.AlgorithmIdentifier({name:F.sigalg});if(null==F.sighex&&null!=F.sbjprvkey&&this.sign(),null==F.sighex)throw new Error("sighex or sbjprvkey parameter not defined");var z=new _({hex:"00"+F.sighex});return new b({array:[P,U,z]}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.csr.CertificationRequest,w.asn1.ASN1Object),w.asn1.csr.CertificationRequestInfo=function(l){var f=w.asn1,b=f.DERSequence,E=f.DERInteger,M=f.DERUTF8String,D=f.DERTaggedObject,F=f.ASN1Util.newObject,U=f.x509,z=U.X500Name,I=U.Extensions,C=U.SubjectPublicKeyInfo;f.csr.CertificationRequestInfo.superclass.constructor.call(this),this.params=null,this.setByParam=function(V){null!=V&&(this.params=V)},this.tohex=function(){var V=this.params,L=[];if(L.push(new E({int:0})),L.push(new z(V.subject)),L.push(new C(Zt.getKey(V.sbjpubkey))),null!=V.attrs){var $=function R(V){for(var L=Error,$=w.asn1.x509.Extensions,J=[],Q=0;Q"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),(typeof w.asn1.ocsp>"u"||!w.asn1.ocsp)&&(w.asn1.ocsp={}),w.asn1.ocsp.DEFAULT_HASH="sha1",w.asn1.ocsp.OCSPResponse=function(l){w.asn1.ocsp.OCSPResponse.superclass.constructor.call(this);var f=w.asn1.ASN1Util.newObject,_=w.asn1.ocsp.ResponseBytes,b=["successful","malformedRequest","internalError","tryLater","_not_used_","sigRequired","unauthorized"];this.params=null,this._getStatusCode=function(){var E=this.params.resstatus;return"number"==typeof E?E:"string"!=typeof E?-1:b.indexOf(E)},this.setByParam=function(E){this.params=E},this.tohex=function(){var E=this.params,M=this._getStatusCode();if(-1==M)throw new Error("responseStatus not supported: "+E.resstatus);if(0!=M)return f({seq:[{enum:{int:M}}]}).tohex();var D=new _(E);return f({seq:[{enum:{int:0}},{tag:{tag:"a0",explicit:!0,obj:D}}]}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.ocsp.OCSPResponse,w.asn1.ASN1Object),w.asn1.ocsp.ResponseBytes=function(l){w.asn1.ocsp.ResponseBytes.superclass.constructor.call(this);var h=w.asn1,f=h.DERSequence,_=h.DERObjectIdentifier,b=h.DEROctetString,E=h.ocsp.BasicOCSPResponse;this.params=null,this.setByParam=function(M){this.params=M},this.tohex=function(){var M=this.params;if("ocspBasic"!=M.restype)throw new Error("not supported responseType: "+M.restype);var D=new E(M),F=[];return F.push(new _({name:"ocspBasic"})),F.push(new b({hex:D.tohex()})),new f({array:F}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.ocsp.ResponseBytes,w.asn1.ASN1Object),w.asn1.ocsp.BasicOCSPResponse=function(l){w.asn1.ocsp.BasicOCSPResponse.superclass.constructor.call(this);var h=Error,f=w.asn1,_=f.ASN1Object,b=f.DERSequence,M=f.DERTaggedObject,D=f.DERBitString,P=f.x509.AlgorithmIdentifier,U=f.ocsp;_SingleResponseList=U.SingleResponseList,_ResponseData=U.ResponseData,this.params=null,this.setByParam=function(I){this.params=I},this.sign=function(){var I=this.params,C=I.tbsresp.tohex(),B=new w.crypto.Signature({alg:I.sigalg});B.init(I.reskey),B.updateHex(C),I.sighex=B.sign()},this.tohex=function(){var I=this.params;null==I.tbsresp&&(I.tbsresp=new _ResponseData(I)),null==I.sighex&&null!=I.reskey&&this.sign();var C=[];if(C.push(I.tbsresp),C.push(new P({name:I.sigalg})),C.push(new D({hex:"00"+I.sighex})),null!=I.certs&&null!=I.certs.length){for(var B=[],R=0;R"u"||!w)&&(w={}),(typeof w.lang>"u"||!w.lang)&&(w.lang={}),w.lang.String=function(){},"function"==typeof Buffer?(Il=function(l){return Qr(Buffer.from(l,"utf8").toString("base64"))},mo=function(l){return Buffer.from(ma(l),"base64").toString("utf8")}):(Il=function(l){return Er(_o(Fe(l)))},mo=function(l){return decodeURIComponent(Xh(nn(l)))}),w.lang.String.isInteger=function(l){return!!l.match(/^[0-9]+$/)||!!l.match(/^-[0-9]+$/)},w.lang.String.isHex=function(l){return qn(l)},w.lang.String.isBase64=function(l){return!(!(l=l.replace(/\s+/g,"")).match(/^[0-9A-Za-z+\/]+={0,3}$/)||l.length%4!=0)},w.lang.String.isBase64URL=function(l){return!l.match(/[+/=]/)&&(l=ma(l),w.lang.String.isBase64(l))},w.lang.String.isIntegerArray=function(l){return!!(l=l.replace(/\s+/g,"")).match(/^\[[0-9,]+\]$/)},w.lang.String.isPrintable=function(l){return null!==l.match(/^[0-9A-Za-z '()+,-./:=?]*$/)},w.lang.String.isIA5=function(l){return null!==l.match(/^[\x20-\x21\x23-\x7f]*$/)},w.lang.String.isMail=function(l){return null!==l.match(/^[A-Za-z0-9]{1}[A-Za-z0-9_.-]*@{1}[A-Za-z0-9_.-]{1,}\.[A-Za-z0-9]{1,}$/)};var gd=function(l,h,f){return null==f&&(f="0"),l.length>=h?l:new Array(h-l.length+1).join(f)+l};function vd(l,h){for(var f=0,_=0;_=0;_--)E+=b[_];return E}function He(l,h){var f=function(){};f.prototype=h.prototype,l.prototype=new f,l.prototype.constructor=l,l.superclass=h.prototype,h.prototype.constructor==Object.prototype.constructor&&(h.prototype.constructor=h)}(typeof w>"u"||!w)&&(w={}),(typeof w.crypto>"u"||!w.crypto)&&(w.crypto={}),w.crypto.Util=new function(){this.DIGESTINFOHEAD={sha1:"3021300906052b0e03021a05000414",sha224:"302d300d06096086480165030402040500041c",sha256:"3031300d060960864801650304020105000420",sha384:"3041300d060960864801650304020205000430",sha512:"3051300d060960864801650304020305000440",md2:"3020300c06082a864886f70d020205000410",md5:"3020300c06082a864886f70d020505000410",ripemd160:"3021300906052b2403020105000414"},this.DEFAULTPROVIDER={md5:"cryptojs",sha1:"cryptojs",sha224:"cryptojs",sha256:"cryptojs",sha384:"cryptojs",sha512:"cryptojs",ripemd160:"cryptojs",hmacmd5:"cryptojs",hmacsha1:"cryptojs",hmacsha224:"cryptojs",hmacsha256:"cryptojs",hmacsha384:"cryptojs",hmacsha512:"cryptojs",hmacripemd160:"cryptojs",MD5withRSA:"cryptojs/jsrsa",SHA1withRSA:"cryptojs/jsrsa",SHA224withRSA:"cryptojs/jsrsa",SHA256withRSA:"cryptojs/jsrsa",SHA384withRSA:"cryptojs/jsrsa",SHA512withRSA:"cryptojs/jsrsa",RIPEMD160withRSA:"cryptojs/jsrsa",MD5withECDSA:"cryptojs/jsrsa",SHA1withECDSA:"cryptojs/jsrsa",SHA224withECDSA:"cryptojs/jsrsa",SHA256withECDSA:"cryptojs/jsrsa",SHA384withECDSA:"cryptojs/jsrsa",SHA512withECDSA:"cryptojs/jsrsa",RIPEMD160withECDSA:"cryptojs/jsrsa",SHA1withDSA:"cryptojs/jsrsa",SHA224withDSA:"cryptojs/jsrsa",SHA256withDSA:"cryptojs/jsrsa",MD5withRSAandMGF1:"cryptojs/jsrsa",SHAwithRSAandMGF1:"cryptojs/jsrsa",SHA1withRSAandMGF1:"cryptojs/jsrsa",SHA224withRSAandMGF1:"cryptojs/jsrsa",SHA256withRSAandMGF1:"cryptojs/jsrsa",SHA384withRSAandMGF1:"cryptojs/jsrsa",SHA512withRSAandMGF1:"cryptojs/jsrsa",RIPEMD160withRSAandMGF1:"cryptojs/jsrsa"},this.CRYPTOJSMESSAGEDIGESTNAME={md5:pt.algo.MD5,sha1:pt.algo.SHA1,sha224:pt.algo.SHA224,sha256:pt.algo.SHA256,sha384:pt.algo.SHA384,sha512:pt.algo.SHA512,ripemd160:pt.algo.RIPEMD160},this.getDigestInfoHex=function(l,h){if(typeof this.DIGESTINFOHEAD[h]>"u")throw"alg not supported in Util.DIGESTINFOHEAD: "+h;return this.DIGESTINFOHEAD[h]+l},this.getPaddedDigestInfoHex=function(l,h,f){var _=this.getDigestInfoHex(l,h),b=f/4;if(_.length+22>b)throw"key is too short for SigAlg: keylen="+f+","+h;for(var E="0001",M="00"+_,D="",F=b-E.length-M.length,P=0;P"u"||!w)&&(w={}),(typeof w.crypto>"u"||!w.crypto)&&(w.crypto={}),w.crypto.ECDSA=function(l){var E=Error,M=_e,D=Mt,F=w.crypto.ECDSA,P=w.crypto.ECParameterDB,U=F.getName,I=rt.getVbyListEx,C=rt.isASN1HEX,B=new Ao;this.type="EC",this.isPrivate=!1,this.isPublic=!1,this.getBigRandom=function(L){return new M(L.bitLength(),B).mod(L.subtract(M.ONE)).add(M.ONE)},this.setNamedCurve=function(L){this.ecparams=P.getByName(L),this.prvKeyHex=null,this.pubKeyHex=null,this.curveName=L},this.setPrivateKeyHex=function(L){this.isPrivate=!0,this.prvKeyHex=L},this.setPublicKeyHex=function(L){this.isPublic=!0,this.pubKeyHex=L},this.getPublicKeyXYHex=function(){var L=this.pubKeyHex;if("04"!==L.substr(0,2))throw"this method supports uncompressed format(04) only";var $=this.ecparams.keycharlen;if(L.length!==2+2*$)throw"malformed public key hex length";var J={};return J.x=L.substr(2,$),J.y=L.substr(2+$),J},this.getShortNISTPCurveName=function(){var L=this.curveName;return"secp256r1"===L||"NIST P-256"===L||"P-256"===L||"prime256v1"===L?"P-256":"secp384r1"===L||"NIST P-384"===L||"P-384"===L?"P-384":"secp521r1"===L||"NIST P-521"===L||"P-521"===L?"P-521":null},this.generateKeyPairHex=function(){var $=this.getBigRandom(this.ecparams.n),J=this.ecparams.keycharlen,Q=("0000000000"+$.toString(16)).slice(-J);return this.setPrivateKeyHex(Q),{ecprvhex:Q,ecpubhex:this.generatePublicKeyHex()}},this.generatePublicKeyHex=function(){var L=new M(this.prvKeyHex,16),$=this.ecparams.G.multiply(L),J=$.getX().toBigInteger(),Q=$.getY().toBigInteger(),te=this.ecparams.keycharlen,j="04"+("0000000000"+J.toString(16)).slice(-te)+("0000000000"+Q.toString(16)).slice(-te);return this.setPublicKeyHex(j),j},this.signWithMessageHash=function(L){return this.signHex(L,this.prvKeyHex)},this.signHex=function(L,$){var J=new M($,16),Q=this.ecparams.n,te=new M(L.substring(0,this.ecparams.keycharlen),16);do{var Se=this.getBigRandom(Q),q=this.ecparams.G.multiply(Se).getX().toBigInteger().mod(Q)}while(q.compareTo(M.ZERO)<=0);var ee=Se.modInverse(Q).multiply(te.add(J.multiply(q))).mod(Q);return F.biRSSigToASN1Sig(q,ee)},this.sign=function(L,$){var J=$,Q=this.ecparams.n,te=M.fromByteArrayUnsigned(L);do{var Se=this.getBigRandom(Q),q=this.ecparams.G.multiply(Se).getX().toBigInteger().mod(Q)}while(q.compareTo(_e.ZERO)<=0);var ee=Se.modInverse(Q).multiply(te.add(J.multiply(q))).mod(Q);return this.serializeSig(q,ee)},this.verifyWithMessageHash=function(L,$){return this.verifyHex(L,$,this.pubKeyHex)},this.verifyHex=function(L,$,J){try{var Q,te,Se=F.parseSigHex($);Q=Se.r,te=Se.s;var Ae=D.decodeFromHex(this.ecparams.curve,J),j=new M(L.substring(0,this.ecparams.keycharlen),16);return this.verifyRaw(j,Q,te,Ae)}catch{return!1}},this.verify=function(L,$,J){var Q,te,Ae;if(Bitcoin.Util.isArray($)){var Se=this.parseSig($);Q=Se.r,te=Se.s}else{if("object"!=typeof $||!$.r||!$.s)throw"Invalid value for signature";Q=$.r,te=$.s}if(J instanceof Mt)Ae=J;else{if(!Bitcoin.Util.isArray(J))throw"Invalid format for pubkey value, must be byte array or ECPointFp";Ae=D.decodeFrom(this.ecparams.curve,J)}var j=M.fromByteArrayUnsigned(L);return this.verifyRaw(j,Q,te,Ae)},this.verifyRaw=function(L,$,J,Q){var te=this.ecparams.n,Se=this.ecparams.G;if($.compareTo(M.ONE)<0||$.compareTo(te)>=0||J.compareTo(M.ONE)<0||J.compareTo(te)>=0)return!1;var Ae=J.modInverse(te),j=L.multiply(Ae).mod(te),q=$.multiply(Ae).mod(te);return Se.multiply(j).add(Q.multiply(q)).getX().toBigInteger().mod(te).equals($)},this.serializeSig=function(L,$){var J=L.toByteArraySigned(),Q=$.toByteArraySigned(),te=[];return te.push(2),te.push(J.length),(te=te.concat(J)).push(2),te.push(Q.length),(te=te.concat(Q)).unshift(te.length),te.unshift(48),te},this.parseSig=function(L){var $;if(48!=L[0])throw new Error("Signature not a valid DERSequence");if(2!=L[$=2])throw new Error("First element in signature must be a DERInteger");var J=L.slice($+2,$+2+L[$+1]);if(2!=L[$+=2+L[$+1]])throw new Error("Second element in signature must be a DERInteger");var Q=L.slice($+2,$+2+L[$+1]);return $+=2+L[$+1],{r:M.fromByteArrayUnsigned(J),s:M.fromByteArrayUnsigned(Q)}},this.parseSigCompact=function(L){if(65!==L.length)throw"Signature has the wrong length";var $=L[0]-27;if($<0||$>7)throw"Invalid signature type";var J=this.ecparams.n;return{r:M.fromByteArrayUnsigned(L.slice(1,33)).mod(J),s:M.fromByteArrayUnsigned(L.slice(33,65)).mod(J),i:$}},this.readPKCS5PrvKeyHex=function(L){if(!1===C(L))throw new Error("not ASN.1 hex string");var $,J,Q;try{$=I(L,0,["[0]",0],"06"),J=I(L,0,[1],"04");try{Q=I(L,0,["[1]",0],"03")}catch{}}catch{throw new Error("malformed PKCS#1/5 plain ECC private key")}if(this.curveName=U($),void 0===this.curveName)throw"unsupported curve name";this.setNamedCurve(this.curveName),this.setPublicKeyHex(Q),this.setPrivateKeyHex(J),this.isPublic=!1},this.readPKCS8PrvKeyHex=function(L){if(!1===C(L))throw new E("not ASN.1 hex string");var J,Q,te;try{I(L,0,[1,0],"06"),J=I(L,0,[1,1],"06"),Q=I(L,0,[2,0,1],"04");try{te=I(L,0,[2,0,"[1]",0],"03")}catch{}}catch{throw new E("malformed PKCS#8 plain ECC private key")}if(this.curveName=U(J),void 0===this.curveName)throw new E("unsupported curve name");this.setNamedCurve(this.curveName),this.setPublicKeyHex(te),this.setPrivateKeyHex(Q),this.isPublic=!1},this.readPKCS8PubKeyHex=function(L){if(!1===C(L))throw new E("not ASN.1 hex string");var J,Q;try{I(L,0,[0,0],"06"),J=I(L,0,[0,1],"06"),Q=I(L,0,[1],"03")}catch{throw new E("malformed PKCS#8 ECC public key")}if(this.curveName=U(J),null===this.curveName)throw new E("unsupported curve name");this.setNamedCurve(this.curveName),this.setPublicKeyHex(Q)},this.readCertPubKeyHex=function(L,$){if(!1===C(L))throw new E("not ASN.1 hex string");var J,Q;try{J=I(L,0,[0,5,0,1],"06"),Q=I(L,0,[0,5,1],"03")}catch{throw new E("malformed X.509 certificate ECC public key")}if(this.curveName=U(J),null===this.curveName)throw new E("unsupported curve name");this.setNamedCurve(this.curveName),this.setPublicKeyHex(Q)},void 0!==l&&void 0!==l.curve&&(this.curveName=l.curve),void 0===this.curveName&&(this.curveName="secp256r1"),this.setNamedCurve(this.curveName),void 0!==l&&(void 0!==l.prv&&this.setPrivateKeyHex(l.prv),void 0!==l.pub&&this.setPublicKeyHex(l.pub))},w.crypto.ECDSA.parseSigHex=function(l){var h=w.crypto.ECDSA.parseSigHexInHexRS(l);return{r:new _e(h.r,16),s:new _e(h.s,16)}},w.crypto.ECDSA.parseSigHexInHexRS=function(l){var f=rt.getChildIdx,_=rt.getV;if(rt.checkStrictDER(l,0),"30"!=l.substr(0,2))throw new Error("signature is not a ASN.1 sequence");var b=f(l,0);if(2!=b.length)throw new Error("signature shall have two elements");var E=b[0],M=b[1];if("02"!=l.substr(E,2))throw new Error("1st item not ASN.1 integer");if("02"!=l.substr(M,2))throw new Error("2nd item not ASN.1 integer");return{r:_(l,E),s:_(l,M)}},w.crypto.ECDSA.asn1SigToConcatSig=function(l){var h=w.crypto.ECDSA.parseSigHexInHexRS(l),f=h.r,_=h.s;if(f.length>=130&&f.length<=134){if(f.length%2!=0)throw Error("unknown ECDSA sig r length error");if(_.length%2!=0)throw Error("unknown ECDSA sig s length error");"00"==f.substr(0,2)&&(f=f.substr(2)),"00"==_.substr(0,2)&&(_=_.substr(2));var b=Math.max(f.length,_.length);return(f=("000000"+f).slice(-b))+("000000"+_).slice(-b)}if("00"==f.substr(0,2)&&f.length%32==2&&(f=f.substr(2)),"00"==_.substr(0,2)&&_.length%32==2&&(_=_.substr(2)),f.length%32==30&&(f="00"+f),_.length%32==30&&(_="00"+_),f.length%32!=0)throw Error("unknown ECDSA sig r length error");if(_.length%32!=0)throw Error("unknown ECDSA sig s length error");return f+_},w.crypto.ECDSA.concatSigToASN1Sig=function(l){if(l.length%4!=0)throw Error("unknown ECDSA concatinated r-s sig length error");var h=l.substr(0,l.length/2),f=l.substr(l.length/2);return w.crypto.ECDSA.hexRSSigToASN1Sig(h,f)},w.crypto.ECDSA.hexRSSigToASN1Sig=function(l,h){var f=new _e(l,16),_=new _e(h,16);return w.crypto.ECDSA.biRSSigToASN1Sig(f,_)},w.crypto.ECDSA.biRSSigToASN1Sig=function(l,h){var f=w.asn1,_=new f.DERInteger({bigint:l}),b=new f.DERInteger({bigint:h});return new f.DERSequence({array:[_,b]}).tohex()},w.crypto.ECDSA.getName=function(l){return"2b8104001f"===l?"secp192k1":"2a8648ce3d030107"===l?"secp256r1":"2b8104000a"===l?"secp256k1":"2b81040021"===l?"secp224r1":"2b81040022"===l?"secp384r1":"2b81040023"===l?"secp521r1":-1!=="|secp256r1|NIST P-256|P-256|prime256v1|".indexOf(l)?"secp256r1":-1!=="|secp256k1|".indexOf(l)?"secp256k1":-1!=="|secp224r1|NIST P-224|P-224|".indexOf(l)?"secp224r1":-1!=="|secp384r1|NIST P-384|P-384|".indexOf(l)?"secp384r1":-1!=="|secp521r1|NIST P-521|P-521|".indexOf(l)?"secp521r1":null},(typeof w>"u"||!w)&&(w={}),(typeof w.crypto>"u"||!w.crypto)&&(w.crypto={}),w.crypto.ECParameterDB=new function(){var l={},h={};function f(_){return new _e(_,16)}this.getByName=function(_){var b=_;if(typeof h[b]<"u"&&(b=h[_]),typeof l[b]<"u")return l[b];throw"unregistered EC curve name: "+b},this.regist=function(_,b,E,M,D,F,P,U,z,I,C,B){l[_]={};var R=f(E),V=f(M),L=f(D),$=f(F),J=f(P),Q=new Nr(R,V,L),te=Q.decodePointHex("04"+U+z);l[_].name=_,l[_].keylen=b,l[_].keycharlen=2*Math.ceil(b/8),l[_].curve=Q,l[_].G=te,l[_].n=$,l[_].h=J,l[_].oid=C,l[_].info=B;for(var Se=0;Se"u"||!w)&&(w={}),(typeof w.crypto>"u"||!w.crypto)&&(w.crypto={}),w.crypto.DSA=function(){var f=rt.getVbyListEx,_=rt.isASN1HEX,b=_e;this.p=null,this.q=null,this.g=null,this.y=null,this.x=null,this.type="DSA",this.isPrivate=!1,this.isPublic=!1,this.setPrivate=function(E,M,D,F,P){this.isPrivate=!0,this.p=E,this.q=M,this.g=D,this.y=F,this.x=P},this.setPrivateHex=function(E,M,D,F,P){var U,z,I,C,B;U=new _e(E,16),z=new _e(M,16),I=new _e(D,16),C="string"==typeof F&&F.length>1?new _e(F,16):null,B=new _e(P,16),this.setPrivate(U,z,I,C,B)},this.setPublic=function(E,M,D,F){this.isPublic=!0,this.p=E,this.q=M,this.g=D,this.y=F,this.x=null},this.setPublicHex=function(E,M,D,F){var P,U,z,I;P=new _e(E,16),U=new _e(M,16),z=new _e(D,16),I=new _e(F,16),this.setPublic(P,U,z,I)},this.signWithMessageHash=function(E){var M=this.p,D=this.q,F=this.g,U=this.x,z=w.crypto.Util.getRandomBigIntegerMinToMax(_e.ONE.add(_e.ONE),D.subtract(_e.ONE)),C=new _e(E.substr(0,D.bitLength()/4),16),B=F.modPow(z,M).mod(D),R=z.modInverse(D).multiply(C.add(U.multiply(B))).mod(D);return w.asn1.ASN1Util.jsonToASN1HEX({seq:[{int:{bigint:B}},{int:{bigint:R}}]})},this.verifyWithMessageHash=function(E,M){var D=this.p,F=this.q,P=this.g,U=this.y,z=this.parseASN1Signature(M),I=z[0],C=z[1],R=new _e(E.substr(0,F.bitLength()/4),16);if(_e.ZERO.compareTo(I)>0||I.compareTo(F)>0||_e.ZERO.compareTo(C)>=0||C.compareTo(F)>0)throw"invalid DSA signature";var V=C.modInverse(F),L=R.multiply(V).mod(F),$=I.multiply(V).mod(F);return 0==P.modPow(L,D).multiply(U.modPow($,D)).mod(D).mod(F).compareTo(I)},this.parseASN1Signature=function(E){try{return[new b(f(E,0,[0],"02"),16),new b(f(E,0,[1],"02"),16)]}catch{throw new Error("malformed ASN.1 DSA signature")}},this.readPKCS5PrvKeyHex=function(E){var M,D,F,P,U;if(!1===_(E))throw new Error("not ASN.1 hex string");try{M=f(E,0,[1],"02"),D=f(E,0,[2],"02"),F=f(E,0,[3],"02"),P=f(E,0,[4],"02"),U=f(E,0,[5],"02")}catch{throw new Error("malformed PKCS#1/5 plain DSA private key")}this.setPrivateHex(M,D,F,P,U)},this.readPKCS8PrvKeyHex=function(E){var M,D,F,P;if(!1===_(E))throw new Error("not ASN.1 hex string");try{M=f(E,0,[1,1,0],"02"),D=f(E,0,[1,1,1],"02"),F=f(E,0,[1,1,2],"02"),P=f(E,0,[2,0],"02")}catch{throw new Error("malformed PKCS#8 plain DSA private key")}this.setPrivateHex(M,D,F,null,P)},this.readPKCS8PubKeyHex=function(E){var M,D,F,P;if(!1===_(E))throw new Error("not ASN.1 hex string");try{M=f(E,0,[0,1,0],"02"),D=f(E,0,[0,1,1],"02"),F=f(E,0,[0,1,2],"02"),P=f(E,0,[1,0],"02")}catch{throw new Error("malformed PKCS#8 DSA public key")}this.setPublicHex(M,D,F,P)},this.readCertPubKeyHex=function(E,M){var D,F,P,U;if(!1===_(E))throw new Error("not ASN.1 hex string");try{D=f(E,0,[0,5,0,1,0],"02"),F=f(E,0,[0,5,0,1,1],"02"),P=f(E,0,[0,5,0,1,2],"02"),U=f(E,0,[0,5,1,0],"02")}catch{throw new Error("malformed X.509 certificate DSA public key")}this.setPublicHex(D,F,P,U)}};var Zt=function(){var l=function(R,V,L){return _(pt.AES,R,V,L)},_=function(R,V,L,$){var J=pt.enc.Hex.parse(V),Q=pt.enc.Hex.parse(L),te=pt.enc.Hex.parse($),Se={};Se.key=Q,Se.iv=te,Se.ciphertext=J;var Ae=R.decrypt(Se,Q,{iv:te});return pt.enc.Hex.stringify(Ae)},b=function(R,V,L){return D(pt.AES,R,V,L)},D=function(R,V,L,$){var J=pt.enc.Hex.parse(V),Q=pt.enc.Hex.parse(L),te=pt.enc.Hex.parse($),Se=R.encrypt(J,Q,{iv:te}),Ae=pt.enc.Hex.parse(Se.toString());return pt.enc.Base64.stringify(Ae)},F={"AES-256-CBC":{proc:l,eproc:b,keylen:32,ivlen:16},"AES-192-CBC":{proc:l,eproc:b,keylen:24,ivlen:16},"AES-128-CBC":{proc:l,eproc:b,keylen:16,ivlen:16},"DES-EDE3-CBC":{proc:function(R,V,L){return _(pt.TripleDES,R,V,L)},eproc:function(R,V,L){return D(pt.TripleDES,R,V,L)},keylen:24,ivlen:8},"DES-CBC":{proc:function(R,V,L){return _(pt.DES,R,V,L)},eproc:function(R,V,L){return D(pt.DES,R,V,L)},keylen:8,ivlen:8}},z=function(R){var V={},L=R.match(new RegExp("DEK-Info: ([^,]+),([0-9A-Fa-f]+)","m"));L&&(V.cipher=L[1],V.ivsalt=L[2]);var $=R.match(new RegExp("-----BEGIN ([A-Z]+) PRIVATE KEY-----"));$&&(V.type=$[1]);var J=-1,Q=0;-1!=R.indexOf("\r\n\r\n")&&(J=R.indexOf("\r\n\r\n"),Q=2),-1!=R.indexOf("\n\n")&&(J=R.indexOf("\n\n"),Q=1);var te=R.indexOf("-----END");if(-1!=J&&-1!=te){var Se=R.substring(J+2*Q,te-Q);Se=Se.replace(/\s+/g,""),V.data=Se}return V},I=function(R,V,L){for(var $=L.substring(0,16),J=pt.enc.Hex.parse($),Q=pt.enc.Utf8.parse(V),te=F[R].keylen+F[R].ivlen,Se="",Ae=null;;){var j=pt.algo.MD5.create();if(null!=Ae&&j.update(Ae),j.update(Q),j.update(J),Ae=j.finalize(),(Se+=pt.enc.Hex.stringify(Ae)).length>=2*te)break}var q={};return q.keyhex=Se.substr(0,2*F[R].keylen),q.ivhex=Se.substr(2*F[R].keylen,2*F[R].ivlen),q},C=function(R,V,L,$){var J=pt.enc.Base64.parse(R),Q=pt.enc.Hex.stringify(J);return(0,F[V].proc)(Q,L,$)};return{version:"1.0.0",parsePKCS5PEM:function(R){return z(R)},getKeyAndUnusedIvByPasscodeAndIvsalt:function(R,V,L){return I(R,V,L)},decryptKeyB64:function(R,V,L,$){return C(R,V,L,$)},getDecryptedKeyHex:function(R,V){var L=z(R),J=L.cipher,Q=L.ivsalt,te=L.data,Se=I(J,V,Q);return C(te,J,Se.keyhex,Q)},getEncryptedPKCS5PEMFromPrvKeyHex:function(R,V,L,$,J){var ee="";if((typeof $>"u"||null==$)&&($="AES-256-CBC"),typeof F[$]>"u")throw new Error("KEYUTIL unsupported algorithm: "+$);if(typeof J>"u"||null==J){var te=function(R){var V=pt.lib.WordArray.random(R);return pt.enc.Hex.stringify(V)}(F[$].ivlen);J=te.toUpperCase()}var j=function(R,V,L,$){return(0,F[V].eproc)(R,L,$)}(V,$,I($,L,J).keyhex,J);return ee="-----BEGIN "+R+" PRIVATE KEY-----\r\n",ee+="Proc-Type: 4,ENCRYPTED\r\n",ee+="DEK-Info: "+$+","+J+"\r\n",ee+="\r\n",(ee+=j.replace(/(.{64})/g,"$1\r\n"))+"\r\n-----END "+R+" PRIVATE KEY-----\r\n"},parseHexOfEncryptedPKCS8:function(R){var L=rt.getChildIdx,$=rt.getV,J={},Q=L(R,0);if(2!=Q.length)throw new Error("malformed format: SEQUENCE(0).items != 2: "+Q.length);J.ciphertext=$(R,Q[1]);var te=L(R,Q[0]);if(2!=te.length)throw new Error("malformed format: SEQUENCE(0.0).items != 2: "+te.length);if("2a864886f70d01050d"!=$(R,te[0]))throw new Error("this only supports pkcs5PBES2");var Se=L(R,te[1]);if(2!=te.length)throw new Error("malformed format: SEQUENCE(0.0.1).items != 2: "+Se.length);var Ae=L(R,Se[1]);if(2!=Ae.length)throw new Error("malformed format: SEQUENCE(0.0.1.1).items != 2: "+Ae.length);if("2a864886f70d0307"!=$(R,Ae[0]))throw"this only supports TripleDES";J.encryptionSchemeAlg="TripleDES",J.encryptionSchemeIV=$(R,Ae[1]);var j=L(R,Se[0]);if(2!=j.length)throw new Error("malformed format: SEQUENCE(0.0.1.0).items != 2: "+j.length);if("2a864886f70d01050c"!=$(R,j[0]))throw new Error("this only supports pkcs5PBKDF2");var q=L(R,j[1]);if(q.length<2)throw new Error("malformed format: SEQUENCE(0.0.1.0.1).items < 2: "+q.length);J.pbkdf2Salt=$(R,q[0]);var ee=$(R,q[1]);try{J.pbkdf2Iter=parseInt(ee,16)}catch{throw new Error("malformed format pbkdf2Iter: "+ee)}return J},getPBKDF2KeyHexFromParam:function(R,V){var L=pt.enc.Hex.parse(R.pbkdf2Salt),J=pt.PBKDF2(V,L,{keySize:6,iterations:R.pbkdf2Iter});return pt.enc.Hex.stringify(J)},_getPlainPKCS8HexFromEncryptedPKCS8PEM:function(R,V){var L=ir(R,"ENCRYPTED PRIVATE KEY"),$=this.parseHexOfEncryptedPKCS8(L),J=Zt.getPBKDF2KeyHexFromParam($,V),Q={};Q.ciphertext=pt.enc.Hex.parse($.ciphertext);var te=pt.enc.Hex.parse(J),Se=pt.enc.Hex.parse($.encryptionSchemeIV),Ae=pt.TripleDES.decrypt(Q,te,{iv:Se});return pt.enc.Hex.stringify(Ae)},getKeyFromEncryptedPKCS8PEM:function(R,V){var L=this._getPlainPKCS8HexFromEncryptedPKCS8PEM(R,V);return this.getKeyFromPlainPrivatePKCS8Hex(L)},parsePlainPrivatePKCS8Hex:function(R){var V=rt,L=V.getChildIdx,$=V.getV,J={algparam:null};if("30"!=R.substr(0,2))throw new Error("malformed plain PKCS8 private key(code:001)");var Q=L(R,0);if(Q.length<3)throw new Error("malformed plain PKCS8 private key(code:002)");if("30"!=R.substr(Q[1],2))throw new Error("malformed PKCS8 private key(code:003)");var te=L(R,Q[1]);if(2!=te.length)throw new Error("malformed PKCS8 private key(code:004)");if("06"!=R.substr(te[0],2))throw new Error("malformed PKCS8 private key(code:005)");if(J.algoid=$(R,te[0]),"06"==R.substr(te[1],2)&&(J.algparam=$(R,te[1])),"04"!=R.substr(Q[2],2))throw new Error("malformed PKCS8 private key(code:006)");return J.keyidx=V.getVidx(R,Q[2]),J},getKeyFromPlainPrivatePKCS8PEM:function(R){var V=ir(R,"PRIVATE KEY");return this.getKeyFromPlainPrivatePKCS8Hex(V)},getKeyFromPlainPrivatePKCS8Hex:function(R){var L,V=this.parsePlainPrivatePKCS8Hex(R);if("2a864886f70d010101"==V.algoid)L=new Ut;else if("2a8648ce380401"==V.algoid)L=new w.crypto.DSA;else{if("2a8648ce3d0201"!=V.algoid)throw new Error("unsupported private key algorithm");L=new w.crypto.ECDSA}return L.readPKCS8PrvKeyHex(R),L},_getKeyFromPublicPKCS8Hex:function(R){var V,L=rt.getVbyList(R,0,[0,0],"06");if("2a864886f70d010101"===L)V=new Ut;else if("2a8648ce380401"===L)V=new w.crypto.DSA;else{if("2a8648ce3d0201"!==L)throw new Error("unsupported PKCS#8 public key hex");V=new w.crypto.ECDSA}return V.readPKCS8PubKeyHex(R),V},parsePublicRawRSAKeyHex:function(R){var L=rt.getChildIdx,$=rt.getV,J={};if("30"!=R.substr(0,2))throw new Error("malformed RSA key(code:001)");var Q=L(R,0);if(2!=Q.length)throw new Error("malformed RSA key(code:002)");if("02"!=R.substr(Q[0],2))throw new Error("malformed RSA key(code:003)");if(J.n=$(R,Q[0]),"02"!=R.substr(Q[1],2))throw new Error("malformed RSA key(code:004)");return J.e=$(R,Q[1]),J},parsePublicPKCS8Hex:function(R){var V=rt,L=V.getChildIdx,$=V.getV,J={algparam:null},Q=L(R,0);if(2!=Q.length)throw new Error("outer DERSequence shall have 2 elements: "+Q.length);var te=Q[0];if("30"!=R.substr(te,2))throw new Error("malformed PKCS8 public key(code:001)");var Se=L(R,te);if(2!=Se.length)throw new Error("malformed PKCS8 public key(code:002)");if("06"!=R.substr(Se[0],2))throw new Error("malformed PKCS8 public key(code:003)");if(J.algoid=$(R,Se[0]),"06"==R.substr(Se[1],2)?J.algparam=$(R,Se[1]):"30"==R.substr(Se[1],2)&&(J.algparam={},J.algparam.p=V.getVbyList(R,Se[1],[0],"02"),J.algparam.q=V.getVbyList(R,Se[1],[1],"02"),J.algparam.g=V.getVbyList(R,Se[1],[2],"02")),"03"!=R.substr(Q[1],2))throw new Error("malformed PKCS8 public key(code:004)");return J.key=$(R,Q[1]).substr(2),J}}}();function Xs(l,h){for(var f="",_=h/4-l.length,b=0;b<_;b++)f+="0";return f+l}function yd(l,h,f){for(var _="",b=0;_.length>24,(16711680&b)>>16,(65280&b)>>8,255&b])))),b+=1;return _}function Os(l){for(var h in w.crypto.Util.DIGESTINFOHEAD){var f=w.crypto.Util.DIGESTINFOHEAD[h],_=f.length;if(l.substring(0,_)==f)return[h,l.substring(_)]}return[]}function rn(l){var J,h=rt,f=h.getChildIdx,_=h.getV,E=h.parse,M=h.getTLV,D=h.getVbyList,F=h.getVbyListEx,P=h.getTLVbyList,U=h.getTLVbyListEx,z=h.getIdxbyList,I=h.getIdxbyListEx,C=h.getVidx,B=h.getInt,R=h.oidname,V=h.hextooidstr,$=ir,Q=Error;try{J=w.asn1.x509.AlgorithmIdentifier.PSSNAME2ASN1TLV}catch{}this.HEX2STAG={"0c":"utf8",13:"prn",16:"ia5","1a":"vis","1e":"bmp"},this.hex=null,this.version=0,this.foffset=0,this.aExtInfo=null,this.getVersion=function(){if(null===this.hex||0!==this.version)return this.version;var j=P(this.hex,0,[0,0]);if("a0"==j.substr(0,2)){var q=P(j,0,[0]),ee=B(q,0);if(ee<0||21){var be=M(j,ue[1]),ce=this.getGeneralName(be);null!=ce.uri&&(re.uri=ce.uri)}if(ue.length>2){var pe=M(j,ue[2]);"0101ff"==pe&&(re.reqauth=!0),"010100"==pe&&(re.reqauth=!1)}return re};var te=function(j){var q={};try{var re=w.asn1.x509.OID.name2oid(j.seq[0].oid);q.type=w.asn1.x509.OID.oid2atype(re);var ue=j.seq[1];if(null!=ue.utf8str)q.ds="utf8",q.value=ue.utf8str.str;else if(null!=ue.numstr)q.ds="num",q.value=ue.numstr.str;else if(null!=ue.telstr)q.ds="tel",q.value=ue.telstr.str;else if(null!=ue.prnstr)q.ds="prn",q.value=ue.prnstr.str;else if(null!=ue.ia5str)q.ds="ia5",q.value=ue.ia5str.str;else if(null!=ue.visstr)q.ds="vis",q.value=ue.visstr.str;else{if(null==ue.bmpstr)throw"error";q.ds="bmp",q.value=ue.bmpstr.str}return q}catch{throw new Erorr("improper ASN.1 parsed AttrTypeAndValue")}},Se=function(j){try{return j.set.map(function(q){return te(q)})}catch(q){throw new Error("improper ASN.1 parsed RDN: "+q)}};this.getX500NameRule=function(j){for(var ce=null,pe=[],ve=0;ve0&&(q.ext=this.getExtParamArray()),q.sighex=this.getSignatureValueHex(),1==j.tbshex&&(q.tbshex=P(this.hex,0,[0])),1==j.nodnarray&&(delete q.issuer.array,delete q.subject.array),q},this.getExtParamArray=function(j){null==j&&-1!=I(this.hex,0,[0,"[3]"])&&(j=U(this.hex,0,[0,"[3]",0],"30"));for(var ee=[],re=f(j,0),ue=0;ue2&&"04"===Q.substr(te[1],2)))throw new Error("unsupported PKCS#1/5 hexadecimal key");(C=new F).readPKCS5PrvKeyHex(Q)}return C}if("pkcs8prv"===f)return I.getKeyFromPlainPrivatePKCS8Hex(l);if("pkcs8pub"===f)return I._getKeyFromPublicPKCS8Hex(l);if("x509pub"===f)return rn.getPublicKeyFromCertHex(l);if(-1!=l.indexOf("-END CERTIFICATE-",0)||-1!=l.indexOf("-END X509 CERTIFICATE-",0)||-1!=l.indexOf("-END TRUSTED CERTIFICATE-",0))return rn.getPublicKeyFromCertPEM(l);if(-1!=l.indexOf("-END PUBLIC KEY-")){var Se=ir(l,"PUBLIC KEY");return I._getKeyFromPublicPKCS8Hex(Se)}if(-1!=l.indexOf("-END RSA PRIVATE KEY-")&&-1==l.indexOf("4,ENCRYPTED")){var Ae=z(l,"RSA PRIVATE KEY");return I.getKey(Ae,null,"pkcs5prv")}if(-1!=l.indexOf("-END DSA PRIVATE KEY-")&&-1==l.indexOf("4,ENCRYPTED")){var q=M(j=z(l,"DSA PRIVATE KEY"),0,[1],"02"),ee=M(j,0,[2],"02"),re=M(j,0,[3],"02"),ue=M(j,0,[4],"02"),be=M(j,0,[5],"02");return(C=new P).setPrivate(new _e(q,16),new _e(ee,16),new _e(re,16),new _e(ue,16),new _e(be,16)),C}if(-1!=l.indexOf("-END EC PRIVATE KEY-")&&-1==l.indexOf("4,ENCRYPTED"))return Ae=z(l,"EC PRIVATE KEY"),I.getKey(Ae,null,"pkcs5prv");if(-1!=l.indexOf("-END PRIVATE KEY-"))return I.getKeyFromPlainPrivatePKCS8PEM(l);if(-1!=l.indexOf("-END RSA PRIVATE KEY-")&&-1!=l.indexOf("4,ENCRYPTED")){var ce=I.getDecryptedKeyHex(l,h),pe=new Ut;return pe.readPKCS5PrvKeyHex(ce),pe}if(-1!=l.indexOf("-END EC PRIVATE KEY-")&&-1!=l.indexOf("4,ENCRYPTED")){var B,C=M(j=I.getDecryptedKeyHex(l,h),0,[1],"04"),ve=M(j,0,[2,0],"06"),Ie=M(j,0,[3,0],"03").substr(2);if(void 0===w.crypto.OID.oidhex2name[ve])throw new Error("undefined OID(hex) in KJUR.crypto.OID: "+ve);return(B=new F({curve:w.crypto.OID.oidhex2name[ve]})).setPublicKeyHex(Ie),B.setPrivateKeyHex(C),B.isPublic=!1,B}if(-1!=l.indexOf("-END DSA PRIVATE KEY-")&&-1!=l.indexOf("4,ENCRYPTED"))return q=M(j=I.getDecryptedKeyHex(l,h),0,[1],"02"),ee=M(j,0,[2],"02"),re=M(j,0,[3],"02"),ue=M(j,0,[4],"02"),be=M(j,0,[5],"02"),(C=new P).setPrivate(new _e(q,16),new _e(ee,16),new _e(re,16),new _e(ue,16),new _e(be,16)),C;if(-1!=l.indexOf("-END ENCRYPTED PRIVATE KEY-"))return I.getKeyFromEncryptedPKCS8PEM(l,h);throw new Error("not supported argument")},Zt.generateKeypair=function(l,h){if("RSA"==l){var f=h;(_=new Ut).generate(f,"10001"),_.isPrivate=!0,_.isPublic=!0;var b=new Ut,E=_.n.toString(16),M=_.e.toString(16);return b.setPublic(E,M),b.isPrivate=!1,b.isPublic=!0,(D={}).prvKeyObj=_,D.pubKeyObj=b,D}if("EC"==l){var _,D,F=h,U=new w.crypto.ECDSA({curve:F}).generateKeyPairHex();return(_=new w.crypto.ECDSA({curve:F})).setPublicKeyHex(U.ecpubhex),_.setPrivateKeyHex(U.ecprvhex),_.isPrivate=!0,_.isPublic=!1,(b=new w.crypto.ECDSA({curve:F})).setPublicKeyHex(U.ecpubhex),b.isPrivate=!1,b.isPublic=!0,(D={}).prvKeyObj=_,D.pubKeyObj=b,D}throw new Error("unknown algorithm: "+l)},Zt.getPEM=function(l,h,f,_,b,E){var D=w.asn1,F=D.DERObjectIdentifier,P=D.DERInteger,U=D.ASN1Util.newObject,C=w.crypto,B=C.DSA,R=C.ECDSA,V=Ut;function L(ve){return U({seq:[{int:0},{int:{bigint:ve.n}},{int:ve.e},{int:{bigint:ve.d}},{int:{bigint:ve.p}},{int:{bigint:ve.q}},{int:{bigint:ve.dmp1}},{int:{bigint:ve.dmq1}},{int:{bigint:ve.coeff}}]})}function $(ve){return U({seq:[{int:1},{octstr:{hex:ve.prvKeyHex}},{tag:["a0",!0,{oid:{name:ve.curveName}}]},{tag:["a1",!0,{bitstr:{hex:"00"+ve.pubKeyHex}}]}]})}function J(ve){return U({seq:[{int:0},{int:{bigint:ve.p}},{int:{bigint:ve.q}},{int:{bigint:ve.g}},{int:{bigint:ve.y}},{int:{bigint:ve.x}}]})}if((void 0!==V&&l instanceof V||void 0!==B&&l instanceof B||void 0!==R&&l instanceof R)&&1==l.isPublic&&(void 0===h||"PKCS8PUB"==h))return Fr(te=new(0,D.x509.SubjectPublicKeyInfo)(l).tohex(),"PUBLIC KEY");if("PKCS1PRV"==h&&void 0!==V&&l instanceof V&&(void 0===f||null==f)&&1==l.isPrivate)return Fr(te=L(l).tohex(),"RSA PRIVATE KEY");if("PKCS1PRV"==h&&void 0!==R&&l instanceof R&&(void 0===f||null==f)&&1==l.isPrivate){var Ae=new F({name:l.curveName}).tohex(),q=$(l).tohex(),ee="";return(ee+=Fr(Ae,"EC PARAMETERS"))+Fr(q,"EC PRIVATE KEY")}if("PKCS1PRV"==h&&void 0!==B&&l instanceof B&&(void 0===f||null==f)&&1==l.isPrivate)return Fr(te=J(l).tohex(),"DSA PRIVATE KEY");if("PKCS5PRV"==h&&void 0!==V&&l instanceof V&&void 0!==f&&null!=f&&1==l.isPrivate){var te=L(l).tohex();return void 0===_&&(_="DES-EDE3-CBC"),this.getEncryptedPKCS5PEMFromPrvKeyHex("RSA",te,f,_,E)}if("PKCS5PRV"==h&&void 0!==R&&l instanceof R&&void 0!==f&&null!=f&&1==l.isPrivate)return te=$(l).tohex(),void 0===_&&(_="DES-EDE3-CBC"),this.getEncryptedPKCS5PEMFromPrvKeyHex("EC",te,f,_,E);if("PKCS5PRV"==h&&void 0!==B&&l instanceof B&&void 0!==f&&null!=f&&1==l.isPrivate)return te=J(l).tohex(),void 0===_&&(_="DES-EDE3-CBC"),this.getEncryptedPKCS5PEMFromPrvKeyHex("DSA",te,f,_,E);var re=function(ve,Ie){var Bt=ue(ve,Ie);return new U({seq:[{seq:[{oid:{name:"pkcs5PBES2"}},{seq:[{seq:[{oid:{name:"pkcs5PBKDF2"}},{seq:[{octstr:{hex:Bt.pbkdf2Salt}},{int:Bt.pbkdf2Iter}]}]},{seq:[{oid:{name:"des-EDE3-CBC"}},{octstr:{hex:Bt.encryptionSchemeIV}}]}]}]},{octstr:{hex:Bt.ciphertext}}]}).tohex()},ue=function(ve,Ie){var Nt=pt.lib.WordArray.random(8),Rn=pt.lib.WordArray.random(8),Y=pt.PBKDF2(Ie,Nt,{keySize:6,iterations:100}),ui=pt.enc.Hex.parse(ve),oi=pt.TripleDES.encrypt(ui,Y,{iv:Rn})+"",Fi={};return Fi.ciphertext=oi,Fi.pbkdf2Salt=pt.enc.Hex.stringify(Nt),Fi.pbkdf2Iter=100,Fi.encryptionSchemeAlg="DES-EDE3-CBC",Fi.encryptionSchemeIV=pt.enc.Hex.stringify(Rn),Fi};if("PKCS8PRV"==h&&null!=V&&l instanceof V&&1==l.isPrivate){var ce=L(l).tohex();return te=U({seq:[{int:0},{seq:[{oid:{name:"rsaEncryption"}},{null:!0}]},{octstr:{hex:ce}}]}).tohex(),void 0===f||null==f?Fr(te,"PRIVATE KEY"):Fr(q=re(te,f),"ENCRYPTED PRIVATE KEY")}if("PKCS8PRV"==h&&void 0!==R&&l instanceof R&&1==l.isPrivate){var pe={seq:[{int:1},{octstr:{hex:l.prvKeyHex}}]};return"string"==typeof l.pubKeyHex&&pe.seq.push({tag:["a1",!0,{bitstr:{hex:"00"+l.pubKeyHex}}]}),ce=new U(pe).tohex(),te=U({seq:[{int:0},{seq:[{oid:{name:"ecPublicKey"}},{oid:{name:l.curveName}}]},{octstr:{hex:ce}}]}).tohex(),void 0===f||null==f?Fr(te,"PRIVATE KEY"):Fr(q=re(te,f),"ENCRYPTED PRIVATE KEY")}if("PKCS8PRV"==h&&void 0!==B&&l instanceof B&&1==l.isPrivate)return ce=new P({bigint:l.x}).tohex(),te=U({seq:[{int:0},{seq:[{oid:{name:"dsa"}},{seq:[{int:{bigint:l.p}},{int:{bigint:l.q}},{int:{bigint:l.g}}]}]},{octstr:{hex:ce}}]}).tohex(),void 0===f||null==f?Fr(te,"PRIVATE KEY"):Fr(q=re(te,f),"ENCRYPTED PRIVATE KEY");throw new Error("unsupported object nor format")},Zt.getKeyFromCSRPEM=function(l){var h=ir(l,"CERTIFICATE REQUEST");return Zt.getKeyFromCSRHex(h)},Zt.getKeyFromCSRHex=function(l){var h=Zt.parseCSRHex(l);return Zt.getKey(h.p8pubkeyhex,null,"pkcs8pub")},Zt.parseCSRHex=function(l){var f=rt.getChildIdx,_=rt.getTLV,b={},E=l;if("30"!=E.substr(0,2))throw new Error("malformed CSR(code:001)");var M=f(E,0);if(M.length<1)throw new Error("malformed CSR(code:002)");if("30"!=E.substr(M[0],2))throw new Error("malformed CSR(code:003)");var D=f(E,M[0]);if(D.length<3)throw new Error("malformed CSR(code:004)");return b.p8pubkeyhex=_(E,D[2]),b},Zt.getKeyID=function(l){var h=Zt,f=rt;"string"==typeof l&&-1!=l.indexOf("BEGIN ")&&(l=h.getKey(l));var _=ir(h.getPEM(l)),b=f.getIdxbyList(_,0,[1]),E=f.getV(_,b).substring(2);return w.crypto.Util.hashHex(E,"sha1")},Zt.getJWK=function(l,h,f,_,b){var E,D,M={},F=w.crypto.Util.hashHex;if("string"==typeof l)E=Zt.getKey(l),-1!=l.indexOf("CERTIFICATE")&&(D=ir(l));else{if("object"!=typeof l)throw new Error("unsupported keyinfo type");l instanceof rn?(E=l.getPublicKey(),D=l.hex):E=l}if(E instanceof Ut&&E.isPrivate)M.kty="RSA",M.n=Er(E.n.toString(16)),M.e=Er(E.e.toString(16)),M.d=Er(E.d.toString(16)),M.p=Er(E.p.toString(16)),M.q=Er(E.q.toString(16)),M.dp=Er(E.dmp1.toString(16)),M.dq=Er(E.dmq1.toString(16)),M.qi=Er(E.coeff.toString(16));else if(E instanceof Ut&&E.isPublic)M.kty="RSA",M.n=Er(E.n.toString(16)),M.e=Er(E.e.toString(16));else if(E instanceof w.crypto.ECDSA&&E.isPrivate){if("P-256"!==(P=E.getShortNISTPCurveName())&&"P-384"!==P&&"P-521"!==P)throw new Error("unsupported curve name for JWT: "+P);var U=E.getPublicKeyXYHex();M.kty="EC",M.crv=P,M.x=Er(U.x),M.y=Er(U.y),M.d=Er(E.prvKeyHex)}else if(E instanceof w.crypto.ECDSA&&E.isPublic){var P;if("P-256"!==(P=E.getShortNISTPCurveName())&&"P-384"!==P&&"P-521"!==P)throw new Error("unsupported curve name for JWT: "+P);U=E.getPublicKeyXYHex(),M.kty="EC",M.crv=P,M.x=Er(U.x),M.y=Er(U.y)}if(null==M.kty)throw new Error("unsupported keyinfo");return!E.isPrivate&&1!=h&&(M.kid=w.jws.JWS.getJWKthumbprint(M)),null!=D&&1!=f&&(M.x5c=[_i(D)]),null!=D&&1!=_&&(M.x5t=Qr(_i(F(D,"sha1")))),null!=D&&1!=b&&(M["x5t#S256"]=Qr(_i(F(D,"sha256")))),M},Zt.getJWKFromKey=function(l){return Zt.getJWK(l,!0,!0,!0,!0)},Ut.getPosArrayOfChildrenFromHex=function(l){return rt.getChildIdx(l,0)},Ut.getHexValueArrayOfChildrenFromHex=function(l){var I,f=rt.getV,_=f(l,(I=Ut.getPosArrayOfChildrenFromHex(l))[0]),b=f(l,I[1]),E=f(l,I[2]),M=f(l,I[3]),D=f(l,I[4]),F=f(l,I[5]),P=f(l,I[6]),U=f(l,I[7]),z=f(l,I[8]);return(I=new Array).push(_,b,E,M,D,F,P,U,z),I},Ut.prototype.readPrivateKeyFromPEMString=function(l){var h=ir(l),f=Ut.getHexValueArrayOfChildrenFromHex(h);this.setPrivateEx(f[1],f[2],f[3],f[4],f[5],f[6],f[7],f[8])},Ut.prototype.readPKCS5PrvKeyHex=function(l){var h=Ut.getHexValueArrayOfChildrenFromHex(l);this.setPrivateEx(h[1],h[2],h[3],h[4],h[5],h[6],h[7],h[8])},Ut.prototype.readPKCS8PrvKeyHex=function(l){var h,f,_,b,E,M,D,F,U=rt.getVbyListEx;if(!1===rt.isASN1HEX(l))throw new Error("not ASN.1 hex string");try{h=U(l,0,[2,0,1],"02"),f=U(l,0,[2,0,2],"02"),_=U(l,0,[2,0,3],"02"),b=U(l,0,[2,0,4],"02"),E=U(l,0,[2,0,5],"02"),M=U(l,0,[2,0,6],"02"),D=U(l,0,[2,0,7],"02"),F=U(l,0,[2,0,8],"02")}catch{throw new Error("malformed PKCS#8 plain RSA private key")}this.setPrivateEx(h,f,_,b,E,M,D,F)},Ut.prototype.readPKCS5PubKeyHex=function(l){var h=rt,f=h.getV;if(!1===h.isASN1HEX(l))throw new Error("keyHex is not ASN.1 hex string");var _=h.getChildIdx(l,0);if(2!==_.length||"02"!==l.substr(_[0],2)||"02"!==l.substr(_[1],2))throw new Error("wrong hex for PKCS#5 public key");var b=f(l,_[0]),E=f(l,_[1]);this.setPublic(b,E)},Ut.prototype.readPKCS8PubKeyHex=function(l){var h=rt;if(!1===h.isASN1HEX(l))throw new Error("not ASN.1 hex string");if("06092a864886f70d010101"!==h.getTLVbyListEx(l,0,[0,0]))throw new Error("not PKCS8 RSA public key");var f=h.getTLVbyListEx(l,0,[1,0]);this.readPKCS5PubKeyHex(f)},Ut.prototype.readCertPubKeyHex=function(l,h){var f,_;(f=new rn).readCertHex(l),_=f.getPublicKeyHex(),this.readPKCS8PubKeyHex(_)},Ut.prototype.sign=function(l,h){var _=function(b){return w.crypto.Util.hashString(b,h)}(l);return this.signWithMessageHash(_,h)},Ut.prototype.signWithMessageHash=function(l,h){var _=hr(w.crypto.Util.getPaddedDigestInfoHex(l,h,this.n.bitLength()),16);return Xs(this.doPrivate(_).toString(16),this.n.bitLength())},Ut.prototype.signPSS=function(l,h,f){var b=function(E){return w.crypto.Util.hashHex(E,h)}(_s(l));return void 0===f&&(f=-1),this.signWithMessageHashPSS(b,h,f)},Ut.prototype.signWithMessageHashPSS=function(l,h,f){var D,_=Vr(l),b=_.length,E=this.n.bitLength()-1,M=Math.ceil(E/8),F=function(V){return w.crypto.Util.hashHex(V,h)};if(-1===f||void 0===f)f=b;else if(-2===f)f=M-b-2;else if(f<-2)throw new Error("invalid salt length");if(M0&&(P=new Array(f),(new Ao).nextBytes(P),P=String.fromCharCode.apply(String,P));var U=Vr(F(_s("\0\0\0\0\0\0\0\0"+_+P))),z=[];for(D=0;D>8*M-E&255),D=0;D_)return!1;var E=this.doPublic(f).toString(16);if(E.length+3!=_/4)return!1;var D=Os(E.replace(/^1f+00/,""));if(0==D.length)return!1;var F=D[0],P=D[1],z=function(I){return w.crypto.Util.hashString(I,F)}(l);return P==z},Ut.prototype.verifyWithMessageHash=function(l,h){if(h.length!=Math.ceil(this.n.bitLength()/4))return!1;var f=hr(h,16);if(f.bitLength()>this.n.bitLength())return 0;var E=Os(this.doPublic(f).toString(16).replace(/^1f+00/,""));return 0!=E.length&&E[1]==l},Ut.prototype.verifyPSS=function(l,h,f,_){var E=function(M){return w.crypto.Util.hashHex(M,f)}(_s(l));return void 0===_&&(_=-1),this.verifyWithMessageHashPSS(E,h,f,_)},Ut.prototype.verifyWithMessageHashPSS=function(l,h,f,_){if(h.length!=Math.ceil(this.n.bitLength()/4))return!1;var U,b=new _e(h,16),E=function($){return w.crypto.Util.hashHex($,f)},M=Vr(l),D=M.length,F=this.n.bitLength()-1,P=Math.ceil(F/8);if(-1===_||void 0===_)_=D;else if(-2===_)_=P-D-2;else if(_<-2)throw new Error("invalid salt length");if(P>8*P-F&255;if(I.charCodeAt(0)&B)throw new Error("bits beyond keysize not zero");var R=yd(C,I.length,E),V=[];for(U=0;U"u"||!w)&&(w={}),(typeof w.jws>"u"||!w.jws)&&(w.jws={}),w.jws.JWS=function(){var f=w.jws.JWS.isSafeJSONString;this.parseJWS=function(_,b){if(void 0===this.parsedJWS||!b&&void 0===this.parsedJWS.sigvalH){var E=_.match(/^([^.]+)\.([^.]+)\.([^.]+)$/);if(null==E)throw"JWS signature is not a form of 'Head.Payload.SigValue'.";var M=E[1],D=E[2],F=E[3],P=M+"."+D;if(this.parsedJWS={},this.parsedJWS.headB64U=M,this.parsedJWS.payloadB64U=D,this.parsedJWS.sigvalB64U=F,this.parsedJWS.si=P,!b){var U=nn(F),z=hr(U,16);this.parsedJWS.sigvalH=U,this.parsedJWS.sigvalBI=z}var I=mo(M),C=mo(D);if(this.parsedJWS.headS=I,this.parsedJWS.payloadS=C,!f(I,this.parsedJWS,"headP"))throw"malformed JSON string for JWS Head: "+I}}},w.jws.JWS.sign=function(l,h,f,_,b){var R,V,L,D=w.jws.JWS,F=D.readSafeJSONString,P=D.isSafeJSONString,U=w.crypto,I=U.Mac,C=U.Signature,B=JSON;if("string"!=typeof h&&"object"!=typeof h)throw"spHeader must be JSON string or object: "+h;if("object"==typeof h&&(R=B.stringify(V=h)),"string"==typeof h){if(!P(R=h))throw"JWS Head is not safe JSON string: "+R;V=F(R)}if(L=f,"object"==typeof f&&(L=B.stringify(f)),(""==l||null==l)&&void 0!==V.alg&&(l=V.alg),""!=l&&null!=l&&void 0===V.alg&&(V.alg=l,R=B.stringify(V)),l!==V.alg)throw"alg and sHeader.alg doesn't match: "+l+"!="+V.alg;var $=null;if(void 0===D.jwsalg2sigalg[l])throw"unsupported alg name: "+l;$=D.jwsalg2sigalg[l];var te=Il(R)+"."+Il(L),Se="";if("Hmac"==$.substr(0,4)){if(void 0===_)throw"mac key shall be specified for HS* alg";var Ae=new I({alg:$,prov:"cryptojs",pass:_});Ae.updateString(te),Se=Ae.doFinal()}else if(-1!=$.indexOf("withECDSA")){(j=new C({alg:$})).init(_,b),j.updateString(te);var q=j.sign();Se=w.crypto.ECDSA.asn1SigToConcatSig(q)}else if("none"!=$){var j;(j=new C({alg:$})).init(_,b),j.updateString(te),Se=j.sign()}return te+"."+Er(Se)},w.jws.JWS.verify=function(l,h,f){var z,E=w.jws.JWS,M=E.readSafeJSONString,D=w.crypto,F=D.ECDSA,P=D.Mac,U=D.Signature;if(z=Ut,!mr(l))return!1;var I=l.split(".");if(3!==I.length)return!1;var J,R=I[0]+"."+I[1],V=nn(I[2]),L=M(mo(I[0])),$=null;if(void 0===L.alg)throw"algorithm not specified in header";if(J=($=L.alg).substr(0,2),null!=f&&"[object Array]"===Object.prototype.toString.call(f)&&f.length>0&&-1==(":"+f.join(":")+":").indexOf(":"+$+":"))throw"algorithm '"+$+"' not accepted in the list";if("none"!=$&&null===h)throw"key shall be specified to verify.";if("string"==typeof h&&-1!=h.indexOf("-----BEGIN ")&&(h=Zt.getKey(h)),!("RS"!=J&&"PS"!=J||h instanceof z))throw"key shall be a RSAKey obj for RS* and PS* algs";if("ES"==J&&!(h instanceof F))throw"key shall be a ECDSA obj for ES* algs";var te=null;if(void 0===E.jwsalg2sigalg[L.alg])throw"unsupported alg name: "+$;if("none"==(te=E.jwsalg2sigalg[$]))throw"not supported";if("Hmac"==te.substr(0,4)){if(void 0===h)throw"hexadecimal key shall be specified for HMAC";var Ae=new P({alg:te,pass:h});return Ae.updateString(R),V==Ae.doFinal()}if(-1!=te.indexOf("withECDSA")){var q,j=null;try{j=F.concatSigToASN1Sig(V)}catch{return!1}return(q=new U({alg:te})).init(h),q.updateString(R),q.verify(j)}return(q=new U({alg:te})).init(h),q.updateString(R),q.verify(V)},w.jws.JWS.parse=function(l){var b,E,h=l.split("."),f={};if(2!=h.length&&3!=h.length)throw"malformed sJWS: wrong number of '.' splitted elements";return b=h[1],3==h.length&&(E=h[2]),f.headerObj=w.jws.JWS.readSafeJSONString(mo(h[0])),f.payloadObj=w.jws.JWS.readSafeJSONString(mo(b)),f.headerPP=JSON.stringify(f.headerObj,null," "),f.payloadPP=null==f.payloadObj?mo(b):JSON.stringify(f.payloadObj,null," "),void 0!==E&&(f.sigHex=nn(E)),f},w.jws.JWS.verifyJWT=function(l,h,f){var b=w.jws,E=b.JWS,M=E.readSafeJSONString,D=E.inArray,F=E.includedArray;if(!mr(l))return!1;var P=l.split(".");if(3!=P.length)return!1;var U=P[0],z=P[1],B=(nn(P[2]),M(mo(U))),R=M(mo(z));if(void 0===B.alg)return!1;if(void 0===f.alg)throw"acceptField.alg shall be specified";if(!D(B.alg,f.alg)||void 0!==R.iss&&"object"==typeof f.iss&&!D(R.iss,f.iss)||void 0!==R.sub&&"object"==typeof f.sub&&!D(R.sub,f.sub))return!1;if(void 0!==R.aud&&"object"==typeof f.aud)if("string"==typeof R.aud){if(!D(R.aud,f.aud))return!1}else if("object"==typeof R.aud&&!F(R.aud,f.aud))return!1;var V=b.IntDate.getNow();return void 0!==f.verifyAt&&"number"==typeof f.verifyAt&&(V=f.verifyAt),(void 0===f.gracePeriod||"number"!=typeof f.gracePeriod)&&(f.gracePeriod=0),!(void 0!==R.exp&&"number"==typeof R.exp&&R.exp+f.gracePeriod"u"||!w)&&(w={}),(typeof w.jws>"u"||!w.jws)&&(w.jws={}),w.jws.JWSJS=function(){var f=w.jws.JWS,_=f.readSafeJSONString;this.aHeader=[],this.sPayload="",this.aSignature=[],this.init=function(){this.aHeader=[],this.sPayload=void 0,this.aSignature=[]},this.initWithJWS=function(b){this.init();var E=b.split(".");if(3!=E.length)throw"malformed input JWS";this.aHeader.push(E[0]),this.sPayload=E[1],this.aSignature.push(E[2])},this.addSignature=function(b,E,M,D){if(null==this.sPayload)throw"there's no JSON-JS signature to add.";var F=this.aHeader.length;if(this.aHeader.length!=this.aSignature.length)throw"aHeader.length != aSignature.length";try{var U=w.jws.JWS.sign(b,E,this.sPayload,M,D).split(".");this.aHeader.push(U[0]),this.aSignature.push(U[2])}catch(C){throw this.aHeader.length>F&&this.aHeader.pop(),this.aSignature.length>F&&this.aSignature.pop(),"addSignature failed: "+C}},this.verifyAll=function(b){if(this.aHeader.length!==b.length||this.aSignature.length!==b.length)return!1;for(var E=0;E0))throw"malformed header";if(this.aHeader=b.headers,"string"!=typeof b.payload)throw"malformed signatures";if(this.sPayload=b.payload,!(b.signatures.length>0))throw"malformed signatures";this.aSignature=b.signatures}catch(M){throw"malformed JWS-JS JSON object: "+M}},this.getJSON=function(){return{headers:this.aHeader,payload:this.sPayload,signatures:this.aSignature}},this.isEmpty=function(){return 0==this.aHeader.length?1:0}},ka.KZ=Zt,ka.fs=w},7489:function(Aa,ka,dt){var qr;Aa=dt.nmd(Aa),function(){var le,ps=200,_i="Expected a function",ao="__lodash_hash_undefined__",Kr="__lodash_placeholder__",Tn=1,Sl=2,_e=4,An=1,di=2,ks=1,Fa=2,El=4,ms=8,Is=16,Yr=32,Sr=64,un=128,Ra=256,lu=512,du=800,cn=16,$t=1/0,Qn=9007199254740991,In=17976931348623157e292,fn=NaN,Fn=4294967295,sr=Fn-1,Wi=Fn>>>1,lc=[["ary",un],["bind",ks],["bindKey",Fa],["curry",ms],["curryRight",Is],["flip",lu],["partial",Yr],["partialRight",Sr],["rearg",Ra]],co="[object Arguments]",dc="[object Array]",$o="[object AsyncFunction]",Fs="[object Boolean]",_t="[object Date]",uu="[object DOMException]",zc="[object Error]",hu="[object Function]",Ep="[object GeneratorFunction]",lo="[object Map]",ad="[object Number]",Gc="[object Null]",Oa="[object Object]",Mp="[object Promise]",dr="[object Proxy]",ur="[object RegExp]",qo="[object Set]",cd="[object String]",Ih="[object Symbol]",Ml="[object Undefined]",uc="[object WeakMap]",hc="[object ArrayBuffer]",Cl="[object DataView]",Fh="[object Float32Array]",ld="[object Float64Array]",Rh="[object Int8Array]",Ph="[object Int16Array]",Cp="[object Int32Array]",Oh="[object Uint8Array]",Lh="[object Uint8ClampedArray]",Nh="[object Uint16Array]",Bh="[object Uint32Array]",Dp=/\b__p \+= '';/g,Vi=/\b(__p \+=) '' \+/g,Vh=/(__e\(.*?\)|\b__t\)) \+\n'';/g,ki=/&(?:amp|lt|gt|quot|#39);/g,fu=/[&<>"']/g,Tp=RegExp(ki.source),Mi=RegExp(fu.source),en=/<%-([\s\S]+?)%>/g,Hh=/<%([\s\S]+?)%>/g,pu=/<%=([\s\S]+?)%>/g,hb=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,mu=/^\w*$/,Ue=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Dl=/[\\^$.*+?()[\]{}|]/g,wn=RegExp(Dl.source),wi=/^\s+|\s+$/g,Ap=/^\s+/,fb=/\s+$/,F0=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,gu=/\{\n\/\* \[wrapped with (.+)\] \*/,uo=/,? & /,pb=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,R0=/\\(\\)?/g,mb=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,La=/\w*$/,gb=/^[-+]0x[0-9a-f]+$/i,_b=/^0b[01]+$/i,vb=/^\[object .+?Constructor\]$/,yb=/^0o[0-7]+$/i,P0=/^(?:0|[1-9]\d*)$/,bb=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,fc=/($^)/,O0=/['\n\r\u2028\u2029\\]/g,Rs="\\ud800-\\udfff",L0="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Je="\\u2700-\\u27bf",N0="a-z\\xdf-\\xf6\\xf8-\\xff",Ip="A-Z\\xc0-\\xd6\\xd8-\\xde",Fp="\\ufe0e\\ufe0f",Uh="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Xr="["+Rs+"]",zh="["+Uh+"]",vu="["+L0+"]",tn="\\d+",dd="["+Je+"]",Rp="["+N0+"]",ho="[^"+Rs+Uh+tn+Je+N0+Ip+"]",yu="\\ud83c[\\udffb-\\udfff]",Ii="[^"+Rs+"]",$s="(?:\\ud83c[\\udde6-\\uddff]){2}",kr="[\\ud800-\\udbff][\\udc00-\\udfff]",ud="["+Ip+"]",qs="(?:"+Rp+"|"+ho+")",hd="(?:"+ud+"|"+ho+")",Gh="(?:['\u2019](?:d|ll|m|re|s|t|ve))?",jh="(?:['\u2019](?:D|LL|M|RE|S|T|VE))?",Op="(?:"+vu+"|"+yu+")?",Wh="["+Fp+"]?",xe=Wh+Op+"(?:\\u200d(?:"+[Ii,$s,kr].join("|")+")"+Wh+Op+")*",Lp="(?:"+[dd,$s,kr].join("|")+")"+xe,hn="(?:"+[Ii+vu+"?",vu,$s,kr,Xr].join("|")+")",bu=RegExp("['\u2019]","g"),Ut=RegExp(vu,"g"),jc=RegExp(yu+"(?="+yu+")|"+hn+xe,"g"),V0=RegExp([ud+"?"+Rp+"+"+Gh+"(?="+[zh,ud,"$"].join("|")+")",hd+"+"+jh+"(?="+[zh,ud+qs,"$"].join("|")+")",ud+"?"+qs+"+"+Gh,ud+"+"+jh,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",tn,Lp].join("|"),"g"),H0=RegExp("[\\u200d"+Rs+L0+Fp+"]"),U0=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,mc=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],ko=-1,Xi={};Xi[Fh]=Xi[ld]=Xi[Rh]=Xi[Ph]=Xi[Cp]=Xi[Oh]=Xi[Lh]=Xi[Nh]=Xi[Bh]=!0,Xi[co]=Xi[dc]=Xi[hc]=Xi[Fs]=Xi[Cl]=Xi[_t]=Xi[zc]=Xi[hu]=Xi[lo]=Xi[ad]=Xi[Oa]=Xi[ur]=Xi[qo]=Xi[cd]=Xi[uc]=!1;var Ki={};Ki[co]=Ki[dc]=Ki[hc]=Ki[Cl]=Ki[Fs]=Ki[_t]=Ki[Fh]=Ki[ld]=Ki[Rh]=Ki[Ph]=Ki[Cp]=Ki[lo]=Ki[ad]=Ki[Oa]=Ki[ur]=Ki[qo]=Ki[cd]=Ki[Ih]=Ki[Oh]=Ki[Lh]=Ki[Nh]=Ki[Bh]=!0,Ki[zc]=Ki[hu]=Ki[uc]=!1;var xu={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},$h=parseFloat,fr=parseInt,qh="object"==typeof global&&global&&global.Object===Object&&global,Ba="object"==typeof self&&self&&self.Object===Object&&self,pr=qh||Ba||Function("return this")(),Np=ka&&!ka.nodeType&&ka,Ln=Np&&Aa&&!Aa.nodeType&&Aa,Bp=Ln&&Ln.exports===Np,wu=Bp&&qh.process,fo=function(){try{return Ln&&Ln.require&&Ln.require("util").types||wu&&wu.binding&&wu.binding("util")}catch{}}(),Mt=fo&&fo.isArrayBuffer,Vp=fo&&fo.isDate,Kh=fo&&fo.isMap,ut=fo&&fo.isRegExp,Yi=fo&&fo.isSet,Ei=fo&&fo.isTypedArray;function Ni(we,Ge,Fe){switch(Fe.length){case 0:return we.call(Ge);case 1:return we.call(Ge,Fe[0]);case 2:return we.call(Ge,Fe[0],Fe[1]);case 3:return we.call(Ge,Fe[0],Fe[1],Fe[2])}return we.apply(Ge,Fe)}function Ps(we,Ge,Fe,Ft){for(var kn=-1,qn=null==we?0:we.length;++kn-1}function Zi(we,Ge,Fe){for(var Ft=-1,kn=null==we?0:we.length;++Ft-1;);return Fe}function gs(we,Ge){for(var Fe=we.length;Fe--&&pa(Ge,we[Fe],0)>-1;);return Fe}var go=Qr({\u00c0:"A",\u00c1:"A",\u00c2:"A",\u00c3:"A",\u00c4:"A",\u00c5:"A",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u00e3:"a",\u00e4:"a",\u00e5:"a",\u00c7:"C",\u00e7:"c",\u00d0:"D",\u00f0:"d",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u00cb:"E",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u00eb:"e",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u00cf:"I",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u00ef:"i",\u00d1:"N",\u00f1:"n",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u00d5:"O",\u00d6:"O",\u00d8:"O",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u00f5:"o",\u00f6:"o",\u00f8:"o",\u00d9:"U",\u00da:"U",\u00db:"U",\u00dc:"U",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u00fc:"u",\u00dd:"Y",\u00fd:"y",\u00ff:"y",\u00c6:"Ae",\u00e6:"ae",\u00de:"Th",\u00fe:"th",\u00df:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u010e:"D",\u0110:"D",\u010f:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011a:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011b:"e",\u011c:"G",\u011e:"G",\u0120:"G",\u0122:"G",\u011d:"g",\u011f:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012a:"I",\u012c:"I",\u012e:"I",\u0130:"I",\u0129:"i",\u012b:"i",\u012d:"i",\u012f:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013b:"L",\u013d:"L",\u013f:"L",\u0141:"L",\u013a:"l",\u013c:"l",\u013e:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014a:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014b:"n",\u014c:"O",\u014e:"O",\u0150:"O",\u014d:"o",\u014f:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015a:"S",\u015c:"S",\u015e:"S",\u0160:"S",\u015b:"s",\u015d:"s",\u015f:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016a:"U",\u016c:"U",\u016e:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016b:"u",\u016d:"u",\u016f:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017b:"Z",\u017d:"Z",\u017a:"z",\u017c:"z",\u017e:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017f:"s"}),Yo=Qr({"&":"&","<":"<",">":">",'"':""","'":"'"});function Vr(we){return"\\"+xu[we]}function ga(we){return H0.test(we)}function Fr(we){var Ge=-1,Fe=Array(we.size);return we.forEach(function(Ft,kn){Fe[++Ge]=[kn,Ft]}),Fe}function ir(we,Ge){return function(Fe){return we(Ge(Fe))}}function _c(we,Ge){for(var Fe=-1,Ft=we.length,kn=0,qn=[];++Fe",""":'"',"'":"'"}),md=function we(Ge){var d,Fe=(Ge=null==Ge?pr:md.defaults(pr.Object(),Ge,md.pick(pr,mc))).Array,Ft=Ge.Date,kn=Ge.Error,qn=Ge.Function,mr=Ge.Math,Cn=Ge.Object,Su=Ge.RegExp,j0=Ge.String,vo=Ge.TypeError,vc=Fe.prototype,Wc=Cn.prototype,$c=Ge["__core-js_shared__"],_d=qn.prototype.toString,Nn=Wc.hasOwnProperty,vd=0,He=(d=/[^.]+$/.exec($c&&$c.keys&&$c.keys.IE_PROTO||""))?"Symbol(src)_1."+d:"",Zt=Wc.toString,Mb=_d.call(Cn),Jh=pr._,Xs=Su("^"+_d.call(Nn).replace(Dl,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),yd=Bp?Ge.Buffer:le,Ha=Ge.Symbol,yc=Ge.Uint8Array,Os=yd?yd.allocUnsafe:le,rn=ir(Cn.getPrototypeOf,Cn),bd=Cn.create,l=Wc.propertyIsEnumerable,h=vc.splice,f=Ha?Ha.isConcatSpreadable:le,_=Ha?Ha.iterator:le,b=Ha?Ha.toStringTag:le,E=function(){try{var d=Bl(Cn,"defineProperty");return d({},"",{}),d}catch{}}(),M=Ge.clearTimeout!==pr.clearTimeout&&Ge.clearTimeout,D=Ft&&Ft.now!==pr.Date.now&&Ft.now,F=Ge.setTimeout!==pr.setTimeout&&Ge.setTimeout,P=mr.ceil,U=mr.floor,z=Cn.getOwnPropertySymbols,I=yd?yd.isBuffer:le,C=Ge.isFinite,B=vc.join,R=ir(Cn.keys,Cn),V=mr.max,L=mr.min,$=Ft.now,J=Ge.parseInt,Q=mr.random,te=vc.reverse,Se=Bl(Ge,"DataView"),Ae=Bl(Ge,"Map"),j=Bl(Ge,"Promise"),q=Bl(Ge,"Set"),ee=Bl(Ge,"WeakMap"),re=Bl(Cn,"create"),ue=ee&&new ee,be={},ce=Hl(Se),pe=Hl(Ae),ve=Hl(j),Ie=Hl(q),Bt=Hl(ee),Nt=Ha?Ha.prototype:le,Lt=Nt?Nt.valueOf:le,Rn=Nt?Nt.toString:le;function Y(d){if(Cr(d)&&!yn(d)&&!(d instanceof ln)){if(d instanceof Fi)return d;if(Nn.call(d,"__wrapped__"))return nM(d)}return new Fi(d)}var ui=function(){function d(){}return function(m){if(!_r(m))return{};if(bd)return bd(m);d.prototype=m;var S=new d;return d.prototype=le,S}}();function oi(){}function Fi(d,m){this.__wrapped__=d,this.__actions__=[],this.__chain__=!!m,this.__index__=0,this.__values__=le}function ln(d){this.__wrapped__=d,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Fn,this.__views__=[]}function Kn(d){var m=-1,S=null==d?0:d.length;for(this.clear();++m=m?d:m)),d}function Zo(d,m,S,O,W,Z){var de,me=m&Tn,Ee=m&Sl,qe=m&_e;if(S&&(de=W?S(d,O,W,Z):S(d)),de!==le)return de;if(!_r(d))return d;var Ye=yn(d);if(Ye){if(de=function YE(d){var m=d.length,S=new d.constructor(m);return m&&"string"==typeof d[0]&&Nn.call(d,"index")&&(S.index=d.index,S.input=d.input),S}(d),!me)return Bs(d,de)}else{var nt=Vs(d),wt=nt==hu||nt==Ep;if(zl(d))return Cd(d,me);if(nt==Oa||nt==co||wt&&!W){if(de=Ee||wt?{}:sm(d),!me)return Ee?function qb(d,m){return $a(d,Jb(d),m)}(d,function $p(d,m){return d&&$a(m,ns(m),d)}(de,d)):function BE(d,m){return $a(d,rm(d),m)}(d,Tb(de,d))}else{if(!Ki[nt])return W?d:{};de=function h_(d,m,S){var O=d.constructor;switch(m){case hc:return Dd(d);case Fs:case _t:return new O(+d);case Cl:return function OE(d,m){var S=m?Dd(d.buffer):d.buffer;return new d.constructor(S,d.byteOffset,d.byteLength)}(d,S);case Fh:case ld:case Rh:case Ph:case Cp:case Oh:case Lh:case Nh:case Bh:return jb(d,S);case lo:return new O;case ad:case cd:return new O(d);case ur:return function tF(d){var m=new d.constructor(d.source,La.exec(d));return m.lastIndex=d.lastIndex,m}(d);case qo:return new O;case Ih:return function Gb(d){return Lt?Cn(Lt.call(d)):{}}(d)}}(d,nt,me)}}Z||(Z=new xc);var Ht=Z.get(d);if(Ht)return Ht;Z.set(d,de),B_(d)?d.forEach(function(dn){de.add(Zo(dn,m,S,dn,d,Z))}):Od(d)&&d.forEach(function(dn,ri){de.set(ri,Zo(dn,m,S,ri,d,Z))});var zn=Ye?le:(qe?Ee?Qs:u_:Ee?ns:bs)(d);return Zr(zn||d,function(dn,ri){zn&&(dn=d[ri=dn]),Eu(de,ri,Zo(dn,m,S,ri,d,Z))}),de}function kb(d,m,S){var O=S.length;if(null==d)return!O;for(d=Cn(d);O--;){var W=S[O],de=d[W];if(de===le&&!(W in d)||!(0,m[W])(de))return!1}return!0}function za(d,m,S){if("function"!=typeof d)throw new vo(_i);return Ad(function(){d.apply(le,S)},m)}function tf(d,m,S,O){var W=-1,Z=Sn,de=!0,me=d.length,Ee=[],qe=m.length;if(!me)return Ee;S&&(m=si(m,Ys(S))),O?(Z=Zi,de=!1):m.length>=ps&&(Z=Io,de=!1,m=new va(m));e:for(;++W-1},$i.prototype.set=function qc(d,m){var S=this.__data__,O=ef(S,d);return O<0?(++this.size,S.push([d,m])):S[O][1]=m,this},Ro.prototype.clear=function wd(){this.size=0,this.__data__={hash:new Kn,map:new(Ae||$i),string:new Kn}},Ro.prototype.delete=function Bi(d){var m=Nl(this,d).delete(d);return this.size-=m?1:0,m},Ro.prototype.get=function Po(d){return Nl(this,d).get(d)},Ro.prototype.has=function vi(d){return Nl(this,d).has(d)},Ro.prototype.set=function bc(d,m){var S=Nl(this,d),O=S.size;return S.set(d,m),this.size+=S.size==O?0:1,this},va.prototype.add=va.prototype.push=function Qh(d){return this.__data__.set(d,ao),this},va.prototype.has=function wE(d){return this.__data__.has(d)},xc.prototype.clear=function $0(){this.__data__=new $i,this.size=0},xc.prototype.delete=function KI(d){var m=this.__data__,S=m.delete(d);return this.size=m.size,S},xc.prototype.get=function SE(d){return this.__data__.get(d)},xc.prototype.has=function EE(d){return this.__data__.has(d)},xc.prototype.set=function YI(d,m){var S=this.__data__;if(S instanceof $i){var O=S.__data__;if(!Ae||O.length0&&S(me)?m>1?ys(me,m-1,S,O,W):Ks(W,me):O||(W[W.length]=me)}return W}var Kp=Kb(),K0=Kb(!0);function ja(d,m){return d&&Kp(d,m,bs)}function Y0(d,m){return d&&K0(d,m,bs)}function Ed(d,m){return xt(m,function(S){return nl(d[S])})}function Jo(d,m){for(var S=0,O=(m=Wa(m,d)).length;null!=d&&Sm}function Tu(d,m){return null!=d&&Nn.call(d,m)}function CE(d,m){return null!=d&&m in Cn(d)}function nf(d,m,S){for(var O=S?Zi:Sn,W=d[0].length,Z=d.length,de=Z,me=Fe(Z),Ee=1/0,qe=[];de--;){var Ye=d[de];de&&m&&(Ye=si(Ye,Ys(m))),Ee=L(Ye.length,Ee),me[de]=!S&&(m||W>=120&&Ye.length>=120)?new va(de&&Ye):le}Ye=d[0];var nt=-1,wt=me[0];e:for(;++nt=me?Ee:Ee*("desc"==S[O]?-1:1)}return d.index-m.index}(Z,de,S)})}function Nb(d,m,S){for(var O=-1,W=m.length,Z={};++O-1;)me!==d&&h.call(me,Ee,1),h.call(d,Ee,1);return d}function J0(d,m){for(var S=d?m.length:0,O=S-1;S--;){var W=m[S];if(S==O||W!==Z){var Z=W;Jc(W)?h.call(d,W,1):Ou(d,W)}}return d}function Ru(d,m){return d+U(Q()*(m-d+1))}function Q0(d,m){var S="";if(!d||m<1||m>Qn)return S;do{m%2&&(S+=d),(m=U(m/2))&&(d+=d)}while(m);return S}function ti(d,m){return g_(nx(d,m,Lo),d+"")}function RE(d){return jp(ju(d))}function QI(d,m){var S=ju(d);return gf(S,Cu(m,0,S.length))}function Ns(d,m,S,O){if(!_r(d))return d;for(var W=-1,Z=(m=Wa(m,d)).length,de=Z-1,me=d;null!=me&&++WW?0:W+m),(S=S>W?W:S)<0&&(S+=W),W=m>S?0:S-m>>>0,m>>>=0;for(var Z=Fe(W);++O>>1,de=d[Z];null!==de&&!ia(de)&&(S?de<=m:de=ps){var qe=m?null:jE(d);if(qe)return Yh(qe);de=!1,W=Io,Ee=new va}else Ee=m?[]:me;e:for(;++O=O?d:Qo(d,m,S)}var zb=M||function(d){return pr.clearTimeout(d)};function Cd(d,m){if(m)return d.slice();var S=d.length,O=Os?Os(S):new d.constructor(S);return d.copy(O),O}function Dd(d){var m=new d.constructor(d.byteLength);return new yc(m).set(new yc(d)),m}function jb(d,m){var S=m?Dd(d.buffer):d.buffer;return new d.constructor(S,d.byteOffset,d.length)}function LE(d,m){if(d!==m){var S=d!==le,O=null===d,W=d==d,Z=ia(d),de=m!==le,me=null===m,Ee=m==m,qe=ia(m);if(!me&&!qe&&!Z&&d>m||Z&&de&&Ee&&!me&&!qe||O&&de&&Ee||!S&&Ee||!W)return 1;if(!O&&!Z&&!qe&&d1?S[W-1]:le,de=W>2?S[2]:le;for(Z=d.length>3&&"function"==typeof Z?(W--,Z):le,de&&yo(S[0],S[1],de)&&(Z=W<3?le:Z,W=1),m=Cn(m);++O-1?W[Z?m[de]:de]:le}}function zE(d){return Zc(function(m){var S=m.length,O=S,W=Fi.prototype.thru;for(d&&m.reverse();O--;){var Z=m[O];if("function"!=typeof Z)throw new vo(_i);if(W&&!de&&"wrapper"==hf(Z))var de=new Fi([],!0)}for(O=de?O:S;++O1&&yi.reverse(),Ye&&Eeme))return!1;var qe=Z.get(d),Ye=Z.get(m);if(qe&&Ye)return qe==m&&Ye==d;var nt=-1,wt=!0,Ht=S&di?new va:le;for(Z.set(d,m),Z.set(m,d);++nt-1&&d%1==0&&d1?"& ":"")+m[O],m=m.join(S>2?", ":" "),d.replace(F0,"{\n/* [wrapped with "+m+"] */\n")}(O,function tM(d,m){return Zr(lc,function(S){var O="_."+S[0];m&S[1]&&!Sn(d,O)&&d.push(O)}),d.sort()}(function Qb(d){var m=d.match(gu);return m?m[1].split(uo):[]}(O),S)))}function __(d){var m=0,S=0;return function(){var O=$(),W=cn-(O-S);if(S=O,W>0){if(++m>=du)return arguments[0]}else m=0;return d.apply(le,arguments)}}function gf(d,m){var S=-1,O=d.length,W=O-1;for(m=m===le?O:m;++S1?d[m-1]:le;return S="function"==typeof S?(d.pop(),S):le,_f(d,S)});function _m(d){var m=Y(d);return m.__chain__=!0,m}function E_(d,m){return m(d)}var oF=Zc(function(d){var m=d.length,S=m?d[0]:0,O=this.__wrapped__,W=function(Z){return Mu(Z,d)};return!(m>1||this.__actions__.length)&&O instanceof ln&&Jc(S)?((O=O.slice(S,+S+(m?1:0))).__actions__.push({func:E_,args:[W],thisArg:le}),new Fi(O,this.__chain__).thru(function(Z){return m&&!Z.length&&Z.push(le),Z})):this.thru(W)}),Ex=n_(function(d,m,S){Nn.call(d,S)?++d[S]:Ua(d,S,1)}),Ri=UE(um),AM=UE(hm);function Cx(d,m){return(yn(d)?Zr:Ga)(d,Ot(m,3))}function Dx(d,m){return(yn(d)?po:qp)(d,Ot(m,3))}var IM=n_(function(d,m,S){Nn.call(d,S)?d[S].push(m):Ua(d,S,[m])}),Tx=ti(function(d,m,S){var O=-1,W="function"==typeof m,Z=Oo(d)?Fe(d.length):[];return Ga(d,function(de){Z[++O]=W?Ni(m,de,S):Au(de,m,S)}),Z}),aF=n_(function(d,m,S){Ua(d,S,m)});function C_(d,m){return(yn(d)?si:IE)(d,Ot(m,3))}var ym=n_(function(d,m,S){d[S?0:1].push(m)},function(){return[[],[]]}),cF=ti(function(d,m){if(null==d)return[];var S=m.length;return S>1&&yo(d,m[0],m[1])?m=[]:S>2&&yo(m[0],m[1],m[2])&&(m=[m[0]]),Xp(d,ys(m,1),[])}),Hu=D||function(){return pr.Date.now()};function bm(d,m,S){return m=S?le:m,Xc(d,un,le,le,le,le,m=d&&null==m?d.length:m)}function T_(d,m){var S;if("function"!=typeof m)throw new vo(_i);return d=Un(d),function(){return--d>0&&(S=m.apply(this,arguments)),d<=1&&(m=le),S}}var xm=ti(function(d,m,S){var O=ks;if(S.length){var W=_c(S,Ll(xm));O|=Yr}return Xc(d,O,m,S,W)}),Ul=ti(function(d,m,S){var O=ks|Fa;if(S.length){var W=_c(S,Ll(Ul));O|=Yr}return Xc(m,O,d,S,W)});function bf(d,m,S){var O,W,Z,de,me,Ee,qe=0,Ye=!1,nt=!1,wt=!0;if("function"!=typeof d)throw new vo(_i);function Ht(Pr){var Ya=O,Xa=W;return O=W=le,qe=Pr,de=d.apply(Xa,Ya)}function dn(Pr){var Ya=Pr-Ee;return Ee===le||Ya>=m||Ya<0||nt&&Pr-qe>=Z}function ri(){var Pr=Hu();if(dn(Pr))return yi(Pr);me=Ad(ri,function zn(Pr){var D1=m-(Pr-Ee);return nt?L(D1,Z-(Pr-qe)):D1}(Pr))}function yi(Pr){return me=le,wt&&O?Ht(Pr):(O=W=le,de)}function to(){var Pr=Hu(),Ya=dn(Pr);if(O=arguments,W=this,Ee=Pr,Ya){if(me===le)return function pn(Pr){return qe=Pr,me=Ad(ri,m),Ye?Ht(Pr):de}(Ee);if(nt)return zb(me),me=Ad(ri,m),Ht(Ee)}return me===le&&(me=Ad(ri,m)),de}return m=wa(m)||0,_r(S)&&(Ye=!!S.leading,Z=(nt="maxWait"in S)?V(wa(S.maxWait)||0,m):Z,wt="trailing"in S?!!S.trailing:wt),to.cancel=function No(){me!==le&&zb(me),qe=0,O=Ee=W=me=le},to.flush=function Bo(){return me===le?de:yi(Hu())},to}var OM=ti(function(d,m){return za(d,1,m)}),A_=ti(function(d,m,S){return za(d,wa(m)||0,S)});function na(d,m){if("function"!=typeof d||null!=m&&"function"!=typeof m)throw new vo(_i);var S=function(){var O=arguments,W=m?m.apply(this,O):O[0],Z=S.cache;if(Z.has(W))return Z.get(W);var de=d.apply(this,O);return S.cache=Z.set(W,de)||Z,de};return S.cache=new(na.Cache||Ro),S}function xf(d){if("function"!=typeof d)throw new vo(_i);return function(){var m=arguments;switch(m.length){case 0:return!d.call(this);case 1:return!d.call(this,m[0]);case 2:return!d.call(this,m[0],m[1]);case 3:return!d.call(this,m[0],m[1],m[2])}return!d.apply(this,m)}}na.Cache=Ro;var LM=Ub(function(d,m){var S=(m=1==m.length&&yn(m[0])?si(m[0],Ys(Ot())):si(ys(m,1),Ys(Ot()))).length;return ti(function(O){for(var W=-1,Z=L(O.length,S);++W=m}),Rd=Kc(function(){return arguments}())?Kc:function(d){return Cr(d)&&Nn.call(d,"callee")&&!l.call(d,"callee")},yn=Fe.isArray,el=Mt?Ys(Mt):function ku(d){return Cr(d)&&Zs(d)==hc};function Oo(d){return null!=d&&Em(d.length)&&!nl(d)}function Rr(d){return Cr(d)&&Oo(d)}var zl=I||Sf,P_=Vp?Ys(Vp):function Iu(d){return Cr(d)&&Zs(d)==_t};function N_(d){if(!Cr(d))return!1;var m=Zs(d);return m==zc||m==uu||"string"==typeof d.message&&"string"==typeof d.name&&!Gu(d)}function nl(d){if(!_r(d))return!1;var m=Zs(d);return m==hu||m==Ep||m==$o||m==dr}function Bx(d){return"number"==typeof d&&d==Un(d)}function Em(d){return"number"==typeof d&&d>-1&&d%1==0&&d<=Qn}function _r(d){var m=typeof d;return null!=d&&("object"==m||"function"==m)}function Cr(d){return null!=d&&"object"==typeof d}var Od=Kh?Ys(Kh):function X0(d){return Cr(d)&&Vs(d)==lo};function qM(d){return"number"==typeof d||Cr(d)&&Zs(d)==ad}function Gu(d){if(!Cr(d)||Zs(d)!=Oa)return!1;var m=rn(d);if(null===m)return!0;var S=Nn.call(m,"constructor")&&m.constructor;return"function"==typeof S&&S instanceof S&&_d.call(S)==Mb}var Mm=ut?Ys(ut):function AE(d){return Cr(d)&&Zs(d)==ur},B_=Yi?Ys(Yi):function Ze(d){return Cr(d)&&Vs(d)==qo};function Cm(d){return"string"==typeof d||!yn(d)&&Cr(d)&&Zs(d)==cd}function ia(d){return"symbol"==typeof d||Cr(d)&&Zs(d)==Ih}var eo=Ei?Ys(Ei):function XI(d){return Cr(d)&&Em(d.length)&&!!Xi[Zs(d)]},ZM=df(Lb),JM=df(function(d,m){return d<=m});function Ux(d){if(!d)return[];if(Oo(d))return Cm(d)?_o(d):Bs(d);if(_&&d[_])return function Hp(we){for(var Ge,Fe=[];!(Ge=we.next()).done;)Fe.push(Ge.value);return Fe}(d[_]());var m=Vs(d);return(m==lo?Fr:m==qo?Yh:ju)(d)}function Mc(d){return d?(d=wa(d))===$t||d===-$t?(d<0?-1:1)*In:d==d?d:0:0===d?d:0}function Un(d){var m=Mc(d),S=m%1;return m==m?S?m-S:m:0}function zx(d){return d?Cu(Un(d),0,Fn):0}function wa(d){if("number"==typeof d)return d;if(ia(d))return fn;if(_r(d)){var m="function"==typeof d.valueOf?d.valueOf():d;d=_r(m)?m+"":m}if("string"!=typeof d)return 0===d?d:+d;d=d.replace(wi,"");var S=_b.test(d);return S||yb.test(d)?fr(d.slice(2),S?2:8):gb.test(d)?fn:+d}function Dn(d){return $a(d,ns(d))}function Pi(d){return null==d?"":ea(d)}var Gx=Td(function(d,m){if(Nu(m)||Oo(m))$a(m,bs(m),d);else for(var S in m)Nn.call(m,S)&&Eu(d,S,m[S])}),jx=Td(function(d,m){$a(m,ns(m),d)}),Dm=Td(function(d,m,S,O){$a(m,ns(m),d,O)}),Wx=Td(function(d,m,S,O){$a(m,bs(m),d,O)}),QM=Zc(Mu),eC=ti(function(d,m){d=Cn(d);var S=-1,O=m.length,W=O>2?m[2]:le;for(W&&yo(m[0],m[1],W)&&(O=1);++S1),Z}),$a(d,Qs(d),S),O&&(S=Zo(S,Tn|Sl|_e,WE));for(var W=m.length;W--;)Ou(S,m[W]);return S}),aC=Zc(function(d,m){return null==d?{}:function rf(d,m){return Nb(d,m,function(S,O){return Xx(d,O)})}(d,m)});function t1(d,m){if(null==d)return{};var S=si(Qs(d),function(O){return[O]});return m=Ot(m),Nb(d,S,function(O,W){return m(O,W[0])})}var r1=Yb(bs),U_=Yb(ns);function ju(d){return null==d?[]:Fl(d,bs(d))}var o1=cf(function(d,m,S){return m=m.toLowerCase(),d+(S?a1(m):m)});function a1(d){return Im(Pi(d).toLowerCase())}function c1(d){return(d=Pi(d))&&d.replace(bb,go).replace(Ut,"")}var wf=cf(function(d,m,S){return d+(S?"-":"")+m.toLowerCase()}),W_=cf(function(d,m,S){return d+(S?" ":"")+m.toLowerCase()}),km=em("toLowerCase"),uC=cf(function(d,m,S){return d+(S?"_":"")+m.toLowerCase()}),u1=cf(function(d,m,S){return d+(S?" ":"")+Im(m)}),X_=cf(function(d,m,S){return d+(S?" ":"")+m.toUpperCase()}),Im=em("toUpperCase");function m1(d,m,S){return d=Pi(d),(m=S?le:m)===le?function Fo(we){return U0.test(we)}(d)?function Zh(we){return we.match(V0)||[]}(d):function Hn(we){return we.match(pb)||[]}(d):d.match(m)||[]}var g1=ti(function(d,m){try{return Ni(d,le,m)}catch(S){return N_(S)?S:new kn(S)}}),_C=Zc(function(d,m){return Zr(m,function(S){S=qa(S),Ua(d,S,xm(d[S],d))}),d});function Z_(d){return function(){return d}}var yC=zE(),bC=zE(!0);function Lo(d){return d}function Q_(d){return kE("function"==typeof d?d:Zo(d,Tn))}var ev=ti(function(d,m){return function(S){return Au(S,d,m)}}),wC=ti(function(d,m){return function(S){return Au(d,S,m)}});function tv(d,m,S){var O=bs(m),W=Ed(m,O);null==S&&(!_r(m)||!W.length&&O.length)&&(S=m,m=d,d=this,W=Ed(m,bs(m)));var Z=!(_r(S)&&"chain"in S&&!S.chain),de=nl(d);return Zr(W,function(me){var Ee=m[me];d[me]=Ee,de&&(d.prototype[me]=function(){var qe=this.__chain__;if(Z||qe){var Ye=d(this.__wrapped__);return(Ye.__actions__=Bs(this.__actions__)).push({func:Ee,args:arguments,thisArg:d}),Ye.__chain__=qe,Ye}return Ee.apply(d,Ks([this.value()],arguments))})}),d}function nv(){}var EC=o_(si),iv=o_(Nr),MC=o_(Ji);function y1(d){return pf(d)?gc(qa(d)):function ya(d){return function(m){return Jo(m,d)}}(d)}var rv=c_(),Rm=c_(!0);function b1(){return[]}function Sf(){return!1}var rl=s_(function(d,m){return d+m},0),Pm=Js("ceil"),Om=s_(function(d,m){return d/m},1),Ef=Js("floor"),AC=s_(function(d,m){return d*m},1),yF=Js("round"),kC=s_(function(d,m){return d-m},0);return Y.after=function PM(d,m){if("function"!=typeof m)throw new vo(_i);return d=Un(d),function(){if(--d<1)return m.apply(this,arguments)}},Y.ary=bm,Y.assign=Gx,Y.assignIn=jx,Y.assignInWith=Dm,Y.assignWith=Wx,Y.at=QM,Y.before=T_,Y.bind=xm,Y.bindAll=_C,Y.bindKey=Ul,Y.castArray=function Lx(){if(!arguments.length)return[];var d=arguments[0];return yn(d)?d:[d]},Y.chain=_m,Y.chunk=function cm(d,m,S){m=(S?yo(d,m,S):m===le)?1:V(Un(m),0);var O=null==d?0:d.length;if(!O||m<1)return[];for(var W=0,Z=0,de=Fe(P(O/m));WW?0:W+S),(O=O===le||O>W?W:Un(O))<0&&(O+=W),O=S>O?0:zx(O);S>>0)?(d=Pi(d))&&("string"==typeof m||null!=m&&!Mm(m))&&!(m=ea(m))&&ga(d)?Ol(_o(d),0,S):d.split(m,S):[]},Y.spread=function BM(d,m){if("function"!=typeof d)throw new vo(_i);return m=null==m?0:V(Un(m),0),ti(function(S){var O=S[m],W=Ol(S,0,m);return O&&Ks(W,O),Ni(d,this,W)})},Y.tail=function Ec(d){var m=null==d?0:d.length;return m?Qo(d,1,m):[]},Y.take=function mM(d,m,S){return d&&d.length?Qo(d,0,(m=S||m===le?1:Un(m))<0?0:m):[]},Y.takeRight=function gM(d,m,S){var O=null==d?0:d.length;return O?Qo(d,(m=O-(m=S||m===le?1:Un(m)))<0?0:m,O):[]},Y.takeRightWhile=function _M(d,m){return d&&d.length?ba(d,Ot(m,3),!1,!0):[]},Y.takeWhile=function vM(d,m){return d&&d.length?ba(d,Ot(m,3)):[]},Y.tap=function S_(d,m){return m(d),d},Y.throttle=function VM(d,m,S){var O=!0,W=!0;if("function"!=typeof d)throw new vo(_i);return _r(S)&&(O="leading"in S?!!S.leading:O,W="trailing"in S?!!S.trailing:W),bf(d,m,{leading:O,maxWait:m,trailing:W})},Y.thru=E_,Y.toArray=Ux,Y.toPairs=r1,Y.toPairsIn=U_,Y.toPath=function E1(d){return yn(d)?si(d,qa):ia(d)?[d]:Bs(Vl(Pi(d)))},Y.toPlainObject=Dn,Y.transform=function s1(d,m,S){var O=yn(d),W=O||zl(d)||eo(d);if(m=Ot(m,4),null==S){var Z=d&&d.constructor;S=W?O?new Z:[]:_r(d)&&nl(Z)?ui(rn(d)):{}}return(W?Zr:ja)(d,function(de,me,Ee){return m(S,de,me,Ee)}),S},Y.unary=function R_(d){return bm(d,1)},Y.union=yM,Y.unionBy=bM,Y.unionWith=vx,Y.uniq=function xM(d){return d&&d.length?Sc(d):[]},Y.uniqBy=function wM(d,m){return d&&d.length?Sc(d,Ot(m,2)):[]},Y.uniqWith=function SM(d,m){return m="function"==typeof m?m:le,d&&d.length?Sc(d,le,m):[]},Y.unset=function z_(d,m){return null==d||Ou(d,m)},Y.unzip=w_,Y.unzipWith=_f,Y.update=function mF(d,m,S){return null==d?d:af(d,m,Md(S))},Y.updateWith=function G_(d,m,S,O){return O="function"==typeof O?O:le,null==d?d:af(d,m,Md(S),O)},Y.values=ju,Y.valuesIn=function gF(d){return null==d?[]:Fl(d,ns(d))},Y.without=Qc,Y.words=m1,Y.wrap=function HM(d,m){return I_(Md(m),d)},Y.xor=vf,Y.xorBy=yx,Y.xorWith=bx,Y.zip=xx,Y.zipObject=function iF(d,m){return Hb(d||[],m||[],Eu)},Y.zipObjectDeep=function rF(d,m){return Hb(d||[],m||[],Ns)},Y.zipWith=sF,Y.entries=r1,Y.entriesIn=U_,Y.extend=jx,Y.extendWith=Dm,tv(Y,Y),Y.add=rl,Y.attempt=g1,Y.camelCase=o1,Y.capitalize=a1,Y.ceil=Pm,Y.clamp=function ie(d,m,S){return S===le&&(S=m,m=le),S!==le&&(S=(S=wa(S))==S?S:0),m!==le&&(m=(m=wa(m))==m?m:0),Cu(wa(d),m,S)},Y.clone=function UM(d){return Zo(d,_e)},Y.cloneDeep=function lF(d){return Zo(d,Tn|_e)},Y.cloneDeepWith=function zM(d,m){return Zo(d,Tn|_e,m="function"==typeof m?m:le)},Y.cloneWith=function Nx(d,m){return Zo(d,_e,m="function"==typeof m?m:le)},Y.conformsTo=function Fd(d,m){return null==m||kb(d,m,bs(m))},Y.deburr=c1,Y.defaultTo=function J_(d,m){return null==d||d!=d?m:d},Y.divide=Om,Y.endsWith=function Am(d,m,S){d=Pi(d),m=ea(m);var O=d.length,W=S=S===le?O:Cu(Un(S),0,O);return(S-=m.length)>=0&&d.slice(S,W)==m},Y.eq=Ka,Y.escape=function Wu(d){return(d=Pi(d))&&Mi.test(d)?d.replace(fu,Yo):d},Y.escapeRegExp=function j_(d){return(d=Pi(d))&&wn.test(d)?d.replace(Dl,"\\$&"):d},Y.every=function M_(d,m,S){var O=yn(d)?Nr:Ib;return S&&yo(d,m,S)&&(m=le),O(d,Ot(m,3))},Y.find=Ri,Y.findIndex=um,Y.findKey=function hF(d,m){return fd(d,Ot(m,3),ja)},Y.findLast=AM,Y.findLastIndex=hm,Y.findLastKey=function qx(d,m){return fd(d,Ot(m,3),Y0)},Y.floor=Ef,Y.forEach=Cx,Y.forEachRight=Dx,Y.forIn=function Kx(d,m){return null==d?d:Kp(d,Ot(m,3),ns)},Y.forInRight=function ts(d,m){return null==d?d:K0(d,Ot(m,3),ns)},Y.forOwn=function nC(d,m){return d&&ja(d,Ot(m,3))},Y.forOwnRight=function V_(d,m){return d&&Y0(d,Ot(m,3))},Y.get=Yx,Y.gt=zu,Y.gte=_n,Y.has=function fF(d,m){return null!=d&&ex(d,m,Tu)},Y.hasIn=Xx,Y.head=hx,Y.identity=Lo,Y.includes=function FM(d,m,S,O){d=Oo(d)?d:ju(d),S=S&&!O?Un(S):0;var W=d.length;return S<0&&(S=V(W+S,0)),Cm(d)?S<=W&&d.indexOf(m,S)>-1:!!W&&pa(d,m,S)>-1},Y.indexOf=function oM(d,m,S){var O=null==d?0:d.length;if(!O)return-1;var W=null==S?0:Un(S);return W<0&&(W=V(O+W,0)),pa(d,m,W)},Y.inRange=function Gl(d,m,S){return m=Mc(m),S===le?(S=m,m=0):S=Mc(S),function or(d,m,S){return d>=L(m,S)&&d=-Qn&&d<=Qn},Y.isSet=B_,Y.isString=Cm,Y.isSymbol=ia,Y.isTypedArray=eo,Y.isUndefined=function YM(d){return d===le},Y.isWeakMap=function Hx(d){return Cr(d)&&Vs(d)==uc},Y.isWeakSet=function XM(d){return Cr(d)&&"[object WeakSet]"==Zs(d)},Y.join=function Vu(d,m){return null==d?"":B.call(d,m)},Y.kebabCase=wf,Y.last=xa,Y.lastIndexOf=function aM(d,m,S){var O=null==d?0:d.length;if(!O)return-1;var W=O;return S!==le&&(W=(W=Un(S))<0?V(O+W,0):L(W,O-1)),m==m?function Eb(we,Ge,Fe){for(var Ft=Fe+1;Ft--;)if(we[Ft]===Ge)return Ft;return Ft}(d,m,W):Va(d,Jr,W,!0)},Y.lowerCase=W_,Y.lowerFirst=km,Y.lt=ZM,Y.lte=JM,Y.max=function CC(d){return d&&d.length?Du(d,Lo,Yp):le},Y.maxBy=function M1(d,m){return d&&d.length?Du(d,Ot(m,2),Yp):le},Y.mean=function C1(d){return kl(d,Lo)},Y.meanBy=function DC(d,m){return kl(d,Ot(m,2))},Y.min=function TC(d){return d&&d.length?Du(d,Lo,Lb):le},Y.minBy=function Mf(d,m){return d&&d.length?Du(d,Ot(m,2),Lb):le},Y.stubArray=b1,Y.stubFalse=Sf,Y.stubObject=function vF(){return{}},Y.stubString=function x1(){return""},Y.stubTrue=function w1(){return!0},Y.multiply=AC,Y.nth=function nF(d,m){return d&&d.length?Hr(d,Un(m)):le},Y.noConflict=function v1(){return pr._===this&&(pr._=Jh),this},Y.noop=nv,Y.now=Hu,Y.pad=function l1(d,m,S){d=Pi(d);var O=(m=Un(m))?pd(d):0;if(!m||O>=m)return d;var W=(m-O)/2;return lf(U(W),S)+d+lf(P(W),S)},Y.padEnd=function $_(d,m,S){d=Pi(d);var O=(m=Un(m))?pd(d):0;return m&&Om){var O=d;d=m,m=O}if(S||d%1||m%1){var W=Q();return L(d+W*(m-d+$h("1e-"+((W+"").length-1))),m)}return Ru(d,m)},Y.reduce=function Ax(d,m,S){var O=yn(d)?Br:ma,W=arguments.length<3;return O(d,Ot(m,4),S,W,Ga)},Y.reduceRight=function kx(d,m,S){var O=yn(d)?Al:ma,W=arguments.length<3;return O(d,Ot(m,4),S,W,qp)},Y.repeat=function d1(d,m,S){return m=(S?yo(d,m,S):m===le)?1:Un(m),Q0(Pi(d),m)},Y.replace=function Y_(){var d=arguments,m=Pi(d[0]);return d.length<3?m:m.replace(d[1],d[2])},Y.result=function cC(d,m,S){var O=-1,W=(m=Wa(m,d)).length;for(W||(W=1,d=le);++OQn)return[];var S=Fn,O=L(d,Fn);m=Ot(m),d-=Fn;for(var W=Il(O,m);++S=Z)return d;var me=S-pd(O);if(me<1)return O;var Ee=de?Ol(de,0,me).join(""):d.slice(0,me);if(W===le)return Ee+O;if(de&&(me+=Ee.length-me),Mm(W)){if(d.slice(me).search(W)){var qe,Ye=Ee;for(W.global||(W=Su(W.source,Pi(La.exec(W))+"g")),W.lastIndex=0;qe=W.exec(Ye);)var nt=qe.index;Ee=Ee.slice(0,nt===le?me:nt)}}else if(d.indexOf(ea(W),me)!=me){var wt=Ee.lastIndexOf(W);wt>-1&&(Ee=Ee.slice(0,wt))}return Ee+O},Y.unescape=function _F(d){return(d=Pi(d))&&Tp.test(d)?d.replace(ki,Xh):d},Y.uniqueId=function sv(d){var m=++vd;return Pi(d)+m},Y.upperCase=X_,Y.upperFirst=Im,Y.each=Cx,Y.eachRight=Dx,Y.first=hx,tv(Y,function(){var d={};return ja(Y,function(m,S){Nn.call(Y.prototype,S)||(d[S]=m)}),d}(),{chain:!1}),Y.VERSION="4.17.19",Zr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(d){Y[d].placeholder=Y}),Zr(["drop","take"],function(d,m){ln.prototype[d]=function(S){S=S===le?1:V(Un(S),0);var O=this.__filtered__&&!m?new ln(this):this.clone();return O.__filtered__?O.__takeCount__=L(S,O.__takeCount__):O.__views__.push({size:L(S,Fn),type:d+(O.__dir__<0?"Right":"")}),O},ln.prototype[d+"Right"]=function(S){return this.reverse()[d](S).reverse()}}),Zr(["filter","map","takeWhile"],function(d,m){var S=m+1,O=1==S||3==S;ln.prototype[d]=function(W){var Z=this.clone();return Z.__iteratees__.push({iteratee:Ot(W,3),type:S}),Z.__filtered__=Z.__filtered__||O,Z}}),Zr(["head","last"],function(d,m){var S="take"+(m?"Right":"");ln.prototype[d]=function(){return this[S](1).value()[0]}}),Zr(["initial","tail"],function(d,m){var S="drop"+(m?"":"Right");ln.prototype[d]=function(){return this.__filtered__?new ln(this):this[S](1)}}),ln.prototype.compact=function(){return this.filter(Lo)},ln.prototype.find=function(d){return this.filter(d).head()},ln.prototype.findLast=function(d){return this.reverse().find(d)},ln.prototype.invokeMap=ti(function(d,m){return"function"==typeof d?new ln(this):this.map(function(S){return Au(S,d,m)})}),ln.prototype.reject=function(d){return this.filter(xf(Ot(d)))},ln.prototype.slice=function(d,m){d=Un(d);var S=this;return S.__filtered__&&(d>0||m<0)?new ln(S):(d<0?S=S.takeRight(-d):d&&(S=S.drop(d)),m!==le&&(S=(m=Un(m))<0?S.dropRight(-m):S.take(m-d)),S)},ln.prototype.takeRightWhile=function(d){return this.reverse().takeWhile(d).reverse()},ln.prototype.toArray=function(){return this.take(Fn)},ja(ln.prototype,function(d,m){var S=/^(?:filter|find|map|reject)|While$/.test(m),O=/^(?:head|last)$/.test(m),W=Y[O?"take"+("last"==m?"Right":""):m],Z=O||/^find/.test(m);W&&(Y.prototype[m]=function(){var de=this.__wrapped__,me=O?[1]:arguments,Ee=de instanceof ln,qe=me[0],Ye=Ee||yn(de),nt=function(ri){var yi=W.apply(Y,Ks([ri],me));return O&&wt?yi[0]:yi};Ye&&S&&"function"==typeof qe&&1!=qe.length&&(Ee=Ye=!1);var wt=this.__chain__,pn=Z&&!wt,zn=Ee&&!this.__actions__.length;if(!Z&&Ye){de=zn?de:new ln(this);var dn=d.apply(de,me);return dn.__actions__.push({func:E_,args:[nt],thisArg:le}),new Fi(dn,wt)}return pn&&zn?d.apply(this,me):(dn=this.thru(nt),pn?O?dn.value()[0]:dn.value():dn)})}),Zr(["pop","push","shift","sort","splice","unshift"],function(d){var m=vc[d],S=/^(?:push|sort|unshift)$/.test(d)?"tap":"thru",O=/^(?:pop|shift)$/.test(d);Y.prototype[d]=function(){var W=arguments;if(O&&!this.__chain__){var Z=this.value();return m.apply(yn(Z)?Z:[],W)}return this[S](function(de){return m.apply(yn(de)?de:[],W)})}}),ja(ln.prototype,function(d,m){var S=Y[m];if(S){var O=S.name+"";Nn.call(be,O)||(be[O]=[]),be[O].push({name:m,func:S})}}),be[r_(le,Fa).name]=[{name:"wrapper",func:le}],ln.prototype.clone=function es(){var d=new ln(this.__wrapped__);return d.__actions__=Bs(this.__actions__),d.__dir__=this.__dir__,d.__filtered__=this.__filtered__,d.__iteratees__=Bs(this.__iteratees__),d.__takeCount__=this.__takeCount__,d.__views__=Bs(this.__views__),d},ln.prototype.reverse=function vs(){if(this.__filtered__){var d=new ln(this);d.__dir__=-1,d.__filtered__=!0}else(d=this.clone()).__dir__*=-1;return d},ln.prototype.value=function Ls(){var d=this.__wrapped__.value(),m=this.__dir__,S=yn(d),O=m<0,W=S?d.length:0,Z=function KE(d,m,S){for(var O=-1,W=S.length;++O=this.__values__.length;return{done:d,value:d?le:this.__values__[this.__index__++]}},Y.prototype.plant=function DM(d){for(var m,S=this;S instanceof oi;){var O=nM(S);O.__index__=0,O.__values__=le,m?W.__wrapped__=O:m=O;var W=O;S=S.__wrapped__}return W.__wrapped__=d,m},Y.prototype.reverse=function Sx(){var d=this.__wrapped__;if(d instanceof ln){var m=d;return this.__actions__.length&&(m=new ln(this)),(m=m.reverse()).__actions__.push({func:E_,args:[gm],thisArg:le}),new Fi(m,this.__chain__)}return this.thru(gm)},Y.prototype.toJSON=Y.prototype.valueOf=Y.prototype.value=function vm(){return t_(this.__wrapped__,this.__actions__)},Y.prototype.first=Y.prototype.head,_&&(Y.prototype[_]=function CM(){return this}),Y}();pr._=md,(qr=function(){return md}.call(ka,dt,ka,Aa))!==le&&(Aa.exports=qr)}.call(this)}},Aa=>{Aa(Aa.s=1658)}]); \ No newline at end of file diff --git a/main.b0a2d2c8312e10f4.js b/main.b0a2d2c8312e10f4.js deleted file mode 100644 index 38d90c0..0000000 --- a/main.b0a2d2c8312e10f4.js +++ /dev/null @@ -1 +0,0 @@ -(self.webpackChunkscrublandeux=self.webpackChunkscrublandeux||[]).push([[179],{1658:(Aa,ka,dt)=>{"use strict";function qr(n){return"function"==typeof n}let le=!1;const pt={Promise:void 0,set useDeprecatedSynchronousErrorHandling(n){if(n){const e=new Error;console.warn("DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \n"+e.stack)}else le&&console.log("RxJS: Back to a better error behavior. Thank you. <3");le=n},get useDeprecatedSynchronousErrorHandling(){return le}};function ps(n){setTimeout(()=>{throw n},0)}const Ia={closed:!0,next(n){},error(n){if(pt.useDeprecatedSynchronousErrorHandling)throw n;ps(n)},complete(){}},_i=Array.isArray||(n=>n&&"number"==typeof n.length);function ao(n){return null!==n&&"object"==typeof n}const Kr=(()=>{function n(e){return Error.call(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((t,i)=>`${i+1}) ${t.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e,this}return n.prototype=Object.create(Error.prototype),n})();class Tn{constructor(e){this.closed=!1,this._parentOrParents=null,this._subscriptions=null,e&&(this._unsubscribe=e)}unsubscribe(){let e;if(this.closed)return;let{_parentOrParents:t,_unsubscribe:i,_subscriptions:r}=this;if(this.closed=!0,this._parentOrParents=null,this._subscriptions=null,t instanceof Tn)t.remove(this);else if(null!==t)for(let s=0;se.concat(t instanceof Kr?t.errors:t),[])}Tn.EMPTY=((n=new Tn).closed=!0,n);const _e="function"==typeof Symbol?Symbol("rxSubscriber"):"@@rxSubscriber_"+Math.random();class di extends Tn{constructor(e,t,i){switch(super(),this.syncErrorValue=null,this.syncErrorThrown=!1,this.syncErrorThrowable=!1,this.isStopped=!1,arguments.length){case 0:this.destination=Ia;break;case 1:if(!e){this.destination=Ia;break}if("object"==typeof e){e instanceof di?(this.syncErrorThrowable=e.syncErrorThrowable,this.destination=e,e.add(this)):(this.syncErrorThrowable=!0,this.destination=new ks(this,e));break}default:this.syncErrorThrowable=!0,this.destination=new ks(this,e,t,i)}}[_e](){return this}static create(e,t,i){const r=new di(e,t,i);return r.syncErrorThrowable=!1,r}next(e){this.isStopped||this._next(e)}error(e){this.isStopped||(this.isStopped=!0,this._error(e))}complete(){this.isStopped||(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe())}_next(e){this.destination.next(e)}_error(e){this.destination.error(e),this.unsubscribe()}_complete(){this.destination.complete(),this.unsubscribe()}_unsubscribeAndRecycle(){const{_parentOrParents:e}=this;return this._parentOrParents=null,this.unsubscribe(),this.closed=!1,this.isStopped=!1,this._parentOrParents=e,this}}class ks extends di{constructor(e,t,i,r){super(),this._parentSubscriber=e;let s,o=this;qr(t)?s=t:t&&(s=t.next,i=t.error,r=t.complete,t!==Ia&&(o=Object.create(t),qr(o.unsubscribe)&&this.add(o.unsubscribe.bind(o)),o.unsubscribe=this.unsubscribe.bind(this))),this._context=o,this._next=s,this._error=i,this._complete=r}next(e){if(!this.isStopped&&this._next){const{_parentSubscriber:t}=this;pt.useDeprecatedSynchronousErrorHandling&&t.syncErrorThrowable?this.__tryOrSetError(t,this._next,e)&&this.unsubscribe():this.__tryOrUnsub(this._next,e)}}error(e){if(!this.isStopped){const{_parentSubscriber:t}=this,{useDeprecatedSynchronousErrorHandling:i}=pt;if(this._error)i&&t.syncErrorThrowable?(this.__tryOrSetError(t,this._error,e),this.unsubscribe()):(this.__tryOrUnsub(this._error,e),this.unsubscribe());else if(t.syncErrorThrowable)i?(t.syncErrorValue=e,t.syncErrorThrown=!0):ps(e),this.unsubscribe();else{if(this.unsubscribe(),i)throw e;ps(e)}}}complete(){if(!this.isStopped){const{_parentSubscriber:e}=this;if(this._complete){const t=()=>this._complete.call(this._context);pt.useDeprecatedSynchronousErrorHandling&&e.syncErrorThrowable?(this.__tryOrSetError(e,t),this.unsubscribe()):(this.__tryOrUnsub(t),this.unsubscribe())}else this.unsubscribe()}}__tryOrUnsub(e,t){try{e.call(this._context,t)}catch(i){if(this.unsubscribe(),pt.useDeprecatedSynchronousErrorHandling)throw i;ps(i)}}__tryOrSetError(e,t,i){if(!pt.useDeprecatedSynchronousErrorHandling)throw new Error("bad call");try{t.call(this._context,i)}catch(r){return pt.useDeprecatedSynchronousErrorHandling?(e.syncErrorValue=r,e.syncErrorThrown=!0,!0):(ps(r),!0)}return!1}_unsubscribe(){const{_parentSubscriber:e}=this;this._context=null,this._parentSubscriber=null,e.unsubscribe()}}const ms="function"==typeof Symbol&&Symbol.observable||"@@observable";function Is(n){return n}function Sr(n){return 0===n.length?Is:1===n.length?n[0]:function(t){return n.reduce((i,r)=>r(i),t)}}let un=(()=>{class n{constructor(t){this._isScalar=!1,t&&(this._subscribe=t)}lift(t){const i=new n;return i.source=this,i.operator=t,i}subscribe(t,i,r){const{operator:s}=this,o=function El(n,e,t){if(n){if(n instanceof di)return n;if(n[_e])return n[_e]()}return n||e||t?new di(n,e,t):new di(Ia)}(t,i,r);if(o.add(s?s.call(o,this.source):this.source||pt.useDeprecatedSynchronousErrorHandling&&!o.syncErrorThrowable?this._subscribe(o):this._trySubscribe(o)),pt.useDeprecatedSynchronousErrorHandling&&o.syncErrorThrowable&&(o.syncErrorThrowable=!1,o.syncErrorThrown))throw o.syncErrorValue;return o}_trySubscribe(t){try{return this._subscribe(t)}catch(i){pt.useDeprecatedSynchronousErrorHandling&&(t.syncErrorThrown=!0,t.syncErrorValue=i),function Fa(n){for(;n;){const{closed:e,destination:t,isStopped:i}=n;if(e||i)return!1;n=t&&t instanceof di?t:null}return!0}(t)?t.error(i):console.warn(i)}}forEach(t,i){return new(i=Ra(i))((r,s)=>{let o;o=this.subscribe(a=>{try{t(a)}catch(c){s(c),o&&o.unsubscribe()}},s,r)})}_subscribe(t){const{source:i}=this;return i&&i.subscribe(t)}[ms](){return this}pipe(...t){return 0===t.length?this:Sr(t)(this)}toPromise(t){return new(t=Ra(t))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=e=>new n(e),n})();function Ra(n){if(n||(n=pt.Promise||Promise),!n)throw new Error("no Promise impl found");return n}const Pa=(()=>{function n(){return Error.call(this),this.message="object unsubscribed",this.name="ObjectUnsubscribedError",this}return n.prototype=Object.create(Error.prototype),n})();class Ws extends Tn{constructor(e,t){super(),this.subject=e,this.subscriber=t,this.closed=!1}unsubscribe(){if(this.closed)return;this.closed=!0;const e=this.subject,t=e.observers;if(this.subject=null,!t||0===t.length||e.isStopped||e.closed)return;const i=t.indexOf(this.subscriber);-1!==i&&t.splice(i,1)}}class du extends di{constructor(e){super(e),this.destination=e}}let cn=(()=>{class n extends un{constructor(){super(),this.observers=[],this.closed=!1,this.isStopped=!1,this.hasError=!1,this.thrownError=null}[_e](){return new du(this)}lift(t){const i=new od(this,this);return i.operator=t,i}next(t){if(this.closed)throw new Pa;if(!this.isStopped){const{observers:i}=this,r=i.length,s=i.slice();for(let o=0;onew od(e,t),n})();class od extends cn{constructor(e,t){super(),this.destination=e,this.source=t}next(e){const{destination:t}=this;t&&t.next&&t.next(e)}error(e){const{destination:t}=this;t&&t.error&&this.destination.error(e)}complete(){const{destination:e}=this;e&&e.complete&&this.destination.complete()}_subscribe(e){const{source:t}=this;return t?this.source.subscribe(e):Tn.EMPTY}}function cc(n){return n&&"function"==typeof n.schedule}class Pt extends di{constructor(e,t,i){super(),this.parent=e,this.outerValue=t,this.outerIndex=i,this.index=0}_next(e){this.parent.notifyNext(this.outerValue,e,this.outerIndex,this.index++,this)}_error(e){this.parent.notifyError(e,this),this.unsubscribe()}_complete(){this.parent.notifyComplete(this),this.unsubscribe()}}const $t=n=>e=>{for(let t=0,i=n.length;tn&&"number"==typeof n.length&&"function"!=typeof n;function co(n){return!!n&&"function"!=typeof n.subscribe&&"function"==typeof n.then}const dc=n=>{if(n&&"function"==typeof n[ms])return(n=>e=>{const t=n[ms]();if("function"!=typeof t.subscribe)throw new TypeError("Provided object does not correctly implement Symbol.observable");return t.subscribe(e)})(n);if(lc(n))return $t(n);if(co(n))return(n=>e=>(n.then(t=>{e.closed||(e.next(t),e.complete())},t=>e.error(t)).then(null,ps),e))(n);if(n&&"function"==typeof n[fn])return(n=>e=>{const t=n[fn]();for(;;){let i;try{i=t.next()}catch(r){return e.error(r),e}if(i.done){e.complete();break}if(e.next(i.value),e.closed)break}return"function"==typeof t.return&&e.add(()=>{t.return&&t.return()}),e})(n);{const t=`You provided ${ao(n)?"an invalid object":`'${n}'`} where a stream was expected. You can provide an Observable, Promise, Array, or Iterable.`;throw new TypeError(t)}};function $o(n,e,t,i,r=new Pt(n,t,i)){if(!r.closed)return e instanceof un?e.subscribe(r):dc(e)(r)}class Fs extends di{notifyNext(e,t,i,r,s){this.destination.next(t)}notifyError(e,t){this.destination.error(e)}notifyComplete(e){this.destination.complete()}}function _t(n,e){return function(i){if("function"!=typeof n)throw new TypeError("argument is not a function. Are you looking for `mapTo()`?");return i.lift(new uu(n,e))}}class uu{constructor(e,t){this.project=e,this.thisArg=t}call(e,t){return t.subscribe(new zc(e,this.project,this.thisArg))}}class zc extends di{constructor(e,t,i){super(e),this.project=t,this.count=0,this.thisArg=i||this}_next(e){let t;try{t=this.project.call(this.thisArg,e,this.count++)}catch(i){return void this.destination.error(i)}this.destination.next(t)}}function lo(n,e){return new un(t=>{const i=new Tn;let r=0;return i.add(e.schedule(function(){r!==n.length?(t.next(n[r++]),t.closed||i.add(this.schedule())):t.complete()})),i})}function dr(n,e){return e?function Mp(n,e){if(null!=n){if(function Gc(n){return n&&"function"==typeof n[ms]}(n))return function hu(n,e){return new un(t=>{const i=new Tn;return i.add(e.schedule(()=>{const r=n[ms]();i.add(r.subscribe({next(s){i.add(e.schedule(()=>t.next(s)))},error(s){i.add(e.schedule(()=>t.error(s)))},complete(){i.add(e.schedule(()=>t.complete()))}}))})),i})}(n,e);if(co(n))return function Ep(n,e){return new un(t=>{const i=new Tn;return i.add(e.schedule(()=>n.then(r=>{i.add(e.schedule(()=>{t.next(r),i.add(e.schedule(()=>t.complete()))}))},r=>{i.add(e.schedule(()=>t.error(r)))}))),i})}(n,e);if(lc(n))return lo(n,e);if(function Oa(n){return n&&"function"==typeof n[fn]}(n)||"string"==typeof n)return function ad(n,e){if(!n)throw new Error("Iterable cannot be null");return new un(t=>{const i=new Tn;let r;return i.add(()=>{r&&"function"==typeof r.return&&r.return()}),i.add(e.schedule(()=>{r=n[fn](),i.add(e.schedule(function(){if(t.closed)return;let s,o;try{const a=r.next();s=a.value,o=a.done}catch(a){return void t.error(a)}o?t.complete():(t.next(s),this.schedule())}))})),i})}(n,e)}throw new TypeError((null!==n&&typeof n||n)+" is not observable")}(n,e):n instanceof un?n:new un(dc(n))}function ur(n,e,t=Number.POSITIVE_INFINITY){return"function"==typeof e?i=>i.pipe(ur((r,s)=>dr(n(r,s)).pipe(_t((o,a)=>e(r,o,s,a))),t)):("number"==typeof e&&(t=e),i=>i.lift(new qo(n,t)))}class qo{constructor(e,t=Number.POSITIVE_INFINITY){this.project=e,this.concurrent=t}call(e,t){return t.subscribe(new cd(e,this.project,this.concurrent))}}class cd extends Fs{constructor(e,t,i=Number.POSITIVE_INFINITY){super(e),this.project=t,this.concurrent=i,this.hasCompleted=!1,this.buffer=[],this.active=0,this.index=0}_next(e){this.active0?this._next(t.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()}}function Ml(n=Number.POSITIVE_INFINITY){return ur(Is,n)}function uc(n,e){return e?lo(n,e):new un($t(n))}function fa(...n){let e=Number.POSITIVE_INFINITY,t=null,i=n[n.length-1];return cc(i)?(t=n.pop(),n.length>1&&"number"==typeof n[n.length-1]&&(e=n.pop())):"number"==typeof i&&(e=n.pop()),null===t&&1===n.length&&n[0]instanceof un?n[0]:Ml(e)(uc(n,t))}function hc(){return function(e){return e.lift(new Cl(e))}}class Cl{constructor(e){this.connectable=e}call(e,t){const{connectable:i}=this;i._refCount++;const r=new Fh(e,i),s=t.subscribe(r);return r.closed||(r.connection=i.connect()),s}}class Fh extends di{constructor(e,t){super(e),this.connectable=t}_unsubscribe(){const{connectable:e}=this;if(!e)return void(this.connection=null);this.connectable=null;const t=e._refCount;if(t<=0)return void(this.connection=null);if(e._refCount=t-1,t>1)return void(this.connection=null);const{connection:i}=this,r=e._connection;this.connection=null,r&&(!i||r===i)&&r.unsubscribe()}}class ld extends un{constructor(e,t){super(),this.source=e,this.subjectFactory=t,this._refCount=0,this._isComplete=!1}_subscribe(e){return this.getSubject().subscribe(e)}getSubject(){const e=this._subject;return(!e||e.isStopped)&&(this._subject=this.subjectFactory()),this._subject}connect(){let e=this._connection;return e||(this._isComplete=!1,e=this._connection=new Tn,e.add(this.source.subscribe(new Ph(this.getSubject(),this))),e.closed&&(this._connection=null,e=Tn.EMPTY)),e}refCount(){return hc()(this)}}const Rh=(()=>{const n=ld.prototype;return{operator:{value:null},_refCount:{value:0,writable:!0},_subject:{value:null,writable:!0},_connection:{value:null,writable:!0},_subscribe:{value:n._subscribe},_isComplete:{value:n._isComplete,writable:!0},getSubject:{value:n.getSubject},connect:{value:n.connect},refCount:{value:n.refCount}}})();class Ph extends du{constructor(e,t){super(e),this.connectable=t}_error(e){this._unsubscribe(),super._error(e)}_complete(){this.connectable._isComplete=!0,this._unsubscribe(),super._complete()}_unsubscribe(){const e=this.connectable;if(e){this.connectable=null;const t=e._connection;e._refCount=0,e._subject=null,e._connection=null,t&&t.unsubscribe()}}}class Nh{constructor(e,t){this.subjectFactory=e,this.selector=t}call(e,t){const{selector:i}=this,r=this.subjectFactory(),s=i(r).subscribe(e);return s.add(t.subscribe(r)),s}}function Bh(){return new cn}function Dp(){return n=>hc()(function Lh(n,e){return function(i){let r;if(r="function"==typeof n?n:function(){return n},"function"==typeof e)return i.lift(new Nh(r,e));const s=Object.create(i,Rh);return s.source=i,s.subjectFactory=r,s}}(Bh)(n))}function Vi(n){for(let e in n)if(n[e]===Vi)return e;throw Error("Could not find renamed property on target object.")}function Vh(n,e){for(const t in e)e.hasOwnProperty(t)&&!n.hasOwnProperty(t)&&(n[t]=e[t])}function ki(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(ki).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const e=n.toString();if(null==e)return""+e;const t=e.indexOf("\n");return-1===t?e:e.substring(0,t)}function fu(n,e){return null==n||""===n?null===e?"":e:null==e||""===e?n:n+" "+e}const Tp=Vi({__forward_ref__:Vi});function Mi(n){return n.__forward_ref__=Mi,n.toString=function(){return ki(this())},n}function en(n){return Hh(n)?n():n}function Hh(n){return"function"==typeof n&&n.hasOwnProperty(Tp)&&n.__forward_ref__===Mi}function pu(n){return n&&!!n.\u0275providers}const mu="https://g.co/ng/security#xss";class Ue extends Error{constructor(e,t){super(Dl(e,t)),this.code=e}}function Dl(n,e){return`NG0${Math.abs(n)}${e?": "+e.trim():""}`}function wn(n){return"string"==typeof n?n:null==n?"":String(n)}function gu(n,e){throw new Ue(-201,!1)}function Rs(n,e){null==n&&function Ci(n,e,t,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${t} ${i} ${e} <=Actual]`))}(e,n,null,"!=")}function Je(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function On(n){return{providers:n.providers||[],imports:n.imports||[]}}function _u(n){return kp(n,Tl)||kp(n,zh)}function kp(n,e){return n.hasOwnProperty(e)?n[e]:null}function Uh(n){return n&&(n.hasOwnProperty(Xr)||n.hasOwnProperty(vu))?n[Xr]:null}const Tl=Vi({\u0275prov:Vi}),Xr=Vi({\u0275inj:Vi}),zh=Vi({ngInjectableDef:Vi}),vu=Vi({ngInjectorDef:Vi});var tn=(()=>((tn=tn||{})[tn.Default=0]="Default",tn[tn.Host=1]="Host",tn[tn.Self=2]="Self",tn[tn.SkipSelf=4]="SkipSelf",tn[tn.Optional=8]="Optional",tn))();let dd;function ho(n){const e=dd;return dd=n,e}function yu(n,e,t){const i=_u(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:t&tn.Optional?null:void 0!==e?e:void gu(ki(n))}const Ii=(()=>typeof globalThis<"u"&&globalThis||typeof global<"u"&&global||typeof window<"u"&&window||typeof self<"u"&&typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&self)(),pc={},qs="__NG_DI_FLAG__",hd="ngTempTokenPath",Gh="ngTokenPath",jh=/\n/gm,Op="\u0275",Wh="__source";let Ao;function hr(n){const e=Ao;return Ao=n,e}function Sb(n,e=tn.Default){if(void 0===Ao)throw new Ue(-203,!1);return null===Ao?yu(n,void 0,e):Ao.get(n,e&tn.Optional?null:void 0,e)}function xe(n,e=tn.Default){return(function Rp(){return dd}()||Sb)(en(n),e)}function hn(n,e=tn.Default){return xe(n,bu(e))}function bu(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Ut(n){const e=[];for(let t=0;t((ko=ko||{})[ko.OnPush=0]="OnPush",ko[ko.Default=1]="Default",ko))(),Ko=(()=>(function(n){n[n.Emulated=0]="Emulated",n[n.None=2]="None",n[n.ShadowDom=3]="ShadowDom"}(Ko||(Ko={})),Ko))();const Na={},Si=[],xu=Vi({\u0275cmp:Vi}),$h=Vi({\u0275dir:Vi}),fr=Vi({\u0275pipe:Vi}),qh=Vi({\u0275mod:Vi}),Ba=Vi({\u0275fac:Vi}),pr=Vi({__NG_ELEMENT_ID__:Vi});let Np=0;function Ln(n){return mc(()=>{const t=!0===n.standalone,i={},r={type:n.type,providersResolver:null,decls:n.decls,vars:n.vars,factory:null,template:n.template||null,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:i,inputs:null,outputs:null,exportAs:n.exportAs||null,onPush:n.changeDetection===ko.OnPush,directiveDefs:null,pipeDefs:null,standalone:t,dependencies:t&&n.dependencies||null,getStandaloneInjector:null,selectors:n.selectors||Si,viewQuery:n.viewQuery||null,features:n.features||null,data:n.data||{},encapsulation:n.encapsulation||Ko.Emulated,id:"c"+Np++,styles:n.styles||Si,_:null,setInput:null,schemas:n.schemas||null,tView:null,findHostDirectiveDefs:null,hostDirectives:null},s=n.dependencies,o=n.features;return r.inputs=Kh(n.inputs,i),r.outputs=Kh(n.outputs),o&&o.forEach(a=>a(r)),r.directiveDefs=s?()=>("function"==typeof s?s():s).map(wu).filter(fo):null,r.pipeDefs=s?()=>("function"==typeof s?s():s).map(Ps).filter(fo):null,r})}function wu(n){return Ei(n)||Ni(n)}function fo(n){return null!==n}function Mt(n){return mc(()=>({type:n.type,bootstrap:n.bootstrap||Si,declarations:n.declarations||Si,imports:n.imports||Si,exports:n.exports||Si,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function Kh(n,e){if(null==n)return Na;const t={};for(const i in n)if(n.hasOwnProperty(i)){let r=n[i],s=r;Array.isArray(r)&&(s=r[1],r=r[0]),t[r]=i,e&&(e[r]=s)}return t}const ut=Ln;function Yi(n){return{type:n.type,name:n.name,factory:null,pure:!1!==n.pure,standalone:!0===n.standalone,onDestroy:n.type.prototype.ngOnDestroy||null}}function Ei(n){return n[xu]||null}function Ni(n){return n[$h]||null}function Ps(n){return n[fr]||null}function po(n,e){const t=n[qh]||null;if(!t&&!0===e)throw new Error(`Type ${ki(n)} does not have '\u0275mod' property.`);return t}const Nr=0,xt=1,Sn=2,Zi=3,si=4,Ks=5,Br=6,Al=7,Ji=8,rt=9,w=10,Hn=11,fd=12,Va=13,pa=14,Ir=15,Jr=16,kl=17,gc=18,Qr=19,ma=20,Er=21,nn=22,mo=1,Ys=2,Fl=7,Io=8,ei=9,gs=10;function go(n){return Array.isArray(n)&&"object"==typeof n[mo]}function Yo(n){return Array.isArray(n)&&!0===n[mo]}function Vr(n){return 0!=(4&n.flags)}function _s(n){return n.componentOffset>-1}function ga(n){return 1==(1&n.flags)}function Fo(n){return null!==n.template}function Hp(n){return 0!=(256&n[Sn])}function qn(n,e){return n.hasOwnProperty(Ba)?n[Ba]:null}class mr{constructor(e,t,i){this.previousValue=e,this.currentValue=t,this.firstChange=i}isFirstChange(){return this.firstChange}}function Cn(){return Su}function Su(n){return n.type.prototype.ngOnChanges&&(n.setInput=vo),j0}function j0(){const n=gd(this),e=n?.current;if(e){const t=n.previous;if(t===Na)n.previous=e;else for(let i in e)t[i]=e[i];n.current=null,this.ngOnChanges(e)}}function vo(n,e,t,i){const r=this.declaredInputs[t],s=gd(n)||function Wc(n,e){return n[vc]=e}(n,{previous:Na,current:null}),o=s.current||(s.current={}),a=s.previous,c=a[r];o[r]=new mr(c&&c.currentValue,e,a===Na),n[i]=e}Cn.ngInherit=!0;const vc="__ngSimpleChanges__";function gd(n){return n[vc]||null}const Nn=function(n,e,t){},vd="svg";function Zt(n){for(;Array.isArray(n);)n=n[Nr];return n}function Jh(n,e){return Zt(e[n])}function Xs(n,e){return Zt(e[n.index])}function Ha(n,e){return n.data[e]}function yc(n,e){return n[e]}function Os(n,e){const t=e[n];return go(t)?t:t[Nr]}function bd(n){return 64==(64&n[Sn])}function h(n,e){return null==e?null:n[e]}function f(n){n[gc]=0}function _(n,e){n[Ks]+=e;let t=n,i=n[Zi];for(;null!==i&&(1===e&&1===t[Ks]||-1===e&&0===t[Ks]);)i[Ks]+=e,t=i,i=i[Zi]}const b={lFrame:es(null),bindingsEnabled:!0};function U(){return b.bindingsEnabled}function C(){return b.lFrame.lView}function B(){return b.lFrame.tView}function R(n){return b.lFrame.contextLView=n,n[Ji]}function V(n){return b.lFrame.contextLView=null,n}function L(){let n=$();for(;null!==n&&64===n.type;)n=n.parent;return n}function $(){return b.lFrame.currentTNode}function Q(n,e){const t=b.lFrame;t.currentTNode=n,t.isParent=e}function te(){return b.lFrame.isParent}function Se(){b.lFrame.isParent=!1}function ee(){const n=b.lFrame;let e=n.bindingRootIndex;return-1===e&&(e=n.bindingRootIndex=n.tView.bindingStartIndex),e}function be(){return b.lFrame.bindingIndex++}function ce(n){const e=b.lFrame,t=e.bindingIndex;return e.bindingIndex=e.bindingIndex+n,t}function Ie(n,e){const t=b.lFrame;t.bindingIndex=t.bindingRootIndex=n,Nt(e)}function Nt(n){b.lFrame.currentDirectiveIndex=n}function Lt(n){const e=b.lFrame.currentDirectiveIndex;return-1===e?null:n[e]}function Rn(){return b.lFrame.currentQueryIndex}function Y(n){b.lFrame.currentQueryIndex=n}function ui(n){const e=n[xt];return 2===e.type?e.declTNode:1===e.type?n[Br]:null}function oi(n,e,t){if(t&tn.SkipSelf){let r=e,s=n;for(;!(r=r.parent,null!==r||t&tn.Host||(r=ui(s),null===r||(s=s[Ir],10&r.type))););if(null===r)return!1;e=r,n=s}const i=b.lFrame=ln();return i.currentTNode=e,i.lView=n,!0}function Fi(n){const e=ln(),t=n[xt];b.lFrame=e,e.currentTNode=t.firstChild,e.lView=n,e.tView=t,e.contextLView=n,e.bindingIndex=t.bindingStartIndex,e.inI18n=!1}function ln(){const n=b.lFrame,e=null===n?null:n.child;return null===e?es(n):e}function es(n){const e={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:n,child:null,inI18n:!1};return null!==n&&(n.child=e),e}function vs(){const n=b.lFrame;return b.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const Ls=vs;function Kn(){const n=vs();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function ii(){return b.lFrame.selectedIndex}function gr(n){b.lFrame.selectedIndex=n}function an(){const n=b.lFrame;return Ha(n.tView,n.selectedIndex)}function $i(){b.lFrame.currentNamespace=vd}function Xo(){!function W0(){b.lFrame.currentNamespace=null}()}function Ro(n,e){for(let t=e.directiveStart,i=e.directiveEnd;t=i)break}else e[c]<0&&(n[gc]+=65536),(a>11>16&&(3&n[Sn])===e){n[Sn]+=2048,Nn(4,a,s);try{s.call(a)}finally{Nn(5,a,s)}}}else{Nn(4,a,s);try{s.call(a)}finally{Nn(5,a,s)}}}const va=-1;class Qh{constructor(e,t,i){this.factory=e,this.resolving=!1,this.canSeeViewProviders=t,this.injectImpl=i}}function jp(n,e,t){let i=0;for(;ie){o=s-1;break}}}for(;s>16}(n),i=e;for(;t>0;)i=i[Ir],t--;return i}let Ua=!0;function Mu(n){const e=Ua;return Ua=n,e}const Zo=255,Ab=5;let kb=0;const za={};function Ga(n,e){const t=Ib(n,e);if(-1!==t)return t;const i=e[xt];i.firstCreatePass&&(n.injectorIndex=e.length,qp(i.data,n),qp(e,null),qp(i.blueprint,null));const r=Du(n,e),s=n.injectorIndex;if(ef(r)){const o=Wp(r),a=$p(r,e),c=a[xt].data;for(let u=0;u<8;u++)e[s+u]=a[o+u]|c[o+u]}return e[s+8]=r,s}function qp(n,e){n.push(0,0,0,0,0,0,0,0,e)}function Ib(n,e){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===e[n.injectorIndex+8]?-1:n.injectorIndex}function Du(n,e){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let t=0,i=null,r=e;for(;null!==r;){if(i=Au(r),null===i)return va;if(t++,r=r[Ir],-1!==i.injectorIndex)return i.injectorIndex|t<<16}return va}function q0(n,e,t){!function tf(n,e,t){let i;"string"==typeof t?i=t.charCodeAt(0)||0:t.hasOwnProperty(pr)&&(i=t[pr]),null==i&&(i=t[pr]=kb++);const r=i&Zo;e.data[n+(r>>Ab)]|=1<=0?e&Zo:CE:e}(t);if("function"==typeof s){if(!oi(e,n,i))return i&tn.Host?ys(r,0,i):Kp(e,t,i,r);try{const o=s(i);if(null!=o||i&tn.Optional)return o;gu()}finally{Ls()}}else if("number"==typeof s){let o=null,a=Ib(n,e),c=va,u=i&tn.Host?e[Jr][Br]:null;for((-1===a||i&tn.SkipSelf)&&(c=-1===a?Du(n,e):e[a+8],c!==va&&Yp(i,!1)?(o=e[xt],a=Wp(c),e=$p(c,e)):a=-1);-1!==a;){const p=e[xt];if(Zs(s,a,p.data)){const g=Y0(a,e,t,o,i,u);if(g!==za)return g}c=e[a+8],c!==va&&Yp(i,e[xt].data[a+8]===u)&&Zs(s,a,e)?(o=p,a=Wp(c),e=$p(c,e)):a=-1}}return r}function Y0(n,e,t,i,r,s){const o=e[xt],a=o.data[n+8],p=Ed(a,o,t,null==i?_s(a)&&Ua:i!=o&&0!=(3&a.type),r&tn.Host&&s===a);return null!==p?Jo(e,o,p,a):za}function Ed(n,e,t,i,r){const s=n.providerIndexes,o=e.data,a=1048575&s,c=n.directiveStart,p=s>>20,v=r?a+p:n.directiveEnd;for(let y=i?a:a+p;y=c&&x.type===t)return y}if(r){const y=o[c];if(y&&Fo(y)&&y.type===t)return c}return null}function Jo(n,e,t,i){let r=n[t];const s=e.data;if(function wE(n){return n instanceof Qh}(r)){const o=r;o.resolving&&function Ap(n,e){const t=e?`. Dependency path: ${e.join(" > ")} > ${n}`:"";throw new Ue(-200,`Circular dependency in DI detected for ${n}${t}`)}(function wi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():wn(n)}(s[t]));const a=Mu(o.canSeeViewProviders);o.resolving=!0;const c=o.injectImpl?ho(o.injectImpl):null;oi(n,i,tn.Default);try{r=n[t]=o.factory(void 0,s,n,i),e.firstCreatePass&&t>=i.directiveStart&&function qc(n,e,t){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=e.type.prototype;if(i){const o=Su(e);(t.preOrderHooks||(t.preOrderHooks=[])).push(n,o),(t.preOrderCheckHooks||(t.preOrderCheckHooks=[])).push(n,o)}r&&(t.preOrderHooks||(t.preOrderHooks=[])).push(0-n,r),s&&((t.preOrderHooks||(t.preOrderHooks=[])).push(n,s),(t.preOrderCheckHooks||(t.preOrderCheckHooks=[])).push(n,s))}(t,s[t],e)}finally{null!==c&&ho(c),Mu(a),o.resolving=!1,Ls()}}return r}function Zs(n,e,t){return!!(t[e+(n>>Ab)]&1<{const e=n.prototype.constructor,t=e[Ba]||nf(e),i=Object.prototype;let r=Object.getPrototypeOf(n.prototype).constructor;for(;r&&r!==i;){const s=r[Ba]||nf(r);if(s&&s!==t)return s;r=Object.getPrototypeOf(r)}return s=>new s})}function nf(n){return Hh(n)?()=>{const e=nf(en(n));return e&&e()}:qn(n)}function Au(n){const e=n[xt],t=e.type;return 2===t?e.declTNode:1===t?n[Br]:null}function Kc(n){return function Fb(n,e){if("class"===e)return n.classes;if("style"===e)return n.styles;const t=n.attrs;if(t){const i=t.length;let r=0;for(;r{const i=function X0(n){return function(...t){if(n){const i=n(...t);for(const r in i)this[r]=i[r]}}}(e);function r(...s){if(this instanceof r)return i.apply(this,s),this;const o=new r(...s);return a.annotation=o,a;function a(c,u,p){const g=c.hasOwnProperty(Iu)?c[Iu]:Object.defineProperty(c,Iu,{value:[]})[Iu];for(;g.length<=p;)g.push(null);return(g[p]=g[p]||[]).push(o),c}}return t&&(r.prototype=Object.create(t.prototype)),r.prototype.ngMetadataName=n,r.annotationCls=r,r})}class Ze{constructor(e,t){this._desc=e,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof t?this.__NG_ELEMENT_ID__=t:void 0!==t&&(this.\u0275prov=Je({token:this,providedIn:t.providedIn||"root",factory:t.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}function Yc(n,e){n.forEach(t=>Array.isArray(t)?Yc(t,e):e(t))}function J0(n,e,t){e>=n.length?n.push(t):n.splice(e,0,t)}function Ru(n,e){return e>=n.length-1?n.pop():n.splice(e,1)[0]}function sf(n,e){const t=[];for(let i=0;i=0?n[1|i]=t:(i=~i,function RE(n,e,t,i){let r=n.length;if(r==e)n.push(t,i);else if(1===r)n.push(i,n[0]),n[0]=t;else{for(r--,n.push(n[r-1],n[r]);r>e;)n[r]=n[r-2],r--;n[e]=t,n[e+1]=i}}(n,i,e,t)),i}function Zp(n,e){const t=Pu(n,e);if(t>=0)return n[1|t]}function Pu(n,e){return function Qo(n,e,t){let i=0,r=n.length>>t;for(;r!==i;){const s=i+(r-i>>1),o=n[s<e?r=s:i=s+1}return~(r<({token:n})),-1),ba=jc(Rl("Optional"),8),Pl=jc(Rl("SkipSelf"),4);var Js=(()=>((Js=Js||{})[Js.Important=1]="Important",Js[Js.DashCase=2]="DashCase",Js))();const nm=new Map;let WE=0;const Ll="__ngContext__";function Ot(n,e){go(e)?(n[Ll]=e[ma],function $E(n){nm.set(n[ma],n)}(e)):n[Ll]=e}let sm;function h_(n,e){return sm(n,e)}function ff(n){const e=n[Zi];return Yo(e)?e[Zi]:e}function pf(n){return om(n[Va])}function f_(n){return om(n[si])}function om(n){for(;null!==n&&!Yo(n);)n=n[si];return n}function Lu(n,e,t,i,r){if(null!=i){let s,o=!1;Yo(i)?s=i:go(i)&&(o=!0,i=i[Nr]);const a=Zt(i);0===n&&null!==t?null==r?qa(e,t,a):Vl(e,t,a,r||null,!0):1===n&&null!==t?Vl(e,t,a,r||null,!0):2===n?function um(n,e,t){const i=cm(n,e);i&&function tM(n,e,t,i){n.removeChild(e,t,i)}(n,i,e,t)}(e,a,o):3===n&&e.destroyNode(a),null!=s&&function sM(n,e,t,i,r){const s=t[Fl];s!==Zt(t)&&Lu(e,n,i,s,r);for(let a=gs;a0&&(n[t-1][si]=i[si]);const s=Ru(n,gs+e);!function ZE(n,e){Bu(n,e,e[Hn],2,null,null),e[Nr]=null,e[Br]=null}(i[xt],i);const o=s[Qr];null!==o&&o.detachView(s[xt]),i[Zi]=null,i[si]=null,i[Sn]&=-65}return i}function m_(n,e){if(!(128&e[Sn])){const t=e[Hn];t.destroyNode&&Bu(n,e,t,3,null,null),function eM(n){let e=n[Va];if(!e)return Ad(n[xt],n);for(;e;){let t=null;if(go(e))t=e[Va];else{const i=e[gs];i&&(t=i)}if(!t){for(;e&&!e[si]&&e!==n;)go(e)&&Ad(e[xt],e),e=e[Zi];null===e&&(e=n),go(e)&&Ad(e[xt],e),t=e&&e[si]}e=t}}(e)}}function Ad(n,e){if(!(128&e[Sn])){e[Sn]&=-65,e[Sn]|=128,function sx(n,e){let t;if(null!=n&&null!=(t=n.destroyHooks))for(let i=0;i=0?i[r=o]():i[r=-o].unsubscribe(),s+=2}else{const o=i[r=t[s+1]];t[s].call(o)}if(null!==i){for(let s=r+1;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ko.None||s===Ko.Emulated)return null}return Xs(i,t)}}(n,e.parent,t)}function Vl(n,e,t,i,r){n.insertBefore(e,t,i,r)}function qa(n,e,t){n.appendChild(e,t)}function Hl(n,e,t,i,r){null!==i?Vl(n,e,t,i,r):qa(n,e,t)}function cm(n,e){return n.parentNode(e)}function ox(n,e,t){return cx(n,e,t)}let v_,fm,pm,cx=function ax(n,e,t){return 40&n.type?Xs(n,t):null};function lm(n,e,t,i){const r=__(n,i,e),s=e[Hn],a=ox(i.parent||e[Br],i,e);if(null!=r)if(Array.isArray(t))for(let c=0;cn,createScript:n=>n,createScriptURL:n=>n})}catch{}return fm}()?.createHTML(n)||n}class kd{constructor(e){this.changingThisBreaksApplicationSecurity=e}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${mu})`}}class dM extends kd{getTypeName(){return"HTML"}}class uM extends kd{getTypeName(){return"Style"}}class hM extends kd{getTypeName(){return"Script"}}class fM extends kd{getTypeName(){return"URL"}}class pM extends kd{getTypeName(){return"ResourceURL"}}function ta(n){return n instanceof kd?n.changingThisBreaksApplicationSecurity:n}function Ec(n,e){const t=function mM(n){return n instanceof kd&&n.getTypeName()||null}(n);if(null!=t&&t!==e){if("ResourceURL"===t&&"URL"===e)return!0;throw new Error(`Required a safe ${e}, got a ${t} (see ${mu})`)}return t===e}class xM{constructor(e){this.inertDocumentHelper=e}getInertBodyElement(e){e=""+e;try{const t=(new window.DOMParser).parseFromString(Vu(e),"text/html").body;return null===t?this.inertDocumentHelper.getInertBodyElement(e):(t.removeChild(t.firstChild),t)}catch{return null}}}class wM{constructor(e){this.defaultDoc=e,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert")}getInertBodyElement(e){const t=this.inertDocument.createElement("template");return t.innerHTML=Vu(e),t}}const w_=/^(?:(?:https?|mailto|data|ftp|tel|file|sms):|[^&:/?#]*(?:[/?#]|$))/gi;function _f(n){return(n=String(n)).match(w_)?n:"unsafe:"+n}function Qc(n){const e={};for(const t of n.split(","))e[t]=!0;return e}function vf(...n){const e={};for(const t of n)for(const i in t)t.hasOwnProperty(i)&&(e[i]=!0);return e}const yx=Qc("area,br,col,hr,img,wbr"),bx=Qc("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),xx=Qc("rp,rt"),_m=vf(yx,vf(bx,Qc("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")),vf(xx,Qc("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")),vf(xx,bx)),S_=Qc("background,cite,href,itemtype,longdesc,poster,src,xlink:href"),wx=vf(S_,Qc("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"),Qc("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")),EM=Qc("script,style,template");class MM{constructor(){this.sanitizedSomething=!1,this.buf=[]}sanitizeChildren(e){let t=e.firstChild,i=!0;for(;t;)if(t.nodeType===Node.ELEMENT_NODE?i=this.startElement(t):t.nodeType===Node.TEXT_NODE?this.chars(t.nodeValue):this.sanitizedSomething=!0,i&&t.firstChild)t=t.firstChild;else for(;t;){t.nodeType===Node.ELEMENT_NODE&&this.endElement(t);let r=this.checkClobberedElement(t,t.nextSibling);if(r){t=r;break}t=this.checkClobberedElement(t,t.parentNode)}return this.buf.join("")}startElement(e){const t=e.nodeName.toLowerCase();if(!_m.hasOwnProperty(t))return this.sanitizedSomething=!0,!EM.hasOwnProperty(t);this.buf.push("<"),this.buf.push(t);const i=e.attributes;for(let r=0;r"),!0}endElement(e){const t=e.nodeName.toLowerCase();_m.hasOwnProperty(t)&&!yx.hasOwnProperty(t)&&(this.buf.push(""))}chars(e){this.buf.push(Sx(e))}checkClobberedElement(e,t){if(t&&(e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY)===Node.DOCUMENT_POSITION_CONTAINED_BY)throw new Error(`Failed to sanitize html because the element is clobbered: ${e.outerHTML}`);return t}}const CM=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,DM=/([^\#-~ |!])/g;function Sx(n){return n.replace(/&/g,"&").replace(CM,function(e){return"&#"+(1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320)+65536)+";"}).replace(DM,function(e){return"&#"+e.charCodeAt(0)+";"}).replace(//g,">")}let vm;function Ex(n,e){let t=null;try{vm=vm||function vx(n){const e=new wM(n);return function SM(){try{return!!(new window.DOMParser).parseFromString(Vu(""),"text/html")}catch{return!1}}()?new xM(e):e}(n);let i=e?String(e):"";t=vm.getInertBodyElement(i);let r=5,s=i;do{if(0===r)throw new Error("Failed to sanitize html because the input is unstable");r--,i=s,s=t.innerHTML,t=vm.getInertBodyElement(i)}while(i!==s);return Vu((new MM).sanitizeChildren(M_(t)||t))}finally{if(t){const i=M_(t)||t;for(;i.firstChild;)i.removeChild(i.firstChild)}}}function M_(n){return"content"in n&&function TM(n){return n.nodeType===Node.ELEMENT_NODE&&"TEMPLATE"===n.nodeName}(n)?n.content:null}var Ri=(()=>((Ri=Ri||{})[Ri.NONE=0]="NONE",Ri[Ri.HTML=1]="HTML",Ri[Ri.STYLE=2]="STYLE",Ri[Ri.SCRIPT=3]="SCRIPT",Ri[Ri.URL=4]="URL",Ri[Ri.RESOURCE_URL=5]="RESOURCE_URL",Ri))();function Id(n){const e=function yf(){const n=C();return n&&n[fd]}();return e?e.sanitize(Ri.URL,n)||"":Ec(n,"URL")?ta(n):_f(wn(n))}const ym=new Ze("ENVIRONMENT_INITIALIZER"),Ax=new Ze("INJECTOR",-1),kx=new Ze("INJECTOR_DEF_TYPES");class Ix{get(e,t=pc){if(t===pc){const i=new Error(`NullInjectorError: No provider for ${ki(e)}!`);throw i.name="NullInjectorError",i}return t}}function Fx(n){return{\u0275providers:n}}function RM(...n){return{\u0275providers:Rx(0,n),\u0275fromNgModule:!0}}function Rx(n,...e){const t=[],i=new Set;let r;return Yc(e,s=>{const o=s;D_(o,t,[],i)&&(r||(r=[]),r.push(o))}),void 0!==r&&Px(r,t),t}function Px(n,e){for(let t=0;t{e.push(s)})}}function D_(n,e,t,i){if(!(n=en(n)))return!1;let r=null,s=Uh(n);const o=!s&&Ei(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const c=n.ngModule;if(s=Uh(c),!s)return!1;r=c}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const c="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const u of c)D_(u,e,t,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let u;i.add(r);try{Yc(s.imports,p=>{D_(p,e,t,i)&&(u||(u=[]),u.push(p))})}finally{}void 0!==u&&Px(u,e)}if(!a){const u=qn(r)||(()=>new r);e.push({provide:r,useFactory:u,deps:Si},{provide:kx,useValue:r,multi:!0},{provide:ym,useValue:()=>xe(r),multi:!0})}const c=s.providers;null==c||a||Hu(c,p=>{e.push(p)})}}return r!==n&&void 0!==n.providers}function Hu(n,e){for(let t of n)pu(t)&&(t=t.\u0275providers),Array.isArray(t)?Hu(t,e):e(t)}const PM=Vi({provide:String,useValue:Vi});function bm(n){return null!==n&&"object"==typeof n&&PM in n}function Ul(n){return"function"==typeof n}const wm=new Ze("Set Injector scope."),bf={},OM={};let A_;function Sm(){return void 0===A_&&(A_=new Ix),A_}class na{}class xf extends na{get destroyed(){return this._destroyed}constructor(e,t,i,r){super(),this.parent=t,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,R_(e,o=>this.processProvider(o)),this.records.set(Ax,Uu(void 0,this)),r.has("environment")&&this.records.set(na,Uu(void 0,this));const s=this.records.get(wm);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(kx.multi,Si,tn.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();for(const e of this._onDestroyHooks)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),this._onDestroyHooks.length=0}}onDestroy(e){this._onDestroyHooks.push(e)}runInContext(e){this.assertNotDestroyed();const t=hr(this),i=ho(void 0);try{return e()}finally{hr(t),ho(i)}}get(e,t=pc,i=tn.Default){this.assertNotDestroyed(),i=bu(i);const r=hr(this),s=ho(void 0);try{if(!(i&tn.SkipSelf)){let a=this.records.get(e);if(void 0===a){const c=function VM(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ze}(e)&&_u(e);a=c&&this.injectableDefInScope(c)?Uu(k_(e),bf):null,this.records.set(e,a)}if(null!=a)return this.hydrate(e,a)}return(i&tn.Self?Sm():this.parent).get(e,t=i&tn.Optional&&t===pc?null:t)}catch(o){if("NullInjectorError"===o.name){if((o[hd]=o[hd]||[]).unshift(ki(e)),r)throw o;return function H0(n,e,t,i){const r=n[hd];throw e[Wh]&&r.unshift(e[Wh]),n.message=function U0(n,e,t,i=null){n=n&&"\n"===n.charAt(0)&&n.charAt(1)==Op?n.slice(2):n;let r=ki(e);if(Array.isArray(e))r=e.map(ki).join(" -> ");else if("object"==typeof e){let s=[];for(let o in e)if(e.hasOwnProperty(o)){let a=e[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):ki(a)))}r=`{${s.join(", ")}}`}return`${t}${i?"("+i+")":""}[${r}]: ${n.replace(jh,"\n ")}`}("\n"+n.message,r,t,i),n[Gh]=r,n[hd]=null,n}(o,e,"R3InjectorError",this.source)}throw o}finally{ho(s),hr(r)}}resolveInjectorInitializers(){const e=hr(this),t=ho(void 0);try{const i=this.get(ym.multi,Si,tn.Self);for(const r of i)r()}finally{hr(e),ho(t)}}toString(){const e=[],t=this.records;for(const i of t.keys())e.push(ki(i));return`R3Injector[${e.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new Ue(205,!1)}processProvider(e){let t=Ul(e=en(e))?e:en(e&&e.provide);const i=function I_(n){return bm(n)?Uu(void 0,n.useValue):Uu(F_(n),bf)}(e);if(Ul(e)||!0!==e.multi)this.records.get(t);else{let r=this.records.get(t);r||(r=Uu(void 0,bf,!0),r.factory=()=>Ut(r.multi),this.records.set(t,r)),t=e,r.multi.push(e)}this.records.set(t,i)}hydrate(e,t){return t.value===bf&&(t.value=OM,t.value=t.factory()),"object"==typeof t.value&&t.value&&function BM(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(t.value)&&this._ngOnDestroyHooks.add(t.value),t.value}injectableDefInScope(e){if(!e.providedIn)return!1;const t=en(e.providedIn);return"string"==typeof t?"any"===t||this.scopes.has(t):this.injectorDefTypes.has(t)}}function k_(n){const e=_u(n),t=null!==e?e.factory:qn(n);if(null!==t)return t;if(n instanceof Ze)throw new Ue(204,!1);if(n instanceof Function)return function LM(n){const e=n.length;if(e>0)throw sf(e,"?"),new Ue(204,!1);const t=function Ip(n){const e=n&&(n[Tl]||n[zh]);return e?(function Fp(n){if(n.hasOwnProperty("name"))return n.name;(""+n).match(/^function\s*([^\s(]+)/)}(n),e):null}(n);return null!==t?()=>t.factory(n):()=>new n}(n);throw new Ue(204,!1)}function F_(n,e,t){let i;if(Ul(n)){const r=en(n);return qn(r)||k_(r)}if(bm(n))i=()=>en(n.useValue);else if(function xm(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Ut(n.deps||[]));else if(function T_(n){return!(!n||!n.useExisting)}(n))i=()=>xe(en(n.useExisting));else{const r=en(n&&(n.useClass||n.provide));if(!function NM(n){return!!n.deps}(n))return qn(r)||k_(r);i=()=>new r(...Ut(n.deps))}return i}function Uu(n,e,t=!1){return{factory:n,value:e,multi:t?[]:void 0}}function R_(n,e){for(const t of n)Array.isArray(t)?R_(t,e):t&&pu(t)?R_(t.\u0275providers,e):e(t)}class HM{}class Lx{}class zM{resolveComponentFactory(e){throw function UM(n){const e=Error(`No component factory found for ${ki(n)}. Did you add it to @NgModule.entryComponents?`);return e.ngComponent=n,e}(e)}}let Fd=(()=>{class n{}return n.NULL=new zM,n})();function Ka(){return zu(L(),C())}function zu(n,e){return new _n(Xs(n,e))}let _n=(()=>{class n{constructor(t){this.nativeElement=t}}return n.__NG_ELEMENT_ID__=Ka,n})();function Rd(n){return n instanceof _n?n.nativeElement:n}class yn{}let el=(()=>{class n{}return n.__NG_ELEMENT_ID__=()=>function Oo(){const n=C(),t=Os(L().index,n);return(go(t)?t:n)[Hn]}(),n})(),Rr=(()=>{class n{}return n.\u0275prov=Je({token:n,providedIn:"root",factory:()=>null}),n})();class Pd{constructor(e){this.full=e,this.major=e.split(".")[0],this.minor=e.split(".")[1],this.patch=e.split(".").slice(2).join(".")}}const zl=new Pd("15.2.1"),P_={},O_="ngOriginalError";function L_(n){return n[O_]}class tl{constructor(){this._console=console}handleError(e){const t=this._findOriginalError(e);this._console.error("ERROR",e),t&&this._console.error("ORIGINAL ERROR",t)}_findOriginalError(e){let t=e&&L_(e);for(;t&&L_(t);)t=L_(t);return t||null}}function il(n){return n instanceof Function?n():n}function Gu(n,e,t){let i=n.length;for(;;){const r=n.indexOf(e,t);if(-1===r)return r;if(0===r||n.charCodeAt(r-1)<=32){const s=e.length;if(r+s===i||n.charCodeAt(r+s)<=32)return r}t=r+1}}const Mm="ng-template";function KM(n,e,t){let i=0;for(;is?"":r[g+1].toLowerCase();const y=8&i?v:null;if(y&&-1!==Gu(y,u,0)||2&i&&u!==v){if(eo(i))return!1;o=!0}}}}else{if(!o&&!eo(i)&&!eo(c))return!1;if(o&&eo(c))continue;o=!1,i=c|1&i}}return eo(i)||o}function eo(n){return 0==(1&n)}function YM(n,e,t,i){if(null===e)return-1;let r=0;if(i||!t){let s=!1;for(;r-1)for(t++;t0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!eo(o)&&(e+=Mc(s,r),r=""),i=o,s=s||!eo(i);t++}return""!==r&&(e+=Mc(s,r)),e}const Dn={};function Le(n){Pi(B(),C(),ii()+n,!1)}function Pi(n,e,t,i){if(!i)if(3==(3&e[Sn])){const s=n.preOrderCheckHooks;null!==s&&wd(e,s,t)}else{const s=n.preOrderHooks;null!==s&&Bi(e,s,0,t)}gr(t)}function qx(n,e=null,t=null,i){const r=Kx(n,e,t,i);return r.resolveInjectorInitializers(),r}function Kx(n,e=null,t=null,i,r=new Set){const s=[t||Si,RM(n)];return i=i||("object"==typeof n?void 0:ki(n)),new xf(s,e||Sm(),i||null,r)}let ts=(()=>{class n{static create(t,i){if(Array.isArray(t))return qx({name:""},i,t,"");{const r=t.name??"";return qx({name:r},t.parent,t.providers,r)}}}return n.THROW_IF_NOT_FOUND=pc,n.NULL=new Ix,n.\u0275prov=Je({token:n,providedIn:"any",factory:()=>xe(Ax)}),n.__NG_ELEMENT_ID__=-1,n})();function ie(n,e=tn.Default){const t=C();return null===t?xe(n,e):K0(L(),t,en(n),e)}function Gl(){throw new Error("invalid")}function o1(n,e){const t=n.contentQueries;if(null!==t)for(let i=0;inn&&Pi(n,e,nn,!1),Nn(o?2:0,r),t(i,r)}finally{gr(s),Nn(o?3:1,r)}}function $_(n,e,t){if(Vr(e)){const r=e.directiveEnd;for(let s=e.directiveStart;s0;){const t=n[--e];if("number"==typeof t&&t<0)return t}return 0})(o)!=a&&o.push(a),o.push(t,i,s)}}(n,e,i,wf(n,t,r.hostVars,Dn),r)}function Cc(n,e,t,i,r,s){const o=Xs(n,e);!function ev(n,e,t,i,r,s,o){if(null==s)n.removeAttribute(e,r,t);else{const a=null==o?wn(s):o(s,i||"",r);n.setAttribute(e,r,a,t)}}(e[Hn],o,s,n.value,t,i,r)}function wC(n,e,t,i,r,s){const o=s[e];if(null!==o){const a=i.setInput;for(let c=0;c0&&iv(t)}}function iv(n){for(let i=pf(n);null!==i;i=f_(i))for(let r=gs;r0&&iv(s)}const t=n[xt].components;if(null!==t)for(let i=0;i0&&iv(r)}}function MC(n,e){const t=Os(e,n),i=t[xt];(function y1(n,e){for(let t=e.length;t-1&&(mf(e,i),Ru(t,i))}this._attachedToViewContainer=!1}m_(this._lView[xt],this._lView)}onDestroy(e){u1(this._lView[xt],this._lView,null,e)}markForCheck(){rv(this._cdRefInjectingView||this._lView)}detach(){this._lView[Sn]&=-65}reattach(){this._lView[Sn]|=64}detectChanges(){Rm(this._lView[xt],this._lView,this.context)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new Ue(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,function QE(n,e){Bu(n,e,e[Hn],2,null,null)}(this._lView[xt],this._lView)}attachToAppRef(e){if(this._attachedToViewContainer)throw new Ue(902,!1);this._appRef=e}}class CC extends Ef{constructor(e){super(e),this._view=e}detectChanges(){const e=this._view;Rm(e[xt],e,e[Ji],!1)}checkNoChanges(){}get context(){return null}}class M1 extends Fd{constructor(e){super(),this.ngModule=e}resolveComponentFactory(e){const t=Ei(e);return new Mf(t,this.ngModule)}}function C1(n){const e=[];for(let t in n)n.hasOwnProperty(t)&&e.push({propName:n[t],templateName:t});return e}class TC{constructor(e,t){this.injector=e,this.parentInjector=t}get(e,t,i){i=bu(i);const r=this.injector.get(e,P_,i);return r!==P_||t===P_?r:this.parentInjector.get(e,t,i)}}class Mf extends Lx{get inputs(){return C1(this.componentDef.inputs)}get outputs(){return C1(this.componentDef.outputs)}constructor(e,t){super(),this.componentDef=e,this.ngModule=t,this.componentType=e.type,this.selector=function zx(n){return n.map(Un).join(",")}(e.selectors),this.ngContentSelectors=e.ngContentSelectors?e.ngContentSelectors:[],this.isBoundToModule=!!t}create(e,t,i,r){let s=(r=r||this.ngModule)instanceof na?r:r?.injector;s&&null!==this.componentDef.getStandaloneInjector&&(s=this.componentDef.getStandaloneInjector(s)||s);const o=s?new TC(e,s):e,a=o.get(yn,null);if(null===a)throw new Ue(407,!1);const c=o.get(Rr,null),u=a.createRenderer(null,this.componentDef),p=this.componentDef.selectors[0][0]||"div",g=i?function hC(n,e,t){return n.selectRootElement(e,t===Ko.ShadowDom)}(u,i,this.componentDef.encapsulation):am(u,p,function DC(n){const e=n.toLowerCase();return"svg"===e?vd:"math"===e?"math":null}(p)),v=this.componentDef.onPush?288:272,y=Y_(0,null,null,1,0,null,null,null,null,null),x=Am(null,y,null,v,null,null,a,u,c,o,null);let T,N;Fi(x);try{const k=this.componentDef;let A,H=null;k.findHostDirectiveDefs?(A=[],H=new Map,k.findHostDirectiveDefs(k,A,H),A.push(k)):A=[k];const G=function kC(n,e){const t=n[xt],i=nn;return n[i]=e,Wu(t,i,2,"#host",null)}(x,g),X=function IC(n,e,t,i,r,s,o,a){const c=r[xt];!function FC(n,e,t,i){for(const r of n)e.mergedAttrs=Sd(e.mergedAttrs,r.hostAttrs);null!==e.mergedAttrs&&(Pm(e,e.mergedAttrs,!0),null!==t&&px(i,t,e))}(i,n,e,o);const u=s.createRenderer(e,t),p=Am(r,d1(t),null,t.onPush?32:16,r[n.index],n,s,u,a||null,null,null);return c.firstCreatePass&&J_(c,n,i.length-1),Fm(r,p),r[n.index]=p}(G,g,k,A,x,a,u);N=Ha(y,nn),g&&function m(n,e,t,i){if(i)jp(n,t,["ng-version",zl.full]);else{const{attrs:r,classes:s}=function wa(n){const e=[],t=[];let i=1,r=2;for(;i0&&fx(n,t,s.join(" "))}}(u,k,g,i),void 0!==t&&function S(n,e,t){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=e+=r.hostVars,r.hostAttrs=Sd(r.hostAttrs,t=Sd(t,r.hostAttrs))}}(i)}function me(n){return n===Na?{}:n===Si?[]:n}function Ee(n,e){const t=n.viewQuery;n.viewQuery=t?(i,r)=>{e(i,r),t(i,r)}:e}function qe(n,e){const t=n.contentQueries;n.contentQueries=t?(i,r,s)=>{e(i,r,s),t(i,r,s)}:e}function Ye(n,e){const t=n.hostBindings;n.hostBindings=t?(i,r)=>{e(i,r),t(i,r)}:e}function to(n){return!!Xa(n)&&(Array.isArray(n)||!(n instanceof Map)&&Symbol.iterator in n)}function Xa(n){return null!==n&&("function"==typeof n||"object"==typeof n)}function jl(n,e,t){return n[e]=t}function Vo(n,e,t){return!Object.is(n[e],t)&&(n[e]=t,!0)}function Cf(n,e,t,i){const r=Vo(n,e,t);return Vo(n,e+1,i)||r}function Di(n,e,t,i){const r=C();return Vo(r,be(),e)&&(B(),Cc(an(),r,n,e,t,i)),Di}function Nm(n,e,t,i){return Vo(n,be(),t)?e+wn(t)+i:Dn}function mt(n,e,t,i,r,s,o,a){const c=C(),u=B(),p=n+nn,g=u.firstCreatePass?function QV(n,e,t,i,r,s,o,a,c){const u=e.consts,p=Wu(e,n,4,o||null,h(u,a));X_(e,t,p,h(u,c)),Ro(e,p);const g=p.tViews=Y_(2,p,i,r,s,e.directiveRegistry,e.pipeRegistry,null,e.schemas,u);return null!==e.queries&&(e.queries.template(e,p),g.queries=e.queries.embeddedTView(p)),p}(p,u,c,e,t,i,r,s,o):u.data[p];Q(g,!1);const v=c[Hn].createComment("");lm(u,c,v,g),Ot(v,c),Fm(c,c[p]=v1(v,c,v,g)),ga(g)&&q_(u,c,g),null!=o&&K_(c,g,a)}function Tc(n){return yc(function Ae(){return b.lFrame.contextLView}(),nn+n)}function $e(n,e,t){const i=C();return Vo(i,be(),e)&&ra(B(),an(),i,n,e,i[Hn],t,!1),$e}function RC(n,e,t,i,r){const o=r?"class":"style";sv(n,t,e.inputs[o],o,i)}function ke(n,e,t,i){const r=C(),s=B(),o=nn+n,a=r[Hn],c=s.firstCreatePass?function tH(n,e,t,i,r,s){const o=e.consts,c=Wu(e,n,2,i,h(o,r));return X_(e,t,c,h(o,s)),null!==c.attrs&&Pm(c,c.attrs,!1),null!==c.mergedAttrs&&Pm(c,c.mergedAttrs,!0),null!==e.queries&&e.queries.elementStart(e,c),c}(o,s,r,e,t,i):s.data[o],u=r[o]=am(a,e,function _a(){return b.lFrame.currentNamespace}()),p=ga(c);return Q(c,!0),px(a,u,c),32!=(32&c.flags)&&lm(s,r,u,c),0===function D(){return b.lFrame.elementDepthCount}()&&Ot(u,r),function F(){b.lFrame.elementDepthCount++}(),p&&(q_(s,r,c),$_(s,c,r)),null!==i&&K_(r,c),ke}function Ne(){let n=L();te()?Se():(n=n.parent,Q(n,!1));const e=n;!function P(){b.lFrame.elementDepthCount--}();const t=B();return t.firstCreatePass&&(Ro(t,n),Vr(n)&&t.queries.elementEnd(n)),null!=e.classesWithoutHost&&function SE(n){return 0!=(8&n.flags)}(e)&&RC(t,e,C(),e.classesWithoutHost,!0),null!=e.stylesWithoutHost&&function EE(n){return 0!=(16&n.flags)}(e)&&RC(t,e,C(),e.stylesWithoutHost,!1),Ne}function qt(n,e,t,i){return ke(n,e,t,i),Ne(),qt}function av(n,e,t){const i=C(),r=B(),s=n+nn,o=r.firstCreatePass?function nH(n,e,t,i,r){const s=e.consts,o=h(s,i),a=Wu(e,n,8,"ng-container",o);return null!==o&&Pm(a,o,!0),X_(e,t,a,h(s,r)),null!==e.queries&&e.queries.elementStart(e,a),a}(s,r,i,e,t):r.data[s];Q(o,!0);const a=i[s]=i[Hn].createComment("");return lm(r,i,a,o),Ot(a,i),ga(o)&&(q_(r,i,o),$_(r,o,i)),null!=t&&K_(i,o),av}function cv(){let n=L();const e=B();return te()?Se():(n=n.parent,Q(n,!1)),e.firstCreatePass&&(Ro(e,n),Vr(n)&&e.queries.elementEnd(n)),cv}function Df(){return C()}function lv(n){return!!n&&"function"==typeof n.then}function kF(n){return!!n&&"function"==typeof n.subscribe}const PC=kF;function Gn(n,e,t,i){const r=C(),s=B(),o=L();return IF(s,r,r[Hn],o,n,e,i),Gn}function OC(n,e){const t=L(),i=C(),r=B();return IF(r,i,S1(Lt(r.data),t,i),t,n,e),OC}function IF(n,e,t,i,r,s,o){const a=ga(i),u=n.firstCreatePass&&w1(n),p=e[Ji],g=x1(e);let v=!0;if(3&i.type||o){const T=Xs(i,e),N=o?o(T):T,k=g.length,A=o?G=>o(Zt(G[i.index])):i.index;let H=null;if(!o&&a&&(H=function iH(n,e,t,i){const r=n.cleanup;if(null!=r)for(let s=0;sc?a[c]:null}"string"==typeof o&&(s+=2)}return null}(n,e,r,i.index)),null!==H)(H.__ngLastListenerFn__||H).__ngNextListenerFn__=s,H.__ngLastListenerFn__=s,v=!1;else{s=RF(i,e,p,s,!1);const G=t.listen(N,r,s);g.push(s,G),u&&u.push(r,A,k,k+1)}}else s=RF(i,e,p,s,!1);const y=i.outputs;let x;if(v&&null!==y&&(x=y[r])){const T=x.length;if(T)for(let N=0;N-1?Os(n.index,e):e);let c=FF(e,t,i,o),u=s.__ngNextListenerFn__;for(;u;)c=FF(e,t,u,o)&&c,u=u.__ngNextListenerFn__;return r&&!1===c&&(o.preventDefault(),o.returnValue=!1),c}}function Jt(n=1){return function Mr(n){return(b.lFrame.contextLView=function Qi(n,e){for(;n>0;)e=e[Ir],n--;return e}(n,b.lFrame.contextLView))[Ji]}(n)}function rH(n,e){let t=null;const i=function XM(n){const e=n.attrs;if(null!=e){const t=e.indexOf(5);if(!(1&t))return e[t+1]}return null}(n);for(let r=0;r>17&32767}function NC(n){return 2|n}function Tf(n){return(131068&n)>>2}function BC(n,e){return-131069&n|e<<2}function VC(n){return 1|n}function GF(n,e,t,i,r){const s=n[t+1],o=null===e;let a=i?$u(s):Tf(s),c=!1;for(;0!==a&&(!1===c||o);){const p=n[a+1];dH(n[a],e)&&(c=!0,n[a+1]=i?VC(p):NC(p)),a=i?$u(p):Tf(p)}c&&(n[t+1]=i?NC(s):VC(s))}function dH(n,e){return null===n||null==e||(Array.isArray(n)?n[1]:n)===e||!(!Array.isArray(n)||"string"!=typeof e)&&Pu(n,e)>=0}const Us={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function jF(n){return n.substring(Us.key,Us.keyEnd)}function WF(n,e){const t=Us.textEnd;return t===e?-1:(e=Us.keyEnd=function pH(n,e,t){for(;e32;)e++;return e}(n,Us.key=e,t),Wm(n,e,t))}function Wm(n,e,t){for(;e=0;t=WF(e,t))Ns(n,jF(e),!0)}function sl(n,e,t,i){const r=C(),s=B(),o=ce(2);s.firstUpdatePass&&ZF(s,n,o,i),e!==Dn&&Vo(r,o,e)&&QF(s,s.data[ii()],r,r[Hn],n,r[o+1]=function MH(n,e){return null==n||("string"==typeof e?n+=e:"object"==typeof n&&(n=ki(ta(n)))),n}(e,t),i,o)}function XF(n,e){return e>=n.expandoStartIndex}function ZF(n,e,t,i){const r=n.data;if(null===r[t+1]){const s=r[ii()],o=XF(n,t);tR(s,i)&&null===e&&!o&&(e=!1),e=function yH(n,e,t,i){const r=Lt(n);let s=i?e.residualClasses:e.residualStyles;if(null===r)0===(i?e.classBindings:e.styleBindings)&&(t=uv(t=HC(null,n,e,t,i),e.attrs,i),s=null);else{const o=e.directiveStylingLast;if(-1===o||n[o]!==r)if(t=HC(r,n,e,t,i),null===s){let c=function bH(n,e,t){const i=t?e.classBindings:e.styleBindings;if(0!==Tf(i))return n[$u(i)]}(n,e,i);void 0!==c&&Array.isArray(c)&&(c=HC(null,n,e,c[1],i),c=uv(c,e.attrs,i),function xH(n,e,t,i){n[$u(t?e.classBindings:e.styleBindings)]=i}(n,e,i,c))}else s=function wH(n,e,t){let i;const r=e.directiveEnd;for(let s=1+e.directiveStylingLast;s0)&&(u=!0)):p=t,r)if(0!==c){const v=$u(n[a+1]);n[i+1]=A1(v,a),0!==v&&(n[v+1]=BC(n[v+1],i)),n[a+1]=function oH(n,e){return 131071&n|e<<17}(n[a+1],i)}else n[i+1]=A1(a,0),0!==a&&(n[a+1]=BC(n[a+1],i)),a=i;else n[i+1]=A1(c,0),0===a?a=i:n[c+1]=BC(n[c+1],i),c=i;u&&(n[i+1]=NC(n[i+1])),GF(n,p,i,!0),GF(n,p,i,!1),function lH(n,e,t,i,r){const s=r?n.residualClasses:n.residualStyles;null!=s&&"string"==typeof e&&Pu(s,e)>=0&&(t[i+1]=VC(t[i+1]))}(e,p,n,i,s),o=A1(a,c),s?e.classBindings=o:e.styleBindings=o}(r,s,e,t,o,i)}}function HC(n,e,t,i,r){let s=null;const o=t.directiveEnd;let a=t.directiveStylingLast;for(-1===a?a=t.directiveStart:a++;a0;){const c=n[r],u=Array.isArray(c),p=u?c[1]:c,g=null===p;let v=t[r+1];v===Dn&&(v=g?Si:void 0);let y=g?Zp(v,i):p===i?v:void 0;if(u&&!k1(y)&&(y=Zp(c,i)),k1(y)&&(a=y,o))return a;const x=n[r+1];r=o?$u(x):Tf(x)}if(null!==e){let c=s?e.residualClasses:e.residualStyles;null!=c&&(a=Zp(c,i))}return a}function k1(n){return void 0!==n}function tR(n,e){return 0!=(n.flags&(e?8:16))}function it(n,e=""){const t=C(),i=B(),r=n+nn,s=i.firstCreatePass?Wu(i,r,1,e,null):i.data[r],o=t[r]=function p_(n,e){return n.createText(e)}(t[Hn],e);lm(i,t,o,s),Q(s,!1)}function Hi(n){return xs("",n,""),Hi}function xs(n,e,t){const i=C(),r=Nm(i,n,e,t);return r!==Dn&&function rl(n,e,t){const i=Jh(e,n);!function Nu(n,e,t){n.setValue(e,t)}(n[Hn],i,t)}(i,ii(),r),xs}function dR(n,e,t){!function ol(n,e,t,i){const r=B(),s=ce(2);r.firstUpdatePass&&ZF(r,null,s,i);const o=C();if(t!==Dn&&Vo(o,s,t)){const a=r.data[ii()];if(tR(a,i)&&!XF(r,s)){let c=i?a.classesWithoutHost:a.stylesWithoutHost;null!==c&&(t=fu(c,t||"")),RC(r,a,o,t,i)}else!function EH(n,e,t,i,r,s,o,a){r===Dn&&(r=Si);let c=0,u=0,p=0((Dt=Dt||{})[Dt.LocaleId=0]="LocaleId",Dt[Dt.DayPeriodsFormat=1]="DayPeriodsFormat",Dt[Dt.DayPeriodsStandalone=2]="DayPeriodsStandalone",Dt[Dt.DaysFormat=3]="DaysFormat",Dt[Dt.DaysStandalone=4]="DaysStandalone",Dt[Dt.MonthsFormat=5]="MonthsFormat",Dt[Dt.MonthsStandalone=6]="MonthsStandalone",Dt[Dt.Eras=7]="Eras",Dt[Dt.FirstDayOfWeek=8]="FirstDayOfWeek",Dt[Dt.WeekendRange=9]="WeekendRange",Dt[Dt.DateFormat=10]="DateFormat",Dt[Dt.TimeFormat=11]="TimeFormat",Dt[Dt.DateTimeFormat=12]="DateTimeFormat",Dt[Dt.NumberSymbols=13]="NumberSymbols",Dt[Dt.NumberFormats=14]="NumberFormats",Dt[Dt.CurrencyCode=15]="CurrencyCode",Dt[Dt.CurrencySymbol=16]="CurrencySymbol",Dt[Dt.CurrencyName=17]="CurrencyName",Dt[Dt.Currencies=18]="Currencies",Dt[Dt.Directionality=19]="Directionality",Dt[Dt.PluralCase=20]="PluralCase",Dt[Dt.ExtraData=21]="ExtraData",Dt))();const qm="en-US";let wR=qm;function jC(n,e,t,i,r){if(n=en(n),Array.isArray(n))for(let s=0;s>20;if(Ul(n)||!n.multi){const y=new Qh(c,r,ie),x=$C(a,e,r?p:p+v,g);-1===x?(q0(Ga(u,o),s,a),WC(s,n,e.length),e.push(a),u.directiveStart++,u.directiveEnd++,r&&(u.providerIndexes+=1048576),t.push(y),o.push(y)):(t[x]=y,o[x]=y)}else{const y=$C(a,e,p+v,g),x=$C(a,e,p,p+v),N=x>=0&&t[x];if(r&&!N||!r&&!(y>=0&&t[y])){q0(Ga(u,o),s,a);const k=function GU(n,e,t,i,r){const s=new Qh(n,t,ie);return s.multi=[],s.index=e,s.componentProviders=0,qR(s,r,i&&!t),s}(r?zU:UU,t.length,r,i,c);!r&&N&&(t[x].providerFactory=k),WC(s,n,e.length,0),e.push(a),u.directiveStart++,u.directiveEnd++,r&&(u.providerIndexes+=1048576),t.push(k),o.push(k)}else WC(s,n,y>-1?y:x,qR(t[r?x:y],c,!r&&i));!r&&i&&N&&t[x].componentProviders++}}}function WC(n,e,t,i){const r=Ul(e),s=function Ox(n){return!!n.useClass}(e);if(r||s){const c=(s?en(e.useClass):e).prototype.ngOnDestroy;if(c){const u=n.destroyHooks||(n.destroyHooks=[]);if(!r&&e.multi){const p=u.indexOf(t);-1===p?u.push(t,[i,c]):u[p+1].push(i,c)}else u.push(t,c)}}}function qR(n,e,t){return t&&n.componentProviders++,n.multi.push(e)-1}function $C(n,e,t,i){for(let r=t;r{t.providersResolver=(i,r)=>function HU(n,e,t){const i=B();if(i.firstCreatePass){const r=Fo(n);jC(t,i.data,i.blueprint,r,!0),jC(e,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,e)}}class Km{}class KR{}class YR extends Km{constructor(e,t){super(),this._parent=t,this._bootstrapComponents=[],this.destroyCbs=[],this.componentFactoryResolver=new M1(this);const i=po(e);this._bootstrapComponents=il(i.bootstrap),this._r3Injector=Kx(e,t,[{provide:Km,useValue:this},{provide:Fd,useValue:this.componentFactoryResolver}],ki(e),new Set(["environment"])),this._r3Injector.resolveInjectorInitializers(),this.instance=this._r3Injector.get(e)}get injector(){return this._r3Injector}destroy(){const e=this._r3Injector;!e.destroyed&&e.destroy(),this.destroyCbs.forEach(t=>t()),this.destroyCbs=null}onDestroy(e){this.destroyCbs.push(e)}}class KC extends KR{constructor(e){super(),this.moduleType=e}create(e){return new YR(this.moduleType,e)}}class WU extends Km{constructor(e,t,i){super(),this.componentFactoryResolver=new M1(this),this.instance=null;const r=new xf([...e,{provide:Km,useValue:this},{provide:Fd,useValue:this.componentFactoryResolver}],t||Sm(),i,new Set(["environment"]));this.injector=r,r.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(e){this.injector.onDestroy(e)}}function O1(n,e,t=null){return new WU(n,e,t).injector}let $U=(()=>{class n{constructor(t){this._injector=t,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(t){if(!t.standalone)return null;if(!this.cachedInjectors.has(t.id)){const i=Rx(0,t.type),r=i.length>0?O1([i],this._injector,`Standalone[${t.type.name}]`):null;this.cachedInjectors.set(t.id,r)}return this.cachedInjectors.get(t.id)}ngOnDestroy(){try{for(const t of this.cachedInjectors.values())null!==t&&t.destroy()}finally{this.cachedInjectors.clear()}}}return n.\u0275prov=Je({token:n,providedIn:"environment",factory:()=>new n(xe(na))}),n})();function _v(n){n.getStandaloneInjector=e=>e.get($U).getOrCreateStandaloneInjector(n)}function qu(n,e,t,i){return iP(C(),ee(),n,e,t,i)}function XC(n,e,t,i,r,s){return sP(C(),ee(),n,e,t,i,r,s)}function vv(n,e){const t=n[e];return t===Dn?void 0:t}function iP(n,e,t,i,r,s){const o=e+t;return Vo(n,o,r)?jl(n,o+1,s?i.call(s,r):i(r)):vv(n,o+1)}function rP(n,e,t,i,r,s,o){const a=e+t;return Cf(n,a,r,s)?jl(n,a+2,o?i.call(o,r,s):i(r,s)):vv(n,a+2)}function sP(n,e,t,i,r,s,o,a){const c=e+t;return function T1(n,e,t,i,r){const s=Cf(n,e,t,i);return Vo(n,e+2,r)||s}(n,c,r,s,o)?jl(n,c+3,a?i.call(a,r,s,o):i(r,s,o)):vv(n,c+3)}function ft(n,e){const t=B();let i;const r=n+nn;t.firstCreatePass?(i=function c9(n,e){if(e)for(let t=e.length-1;t>=0;t--){const i=e[t];if(n===i.name)return i}}(e,t.pipeRegistry),t.data[r]=i,i.onDestroy&&(t.destroyHooks||(t.destroyHooks=[])).push(r,i.onDestroy)):i=t.data[r];const s=i.factory||(i.factory=qn(i.type)),o=ho(ie);try{const a=Mu(!1),c=s();return Mu(a),function eH(n,e,t,i){t>=n.data.length&&(n.data[t]=null,n.blueprint[t]=null),e[t]=i}(t,C(),r,c),c}finally{ho(o)}}function vn(n,e,t){const i=n+nn,r=C(),s=yc(r,i);return bv(r,i)?iP(r,ee(),e,s.transform,t,s):s.transform(t)}function Ti(n,e,t,i){const r=n+nn,s=C(),o=yc(s,r);return bv(s,r)?rP(s,ee(),e,o.transform,t,i,o):o.transform(t,i)}function yv(n,e,t,i,r){const s=n+nn,o=C(),a=yc(o,s);return bv(o,s)?sP(o,ee(),e,a.transform,t,i,r,a):a.transform(t,i,r)}function bv(n,e){return n[xt].data[e].pure}function ZC(n){return e=>{setTimeout(n,void 0,e)}}const Pn=class u9 extends cn{constructor(e=!1){super(),this.__isAsync=e}emit(e){super.next(e)}subscribe(e,t,i){let r=e,s=t||(()=>null),o=i;if(e&&"object"==typeof e){const c=e;r=c.next?.bind(c),s=c.error?.bind(c),o=c.complete?.bind(c)}this.__isAsync&&(s=ZC(s),r&&(r=ZC(r)),o&&(o=ZC(o)));const a=super.subscribe({next:r,error:s,complete:o});return e instanceof Tn&&e.add(a),a}};function h9(){return this._results[Symbol.iterator]()}class xv{get changes(){return this._changes||(this._changes=new Pn)}constructor(e=!1){this._emitDistinctChangesOnly=e,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=null,this.length=0,this.first=void 0,this.last=void 0;const t=xv.prototype;t[Symbol.iterator]||(t[Symbol.iterator]=h9)}get(e){return this._results[e]}map(e){return this._results.map(e)}filter(e){return this._results.filter(e)}find(e){return this._results.find(e)}reduce(e,t){return this._results.reduce(e,t)}forEach(e){this._results.forEach(e)}some(e){return this._results.some(e)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(e,t){const i=this;i.dirty=!1;const r=function ya(n){return n.flat(Number.POSITIVE_INFINITY)}(e);(this._changesDetected=!function Nb(n,e,t){if(n.length!==e.length)return!1;for(let i=0;i{class n{}return n.__NG_ELEMENT_ID__=m9,n})();const f9=al,p9=class extends f9{constructor(e,t,i){super(),this._declarationLView=e,this._declarationTContainer=t,this.elementRef=i}createEmbeddedView(e,t){const i=this._declarationTContainer.tViews,r=Am(this._declarationLView,i,e,16,null,i.declTNode,null,null,null,null,t||null);r[kl]=this._declarationLView[this._declarationTContainer.index];const o=this._declarationLView[Qr];return null!==o&&(r[Qr]=o.createEmbeddedView(i)),W_(i,r,e),new Ef(r)}};function m9(){return L1(L(),C())}function L1(n,e){return 4&n.type?new p9(e,n,zu(n,e)):null}let Sa=(()=>{class n{}return n.__NG_ELEMENT_ID__=g9,n})();function g9(){return dP(L(),C())}const _9=Sa,cP=class extends _9{constructor(e,t,i){super(),this._lContainer=e,this._hostTNode=t,this._hostLView=i}get element(){return zu(this._hostTNode,this._hostLView)}get injector(){return new Tu(this._hostTNode,this._hostLView)}get parentInjector(){const e=Du(this._hostTNode,this._hostLView);if(ef(e)){const t=$p(e,this._hostLView),i=Wp(e);return new Tu(t[xt].data[i+8],t)}return new Tu(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(e){const t=lP(this._lContainer);return null!==t&&t[e]||null}get length(){return this._lContainer.length-gs}createEmbeddedView(e,t,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const o=e.createEmbeddedView(t||{},s);return this.insert(o,r),o}createComponent(e,t,i,r,s){const o=e&&!function rf(n){return"function"==typeof n}(e);let a;if(o)a=t;else{const g=t||{};a=g.index,i=g.injector,r=g.projectableNodes,s=g.environmentInjector||g.ngModuleRef}const c=o?e:new Mf(Ei(e)),u=i||this.parentInjector;if(!s&&null==c.ngModule){const v=(o?u:this.parentInjector).get(na,null);v&&(s=v)}const p=c.create(u,r,void 0,s);return this.insert(p.hostView,a),p}insert(e,t){const i=e._lView,r=i[xt];if(function l(n){return Yo(n[Zi])}(i)){const p=this.indexOf(e);if(-1!==p)this.detach(p);else{const g=i[Zi],v=new cP(g,g[Br],g[Zi]);v.detach(v.indexOf(e))}}const s=this._adjustIndex(t),o=this._lContainer;!function nx(n,e,t,i){const r=gs+i,s=t.length;i>0&&(t[r-1][si]=e),i0)i.push(o[a/2]);else{const u=s[a+1],p=e[-c];for(let g=gs;g{class n{constructor(t){this.appInits=t,this.resolve=B1,this.reject=B1,this.initialized=!1,this.done=!1,this.donePromise=new Promise((i,r)=>{this.resolve=i,this.reject=r})}runInitializers(){if(this.initialized)return;const t=[],i=()=>{this.done=!0,this.resolve()};if(this.appInits)for(let r=0;r{s.subscribe({complete:a,error:c})});t.push(o)}}Promise.all(t).then(()=>{i()}).catch(r=>{this.reject(r)}),0===t.length&&i(),this.initialized=!0}}return n.\u0275fac=function(t){return new(t||n)(xe(V1,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const Zm=new Ze("AppId",{providedIn:"root",factory:function RP(){return`${lD()}${lD()}${lD()}`}});function lD(){return String.fromCharCode(97+Math.floor(25*Math.random()))}const PP=new Ze("Platform Initializer"),U1=new Ze("Platform ID",{providedIn:"platform",factory:()=>"unknown"}),OP=new Ze("appBootstrapListener"),bo=new Ze("AnimationModuleType");let G9=(()=>{class n{log(t){console.log(t)}warn(t){console.warn(t)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})();const Ac=new Ze("LocaleId",{providedIn:"root",factory:()=>hn(Ac,tn.Optional|tn.SkipSelf)||function j9(){return typeof $localize<"u"&&$localize.locale||qm}()});class $9{constructor(e,t){this.ngModuleFactory=e,this.componentFactories=t}}let LP=(()=>{class n{compileModuleSync(t){return new KC(t)}compileModuleAsync(t){return Promise.resolve(this.compileModuleSync(t))}compileModuleAndAllComponentsSync(t){const i=this.compileModuleSync(t),s=il(po(t).declarations).reduce((o,a)=>{const c=Ei(a);return c&&o.push(new Mf(c)),o},[]);return new $9(i,s)}compileModuleAndAllComponentsAsync(t){return Promise.resolve(this.compileModuleAndAllComponentsSync(t))}clearCache(){}clearCacheFor(t){}getModuleId(t){}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const Y9=(()=>Promise.resolve(0))();function dD(n){typeof Zone>"u"?Y9.then(()=>{n&&n.apply(null,null)}):Zone.current.scheduleMicroTask("scheduleMicrotask",n)}class Xt{constructor({enableLongStackTrace:e=!1,shouldCoalesceEventChangeDetection:t=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Pn(!1),this.onMicrotaskEmpty=new Pn(!1),this.onStable=new Pn(!1),this.onError=new Pn(!1),typeof Zone>"u")throw new Ue(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),e&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&t,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function X9(){let n=Ii.requestAnimationFrame,e=Ii.cancelAnimationFrame;if(typeof Zone<"u"&&n&&e){const t=n[Zone.__symbol__("OriginalDelegate")];t&&(n=t);const i=e[Zone.__symbol__("OriginalDelegate")];i&&(e=i)}return{nativeRequestAnimationFrame:n,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function Q9(n){const e=()=>{!function J9(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(Ii,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,hD(n),n.isCheckStableRunning=!0,uD(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),hD(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(t,i,r,s,o,a)=>{try{return VP(n),t.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&e(),HP(n)}},onInvoke:(t,i,r,s,o,a,c)=>{try{return VP(n),t.invoke(r,s,o,a,c)}finally{n.shouldCoalesceRunChangeDetection&&e(),HP(n)}},onHasTask:(t,i,r,s)=>{t.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,hD(n),uD(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(t,i,r,s)=>(t.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Xt.isInAngularZone())throw new Ue(909,!1)}static assertNotInAngularZone(){if(Xt.isInAngularZone())throw new Ue(909,!1)}run(e,t,i){return this._inner.run(e,t,i)}runTask(e,t,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,e,Z9,B1,B1);try{return s.runTask(o,t,i)}finally{s.cancelTask(o)}}runGuarded(e,t,i){return this._inner.runGuarded(e,t,i)}runOutsideAngular(e){return this._outer.run(e)}}const Z9={};function uD(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function hD(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function VP(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function HP(n){n._nesting--,uD(n)}class e7{constructor(){this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new Pn,this.onMicrotaskEmpty=new Pn,this.onStable=new Pn,this.onError=new Pn}run(e,t,i){return e.apply(t,i)}runGuarded(e,t,i){return e.apply(t,i)}runOutsideAngular(e){return e()}runTask(e,t,i,r){return e.apply(t,i)}}const UP=new Ze(""),z1=new Ze("");let mD,fD=(()=>{class n{constructor(t,i,r){this._ngZone=t,this.registry=i,this._pendingCount=0,this._isZoneStable=!0,this._didWork=!1,this._callbacks=[],this.taskTrackingZone=null,mD||(function t7(n){mD=n}(r),r.addToWindow(i)),this._watchAngularEvents(),t.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:()=>{Xt.assertNotInAngularZone(),dD(()=>{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())dD(()=>{for(;0!==this._callbacks.length;){let t=this._callbacks.pop();clearTimeout(t.timeoutId),t.doneCb(this._didWork)}this._didWork=!1});else{let t=this.getPendingTasks();this._callbacks=this._callbacks.filter(i=>!i.updateCb||!i.updateCb(t)||(clearTimeout(i.timeoutId),!1)),this._didWork=!0}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(t=>({source:t.source,creationLocation:t.creationLocation,data:t.data})):[]}addCallback(t,i,r){let s=-1;i&&i>0&&(s=setTimeout(()=>{this._callbacks=this._callbacks.filter(o=>o.timeoutId!==s),t(this._didWork,this.getPendingTasks())},i)),this._callbacks.push({doneCb:t,timeoutId:s,updateCb:r})}whenStable(t,i,r){if(r&&!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(t,i,r),this._runCallbacksIfReady()}getPendingRequestCount(){return this._pendingCount}registerApplication(t){this.registry.registerApplication(t,this)}unregisterApplication(t){this.registry.unregisterApplication(t)}findProviders(t,i,r){return[]}}return n.\u0275fac=function(t){return new(t||n)(xe(Xt),xe(pD),xe(z1))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),pD=(()=>{class n{constructor(){this._applications=new Map}registerApplication(t,i){this._applications.set(t,i)}unregisterApplication(t){this._applications.delete(t)}unregisterAllApplications(){this._applications.clear()}getTestability(t){return this._applications.get(t)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(t,i=!0){return mD?.findTestabilityInTree(this,t,i)??null}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})(),Ku=null;const zP=new Ze("AllowMultipleToken"),gD=new Ze("PlatformDestroyListeners"),Ld=!1;class GP{constructor(e,t){this.name=e,this.token=t}}function WP(n,e,t=[]){const i=`Platform: ${e}`,r=new Ze(i);return(s=[])=>{let o=_D();if(!o||o.injector.get(zP,!1)){const a=[...t,...s,{provide:r,useValue:!0}];n?n(a):function r7(n){if(Ku&&!Ku.get(zP,!1))throw new Ue(400,!1);Ku=n;const e=n.get(qP);(function jP(n){const e=n.get(PP,null);e&&e.forEach(t=>t())})(n)}(function $P(n=[],e){return ts.create({name:e,providers:[{provide:wm,useValue:"platform"},{provide:gD,useValue:new Set([()=>Ku=null])},...n]})}(a,i))}return function o7(n){const e=_D();if(!e)throw new Ue(401,!1);return e}()}}function _D(){return Ku?.get(qP)??null}let qP=(()=>{class n{constructor(t){this._injector=t,this._modules=[],this._destroyListeners=[],this._destroyed=!1}bootstrapModuleFactory(t,i){const r=function YP(n,e){let t;return t="noop"===n?new e7:("zone.js"===n?void 0:n)||new Xt(e),t}(i?.ngZone,function KP(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:!(!n||!n.ngZoneEventCoalescing)||!1,shouldCoalesceRunChangeDetection:!(!n||!n.ngZoneRunCoalescing)||!1}}(i)),s=[{provide:Xt,useValue:r}];return r.run(()=>{const o=ts.create({providers:s,parent:this.injector,name:t.moduleType.name}),a=t.create(o),c=a.injector.get(tl,null);if(!c)throw new Ue(402,!1);return r.runOutsideAngular(()=>{const u=r.onError.subscribe({next:p=>{c.handleError(p)}});a.onDestroy(()=>{G1(this._modules,a),u.unsubscribe()})}),function XP(n,e,t){try{const i=t();return lv(i)?i.catch(r=>{throw e.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw e.runOutsideAngular(()=>n.handleError(i)),i}}(c,r,()=>{const u=a.injector.get(H1);return u.runInitializers(),u.donePromise.then(()=>(function SR(n){Rs(n,"Expected localeId to be defined"),"string"==typeof n&&(wR=n.toLowerCase().replace(/_/g,"-"))}(a.injector.get(Ac,qm)||qm),this._moduleDoBootstrap(a),a))})})}bootstrapModule(t,i=[]){const r=ZP({},i);return function n7(n,e,t){const i=new KC(t);return Promise.resolve(i)}(0,0,t).then(s=>this.bootstrapModuleFactory(s,r))}_moduleDoBootstrap(t){const i=t.injector.get(Jm);if(t._bootstrapComponents.length>0)t._bootstrapComponents.forEach(r=>i.bootstrap(r));else{if(!t.instance.ngDoBootstrap)throw new Ue(-403,!1);t.instance.ngDoBootstrap(i)}this._modules.push(t)}onDestroy(t){this._destroyListeners.push(t)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new Ue(404,!1);this._modules.slice().forEach(i=>i.destroy()),this._destroyListeners.forEach(i=>i());const t=this._injector.get(gD,null);t&&(t.forEach(i=>i()),t.clear()),this._destroyed=!0}get destroyed(){return this._destroyed}}return n.\u0275fac=function(t){return new(t||n)(xe(ts))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"platform"}),n})();function ZP(n,e){return Array.isArray(e)?e.reduce(ZP,n):{...n,...e}}let Jm=(()=>{class n{get destroyed(){return this._destroyed}get injector(){return this._injector}constructor(t,i,r){this._zone=t,this._injector=i,this._exceptionHandler=r,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 s=new un(a=>{this._stable=this._zone.isStable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks,this._zone.runOutsideAngular(()=>{a.next(this._stable),a.complete()})}),o=new un(a=>{let c;this._zone.runOutsideAngular(()=>{c=this._zone.onStable.subscribe(()=>{Xt.assertNotInAngularZone(),dD(()=>{!this._stable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks&&(this._stable=!0,a.next(!0))})})});const u=this._zone.onUnstable.subscribe(()=>{Xt.assertInAngularZone(),this._stable&&(this._stable=!1,this._zone.runOutsideAngular(()=>{a.next(!1)}))});return()=>{c.unsubscribe(),u.unsubscribe()}});this.isStable=fa(s,o.pipe(Dp()))}bootstrap(t,i){const r=t instanceof Lx;if(!this._injector.get(H1).done){!r&&function Zr(n){const e=Ei(n)||Ni(n)||Ps(n);return null!==e&&e.standalone}(t);throw new Ue(405,Ld)}let o;o=r?t:this._injector.get(Fd).resolveComponentFactory(t),this.componentTypes.push(o.componentType);const a=function i7(n){return n.isBoundToModule}(o)?void 0:this._injector.get(Km),u=o.create(ts.NULL,[],i||o.selector,a),p=u.location.nativeElement,g=u.injector.get(UP,null);return g?.registerApplication(p),u.onDestroy(()=>{this.detachView(u.hostView),G1(this.components,u),g?.unregisterApplication(p)}),this._loadComponent(u),u}tick(){if(this._runningTick)throw new Ue(101,!1);try{this._runningTick=!0;for(let t of this._views)t.detectChanges()}catch(t){this._zone.runOutsideAngular(()=>this._exceptionHandler.handleError(t))}finally{this._runningTick=!1}}attachView(t){const i=t;this._views.push(i),i.attachToAppRef(this)}detachView(t){const i=t;G1(this._views,i),i.detachFromAppRef()}_loadComponent(t){this.attachView(t.hostView),this.tick(),this.components.push(t);const i=this._injector.get(OP,[]);i.push(...this._bootstrapListeners),i.forEach(r=>r(t))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(t=>t()),this._views.slice().forEach(t=>t.destroy()),this._onMicrotaskEmptySubscription.unsubscribe()}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(t){return this._destroyListeners.push(t),()=>G1(this._destroyListeners,t)}destroy(){if(this._destroyed)throw new Ue(406,!1);const t=this._injector;t.destroy&&!t.destroyed&&t.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}}return n.\u0275fac=function(t){return new(t||n)(xe(Xt),xe(na),xe(tl))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function G1(n,e){const t=n.indexOf(e);t>-1&&n.splice(t,1)}let aa=(()=>{class n{}return n.__NG_ELEMENT_ID__=c7,n})();function c7(n){return function l7(n,e,t){if(_s(n)&&!t){const i=Os(n.index,e);return new Ef(i,i)}return 47&n.type?new Ef(e[Jr],e):null}(L(),C(),16==(16&n))}class n3{constructor(){}supports(e){return to(e)}create(e){return new m7(e)}}const p7=(n,e)=>e;class m7{constructor(e){this.length=0,this._linkedRecords=null,this._unlinkedRecords=null,this._previousItHead=null,this._itHead=null,this._itTail=null,this._additionsHead=null,this._additionsTail=null,this._movesHead=null,this._movesTail=null,this._removalsHead=null,this._removalsTail=null,this._identityChangesHead=null,this._identityChangesTail=null,this._trackByFn=e||p7}forEachItem(e){let t;for(t=this._itHead;null!==t;t=t._next)e(t)}forEachOperation(e){let t=this._itHead,i=this._removalsHead,r=0,s=null;for(;t||i;){const o=!i||t&&t.currentIndex{o=this._trackByFn(r,a),null!==t&&Object.is(t.trackById,o)?(i&&(t=this._verifyReinsertion(t,a,o,r)),Object.is(t.item,a)||this._addIdentityChange(t,a)):(t=this._mismatch(t,a,o,r),i=!0),t=t._next,r++}),this.length=r;return this._truncate(t),this.collection=e,this.isDirty}get isDirty(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}_reset(){if(this.isDirty){let e;for(e=this._previousItHead=this._itHead;null!==e;e=e._next)e._nextPrevious=e._next;for(e=this._additionsHead;null!==e;e=e._nextAdded)e.previousIndex=e.currentIndex;for(this._additionsHead=this._additionsTail=null,e=this._movesHead;null!==e;e=e._nextMoved)e.previousIndex=e.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(e,t,i,r){let s;return null===e?s=this._itTail:(s=e._prev,this._remove(e)),null!==(e=null===this._unlinkedRecords?null:this._unlinkedRecords.get(i,null))?(Object.is(e.item,t)||this._addIdentityChange(e,t),this._reinsertAfter(e,s,r)):null!==(e=null===this._linkedRecords?null:this._linkedRecords.get(i,r))?(Object.is(e.item,t)||this._addIdentityChange(e,t),this._moveAfter(e,s,r)):e=this._addAfter(new g7(t,i),s,r),e}_verifyReinsertion(e,t,i,r){let s=null===this._unlinkedRecords?null:this._unlinkedRecords.get(i,null);return null!==s?e=this._reinsertAfter(s,e._prev,r):e.currentIndex!=r&&(e.currentIndex=r,this._addToMoves(e,r)),e}_truncate(e){for(;null!==e;){const t=e._next;this._addToRemovals(this._unlink(e)),e=t}null!==this._unlinkedRecords&&this._unlinkedRecords.clear(),null!==this._additionsTail&&(this._additionsTail._nextAdded=null),null!==this._movesTail&&(this._movesTail._nextMoved=null),null!==this._itTail&&(this._itTail._next=null),null!==this._removalsTail&&(this._removalsTail._nextRemoved=null),null!==this._identityChangesTail&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(e,t,i){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(e);const r=e._prevRemoved,s=e._nextRemoved;return null===r?this._removalsHead=s:r._nextRemoved=s,null===s?this._removalsTail=r:s._prevRemoved=r,this._insertAfter(e,t,i),this._addToMoves(e,i),e}_moveAfter(e,t,i){return this._unlink(e),this._insertAfter(e,t,i),this._addToMoves(e,i),e}_addAfter(e,t,i){return this._insertAfter(e,t,i),this._additionsTail=null===this._additionsTail?this._additionsHead=e:this._additionsTail._nextAdded=e,e}_insertAfter(e,t,i){const r=null===t?this._itHead:t._next;return e._next=r,e._prev=t,null===r?this._itTail=e:r._prev=e,null===t?this._itHead=e:t._next=e,null===this._linkedRecords&&(this._linkedRecords=new i3),this._linkedRecords.put(e),e.currentIndex=i,e}_remove(e){return this._addToRemovals(this._unlink(e))}_unlink(e){null!==this._linkedRecords&&this._linkedRecords.remove(e);const t=e._prev,i=e._next;return null===t?this._itHead=i:t._next=i,null===i?this._itTail=t:i._prev=t,e}_addToMoves(e,t){return e.previousIndex===t||(this._movesTail=null===this._movesTail?this._movesHead=e:this._movesTail._nextMoved=e),e}_addToRemovals(e){return null===this._unlinkedRecords&&(this._unlinkedRecords=new i3),this._unlinkedRecords.put(e),e.currentIndex=null,e._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=e,e._prevRemoved=null):(e._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=e),e}_addIdentityChange(e,t){return e.item=t,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=e:this._identityChangesTail._nextIdentityChange=e,e}}class g7{constructor(e,t){this.item=e,this.trackById=t,this.currentIndex=null,this.previousIndex=null,this._nextPrevious=null,this._prev=null,this._next=null,this._prevDup=null,this._nextDup=null,this._prevRemoved=null,this._nextRemoved=null,this._nextAdded=null,this._nextMoved=null,this._nextIdentityChange=null}}class _7{constructor(){this._head=null,this._tail=null}add(e){null===this._head?(this._head=this._tail=e,e._nextDup=null,e._prevDup=null):(this._tail._nextDup=e,e._prevDup=this._tail,e._nextDup=null,this._tail=e)}get(e,t){let i;for(i=this._head;null!==i;i=i._nextDup)if((null===t||t<=i.currentIndex)&&Object.is(i.trackById,e))return i;return null}remove(e){const t=e._prevDup,i=e._nextDup;return null===t?this._head=i:t._nextDup=i,null===i?this._tail=t:i._prevDup=t,null===this._head}}class i3{constructor(){this.map=new Map}put(e){const t=e.trackById;let i=this.map.get(t);i||(i=new _7,this.map.set(t,i)),i.add(e)}get(e,t){const r=this.map.get(e);return r?r.get(e,t):null}remove(e){const t=e.trackById;return this.map.get(t).remove(e)&&this.map.delete(t),e}get isEmpty(){return 0===this.map.size}clear(){this.map.clear()}}function r3(n,e,t){const i=n.previousIndex;if(null===i)return i;let r=0;return t&&i{if(t&&t.key===r)this._maybeAddToChanges(t,i),this._appendAfter=t,t=t._next;else{const s=this._getOrCreateRecordForKey(r,i);t=this._insertBeforeOrAppend(t,s)}}),t){t._prev&&(t._prev._next=null),this._removalsHead=t;for(let i=t;null!==i;i=i._nextRemoved)i===this._mapHead&&(this._mapHead=null),this._records.delete(i.key),i._nextRemoved=i._next,i.previousValue=i.currentValue,i.currentValue=null,i._prev=null,i._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(e,t){if(e){const i=e._prev;return t._next=e,t._prev=i,e._prev=t,i&&(i._next=t),e===this._mapHead&&(this._mapHead=t),this._appendAfter=e,e}return this._appendAfter?(this._appendAfter._next=t,t._prev=this._appendAfter):this._mapHead=t,this._appendAfter=t,null}_getOrCreateRecordForKey(e,t){if(this._records.has(e)){const r=this._records.get(e);this._maybeAddToChanges(r,t);const s=r._prev,o=r._next;return s&&(s._next=o),o&&(o._prev=s),r._next=null,r._prev=null,r}const i=new y7(e);return this._records.set(e,i),i.currentValue=t,this._addToAdditions(i),i}_reset(){if(this.isDirty){let e;for(this._previousMapHead=this._mapHead,e=this._previousMapHead;null!==e;e=e._next)e._nextPrevious=e._next;for(e=this._changesHead;null!==e;e=e._nextChanged)e.previousValue=e.currentValue;for(e=this._additionsHead;null!=e;e=e._nextAdded)e.previousValue=e.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(e,t){Object.is(t,e.currentValue)||(e.previousValue=e.currentValue,e.currentValue=t,this._addToChanges(e))}_addToAdditions(e){null===this._additionsHead?this._additionsHead=this._additionsTail=e:(this._additionsTail._nextAdded=e,this._additionsTail=e)}_addToChanges(e){null===this._changesHead?this._changesHead=this._changesTail=e:(this._changesTail._nextChanged=e,this._changesTail=e)}_forEach(e,t){e instanceof Map?e.forEach(t):Object.keys(e).forEach(i=>t(e[i],i))}}class y7{constructor(e){this.key=e,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._prev=null,this._nextAdded=null,this._nextRemoved=null,this._nextChanged=null}}function o3(){return new $1([new n3])}let $1=(()=>{class n{constructor(t){this.factories=t}static create(t,i){if(null!=i){const r=i.factories.slice();t=t.concat(r)}return new n(t)}static extend(t){return{provide:n,useFactory:i=>n.create(t,i||o3()),deps:[[n,new Pl,new ba]]}}find(t){const i=this.factories.find(r=>r.supports(t));if(null!=i)return i;throw new Ue(901,!1)}}return n.\u0275prov=Je({token:n,providedIn:"root",factory:o3}),n})();function a3(){return new Ev([new s3])}let Ev=(()=>{class n{constructor(t){this.factories=t}static create(t,i){if(i){const r=i.factories.slice();t=t.concat(r)}return new n(t)}static extend(t){return{provide:n,useFactory:i=>n.create(t,i||a3()),deps:[[n,new Pl,new ba]]}}find(t){const i=this.factories.find(r=>r.supports(t));if(i)return i;throw new Ue(901,!1)}}return n.\u0275prov=Je({token:n,providedIn:"root",factory:a3}),n})();const w7=WP(null,"core",[]);let S7=(()=>{class n{constructor(t){}}return n.\u0275fac=function(t){return new(t||n)(xe(Jm))},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})();let wD=null;function Nd(){return wD}class C7{}const Mn=new Ze("DocumentToken");let SD=(()=>{class n{historyGo(t){throw new Error("Not implemented")}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return function D7(){return xe(c3)}()},providedIn:"platform"}),n})();const T7=new Ze("Location Initialized");let c3=(()=>{class n extends SD{constructor(t){super(),this._doc=t,this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return Nd().getBaseHref(this._doc)}onPopState(t){const i=Nd().getGlobalEventTarget(this._doc,"window");return i.addEventListener("popstate",t,!1),()=>i.removeEventListener("popstate",t)}onHashChange(t){const i=Nd().getGlobalEventTarget(this._doc,"window");return i.addEventListener("hashchange",t,!1),()=>i.removeEventListener("hashchange",t)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(t){this._location.pathname=t}pushState(t,i,r){l3()?this._history.pushState(t,i,r):this._location.hash=r}replaceState(t,i,r){l3()?this._history.replaceState(t,i,r):this._location.hash=r}forward(){this._history.forward()}back(){this._history.back()}historyGo(t=0){this._history.go(t)}getState(){return this._history.state}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:function(){return function A7(){return new c3(xe(Mn))}()},providedIn:"platform"}),n})();function l3(){return!!window.history.pushState}function ED(n,e){if(0==n.length)return e;if(0==e.length)return n;let t=0;return n.endsWith("/")&&t++,e.startsWith("/")&&t++,2==t?n+e.substring(1):1==t?n+e:n+"/"+e}function d3(n){const e=n.match(/#|\?|$/),t=e&&e.index||n.length;return n.slice(0,t-("/"===n[t-1]?1:0))+n.slice(t)}function Bd(n){return n&&"?"!==n[0]?"?"+n:n}let Ff=(()=>{class n{historyGo(t){throw new Error("Not implemented")}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return hn(h3)},providedIn:"root"}),n})();const u3=new Ze("appBaseHref");let h3=(()=>{class n extends Ff{constructor(t,i){super(),this._platformLocation=t,this._removeListenerFns=[],this._baseHref=i??this._platformLocation.getBaseHrefFromDOM()??hn(Mn).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(t){this._removeListenerFns.push(this._platformLocation.onPopState(t),this._platformLocation.onHashChange(t))}getBaseHref(){return this._baseHref}prepareExternalUrl(t){return ED(this._baseHref,t)}path(t=!1){const i=this._platformLocation.pathname+Bd(this._platformLocation.search),r=this._platformLocation.hash;return r&&t?`${i}${r}`:i}pushState(t,i,r,s){const o=this.prepareExternalUrl(r+Bd(s));this._platformLocation.pushState(t,i,o)}replaceState(t,i,r,s){const o=this.prepareExternalUrl(r+Bd(s));this._platformLocation.replaceState(t,i,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(t=0){this._platformLocation.historyGo?.(t)}}return n.\u0275fac=function(t){return new(t||n)(xe(SD),xe(u3,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),k7=(()=>{class n extends Ff{constructor(t,i){super(),this._platformLocation=t,this._baseHref="",this._removeListenerFns=[],null!=i&&(this._baseHref=i)}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(t){this._removeListenerFns.push(this._platformLocation.onPopState(t),this._platformLocation.onHashChange(t))}getBaseHref(){return this._baseHref}path(t=!1){let i=this._platformLocation.hash;return null==i&&(i="#"),i.length>0?i.substring(1):i}prepareExternalUrl(t){const i=ED(this._baseHref,t);return i.length>0?"#"+i:i}pushState(t,i,r,s){let o=this.prepareExternalUrl(r+Bd(s));0==o.length&&(o=this._platformLocation.pathname),this._platformLocation.pushState(t,i,o)}replaceState(t,i,r,s){let o=this.prepareExternalUrl(r+Bd(s));0==o.length&&(o=this._platformLocation.pathname),this._platformLocation.replaceState(t,i,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(t=0){this._platformLocation.historyGo?.(t)}}return n.\u0275fac=function(t){return new(t||n)(xe(SD),xe(u3,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),Mv=(()=>{class n{constructor(t){this._subject=new Pn,this._urlChangeListeners=[],this._urlChangeSubscription=null,this._locationStrategy=t;const i=this._locationStrategy.getBaseHref();this._basePath=function R7(n){if(new RegExp("^(https?:)?//").test(n)){const[,t]=n.split(/\/\/[^\/]+/);return t}return n}(d3(f3(i))),this._locationStrategy.onPopState(r=>{this._subject.emit({url:this.path(!0),pop:!0,state:r.state,type:r.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(t=!1){return this.normalize(this._locationStrategy.path(t))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(t,i=""){return this.path()==this.normalize(t+Bd(i))}normalize(t){return n.stripTrailingSlash(function F7(n,e){if(!n||!e.startsWith(n))return e;const t=e.substring(n.length);return""===t||["/",";","?","#"].includes(t[0])?t:e}(this._basePath,f3(t)))}prepareExternalUrl(t){return t&&"/"!==t[0]&&(t="/"+t),this._locationStrategy.prepareExternalUrl(t)}go(t,i="",r=null){this._locationStrategy.pushState(r,"",t,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+Bd(i)),r)}replaceState(t,i="",r=null){this._locationStrategy.replaceState(r,"",t,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+Bd(i)),r)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(t=0){this._locationStrategy.historyGo?.(t)}onUrlChange(t){return this._urlChangeListeners.push(t),this._urlChangeSubscription||(this._urlChangeSubscription=this.subscribe(i=>{this._notifyUrlChangeListeners(i.url,i.state)})),()=>{const i=this._urlChangeListeners.indexOf(t);this._urlChangeListeners.splice(i,1),0===this._urlChangeListeners.length&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(t="",i){this._urlChangeListeners.forEach(r=>r(t,i))}subscribe(t,i,r){return this._subject.subscribe({next:t,error:i,complete:r})}}return n.normalizeQueryParams=Bd,n.joinWithSlash=ED,n.stripTrailingSlash=d3,n.\u0275fac=function(t){return new(t||n)(xe(Ff))},n.\u0275prov=Je({token:n,factory:function(){return function I7(){return new Mv(xe(Ff))}()},providedIn:"root"}),n})();function f3(n){return n.replace(/\/index.html$/,"")}var rs=(()=>((rs=rs||{})[rs.Format=0]="Format",rs[rs.Standalone=1]="Standalone",rs))(),fi=(()=>((fi=fi||{})[fi.Narrow=0]="Narrow",fi[fi.Abbreviated=1]="Abbreviated",fi[fi.Wide=2]="Wide",fi[fi.Short=3]="Short",fi))(),Or=(()=>((Or=Or||{})[Or.Short=0]="Short",Or[Or.Medium=1]="Medium",Or[Or.Long=2]="Long",Or[Or.Full=3]="Full",Or))(),mn=(()=>((mn=mn||{})[mn.Decimal=0]="Decimal",mn[mn.Group=1]="Group",mn[mn.List=2]="List",mn[mn.PercentSign=3]="PercentSign",mn[mn.PlusSign=4]="PlusSign",mn[mn.MinusSign=5]="MinusSign",mn[mn.Exponential=6]="Exponential",mn[mn.SuperscriptingExponent=7]="SuperscriptingExponent",mn[mn.PerMille=8]="PerMille",mn[mn.Infinity=9]="Infinity",mn[mn.NaN=10]="NaN",mn[mn.TimeSeparator=11]="TimeSeparator",mn[mn.CurrencyDecimal=12]="CurrencyDecimal",mn[mn.CurrencyGroup=13]="CurrencyGroup",mn))();function q1(n,e){return Ic(sa(n)[Dt.DateFormat],e)}function K1(n,e){return Ic(sa(n)[Dt.TimeFormat],e)}function Y1(n,e){return Ic(sa(n)[Dt.DateTimeFormat],e)}function kc(n,e){const t=sa(n),i=t[Dt.NumberSymbols][e];if(typeof i>"u"){if(e===mn.CurrencyDecimal)return t[Dt.NumberSymbols][mn.Decimal];if(e===mn.CurrencyGroup)return t[Dt.NumberSymbols][mn.Group]}return i}function m3(n){if(!n[Dt.ExtraData])throw new Error(`Missing extra locale data for the locale "${n[Dt.LocaleId]}". Use "registerLocaleData" to load new data. See the "I18n guide" on angular.io to know more.`)}function Ic(n,e){for(let t=e;t>-1;t--)if(typeof n[t]<"u")return n[t];throw new Error("Locale data API: locale data undefined")}function CD(n){const[e,t]=n.split(":");return{hours:+e,minutes:+t}}const $7=/^(\d{4,})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/,Cv={},q7=/((?:[^BEGHLMOSWYZabcdhmswyz']+)|(?:'(?:[^']|'')*')|(?:G{1,5}|y{1,4}|Y{1,4}|M{1,5}|L{1,5}|w{1,2}|W{1}|d{1,2}|E{1,6}|c{1,6}|a{1,5}|b{1,5}|B{1,5}|h{1,2}|H{1,2}|m{1,2}|s{1,2}|S{1,3}|z{1,4}|Z{1,5}|O{1,4}))([\s\S]*)/;var zs=(()=>((zs=zs||{})[zs.Short=0]="Short",zs[zs.ShortGMT=1]="ShortGMT",zs[zs.Long=2]="Long",zs[zs.Extended=3]="Extended",zs))(),bn=(()=>((bn=bn||{})[bn.FullYear=0]="FullYear",bn[bn.Month=1]="Month",bn[bn.Date=2]="Date",bn[bn.Hours=3]="Hours",bn[bn.Minutes=4]="Minutes",bn[bn.Seconds=5]="Seconds",bn[bn.FractionalSeconds=6]="FractionalSeconds",bn[bn.Day=7]="Day",bn))(),Zn=(()=>((Zn=Zn||{})[Zn.DayPeriods=0]="DayPeriods",Zn[Zn.Days=1]="Days",Zn[Zn.Months=2]="Months",Zn[Zn.Eras=3]="Eras",Zn))();function DD(n,e,t,i){let r=function nz(n){if(v3(n))return n;if("number"==typeof n&&!isNaN(n))return new Date(n);if("string"==typeof n){if(n=n.trim(),/^(\d{4}(-\d{1,2}(-\d{1,2})?)?)$/.test(n)){const[r,s=1,o=1]=n.split("-").map(a=>+a);return X1(r,s-1,o)}const t=parseFloat(n);if(!isNaN(n-t))return new Date(t);let i;if(i=n.match($7))return function iz(n){const e=new Date(0);let t=0,i=0;const r=n[8]?e.setUTCFullYear:e.setFullYear,s=n[8]?e.setUTCHours:e.setHours;n[9]&&(t=Number(n[9]+n[10]),i=Number(n[9]+n[11])),r.call(e,Number(n[1]),Number(n[2])-1,Number(n[3]));const o=Number(n[4]||0)-t,a=Number(n[5]||0)-i,c=Number(n[6]||0),u=Math.floor(1e3*parseFloat("0."+(n[7]||0)));return s.call(e,o,a,c,u),e}(i)}const e=new Date(n);if(!v3(e))throw new Error(`Unable to convert "${n}" into a date`);return e}(n);e=Vd(t,e)||e;let a,o=[];for(;e;){if(a=q7.exec(e),!a){o.push(e);break}{o=o.concat(a.slice(1));const p=o.pop();if(!p)break;e=p}}let c=r.getTimezoneOffset();i&&(c=_3(i,c),r=function tz(n,e,t){const i=t?-1:1,r=n.getTimezoneOffset();return function ez(n,e){return(n=new Date(n.getTime())).setMinutes(n.getMinutes()+e),n}(n,i*(_3(e,r)-r))}(r,i,!0));let u="";return o.forEach(p=>{const g=function Q7(n){if(AD[n])return AD[n];let e;switch(n){case"G":case"GG":case"GGG":e=ar(Zn.Eras,fi.Abbreviated);break;case"GGGG":e=ar(Zn.Eras,fi.Wide);break;case"GGGGG":e=ar(Zn.Eras,fi.Narrow);break;case"y":e=Ss(bn.FullYear,1,0,!1,!0);break;case"yy":e=Ss(bn.FullYear,2,0,!0,!0);break;case"yyy":e=Ss(bn.FullYear,3,0,!1,!0);break;case"yyyy":e=Ss(bn.FullYear,4,0,!1,!0);break;case"Y":e=ew(1);break;case"YY":e=ew(2,!0);break;case"YYY":e=ew(3);break;case"YYYY":e=ew(4);break;case"M":case"L":e=Ss(bn.Month,1,1);break;case"MM":case"LL":e=Ss(bn.Month,2,1);break;case"MMM":e=ar(Zn.Months,fi.Abbreviated);break;case"MMMM":e=ar(Zn.Months,fi.Wide);break;case"MMMMM":e=ar(Zn.Months,fi.Narrow);break;case"LLL":e=ar(Zn.Months,fi.Abbreviated,rs.Standalone);break;case"LLLL":e=ar(Zn.Months,fi.Wide,rs.Standalone);break;case"LLLLL":e=ar(Zn.Months,fi.Narrow,rs.Standalone);break;case"w":e=TD(1);break;case"ww":e=TD(2);break;case"W":e=TD(1,!0);break;case"d":e=Ss(bn.Date,1);break;case"dd":e=Ss(bn.Date,2);break;case"c":case"cc":e=Ss(bn.Day,1);break;case"ccc":e=ar(Zn.Days,fi.Abbreviated,rs.Standalone);break;case"cccc":e=ar(Zn.Days,fi.Wide,rs.Standalone);break;case"ccccc":e=ar(Zn.Days,fi.Narrow,rs.Standalone);break;case"cccccc":e=ar(Zn.Days,fi.Short,rs.Standalone);break;case"E":case"EE":case"EEE":e=ar(Zn.Days,fi.Abbreviated);break;case"EEEE":e=ar(Zn.Days,fi.Wide);break;case"EEEEE":e=ar(Zn.Days,fi.Narrow);break;case"EEEEEE":e=ar(Zn.Days,fi.Short);break;case"a":case"aa":case"aaa":e=ar(Zn.DayPeriods,fi.Abbreviated);break;case"aaaa":e=ar(Zn.DayPeriods,fi.Wide);break;case"aaaaa":e=ar(Zn.DayPeriods,fi.Narrow);break;case"b":case"bb":case"bbb":e=ar(Zn.DayPeriods,fi.Abbreviated,rs.Standalone,!0);break;case"bbbb":e=ar(Zn.DayPeriods,fi.Wide,rs.Standalone,!0);break;case"bbbbb":e=ar(Zn.DayPeriods,fi.Narrow,rs.Standalone,!0);break;case"B":case"BB":case"BBB":e=ar(Zn.DayPeriods,fi.Abbreviated,rs.Format,!0);break;case"BBBB":e=ar(Zn.DayPeriods,fi.Wide,rs.Format,!0);break;case"BBBBB":e=ar(Zn.DayPeriods,fi.Narrow,rs.Format,!0);break;case"h":e=Ss(bn.Hours,1,-12);break;case"hh":e=Ss(bn.Hours,2,-12);break;case"H":e=Ss(bn.Hours,1);break;case"HH":e=Ss(bn.Hours,2);break;case"m":e=Ss(bn.Minutes,1);break;case"mm":e=Ss(bn.Minutes,2);break;case"s":e=Ss(bn.Seconds,1);break;case"ss":e=Ss(bn.Seconds,2);break;case"S":e=Ss(bn.FractionalSeconds,1);break;case"SS":e=Ss(bn.FractionalSeconds,2);break;case"SSS":e=Ss(bn.FractionalSeconds,3);break;case"Z":case"ZZ":case"ZZZ":e=J1(zs.Short);break;case"ZZZZZ":e=J1(zs.Extended);break;case"O":case"OO":case"OOO":case"z":case"zz":case"zzz":e=J1(zs.ShortGMT);break;case"OOOO":case"ZZZZ":case"zzzz":e=J1(zs.Long);break;default:return null}return AD[n]=e,e}(p);u+=g?g(r,t,c):"''"===p?"'":p.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),u}function X1(n,e,t){const i=new Date(0);return i.setFullYear(n,e,t),i.setHours(0,0,0),i}function Vd(n,e){const t=function P7(n){return sa(n)[Dt.LocaleId]}(n);if(Cv[t]=Cv[t]||{},Cv[t][e])return Cv[t][e];let i="";switch(e){case"shortDate":i=q1(n,Or.Short);break;case"mediumDate":i=q1(n,Or.Medium);break;case"longDate":i=q1(n,Or.Long);break;case"fullDate":i=q1(n,Or.Full);break;case"shortTime":i=K1(n,Or.Short);break;case"mediumTime":i=K1(n,Or.Medium);break;case"longTime":i=K1(n,Or.Long);break;case"fullTime":i=K1(n,Or.Full);break;case"short":const r=Vd(n,"shortTime"),s=Vd(n,"shortDate");i=Z1(Y1(n,Or.Short),[r,s]);break;case"medium":const o=Vd(n,"mediumTime"),a=Vd(n,"mediumDate");i=Z1(Y1(n,Or.Medium),[o,a]);break;case"long":const c=Vd(n,"longTime"),u=Vd(n,"longDate");i=Z1(Y1(n,Or.Long),[c,u]);break;case"full":const p=Vd(n,"fullTime"),g=Vd(n,"fullDate");i=Z1(Y1(n,Or.Full),[p,g])}return i&&(Cv[t][e]=i),i}function Z1(n,e){return e&&(n=n.replace(/\{([^}]+)}/g,function(t,i){return null!=e&&i in e?e[i]:t})),n}function ll(n,e,t="-",i,r){let s="";(n<0||r&&n<=0)&&(r?n=1-n:(n=-n,s=t));let o=String(n);for(;o.length0||a>-t)&&(a+=t),n===bn.Hours)0===a&&-12===t&&(a=12);else if(n===bn.FractionalSeconds)return function K7(n,e){return ll(n,3).substring(0,e)}(a,e);const c=kc(o,mn.MinusSign);return ll(a,e,c,i,r)}}function ar(n,e,t=rs.Format,i=!1){return function(r,s){return function X7(n,e,t,i,r,s){switch(t){case Zn.Months:return function N7(n,e,t){const i=sa(n),s=Ic([i[Dt.MonthsFormat],i[Dt.MonthsStandalone]],e);return Ic(s,t)}(e,r,i)[n.getMonth()];case Zn.Days:return function L7(n,e,t){const i=sa(n),s=Ic([i[Dt.DaysFormat],i[Dt.DaysStandalone]],e);return Ic(s,t)}(e,r,i)[n.getDay()];case Zn.DayPeriods:const o=n.getHours(),a=n.getMinutes();if(s){const u=function U7(n){const e=sa(n);return m3(e),(e[Dt.ExtraData][2]||[]).map(i=>"string"==typeof i?CD(i):[CD(i[0]),CD(i[1])])}(e),p=function z7(n,e,t){const i=sa(n);m3(i);const s=Ic([i[Dt.ExtraData][0],i[Dt.ExtraData][1]],e)||[];return Ic(s,t)||[]}(e,r,i),g=u.findIndex(v=>{if(Array.isArray(v)){const[y,x]=v,T=o>=y.hours&&a>=y.minutes,N=o0?Math.floor(r/60):Math.ceil(r/60);switch(n){case zs.Short:return(r>=0?"+":"")+ll(o,2,s)+ll(Math.abs(r%60),2,s);case zs.ShortGMT:return"GMT"+(r>=0?"+":"")+ll(o,1,s);case zs.Long:return"GMT"+(r>=0?"+":"")+ll(o,2,s)+":"+ll(Math.abs(r%60),2,s);case zs.Extended:return 0===i?"Z":(r>=0?"+":"")+ll(o,2,s)+":"+ll(Math.abs(r%60),2,s);default:throw new Error(`Unknown zone width "${n}"`)}}}const Z7=0,Q1=4;function g3(n){return X1(n.getFullYear(),n.getMonth(),n.getDate()+(Q1-n.getDay()))}function TD(n,e=!1){return function(t,i){let r;if(e){const s=new Date(t.getFullYear(),t.getMonth(),1).getDay()-1,o=t.getDate();r=1+Math.floor((o+s)/7)}else{const s=g3(t),o=function J7(n){const e=X1(n,Z7,1).getDay();return X1(n,0,1+(e<=Q1?Q1:Q1+7)-e)}(s.getFullYear()),a=s.getTime()-o.getTime();r=1+Math.round(a/6048e5)}return ll(r,n,kc(i,mn.MinusSign))}}function ew(n,e=!1){return function(t,i){return ll(g3(t).getFullYear(),n,kc(i,mn.MinusSign),e)}}const AD={};function _3(n,e){n=n.replace(/:/g,"");const t=Date.parse("Jan 01, 1970 00:00:00 "+n)/6e4;return isNaN(t)?e:t}function v3(n){return n instanceof Date&&!isNaN(n.valueOf())}function Es(n,e,t){return function WH(n,e,t){"string"!=typeof e&&(t=e,e=n[Dt.LocaleId]),e=e.toLowerCase().replace(/_/g,"-"),$m[e]=n,t&&($m[e][Dt.ExtraData]=t)}(n,e,t)}function w3(n,e){e=encodeURIComponent(e);for(const t of n.split(";")){const i=t.indexOf("="),[r,s]=-1==i?[t,""]:[t.slice(0,i),t.slice(i+1)];if(r.trim()===e)return decodeURIComponent(s)}return null}const OD=/\s+/,S3=[];let eg=(()=>{class n{constructor(t,i,r,s){this._iterableDiffers=t,this._keyValueDiffers=i,this._ngEl=r,this._renderer=s,this.initialClasses=S3,this.stateMap=new Map}set klass(t){this.initialClasses=null!=t?t.trim().split(OD):S3}set ngClass(t){this.rawClass="string"==typeof t?t.trim().split(OD):t}ngDoCheck(){for(const i of this.initialClasses)this._updateState(i,!0);const t=this.rawClass;if(Array.isArray(t)||t instanceof Set)for(const i of t)this._updateState(i,!0);else if(null!=t)for(const i of Object.keys(t))this._updateState(i,Boolean(t[i]));this._applyStateDiff()}_updateState(t,i){const r=this.stateMap.get(t);void 0!==r?(r.enabled!==i&&(r.changed=!0,r.enabled=i),r.touched=!0):this.stateMap.set(t,{enabled:i,changed:!0,touched:!0})}_applyStateDiff(){for(const t of this.stateMap){const i=t[0],r=t[1];r.changed?(this._toggleClass(i,r.enabled),r.changed=!1):r.touched||(r.enabled&&this._toggleClass(i,!1),this.stateMap.delete(i)),r.touched=!1}}_toggleClass(t,i){(t=t.trim()).length>0&&t.split(OD).forEach(r=>{i?this._renderer.addClass(this._ngEl.nativeElement,r):this._renderer.removeClass(this._ngEl.nativeElement,r)})}}return n.\u0275fac=function(t){return new(t||n)(ie($1),ie(Ev),ie(_n),ie(el))},n.\u0275dir=ut({type:n,selectors:[["","ngClass",""]],inputs:{klass:["class","klass"],ngClass:"ngClass"},standalone:!0}),n})();class gz{constructor(e,t,i,r){this.$implicit=e,this.ngForOf=t,this.index=i,this.count=r}get first(){return 0===this.index}get last(){return this.index===this.count-1}get even(){return this.index%2==0}get odd(){return!this.even}}let tg=(()=>{class n{set ngForOf(t){this._ngForOf=t,this._ngForOfDirty=!0}set ngForTrackBy(t){this._trackByFn=t}get ngForTrackBy(){return this._trackByFn}constructor(t,i,r){this._viewContainer=t,this._template=i,this._differs=r,this._ngForOf=null,this._ngForOfDirty=!0,this._differ=null}set ngForTemplate(t){t&&(this._template=t)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;const t=this._ngForOf;!this._differ&&t&&(this._differ=this._differs.find(t).create(this.ngForTrackBy))}if(this._differ){const t=this._differ.diff(this._ngForOf);t&&this._applyChanges(t)}}_applyChanges(t){const i=this._viewContainer;t.forEachOperation((r,s,o)=>{if(null==r.previousIndex)i.createEmbeddedView(this._template,new gz(r.item,this._ngForOf,-1,-1),null===o?void 0:o);else if(null==o)i.remove(null===s?void 0:s);else if(null!==s){const a=i.get(s);i.move(a,o),C3(a,r)}});for(let r=0,s=i.length;r{C3(i.get(r.currentIndex),r)})}static ngTemplateContextGuard(t,i){return!0}}return n.\u0275fac=function(t){return new(t||n)(ie(Sa),ie(al),ie($1))},n.\u0275dir=ut({type:n,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"},standalone:!0}),n})();function C3(n,e){n.context.$implicit=e.item}let Yu=(()=>{class n{constructor(t,i){this._viewContainer=t,this._context=new vz,this._thenTemplateRef=null,this._elseTemplateRef=null,this._thenViewRef=null,this._elseViewRef=null,this._thenTemplateRef=i}set ngIf(t){this._context.$implicit=this._context.ngIf=t,this._updateView()}set ngIfThen(t){D3("ngIfThen",t),this._thenTemplateRef=t,this._thenViewRef=null,this._updateView()}set ngIfElse(t){D3("ngIfElse",t),this._elseTemplateRef=t,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(t,i){return!0}}return n.\u0275fac=function(t){return new(t||n)(ie(Sa),ie(al))},n.\u0275dir=ut({type:n,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"},standalone:!0}),n})();class vz{constructor(){this.$implicit=null,this.ngIf=null}}function D3(n,e){if(e&&!e.createEmbeddedView)throw new Error(`${n} must be a TemplateRef, but received '${ki(e)}'.`)}class LD{constructor(e,t){this._viewContainerRef=e,this._templateRef=t,this._created=!1}create(){this._created=!0,this._viewContainerRef.createEmbeddedView(this._templateRef)}destroy(){this._created=!1,this._viewContainerRef.clear()}enforceState(e){e&&!this._created?this.create():!e&&this._created&&this.destroy()}}let Tv=(()=>{class n{constructor(){this._defaultViews=[],this._defaultUsed=!1,this._caseCount=0,this._lastCaseCheckIndex=0,this._lastCasesMatched=!1}set ngSwitch(t){this._ngSwitch=t,0===this._caseCount&&this._updateDefaultCases(!0)}_addCase(){return this._caseCount++}_addDefault(t){this._defaultViews.push(t)}_matchCase(t){const i=t==this._ngSwitch;return this._lastCasesMatched=this._lastCasesMatched||i,this._lastCaseCheckIndex++,this._lastCaseCheckIndex===this._caseCount&&(this._updateDefaultCases(!this._lastCasesMatched),this._lastCaseCheckIndex=0,this._lastCasesMatched=!1),i}_updateDefaultCases(t){if(this._defaultViews.length>0&&t!==this._defaultUsed){this._defaultUsed=t;for(const i of this._defaultViews)i.enforceState(t)}}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["","ngSwitch",""]],inputs:{ngSwitch:"ngSwitch"},standalone:!0}),n})(),ND=(()=>{class n{constructor(t,i,r){this.ngSwitch=r,r._addCase(),this._view=new LD(t,i)}ngDoCheck(){this._view.enforceState(this.ngSwitch._matchCase(this.ngSwitchCase))}}return n.\u0275fac=function(t){return new(t||n)(ie(Sa),ie(al),ie(Tv,9))},n.\u0275dir=ut({type:n,selectors:[["","ngSwitchCase",""]],inputs:{ngSwitchCase:"ngSwitchCase"},standalone:!0}),n})(),T3=(()=>{class n{constructor(t,i,r){r._addDefault(new LD(t,i))}}return n.\u0275fac=function(t){return new(t||n)(ie(Sa),ie(al),ie(Tv,9))},n.\u0275dir=ut({type:n,selectors:[["","ngSwitchDefault",""]],standalone:!0}),n})(),nw=(()=>{class n{constructor(t,i,r){this._ngEl=t,this._differs=i,this._renderer=r,this._ngStyle=null,this._differ=null}set ngStyle(t){this._ngStyle=t,!this._differ&&t&&(this._differ=this._differs.find(t).create())}ngDoCheck(){if(this._differ){const t=this._differ.diff(this._ngStyle);t&&this._applyChanges(t)}}_setStyle(t,i){const[r,s]=t.split("."),o=-1===r.indexOf("-")?void 0:Js.DashCase;null!=i?this._renderer.setStyle(this._ngEl.nativeElement,r,s?`${i}${s}`:i,o):this._renderer.removeStyle(this._ngEl.nativeElement,r,o)}_applyChanges(t){t.forEachRemovedItem(i=>this._setStyle(i.key,null)),t.forEachAddedItem(i=>this._setStyle(i.key,i.currentValue)),t.forEachChangedItem(i=>this._setStyle(i.key,i.currentValue))}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Ev),ie(el))},n.\u0275dir=ut({type:n,selectors:[["","ngStyle",""]],inputs:{ngStyle:"ngStyle"},standalone:!0}),n})(),BD=(()=>{class n{constructor(t){this._viewContainerRef=t,this._viewRef=null,this.ngTemplateOutletContext=null,this.ngTemplateOutlet=null,this.ngTemplateOutletInjector=null}ngOnChanges(t){if(t.ngTemplateOutlet||t.ngTemplateOutletInjector){const i=this._viewContainerRef;if(this._viewRef&&i.remove(i.indexOf(this._viewRef)),this.ngTemplateOutlet){const{ngTemplateOutlet:r,ngTemplateOutletContext:s,ngTemplateOutletInjector:o}=this;this._viewRef=i.createEmbeddedView(r,s,o?{injector:o}:void 0)}else this._viewRef=null}else this._viewRef&&t.ngTemplateOutletContext&&this.ngTemplateOutletContext&&(this._viewRef.context=this.ngTemplateOutletContext)}}return n.\u0275fac=function(t){return new(t||n)(ie(Sa))},n.\u0275dir=ut({type:n,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet",ngTemplateOutletInjector:"ngTemplateOutletInjector"},standalone:!0,features:[Cn]}),n})();function dl(n,e){return new Ue(2100,!1)}class bz{createSubscription(e,t){return e.subscribe({next:t,error:i=>{throw i}})}dispose(e){e.unsubscribe()}}class xz{createSubscription(e,t){return e.then(t,i=>{throw i})}dispose(e){}}const wz=new xz,Sz=new bz;let Rf=(()=>{class n{constructor(t){this._latestValue=null,this._subscription=null,this._obj=null,this._strategy=null,this._ref=t}ngOnDestroy(){this._subscription&&this._dispose(),this._ref=null}transform(t){return this._obj?t!==this._obj?(this._dispose(),this.transform(t)):this._latestValue:(t&&this._subscribe(t),this._latestValue)}_subscribe(t){this._obj=t,this._strategy=this._selectStrategy(t),this._subscription=this._strategy.createSubscription(t,i=>this._updateLatestValue(t,i))}_selectStrategy(t){if(lv(t))return wz;if(kF(t))return Sz;throw dl()}_dispose(){this._strategy.dispose(this._subscription),this._latestValue=null,this._subscription=null,this._obj=null}_updateLatestValue(t,i){t===this._obj&&(this._latestValue=i,this._ref.markForCheck())}}return n.\u0275fac=function(t){return new(t||n)(ie(aa,16))},n.\u0275pipe=Yi({name:"async",type:n,pure:!1,standalone:!0}),n})();const Az=new Ze("DATE_PIPE_DEFAULT_TIMEZONE"),kz=new Ze("DATE_PIPE_DEFAULT_OPTIONS");let k3=(()=>{class n{constructor(t,i,r){this.locale=t,this.defaultTimezone=i,this.defaultOptions=r}transform(t,i,r,s){if(null==t||""===t||t!=t)return null;try{return DD(t,i??this.defaultOptions?.dateFormat??"mediumDate",s||this.locale,r??this.defaultOptions?.timezone??this.defaultTimezone??void 0)}catch(o){throw dl()}}}return n.\u0275fac=function(t){return new(t||n)(ie(Ac,16),ie(Az,24),ie(kz,24))},n.\u0275pipe=Yi({name:"date",type:n,pure:!0,standalone:!0}),n})(),ul=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})();const F3="browser";let jz=(()=>{class n{}return n.\u0275prov=Je({token:n,providedIn:"root",factory:()=>new Wz(xe(Mn),window)}),n})();class Wz{constructor(e,t){this.document=e,this.window=t,this.offset=()=>[0,0]}setOffset(e){this.offset=Array.isArray(e)?()=>e:e}getScrollPosition(){return this.supportsScrolling()?[this.window.pageXOffset,this.window.pageYOffset]:[0,0]}scrollToPosition(e){this.supportsScrolling()&&this.window.scrollTo(e[0],e[1])}scrollToAnchor(e){if(!this.supportsScrolling())return;const t=function $z(n,e){const t=n.getElementById(e)||n.getElementsByName(e)[0];if(t)return t;if("function"==typeof n.createTreeWalker&&n.body&&(n.body.createShadowRoot||n.body.attachShadow)){const i=n.createTreeWalker(n.body,NodeFilter.SHOW_ELEMENT);let r=i.currentNode;for(;r;){const s=r.shadowRoot;if(s){const o=s.getElementById(e)||s.querySelector(`[name="${e}"]`);if(o)return o}r=i.nextNode()}}return null}(this.document,e);t&&(this.scrollToElement(t),t.focus())}setHistoryScrollRestoration(e){if(this.supportScrollRestoration()){const t=this.window.history;t&&t.scrollRestoration&&(t.scrollRestoration=e)}}scrollToElement(e){const t=e.getBoundingClientRect(),i=t.left+this.window.pageXOffset,r=t.top+this.window.pageYOffset,s=this.offset();this.window.scrollTo(i-s[0],r-s[1])}supportScrollRestoration(){try{if(!this.supportsScrolling())return!1;const e=R3(this.window.history)||R3(Object.getPrototypeOf(this.window.history));return!(!e||!e.writable&&!e.set)}catch{return!1}}supportsScrolling(){try{return!!this.window&&!!this.window.scrollTo&&"pageXOffset"in this.window}catch{return!1}}}function R3(n){return Object.getOwnPropertyDescriptor(n,"scrollRestoration")}class P3{}class yG extends C7{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class GD extends yG{static makeCurrent(){!function M7(n){wD||(wD=n)}(new GD)}onAndCancel(e,t,i){return e.addEventListener(t,i,!1),()=>{e.removeEventListener(t,i,!1)}}dispatchEvent(e,t){e.dispatchEvent(t)}remove(e){e.parentNode&&e.parentNode.removeChild(e)}createElement(e,t){return(t=t||this.getDefaultDocument()).createElement(e)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(e){return e.nodeType===Node.ELEMENT_NODE}isShadowRoot(e){return e instanceof DocumentFragment}getGlobalEventTarget(e,t){return"window"===t?window:"document"===t?e:"body"===t?e.body:null}getBaseHref(e){const t=function bG(){return kv=kv||document.querySelector("base"),kv?kv.getAttribute("href"):null}();return null==t?null:function xG(n){sw=sw||document.createElement("a"),sw.setAttribute("href",n);const e=sw.pathname;return"/"===e.charAt(0)?e:`/${e}`}(t)}resetBaseElement(){kv=null}getUserAgent(){return window.navigator.userAgent}getCookie(e){return w3(document.cookie,e)}}let sw,kv=null;const V3=new Ze("TRANSITION_ID"),SG=[{provide:V1,useFactory:function wG(n,e,t){return()=>{t.get(H1).donePromise.then(()=>{const i=Nd(),r=e.querySelectorAll(`style[ng-transition="${n}"]`);for(let s=0;s{class n{build(){return new XMLHttpRequest}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const ow=new Ze("EventManagerPlugins");let aw=(()=>{class n{constructor(t,i){this._zone=i,this._eventNameToPlugin=new Map,t.forEach(r=>r.manager=this),this._plugins=t.slice().reverse()}addEventListener(t,i,r){return this._findPluginFor(i).addEventListener(t,i,r)}addGlobalEventListener(t,i,r){return this._findPluginFor(i).addGlobalEventListener(t,i,r)}getZone(){return this._zone}_findPluginFor(t){const i=this._eventNameToPlugin.get(t);if(i)return i;const r=this._plugins;for(let s=0;s{class n{constructor(){this.usageCount=new Map}addStyles(t){for(const i of t)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(t){for(const i of t)0===this.changeUsageCount(i,-1)&&this.onStyleRemoved(i)}onStyleRemoved(t){}onStyleAdded(t){}getAllStyles(){return this.usageCount.keys()}changeUsageCount(t,i){const r=this.usageCount;let s=r.get(t)??0;return s+=i,s>0?r.set(t,s):r.delete(t),s}ngOnDestroy(){for(const t of this.getAllStyles())this.onStyleRemoved(t);this.usageCount.clear()}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),Iv=(()=>{class n extends U3{constructor(t){super(),this.doc=t,this.styleRef=new Map,this.hostNodes=new Set,this.resetHostNodes()}onStyleAdded(t){for(const i of this.hostNodes)this.addStyleToHost(i,t)}onStyleRemoved(t){const i=this.styleRef;i.get(t)?.forEach(s=>s.remove()),i.delete(t)}ngOnDestroy(){super.ngOnDestroy(),this.styleRef.clear(),this.resetHostNodes()}addHost(t){this.hostNodes.add(t);for(const i of this.getAllStyles())this.addStyleToHost(t,i)}removeHost(t){this.hostNodes.delete(t)}addStyleToHost(t,i){const r=this.doc.createElement("style");r.textContent=i,t.appendChild(r);const s=this.styleRef.get(i);s?s.push(r):this.styleRef.set(i,[r])}resetHostNodes(){const t=this.hostNodes;t.clear(),t.add(this.doc.head)}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const jD={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/"},WD=/%COMP%/g,j3=new Ze("RemoveStylesOnCompDestory",{providedIn:"root",factory:()=>!1});function W3(n,e){return e.flat(100).map(t=>t.replace(WD,n))}function $3(n){return e=>{if("__ngUnwrap__"===e)return n;!1===n(e)&&(e.preventDefault(),e.returnValue=!1)}}let cw=(()=>{class n{constructor(t,i,r,s){this.eventManager=t,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestory=s,this.rendererByCompId=new Map,this.defaultRenderer=new $D(t)}createRenderer(t,i){if(!t||!i)return this.defaultRenderer;const r=this.getOrCreateRenderer(t,i);return r instanceof Y3?r.applyToHost(t):r instanceof qD&&r.applyStyles(),r}getOrCreateRenderer(t,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.eventManager,a=this.sharedStylesHost,c=this.removeStylesOnCompDestory;switch(i.encapsulation){case Ko.Emulated:s=new Y3(o,a,i,this.appId,c);break;case Ko.ShadowDom:return new FG(o,a,t,i);default:s=new qD(o,a,i,c)}s.onDestroy=()=>r.delete(i.id),r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}begin(){}end(){}}return n.\u0275fac=function(t){return new(t||n)(xe(aw),xe(Iv),xe(Zm),xe(j3))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class $D{constructor(e){this.eventManager=e,this.data=Object.create(null),this.destroyNode=null}destroy(){}createElement(e,t){return t?document.createElementNS(jD[t]||t,e):document.createElement(e)}createComment(e){return document.createComment(e)}createText(e){return document.createTextNode(e)}appendChild(e,t){(K3(e)?e.content:e).appendChild(t)}insertBefore(e,t,i){e&&(K3(e)?e.content:e).insertBefore(t,i)}removeChild(e,t){e&&e.removeChild(t)}selectRootElement(e,t){let i="string"==typeof e?document.querySelector(e):e;if(!i)throw new Error(`The selector "${e}" did not match any elements`);return t||(i.textContent=""),i}parentNode(e){return e.parentNode}nextSibling(e){return e.nextSibling}setAttribute(e,t,i,r){if(r){t=r+":"+t;const s=jD[r];s?e.setAttributeNS(s,t,i):e.setAttribute(t,i)}else e.setAttribute(t,i)}removeAttribute(e,t,i){if(i){const r=jD[i];r?e.removeAttributeNS(r,t):e.removeAttribute(`${i}:${t}`)}else e.removeAttribute(t)}addClass(e,t){e.classList.add(t)}removeClass(e,t){e.classList.remove(t)}setStyle(e,t,i,r){r&(Js.DashCase|Js.Important)?e.style.setProperty(t,i,r&Js.Important?"important":""):e.style[t]=i}removeStyle(e,t,i){i&Js.DashCase?e.style.removeProperty(t):e.style[t]=""}setProperty(e,t,i){e[t]=i}setValue(e,t){e.nodeValue=t}listen(e,t,i){return"string"==typeof e?this.eventManager.addGlobalEventListener(e,t,$3(i)):this.eventManager.addEventListener(e,t,$3(i))}}function K3(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class FG extends $D{constructor(e,t,i,r){super(e),this.sharedStylesHost=t,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const s=W3(r.id,r.styles);for(const o of s){const a=document.createElement("style");a.textContent=o,this.shadowRoot.appendChild(a)}}nodeOrShadowRoot(e){return e===this.hostEl?this.shadowRoot:e}appendChild(e,t){return super.appendChild(this.nodeOrShadowRoot(e),t)}insertBefore(e,t,i){return super.insertBefore(this.nodeOrShadowRoot(e),t,i)}removeChild(e,t){return super.removeChild(this.nodeOrShadowRoot(e),t)}parentNode(e){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(e)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class qD extends $D{constructor(e,t,i,r,s=i.id){super(e),this.sharedStylesHost=t,this.removeStylesOnCompDestory=r,this.rendererUsageCount=0,this.styles=W3(s,i.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 Y3 extends qD{constructor(e,t,i,r,s){const o=r+"-"+i.id;super(e,t,i,s,o),this.contentAttr=function AG(n){return"_ngcontent-%COMP%".replace(WD,n)}(o),this.hostAttr=function kG(n){return"_nghost-%COMP%".replace(WD,n)}(o)}applyToHost(e){this.applyStyles(),this.setAttribute(e,this.hostAttr,"")}createElement(e,t){const i=super.createElement(e,t);return super.setAttribute(i,this.contentAttr,""),i}}let RG=(()=>{class n extends H3{constructor(t){super(t)}supports(t){return!0}addEventListener(t,i,r){return t.addEventListener(i,r,!1),()=>this.removeEventListener(t,i,r)}removeEventListener(t,i,r){return t.removeEventListener(i,r)}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const X3=["alt","control","meta","shift"],PG={"\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"},OG={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let LG=(()=>{class n extends H3{constructor(t){super(t)}supports(t){return null!=n.parseEventName(t)}addEventListener(t,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Nd().onAndCancel(t,s.domEventName,o))}static parseEventName(t){const i=t.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),X3.forEach(u=>{const p=i.indexOf(u);p>-1&&(i.splice(p,1),o+=u+".")}),o+=s,0!=i.length||0===s.length)return null;const c={};return c.domEventName=r,c.fullKey=o,c}static matchEventFullKeyCode(t,i){let r=PG[t.key]||t.key,s="";return i.indexOf("code.")>-1&&(r=t.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),X3.forEach(o=>{o!==r&&(0,OG[o])(t)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(t,i,r){return s=>{n.matchEventFullKeyCode(s,t)&&r.runGuarded(()=>i(s))}}static _normalizeKey(t){return"esc"===t?"escape":t}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const J3=[{provide:U1,useValue:F3},{provide:PP,useValue:function NG(){GD.makeCurrent()},multi:!0},{provide:Mn,useFactory:function VG(){return function lM(n){pm=n}(document),document},deps:[]}],HG=WP(w7,"browser",J3),Q3=new Ze(""),eO=[{provide:z1,useClass:class EG{addToWindow(e){Ii.getAngularTestability=(i,r=!0)=>{const s=e.findTestabilityInTree(i,r);if(null==s)throw new Error("Could not find testability for element.");return s},Ii.getAllAngularTestabilities=()=>e.getAllTestabilities(),Ii.getAllAngularRootElements=()=>e.getAllRootElements(),Ii.frameworkStabilizers||(Ii.frameworkStabilizers=[]),Ii.frameworkStabilizers.push(i=>{const r=Ii.getAllAngularTestabilities();let s=r.length,o=!1;const a=function(c){o=o||c,s--,0==s&&i(o)};r.forEach(function(c){c.whenStable(a)})})}findTestabilityInTree(e,t,i){return null==t?null:e.getTestability(t)??(i?Nd().isShadowRoot(t)?this.findTestabilityInTree(e,t.host,!0):this.findTestabilityInTree(e,t.parentElement,!0):null)}},deps:[]},{provide:UP,useClass:fD,deps:[Xt,pD,z1]},{provide:fD,useClass:fD,deps:[Xt,pD,z1]}],tO=[{provide:wm,useValue:"root"},{provide:tl,useFactory:function BG(){return new tl},deps:[]},{provide:ow,useClass:RG,multi:!0,deps:[Mn,Xt,U1]},{provide:ow,useClass:LG,multi:!0,deps:[Mn]},{provide:cw,useClass:cw,deps:[aw,Iv,Zm,j3]},{provide:yn,useExisting:cw},{provide:U3,useExisting:Iv},{provide:Iv,useClass:Iv,deps:[Mn]},{provide:aw,useClass:aw,deps:[ow,Xt]},{provide:P3,useClass:MG,deps:[]},[]];let nO=(()=>{class n{constructor(t){}static withServerTransition(t){return{ngModule:n,providers:[{provide:Zm,useValue:t.appId},{provide:V3,useExisting:Zm},SG]}}}return n.\u0275fac=function(t){return new(t||n)(xe(Q3,12))},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[...tO,...eO],imports:[ul,S7]}),n})(),iO=(()=>{class n{constructor(t){this._doc=t}getTitle(){return this._doc.title}setTitle(t){this._doc.title=t||""}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:function(t){let i=null;return i=t?new t:function zG(){return new iO(xe(Mn))}(),i},providedIn:"root"}),n})();typeof window<"u"&&window;let XD=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(t){let i=null;return i=t?new(t||n):xe(oO),i},providedIn:"root"}),n})(),oO=(()=>{class n extends XD{constructor(t){super(),this._doc=t}sanitize(t,i){if(null==i)return null;switch(t){case Ri.NONE:return i;case Ri.HTML:return Ec(i,"HTML")?ta(i):Ex(this._doc,String(i)).toString();case Ri.STYLE:return Ec(i,"Style")?ta(i):i;case Ri.SCRIPT:if(Ec(i,"Script"))return ta(i);throw new Error("unsafe value used in a script context");case Ri.URL:return Ec(i,"URL")?ta(i):_f(String(i));case Ri.RESOURCE_URL:if(Ec(i,"ResourceURL"))return ta(i);throw new Error(`unsafe value used in a resource URL context (see ${mu})`);default:throw new Error(`Unexpected SecurityContext ${t} (see ${mu})`)}}bypassSecurityTrustHtml(t){return function gM(n){return new dM(n)}(t)}bypassSecurityTrustStyle(t){return function _M(n){return new uM(n)}(t)}bypassSecurityTrustScript(t){return function vM(n){return new hM(n)}(t)}bypassSecurityTrustUrl(t){return function yM(n){return new fM(n)}(t)}bypassSecurityTrustResourceUrl(t){return function bM(n){return new pM(n)}(t)}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:function(t){let i=null;return i=t?new t:function YG(n){return new oO(n.get(Mn))}(xe(ts)),i},providedIn:"root"}),n})();function Tt(...n){let e=n[n.length-1];return cc(e)?(n.pop(),lo(n,e)):uc(n)}function Zu(n,e){return ur(n,e,1)}function Ui(n,e){return function(i){return i.lift(new XG(n,e))}}class XG{constructor(e,t){this.predicate=e,this.thisArg=t}call(e,t){return t.subscribe(new ZG(e,this.predicate,this.thisArg))}}class ZG extends di{constructor(e,t,i){super(e),this.predicate=t,this.thisArg=i,this.count=0}_next(e){let t;try{t=this.predicate.call(this.thisArg,e,this.count++)}catch(i){return void this.destination.error(i)}t&&this.destination.next(e)}}class lw{}class ZD{}class Ho{constructor(e){this.normalizedNames=new Map,this.lazyUpdate=null,e?this.lazyInit="string"==typeof e?()=>{this.headers=new Map,e.split("\n").forEach(t=>{const i=t.indexOf(":");if(i>0){const r=t.slice(0,i),s=r.toLowerCase(),o=t.slice(i+1).trim();this.maybeSetNormalizedName(r,s),this.headers.has(s)?this.headers.get(s).push(o):this.headers.set(s,[o])}})}:()=>{this.headers=new Map,Object.keys(e).forEach(t=>{let i=e[t];const r=t.toLowerCase();"string"==typeof i&&(i=[i]),i.length>0&&(this.headers.set(r,i),this.maybeSetNormalizedName(t,r))})}:this.headers=new Map}has(e){return this.init(),this.headers.has(e.toLowerCase())}get(e){this.init();const t=this.headers.get(e.toLowerCase());return t&&t.length>0?t[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(e){return this.init(),this.headers.get(e.toLowerCase())||null}append(e,t){return this.clone({name:e,value:t,op:"a"})}set(e,t){return this.clone({name:e,value:t,op:"s"})}delete(e,t){return this.clone({name:e,value:t,op:"d"})}maybeSetNormalizedName(e,t){this.normalizedNames.has(t)||this.normalizedNames.set(t,e)}init(){this.lazyInit&&(this.lazyInit instanceof Ho?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(e=>this.applyUpdate(e)),this.lazyUpdate=null))}copyFrom(e){e.init(),Array.from(e.headers.keys()).forEach(t=>{this.headers.set(t,e.headers.get(t)),this.normalizedNames.set(t,e.normalizedNames.get(t))})}clone(e){const t=new Ho;return t.lazyInit=this.lazyInit&&this.lazyInit instanceof Ho?this.lazyInit:this,t.lazyUpdate=(this.lazyUpdate||[]).concat([e]),t}applyUpdate(e){const t=e.name.toLowerCase();switch(e.op){case"a":case"s":let i=e.value;if("string"==typeof i&&(i=[i]),0===i.length)return;this.maybeSetNormalizedName(e.name,t);const r=("a"===e.op?this.headers.get(t):void 0)||[];r.push(...i),this.headers.set(t,r);break;case"d":const s=e.value;if(s){let o=this.headers.get(t);if(!o)return;o=o.filter(a=>-1===s.indexOf(a)),0===o.length?(this.headers.delete(t),this.normalizedNames.delete(t)):this.headers.set(t,o)}else this.headers.delete(t),this.normalizedNames.delete(t)}}forEach(e){this.init(),Array.from(this.normalizedNames.keys()).forEach(t=>e(this.normalizedNames.get(t),this.headers.get(t)))}}class JG{encodeKey(e){return aO(e)}encodeValue(e){return aO(e)}decodeKey(e){return decodeURIComponent(e)}decodeValue(e){return decodeURIComponent(e)}}const ej=/%(\d[a-f0-9])/gi,tj={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function aO(n){return encodeURIComponent(n).replace(ej,(e,t)=>tj[t]??e)}function dw(n){return`${n}`}class Za{constructor(e={}){if(this.updates=null,this.cloneFrom=null,this.encoder=e.encoder||new JG,e.fromString){if(e.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=function QG(n,e){const t=new Map;return n.length>0&&n.replace(/^\?/,"").split("&").forEach(r=>{const s=r.indexOf("="),[o,a]=-1==s?[e.decodeKey(r),""]:[e.decodeKey(r.slice(0,s)),e.decodeValue(r.slice(s+1))],c=t.get(o)||[];c.push(a),t.set(o,c)}),t}(e.fromString,this.encoder)}else e.fromObject?(this.map=new Map,Object.keys(e.fromObject).forEach(t=>{const i=e.fromObject[t],r=Array.isArray(i)?i.map(dw):[dw(i)];this.map.set(t,r)})):this.map=null}has(e){return this.init(),this.map.has(e)}get(e){this.init();const t=this.map.get(e);return t?t[0]:null}getAll(e){return this.init(),this.map.get(e)||null}keys(){return this.init(),Array.from(this.map.keys())}append(e,t){return this.clone({param:e,value:t,op:"a"})}appendAll(e){const t=[];return Object.keys(e).forEach(i=>{const r=e[i];Array.isArray(r)?r.forEach(s=>{t.push({param:i,value:s,op:"a"})}):t.push({param:i,value:r,op:"a"})}),this.clone(t)}set(e,t){return this.clone({param:e,value:t,op:"s"})}delete(e,t){return this.clone({param:e,value:t,op:"d"})}toString(){return this.init(),this.keys().map(e=>{const t=this.encoder.encodeKey(e);return this.map.get(e).map(i=>t+"="+this.encoder.encodeValue(i)).join("&")}).filter(e=>""!==e).join("&")}clone(e){const t=new Za({encoder:this.encoder});return t.cloneFrom=this.cloneFrom||this,t.updates=(this.updates||[]).concat(e),t}init(){null===this.map&&(this.map=new Map),null!==this.cloneFrom&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(e=>this.map.set(e,this.cloneFrom.map.get(e))),this.updates.forEach(e=>{switch(e.op){case"a":case"s":const t=("a"===e.op?this.map.get(e.param):void 0)||[];t.push(dw(e.value)),this.map.set(e.param,t);break;case"d":if(void 0===e.value){this.map.delete(e.param);break}{let i=this.map.get(e.param)||[];const r=i.indexOf(dw(e.value));-1!==r&&i.splice(r,1),i.length>0?this.map.set(e.param,i):this.map.delete(e.param)}}}),this.cloneFrom=this.updates=null)}}class nj{constructor(){this.map=new Map}set(e,t){return this.map.set(e,t),this}get(e){return this.map.has(e)||this.map.set(e,e.defaultValue()),this.map.get(e)}delete(e){return this.map.delete(e),this}has(e){return this.map.has(e)}keys(){return this.map.keys()}}function cO(n){return typeof ArrayBuffer<"u"&&n instanceof ArrayBuffer}function lO(n){return typeof Blob<"u"&&n instanceof Blob}function dO(n){return typeof FormData<"u"&&n instanceof FormData}class Fv{constructor(e,t,i,r){let s;if(this.url=t,this.body=null,this.reportProgress=!1,this.withCredentials=!1,this.responseType="json",this.method=e.toUpperCase(),function ij(n){switch(n){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}(this.method)||r?(this.body=void 0!==i?i:null,s=r):s=i,s&&(this.reportProgress=!!s.reportProgress,this.withCredentials=!!s.withCredentials,s.responseType&&(this.responseType=s.responseType),s.headers&&(this.headers=s.headers),s.context&&(this.context=s.context),s.params&&(this.params=s.params)),this.headers||(this.headers=new Ho),this.context||(this.context=new nj),this.params){const o=this.params.toString();if(0===o.length)this.urlWithParams=t;else{const a=t.indexOf("?");this.urlWithParams=t+(-1===a?"?":ag.set(v,e.setHeaders[v]),c)),e.setParams&&(u=Object.keys(e.setParams).reduce((g,v)=>g.set(v,e.setParams[v]),u)),new Fv(t,i,s,{params:u,headers:c,context:p,reportProgress:a,responseType:r,withCredentials:o})}}var Ms=(()=>((Ms=Ms||{})[Ms.Sent=0]="Sent",Ms[Ms.UploadProgress=1]="UploadProgress",Ms[Ms.ResponseHeader=2]="ResponseHeader",Ms[Ms.DownloadProgress=3]="DownloadProgress",Ms[Ms.Response=4]="Response",Ms[Ms.User=5]="User",Ms))();class JD{constructor(e,t=200,i="OK"){this.headers=e.headers||new Ho,this.status=void 0!==e.status?e.status:t,this.statusText=e.statusText||i,this.url=e.url||null,this.ok=this.status>=200&&this.status<300}}class QD extends JD{constructor(e={}){super(e),this.type=Ms.ResponseHeader}clone(e={}){return new QD({headers:e.headers||this.headers,status:void 0!==e.status?e.status:this.status,statusText:e.statusText||this.statusText,url:e.url||this.url||void 0})}}class uw extends JD{constructor(e={}){super(e),this.type=Ms.Response,this.body=void 0!==e.body?e.body:null}clone(e={}){return new uw({body:void 0!==e.body?e.body:this.body,headers:e.headers||this.headers,status:void 0!==e.status?e.status:this.status,statusText:e.statusText||this.statusText,url:e.url||this.url||void 0})}}class uO extends JD{constructor(e){super(e,0,"Unknown Error"),this.name="HttpErrorResponse",this.ok=!1,this.message=this.status>=200&&this.status<300?`Http failure during parsing for ${e.url||"(unknown url)"}`:`Http failure response for ${e.url||"(unknown url)"}: ${e.status} ${e.statusText}`,this.error=e.error||null}}function eT(n,e){return{body:e,headers:n.headers,context:n.context,observe:n.observe,params:n.params,reportProgress:n.reportProgress,responseType:n.responseType,withCredentials:n.withCredentials}}let Ju=(()=>{class n{constructor(t){this.handler=t}request(t,i,r={}){let s;if(t instanceof Fv)s=t;else{let c,u;c=r.headers instanceof Ho?r.headers:new Ho(r.headers),r.params&&(u=r.params instanceof Za?r.params:new Za({fromObject:r.params})),s=new Fv(t,i,void 0!==r.body?r.body:null,{headers:c,context:r.context,params:u,reportProgress:r.reportProgress,responseType:r.responseType||"json",withCredentials:r.withCredentials})}const o=Tt(s).pipe(Zu(c=>this.handler.handle(c)));if(t instanceof Fv||"events"===r.observe)return o;const a=o.pipe(Ui(c=>c instanceof uw));switch(r.observe||"body"){case"body":switch(s.responseType){case"arraybuffer":return a.pipe(_t(c=>{if(null!==c.body&&!(c.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return c.body}));case"blob":return a.pipe(_t(c=>{if(null!==c.body&&!(c.body instanceof Blob))throw new Error("Response is not a Blob.");return c.body}));case"text":return a.pipe(_t(c=>{if(null!==c.body&&"string"!=typeof c.body)throw new Error("Response is not a string.");return c.body}));default:return a.pipe(_t(c=>c.body))}case"response":return a;default:throw new Error(`Unreachable: unhandled observe type ${r.observe}}`)}}delete(t,i={}){return this.request("DELETE",t,i)}get(t,i={}){return this.request("GET",t,i)}head(t,i={}){return this.request("HEAD",t,i)}jsonp(t,i){return this.request("JSONP",t,{params:(new Za).append(i,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(t,i={}){return this.request("OPTIONS",t,i)}patch(t,i,r={}){return this.request("PATCH",t,eT(r,i))}post(t,i,r={}){return this.request("POST",t,eT(r,i))}put(t,i,r={}){return this.request("PUT",t,eT(r,i))}}return n.\u0275fac=function(t){return new(t||n)(xe(lw))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();function hO(n,e){return e(n)}function sj(n,e){return(t,i)=>e.intercept(t,{handle:r=>n(r,i)})}const tT=new Ze("HTTP_INTERCEPTORS"),Rv=new Ze("HTTP_INTERCEPTOR_FNS");function aj(){let n=null;return(e,t)=>(null===n&&(n=(hn(tT,{optional:!0})??[]).reduceRight(sj,hO)),n(e,t))}let fO=(()=>{class n extends lw{constructor(t,i){super(),this.backend=t,this.injector=i,this.chain=null}handle(t){if(null===this.chain){const i=Array.from(new Set(this.injector.get(Rv)));this.chain=i.reduceRight((r,s)=>function oj(n,e,t){return(i,r)=>t.runInContext(()=>e(i,s=>n(s,r)))}(r,s,this.injector),hO)}return this.chain(t,i=>this.backend.handle(i))}}return n.\u0275fac=function(t){return new(t||n)(xe(ZD),xe(na))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const uj=/^\)\]\}',?\n/;let mO=(()=>{class n{constructor(t){this.xhrFactory=t}handle(t){if("JSONP"===t.method)throw new Error("Attempted to construct Jsonp request without HttpClientJsonpModule installed.");return new un(i=>{const r=this.xhrFactory.build();if(r.open(t.method,t.urlWithParams),t.withCredentials&&(r.withCredentials=!0),t.headers.forEach((y,x)=>r.setRequestHeader(y,x.join(","))),t.headers.has("Accept")||r.setRequestHeader("Accept","application/json, text/plain, */*"),!t.headers.has("Content-Type")){const y=t.detectContentTypeHeader();null!==y&&r.setRequestHeader("Content-Type",y)}if(t.responseType){const y=t.responseType.toLowerCase();r.responseType="json"!==y?y:"text"}const s=t.serializeBody();let o=null;const a=()=>{if(null!==o)return o;const y=r.statusText||"OK",x=new Ho(r.getAllResponseHeaders()),T=function hj(n){return"responseURL"in n&&n.responseURL?n.responseURL:/^X-Request-URL:/m.test(n.getAllResponseHeaders())?n.getResponseHeader("X-Request-URL"):null}(r)||t.url;return o=new QD({headers:x,status:r.status,statusText:y,url:T}),o},c=()=>{let{headers:y,status:x,statusText:T,url:N}=a(),k=null;204!==x&&(k=typeof r.response>"u"?r.responseText:r.response),0===x&&(x=k?200:0);let A=x>=200&&x<300;if("json"===t.responseType&&"string"==typeof k){const H=k;k=k.replace(uj,"");try{k=""!==k?JSON.parse(k):null}catch(G){k=H,A&&(A=!1,k={error:G,text:k})}}A?(i.next(new uw({body:k,headers:y,status:x,statusText:T,url:N||void 0})),i.complete()):i.error(new uO({error:k,headers:y,status:x,statusText:T,url:N||void 0}))},u=y=>{const{url:x}=a(),T=new uO({error:y,status:r.status||0,statusText:r.statusText||"Unknown Error",url:x||void 0});i.error(T)};let p=!1;const g=y=>{p||(i.next(a()),p=!0);let x={type:Ms.DownloadProgress,loaded:y.loaded};y.lengthComputable&&(x.total=y.total),"text"===t.responseType&&r.responseText&&(x.partialText=r.responseText),i.next(x)},v=y=>{let x={type:Ms.UploadProgress,loaded:y.loaded};y.lengthComputable&&(x.total=y.total),i.next(x)};return r.addEventListener("load",c),r.addEventListener("error",u),r.addEventListener("timeout",u),r.addEventListener("abort",u),t.reportProgress&&(r.addEventListener("progress",g),null!==s&&r.upload&&r.upload.addEventListener("progress",v)),r.send(s),i.next({type:Ms.Sent}),()=>{r.removeEventListener("error",u),r.removeEventListener("abort",u),r.removeEventListener("load",c),r.removeEventListener("timeout",u),t.reportProgress&&(r.removeEventListener("progress",g),null!==s&&r.upload&&r.upload.removeEventListener("progress",v)),r.readyState!==r.DONE&&r.abort()}})}}return n.\u0275fac=function(t){return new(t||n)(xe(P3))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const nT=new Ze("XSRF_ENABLED"),gO=new Ze("XSRF_COOKIE_NAME",{providedIn:"root",factory:()=>"XSRF-TOKEN"}),_O=new Ze("XSRF_HEADER_NAME",{providedIn:"root",factory:()=>"X-XSRF-TOKEN"});class vO{}let mj=(()=>{class n{constructor(t,i,r){this.doc=t,this.platform=i,this.cookieName=r,this.lastCookieString="",this.lastToken=null,this.parseCount=0}getToken(){if("server"===this.platform)return null;const t=this.doc.cookie||"";return t!==this.lastCookieString&&(this.parseCount++,this.lastToken=w3(t,this.cookieName),this.lastCookieString=t),this.lastToken}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn),xe(U1),xe(gO))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();function gj(n,e){const t=n.url.toLowerCase();if(!hn(nT)||"GET"===n.method||"HEAD"===n.method||t.startsWith("http://")||t.startsWith("https://"))return e(n);const i=hn(vO).getToken(),r=hn(_O);return null!=i&&!n.headers.has(r)&&(n=n.clone({headers:n.headers.set(r,i)})),e(n)}var os=(()=>((os=os||{})[os.Interceptors=0]="Interceptors",os[os.LegacyInterceptors=1]="LegacyInterceptors",os[os.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",os[os.NoXsrfProtection=3]="NoXsrfProtection",os[os.JsonpSupport=4]="JsonpSupport",os[os.RequestsMadeViaParent=5]="RequestsMadeViaParent",os))();function ng(n,e){return{\u0275kind:n,\u0275providers:e}}function _j(...n){const e=[Ju,mO,fO,{provide:lw,useExisting:fO},{provide:ZD,useExisting:mO},{provide:Rv,useValue:gj,multi:!0},{provide:nT,useValue:!0},{provide:vO,useClass:mj}];for(const t of n)e.push(...t.\u0275providers);return Fx(e)}const yO=new Ze("LEGACY_INTERCEPTOR_FN");let yj=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[_j(ng(os.LegacyInterceptors,[{provide:yO,useFactory:aj},{provide:Rv,useExisting:yO,multi:!0}]))]}),n})();function ig(...n){if(1===n.length){const e=n[0];if(_i(e))return hw(e,null);if(ao(e)&&Object.getPrototypeOf(e)===Object.prototype){const t=Object.keys(e);return hw(t.map(i=>e[i]),t)}}if("function"==typeof n[n.length-1]){const e=n.pop();return hw(n=1===n.length&&_i(n[0])?n[0]:n,null).pipe(_t(t=>e(...t)))}return hw(n,null)}function hw(n,e){return new un(t=>{const i=n.length;if(0===i)return void t.complete();const r=new Array(i);let s=0,o=0;for(let a=0;a{u||(u=!0,o++),r[a]=p},error:p=>t.error(p),complete:()=>{s++,(s===i||!u)&&(o===i&&t.next(e?e.reduce((p,g,v)=>(p[g]=r[v],p),{}):r),t.complete())}}))}})}let bO=(()=>{class n{constructor(t,i){this._renderer=t,this._elementRef=i,this.onChange=r=>{},this.onTouched=()=>{}}setProperty(t,i){this._renderer.setProperty(this._elementRef.nativeElement,t,i)}registerOnTouched(t){this.onTouched=t}registerOnChange(t){this.onChange=t}setDisabledState(t){this.setProperty("disabled",t)}}return n.\u0275fac=function(t){return new(t||n)(ie(el),ie(_n))},n.\u0275dir=ut({type:n}),n})(),Pf=(()=>{class n extends bO{}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275dir=ut({type:n,features:[Z]}),n})();const Ja=new Ze("NgValueAccessor"),xj={provide:Ja,useExisting:Mi(()=>iT),multi:!0},Sj=new Ze("CompositionEventMode");let iT=(()=>{class n extends bO{constructor(t,i,r){super(t,i),this._compositionMode=r,this._composing=!1,null==this._compositionMode&&(this._compositionMode=!function wj(){const n=Nd()?Nd().getUserAgent():"";return/android (\d+)/.test(n.toLowerCase())}())}writeValue(t){this.setProperty("value",t??"")}_handleInput(t){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(t)}_compositionStart(){this._composing=!0}_compositionEnd(t){this._composing=!1,this._compositionMode&&this.onChange(t)}}return n.\u0275fac=function(t){return new(t||n)(ie(el),ie(_n),ie(Sj,8))},n.\u0275dir=ut({type:n,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(t,i){1&t&&Gn("input",function(s){return i._handleInput(s.target.value)})("blur",function(){return i.onTouched()})("compositionstart",function(){return i._compositionStart()})("compositionend",function(s){return i._compositionEnd(s.target.value)})},features:[Oi([xj]),Z]}),n})();const Ej=!1;function Qu(n){return null==n||("string"==typeof n||Array.isArray(n))&&0===n.length}function wO(n){return null!=n&&"number"==typeof n.length}const xo=new Ze("NgValidators"),eh=new Ze("NgAsyncValidators"),Mj=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;class Cj{static min(e){return function SO(n){return e=>{if(Qu(e.value)||Qu(n))return null;const t=parseFloat(e.value);return!isNaN(t)&&t{if(Qu(e.value)||Qu(n))return null;const t=parseFloat(e.value);return!isNaN(t)&&t>n?{max:{max:n,actual:e.value}}:null}}(e)}static required(e){return function MO(n){return Qu(n.value)?{required:!0}:null}(e)}static requiredTrue(e){return function CO(n){return!0===n.value?null:{required:!0}}(e)}static email(e){return function DO(n){return Qu(n.value)||Mj.test(n.value)?null:{email:!0}}(e)}static minLength(e){return function TO(n){return e=>Qu(e.value)||!wO(e.value)?null:e.value.lengthwO(e.value)&&e.value.length>n?{maxlength:{requiredLength:n,actualLength:e.value.length}}:null}(e)}static pattern(e){return function kO(n){if(!n)return fw;let e,t;return"string"==typeof n?(t="","^"!==n.charAt(0)&&(t+="^"),t+=n,"$"!==n.charAt(n.length-1)&&(t+="$"),e=new RegExp(t)):(t=n.toString(),e=n),i=>{if(Qu(i.value))return null;const r=i.value;return e.test(r)?null:{pattern:{requiredPattern:t,actualValue:r}}}}(e)}static nullValidator(e){return null}static compose(e){return LO(e)}static composeAsync(e){return NO(e)}}function fw(n){return null}function IO(n){return null!=n}function FO(n){const e=lv(n)?dr(n):n;if(Ej&&!PC(e)){let t="Expected async validator to return Promise or Observable.";throw"object"==typeof n&&(t+=" Are you using a synchronous validator where an async validator is expected?"),new Ue(-1101,t)}return e}function RO(n){let e={};return n.forEach(t=>{e=null!=t?{...e,...t}:e}),0===Object.keys(e).length?null:e}function PO(n,e){return e.map(t=>t(n))}function OO(n){return n.map(e=>function Dj(n){return!n.validate}(e)?e:t=>e.validate(t))}function LO(n){if(!n)return null;const e=n.filter(IO);return 0==e.length?null:function(t){return RO(PO(t,e))}}function rT(n){return null!=n?LO(OO(n)):null}function NO(n){if(!n)return null;const e=n.filter(IO);return 0==e.length?null:function(t){return ig(PO(t,e).map(FO)).pipe(_t(RO))}}function sT(n){return null!=n?NO(OO(n)):null}function BO(n,e){return null===n?[e]:Array.isArray(n)?[...n,e]:[n,e]}function VO(n){return n._rawValidators}function HO(n){return n._rawAsyncValidators}function oT(n){return n?Array.isArray(n)?n:[n]:[]}function pw(n,e){return Array.isArray(n)?n.includes(e):n===e}function UO(n,e){const t=oT(e);return oT(n).forEach(r=>{pw(t,r)||t.push(r)}),t}function zO(n,e){return oT(e).filter(t=>!pw(n,t))}class GO{constructor(){this._rawValidators=[],this._rawAsyncValidators=[],this._onDestroyCallbacks=[]}get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_setValidators(e){this._rawValidators=e||[],this._composedValidatorFn=rT(this._rawValidators)}_setAsyncValidators(e){this._rawAsyncValidators=e||[],this._composedAsyncValidatorFn=sT(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_registerOnDestroy(e){this._onDestroyCallbacks.push(e)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(e=>e()),this._onDestroyCallbacks=[]}reset(e){this.control&&this.control.reset(e)}hasError(e,t){return!!this.control&&this.control.hasError(e,t)}getError(e,t){return this.control?this.control.getError(e,t):null}}class ca extends GO{get formDirective(){return null}get path(){return null}}class Hd extends GO{constructor(){super(...arguments),this._parent=null,this.name=null,this.valueAccessor=null}}class jO{constructor(e){this._cd=e}get isTouched(){return!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return!!this._cd?.submitted}}let aT=(()=>{class n extends jO{constructor(t){super(t)}}return n.\u0275fac=function(t){return new(t||n)(ie(Hd,2))},n.\u0275dir=ut({type:n,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(t,i){2&t&&hi("ng-untouched",i.isUntouched)("ng-touched",i.isTouched)("ng-pristine",i.isPristine)("ng-dirty",i.isDirty)("ng-valid",i.isValid)("ng-invalid",i.isInvalid)("ng-pending",i.isPending)},features:[Z]}),n})();function WO(n,e){return n?`with name: '${e}'`:`at index: ${e}`}const dT=!1,Pv="VALID",gw="INVALID",rg="PENDING",Ov="DISABLED";function uT(n){return(_w(n)?n.validators:n)||null}function hT(n,e){return(_w(e)?e.asyncValidators:n)||null}function _w(n){return null!=n&&!Array.isArray(n)&&"object"==typeof n}class KO{constructor(e,t){this._pendingDirty=!1,this._hasOwnPendingAsyncValidator=!1,this._pendingTouched=!1,this._onCollectionChange=()=>{},this._parent=null,this.pristine=!0,this.touched=!1,this._onDisabledChange=[],this._assignValidators(e),this._assignAsyncValidators(t)}get validator(){return this._composedValidatorFn}set validator(e){this._rawValidators=this._composedValidatorFn=e}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(e){this._rawAsyncValidators=this._composedAsyncValidatorFn=e}get parent(){return this._parent}get valid(){return this.status===Pv}get invalid(){return this.status===gw}get pending(){return this.status==rg}get disabled(){return this.status===Ov}get enabled(){return this.status!==Ov}get dirty(){return!this.pristine}get untouched(){return!this.touched}get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(e){this._assignValidators(e)}setAsyncValidators(e){this._assignAsyncValidators(e)}addValidators(e){this.setValidators(UO(e,this._rawValidators))}addAsyncValidators(e){this.setAsyncValidators(UO(e,this._rawAsyncValidators))}removeValidators(e){this.setValidators(zO(e,this._rawValidators))}removeAsyncValidators(e){this.setAsyncValidators(zO(e,this._rawAsyncValidators))}hasValidator(e){return pw(this._rawValidators,e)}hasAsyncValidator(e){return pw(this._rawAsyncValidators,e)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(e={}){this.touched=!0,this._parent&&!e.onlySelf&&this._parent.markAsTouched(e)}markAllAsTouched(){this.markAsTouched({onlySelf:!0}),this._forEachChild(e=>e.markAllAsTouched())}markAsUntouched(e={}){this.touched=!1,this._pendingTouched=!1,this._forEachChild(t=>{t.markAsUntouched({onlySelf:!0})}),this._parent&&!e.onlySelf&&this._parent._updateTouched(e)}markAsDirty(e={}){this.pristine=!1,this._parent&&!e.onlySelf&&this._parent.markAsDirty(e)}markAsPristine(e={}){this.pristine=!0,this._pendingDirty=!1,this._forEachChild(t=>{t.markAsPristine({onlySelf:!0})}),this._parent&&!e.onlySelf&&this._parent._updatePristine(e)}markAsPending(e={}){this.status=rg,!1!==e.emitEvent&&this.statusChanges.emit(this.status),this._parent&&!e.onlySelf&&this._parent.markAsPending(e)}disable(e={}){const t=this._parentMarkedDirty(e.onlySelf);this.status=Ov,this.errors=null,this._forEachChild(i=>{i.disable({...e,onlySelf:!0})}),this._updateValue(),!1!==e.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors({...e,skipPristineCheck:t}),this._onDisabledChange.forEach(i=>i(!0))}enable(e={}){const t=this._parentMarkedDirty(e.onlySelf);this.status=Pv,this._forEachChild(i=>{i.enable({...e,onlySelf:!0})}),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent}),this._updateAncestors({...e,skipPristineCheck:t}),this._onDisabledChange.forEach(i=>i(!1))}_updateAncestors(e){this._parent&&!e.onlySelf&&(this._parent.updateValueAndValidity(e),e.skipPristineCheck||this._parent._updatePristine(),this._parent._updateTouched())}setParent(e){this._parent=e}getRawValue(){return this.value}updateValueAndValidity(e={}){this._setInitialStatus(),this._updateValue(),this.enabled&&(this._cancelExistingSubscription(),this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===Pv||this.status===rg)&&this._runAsyncValidator(e.emitEvent)),!1!==e.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!e.onlySelf&&this._parent.updateValueAndValidity(e)}_updateTreeValidity(e={emitEvent:!0}){this._forEachChild(t=>t._updateTreeValidity(e)),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?Ov:Pv}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(e){if(this.asyncValidator){this.status=rg,this._hasOwnPendingAsyncValidator=!0;const t=FO(this.asyncValidator(this));this._asyncValidationSubscription=t.subscribe(i=>{this._hasOwnPendingAsyncValidator=!1,this.setErrors(i,{emitEvent:e})})}}_cancelExistingSubscription(){this._asyncValidationSubscription&&(this._asyncValidationSubscription.unsubscribe(),this._hasOwnPendingAsyncValidator=!1)}setErrors(e,t={}){this.errors=e,this._updateControlsErrors(!1!==t.emitEvent)}get(e){let t=e;return null==t||(Array.isArray(t)||(t=t.split(".")),0===t.length)?null:t.reduce((i,r)=>i&&i._find(r),this)}getError(e,t){const i=t?this.get(t):this;return i&&i.errors?i.errors[e]:null}hasError(e,t){return!!this.getError(e,t)}get root(){let e=this;for(;e._parent;)e=e._parent;return e}_updateControlsErrors(e){this.status=this._calculateStatus(),e&&this.statusChanges.emit(this.status),this._parent&&this._parent._updateControlsErrors(e)}_initObservables(){this.valueChanges=new Pn,this.statusChanges=new Pn}_calculateStatus(){return this._allControlsDisabled()?Ov:this.errors?gw:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(rg)?rg:this._anyControlsHaveStatus(gw)?gw:Pv}_anyControlsHaveStatus(e){return this._anyControls(t=>t.status===e)}_anyControlsDirty(){return this._anyControls(e=>e.dirty)}_anyControlsTouched(){return this._anyControls(e=>e.touched)}_updatePristine(e={}){this.pristine=!this._anyControlsDirty(),this._parent&&!e.onlySelf&&this._parent._updatePristine(e)}_updateTouched(e={}){this.touched=this._anyControlsTouched(),this._parent&&!e.onlySelf&&this._parent._updateTouched(e)}_registerOnCollectionChange(e){this._onCollectionChange=e}_setUpdateStrategy(e){_w(e)&&null!=e.updateOn&&(this._updateOn=e.updateOn)}_parentMarkedDirty(e){return!e&&!(!this._parent||!this._parent.dirty)&&!this._parent._anyControlsDirty()}_find(e){return null}_assignValidators(e){this._rawValidators=Array.isArray(e)?e.slice():e,this._composedValidatorFn=function Oj(n){return Array.isArray(n)?rT(n):n||null}(this._rawValidators)}_assignAsyncValidators(e){this._rawAsyncValidators=Array.isArray(e)?e.slice():e,this._composedAsyncValidatorFn=function Lj(n){return Array.isArray(n)?sT(n):n||null}(this._rawAsyncValidators)}}class fT extends KO{constructor(e,t,i){super(uT(t),hT(i,t)),this.controls=e,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}registerControl(e,t){return this.controls[e]?this.controls[e]:(this.controls[e]=t,t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange),t)}addControl(e,t,i={}){this.registerControl(e,t),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}removeControl(e,t={}){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}setControl(e,t,i={}){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],t&&this.registerControl(e,t),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}contains(e){return this.controls.hasOwnProperty(e)&&this.controls[e].enabled}setValue(e,t={}){(function qO(n,e,t){n._forEachChild((i,r)=>{if(void 0===t[r])throw new Ue(1002,dT?function Pj(n,e){return`Must supply a value for form control ${WO(n,e)}`}(e,r):"")})})(this,!0,e),Object.keys(e).forEach(i=>{(function $O(n,e,t){const i=n.controls;if(!(e?Object.keys(i):i).length)throw new Ue(1e3,dT?function Fj(n){return`\n There are no form controls registered with this ${n?"group":"array"} yet. If you're using ngModel,\n you may want to check next tick (e.g. use setTimeout).\n `}(e):"");if(!i[t])throw new Ue(1001,dT?function Rj(n,e){return`Cannot find form control ${WO(n,e)}`}(e,t):"")})(this,!0,i),this.controls[i].setValue(e[i],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(e,t={}){null!=e&&(Object.keys(e).forEach(i=>{const r=this.controls[i];r&&r.patchValue(e[i],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t))}reset(e={},t={}){this._forEachChild((i,r)=>{i.reset(e[r],{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t),this._updateTouched(t),this.updateValueAndValidity(t)}getRawValue(){return this._reduceChildren({},(e,t,i)=>(e[i]=t.getRawValue(),e))}_syncPendingControls(){let e=this._reduceChildren(!1,(t,i)=>!!i._syncPendingControls()||t);return e&&this.updateValueAndValidity({onlySelf:!0}),e}_forEachChild(e){Object.keys(this.controls).forEach(t=>{const i=this.controls[t];i&&e(i,t)})}_setUpControls(){this._forEachChild(e=>{e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(e){for(const[t,i]of Object.entries(this.controls))if(this.contains(t)&&e(i))return!0;return!1}_reduceValue(){return this._reduceChildren({},(t,i,r)=>((i.enabled||this.disabled)&&(t[r]=i.value),t))}_reduceChildren(e,t){let i=e;return this._forEachChild((r,s)=>{i=t(i,r,s)}),i}_allControlsDisabled(){for(const e of Object.keys(this.controls))if(this.controls[e].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(e){return this.controls.hasOwnProperty(e)?this.controls[e]:null}}const sg=new Ze("CallSetDisabledState",{providedIn:"root",factory:()=>vw}),vw="always";function Lv(n,e,t=vw){pT(n,e),e.valueAccessor.writeValue(n.value),(n.disabled||"always"===t)&&e.valueAccessor.setDisabledState?.(n.disabled),function Vj(n,e){e.valueAccessor.registerOnChange(t=>{n._pendingValue=t,n._pendingChange=!0,n._pendingDirty=!0,"change"===n.updateOn&&YO(n,e)})}(n,e),function Uj(n,e){const t=(i,r)=>{e.valueAccessor.writeValue(i),r&&e.viewToModelUpdate(i)};n.registerOnChange(t),e._registerOnDestroy(()=>{n._unregisterOnChange(t)})}(n,e),function Hj(n,e){e.valueAccessor.registerOnTouched(()=>{n._pendingTouched=!0,"blur"===n.updateOn&&n._pendingChange&&YO(n,e),"submit"!==n.updateOn&&n.markAsTouched()})}(n,e),function Bj(n,e){if(e.valueAccessor.setDisabledState){const t=i=>{e.valueAccessor.setDisabledState(i)};n.registerOnDisabledChange(t),e._registerOnDestroy(()=>{n._unregisterOnDisabledChange(t)})}}(n,e)}function bw(n,e,t=!0){const i=()=>{};e.valueAccessor&&(e.valueAccessor.registerOnChange(i),e.valueAccessor.registerOnTouched(i)),ww(n,e),n&&(e._invokeOnDestroyCallbacks(),n._registerOnCollectionChange(()=>{}))}function xw(n,e){n.forEach(t=>{t.registerOnValidatorChange&&t.registerOnValidatorChange(e)})}function pT(n,e){const t=VO(n);null!==e.validator?n.setValidators(BO(t,e.validator)):"function"==typeof t&&n.setValidators([t]);const i=HO(n);null!==e.asyncValidator?n.setAsyncValidators(BO(i,e.asyncValidator)):"function"==typeof i&&n.setAsyncValidators([i]);const r=()=>n.updateValueAndValidity();xw(e._rawValidators,r),xw(e._rawAsyncValidators,r)}function ww(n,e){let t=!1;if(null!==n){if(null!==e.validator){const r=VO(n);if(Array.isArray(r)&&r.length>0){const s=r.filter(o=>o!==e.validator);s.length!==r.length&&(t=!0,n.setValidators(s))}}if(null!==e.asyncValidator){const r=HO(n);if(Array.isArray(r)&&r.length>0){const s=r.filter(o=>o!==e.asyncValidator);s.length!==r.length&&(t=!0,n.setAsyncValidators(s))}}}const i=()=>{};return xw(e._rawValidators,i),xw(e._rawAsyncValidators,i),t}function YO(n,e){n._pendingDirty&&n.markAsDirty(),n.setValue(n._pendingValue,{emitModelToViewChange:!1}),e.viewToModelUpdate(n._pendingValue),n._pendingChange=!1}function XO(n,e){pT(n,e)}function ZO(n,e){n._syncPendingControls(),e.forEach(t=>{const i=t.control;"submit"===i.updateOn&&i._pendingChange&&(t.viewToModelUpdate(i._pendingValue),i._pendingChange=!1)})}const $j={provide:ca,useExisting:Mi(()=>Sw)},Nv=(()=>Promise.resolve())();let Sw=(()=>{class n extends ca{constructor(t,i,r){super(),this.callSetDisabledState=r,this.submitted=!1,this._directives=new Set,this.ngSubmit=new Pn,this.form=new fT({},rT(t),sT(i))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(t){Nv.then(()=>{const i=this._findContainer(t.path);t.control=i.registerControl(t.name,t.control),Lv(t.control,t,this.callSetDisabledState),t.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(t)})}getControl(t){return this.form.get(t.path)}removeControl(t){Nv.then(()=>{const i=this._findContainer(t.path);i&&i.removeControl(t.name),this._directives.delete(t)})}addFormGroup(t){Nv.then(()=>{const i=this._findContainer(t.path),r=new fT({});XO(r,t),i.registerControl(t.name,r),r.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(t){Nv.then(()=>{const i=this._findContainer(t.path);i&&i.removeControl(t.name)})}getFormGroup(t){return this.form.get(t.path)}updateModel(t,i){Nv.then(()=>{this.form.get(t.path).setValue(i)})}setValue(t){this.control.setValue(t)}onSubmit(t){return this.submitted=!0,ZO(this.form,this._directives),this.ngSubmit.emit(t),"dialog"===t?.target?.method}onReset(){this.resetForm()}resetForm(t){this.form.reset(t),this.submitted=!1}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.form._updateOn=this.options.updateOn)}_findContainer(t){return t.pop(),t.length?this.form.get(t):this.form}}return n.\u0275fac=function(t){return new(t||n)(ie(xo,10),ie(eh,10),ie(sg,8))},n.\u0275dir=ut({type:n,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(t,i){1&t&&Gn("submit",function(s){return i.onSubmit(s)})("reset",function(){return i.onReset()})},inputs:{options:["ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Oi([$j]),Z]}),n})();function JO(n,e){const t=n.indexOf(e);t>-1&&n.splice(t,1)}function QO(n){return"object"==typeof n&&null!==n&&2===Object.keys(n).length&&"value"in n&&"disabled"in n}const eL=class extends KO{constructor(e=null,t,i){super(uT(t),hT(i,t)),this.defaultValue=null,this._onChange=[],this._pendingChange=!1,this._applyFormState(e),this._setUpdateStrategy(t),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),_w(t)&&(t.nonNullable||t.initialValueIsDefault)&&(this.defaultValue=QO(e)?e.value:e)}setValue(e,t={}){this.value=this._pendingValue=e,this._onChange.length&&!1!==t.emitModelToViewChange&&this._onChange.forEach(i=>i(this.value,!1!==t.emitViewToModelChange)),this.updateValueAndValidity(t)}patchValue(e,t={}){this.setValue(e,t)}reset(e=this.defaultValue,t={}){this._applyFormState(e),this.markAsPristine(t),this.markAsUntouched(t),this.setValue(this.value,t),this._pendingChange=!1}_updateValue(){}_anyControls(e){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(e){this._onChange.push(e)}_unregisterOnChange(e){JO(this._onChange,e)}registerOnDisabledChange(e){this._onDisabledChange.push(e)}_unregisterOnDisabledChange(e){JO(this._onDisabledChange,e)}_forEachChild(e){}_syncPendingControls(){return!("submit"!==this.updateOn||(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),!this._pendingChange)||(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),0))}_applyFormState(e){QO(e)?(this.value=this._pendingValue=e.value,e.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=e}},Yj={provide:Hd,useExisting:Mi(()=>Ew)},iL=(()=>Promise.resolve())();let Ew=(()=>{class n extends Hd{constructor(t,i,r,s,o,a){super(),this._changeDetectorRef=o,this.callSetDisabledState=a,this.control=new eL,this._registered=!1,this.update=new Pn,this._parent=t,this._setValidators(i),this._setAsyncValidators(r),this.valueAccessor=function _T(n,e){if(!e)return null;let t,i,r;return Array.isArray(e),e.forEach(s=>{s.constructor===iT?t=s:function jj(n){return Object.getPrototypeOf(n.constructor)===Pf}(s)?i=s:r=s}),r||i||t||null}(0,s)}ngOnChanges(t){if(this._checkForErrors(),!this._registered||"name"in t){if(this._registered&&(this._checkName(),this.formDirective)){const i=t.name.previousValue;this.formDirective.removeControl({name:i,path:this._getPath(i)})}this._setUpControl()}"isDisabled"in t&&this._updateDisabled(t),function gT(n,e){if(!n.hasOwnProperty("model"))return!1;const t=n.model;return!!t.isFirstChange()||!Object.is(e,t.currentValue)}(t,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!(!this.options||!this.options.standalone)}_setUpStandalone(){Lv(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._isStandalone()||this._checkParentType(),this._checkName()}_checkParentType(){}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),this._isStandalone()}_updateValue(t){iL.then(()=>{this.control.setValue(t,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(t){const i=t.isDisabled.currentValue,r=0!==i&&function Qm(n){return"boolean"==typeof n?n:null!=n&&"false"!==n}(i);iL.then(()=>{r&&!this.control.disabled?this.control.disable():!r&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(t){return this._parent?function yw(n,e){return[...e.path,n]}(t,this._parent):[t]}}return n.\u0275fac=function(t){return new(t||n)(ie(ca,9),ie(xo,10),ie(eh,10),ie(Ja,10),ie(aa,8),ie(sg,8))},n.\u0275dir=ut({type:n,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:["disabled","isDisabled"],model:["ngModel","model"],options:["ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],features:[Oi([Yj]),Z,Cn]}),n})(),sL=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})();const nW={provide:ca,useExisting:Mi(()=>Mw)};let ET,Mw=(()=>{class n extends ca{constructor(t,i,r){super(),this.callSetDisabledState=r,this.submitted=!1,this._onCollectionChange=()=>this._updateDomValue(),this.directives=[],this.form=null,this.ngSubmit=new Pn,this._setValidators(t),this._setAsyncValidators(i)}ngOnChanges(t){this._checkFormPresent(),t.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(ww(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(t){const i=this.form.get(t.path);return Lv(i,t,this.callSetDisabledState),i.updateValueAndValidity({emitEvent:!1}),this.directives.push(t),i}getControl(t){return this.form.get(t.path)}removeControl(t){bw(t.control||null,t,!1),function Wj(n,e){const t=n.indexOf(e);t>-1&&n.splice(t,1)}(this.directives,t)}addFormGroup(t){this._setUpFormContainer(t)}removeFormGroup(t){this._cleanUpFormContainer(t)}getFormGroup(t){return this.form.get(t.path)}addFormArray(t){this._setUpFormContainer(t)}removeFormArray(t){this._cleanUpFormContainer(t)}getFormArray(t){return this.form.get(t.path)}updateModel(t,i){this.form.get(t.path).setValue(i)}onSubmit(t){return this.submitted=!0,ZO(this.form,this.directives),this.ngSubmit.emit(t),"dialog"===t?.target?.method}onReset(){this.resetForm()}resetForm(t){this.form.reset(t),this.submitted=!1}_updateDomValue(){this.directives.forEach(t=>{const i=t.control,r=this.form.get(t.path);i!==r&&(bw(i||null,t),(n=>n instanceof eL)(r)&&(Lv(r,t,this.callSetDisabledState),t.control=r))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(t){const i=this.form.get(t.path);XO(i,t),i.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(t){if(this.form){const i=this.form.get(t.path);i&&function zj(n,e){return ww(n,e)}(i,t)&&i.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){pT(this.form,this),this._oldForm&&ww(this._oldForm,this)}_checkFormPresent(){}}return n.\u0275fac=function(t){return new(t||n)(ie(xo,10),ie(eh,10),ie(sg,8))},n.\u0275dir=ut({type:n,selectors:[["","formGroup",""]],hostBindings:function(t,i){1&t&&Gn("submit",function(s){return i.onSubmit(s)})("reset",function(){return i.onReset()})},inputs:{form:["formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Oi([nW]),Z,Cn]}),n})(),bW=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[sL]}),n})(),wW=(()=>{class n{static withConfig(t){return{ngModule:n,providers:[{provide:sg,useValue:t.callSetDisabledState??vw}]}}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[bW]}),n})();try{ET=typeof Intl<"u"&&Intl.v8BreakIterator}catch{ET=!1}let Bv,Cw,Lf,MT,as=(()=>{class n{constructor(t){this._platformId=t,this.isBrowser=this._platformId?function Gz(n){return n===F3}(this._platformId):"object"==typeof document&&!!document,this.EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent),this.TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent),this.BLINK=this.isBrowser&&!(!window.chrome&&!ET)&&typeof CSS<"u"&&!this.EDGE&&!this.TRIDENT,this.WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT,this.IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window),this.FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent),this.ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT,this.SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT}}return n.\u0275fac=function(t){return new(t||n)(xe(U1))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function Vv(n){return function SW(){if(null==Bv&&typeof window<"u")try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>Bv=!0}))}finally{Bv=Bv||!1}return Bv}()?n:!!n.capture}function SL(){if(null==Lf){if("object"!=typeof document||!document||"function"!=typeof Element||!Element)return Lf=!1,Lf;if("scrollBehavior"in document.documentElement.style)Lf=!0;else{const n=Element.prototype.scrollTo;Lf=!!n&&!/\{\s*\[native code\]\s*\}/.test(n.toString())}}return Lf}function Hv(){if("object"!=typeof document||!document)return 0;if(null==Cw){const n=document.createElement("div"),e=n.style;n.dir="rtl",e.width="1px",e.overflow="auto",e.visibility="hidden",e.pointerEvents="none",e.position="absolute";const t=document.createElement("div"),i=t.style;i.width="2px",i.height="1px",n.appendChild(t),document.body.appendChild(n),Cw=0,0===n.scrollLeft&&(n.scrollLeft=1,Cw=0===n.scrollLeft?1:2),n.remove()}return Cw}function Dw(){let n=typeof document<"u"&&document?document.activeElement:null;for(;n&&n.shadowRoot;){const e=n.shadowRoot.activeElement;if(e===n)break;n=e}return n}function th(n){return n.composedPath?n.composedPath()[0]:n.target}function CT(){return typeof __karma__<"u"&&!!__karma__||typeof jasmine<"u"&&!!jasmine||typeof jest<"u"&&!!jest||typeof Mocha<"u"&&!!Mocha}class er extends cn{constructor(e){super(),this._value=e}get value(){return this.getValue()}_subscribe(e){const t=super._subscribe(e);return t&&!t.closed&&e.next(this._value),t}getValue(){if(this.hasError)throw this.thrownError;if(this.closed)throw new Pa;return this._value}next(e){super.next(this._value=e)}}function ql(n,...e){return e.length?e.some(t=>n[t]):n.altKey||n.shiftKey||n.ctrlKey||n.metaKey}function nh(){}function Dr(n,e,t){return function(r){return r.lift(new VW(n,e,t))}}class VW{constructor(e,t,i){this.nextOrObserver=e,this.error=t,this.complete=i}call(e,t){return t.subscribe(new HW(e,this.nextOrObserver,this.error,this.complete))}}class HW extends di{constructor(e,t,i,r){super(e),this._tapNext=nh,this._tapError=nh,this._tapComplete=nh,this._tapError=i||nh,this._tapComplete=r||nh,qr(t)?(this._context=this,this._tapNext=t):t&&(this._context=t,this._tapNext=t.next||nh,this._tapError=t.error||nh,this._tapComplete=t.complete||nh)}_next(e){try{this._tapNext.call(this._context,e)}catch(t){return void this.destination.error(t)}this.destination.next(e)}_error(e){try{this._tapError.call(this._context,e)}catch(t){return void this.destination.error(t)}this.destination.error(e)}_complete(){try{this._tapComplete.call(this._context)}catch(e){return void this.destination.error(e)}return this.destination.complete()}}class UW extends Tn{constructor(e,t){super()}schedule(e,t=0){return this}}class kT extends UW{constructor(e,t){super(e,t),this.scheduler=e,this.work=t,this.pending=!1}schedule(e,t=0){if(this.closed)return this;this.state=e;const i=this.id,r=this.scheduler;return null!=i&&(this.id=this.recycleAsyncId(r,i,t)),this.pending=!0,this.delay=t,this.id=this.id||this.requestAsyncId(r,this.id,t),this}requestAsyncId(e,t,i=0){return setInterval(e.flush.bind(e,this),i)}recycleAsyncId(e,t,i=0){if(null!==i&&this.delay===i&&!1===this.pending)return t;clearInterval(t)}execute(e,t){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;const i=this._execute(e,t);if(i)return i;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(e,t){let r,i=!1;try{this.work(e)}catch(s){i=!0,r=!!s&&s||new Error(s)}if(i)return this.unsubscribe(),r}_unsubscribe(){const e=this.id,t=this.scheduler,i=t.actions,r=i.indexOf(this);this.work=null,this.state=null,this.pending=!1,this.scheduler=null,-1!==r&&i.splice(r,1),null!=e&&(this.id=this.recycleAsyncId(t,e,null)),this.delay=null}}let CL=(()=>{class n{constructor(t,i=n.now){this.SchedulerAction=t,this.now=i}schedule(t,i=0,r){return new this.SchedulerAction(this,t).schedule(r,i)}}return n.now=()=>Date.now(),n})();class Kl extends CL{constructor(e,t=CL.now){super(e,()=>Kl.delegate&&Kl.delegate!==this?Kl.delegate.now():t()),this.actions=[],this.active=!1,this.scheduled=void 0}schedule(e,t=0,i){return Kl.delegate&&Kl.delegate!==this?Kl.delegate.schedule(e,t,i):super.schedule(e,t,i)}flush(e){const{actions:t}=this;if(this.active)return void t.push(e);let i;this.active=!0;do{if(i=e.execute(e.state,e.delay))break}while(e=t.shift());if(this.active=!1,i){for(;e=t.shift();)e.unsubscribe();throw i}}}const ag=new Kl(kT);function zv(n,e=ag){return t=>t.lift(new zW(n,e))}class zW{constructor(e,t){this.dueTime=e,this.scheduler=t}call(e,t){return t.subscribe(new GW(e,this.dueTime,this.scheduler))}}class GW extends di{constructor(e,t,i){super(e),this.dueTime=t,this.scheduler=i,this.debouncedSubscription=null,this.lastValue=null,this.hasValue=!1}_next(e){this.clearDebounce(),this.lastValue=e,this.hasValue=!0,this.add(this.debouncedSubscription=this.scheduler.schedule(jW,this.dueTime,this))}_complete(){this.debouncedNext(),this.destination.complete()}debouncedNext(){if(this.clearDebounce(),this.hasValue){const{lastValue:e}=this;this.lastValue=null,this.hasValue=!1,this.destination.next(e)}}clearDebounce(){const e=this.debouncedSubscription;null!==e&&(this.remove(e),e.unsubscribe(),this.debouncedSubscription=null)}}function jW(n){n.debouncedNext()}const DL=(()=>{function n(){return Error.call(this),this.message="argument out of range",this.name="ArgumentOutOfRangeError",this}return n.prototype=Object.create(Error.prototype),n})(),Fc=new un(n=>n.complete());function kw(n){return n?function WW(n){return new un(e=>n.schedule(()=>e.complete()))}(n):Fc}function Gr(n){return e=>0===n?kw():e.lift(new $W(n))}class $W{constructor(e){if(this.total=e,this.total<0)throw new DL}call(e,t){return t.subscribe(new qW(e,this.total))}}class qW extends di{constructor(e,t){super(e),this.total=t,this.count=0}_next(e){const t=this.total,i=++this.count;i<=t&&(this.destination.next(e),i===t&&(this.destination.complete(),this.unsubscribe()))}}function TL(n){return e=>e.lift(new KW(n))}class KW{constructor(e){this.total=e}call(e,t){return t.subscribe(new YW(e,this.total))}}class YW extends di{constructor(e,t){super(e),this.total=t,this.count=0}_next(e){++this.count>this.total&&this.destination.next(e)}}function Rc(n,e){return t=>t.lift(new XW(n,e))}class XW{constructor(e,t){this.compare=e,this.keySelector=t}call(e,t){return t.subscribe(new ZW(e,this.compare,this.keySelector))}}class ZW extends di{constructor(e,t,i){super(e),this.keySelector=i,this.hasKey=!1,"function"==typeof t&&(this.compare=t)}compare(e,t){return e===t}_next(e){let t;try{const{keySelector:r}=this;t=r?r(e):e}catch(r){return this.destination.error(r)}let i=!1;if(this.hasKey)try{const{compare:r}=this;i=r(this.key,t)}catch(r){return this.destination.error(r)}else this.hasKey=!0;i||(this.key=t,this.destination.next(e))}}function Tr(n){return e=>e.lift(new JW(n))}class JW{constructor(e){this.notifier=e}call(e,t){const i=new QW(e),r=$o(i,this.notifier);return r&&!i.seenValue?(i.add(r),t.subscribe(i)):i}}class QW extends Fs{constructor(e){super(e),this.seenValue=!1}notifyNext(e,t,i,r,s){this.seenValue=!0,this.complete()}notifyComplete(){}}function bi(n){return null!=n&&"false"!=`${n}`}function ih(n,e=0){return function e$(n){return!isNaN(parseFloat(n))&&!isNaN(Number(n))}(n)?Number(n):e}function Iw(n){return Array.isArray(n)?n:[n]}function Cs(n){return null==n?"":"string"==typeof n?n:`${n}px`}function Nf(n){return n instanceof _n?n.nativeElement:n}let AL=(()=>{class n{create(t){return typeof MutationObserver>"u"?null:new MutationObserver(t)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),t$=(()=>{class n{constructor(t){this._mutationObserverFactory=t,this._observedElements=new Map}ngOnDestroy(){this._observedElements.forEach((t,i)=>this._cleanupObserver(i))}observe(t){const i=Nf(t);return new un(r=>{const o=this._observeElement(i).subscribe(r);return()=>{o.unsubscribe(),this._unobserveElement(i)}})}_observeElement(t){if(this._observedElements.has(t))this._observedElements.get(t).count++;else{const i=new cn,r=this._mutationObserverFactory.create(s=>i.next(s));r&&r.observe(t,{characterData:!0,childList:!0,subtree:!0}),this._observedElements.set(t,{observer:r,stream:i,count:1})}return this._observedElements.get(t).stream}_unobserveElement(t){this._observedElements.has(t)&&(this._observedElements.get(t).count--,this._observedElements.get(t).count||this._cleanupObserver(t))}_cleanupObserver(t){if(this._observedElements.has(t)){const{observer:i,stream:r}=this._observedElements.get(t);i&&i.disconnect(),r.complete(),this._observedElements.delete(t)}}}return n.\u0275fac=function(t){return new(t||n)(xe(AL))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),IT=(()=>{class n{get disabled(){return this._disabled}set disabled(t){this._disabled=bi(t),this._disabled?this._unsubscribe():this._subscribe()}get debounce(){return this._debounce}set debounce(t){this._debounce=ih(t),this._subscribe()}constructor(t,i,r){this._contentObserver=t,this._elementRef=i,this._ngZone=r,this.event=new Pn,this._disabled=!1,this._currentSubscription=null}ngAfterContentInit(){!this._currentSubscription&&!this.disabled&&this._subscribe()}ngOnDestroy(){this._unsubscribe()}_subscribe(){this._unsubscribe();const t=this._contentObserver.observe(this._elementRef);this._ngZone.runOutsideAngular(()=>{this._currentSubscription=(this.debounce?t.pipe(zv(this.debounce)):t).subscribe(this.event)})}_unsubscribe(){this._currentSubscription?.unsubscribe()}}return n.\u0275fac=function(t){return new(t||n)(ie(t$),ie(_n),ie(Xt))},n.\u0275dir=ut({type:n,selectors:[["","cdkObserveContent",""]],inputs:{disabled:["cdkObserveContentDisabled","disabled"],debounce:"debounce"},outputs:{event:"cdkObserveContent"},exportAs:["cdkObserveContent"]}),n})(),FT=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[AL]}),n})();const kL={};function Fw(...n){let e=null,t=null;return cc(n[n.length-1])&&(t=n.pop()),"function"==typeof n[n.length-1]&&(e=n.pop()),1===n.length&&_i(n[0])&&(n=n[0]),uc(n,t).lift(new n$(e))}class n${constructor(e){this.resultSelector=e}call(e,t){return t.subscribe(new i$(e,this.resultSelector))}}class i$ extends Fs{constructor(e,t){super(e),this.resultSelector=t,this.active=0,this.values=[],this.observables=[]}_next(e){this.values.push(kL),this.observables.push(e)}_complete(){const e=this.observables,t=e.length;if(0===t)this.destination.complete();else{this.active=t,this.toRespond=t;for(let i=0;iRw(n,t,e)):t=>Rw(n,t)}const IL=new Set;let cg,s$=(()=>{class n{constructor(t){this._platform=t,this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):a$}matchMedia(t){return(this._platform.WEBKIT||this._platform.BLINK)&&function o$(n){if(!IL.has(n))try{cg||(cg=document.createElement("style"),cg.setAttribute("type","text/css"),document.head.appendChild(cg)),cg.sheet&&(cg.sheet.insertRule(`@media ${n} {body{ }}`,0),IL.add(n))}catch(e){console.error(e)}}(t),this._matchMedia(t)}}return n.\u0275fac=function(t){return new(t||n)(xe(as))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function a$(n){return{matches:"all"===n||""===n,media:n,addListener:()=>{},removeListener:()=>{}}}let FL=(()=>{class n{constructor(t,i){this._mediaMatcher=t,this._zone=i,this._queries=new Map,this._destroySubject=new cn}ngOnDestroy(){this._destroySubject.next(),this._destroySubject.complete()}isMatched(t){return RL(Iw(t)).some(r=>this._registerQuery(r).mql.matches)}observe(t){let s=Fw(RL(Iw(t)).map(o=>this._registerQuery(o).observable));return s=Rw(s.pipe(Gr(1)),s.pipe(TL(1),zv(0))),s.pipe(_t(o=>{const a={matches:!1,breakpoints:{}};return o.forEach(({matches:c,query:u})=>{a.matches=a.matches||c,a.breakpoints[u]=c}),a}))}_registerQuery(t){if(this._queries.has(t))return this._queries.get(t);const i=this._mediaMatcher.matchMedia(t),s={observable:new un(o=>{const a=c=>this._zone.run(()=>o.next(c));return i.addListener(a),()=>{i.removeListener(a)}}).pipe(Bf(i),_t(({matches:o})=>({query:t,matches:o})),Tr(this._destroySubject)),mql:i};return this._queries.set(t,s),s}}return n.\u0275fac=function(t){return new(t||n)(xe(s$),xe(Xt))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function RL(n){return n.map(e=>e.split(",")).reduce((e,t)=>e.concat(t)).map(e=>e.trim())}const lg_Medium="(min-width: 960px) and (max-width: 1279.98px)",lg_Large="(min-width: 1280px) and (max-width: 1919.98px)";function Pw(n,e){return(n.getAttribute(e)||"").match(/\S+/g)||[]}const OL="cdk-describedby-message",Ow="cdk-describedby-host";let RT=0,d$=(()=>{class n{constructor(t,i){this._platform=i,this._messageRegistry=new Map,this._messagesContainer=null,this._id=""+RT++,this._document=t,this._id=hn(Zm)+"-"+RT++}describe(t,i,r){if(!this._canBeDescribed(t,i))return;const s=PT(i,r);"string"!=typeof i?(LL(i,this._id),this._messageRegistry.set(s,{messageElement:i,referenceCount:0})):this._messageRegistry.has(s)||this._createMessageElement(i,r),this._isElementDescribedByMessage(t,s)||this._addMessageReference(t,s)}removeDescription(t,i,r){if(!i||!this._isElementNode(t))return;const s=PT(i,r);if(this._isElementDescribedByMessage(t,s)&&this._removeMessageReference(t,s),"string"==typeof i){const o=this._messageRegistry.get(s);o&&0===o.referenceCount&&this._deleteMessageElement(s)}0===this._messagesContainer?.childNodes.length&&(this._messagesContainer.remove(),this._messagesContainer=null)}ngOnDestroy(){const t=this._document.querySelectorAll(`[${Ow}="${this._id}"]`);for(let i=0;i0!=r.indexOf(OL));t.setAttribute("aria-describedby",i.join(" "))}_addMessageReference(t,i){const r=this._messageRegistry.get(i);(function c$(n,e,t){const i=Pw(n,e);i.some(r=>r.trim()==t.trim())||(i.push(t.trim()),n.setAttribute(e,i.join(" ")))})(t,"aria-describedby",r.messageElement.id),t.setAttribute(Ow,this._id),r.referenceCount++}_removeMessageReference(t,i){const r=this._messageRegistry.get(i);r.referenceCount--,function l$(n,e,t){const r=Pw(n,e).filter(s=>s!=t.trim());r.length?n.setAttribute(e,r.join(" ")):n.removeAttribute(e)}(t,"aria-describedby",r.messageElement.id),t.removeAttribute(Ow)}_isElementDescribedByMessage(t,i){const r=Pw(t,"aria-describedby"),s=this._messageRegistry.get(i),o=s&&s.messageElement.id;return!!o&&-1!=r.indexOf(o)}_canBeDescribed(t,i){if(!this._isElementNode(t))return!1;if(i&&"object"==typeof i)return!0;const r=null==i?"":`${i}`.trim(),s=t.getAttribute("aria-label");return!(!r||s&&s.trim()===r)}_isElementNode(t){return t.nodeType===this._document.ELEMENT_NODE}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn),xe(as))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function PT(n,e){return"string"==typeof n?`${e||""}/${n}`:n}function LL(n,e){n.id||(n.id=`${OL}-${e}-${RT++}`)}class NL{constructor(e){this._items=e,this._activeItemIndex=-1,this._activeItem=null,this._wrap=!1,this._letterKeyStream=new cn,this._typeaheadSubscription=Tn.EMPTY,this._vertical=!0,this._allowedModifierKeys=[],this._homeAndEnd=!1,this._pageUpAndDown={enabled:!1,delta:10},this._skipPredicateFn=t=>t.disabled,this._pressedLetters=[],this.tabOut=new cn,this.change=new cn,e instanceof xv&&(this._itemChangesSubscription=e.changes.subscribe(t=>{if(this._activeItem){const r=t.toArray().indexOf(this._activeItem);r>-1&&r!==this._activeItemIndex&&(this._activeItemIndex=r)}}))}skipPredicate(e){return this._skipPredicateFn=e,this}withWrap(e=!0){return this._wrap=e,this}withVerticalOrientation(e=!0){return this._vertical=e,this}withHorizontalOrientation(e){return this._horizontal=e,this}withAllowedModifierKeys(e){return this._allowedModifierKeys=e,this}withTypeAhead(e=200){return this._typeaheadSubscription.unsubscribe(),this._typeaheadSubscription=this._letterKeyStream.pipe(Dr(t=>this._pressedLetters.push(t)),zv(e),Ui(()=>this._pressedLetters.length>0),_t(()=>this._pressedLetters.join(""))).subscribe(t=>{const i=this._getItemsArray();for(let r=1;r!e[s]||this._allowedModifierKeys.indexOf(s)>-1);switch(t){case 9:return void this.tabOut.next();case 40:if(this._vertical&&r){this.setNextItemActive();break}return;case 38:if(this._vertical&&r){this.setPreviousItemActive();break}return;case 39:if(this._horizontal&&r){"rtl"===this._horizontal?this.setPreviousItemActive():this.setNextItemActive();break}return;case 37:if(this._horizontal&&r){"rtl"===this._horizontal?this.setNextItemActive():this.setPreviousItemActive();break}return;case 36:if(this._homeAndEnd&&r){this.setFirstItemActive();break}return;case 35:if(this._homeAndEnd&&r){this.setLastItemActive();break}return;case 33:if(this._pageUpAndDown.enabled&&r){const s=this._activeItemIndex-this._pageUpAndDown.delta;this._setActiveItemByIndex(s>0?s:0,1);break}return;case 34:if(this._pageUpAndDown.enabled&&r){const s=this._activeItemIndex+this._pageUpAndDown.delta,o=this._getItemsArray().length;this._setActiveItemByIndex(s=65&&t<=90||t>=48&&t<=57)&&this._letterKeyStream.next(String.fromCharCode(t))))}this._pressedLetters=[],e.preventDefault()}get activeItemIndex(){return this._activeItemIndex}get activeItem(){return this._activeItem}isTyping(){return this._pressedLetters.length>0}setFirstItemActive(){this._setActiveItemByIndex(0,1)}setLastItemActive(){this._setActiveItemByIndex(this._items.length-1,-1)}setNextItemActive(){this._activeItemIndex<0?this.setFirstItemActive():this._setActiveItemByDelta(1)}setPreviousItemActive(){this._activeItemIndex<0&&this._wrap?this.setLastItemActive():this._setActiveItemByDelta(-1)}updateActiveItem(e){const t=this._getItemsArray(),i="number"==typeof e?e:t.indexOf(e);this._activeItem=t[i]??null,this._activeItemIndex=i}destroy(){this._typeaheadSubscription.unsubscribe(),this._itemChangesSubscription?.unsubscribe(),this._letterKeyStream.complete(),this.tabOut.complete(),this.change.complete(),this._pressedLetters=[]}_setActiveItemByDelta(e){this._wrap?this._setActiveInWrapMode(e):this._setActiveInDefaultMode(e)}_setActiveInWrapMode(e){const t=this._getItemsArray();for(let i=1;i<=t.length;i++){const r=(this._activeItemIndex+e*i+t.length)%t.length;if(!this._skipPredicateFn(t[r]))return void this.setActiveItem(r)}}_setActiveInDefaultMode(e){this._setActiveItemByIndex(this._activeItemIndex+e,e)}_setActiveItemByIndex(e,t){const i=this._getItemsArray();if(i[e]){for(;this._skipPredicateFn(i[e]);)if(!i[e+=t])return;this.setActiveItem(e)}}_getItemsArray(){return this._items instanceof xv?this._items.toArray():this._items}}class u$ extends NL{setActiveItem(e){this.activeItem&&this.activeItem.setInactiveStyles(),super.setActiveItem(e),this.activeItem&&this.activeItem.setActiveStyles()}}let Gv=(()=>{class n{constructor(t){this._platform=t}isDisabled(t){return t.hasAttribute("disabled")}isVisible(t){return function p$(n){return!!(n.offsetWidth||n.offsetHeight||"function"==typeof n.getClientRects&&n.getClientRects().length)}(t)&&"visible"===getComputedStyle(t).visibility}isTabbable(t){if(!this._platform.isBrowser)return!1;const i=function f$(n){try{return n.frameElement}catch{return null}}(function w$(n){return n.ownerDocument&&n.ownerDocument.defaultView||window}(t));if(i&&(-1===VL(i)||!this.isVisible(i)))return!1;let r=t.nodeName.toLowerCase(),s=VL(t);return t.hasAttribute("contenteditable")?-1!==s:!("iframe"===r||"object"===r||this._platform.WEBKIT&&this._platform.IOS&&!function b$(n){let e=n.nodeName.toLowerCase(),t="input"===e&&n.type;return"text"===t||"password"===t||"select"===e||"textarea"===e}(t))&&("audio"===r?!!t.hasAttribute("controls")&&-1!==s:"video"===r?-1!==s&&(null!==s||this._platform.FIREFOX||t.hasAttribute("controls")):t.tabIndex>=0)}isFocusable(t,i){return function x$(n){return!function g$(n){return function v$(n){return"input"==n.nodeName.toLowerCase()}(n)&&"hidden"==n.type}(n)&&(function m$(n){let e=n.nodeName.toLowerCase();return"input"===e||"select"===e||"button"===e||"textarea"===e}(n)||function _$(n){return function y$(n){return"a"==n.nodeName.toLowerCase()}(n)&&n.hasAttribute("href")}(n)||n.hasAttribute("contenteditable")||BL(n))}(t)&&!this.isDisabled(t)&&(i?.ignoreVisibility||this.isVisible(t))}}return n.\u0275fac=function(t){return new(t||n)(xe(as))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function BL(n){if(!n.hasAttribute("tabindex")||void 0===n.tabIndex)return!1;let e=n.getAttribute("tabindex");return!(!e||isNaN(parseInt(e,10)))}function VL(n){if(!BL(n))return null;const e=parseInt(n.getAttribute("tabindex")||"",10);return isNaN(e)?-1:e}class S${get enabled(){return this._enabled}set enabled(e){this._enabled=e,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(e,this._startAnchor),this._toggleAnchorTabIndex(e,this._endAnchor))}constructor(e,t,i,r,s=!1){this._element=e,this._checker=t,this._ngZone=i,this._document=r,this._hasAttached=!1,this.startAnchorListener=()=>this.focusLastTabbableElement(),this.endAnchorListener=()=>this.focusFirstTabbableElement(),this._enabled=!0,s||this.attachAnchors()}destroy(){const e=this._startAnchor,t=this._endAnchor;e&&(e.removeEventListener("focus",this.startAnchorListener),e.remove()),t&&(t.removeEventListener("focus",this.endAnchorListener),t.remove()),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}attachAnchors(){return!!this._hasAttached||(this._ngZone.runOutsideAngular(()=>{this._startAnchor||(this._startAnchor=this._createAnchor(),this._startAnchor.addEventListener("focus",this.startAnchorListener)),this._endAnchor||(this._endAnchor=this._createAnchor(),this._endAnchor.addEventListener("focus",this.endAnchorListener))}),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}focusInitialElementWhenReady(e){return new Promise(t=>{this._executeOnStable(()=>t(this.focusInitialElement(e)))})}focusFirstTabbableElementWhenReady(e){return new Promise(t=>{this._executeOnStable(()=>t(this.focusFirstTabbableElement(e)))})}focusLastTabbableElementWhenReady(e){return new Promise(t=>{this._executeOnStable(()=>t(this.focusLastTabbableElement(e)))})}_getRegionBoundary(e){const t=this._element.querySelectorAll(`[cdk-focus-region-${e}], [cdkFocusRegion${e}], [cdk-focus-${e}]`);return"start"==e?t.length?t[0]:this._getFirstTabbableElement(this._element):t.length?t[t.length-1]:this._getLastTabbableElement(this._element)}focusInitialElement(e){const t=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");if(t){if(!this._checker.isFocusable(t)){const i=this._getFirstTabbableElement(t);return i?.focus(e),!!i}return t.focus(e),!0}return this.focusFirstTabbableElement(e)}focusFirstTabbableElement(e){const t=this._getRegionBoundary("start");return t&&t.focus(e),!!t}focusLastTabbableElement(e){const t=this._getRegionBoundary("end");return t&&t.focus(e),!!t}hasAttached(){return this._hasAttached}_getFirstTabbableElement(e){if(this._checker.isFocusable(e)&&this._checker.isTabbable(e))return e;const t=e.children;for(let i=0;i=0;i--){const r=t[i].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(t[i]):null;if(r)return r}return null}_createAnchor(){const e=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,e),e.classList.add("cdk-visually-hidden"),e.classList.add("cdk-focus-trap-anchor"),e.setAttribute("aria-hidden","true"),e}_toggleAnchorTabIndex(e,t){e?t.setAttribute("tabindex","0"):t.removeAttribute("tabindex")}toggleAnchors(e){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(e,this._startAnchor),this._toggleAnchorTabIndex(e,this._endAnchor))}_executeOnStable(e){this._ngZone.isStable?e():this._ngZone.onStable.pipe(Gr(1)).subscribe(e)}}let Lw=(()=>{class n{constructor(t,i,r){this._checker=t,this._ngZone=i,this._document=r}create(t,i=!1){return new S$(t,this._checker,this._ngZone,this._document,i)}}return n.\u0275fac=function(t){return new(t||n)(xe(Gv),xe(Xt),xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function HL(n){return 0===n.buttons||0===n.offsetX&&0===n.offsetY}function UL(n){const e=n.touches&&n.touches[0]||n.changedTouches&&n.changedTouches[0];return!(!e||-1!==e.identifier||null!=e.radiusX&&1!==e.radiusX||null!=e.radiusY&&1!==e.radiusY)}const E$=new Ze("cdk-input-modality-detector-options"),M$={ignoreKeys:[18,17,224,91,16]},dg=Vv({passive:!0,capture:!0});let C$=(()=>{class n{get mostRecentModality(){return this._modality.value}constructor(t,i,r,s){this._platform=t,this._mostRecentTarget=null,this._modality=new er(null),this._lastTouchMs=0,this._onKeydown=o=>{this._options?.ignoreKeys?.some(a=>a===o.keyCode)||(this._modality.next("keyboard"),this._mostRecentTarget=th(o))},this._onMousedown=o=>{Date.now()-this._lastTouchMs<650||(this._modality.next(HL(o)?"keyboard":"mouse"),this._mostRecentTarget=th(o))},this._onTouchstart=o=>{UL(o)?this._modality.next("keyboard"):(this._lastTouchMs=Date.now(),this._modality.next("touch"),this._mostRecentTarget=th(o))},this._options={...M$,...s},this.modalityDetected=this._modality.pipe(TL(1)),this.modalityChanged=this.modalityDetected.pipe(Rc()),t.isBrowser&&i.runOutsideAngular(()=>{r.addEventListener("keydown",this._onKeydown,dg),r.addEventListener("mousedown",this._onMousedown,dg),r.addEventListener("touchstart",this._onTouchstart,dg)})}ngOnDestroy(){this._modality.complete(),this._platform.isBrowser&&(document.removeEventListener("keydown",this._onKeydown,dg),document.removeEventListener("mousedown",this._onMousedown,dg),document.removeEventListener("touchstart",this._onTouchstart,dg))}}return n.\u0275fac=function(t){return new(t||n)(xe(as),xe(Xt),xe(Mn),xe(E$,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const D$=new Ze("liveAnnouncerElement",{providedIn:"root",factory:function T$(){return null}}),A$=new Ze("LIVE_ANNOUNCER_DEFAULT_OPTIONS");let k$=0,I$=(()=>{class n{constructor(t,i,r,s){this._ngZone=i,this._defaultOptions=s,this._document=r,this._liveElement=t||this._createLiveElement()}announce(t,...i){const r=this._defaultOptions;let s,o;return 1===i.length&&"number"==typeof i[0]?o=i[0]:[s,o]=i,this.clear(),clearTimeout(this._previousTimeout),s||(s=r&&r.politeness?r.politeness:"polite"),null==o&&r&&(o=r.duration),this._liveElement.setAttribute("aria-live",s),this._liveElement.id&&this._exposeAnnouncerToModals(this._liveElement.id),this._ngZone.runOutsideAngular(()=>(this._currentPromise||(this._currentPromise=new Promise(a=>this._currentResolve=a)),clearTimeout(this._previousTimeout),this._previousTimeout=setTimeout(()=>{this._liveElement.textContent=t,"number"==typeof o&&(this._previousTimeout=setTimeout(()=>this.clear(),o)),this._currentResolve(),this._currentPromise=this._currentResolve=void 0},100),this._currentPromise))}clear(){this._liveElement&&(this._liveElement.textContent="")}ngOnDestroy(){clearTimeout(this._previousTimeout),this._liveElement?.remove(),this._liveElement=null,this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0}_createLiveElement(){const t="cdk-live-announcer-element",i=this._document.getElementsByClassName(t),r=this._document.createElement("div");for(let s=0;s .cdk-overlay-container [aria-modal="true"]');for(let r=0;r{class n{constructor(t,i,r,s,o){this._ngZone=t,this._platform=i,this._inputModalityDetector=r,this._origin=null,this._windowFocused=!1,this._originFromTouchInteraction=!1,this._elementInfo=new Map,this._monitoredElementCount=0,this._rootNodeFocusListenerCount=new Map,this._windowFocusListener=()=>{this._windowFocused=!0,this._windowFocusTimeoutId=window.setTimeout(()=>this._windowFocused=!1)},this._stopInputModalityDetector=new cn,this._rootNodeFocusAndBlurListener=a=>{for(let u=th(a);u;u=u.parentElement)"focus"===a.type?this._onFocus(a,u):this._onBlur(a,u)},this._document=s,this._detectionMode=o?.detectionMode||0}monitor(t,i=!1){const r=Nf(t);if(!this._platform.isBrowser||1!==r.nodeType)return Tt(null);const s=function MW(n){if(function EW(){if(null==MT){const n=typeof document<"u"?document.head:null;MT=!(!n||!n.createShadowRoot&&!n.attachShadow)}return MT}()){const e=n.getRootNode?n.getRootNode():null;if(typeof ShadowRoot<"u"&&ShadowRoot&&e instanceof ShadowRoot)return e}return null}(r)||this._getDocument(),o=this._elementInfo.get(r);if(o)return i&&(o.checkChildren=!0),o.subject;const a={checkChildren:i,subject:new cn,rootNode:s};return this._elementInfo.set(r,a),this._registerGlobalListeners(a),a.subject}stopMonitoring(t){const i=Nf(t),r=this._elementInfo.get(i);r&&(r.subject.complete(),this._setClasses(i),this._elementInfo.delete(i),this._removeGlobalListeners(r))}focusVia(t,i,r){const s=Nf(t);s===this._getDocument().activeElement?this._getClosestElementsInfo(s).forEach(([a,c])=>this._originChanged(a,i,c)):(this._setOrigin(i),"function"==typeof s.focus&&s.focus(r))}ngOnDestroy(){this._elementInfo.forEach((t,i)=>this.stopMonitoring(i))}_getDocument(){return this._document||document}_getWindow(){return this._getDocument().defaultView||window}_getFocusOrigin(t){return this._origin?this._originFromTouchInteraction?this._shouldBeAttributedToTouch(t)?"touch":"program":this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:t&&this._isLastInteractionFromInputLabel(t)?"mouse":"program"}_shouldBeAttributedToTouch(t){return 1===this._detectionMode||!!t?.contains(this._inputModalityDetector._mostRecentTarget)}_setClasses(t,i){t.classList.toggle("cdk-focused",!!i),t.classList.toggle("cdk-touch-focused","touch"===i),t.classList.toggle("cdk-keyboard-focused","keyboard"===i),t.classList.toggle("cdk-mouse-focused","mouse"===i),t.classList.toggle("cdk-program-focused","program"===i)}_setOrigin(t,i=!1){this._ngZone.runOutsideAngular(()=>{this._origin=t,this._originFromTouchInteraction="touch"===t&&i,0===this._detectionMode&&(clearTimeout(this._originTimeoutId),this._originTimeoutId=setTimeout(()=>this._origin=null,this._originFromTouchInteraction?650:1))})}_onFocus(t,i){const r=this._elementInfo.get(i),s=th(t);!r||!r.checkChildren&&i!==s||this._originChanged(i,this._getFocusOrigin(s),r)}_onBlur(t,i){const r=this._elementInfo.get(i);!r||r.checkChildren&&t.relatedTarget instanceof Node&&i.contains(t.relatedTarget)||(this._setClasses(i),this._emitOrigin(r,null))}_emitOrigin(t,i){t.subject.observers.length&&this._ngZone.run(()=>t.subject.next(i))}_registerGlobalListeners(t){if(!this._platform.isBrowser)return;const i=t.rootNode,r=this._rootNodeFocusListenerCount.get(i)||0;r||this._ngZone.runOutsideAngular(()=>{i.addEventListener("focus",this._rootNodeFocusAndBlurListener,Nw),i.addEventListener("blur",this._rootNodeFocusAndBlurListener,Nw)}),this._rootNodeFocusListenerCount.set(i,r+1),1==++this._monitoredElementCount&&(this._ngZone.runOutsideAngular(()=>{this._getWindow().addEventListener("focus",this._windowFocusListener)}),this._inputModalityDetector.modalityDetected.pipe(Tr(this._stopInputModalityDetector)).subscribe(s=>{this._setOrigin(s,!0)}))}_removeGlobalListeners(t){const i=t.rootNode;if(this._rootNodeFocusListenerCount.has(i)){const r=this._rootNodeFocusListenerCount.get(i);r>1?this._rootNodeFocusListenerCount.set(i,r-1):(i.removeEventListener("focus",this._rootNodeFocusAndBlurListener,Nw),i.removeEventListener("blur",this._rootNodeFocusAndBlurListener,Nw),this._rootNodeFocusListenerCount.delete(i))}--this._monitoredElementCount||(this._getWindow().removeEventListener("focus",this._windowFocusListener),this._stopInputModalityDetector.next(),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._originTimeoutId))}_originChanged(t,i,r){this._setClasses(t,i),this._emitOrigin(r,i),this._lastFocusOrigin=i}_getClosestElementsInfo(t){const i=[];return this._elementInfo.forEach((r,s)=>{(s===t||r.checkChildren&&s.contains(t))&&i.push([s,r])}),i}_isLastInteractionFromInputLabel(t){const{_mostRecentTarget:i,mostRecentModality:r}=this._inputModalityDetector;if("mouse"!==r||!i||i===t||"INPUT"!==t.nodeName&&"TEXTAREA"!==t.nodeName||t.disabled)return!1;const s=t.labels;if(s)for(let o=0;o{class n{constructor(t,i){this._platform=t,this._document=i,this._breakpointSubscription=hn(FL).observe("(forced-colors: active)").subscribe(()=>{this._hasCheckedHighContrastMode&&(this._hasCheckedHighContrastMode=!1,this._applyBodyHighContrastModeCssClasses())})}getHighContrastMode(){if(!this._platform.isBrowser)return 0;const t=this._document.createElement("div");t.style.backgroundColor="rgb(1,2,3)",t.style.position="absolute",this._document.body.appendChild(t);const i=this._document.defaultView||window,r=i&&i.getComputedStyle?i.getComputedStyle(t):null,s=(r&&r.backgroundColor||"").replace(/ /g,"");switch(t.remove(),s){case"rgb(0,0,0)":case"rgb(45,50,54)":case"rgb(32,32,32)":return 2;case"rgb(255,255,255)":case"rgb(255,250,239)":return 1}return 0}ngOnDestroy(){this._breakpointSubscription.unsubscribe()}_applyBodyHighContrastModeCssClasses(){if(!this._hasCheckedHighContrastMode&&this._platform.isBrowser&&this._document.body){const t=this._document.body.classList;t.remove(OT,GL,jL),this._hasCheckedHighContrastMode=!0;const i=this.getHighContrastMode();1===i?t.add(OT,GL):2===i&&t.add(OT,jL)}}}return n.\u0275fac=function(t){return new(t||n)(xe(as),xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),$L=(()=>{class n{constructor(t){t._applyBodyHighContrastModeCssClasses()}}return n.\u0275fac=function(t){return new(t||n)(xe(WL))},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[FT]}),n})();const R$=new Ze("cdk-dir-doc",{providedIn:"root",factory:function P$(){return hn(Mn)}}),O$=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;let Yl=(()=>{class n{constructor(t){this.value="ltr",this.change=new Pn,t&&(this.value=function L$(n){const e=n?.toLowerCase()||"";return"auto"===e&&typeof navigator<"u"&&navigator?.language?O$.test(navigator.language)?"rtl":"ltr":"rtl"===e?"rtl":"ltr"}((t.body?t.body.dir:null)||(t.documentElement?t.documentElement.dir:null)||"ltr"))}ngOnDestroy(){this.change.complete()}}return n.\u0275fac=function(t){return new(t||n)(xe(R$,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),jv=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})();const N$=["text"];function B$(n,e){if(1&n&&qt(0,"mat-pseudo-checkbox",6),2&n){const t=Jt();$e("state",t.selected?"checked":"unchecked")("disabled",t.disabled)}}function V$(n,e){1&n&&qt(0,"mat-pseudo-checkbox",7),2&n&&$e("disabled",Jt().disabled)}function H$(n,e){if(1&n&&(ke(0,"span",8),it(1),Ne()),2&n){const t=Jt();Le(1),xs("(",t.group.label,")")}}const U$=[[["mat-icon"]],"*"],z$=["mat-icon","*"];let YL=(()=>{class n{}return n.STANDARD_CURVE="cubic-bezier(0.4,0.0,0.2,1)",n.DECELERATION_CURVE="cubic-bezier(0.0,0.0,0.2,1)",n.ACCELERATION_CURVE="cubic-bezier(0.4,0.0,1,1)",n.SHARP_CURVE="cubic-bezier(0.4,0.0,0.6,1)",n})(),XL=(()=>{class n{}return n.COMPLEX="375ms",n.ENTERING="225ms",n.EXITING="195ms",n})();const j$=new Ze("mat-sanity-checks",{providedIn:"root",factory:function G$(){return!0}});let rr=(()=>{class n{constructor(t,i,r){this._sanityChecks=i,this._document=r,this._hasDoneGlobalChecks=!1,t._applyBodyHighContrastModeCssClasses(),this._hasDoneGlobalChecks||(this._hasDoneGlobalChecks=!0)}_checkIsEnabled(t){return!CT()&&("boolean"==typeof this._sanityChecks?this._sanityChecks:!!this._sanityChecks[t])}}return n.\u0275fac=function(t){return new(t||n)(xe(WL),xe(j$,8),xe(Mn))},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[jv,jv]}),n})();function LT(n){return class extends n{get disabled(){return this._disabled}set disabled(e){this._disabled=bi(e)}constructor(...e){super(...e),this._disabled=!1}}}function NT(n,e){return class extends n{get color(){return this._color}set color(t){const i=t||this.defaultColor;i!==this._color&&(this._color&&this._elementRef.nativeElement.classList.remove(`mat-${this._color}`),i&&this._elementRef.nativeElement.classList.add(`mat-${i}`),this._color=i)}constructor(...t){super(...t),this.defaultColor=e,this.color=e}}}function Bw(n){return class extends n{get disableRipple(){return this._disableRipple}set disableRipple(e){this._disableRipple=bi(e)}constructor(...e){super(...e),this._disableRipple=!1}}}function ZL(n,e=0){return class extends n{get tabIndex(){return this.disabled?-1:this._tabIndex}set tabIndex(t){this._tabIndex=null!=t?ih(t):this.defaultTabIndex}constructor(...t){super(...t),this._tabIndex=e,this.defaultTabIndex=e}}}function W$(n){return class extends n{updateErrorState(){const e=this.errorState,s=(this.errorStateMatcher||this._defaultErrorStateMatcher).isErrorState(this.ngControl?this.ngControl.control:null,this._parentFormGroup||this._parentForm);s!==e&&(this.errorState=s,this.stateChanges.next())}constructor(...e){super(...e),this.errorState=!1}}}let q$=(()=>{class n{isErrorState(t,i){return!!(t&&t.invalid&&(t.touched||i&&i.submitted))}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();class K${constructor(e,t,i,r=!1){this._renderer=e,this.element=t,this.config=i,this._animationForciblyDisabledThroughCss=r,this.state=3}fadeOut(){this._renderer.fadeOutRipple(this)}}const JL=Vv({passive:!0,capture:!0});class Y${constructor(){this._events=new Map,this._delegateEventHandler=e=>{const t=th(e);t&&this._events.get(e.type)?.forEach((i,r)=>{(r===t||r.contains(t))&&i.forEach(s=>s.handleEvent(e))})}}addHandler(e,t,i,r){const s=this._events.get(t);if(s){const o=s.get(i);o?o.add(r):s.set(i,new Set([r]))}else this._events.set(t,new Map([[i,new Set([r])]])),e.runOutsideAngular(()=>{document.addEventListener(t,this._delegateEventHandler,JL)})}removeHandler(e,t,i){const r=this._events.get(e);if(!r)return;const s=r.get(t);s&&(s.delete(i),0===s.size&&r.delete(t),0===r.size&&(this._events.delete(e),document.removeEventListener(e,this._delegateEventHandler,JL)))}}const QL={enterDuration:225,exitDuration:150},eN=Vv({passive:!0,capture:!0}),tN=["mousedown","touchstart"],nN=["mouseup","mouseleave","touchend","touchcancel"];class ug{constructor(e,t,i,r){this._target=e,this._ngZone=t,this._platform=r,this._isPointerDown=!1,this._activeRipples=new Map,this._pointerUpEventsRegistered=!1,r.isBrowser&&(this._containerElement=Nf(i))}fadeInRipple(e,t,i={}){const r=this._containerRect=this._containerRect||this._containerElement.getBoundingClientRect(),s={...QL,...i.animation};i.centered&&(e=r.left+r.width/2,t=r.top+r.height/2);const o=i.radius||function Z$(n,e,t){const i=Math.max(Math.abs(n-t.left),Math.abs(n-t.right)),r=Math.max(Math.abs(e-t.top),Math.abs(e-t.bottom));return Math.sqrt(i*i+r*r)}(e,t,r),a=e-r.left,c=t-r.top,u=s.enterDuration,p=document.createElement("div");p.classList.add("mat-ripple-element"),p.style.left=a-o+"px",p.style.top=c-o+"px",p.style.height=2*o+"px",p.style.width=2*o+"px",null!=i.color&&(p.style.backgroundColor=i.color),p.style.transitionDuration=`${u}ms`,this._containerElement.appendChild(p);const g=window.getComputedStyle(p),y=g.transitionDuration,x="none"===g.transitionProperty||"0s"===y||"0s, 0s"===y||0===r.width&&0===r.height,T=new K$(this,p,i,x);p.style.transform="scale3d(1, 1, 1)",T.state=0,i.persistent||(this._mostRecentTransientRipple=T);let N=null;return!x&&(u||s.exitDuration)&&this._ngZone.runOutsideAngular(()=>{const k=()=>this._finishRippleTransition(T),A=()=>this._destroyRipple(T);p.addEventListener("transitionend",k),p.addEventListener("transitioncancel",A),N={onTransitionEnd:k,onTransitionCancel:A}}),this._activeRipples.set(T,N),(x||!u)&&this._finishRippleTransition(T),T}fadeOutRipple(e){if(2===e.state||3===e.state)return;const t=e.element,i={...QL,...e.config.animation};t.style.transitionDuration=`${i.exitDuration}ms`,t.style.opacity="0",e.state=2,(e._animationForciblyDisabledThroughCss||!i.exitDuration)&&this._finishRippleTransition(e)}fadeOutAll(){this._getActiveRipples().forEach(e=>e.fadeOut())}fadeOutAllNonPersistent(){this._getActiveRipples().forEach(e=>{e.config.persistent||e.fadeOut()})}setupTriggerEvents(e){const t=Nf(e);!this._platform.isBrowser||!t||t===this._triggerElement||(this._removeTriggerEvents(),this._triggerElement=t,tN.forEach(i=>{ug._eventManager.addHandler(this._ngZone,i,t,this)}))}handleEvent(e){"mousedown"===e.type?this._onMousedown(e):"touchstart"===e.type?this._onTouchStart(e):this._onPointerUp(),this._pointerUpEventsRegistered||(this._ngZone.runOutsideAngular(()=>{nN.forEach(t=>{this._triggerElement.addEventListener(t,this,eN)})}),this._pointerUpEventsRegistered=!0)}_finishRippleTransition(e){0===e.state?this._startFadeOutTransition(e):2===e.state&&this._destroyRipple(e)}_startFadeOutTransition(e){const t=e===this._mostRecentTransientRipple,{persistent:i}=e.config;e.state=1,!i&&(!t||!this._isPointerDown)&&e.fadeOut()}_destroyRipple(e){const t=this._activeRipples.get(e)??null;this._activeRipples.delete(e),this._activeRipples.size||(this._containerRect=null),e===this._mostRecentTransientRipple&&(this._mostRecentTransientRipple=null),e.state=3,null!==t&&(e.element.removeEventListener("transitionend",t.onTransitionEnd),e.element.removeEventListener("transitioncancel",t.onTransitionCancel)),e.element.remove()}_onMousedown(e){const t=HL(e),i=this._lastTouchStartEvent&&Date.now(){!e.config.persistent&&(1===e.state||e.config.terminateOnPointerUp&&0===e.state)&&e.fadeOut()}))}_getActiveRipples(){return Array.from(this._activeRipples.keys())}_removeTriggerEvents(){const e=this._triggerElement;e&&(tN.forEach(t=>ug._eventManager.removeHandler(t,e,this)),this._pointerUpEventsRegistered&&nN.forEach(t=>e.removeEventListener(t,this,eN)))}}ug._eventManager=new Y$;const Vw=new Ze("mat-ripple-global-options");let rh=(()=>{class n{get disabled(){return this._disabled}set disabled(t){t&&this.fadeOutAllNonPersistent(),this._disabled=t,this._setupTriggerEventsIfEnabled()}get trigger(){return this._trigger||this._elementRef.nativeElement}set trigger(t){this._trigger=t,this._setupTriggerEventsIfEnabled()}constructor(t,i,r,s,o){this._elementRef=t,this._animationMode=o,this.radius=0,this._disabled=!1,this._isInitialized=!1,this._globalOptions=s||{},this._rippleRenderer=new ug(this,i,t,r)}ngOnInit(){this._isInitialized=!0,this._setupTriggerEventsIfEnabled()}ngOnDestroy(){this._rippleRenderer._removeTriggerEvents()}fadeOutAll(){this._rippleRenderer.fadeOutAll()}fadeOutAllNonPersistent(){this._rippleRenderer.fadeOutAllNonPersistent()}get rippleConfig(){return{centered:this.centered,radius:this.radius,color:this.color,animation:{...this._globalOptions.animation,..."NoopAnimations"===this._animationMode?{enterDuration:0,exitDuration:0}:{},...this.animation},terminateOnPointerUp:this._globalOptions.terminateOnPointerUp}}get rippleDisabled(){return this.disabled||!!this._globalOptions.disabled}_setupTriggerEventsIfEnabled(){!this.disabled&&this._isInitialized&&this._rippleRenderer.setupTriggerEvents(this.trigger)}launch(t,i=0,r){return"number"==typeof t?this._rippleRenderer.fadeInRipple(t,i,{...this.rippleConfig,...r}):this._rippleRenderer.fadeInRipple(0,0,{...this.rippleConfig,...t})}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Xt),ie(as),ie(Vw,8),ie(bo,8))},n.\u0275dir=ut({type:n,selectors:[["","mat-ripple",""],["","matRipple",""]],hostAttrs:[1,"mat-ripple"],hostVars:2,hostBindings:function(t,i){2&t&&hi("mat-ripple-unbounded",i.unbounded)},inputs:{color:["matRippleColor","color"],unbounded:["matRippleUnbounded","unbounded"],centered:["matRippleCentered","centered"],radius:["matRippleRadius","radius"],animation:["matRippleAnimation","animation"],disabled:["matRippleDisabled","disabled"],trigger:["matRippleTrigger","trigger"]},exportAs:["matRipple"]}),n})(),$v=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,rr]}),n})(),J$=(()=>{class n{constructor(t){this._animationMode=t,this.state="unchecked",this.disabled=!1,this.appearance="full"}}return n.\u0275fac=function(t){return new(t||n)(ie(bo,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-pseudo-checkbox"]],hostAttrs:[1,"mat-pseudo-checkbox"],hostVars:12,hostBindings:function(t,i){2&t&&hi("mat-pseudo-checkbox-indeterminate","indeterminate"===i.state)("mat-pseudo-checkbox-checked","checked"===i.state)("mat-pseudo-checkbox-disabled",i.disabled)("mat-pseudo-checkbox-minimal","minimal"===i.appearance)("mat-pseudo-checkbox-full","full"===i.appearance)("_mat-animation-noopable","NoopAnimations"===i._animationMode)},inputs:{state:"state",disabled:"disabled",appearance:"appearance"},decls:0,vars:0,template:function(t,i){},styles:['.mat-pseudo-checkbox{border-radius:2px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1),background-color 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox::after{position:absolute;opacity:0;content:"";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox._mat-animation-noopable{transition:none !important;animation:none !important}.mat-pseudo-checkbox._mat-animation-noopable::after{transition:none}.mat-pseudo-checkbox-disabled{cursor:default}.mat-pseudo-checkbox-indeterminate::after{left:1px;opacity:1;border-radius:2px}.mat-pseudo-checkbox-checked::after{left:1px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box}.mat-pseudo-checkbox-full{border:2px solid}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked,.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate{border-color:rgba(0,0,0,0)}.mat-pseudo-checkbox{width:18px;height:18px}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-checked::after{width:14px;height:6px;transform-origin:center;top:-4.2426406871px;left:0;bottom:0;right:0;margin:auto}.mat-pseudo-checkbox-minimal.mat-pseudo-checkbox-indeterminate::after{top:8px;width:16px}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-checked::after{width:10px;height:4px;transform-origin:center;top:-2.8284271247px;left:0;bottom:0;right:0;margin:auto}.mat-pseudo-checkbox-full.mat-pseudo-checkbox-indeterminate::after{top:6px;width:12px}'],encapsulation:2,changeDetection:0}),n})(),iN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr]}),n})();const rN=new Ze("MAT_OPTION_PARENT_COMPONENT"),sN=new Ze("MatOptgroup");let Q$=0;class eq{constructor(e,t=!1){this.source=e,this.isUserInput=t}}let tq=(()=>{class n{get multiple(){return this._parent&&this._parent.multiple}get selected(){return this._selected}get disabled(){return this.group&&this.group.disabled||this._disabled}set disabled(t){this._disabled=bi(t)}get disableRipple(){return!(!this._parent||!this._parent.disableRipple)}get hideSingleSelectionIndicator(){return!(!this._parent||!this._parent.hideSingleSelectionIndicator)}constructor(t,i,r,s){this._element=t,this._changeDetectorRef=i,this._parent=r,this.group=s,this._selected=!1,this._active=!1,this._disabled=!1,this._mostRecentViewValue="",this.id="mat-option-"+Q$++,this.onSelectionChange=new Pn,this._stateChanges=new cn}get active(){return this._active}get viewValue(){return(this._text?.nativeElement.textContent||"").trim()}select(){this._selected||(this._selected=!0,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent())}deselect(){this._selected&&(this._selected=!1,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent())}focus(t,i){const r=this._getHostElement();"function"==typeof r.focus&&r.focus(i)}setActiveStyles(){this._active||(this._active=!0,this._changeDetectorRef.markForCheck())}setInactiveStyles(){this._active&&(this._active=!1,this._changeDetectorRef.markForCheck())}getLabel(){return this.viewValue}_handleKeydown(t){(13===t.keyCode||32===t.keyCode)&&!ql(t)&&(this._selectViaInteraction(),t.preventDefault())}_selectViaInteraction(){this.disabled||(this._selected=!this.multiple||!this._selected,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent(!0))}_getAriaSelected(){return this.selected||!this.multiple&&null}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._element.nativeElement}ngAfterViewChecked(){if(this._selected){const t=this.viewValue;t!==this._mostRecentViewValue&&(this._mostRecentViewValue&&this._stateChanges.next(),this._mostRecentViewValue=t)}}ngOnDestroy(){this._stateChanges.complete()}_emitSelectionChangeEvent(t=!1){this.onSelectionChange.emit(new eq(this,t))}}return n.\u0275fac=function(t){Gl()},n.\u0275dir=ut({type:n,viewQuery:function(t,i){if(1&t&&zr(N$,7),2&t){let r;Yn(r=Xn())&&(i._text=r.first)}},inputs:{value:"value",id:"id",disabled:"disabled"},outputs:{onSelectionChange:"onSelectionChange"}}),n})(),BT=(()=>{class n extends tq{constructor(t,i,r,s){super(t,i,r,s)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(aa),ie(rN,8),ie(sN,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-option"]],hostAttrs:["role","option",1,"mat-mdc-option","mat-mdc-focus-indicator","mdc-list-item"],hostVars:12,hostBindings:function(t,i){1&t&&Gn("click",function(){return i._selectViaInteraction()})("keydown",function(s){return i._handleKeydown(s)}),2&t&&(Af("id",i.id),Di("tabindex",i._getTabIndex())("aria-selected",i._getAriaSelected())("aria-disabled",i.disabled.toString()),hi("mdc-list-item--selected",i.selected)("mat-mdc-option-multiple",i.multiple)("mat-mdc-option-active",i.active)("mdc-list-item--disabled",i.disabled))},exportAs:["matOption"],features:[Z],ngContentSelectors:z$,decls:8,vars:5,consts:[["class","mat-mdc-option-pseudo-checkbox",3,"state","disabled",4,"ngIf"],[1,"mdc-list-item__primary-text"],["text",""],["class","mat-mdc-option-pseudo-checkbox","state","checked","appearance","minimal",3,"disabled",4,"ngIf"],["class","cdk-visually-hidden",4,"ngIf"],["mat-ripple","",1,"mat-mdc-option-ripple",3,"matRippleTrigger","matRippleDisabled"],[1,"mat-mdc-option-pseudo-checkbox",3,"state","disabled"],["state","checked","appearance","minimal",1,"mat-mdc-option-pseudo-checkbox",3,"disabled"],[1,"cdk-visually-hidden"]],template:function(t,i){1&t&&(Hs(U$),mt(0,B$,1,2,"mat-pseudo-checkbox",0),En(1),ke(2,"span",1,2),En(4,1),Ne(),mt(5,V$,1,1,"mat-pseudo-checkbox",3),mt(6,H$,2,1,"span",4),qt(7,"div",5)),2&t&&($e("ngIf",i.multiple),Le(5),$e("ngIf",!i.multiple&&i.selected&&!i.hideSingleSelectionIndicator),Le(1),$e("ngIf",i.group&&i.group._inert),Le(1),$e("matRippleTrigger",i._getHostElement())("matRippleDisabled",i.disabled||i.disableRipple))},dependencies:[rh,Yu,J$],styles:['.mat-mdc-option{display:flex;position:relative;align-items:center;justify-content:flex-start;overflow:hidden;padding:0;padding-left:16px;padding-right:16px;-webkit-user-select:none;user-select:none;cursor:pointer;-webkit-tap-highlight-color:rgba(0,0,0,0);min-height:48px}.mat-mdc-option:focus{outline:none}[dir=rtl] .mat-mdc-option,.mat-mdc-option[dir=rtl]{padding-left:16px;padding-right:16px}.mat-mdc-option.mdc-list-item{align-items:center}.mat-mdc-option.mdc-list-item--disabled{opacity:.38;cursor:default}.mat-mdc-optgroup .mat-mdc-option:not(.mat-mdc-option-multiple){padding-left:32px}[dir=rtl] .mat-mdc-optgroup .mat-mdc-option:not(.mat-mdc-option-multiple){padding-left:16px;padding-right:32px}.mat-mdc-option .mat-icon,.mat-mdc-option .mat-pseudo-checkbox-full{margin-right:16px;flex-shrink:0}[dir=rtl] .mat-mdc-option .mat-icon,[dir=rtl] .mat-mdc-option .mat-pseudo-checkbox-full{margin-right:0;margin-left:16px}.mat-mdc-option .mat-pseudo-checkbox-minimal{margin-left:16px;flex-shrink:0}[dir=rtl] .mat-mdc-option .mat-pseudo-checkbox-minimal{margin-right:16px;margin-left:0}.mat-mdc-option .mat-mdc-option-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-mdc-option .mdc-list-item__primary-text{white-space:normal;font-size:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;font-family:inherit;text-decoration:inherit;text-transform:inherit;margin-right:auto}[dir=rtl] .mat-mdc-option .mdc-list-item__primary-text{margin-right:0;margin-left:auto}.cdk-high-contrast-active .mat-mdc-option.mdc-list-item--selected:not(.mat-mdc-option-multiple)::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}[dir=rtl] .cdk-high-contrast-active .mat-mdc-option.mdc-list-item--selected:not(.mat-mdc-option-multiple)::after{right:auto;left:16px}.mat-mdc-option-active::before{content:""}'],encapsulation:2,changeDetection:0}),n})(),oN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[$v,ul,rr,iN]}),n})();const aN=["mat-button",""],VT=[[["",8,"material-icons",3,"iconPositionEnd",""],["mat-icon",3,"iconPositionEnd",""],["","matButtonIcon","",3,"iconPositionEnd",""]],"*",[["","iconPositionEnd","",8,"material-icons"],["mat-icon","iconPositionEnd",""],["","matButtonIcon","","iconPositionEnd",""]]],HT=[".material-icons:not([iconPositionEnd]), mat-icon:not([iconPositionEnd]), [matButtonIcon]:not([iconPositionEnd])","*",".material-icons[iconPositionEnd], mat-icon[iconPositionEnd], [matButtonIcon][iconPositionEnd]"],oq=["mat-mini-fab",""],cq=[{selector:"mat-button",mdcClasses:["mdc-button","mat-mdc-button"]},{selector:"mat-flat-button",mdcClasses:["mdc-button","mdc-button--unelevated","mat-mdc-unelevated-button"]},{selector:"mat-raised-button",mdcClasses:["mdc-button","mdc-button--raised","mat-mdc-raised-button"]},{selector:"mat-stroked-button",mdcClasses:["mdc-button","mdc-button--outlined","mat-mdc-outlined-button"]},{selector:"mat-fab",mdcClasses:["mdc-fab","mat-mdc-fab"]},{selector:"mat-mini-fab",mdcClasses:["mdc-fab","mdc-fab--mini","mat-mdc-mini-fab"]},{selector:"mat-icon-button",mdcClasses:["mdc-icon-button","mat-mdc-icon-button"]}],lq=NT(LT(Bw(class{constructor(n){this._elementRef=n}})));let UT=(()=>{class n extends lq{constructor(t,i,r,s){super(t),this._platform=i,this._ngZone=r,this._animationMode=s,this._focusMonitor=hn(Vf),this._isFab=!1;const o=t.nativeElement.classList;for(const a of cq)this._hasHostAttributes(a.selector)&&a.mdcClasses.forEach(c=>{o.add(c)})}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef)}focus(t="program",i){t?this._focusMonitor.focusVia(this._elementRef.nativeElement,t,i):this._elementRef.nativeElement.focus(i)}_hasHostAttributes(...t){return t.some(i=>this._elementRef.nativeElement.hasAttribute(i))}_isRippleDisabled(){return this.disableRipple||this.disabled}}return n.\u0275fac=function(t){Gl()},n.\u0275dir=ut({type:n,viewQuery:function(t,i){if(1&t&&zr(rh,5),2&t){let r;Yn(r=Xn())&&(i.ripple=r.first)}},features:[Z]}),n})(),uq=(()=>{class n extends UT{constructor(t,i,r,s){super(t,i,r,s),this._haltDisabledEvents=o=>{this.disabled&&(o.preventDefault(),o.stopImmediatePropagation())}}ngOnInit(){this._ngZone.runOutsideAngular(()=>{this._elementRef.nativeElement.addEventListener("click",this._haltDisabledEvents)})}ngOnDestroy(){super.ngOnDestroy(),this._elementRef.nativeElement.removeEventListener("click",this._haltDisabledEvents)}}return n.\u0275fac=function(t){Gl()},n.\u0275dir=ut({type:n,features:[Z]}),n})(),cN=(()=>{class n extends UT{constructor(t,i,r,s){super(t,i,r,s)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(as),ie(Xt),ie(bo,8))},n.\u0275cmp=Ln({type:n,selectors:[["button","mat-button",""],["button","mat-raised-button",""],["button","mat-flat-button",""],["button","mat-stroked-button",""]],hostVars:7,hostBindings:function(t,i){2&t&&(Di("disabled",i.disabled||null),hi("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mat-unthemed",!i.color)("mat-mdc-button-base",!0))},inputs:{disabled:"disabled",disableRipple:"disableRipple",color:"color"},exportAs:["matButton"],features:[Z],attrs:aN,ngContentSelectors:HT,decls:8,vars:6,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-mdc-focus-indicator"],["matRipple","",1,"mat-mdc-button-ripple",3,"matRippleDisabled","matRippleTrigger"],[1,"mat-mdc-button-touch-target"]],template:function(t,i){1&t&&(Hs(VT),qt(0,"span",0),En(1),ke(2,"span",1),En(3,1),Ne(),En(4,2),qt(5,"span",2)(6,"span",3)(7,"span",4)),2&t&&(hi("mdc-button__ripple",!i._isFab)("mdc-fab__ripple",i._isFab),Le(6),$e("matRippleDisabled",i._isRippleDisabled())("matRippleTrigger",i._elementRef.nativeElement))},dependencies:[rh],styles:['.mdc-touch-target-wrapper{display:inline}.mdc-elevation-overlay{position:absolute;border-radius:inherit;pointer-events:none;opacity:var(--mdc-elevation-overlay-opacity, 0);transition:opacity 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-button{position:relative;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:64px;border:none;outline:none;line-height:inherit;user-select:none;-webkit-appearance:none;overflow:visible;vertical-align:middle;background:rgba(0,0,0,0)}.mdc-button .mdc-elevation-overlay{width:100%;height:100%;top:0;left:0}.mdc-button::-moz-focus-inner{padding:0;border:0}.mdc-button:active{outline:none}.mdc-button:hover{cursor:pointer}.mdc-button:disabled{cursor:default;pointer-events:none}.mdc-button[hidden]{display:none}.mdc-button .mdc-button__icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top}[dir=rtl] .mdc-button .mdc-button__icon,.mdc-button .mdc-button__icon[dir=rtl]{margin-left:8px;margin-right:0}.mdc-button .mdc-button__progress-indicator{font-size:0;position:absolute;transform:translate(-50%, -50%);top:50%;left:50%;line-height:initial}.mdc-button .mdc-button__label{position:relative}.mdc-button .mdc-button__focus-ring{pointer-events:none;border:2px solid rgba(0,0,0,0);border-radius:6px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(\n 100% + 4px\n );width:calc(\n 100% + 4px\n );display:none}@media screen and (forced-colors: active){.mdc-button .mdc-button__focus-ring{border-color:CanvasText}}.mdc-button .mdc-button__focus-ring::after{content:"";border:2px solid rgba(0,0,0,0);border-radius:8px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-button .mdc-button__focus-ring::after{border-color:CanvasText}}@media screen and (forced-colors: active){.mdc-button.mdc-ripple-upgraded--background-focused .mdc-button__focus-ring,.mdc-button:not(.mdc-ripple-upgraded):focus .mdc-button__focus-ring{display:block}}.mdc-button .mdc-button__touch{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%)}.mdc-button__label+.mdc-button__icon{margin-left:8px;margin-right:0}[dir=rtl] .mdc-button__label+.mdc-button__icon,.mdc-button__label+.mdc-button__icon[dir=rtl]{margin-left:0;margin-right:8px}svg.mdc-button__icon{fill:currentColor}.mdc-button--touch{margin-top:6px;margin-bottom:6px}.mdc-button{padding:0 8px 0 8px}.mdc-button--unelevated{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);padding:0 16px 0 16px}.mdc-button--unelevated.mdc-button--icon-trailing{padding:0 12px 0 16px}.mdc-button--unelevated.mdc-button--icon-leading{padding:0 16px 0 12px}.mdc-button--raised{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);padding:0 16px 0 16px}.mdc-button--raised.mdc-button--icon-trailing{padding:0 12px 0 16px}.mdc-button--raised.mdc-button--icon-leading{padding:0 16px 0 12px}.mdc-button--outlined{border-style:solid;transition:border 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-button--outlined .mdc-button__ripple{border-style:solid;border-color:rgba(0,0,0,0)}.mat-mdc-button{height:var(--mdc-text-button-container-height, 36px);border-radius:var(--mdc-text-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-button:not(:disabled){color:var(--mdc-text-button-label-text-color, inherit)}.mat-mdc-button:disabled{color:var(--mdc-text-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-button .mdc-button__ripple{border-radius:var(--mdc-text-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-unelevated-button{height:var(--mdc-filled-button-container-height, 36px);border-radius:var(--mdc-filled-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-unelevated-button:not(:disabled){background-color:var(--mdc-filled-button-container-color, transparent)}.mat-mdc-unelevated-button:disabled{background-color:var(--mdc-filled-button-disabled-container-color, rgba(0, 0, 0, 0.12))}.mat-mdc-unelevated-button:not(:disabled){color:var(--mdc-filled-button-label-text-color, inherit)}.mat-mdc-unelevated-button:disabled{color:var(--mdc-filled-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-unelevated-button .mdc-button__ripple{border-radius:var(--mdc-filled-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-raised-button{height:var(--mdc-protected-button-container-height, 36px);border-radius:var(--mdc-protected-button-container-shape, var(--mdc-shape-small, 4px));box-shadow:var(--mdc-protected-button-container-elevation, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled){background-color:var(--mdc-protected-button-container-color, transparent)}.mat-mdc-raised-button:disabled{background-color:var(--mdc-protected-button-disabled-container-color, rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled){color:var(--mdc-protected-button-label-text-color, inherit)}.mat-mdc-raised-button:disabled{color:var(--mdc-protected-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-raised-button .mdc-button__ripple{border-radius:var(--mdc-protected-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-raised-button.mdc-ripple-upgraded--background-focused,.mat-mdc-raised-button:not(.mdc-ripple-upgraded):focus{box-shadow:var(--mdc-protected-button-focus-container-elevation, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:hover{box-shadow:var(--mdc-protected-button-hover-container-elevation, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled):active{box-shadow:var(--mdc-protected-button-pressed-container-elevation, 0px 5px 5px -3px rgba(0, 0, 0, 0.2), 0px 8px 10px 1px rgba(0, 0, 0, 0.14), 0px 3px 14px 2px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:disabled{box-shadow:var(--mdc-protected-button-disabled-container-elevation, 0px 0px 0px 0px rgba(0, 0, 0, 0.2), 0px 0px 0px 0px rgba(0, 0, 0, 0.14), 0px 0px 0px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button{height:var(--mdc-outlined-button-container-height, 36px);border-radius:var(--mdc-outlined-button-container-shape, var(--mdc-shape-small, 4px));padding:0 15px 0 15px;border-width:var(--mdc-outlined-button-outline-width, 1px)}.mat-mdc-outlined-button:not(:disabled){color:var(--mdc-outlined-button-label-text-color, inherit)}.mat-mdc-outlined-button:disabled{color:var(--mdc-outlined-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-outlined-button .mdc-button__ripple{border-radius:var(--mdc-outlined-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-outlined-button:not(:disabled){border-color:var(--mdc-outlined-button-outline-color, rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button:disabled{border-color:var(--mdc-outlined-button-disabled-outline-color, rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button.mdc-button--icon-trailing{padding:0 11px 0 15px}.mat-mdc-outlined-button.mdc-button--icon-leading{padding:0 15px 0 11px}.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px;border-width:var(--mdc-outlined-button-outline-width, 1px)}.mat-mdc-outlined-button .mdc-button__touch{left:calc(-1 * var(--mdc-outlined-button-outline-width, 1px));width:calc(100% + 2 * var(--mdc-outlined-button-outline-width, 1px))}.mat-mdc-button,.mat-mdc-unelevated-button,.mat-mdc-raised-button,.mat-mdc-outlined-button{-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-button .mat-mdc-button-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0;background-color:var(--mat-mdc-button-persistent-ripple-color)}.mat-mdc-button .mat-ripple-element,.mat-mdc-unelevated-button .mat-ripple-element,.mat-mdc-raised-button .mat-ripple-element,.mat-mdc-outlined-button .mat-ripple-element{background-color:var(--mat-mdc-button-ripple-color)}.mat-mdc-button .mdc-button__label,.mat-mdc-unelevated-button .mdc-button__label,.mat-mdc-raised-button .mdc-button__label,.mat-mdc-outlined-button .mdc-button__label{z-index:1}.mat-mdc-button .mat-mdc-focus-indicator,.mat-mdc-unelevated-button .mat-mdc-focus-indicator,.mat-mdc-raised-button .mat-mdc-focus-indicator,.mat-mdc-outlined-button .mat-mdc-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-unelevated-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-raised-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-outlined-button:focus .mat-mdc-focus-indicator::before{content:""}.mat-mdc-button[disabled],.mat-mdc-unelevated-button[disabled],.mat-mdc-raised-button[disabled],.mat-mdc-outlined-button[disabled]{cursor:default;pointer-events:none}.mat-mdc-button .mat-mdc-button-touch-target,.mat-mdc-unelevated-button .mat-mdc-button-touch-target,.mat-mdc-raised-button .mat-mdc-button-touch-target,.mat-mdc-outlined-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%)}.mat-mdc-button._mat-animation-noopable,.mat-mdc-unelevated-button._mat-animation-noopable,.mat-mdc-raised-button._mat-animation-noopable,.mat-mdc-outlined-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-button>.mat-icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem}[dir=rtl] .mat-mdc-button>.mat-icon,.mat-mdc-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:0}.mat-mdc-button .mdc-button__label+.mat-icon{margin-left:8px;margin-right:0}[dir=rtl] .mat-mdc-button .mdc-button__label+.mat-icon,.mat-mdc-button .mdc-button__label+.mat-icon[dir=rtl]{margin-left:0;margin-right:8px}.mat-mdc-unelevated-button>.mat-icon,.mat-mdc-raised-button>.mat-icon,.mat-mdc-outlined-button>.mat-icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem;margin-left:-4px;margin-right:8px}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon,[dir=rtl] .mat-mdc-raised-button>.mat-icon,[dir=rtl] .mat-mdc-outlined-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon[dir=rtl],.mat-mdc-raised-button>.mat-icon[dir=rtl],.mat-mdc-outlined-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:0}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon,[dir=rtl] .mat-mdc-raised-button>.mat-icon,[dir=rtl] .mat-mdc-outlined-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon[dir=rtl],.mat-mdc-raised-button>.mat-icon[dir=rtl],.mat-mdc-outlined-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:-4px}.mat-mdc-unelevated-button .mdc-button__label+.mat-icon,.mat-mdc-raised-button .mdc-button__label+.mat-icon,.mat-mdc-outlined-button .mdc-button__label+.mat-icon{margin-left:8px;margin-right:-4px}[dir=rtl] .mat-mdc-unelevated-button .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-raised-button .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-outlined-button .mdc-button__label+.mat-icon,.mat-mdc-unelevated-button .mdc-button__label+.mat-icon[dir=rtl],.mat-mdc-raised-button .mdc-button__label+.mat-icon[dir=rtl],.mat-mdc-outlined-button .mdc-button__label+.mat-icon[dir=rtl]{margin-left:-4px;margin-right:8px}.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px;border-width:-1px}.mat-mdc-unelevated-button .mat-mdc-focus-indicator::before,.mat-mdc-raised-button .mat-mdc-focus-indicator::before{margin:calc(calc(var(--mat-mdc-focus-indicator-border-width, 3px) + 2px) * -1)}.mat-mdc-outlined-button .mat-mdc-focus-indicator::before{margin:calc(calc(var(--mat-mdc-focus-indicator-border-width, 3px) + 3px) * -1)}',".cdk-high-contrast-active .mat-mdc-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-unelevated-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-raised-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-outlined-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-icon-button{outline:solid 1px}"],encapsulation:2,changeDetection:0}),n})(),hq=(()=>{class n extends uq{constructor(t,i,r,s){super(t,i,r,s)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(as),ie(Xt),ie(bo,8))},n.\u0275cmp=Ln({type:n,selectors:[["a","mat-button",""],["a","mat-raised-button",""],["a","mat-flat-button",""],["a","mat-stroked-button",""]],hostVars:9,hostBindings:function(t,i){2&t&&(Di("disabled",i.disabled||null)("tabindex",i.disabled?-1:i.tabIndex)("aria-disabled",i.disabled.toString()),hi("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mat-unthemed",!i.color)("mat-mdc-button-base",!0))},inputs:{disabled:"disabled",disableRipple:"disableRipple",color:"color",tabIndex:"tabIndex"},exportAs:["matButton","matAnchor"],features:[Z],attrs:aN,ngContentSelectors:HT,decls:8,vars:6,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-mdc-focus-indicator"],["matRipple","",1,"mat-mdc-button-ripple",3,"matRippleDisabled","matRippleTrigger"],[1,"mat-mdc-button-touch-target"]],template:function(t,i){1&t&&(Hs(VT),qt(0,"span",0),En(1),ke(2,"span",1),En(3,1),Ne(),En(4,2),qt(5,"span",2)(6,"span",3)(7,"span",4)),2&t&&(hi("mdc-button__ripple",!i._isFab)("mdc-fab__ripple",i._isFab),Le(6),$e("matRippleDisabled",i._isRippleDisabled())("matRippleTrigger",i._elementRef.nativeElement))},dependencies:[rh],styles:['.mdc-touch-target-wrapper{display:inline}.mdc-elevation-overlay{position:absolute;border-radius:inherit;pointer-events:none;opacity:var(--mdc-elevation-overlay-opacity, 0);transition:opacity 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-button{position:relative;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:64px;border:none;outline:none;line-height:inherit;user-select:none;-webkit-appearance:none;overflow:visible;vertical-align:middle;background:rgba(0,0,0,0)}.mdc-button .mdc-elevation-overlay{width:100%;height:100%;top:0;left:0}.mdc-button::-moz-focus-inner{padding:0;border:0}.mdc-button:active{outline:none}.mdc-button:hover{cursor:pointer}.mdc-button:disabled{cursor:default;pointer-events:none}.mdc-button[hidden]{display:none}.mdc-button .mdc-button__icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top}[dir=rtl] .mdc-button .mdc-button__icon,.mdc-button .mdc-button__icon[dir=rtl]{margin-left:8px;margin-right:0}.mdc-button .mdc-button__progress-indicator{font-size:0;position:absolute;transform:translate(-50%, -50%);top:50%;left:50%;line-height:initial}.mdc-button .mdc-button__label{position:relative}.mdc-button .mdc-button__focus-ring{pointer-events:none;border:2px solid rgba(0,0,0,0);border-radius:6px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(\n 100% + 4px\n );width:calc(\n 100% + 4px\n );display:none}@media screen and (forced-colors: active){.mdc-button .mdc-button__focus-ring{border-color:CanvasText}}.mdc-button .mdc-button__focus-ring::after{content:"";border:2px solid rgba(0,0,0,0);border-radius:8px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-button .mdc-button__focus-ring::after{border-color:CanvasText}}@media screen and (forced-colors: active){.mdc-button.mdc-ripple-upgraded--background-focused .mdc-button__focus-ring,.mdc-button:not(.mdc-ripple-upgraded):focus .mdc-button__focus-ring{display:block}}.mdc-button .mdc-button__touch{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%)}.mdc-button__label+.mdc-button__icon{margin-left:8px;margin-right:0}[dir=rtl] .mdc-button__label+.mdc-button__icon,.mdc-button__label+.mdc-button__icon[dir=rtl]{margin-left:0;margin-right:8px}svg.mdc-button__icon{fill:currentColor}.mdc-button--touch{margin-top:6px;margin-bottom:6px}.mdc-button{padding:0 8px 0 8px}.mdc-button--unelevated{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);padding:0 16px 0 16px}.mdc-button--unelevated.mdc-button--icon-trailing{padding:0 12px 0 16px}.mdc-button--unelevated.mdc-button--icon-leading{padding:0 16px 0 12px}.mdc-button--raised{transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);padding:0 16px 0 16px}.mdc-button--raised.mdc-button--icon-trailing{padding:0 12px 0 16px}.mdc-button--raised.mdc-button--icon-leading{padding:0 16px 0 12px}.mdc-button--outlined{border-style:solid;transition:border 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-button--outlined .mdc-button__ripple{border-style:solid;border-color:rgba(0,0,0,0)}.mat-mdc-button{height:var(--mdc-text-button-container-height, 36px);border-radius:var(--mdc-text-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-button:not(:disabled){color:var(--mdc-text-button-label-text-color, inherit)}.mat-mdc-button:disabled{color:var(--mdc-text-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-button .mdc-button__ripple{border-radius:var(--mdc-text-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-unelevated-button{height:var(--mdc-filled-button-container-height, 36px);border-radius:var(--mdc-filled-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-unelevated-button:not(:disabled){background-color:var(--mdc-filled-button-container-color, transparent)}.mat-mdc-unelevated-button:disabled{background-color:var(--mdc-filled-button-disabled-container-color, rgba(0, 0, 0, 0.12))}.mat-mdc-unelevated-button:not(:disabled){color:var(--mdc-filled-button-label-text-color, inherit)}.mat-mdc-unelevated-button:disabled{color:var(--mdc-filled-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-unelevated-button .mdc-button__ripple{border-radius:var(--mdc-filled-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-raised-button{height:var(--mdc-protected-button-container-height, 36px);border-radius:var(--mdc-protected-button-container-shape, var(--mdc-shape-small, 4px));box-shadow:var(--mdc-protected-button-container-elevation, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled){background-color:var(--mdc-protected-button-container-color, transparent)}.mat-mdc-raised-button:disabled{background-color:var(--mdc-protected-button-disabled-container-color, rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled){color:var(--mdc-protected-button-label-text-color, inherit)}.mat-mdc-raised-button:disabled{color:var(--mdc-protected-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-raised-button .mdc-button__ripple{border-radius:var(--mdc-protected-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-raised-button.mdc-ripple-upgraded--background-focused,.mat-mdc-raised-button:not(.mdc-ripple-upgraded):focus{box-shadow:var(--mdc-protected-button-focus-container-elevation, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:hover{box-shadow:var(--mdc-protected-button-hover-container-elevation, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:not(:disabled):active{box-shadow:var(--mdc-protected-button-pressed-container-elevation, 0px 5px 5px -3px rgba(0, 0, 0, 0.2), 0px 8px 10px 1px rgba(0, 0, 0, 0.14), 0px 3px 14px 2px rgba(0, 0, 0, 0.12))}.mat-mdc-raised-button:disabled{box-shadow:var(--mdc-protected-button-disabled-container-elevation, 0px 0px 0px 0px rgba(0, 0, 0, 0.2), 0px 0px 0px 0px rgba(0, 0, 0, 0.14), 0px 0px 0px 0px rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button{height:var(--mdc-outlined-button-container-height, 36px);border-radius:var(--mdc-outlined-button-container-shape, var(--mdc-shape-small, 4px));padding:0 15px 0 15px;border-width:var(--mdc-outlined-button-outline-width, 1px)}.mat-mdc-outlined-button:not(:disabled){color:var(--mdc-outlined-button-label-text-color, inherit)}.mat-mdc-outlined-button:disabled{color:var(--mdc-outlined-button-disabled-label-text-color, rgba(0, 0, 0, 0.38))}.mat-mdc-outlined-button .mdc-button__ripple{border-radius:var(--mdc-outlined-button-container-shape, var(--mdc-shape-small, 4px))}.mat-mdc-outlined-button:not(:disabled){border-color:var(--mdc-outlined-button-outline-color, rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button:disabled{border-color:var(--mdc-outlined-button-disabled-outline-color, rgba(0, 0, 0, 0.12))}.mat-mdc-outlined-button.mdc-button--icon-trailing{padding:0 11px 0 15px}.mat-mdc-outlined-button.mdc-button--icon-leading{padding:0 15px 0 11px}.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px;border-width:var(--mdc-outlined-button-outline-width, 1px)}.mat-mdc-outlined-button .mdc-button__touch{left:calc(-1 * var(--mdc-outlined-button-outline-width, 1px));width:calc(100% + 2 * var(--mdc-outlined-button-outline-width, 1px))}.mat-mdc-button,.mat-mdc-unelevated-button,.mat-mdc-raised-button,.mat-mdc-outlined-button{-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-button .mat-mdc-button-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple,.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-unelevated-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-raised-button .mat-mdc-button-persistent-ripple::before,.mat-mdc-outlined-button .mat-mdc-button-persistent-ripple::before{content:"";opacity:0;background-color:var(--mat-mdc-button-persistent-ripple-color)}.mat-mdc-button .mat-ripple-element,.mat-mdc-unelevated-button .mat-ripple-element,.mat-mdc-raised-button .mat-ripple-element,.mat-mdc-outlined-button .mat-ripple-element{background-color:var(--mat-mdc-button-ripple-color)}.mat-mdc-button .mdc-button__label,.mat-mdc-unelevated-button .mdc-button__label,.mat-mdc-raised-button .mdc-button__label,.mat-mdc-outlined-button .mdc-button__label{z-index:1}.mat-mdc-button .mat-mdc-focus-indicator,.mat-mdc-unelevated-button .mat-mdc-focus-indicator,.mat-mdc-raised-button .mat-mdc-focus-indicator,.mat-mdc-outlined-button .mat-mdc-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-unelevated-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-raised-button:focus .mat-mdc-focus-indicator::before,.mat-mdc-outlined-button:focus .mat-mdc-focus-indicator::before{content:""}.mat-mdc-button[disabled],.mat-mdc-unelevated-button[disabled],.mat-mdc-raised-button[disabled],.mat-mdc-outlined-button[disabled]{cursor:default;pointer-events:none}.mat-mdc-button .mat-mdc-button-touch-target,.mat-mdc-unelevated-button .mat-mdc-button-touch-target,.mat-mdc-raised-button .mat-mdc-button-touch-target,.mat-mdc-outlined-button .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:0;right:0;transform:translateY(-50%)}.mat-mdc-button._mat-animation-noopable,.mat-mdc-unelevated-button._mat-animation-noopable,.mat-mdc-raised-button._mat-animation-noopable,.mat-mdc-outlined-button._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-button>.mat-icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem}[dir=rtl] .mat-mdc-button>.mat-icon,.mat-mdc-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:0}.mat-mdc-button .mdc-button__label+.mat-icon{margin-left:8px;margin-right:0}[dir=rtl] .mat-mdc-button .mdc-button__label+.mat-icon,.mat-mdc-button .mdc-button__label+.mat-icon[dir=rtl]{margin-left:0;margin-right:8px}.mat-mdc-unelevated-button>.mat-icon,.mat-mdc-raised-button>.mat-icon,.mat-mdc-outlined-button>.mat-icon{margin-left:0;margin-right:8px;display:inline-block;position:relative;vertical-align:top;font-size:1.125rem;height:1.125rem;width:1.125rem;margin-left:-4px;margin-right:8px}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon,[dir=rtl] .mat-mdc-raised-button>.mat-icon,[dir=rtl] .mat-mdc-outlined-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon[dir=rtl],.mat-mdc-raised-button>.mat-icon[dir=rtl],.mat-mdc-outlined-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:0}[dir=rtl] .mat-mdc-unelevated-button>.mat-icon,[dir=rtl] .mat-mdc-raised-button>.mat-icon,[dir=rtl] .mat-mdc-outlined-button>.mat-icon,.mat-mdc-unelevated-button>.mat-icon[dir=rtl],.mat-mdc-raised-button>.mat-icon[dir=rtl],.mat-mdc-outlined-button>.mat-icon[dir=rtl]{margin-left:8px;margin-right:-4px}.mat-mdc-unelevated-button .mdc-button__label+.mat-icon,.mat-mdc-raised-button .mdc-button__label+.mat-icon,.mat-mdc-outlined-button .mdc-button__label+.mat-icon{margin-left:8px;margin-right:-4px}[dir=rtl] .mat-mdc-unelevated-button .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-raised-button .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-outlined-button .mdc-button__label+.mat-icon,.mat-mdc-unelevated-button .mdc-button__label+.mat-icon[dir=rtl],.mat-mdc-raised-button .mdc-button__label+.mat-icon[dir=rtl],.mat-mdc-outlined-button .mdc-button__label+.mat-icon[dir=rtl]{margin-left:-4px;margin-right:8px}.mat-mdc-outlined-button .mat-mdc-button-ripple,.mat-mdc-outlined-button .mdc-button__ripple{top:-1px;left:-1px;bottom:-1px;right:-1px;border-width:-1px}.mat-mdc-unelevated-button .mat-mdc-focus-indicator::before,.mat-mdc-raised-button .mat-mdc-focus-indicator::before{margin:calc(calc(var(--mat-mdc-focus-indicator-border-width, 3px) + 2px) * -1)}.mat-mdc-outlined-button .mat-mdc-focus-indicator::before{margin:calc(calc(var(--mat-mdc-focus-indicator-border-width, 3px) + 3px) * -1)}',".cdk-high-contrast-active .mat-mdc-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-unelevated-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-raised-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-outlined-button:not(.mdc-button--outlined),.cdk-high-contrast-active .mat-mdc-icon-button{outline:solid 1px}"],encapsulation:2,changeDetection:0}),n})();const fq=new Ze("mat-mdc-fab-default-options",{providedIn:"root",factory:lN});function lN(){return{color:"accent"}}const dN=lN();let pq=(()=>{class n extends UT{constructor(t,i,r,s,o){super(t,i,r,s),this._options=o,this._isFab=!0,this._options=this._options||dN,this.color=this.defaultColor=this._options.color||dN.color}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(as),ie(Xt),ie(bo,8),ie(fq,8))},n.\u0275cmp=Ln({type:n,selectors:[["button","mat-mini-fab",""]],hostVars:7,hostBindings:function(t,i){2&t&&(Di("disabled",i.disabled||null),hi("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mat-unthemed",!i.color)("mat-mdc-button-base",!0))},inputs:{disabled:"disabled",disableRipple:"disableRipple",color:"color"},exportAs:["matButton"],features:[Z],attrs:oq,ngContentSelectors:HT,decls:8,vars:6,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-mdc-focus-indicator"],["matRipple","",1,"mat-mdc-button-ripple",3,"matRippleDisabled","matRippleTrigger"],[1,"mat-mdc-button-touch-target"]],template:function(t,i){1&t&&(Hs(VT),qt(0,"span",0),En(1),ke(2,"span",1),En(3,1),Ne(),En(4,2),qt(5,"span",2)(6,"span",3)(7,"span",4)),2&t&&(hi("mdc-button__ripple",!i._isFab)("mdc-fab__ripple",i._isFab),Le(6),$e("matRippleDisabled",i._isRippleDisabled())("matRippleTrigger",i._elementRef.nativeElement))},dependencies:[rh],styles:['.mdc-touch-target-wrapper{display:inline}.mdc-elevation-overlay{position:absolute;border-radius:inherit;pointer-events:none;opacity:var(--mdc-elevation-overlay-opacity, 0);transition:opacity 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-fab{position:relative;display:inline-flex;position:relative;align-items:center;justify-content:center;box-sizing:border-box;width:56px;height:56px;padding:0;border:none;fill:currentColor;text-decoration:none;cursor:pointer;user-select:none;-moz-appearance:none;-webkit-appearance:none;overflow:visible;transition:box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1),opacity 15ms linear 30ms,transform 270ms 0ms cubic-bezier(0, 0, 0.2, 1)}.mdc-fab .mdc-elevation-overlay{width:100%;height:100%;top:0;left:0}.mdc-fab[hidden]{display:none}.mdc-fab::-moz-focus-inner{padding:0;border:0}.mdc-fab .mdc-fab__focus-ring{position:absolute}.mdc-fab.mdc-ripple-upgraded--background-focused .mdc-fab__focus-ring,.mdc-fab:not(.mdc-ripple-upgraded):focus .mdc-fab__focus-ring{pointer-events:none;border:2px solid rgba(0,0,0,0);border-radius:6px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(\n 100% + 4px\n );width:calc(\n 100% + 4px\n )}@media screen and (forced-colors: active){.mdc-fab.mdc-ripple-upgraded--background-focused .mdc-fab__focus-ring,.mdc-fab:not(.mdc-ripple-upgraded):focus .mdc-fab__focus-ring{border-color:CanvasText}}.mdc-fab.mdc-ripple-upgraded--background-focused .mdc-fab__focus-ring::after,.mdc-fab:not(.mdc-ripple-upgraded):focus .mdc-fab__focus-ring::after{content:"";border:2px solid rgba(0,0,0,0);border-radius:8px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-fab.mdc-ripple-upgraded--background-focused .mdc-fab__focus-ring::after,.mdc-fab:not(.mdc-ripple-upgraded):focus .mdc-fab__focus-ring::after{border-color:CanvasText}}.mdc-fab:active,.mdc-fab:focus{outline:none}.mdc-fab:hover{cursor:pointer}.mdc-fab>svg{width:100%}.mdc-fab--mini{width:40px;height:40px}.mdc-fab--extended{border-radius:24px;padding-left:20px;padding-right:20px;width:auto;max-width:100%;height:48px;line-height:normal}.mdc-fab--extended .mdc-fab__ripple{border-radius:24px}.mdc-fab--extended .mdc-fab__icon{margin-left:calc(12px - 20px);margin-right:12px}[dir=rtl] .mdc-fab--extended .mdc-fab__icon,.mdc-fab--extended .mdc-fab__icon[dir=rtl]{margin-left:12px;margin-right:calc(12px - 20px)}.mdc-fab--extended .mdc-fab__label+.mdc-fab__icon{margin-left:12px;margin-right:calc(12px - 20px)}[dir=rtl] .mdc-fab--extended .mdc-fab__label+.mdc-fab__icon,.mdc-fab--extended .mdc-fab__label+.mdc-fab__icon[dir=rtl]{margin-left:calc(12px - 20px);margin-right:12px}.mdc-fab--touch{margin-top:4px;margin-bottom:4px;margin-right:4px;margin-left:4px}.mdc-fab--touch .mdc-fab__touch{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%)}.mdc-fab::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-fab::before{border-color:CanvasText}}.mdc-fab__label{justify-content:flex-start;text-overflow:ellipsis;white-space:nowrap;overflow-x:hidden;overflow-y:visible}.mdc-fab__icon{transition:transform 180ms 90ms cubic-bezier(0, 0, 0.2, 1);fill:currentColor;will-change:transform}.mdc-fab .mdc-fab__icon{display:inline-flex;align-items:center;justify-content:center}.mdc-fab--exited{transform:scale(0);opacity:0;transition:opacity 15ms linear 150ms,transform 180ms 0ms cubic-bezier(0.4, 0, 1, 1)}.mdc-fab--exited .mdc-fab__icon{transform:scale(0);transition:transform 135ms 0ms cubic-bezier(0.4, 0, 1, 1)}.mdc-fab .mdc-fab__icon{width:24px;height:24px;font-size:24px}.mdc-fab:not(.mdc-fab--extended){border-radius:50%}.mdc-fab:not(.mdc-fab--extended) .mdc-fab__ripple{border-radius:50%}.mat-mdc-fab,.mat-mdc-mini-fab{-webkit-tap-highlight-color:rgba(0,0,0,0);background-color:var(--mdc-fab-container-color, transparent);box-shadow:0px 3px 5px -1px rgba(0, 0, 0, 0.2), 0px 6px 10px 0px rgba(0, 0, 0, 0.14), 0px 1px 18px 0px rgba(0, 0, 0, 0.12);color:var(--mat-mdc-fab-color, inherit);flex-shrink:0}.mat-mdc-fab .mat-mdc-button-ripple,.mat-mdc-fab .mat-mdc-button-persistent-ripple,.mat-mdc-fab .mat-mdc-button-persistent-ripple::before,.mat-mdc-mini-fab .mat-mdc-button-ripple,.mat-mdc-mini-fab .mat-mdc-button-persistent-ripple,.mat-mdc-mini-fab .mat-mdc-button-persistent-ripple::before{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-mdc-fab .mat-mdc-button-persistent-ripple::before,.mat-mdc-mini-fab .mat-mdc-button-persistent-ripple::before{content:"";opacity:0;background-color:var(--mat-mdc-button-persistent-ripple-color)}.mat-mdc-fab .mat-ripple-element,.mat-mdc-mini-fab .mat-ripple-element{background-color:var(--mat-mdc-button-ripple-color)}.mat-mdc-fab .mdc-button__label,.mat-mdc-mini-fab .mdc-button__label{z-index:1}.mat-mdc-fab .mat-mdc-focus-indicator,.mat-mdc-mini-fab .mat-mdc-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute}.mat-mdc-fab:focus .mat-mdc-focus-indicator::before,.mat-mdc-mini-fab:focus .mat-mdc-focus-indicator::before{content:""}.mat-mdc-fab .mat-mdc-button-touch-target,.mat-mdc-mini-fab .mat-mdc-button-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%)}.mat-mdc-fab._mat-animation-noopable,.mat-mdc-mini-fab._mat-animation-noopable{transition:none !important;animation:none !important}.mat-mdc-fab:not(:disabled) .mdc-fab__icon,.mat-mdc-mini-fab:not(:disabled) .mdc-fab__icon{color:var(--mdc-fab-icon-color, inherit)}.mat-mdc-fab:not(.mdc-fab--extended),.mat-mdc-mini-fab:not(.mdc-fab--extended){border-radius:var(--mdc-fab-container-shape, 50%)}.mat-mdc-fab:not(.mdc-fab--extended) .mdc-fab__ripple,.mat-mdc-mini-fab:not(.mdc-fab--extended) .mdc-fab__ripple{border-radius:var(--mdc-fab-container-shape, 50%)}.mat-mdc-fab:hover,.mat-mdc-fab:focus,.mat-mdc-mini-fab:hover,.mat-mdc-mini-fab:focus{box-shadow:0px 5px 5px -3px rgba(0, 0, 0, 0.2), 0px 8px 10px 1px rgba(0, 0, 0, 0.14), 0px 3px 14px 2px rgba(0, 0, 0, 0.12)}.mat-mdc-fab:active,.mat-mdc-fab:focus:active,.mat-mdc-mini-fab:active,.mat-mdc-mini-fab:focus:active{box-shadow:0px 7px 8px -4px rgba(0, 0, 0, 0.2), 0px 12px 17px 2px rgba(0, 0, 0, 0.14), 0px 5px 22px 4px rgba(0, 0, 0, 0.12)}.mat-mdc-fab[disabled],.mat-mdc-mini-fab[disabled]{cursor:default;pointer-events:none;box-shadow:0px 0px 0px 0px rgba(0, 0, 0, 0.2), 0px 0px 0px 0px rgba(0, 0, 0, 0.14), 0px 0px 0px 0px rgba(0, 0, 0, 0.12)}.mat-mdc-fab:not(.mdc-ripple-upgraded):focus::before,.mat-mdc-mini-fab:not(.mdc-ripple-upgraded):focus::before{background:rgba(0,0,0,0);opacity:1}.mat-mdc-fab .mat-icon,.mat-mdc-fab .material-icons,.mat-mdc-mini-fab .mat-icon,.mat-mdc-mini-fab .material-icons{transition:transform 180ms 90ms cubic-bezier(0, 0, 0.2, 1);fill:currentColor;will-change:transform}.mat-mdc-fab .mat-mdc-focus-indicator::before,.mat-mdc-mini-fab .mat-mdc-focus-indicator::before{margin:calc(calc(var(--mat-mdc-focus-indicator-border-width, 3px) + 2px) * -1)}.mat-mdc-extended-fab{border-radius:24px;padding-left:20px;padding-right:20px;width:auto;max-width:100%;height:48px;line-height:normal}.mat-mdc-extended-fab .mdc-fab__ripple{border-radius:24px}.mat-mdc-extended-fab .mdc-fab__icon{margin-left:calc(12px - 20px);margin-right:12px}[dir=rtl] .mat-mdc-extended-fab .mdc-fab__icon,.mat-mdc-extended-fab .mdc-fab__icon[dir=rtl]{margin-left:12px;margin-right:calc(12px - 20px)}.mat-mdc-extended-fab .mdc-fab__label+.mdc-fab__icon{margin-left:12px;margin-right:calc(12px - 20px)}[dir=rtl] .mat-mdc-extended-fab .mdc-fab__label+.mdc-fab__icon,.mat-mdc-extended-fab .mdc-fab__label+.mdc-fab__icon[dir=rtl]{margin-left:calc(12px - 20px);margin-right:12px}.mat-mdc-extended-fab>.mat-icon,.mat-mdc-extended-fab>.material-icons{margin-left:calc(12px - 20px);margin-right:12px}[dir=rtl] .mat-mdc-extended-fab>.mat-icon,[dir=rtl] .mat-mdc-extended-fab>.material-icons,.mat-mdc-extended-fab>.mat-icon[dir=rtl],.mat-mdc-extended-fab>.material-icons[dir=rtl]{margin-left:12px;margin-right:calc(12px - 20px)}.mat-mdc-extended-fab .mdc-button__label+.mat-icon,.mat-mdc-extended-fab .mdc-button__label+.material-icons{margin-left:12px;margin-right:calc(12px - 20px)}[dir=rtl] .mat-mdc-extended-fab .mdc-button__label+.mat-icon,[dir=rtl] .mat-mdc-extended-fab .mdc-button__label+.material-icons,.mat-mdc-extended-fab .mdc-button__label+.mat-icon[dir=rtl],.mat-mdc-extended-fab .mdc-button__label+.material-icons[dir=rtl]{margin-left:calc(12px - 20px);margin-right:12px}.mat-mdc-extended-fab .mat-mdc-button-touch-target{width:100%}'],encapsulation:2,changeDetection:0}),n})(),uN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,$v,rr]}),n})();class Hw{get selected(){return this._selected||(this._selected=Array.from(this._selection.values())),this._selected}constructor(e=!1,t,i=!0,r){this._multiple=e,this._emitChanges=i,this.compareWith=r,this._selection=new Set,this._deselectedToEmit=[],this._selectedToEmit=[],this.changed=new cn,t&&t.length&&(e?t.forEach(s=>this._markSelected(s)):this._markSelected(t[0]),this._selectedToEmit.length=0)}select(...e){this._verifyValueAssignment(e),e.forEach(i=>this._markSelected(i));const t=this._hasQueuedChanges();return this._emitChangeEvent(),t}deselect(...e){this._verifyValueAssignment(e),e.forEach(i=>this._unmarkSelected(i));const t=this._hasQueuedChanges();return this._emitChangeEvent(),t}setSelection(...e){this._verifyValueAssignment(e);const t=this.selected,i=new Set(e);e.forEach(s=>this._markSelected(s)),t.filter(s=>!i.has(s)).forEach(s=>this._unmarkSelected(s));const r=this._hasQueuedChanges();return this._emitChangeEvent(),r}toggle(e){return this.isSelected(e)?this.deselect(e):this.select(e)}clear(e=!0){this._unmarkAll();const t=this._hasQueuedChanges();return e&&this._emitChangeEvent(),t}isSelected(e){return this._selection.has(this._getConcreteValue(e))}isEmpty(){return 0===this._selection.size}hasValue(){return!this.isEmpty()}sort(e){this._multiple&&this.selected&&this._selected.sort(e)}isMultipleSelection(){return this._multiple}_emitChangeEvent(){this._selected=null,(this._selectedToEmit.length||this._deselectedToEmit.length)&&(this.changed.next({source:this,added:this._selectedToEmit,removed:this._deselectedToEmit}),this._deselectedToEmit=[],this._selectedToEmit=[])}_markSelected(e){e=this._getConcreteValue(e),this.isSelected(e)||(this._multiple||this._unmarkAll(),this.isSelected(e)||this._selection.add(e),this._emitChanges&&this._selectedToEmit.push(e))}_unmarkSelected(e){e=this._getConcreteValue(e),this.isSelected(e)&&(this._selection.delete(e),this._emitChanges&&this._deselectedToEmit.push(e))}_unmarkAll(){this.isEmpty()||this._selection.forEach(e=>this._unmarkSelected(e))}_verifyValueAssignment(e){}_hasQueuedChanges(){return!(!this._deselectedToEmit.length&&!this._selectedToEmit.length)}_getConcreteValue(e){if(this.compareWith){for(let t of this._selection)if(this.compareWith(e,t))return t;return e}return e}}const mq=["button"],gq=["*"],hN=new Ze("MAT_BUTTON_TOGGLE_DEFAULT_OPTIONS"),fN=new Ze("MatButtonToggleGroup"),_q={provide:Ja,useExisting:Mi(()=>gN),multi:!0};let pN=0;class mN{constructor(e,t){this.source=e,this.value=t}}let gN=(()=>{class n{get name(){return this._name}set name(t){this._name=t,this._markButtonsForCheck()}get vertical(){return this._vertical}set vertical(t){this._vertical=bi(t)}get value(){const t=this._selectionModel?this._selectionModel.selected:[];return this.multiple?t.map(i=>i.value):t[0]?t[0].value:void 0}set value(t){this._setSelectionByValue(t),this.valueChange.emit(this.value)}get selected(){const t=this._selectionModel?this._selectionModel.selected:[];return this.multiple?t:t[0]||null}get multiple(){return this._multiple}set multiple(t){this._multiple=bi(t),this._markButtonsForCheck()}get disabled(){return this._disabled}set disabled(t){this._disabled=bi(t),this._markButtonsForCheck()}constructor(t,i){this._changeDetector=t,this._vertical=!1,this._multiple=!1,this._disabled=!1,this._controlValueAccessorChangeFn=()=>{},this._onTouched=()=>{},this._name="mat-button-toggle-group-"+pN++,this.valueChange=new Pn,this.change=new Pn,this.appearance=i&&i.appearance?i.appearance:"standard"}ngOnInit(){this._selectionModel=new Hw(this.multiple,void 0,!1)}ngAfterContentInit(){this._selectionModel.select(...this._buttonToggles.filter(t=>t.checked))}writeValue(t){this.value=t,this._changeDetector.markForCheck()}registerOnChange(t){this._controlValueAccessorChangeFn=t}registerOnTouched(t){this._onTouched=t}setDisabledState(t){this.disabled=t}_emitChangeEvent(t){const i=new mN(t,this.value);this._controlValueAccessorChangeFn(i.value),this.change.emit(i)}_syncButtonToggle(t,i,r=!1,s=!1){!this.multiple&&this.selected&&!t.checked&&(this.selected.checked=!1),this._selectionModel?i?this._selectionModel.select(t):this._selectionModel.deselect(t):s=!0,s?Promise.resolve().then(()=>this._updateModelValue(t,r)):this._updateModelValue(t,r)}_isSelected(t){return this._selectionModel&&this._selectionModel.isSelected(t)}_isPrechecked(t){return!(typeof this._rawValue>"u")&&(this.multiple&&Array.isArray(this._rawValue)?this._rawValue.some(i=>null!=t.value&&i===t.value):t.value===this._rawValue)}_setSelectionByValue(t){this._rawValue=t,this._buttonToggles&&(this.multiple&&t?(Array.isArray(t),this._clearSelection(),t.forEach(i=>this._selectValue(i))):(this._clearSelection(),this._selectValue(t)))}_clearSelection(){this._selectionModel.clear(),this._buttonToggles.forEach(t=>t.checked=!1)}_selectValue(t){const i=this._buttonToggles.find(r=>null!=r.value&&r.value===t);i&&(i.checked=!0,this._selectionModel.select(i))}_updateModelValue(t,i){i&&this._emitChangeEvent(t),this.valueChange.emit(this.value)}_markButtonsForCheck(){this._buttonToggles?.forEach(t=>t._markForCheck())}}return n.\u0275fac=function(t){return new(t||n)(ie(aa),ie(hN,8))},n.\u0275dir=ut({type:n,selectors:[["mat-button-toggle-group"]],contentQueries:function(t,i,r){if(1&t&&is(r,_N,5),2&t){let s;Yn(s=Xn())&&(i._buttonToggles=s)}},hostAttrs:["role","group",1,"mat-button-toggle-group"],hostVars:5,hostBindings:function(t,i){2&t&&(Di("aria-disabled",i.disabled),hi("mat-button-toggle-vertical",i.vertical)("mat-button-toggle-group-appearance-standard","standard"===i.appearance))},inputs:{appearance:"appearance",name:"name",vertical:"vertical",value:"value",multiple:"multiple",disabled:"disabled"},outputs:{valueChange:"valueChange",change:"change"},exportAs:["matButtonToggleGroup"],features:[Oi([_q,{provide:fN,useExisting:n}])]}),n})();const vq=Bw(class{});let _N=(()=>{class n extends vq{get buttonId(){return`${this.id}-button`}get appearance(){return this.buttonToggleGroup?this.buttonToggleGroup.appearance:this._appearance}set appearance(t){this._appearance=t}get checked(){return this.buttonToggleGroup?this.buttonToggleGroup._isSelected(this):this._checked}set checked(t){const i=bi(t);i!==this._checked&&(this._checked=i,this.buttonToggleGroup&&this.buttonToggleGroup._syncButtonToggle(this,this._checked),this._changeDetectorRef.markForCheck())}get disabled(){return this._disabled||this.buttonToggleGroup&&this.buttonToggleGroup.disabled}set disabled(t){this._disabled=bi(t)}constructor(t,i,r,s,o,a){super(),this._changeDetectorRef=i,this._elementRef=r,this._focusMonitor=s,this._checked=!1,this.ariaLabelledby=null,this._disabled=!1,this.change=new Pn;const c=Number(o);this.tabIndex=c||0===c?c:null,this.buttonToggleGroup=t,this.appearance=a&&a.appearance?a.appearance:"standard"}ngOnInit(){const t=this.buttonToggleGroup;this.id=this.id||"mat-button-toggle-"+pN++,t&&(t._isPrechecked(this)?this.checked=!0:t._isSelected(this)!==this._checked&&t._syncButtonToggle(this,this._checked))}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){const t=this.buttonToggleGroup;this._focusMonitor.stopMonitoring(this._elementRef),t&&t._isSelected(this)&&t._syncButtonToggle(this,!1,!1,!0)}focus(t){this._buttonElement.nativeElement.focus(t)}_onButtonClick(){const t=!!this._isSingleSelector()||!this._checked;t!==this._checked&&(this._checked=t,this.buttonToggleGroup&&(this.buttonToggleGroup._syncButtonToggle(this,this._checked,!0),this.buttonToggleGroup._onTouched())),this.change.emit(new mN(this,this.value))}_markForCheck(){this._changeDetectorRef.markForCheck()}_getButtonName(){return this._isSingleSelector()?this.buttonToggleGroup.name:this.name||null}_isSingleSelector(){return this.buttonToggleGroup&&!this.buttonToggleGroup.multiple}}return n.\u0275fac=function(t){return new(t||n)(ie(fN,8),ie(aa),ie(_n),ie(Vf),Kc("tabindex"),ie(hN,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-button-toggle"]],viewQuery:function(t,i){if(1&t&&zr(mq,5),2&t){let r;Yn(r=Xn())&&(i._buttonElement=r.first)}},hostAttrs:["role","presentation",1,"mat-button-toggle"],hostVars:12,hostBindings:function(t,i){1&t&&Gn("focus",function(){return i.focus()}),2&t&&(Di("aria-label",null)("aria-labelledby",null)("id",i.id)("name",null),hi("mat-button-toggle-standalone",!i.buttonToggleGroup)("mat-button-toggle-checked",i.checked)("mat-button-toggle-disabled",i.disabled)("mat-button-toggle-appearance-standard","standard"===i.appearance))},inputs:{disableRipple:"disableRipple",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],id:"id",name:"name",value:"value",tabIndex:"tabIndex",appearance:"appearance",checked:"checked",disabled:"disabled"},outputs:{change:"change"},exportAs:["matButtonToggle"],features:[Z],ngContentSelectors:gq,decls:6,vars:9,consts:[["type","button",1,"mat-button-toggle-button","mat-focus-indicator",3,"id","disabled","click"],["button",""],[1,"mat-button-toggle-label-content"],[1,"mat-button-toggle-focus-overlay"],["matRipple","",1,"mat-button-toggle-ripple",3,"matRippleTrigger","matRippleDisabled"]],template:function(t,i){if(1&t&&(Hs(),ke(0,"button",0,1),Gn("click",function(){return i._onButtonClick()}),ke(2,"span",2),En(3),Ne()(),qt(4,"span",3)(5,"span",4)),2&t){const r=Tc(1);$e("id",i.buttonId)("disabled",i.disabled||null),Di("tabindex",i.disabled?-1:i.tabIndex)("aria-pressed",i.checked)("name",i._getButtonName())("aria-label",i.ariaLabel)("aria-labelledby",i.ariaLabelledby),Le(5),$e("matRippleTrigger",r)("matRippleDisabled",i.disableRipple||i.disabled)}},dependencies:[rh],styles:[".mat-button-toggle-standalone,.mat-button-toggle-group{position:relative;display:inline-flex;flex-direction:row;white-space:nowrap;overflow:hidden;border-radius:2px;-webkit-tap-highlight-color:rgba(0,0,0,0);transform:translateZ(0)}.cdk-high-contrast-active .mat-button-toggle-standalone,.cdk-high-contrast-active .mat-button-toggle-group{outline:solid 1px}.mat-button-toggle-standalone.mat-button-toggle-appearance-standard,.mat-button-toggle-group-appearance-standard{border-radius:4px}.cdk-high-contrast-active .mat-button-toggle-standalone.mat-button-toggle-appearance-standard,.cdk-high-contrast-active .mat-button-toggle-group-appearance-standard{outline:0}.mat-button-toggle-vertical{flex-direction:column}.mat-button-toggle-vertical .mat-button-toggle-label-content{display:block}.mat-button-toggle{white-space:nowrap;position:relative}.mat-button-toggle .mat-icon svg{vertical-align:top}.mat-button-toggle.cdk-keyboard-focused .mat-button-toggle-focus-overlay{opacity:1}.mat-button-toggle-appearance-standard:not(.mat-button-toggle-disabled):hover .mat-button-toggle-focus-overlay{opacity:.04}.mat-button-toggle-appearance-standard.cdk-keyboard-focused:not(.mat-button-toggle-disabled) .mat-button-toggle-focus-overlay{opacity:.12}@media(hover: none){.mat-button-toggle-appearance-standard:not(.mat-button-toggle-disabled):hover .mat-button-toggle-focus-overlay{display:none}}.mat-button-toggle-label-content{-webkit-user-select:none;user-select:none;display:inline-block;line-height:36px;padding:0 16px;position:relative}.mat-button-toggle-appearance-standard .mat-button-toggle-label-content{padding:0 12px}.mat-button-toggle-label-content>*{vertical-align:middle}.mat-button-toggle-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:inherit;pointer-events:none;opacity:0}.cdk-high-contrast-active .mat-button-toggle-checked .mat-button-toggle-focus-overlay{border-bottom:solid 36px;opacity:.5;height:0}.cdk-high-contrast-active .mat-button-toggle-checked:hover .mat-button-toggle-focus-overlay{opacity:.6}.cdk-high-contrast-active .mat-button-toggle-checked.mat-button-toggle-appearance-standard .mat-button-toggle-focus-overlay{border-bottom:solid 500px}.mat-button-toggle .mat-button-toggle-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-button-toggle-button{border:0;background:none;color:inherit;padding:0;margin:0;font:inherit;outline:none;width:100%;cursor:pointer}.mat-button-toggle-disabled .mat-button-toggle-button{cursor:default}.mat-button-toggle-button::-moz-focus-inner{border:0}"],encapsulation:2,changeDetection:0}),n})(),yq=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,$v,rr]}),n})();const bq=["input"],xq=["label"],wq=["*"],Sq=new Ze("mat-checkbox-default-options",{providedIn:"root",factory:vN});function vN(){return{color:"accent",clickAction:"check-indeterminate"}}const Eq={provide:Ja,useExisting:Mi(()=>bN),multi:!0};class Mq{}let Cq=0;const yN=vN(),Dq=ZL(NT(Bw(LT(class{constructor(n){this._elementRef=n}}))));let Tq=(()=>{class n extends Dq{get inputId(){return`${this.id||this._uniqueId}-input`}get required(){return this._required}set required(t){this._required=bi(t)}constructor(t,i,r,s,o,a,c){super(i),this._changeDetectorRef=r,this._ngZone=s,this._animationMode=a,this._options=c,this.ariaLabel="",this.ariaLabelledby=null,this.labelPosition="after",this.name=null,this.change=new Pn,this.indeterminateChange=new Pn,this._onTouched=()=>{},this._currentAnimationClass="",this._currentCheckState=0,this._controlValueAccessorChangeFn=()=>{},this._checked=!1,this._disabled=!1,this._indeterminate=!1,this._options=this._options||yN,this.color=this.defaultColor=this._options.color||yN.color,this.tabIndex=parseInt(o)||0,this.id=this._uniqueId=`${t}${++Cq}`}ngAfterViewInit(){this._syncIndeterminate(this._indeterminate)}get checked(){return this._checked}set checked(t){const i=bi(t);i!=this.checked&&(this._checked=i,this._changeDetectorRef.markForCheck())}get disabled(){return this._disabled}set disabled(t){const i=bi(t);i!==this.disabled&&(this._disabled=i,this._changeDetectorRef.markForCheck())}get indeterminate(){return this._indeterminate}set indeterminate(t){const i=t!=this._indeterminate;this._indeterminate=bi(t),i&&(this._transitionCheckState(this._indeterminate?3:this.checked?1:2),this.indeterminateChange.emit(this._indeterminate)),this._syncIndeterminate(this._indeterminate)}_isRippleDisabled(){return this.disableRipple||this.disabled}_onLabelTextChange(){this._changeDetectorRef.detectChanges()}writeValue(t){this.checked=!!t}registerOnChange(t){this._controlValueAccessorChangeFn=t}registerOnTouched(t){this._onTouched=t}setDisabledState(t){this.disabled=t}_getAriaChecked(){return this.checked?"true":this.indeterminate?"mixed":"false"}_transitionCheckState(t){let i=this._currentCheckState,r=this._getAnimationTargetElement();if(i!==t&&r&&(this._currentAnimationClass&&r.classList.remove(this._currentAnimationClass),this._currentAnimationClass=this._getAnimationClassForCheckStateTransition(i,t),this._currentCheckState=t,this._currentAnimationClass.length>0)){r.classList.add(this._currentAnimationClass);const s=this._currentAnimationClass;this._ngZone.runOutsideAngular(()=>{setTimeout(()=>{r.classList.remove(s)},1e3)})}}_emitChangeEvent(){this._controlValueAccessorChangeFn(this.checked),this.change.emit(this._createChangeEvent(this.checked)),this._inputElement&&(this._inputElement.nativeElement.checked=this.checked)}toggle(){this.checked=!this.checked,this._controlValueAccessorChangeFn(this.checked)}_handleInputClick(){const t=this._options?.clickAction;this.disabled||"noop"===t?!this.disabled&&"noop"===t&&(this._inputElement.nativeElement.checked=this.checked,this._inputElement.nativeElement.indeterminate=this.indeterminate):(this.indeterminate&&"check"!==t&&Promise.resolve().then(()=>{this._indeterminate=!1,this.indeterminateChange.emit(this._indeterminate)}),this._checked=!this._checked,this._transitionCheckState(this._checked?1:2),this._emitChangeEvent())}_onInteractionEvent(t){t.stopPropagation()}_onBlur(){Promise.resolve().then(()=>{this._onTouched(),this._changeDetectorRef.markForCheck()})}_getAnimationClassForCheckStateTransition(t,i){if("NoopAnimations"===this._animationMode)return"";switch(t){case 0:if(1===i)return this._animationClasses.uncheckedToChecked;if(3==i)return this._checked?this._animationClasses.checkedToIndeterminate:this._animationClasses.uncheckedToIndeterminate;break;case 2:return 1===i?this._animationClasses.uncheckedToChecked:this._animationClasses.uncheckedToIndeterminate;case 1:return 2===i?this._animationClasses.checkedToUnchecked:this._animationClasses.checkedToIndeterminate;case 3:return 1===i?this._animationClasses.indeterminateToChecked:this._animationClasses.indeterminateToUnchecked}return""}_syncIndeterminate(t){const i=this._inputElement;i&&(i.nativeElement.indeterminate=t)}}return n.\u0275fac=function(t){Gl()},n.\u0275dir=ut({type:n,viewQuery:function(t,i){if(1&t&&(zr(bq,5),zr(xq,5),zr(rh,5)),2&t){let r;Yn(r=Xn())&&(i._inputElement=r.first),Yn(r=Xn())&&(i._labelElement=r.first),Yn(r=Xn())&&(i.ripple=r.first)}},inputs:{ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],ariaDescribedby:["aria-describedby","ariaDescribedby"],id:"id",required:"required",labelPosition:"labelPosition",name:"name",value:"value",checked:"checked",disabled:"disabled",indeterminate:"indeterminate"},outputs:{change:"change",indeterminateChange:"indeterminateChange"},features:[Z]}),n})(),bN=(()=>{class n extends Tq{constructor(t,i,r,s,o,a){super("mat-mdc-checkbox-",t,i,r,s,o,a),this._animationClasses={uncheckedToChecked:"mdc-checkbox--anim-unchecked-checked",uncheckedToIndeterminate:"mdc-checkbox--anim-unchecked-indeterminate",checkedToUnchecked:"mdc-checkbox--anim-checked-unchecked",checkedToIndeterminate:"mdc-checkbox--anim-checked-indeterminate",indeterminateToChecked:"mdc-checkbox--anim-indeterminate-checked",indeterminateToUnchecked:"mdc-checkbox--anim-indeterminate-unchecked"}}focus(){this._inputElement.nativeElement.focus()}_createChangeEvent(t){const i=new Mq;return i.source=this,i.checked=t,i}_getAnimationTargetElement(){return this._inputElement?.nativeElement}_onInputClick(){super._handleInputClick()}_onTouchTargetClick(){super._handleInputClick(),this.disabled||this._inputElement.nativeElement.focus()}_preventBubblingFromLabel(t){t.target&&this._labelElement.nativeElement.contains(t.target)&&t.stopPropagation()}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(aa),ie(Xt),Kc("tabindex"),ie(bo,8),ie(Sq,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-checkbox"]],hostAttrs:[1,"mat-mdc-checkbox"],hostVars:12,hostBindings:function(t,i){2&t&&(Af("id",i.id),Di("tabindex",null)("aria-label",null)("aria-labelledby",null),hi("_mat-animation-noopable","NoopAnimations"===i._animationMode)("mdc-checkbox--disabled",i.disabled)("mat-mdc-checkbox-disabled",i.disabled)("mat-mdc-checkbox-checked",i.checked))},inputs:{disableRipple:"disableRipple",color:"color",tabIndex:"tabIndex"},exportAs:["matCheckbox"],features:[Oi([Eq]),Z],ngContentSelectors:wq,decls:15,vars:19,consts:[[1,"mdc-form-field",3,"click"],[1,"mdc-checkbox"],["checkbox",""],[1,"mat-mdc-checkbox-touch-target",3,"click"],["type","checkbox",1,"mdc-checkbox__native-control",3,"checked","disabled","id","required","tabIndex","blur","click","change"],["input",""],[1,"mdc-checkbox__ripple"],[1,"mdc-checkbox__background"],["focusable","false","viewBox","0 0 24 24","aria-hidden","true",1,"mdc-checkbox__checkmark"],["fill","none","d","M1.73,12.91 8.1,19.28 22.79,4.59",1,"mdc-checkbox__checkmark-path"],[1,"mdc-checkbox__mixedmark"],["mat-ripple","",1,"mat-mdc-checkbox-ripple","mat-mdc-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleCentered"],[3,"for"],["label",""]],template:function(t,i){if(1&t&&(Hs(),ke(0,"div",0),Gn("click",function(s){return i._preventBubblingFromLabel(s)}),ke(1,"div",1,2)(3,"div",3),Gn("click",function(){return i._onTouchTargetClick()}),Ne(),ke(4,"input",4,5),Gn("blur",function(){return i._onBlur()})("click",function(){return i._onInputClick()})("change",function(s){return i._onInteractionEvent(s)}),Ne(),qt(6,"div",6),ke(7,"div",7),$i(),ke(8,"svg",8),qt(9,"path",9),Ne(),Xo(),qt(10,"div",10),Ne(),qt(11,"div",11),Ne(),ke(12,"label",12,13),En(14),Ne()()),2&t){const r=Tc(2);hi("mdc-form-field--align-end","before"==i.labelPosition),Le(4),hi("mdc-checkbox--selected",i.checked),$e("checked",i.checked)("disabled",i.disabled)("id",i.inputId)("required",i.required)("tabIndex",i.tabIndex),Di("aria-checked",i._getAriaChecked())("aria-label",i.ariaLabel||null)("aria-labelledby",i.ariaLabelledby)("aria-describedby",i.ariaDescribedby)("name",i.name)("value",i.value),Le(7),$e("matRippleTrigger",r)("matRippleDisabled",i.disableRipple||i.disabled)("matRippleCentered",!0),Le(1),$e("for",i.inputId)}},dependencies:[rh],styles:['.mdc-touch-target-wrapper{display:inline}@keyframes mdc-checkbox-unchecked-checked-checkmark-path{0%,50%{stroke-dashoffset:29.7833385}50%{animation-timing-function:cubic-bezier(0, 0, 0.2, 1)}100%{stroke-dashoffset:0}}@keyframes mdc-checkbox-unchecked-indeterminate-mixedmark{0%,68.2%{transform:scaleX(0)}68.2%{animation-timing-function:cubic-bezier(0, 0, 0, 1)}100%{transform:scaleX(1)}}@keyframes mdc-checkbox-checked-unchecked-checkmark-path{from{animation-timing-function:cubic-bezier(0.4, 0, 1, 1);opacity:1;stroke-dashoffset:0}to{opacity:0;stroke-dashoffset:-29.7833385}}@keyframes mdc-checkbox-checked-indeterminate-checkmark{from{animation-timing-function:cubic-bezier(0, 0, 0.2, 1);transform:rotate(0deg);opacity:1}to{transform:rotate(45deg);opacity:0}}@keyframes mdc-checkbox-indeterminate-checked-checkmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);transform:rotate(45deg);opacity:0}to{transform:rotate(360deg);opacity:1}}@keyframes mdc-checkbox-checked-indeterminate-mixedmark{from{animation-timing-function:mdc-animation-deceleration-curve-timing-function;transform:rotate(-45deg);opacity:0}to{transform:rotate(0deg);opacity:1}}@keyframes mdc-checkbox-indeterminate-checked-mixedmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);transform:rotate(0deg);opacity:1}to{transform:rotate(315deg);opacity:0}}@keyframes mdc-checkbox-indeterminate-unchecked-mixedmark{0%{animation-timing-function:linear;transform:scaleX(1);opacity:1}32.8%,100%{transform:scaleX(0);opacity:0}}.mdc-checkbox{display:inline-block;position:relative;flex:0 0 18px;box-sizing:content-box;width:18px;height:18px;line-height:0;white-space:nowrap;cursor:pointer;vertical-align:bottom}.mdc-checkbox[hidden]{display:none}.mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__focus-ring,.mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__focus-ring{pointer-events:none;border:2px solid rgba(0,0,0,0);border-radius:6px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:100%;width:100%}@media screen and (forced-colors: active){.mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__focus-ring,.mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__focus-ring{border-color:CanvasText}}.mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__focus-ring::after,.mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__focus-ring::after{content:"";border:2px solid rgba(0,0,0,0);border-radius:8px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}@media screen and (forced-colors: active){.mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__focus-ring::after,.mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__focus-ring::after{border-color:CanvasText}}@media all and (-ms-high-contrast: none){.mdc-checkbox .mdc-checkbox__focus-ring{display:none}}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-checkbox__mixedmark{margin:0 1px}}.mdc-checkbox--disabled{cursor:default;pointer-events:none}.mdc-checkbox__background{display:inline-flex;position:absolute;align-items:center;justify-content:center;box-sizing:border-box;width:18px;height:18px;border:2px solid currentColor;border-radius:2px;background-color:rgba(0,0,0,0);pointer-events:none;will-change:background-color,border-color;transition:background-color 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1),border-color 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox__checkmark{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;opacity:0;transition:opacity 180ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox--upgraded .mdc-checkbox__checkmark{opacity:1}.mdc-checkbox__checkmark-path{transition:stroke-dashoffset 180ms 0ms cubic-bezier(0.4, 0, 0.6, 1);stroke:currentColor;stroke-width:3.12px;stroke-dashoffset:29.7833385;stroke-dasharray:29.7833385}.mdc-checkbox__mixedmark{width:100%;height:0;transform:scaleX(0) rotate(0deg);border-width:1px;border-style:solid;opacity:0;transition:opacity 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1),transform 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__background,.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__background,.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__background,.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__background{animation-duration:180ms;animation-timing-function:linear}.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__checkmark-path{animation:mdc-checkbox-unchecked-checked-checkmark-path 180ms linear 0s;transition:none}.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__mixedmark{animation:mdc-checkbox-unchecked-indeterminate-mixedmark 90ms linear 0s;transition:none}.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__checkmark-path{animation:mdc-checkbox-checked-unchecked-checkmark-path 90ms linear 0s;transition:none}.mdc-checkbox--anim-checked-indeterminate .mdc-checkbox__checkmark{animation:mdc-checkbox-checked-indeterminate-checkmark 90ms linear 0s;transition:none}.mdc-checkbox--anim-checked-indeterminate .mdc-checkbox__mixedmark{animation:mdc-checkbox-checked-indeterminate-mixedmark 90ms linear 0s;transition:none}.mdc-checkbox--anim-indeterminate-checked .mdc-checkbox__checkmark{animation:mdc-checkbox-indeterminate-checked-checkmark 500ms linear 0s;transition:none}.mdc-checkbox--anim-indeterminate-checked .mdc-checkbox__mixedmark{animation:mdc-checkbox-indeterminate-checked-mixedmark 500ms linear 0s;transition:none}.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__mixedmark{animation:mdc-checkbox-indeterminate-unchecked-mixedmark 300ms linear 0s;transition:none}.mdc-checkbox__native-control:checked~.mdc-checkbox__background,.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background{transition:border-color 90ms 0ms cubic-bezier(0, 0, 0.2, 1),background-color 90ms 0ms cubic-bezier(0, 0, 0.2, 1)}.mdc-checkbox__native-control:checked~.mdc-checkbox__background .mdc-checkbox__checkmark-path,.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background .mdc-checkbox__checkmark-path,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background .mdc-checkbox__checkmark-path{stroke-dashoffset:0}.mdc-checkbox__native-control{position:absolute;margin:0;padding:0;opacity:0;cursor:inherit}.mdc-checkbox__native-control:disabled{cursor:default;pointer-events:none}.mdc-checkbox--touch{margin:calc((var(--mdc-checkbox-state-layer-size, 48px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2)}.mdc-checkbox--touch .mdc-checkbox__native-control{top:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 48px)) / 2);right:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 48px)) / 2);left:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 48px)) / 2);width:var(--mdc-checkbox-state-layer-size, 48px);height:var(--mdc-checkbox-state-layer-size, 48px)}.mdc-checkbox__native-control:checked~.mdc-checkbox__background .mdc-checkbox__checkmark{transition:opacity 180ms 0ms cubic-bezier(0, 0, 0.2, 1),transform 180ms 0ms cubic-bezier(0, 0, 0.2, 1);opacity:1}.mdc-checkbox__native-control:checked~.mdc-checkbox__background .mdc-checkbox__mixedmark{transform:scaleX(1) rotate(-45deg)}.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background .mdc-checkbox__checkmark,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background .mdc-checkbox__checkmark{transform:rotate(45deg);opacity:0;transition:opacity 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1),transform 90ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-checkbox__native-control:indeterminate~.mdc-checkbox__background .mdc-checkbox__mixedmark,.mdc-checkbox__native-control[data-indeterminate=true]~.mdc-checkbox__background .mdc-checkbox__mixedmark{transform:scaleX(1) rotate(0deg);opacity:1}.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__background,.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__checkmark,.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__checkmark-path,.mdc-checkbox.mdc-checkbox--upgraded .mdc-checkbox__mixedmark{transition:none}.mdc-form-field{display:inline-flex;align-items:center;vertical-align:middle}.mdc-form-field[hidden]{display:none}.mdc-form-field>label{margin-left:0;margin-right:auto;padding-left:4px;padding-right:0;order:0}[dir=rtl] .mdc-form-field>label,.mdc-form-field>label[dir=rtl]{margin-left:auto;margin-right:0}[dir=rtl] .mdc-form-field>label,.mdc-form-field>label[dir=rtl]{padding-left:0;padding-right:4px}.mdc-form-field--nowrap>label{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.mdc-form-field--align-end>label{margin-left:auto;margin-right:0;padding-left:0;padding-right:4px;order:-1}[dir=rtl] .mdc-form-field--align-end>label,.mdc-form-field--align-end>label[dir=rtl]{margin-left:0;margin-right:auto}[dir=rtl] .mdc-form-field--align-end>label,.mdc-form-field--align-end>label[dir=rtl]{padding-left:4px;padding-right:0}.mdc-form-field--space-between{justify-content:space-between}.mdc-form-field--space-between>label{margin:0}[dir=rtl] .mdc-form-field--space-between>label,.mdc-form-field--space-between>label[dir=rtl]{margin:0}.mat-mdc-checkbox{display:inline-block;position:relative;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-checkbox .mdc-checkbox{padding:calc((var(--mdc-checkbox-state-layer-size, 40px) - 18px) / 2);margin:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control[disabled]:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-disabled-unselected-icon-color, rgba(0, 0, 0, 0.38));background-color:transparent}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control[disabled]:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control[disabled]:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control[data-indeterminate=true][disabled]~.mdc-checkbox__background{border-color:transparent;background-color:var(--mdc-checkbox-disabled-selected-icon-color, rgba(0, 0, 0, 0.38))}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:enabled~.mdc-checkbox__background .mdc-checkbox__checkmark{color:var(--mdc-checkbox-selected-checkmark-color, #fff)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:enabled~.mdc-checkbox__background .mdc-checkbox__mixedmark{border-color:var(--mdc-checkbox-selected-checkmark-color, #fff)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:disabled~.mdc-checkbox__background .mdc-checkbox__checkmark{color:var(--mdc-checkbox-disabled-selected-checkmark-color, #fff)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:disabled~.mdc-checkbox__background .mdc-checkbox__mixedmark{border-color:var(--mdc-checkbox-disabled-selected-checkmark-color, #fff)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786))}@keyframes mdc-checkbox-fade-in-background-8A000000FF01878600000000FF018786{0%{border-color:var(--mdc-checkbox-unselected-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}50%{border-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786))}}@keyframes mdc-checkbox-fade-out-background-8A000000FF01878600000000FF018786{0%,80%{border-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-icon-color, var(--mdc-theme-secondary, #018786))}100%{border-color:var(--mdc-checkbox-unselected-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}}.mat-mdc-checkbox .mdc-checkbox.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-in-background-8A000000FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-out-background-8A000000FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox:hover .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}.mat-mdc-checkbox .mdc-checkbox:hover .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:hover .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:hover .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786))}@keyframes mdc-checkbox-fade-in-background-FF018786FF01878600000000FF018786{0%{border-color:var(--mdc-checkbox-unselected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}50%{border-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786))}}@keyframes mdc-checkbox-fade-out-background-FF018786FF01878600000000FF018786{0%,80%{border-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-hover-icon-color, var(--mdc-theme-secondary, #018786))}100%{border-color:var(--mdc-checkbox-unselected-hover-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}}.mat-mdc-checkbox .mdc-checkbox:hover.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:hover.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-in-background-FF018786FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox:hover.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:hover.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-out-background-FF018786FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786))}@keyframes mdc-checkbox-fade-in-background-FF018786FF01878600000000FF018786{0%{border-color:var(--mdc-checkbox-unselected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}50%{border-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786))}}@keyframes mdc-checkbox-fade-out-background-FF018786FF01878600000000FF018786{0%,80%{border-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-focus-icon-color, var(--mdc-theme-secondary, #018786))}100%{border-color:var(--mdc-checkbox-unselected-focus-icon-color, var(--mdc-theme-secondary, #018786));background-color:transparent}}.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-in-background-FF018786FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox.mdc-ripple-upgraded--background-focused.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(.mdc-ripple-upgraded):focus.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-out-background-FF018786FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-pressed-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active .mdc-checkbox__native-control:enabled:checked~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active .mdc-checkbox__native-control:enabled:indeterminate~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active .mdc-checkbox__native-control[data-indeterminate=true]:enabled~.mdc-checkbox__background{border-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786))}@keyframes mdc-checkbox-fade-in-background-8A000000FF01878600000000FF018786{0%{border-color:var(--mdc-checkbox-unselected-pressed-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}50%{border-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786))}}@keyframes mdc-checkbox-fade-out-background-8A000000FF01878600000000FF018786{0%,80%{border-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786));background-color:var(--mdc-checkbox-selected-pressed-icon-color, var(--mdc-theme-secondary, #018786))}100%{border-color:var(--mdc-checkbox-unselected-pressed-icon-color, rgba(0, 0, 0, 0.54));background-color:transparent}}.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active.mdc-checkbox--anim-unchecked-checked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active.mdc-checkbox--anim-unchecked-indeterminate .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-in-background-8A000000FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active.mdc-checkbox--anim-checked-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background,.mat-mdc-checkbox .mdc-checkbox:not(:disabled):active.mdc-checkbox--anim-indeterminate-unchecked .mdc-checkbox__native-control:enabled~.mdc-checkbox__background{animation-name:mdc-checkbox-fade-out-background-8A000000FF01878600000000FF018786}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__background{top:calc((var(--mdc-checkbox-state-layer-size, 40px) - 18px) / 2);left:calc((var(--mdc-checkbox-state-layer-size, 40px) - 18px) / 2)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control{top:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2);right:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2);left:calc((var(--mdc-checkbox-state-layer-size, 40px) - var(--mdc-checkbox-state-layer-size, 40px)) / 2);width:var(--mdc-checkbox-state-layer-size, 40px);height:var(--mdc-checkbox-state-layer-size, 40px)}.mat-mdc-checkbox .mdc-checkbox:hover .mdc-checkbox__native-control:not([disabled])~.mdc-checkbox__ripple{opacity:.04;transform:scale(1);transition:opacity 80ms 0 cubic-bezier(0, 0, 0.2, 1),transform 80ms 0 cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-checkbox .mdc-checkbox .mdc-checkbox__native-control:not([disabled]):focus~.mdc-checkbox__ripple{opacity:.16}.mat-mdc-checkbox .mdc-checkbox__background{-webkit-print-color-adjust:exact;color-adjust:exact}.mat-mdc-checkbox._mat-animation-noopable *,.mat-mdc-checkbox._mat-animation-noopable *::before{transition:none !important;animation:none !important}.mat-mdc-checkbox label{cursor:pointer}.mat-mdc-checkbox.mat-mdc-checkbox-disabled label{cursor:default}.mat-mdc-checkbox label:empty{display:none}.mat-mdc-checkbox .mdc-checkbox__native-control:focus:enabled:not(:checked):not(:indeterminate):not([data-indeterminate=true])~.mdc-checkbox__background{border-color:var(--mdc-checkbox-unselected-focus-icon-color, black)}.cdk-high-contrast-active .mat-mdc-checkbox.mat-mdc-checkbox-disabled{opacity:.5}.cdk-high-contrast-active .mat-mdc-checkbox .mdc-checkbox__checkmark{--mdc-checkbox-selected-checkmark-color: CanvasText;--mdc-checkbox-disabled-selected-checkmark-color: CanvasText}.mat-mdc-checkbox .mdc-checkbox__ripple{opacity:0}.mat-mdc-checkbox-ripple,.mdc-checkbox__ripple{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:50%;pointer-events:none}.mat-mdc-checkbox-ripple:not(:empty),.mdc-checkbox__ripple:not(:empty){transform:translateZ(0)}.mat-mdc-checkbox-touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%)}.mat-mdc-checkbox-ripple::before{border-radius:50%}.mdc-checkbox__native-control:focus~.mat-mdc-focus-indicator::before{content:""}'],encapsulation:2,changeDetection:0}),n})(),xN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})(),Iq=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,$v,xN,rr,xN]}),n})();const Fq=["*"],Nq=new Ze("MAT_CARD_CONFIG");let Uw=(()=>{class n{constructor(t){this.appearance=t?.appearance||"raised"}}return n.\u0275fac=function(t){return new(t||n)(ie(Nq,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-card"]],hostAttrs:[1,"mat-mdc-card","mdc-card"],hostVars:4,hostBindings:function(t,i){2&t&&hi("mat-mdc-card-outlined","outlined"===i.appearance)("mdc-card--outlined","outlined"===i.appearance)},inputs:{appearance:"appearance"},exportAs:["matCard"],ngContentSelectors:Fq,decls:1,vars:0,template:function(t,i){1&t&&(Hs(),En(0))},styles:['.mdc-card{display:flex;flex-direction:column;box-sizing:border-box}.mdc-card::after{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none;pointer-events:none}@media screen and (forced-colors: active){.mdc-card::after{border-color:CanvasText}}.mdc-card--outlined::after{border:none}.mdc-card__content{border-radius:inherit;height:100%}.mdc-card__media{position:relative;box-sizing:border-box;background-repeat:no-repeat;background-position:center;background-size:cover}.mdc-card__media::before{display:block;content:""}.mdc-card__media:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}.mdc-card__media:last-child{border-bottom-left-radius:inherit;border-bottom-right-radius:inherit}.mdc-card__media--square::before{margin-top:100%}.mdc-card__media--16-9::before{margin-top:56.25%}.mdc-card__media-content{position:absolute;top:0;right:0;bottom:0;left:0;box-sizing:border-box}.mdc-card__primary-action{display:flex;flex-direction:column;box-sizing:border-box;position:relative;outline:none;color:inherit;text-decoration:none;cursor:pointer;overflow:hidden}.mdc-card__primary-action:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}.mdc-card__primary-action:last-child{border-bottom-left-radius:inherit;border-bottom-right-radius:inherit}.mdc-card__actions{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;min-height:52px;padding:8px}.mdc-card__actions--full-bleed{padding:0}.mdc-card__action-buttons,.mdc-card__action-icons{display:flex;flex-direction:row;align-items:center;box-sizing:border-box}.mdc-card__action-icons{flex-grow:1;justify-content:flex-end}.mdc-card__action-buttons+.mdc-card__action-icons{margin-left:16px;margin-right:0}[dir=rtl] .mdc-card__action-buttons+.mdc-card__action-icons,.mdc-card__action-buttons+.mdc-card__action-icons[dir=rtl]{margin-left:0;margin-right:16px}.mdc-card__action{display:inline-flex;flex-direction:row;align-items:center;box-sizing:border-box;justify-content:center;cursor:pointer;user-select:none}.mdc-card__action:focus{outline:none}.mdc-card__action--button{margin-left:0;margin-right:8px;padding:0 8px}[dir=rtl] .mdc-card__action--button,.mdc-card__action--button[dir=rtl]{margin-left:8px;margin-right:0}.mdc-card__action--button:last-child{margin-left:0;margin-right:0}[dir=rtl] .mdc-card__action--button:last-child,.mdc-card__action--button:last-child[dir=rtl]{margin-left:0;margin-right:0}.mdc-card__actions--full-bleed .mdc-card__action--button{justify-content:space-between;width:100%;height:auto;max-height:none;margin:0;padding:8px 16px;text-align:left}[dir=rtl] .mdc-card__actions--full-bleed .mdc-card__action--button,.mdc-card__actions--full-bleed .mdc-card__action--button[dir=rtl]{text-align:right}.mdc-card__action--icon{margin:-6px 0;padding:12px}.mat-mdc-card{position:relative;border-radius:var(--mdc-elevated-card-container-shape, var(--mdc-shape-medium, 4px));background-color:var(--mdc-elevated-card-container-color, transparent);border-width:0;border-style:solid;border-color:var(--mdc-elevated-card-container-color, transparent)}.mat-mdc-card .mdc-card::after{border-radius:var(--mdc-elevated-card-container-shape, var(--mdc-shape-medium, 4px))}.mat-mdc-card-outlined{border-width:var(--mdc-outlined-card-outline-width, 1px);border-style:solid;border-color:var(--mdc-outlined-card-outline-color, transparent)}.mat-mdc-card-title,.mat-mdc-card-subtitle{display:block;margin:0}.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-title,.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-subtitle{padding:16px 16px 0}.mat-mdc-card-header{display:flex;padding:16px 16px 0}.mat-mdc-card-content{display:block;padding:0 16px}.mat-mdc-card-content:first-child{padding-top:16px}.mat-mdc-card-content:last-child{padding-bottom:16px}.mat-mdc-card-title-group{display:flex;justify-content:space-between;width:100%}.mat-mdc-card-avatar{height:40px;width:40px;border-radius:50%;flex-shrink:0;margin-bottom:16px;object-fit:cover}.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-subtitle,.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-title{line-height:normal}.mat-mdc-card-sm-image{width:80px;height:80px}.mat-mdc-card-md-image{width:112px;height:112px}.mat-mdc-card-lg-image{width:152px;height:152px}.mat-mdc-card-xl-image{width:240px;height:240px}.mat-mdc-card-subtitle~.mat-mdc-card-title,.mat-mdc-card-title~.mat-mdc-card-subtitle,.mat-mdc-card-header .mat-mdc-card-header-text .mat-mdc-card-title,.mat-mdc-card-header .mat-mdc-card-header-text .mat-mdc-card-subtitle,.mat-mdc-card-title-group .mat-mdc-card-title,.mat-mdc-card-title-group .mat-mdc-card-subtitle{padding-top:0}.mat-mdc-card-content>:last-child:not(.mat-mdc-card-footer){margin-bottom:0}.mat-mdc-card-actions-align-end{justify-content:flex-end}'],encapsulation:2,changeDetection:0}),n})(),zT=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["mat-card-title"],["","mat-card-title",""],["","matCardTitle",""]],hostAttrs:[1,"mat-mdc-card-title"]}),n})(),GT=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["mat-card-subtitle"],["","mat-card-subtitle",""],["","matCardSubtitle",""]],hostAttrs:[1,"mat-mdc-card-subtitle"]}),n})(),Yq=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,ul,rr]}),n})();function jT(n,e,t,i){return qr(t)&&(i=t,t=void 0),i?jT(n,e,t).pipe(_t(r=>_i(r)?i(...r):i(r))):new un(r=>{wN(n,e,function s(o){r.next(arguments.length>1?Array.prototype.slice.call(arguments):o)},r,t)})}function wN(n,e,t,i,r){let s;if(function Jq(n){return n&&"function"==typeof n.addEventListener&&"function"==typeof n.removeEventListener}(n)){const o=n;n.addEventListener(e,t,r),s=()=>o.removeEventListener(e,t,r)}else if(function Zq(n){return n&&"function"==typeof n.on&&"function"==typeof n.off}(n)){const o=n;n.on(e,t),s=()=>o.off(e,t)}else if(function Xq(n){return n&&"function"==typeof n.addListener&&"function"==typeof n.removeListener}(n)){const o=n;n.addListener(e,t),s=()=>o.removeListener(e,t)}else{if(!n||!n.length)throw new TypeError("Invalid event target");for(let o=0,a=n.length;o0?super.requestAsyncId(e,t,i):(e.actions.push(this),e.scheduled||(e.scheduled=requestAnimationFrame(()=>e.flush(null))))}recycleAsyncId(e,t,i=0){if(null!==i&&i>0||null===i&&this.delay>0)return super.recycleAsyncId(e,t,i);0===e.actions.length&&(cancelAnimationFrame(t),e.scheduled=void 0)}});let nK=1;const iK=Promise.resolve(),zw={};function SN(n){return n in zw&&(delete zw[n],!0)}const EN={setImmediate(n){const e=nK++;return zw[e]=!0,iK.then(()=>SN(e)&&n()),e},clearImmediate(n){SN(n)}},oK=new class sK extends Kl{flush(e){this.active=!0,this.scheduled=void 0;const{actions:t}=this;let i,r=-1,s=t.length;e=e||t.shift();do{if(i=e.execute(e.state,e.delay))break}while(++r0?super.requestAsyncId(e,t,i):(e.actions.push(this),e.scheduled||(e.scheduled=EN.setImmediate(e.flush.bind(e,null))))}recycleAsyncId(e,t,i=0){if(null!==i&&i>0||null===i&&this.delay>0)return super.recycleAsyncId(e,t,i);0===e.actions.length&&(EN.clearImmediate(t),e.scheduled=void 0)}});class cK{constructor(e){this.durationSelector=e}call(e,t){return t.subscribe(new lK(e,this.durationSelector))}}class lK extends Fs{constructor(e,t){super(e),this.durationSelector=t,this.hasValue=!1}_next(e){if(this.value=e,this.hasValue=!0,!this.throttled){let t;try{const{durationSelector:r}=this;t=r(e)}catch(r){return this.destination.error(r)}const i=$o(this,t);!i||i.closed?this.clearThrottle():this.add(this.throttled=i)}}clearThrottle(){const{value:e,hasValue:t,throttled:i}=this;i&&(this.remove(i),this.throttled=null,i.unsubscribe()),t&&(this.value=null,this.hasValue=!1,this.destination.next(e))}notifyNext(e,t,i,r){this.clearThrottle()}notifyComplete(){this.clearThrottle()}}function MN(n){return!_i(n)&&n-parseFloat(n)+1>=0}function uK(n){const{index:e,period:t,subscriber:i}=n;if(i.next(e),!i.closed){if(-1===t)return i.complete();n.index=e+1,this.schedule(n,t)}}function WT(n,e=ag){return function aK(n){return function(t){return t.lift(new cK(n))}}(()=>function dK(n=0,e,t){let i=-1;return MN(e)?i=Number(e)<1?1:Number(e):cc(e)&&(t=e),cc(t)||(t=ag),new un(r=>{const s=MN(n)?n:+n-t.now();return t.schedule(uK,s,{index:0,period:i,subscriber:r})})}(n,e))}const hK=["contentWrapper"],fK=["*"],pK=new Ze("VIRTUAL_SCROLL_STRATEGY");let qv=(()=>{class n{constructor(t,i,r){this._ngZone=t,this._platform=i,this._scrolled=new cn,this._globalSubscription=null,this._scrolledCount=0,this.scrollContainers=new Map,this._document=r}register(t){this.scrollContainers.has(t)||this.scrollContainers.set(t,t.elementScrolled().subscribe(()=>this._scrolled.next(t)))}deregister(t){const i=this.scrollContainers.get(t);i&&(i.unsubscribe(),this.scrollContainers.delete(t))}scrolled(t=20){return this._platform.isBrowser?new un(i=>{this._globalSubscription||this._addGlobalListener();const r=t>0?this._scrolled.pipe(WT(t)).subscribe(i):this._scrolled.subscribe(i);return this._scrolledCount++,()=>{r.unsubscribe(),this._scrolledCount--,this._scrolledCount||this._removeGlobalListener()}}):Tt()}ngOnDestroy(){this._removeGlobalListener(),this.scrollContainers.forEach((t,i)=>this.deregister(i)),this._scrolled.complete()}ancestorScrolled(t,i){const r=this.getAncestorScrollContainers(t);return this.scrolled(i).pipe(Ui(s=>!s||r.indexOf(s)>-1))}getAncestorScrollContainers(t){const i=[];return this.scrollContainers.forEach((r,s)=>{this._scrollableContainsElement(s,t)&&i.push(s)}),i}_getWindow(){return this._document.defaultView||window}_scrollableContainsElement(t,i){let r=Nf(i),s=t.getElementRef().nativeElement;do{if(r==s)return!0}while(r=r.parentElement);return!1}_addGlobalListener(){this._globalSubscription=this._ngZone.runOutsideAngular(()=>jT(this._getWindow().document,"scroll").subscribe(()=>this._scrolled.next()))}_removeGlobalListener(){this._globalSubscription&&(this._globalSubscription.unsubscribe(),this._globalSubscription=null)}}return n.\u0275fac=function(t){return new(t||n)(xe(Xt),xe(as),xe(Mn,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),CN=(()=>{class n{constructor(t,i,r,s){this.elementRef=t,this.scrollDispatcher=i,this.ngZone=r,this.dir=s,this._destroyed=new cn,this._elementScrolled=new un(o=>this.ngZone.runOutsideAngular(()=>jT(this.elementRef.nativeElement,"scroll").pipe(Tr(this._destroyed)).subscribe(o)))}ngOnInit(){this.scrollDispatcher.register(this)}ngOnDestroy(){this.scrollDispatcher.deregister(this),this._destroyed.next(),this._destroyed.complete()}elementScrolled(){return this._elementScrolled}getElementRef(){return this.elementRef}scrollTo(t){const i=this.elementRef.nativeElement,r=this.dir&&"rtl"==this.dir.value;null==t.left&&(t.left=r?t.end:t.start),null==t.right&&(t.right=r?t.start:t.end),null!=t.bottom&&(t.top=i.scrollHeight-i.clientHeight-t.bottom),r&&0!=Hv()?(null!=t.left&&(t.right=i.scrollWidth-i.clientWidth-t.left),2==Hv()?t.left=t.right:1==Hv()&&(t.left=t.right?-t.right:t.right)):null!=t.right&&(t.left=i.scrollWidth-i.clientWidth-t.right),this._applyScrollToOptions(t)}_applyScrollToOptions(t){const i=this.elementRef.nativeElement;SL()?i.scrollTo(t):(null!=t.top&&(i.scrollTop=t.top),null!=t.left&&(i.scrollLeft=t.left))}measureScrollOffset(t){const i="left",r="right",s=this.elementRef.nativeElement;if("top"==t)return s.scrollTop;if("bottom"==t)return s.scrollHeight-s.clientHeight-s.scrollTop;const o=this.dir&&"rtl"==this.dir.value;return"start"==t?t=o?r:i:"end"==t&&(t=o?i:r),o&&2==Hv()?t==i?s.scrollWidth-s.clientWidth-s.scrollLeft:s.scrollLeft:o&&1==Hv()?t==i?s.scrollLeft+s.scrollWidth-s.clientWidth:-s.scrollLeft:t==i?s.scrollLeft:s.scrollWidth-s.clientWidth-s.scrollLeft}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(qv),ie(Xt),ie(Yl,8))},n.\u0275dir=ut({type:n,selectors:[["","cdk-scrollable",""],["","cdkScrollable",""]],standalone:!0}),n})(),Gw=(()=>{class n{constructor(t,i,r){this._platform=t,this._change=new cn,this._changeListener=s=>{this._change.next(s)},this._document=r,i.runOutsideAngular(()=>{if(t.isBrowser){const s=this._getWindow();s.addEventListener("resize",this._changeListener),s.addEventListener("orientationchange",this._changeListener)}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){if(this._platform.isBrowser){const t=this._getWindow();t.removeEventListener("resize",this._changeListener),t.removeEventListener("orientationchange",this._changeListener)}this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();const t={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),t}getViewportRect(){const t=this.getViewportScrollPosition(),{width:i,height:r}=this.getViewportSize();return{top:t.top,left:t.left,bottom:t.top+r,right:t.left+i,height:r,width:i}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};const t=this._document,i=this._getWindow(),r=t.documentElement,s=r.getBoundingClientRect();return{top:-s.top||t.body.scrollTop||i.scrollY||r.scrollTop||0,left:-s.left||t.body.scrollLeft||i.scrollX||r.scrollLeft||0}}change(t=20){return t>0?this._change.pipe(WT(t)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){const t=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:t.innerWidth,height:t.innerHeight}:{width:0,height:0}}}return n.\u0275fac=function(t){return new(t||n)(xe(as),xe(Xt),xe(Mn,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const DN=new Ze("VIRTUAL_SCROLLABLE");let _K=(()=>{class n extends CN{constructor(t,i,r,s){super(t,i,r,s)}measureViewportSize(t){const i=this.elementRef.nativeElement;return"horizontal"===t?i.clientWidth:i.clientHeight}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(qv),ie(Xt),ie(Yl,8))},n.\u0275dir=ut({type:n,features:[Z]}),n})();const yK=typeof requestAnimationFrame<"u"?tK:oK;let bK=(()=>{class n extends _K{get orientation(){return this._orientation}set orientation(t){this._orientation!==t&&(this._orientation=t,this._calculateSpacerSize())}get appendOnly(){return this._appendOnly}set appendOnly(t){this._appendOnly=bi(t)}constructor(t,i,r,s,o,a,c,u){super(t,a,r,o),this.elementRef=t,this._changeDetectorRef=i,this._scrollStrategy=s,this.scrollable=u,this._platform=hn(as),this._detachedSubject=new cn,this._renderedRangeSubject=new cn,this._orientation="vertical",this._appendOnly=!1,this.scrolledIndexChange=new un(p=>this._scrollStrategy.scrolledIndexChange.subscribe(g=>Promise.resolve().then(()=>this.ngZone.run(()=>p.next(g))))),this.renderedRangeStream=this._renderedRangeSubject,this._totalContentSize=0,this._totalContentWidth="",this._totalContentHeight="",this._renderedRange={start:0,end:0},this._dataLength=0,this._viewportSize=0,this._renderedContentOffset=0,this._renderedContentOffsetNeedsRewrite=!1,this._isChangeDetectionPending=!1,this._runAfterChangeDetection=[],this._viewportChanges=Tn.EMPTY,this._viewportChanges=c.change().subscribe(()=>{this.checkViewportSize()}),this.scrollable||(this.elementRef.nativeElement.classList.add("cdk-virtual-scrollable"),this.scrollable=this)}ngOnInit(){this._platform.isBrowser&&(this.scrollable===this&&super.ngOnInit(),this.ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>{this._measureViewportSize(),this._scrollStrategy.attach(this),this.scrollable.elementScrolled().pipe(Bf(null),WT(0,yK)).subscribe(()=>this._scrollStrategy.onContentScrolled()),this._markChangeDetectionNeeded()})))}ngOnDestroy(){this.detach(),this._scrollStrategy.detach(),this._renderedRangeSubject.complete(),this._detachedSubject.complete(),this._viewportChanges.unsubscribe(),super.ngOnDestroy()}attach(t){this.ngZone.runOutsideAngular(()=>{this._forOf=t,this._forOf.dataStream.pipe(Tr(this._detachedSubject)).subscribe(i=>{const r=i.length;r!==this._dataLength&&(this._dataLength=r,this._scrollStrategy.onDataLengthChanged()),this._doChangeDetection()})})}detach(){this._forOf=null,this._detachedSubject.next()}getDataLength(){return this._dataLength}getViewportSize(){return this._viewportSize}getRenderedRange(){return this._renderedRange}measureBoundingClientRectWithScrollOffset(t){return this.getElementRef().nativeElement.getBoundingClientRect()[t]}setTotalContentSize(t){this._totalContentSize!==t&&(this._totalContentSize=t,this._calculateSpacerSize(),this._markChangeDetectionNeeded())}setRenderedRange(t){(function vK(n,e){return n.start==e.start&&n.end==e.end})(this._renderedRange,t)||(this.appendOnly&&(t={start:0,end:Math.max(this._renderedRange.end,t.end)}),this._renderedRangeSubject.next(this._renderedRange=t),this._markChangeDetectionNeeded(()=>this._scrollStrategy.onContentRendered()))}getOffsetToRenderedContentStart(){return this._renderedContentOffsetNeedsRewrite?null:this._renderedContentOffset}setRenderedContentOffset(t,i="to-start"){t=this.appendOnly&&"to-start"===i?0:t;const s="horizontal"==this.orientation,o=s?"X":"Y";let c=`translate${o}(${Number((s&&this.dir&&"rtl"==this.dir.value?-1:1)*t)}px)`;this._renderedContentOffset=t,"to-end"===i&&(c+=` translate${o}(-100%)`,this._renderedContentOffsetNeedsRewrite=!0),this._renderedContentTransform!=c&&(this._renderedContentTransform=c,this._markChangeDetectionNeeded(()=>{this._renderedContentOffsetNeedsRewrite?(this._renderedContentOffset-=this.measureRenderedContentSize(),this._renderedContentOffsetNeedsRewrite=!1,this.setRenderedContentOffset(this._renderedContentOffset)):this._scrollStrategy.onRenderedOffsetChanged()}))}scrollToOffset(t,i="auto"){const r={behavior:i};"horizontal"===this.orientation?r.start=t:r.top=t,this.scrollable.scrollTo(r)}scrollToIndex(t,i="auto"){this._scrollStrategy.scrollToIndex(t,i)}measureScrollOffset(t){let i;return i=this.scrollable==this?r=>super.measureScrollOffset(r):r=>this.scrollable.measureScrollOffset(r),Math.max(0,i(t??("horizontal"===this.orientation?"start":"top"))-this.measureViewportOffset())}measureViewportOffset(t){let i;const r="left",s="right",o="rtl"==this.dir?.value;i="start"==t?o?s:r:"end"==t?o?r:s:t||("horizontal"===this.orientation?"left":"top");const a=this.scrollable.measureBoundingClientRectWithScrollOffset(i);return this.elementRef.nativeElement.getBoundingClientRect()[i]-a}measureRenderedContentSize(){const t=this._contentWrapper.nativeElement;return"horizontal"===this.orientation?t.offsetWidth:t.offsetHeight}measureRangeSize(t){return this._forOf?this._forOf.measureRangeSize(t,this.orientation):0}checkViewportSize(){this._measureViewportSize(),this._scrollStrategy.onDataLengthChanged()}_measureViewportSize(){this._viewportSize=this.scrollable.measureViewportSize(this.orientation)}_markChangeDetectionNeeded(t){t&&this._runAfterChangeDetection.push(t),this._isChangeDetectionPending||(this._isChangeDetectionPending=!0,this.ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>{this._doChangeDetection()})))}_doChangeDetection(){this._isChangeDetectionPending=!1,this._contentWrapper.nativeElement.style.transform=this._renderedContentTransform,this.ngZone.run(()=>this._changeDetectorRef.markForCheck());const t=this._runAfterChangeDetection;this._runAfterChangeDetection=[];for(const i of t)i()}_calculateSpacerSize(){this._totalContentHeight="horizontal"===this.orientation?"":`${this._totalContentSize}px`,this._totalContentWidth="horizontal"===this.orientation?`${this._totalContentSize}px`:""}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(aa),ie(Xt),ie(pK,8),ie(Yl,8),ie(qv),ie(Gw),ie(DN,8))},n.\u0275cmp=Ln({type:n,selectors:[["cdk-virtual-scroll-viewport"]],viewQuery:function(t,i){if(1&t&&zr(hK,7),2&t){let r;Yn(r=Xn())&&(i._contentWrapper=r.first)}},hostAttrs:[1,"cdk-virtual-scroll-viewport"],hostVars:4,hostBindings:function(t,i){2&t&&hi("cdk-virtual-scroll-orientation-horizontal","horizontal"===i.orientation)("cdk-virtual-scroll-orientation-vertical","horizontal"!==i.orientation)},inputs:{orientation:"orientation",appendOnly:"appendOnly"},outputs:{scrolledIndexChange:"scrolledIndexChange"},standalone:!0,features:[Oi([{provide:CN,useFactory:(e,t)=>e||t,deps:[[new ba,new af(DN)],n]}]),Z,_v],ngContentSelectors:fK,decls:4,vars:4,consts:[[1,"cdk-virtual-scroll-content-wrapper"],["contentWrapper",""],[1,"cdk-virtual-scroll-spacer"]],template:function(t,i){1&t&&(Hs(),ke(0,"div",0,1),En(2),Ne(),qt(3,"div",2)),2&t&&(Le(3),dv("width",i._totalContentWidth)("height",i._totalContentHeight))},styles:["cdk-virtual-scroll-viewport{display:block;position:relative;transform:translateZ(0)}.cdk-virtual-scrollable{overflow:auto;will-change:scroll-position;contain:strict;-webkit-overflow-scrolling:touch}.cdk-virtual-scroll-content-wrapper{position:absolute;top:0;left:0;contain:content}[dir=rtl] .cdk-virtual-scroll-content-wrapper{right:0;left:auto}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper{min-height:100%}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-left:0;padding-right:0;margin-left:0;margin-right:0;border-left-width:0;border-right-width:0;outline:none}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper{min-width:100%}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-top:0;padding-bottom:0;margin-top:0;margin-bottom:0;border-top-width:0;border-bottom-width:0;outline:none}.cdk-virtual-scroll-spacer{height:1px;transform-origin:0 0;flex:0 0 auto}[dir=rtl] .cdk-virtual-scroll-spacer{transform-origin:100% 0}"],encapsulation:2,changeDetection:0}),n})(),jw=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})(),TN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[jv,jw,bK,jv,jw]}),n})();class $T{attach(e){return this._attachedHost=e,e.attach(this)}detach(){let e=this._attachedHost;null!=e&&(this._attachedHost=null,e.detach())}get isAttached(){return null!=this._attachedHost}setAttachedHost(e){this._attachedHost=e}}class Ww extends $T{constructor(e,t,i,r,s){super(),this.component=e,this.viewContainerRef=t,this.injector=i,this.componentFactoryResolver=r,this.projectableNodes=s}}class qT extends $T{constructor(e,t,i,r){super(),this.templateRef=e,this.viewContainerRef=t,this.context=i,this.injector=r}get origin(){return this.templateRef.elementRef}attach(e,t=this.context){return this.context=t,super.attach(e)}detach(){return this.context=void 0,super.detach()}}class xK extends $T{constructor(e){super(),this.element=e instanceof _n?e.nativeElement:e}}class KT{constructor(){this._isDisposed=!1,this.attachDomPortal=null}hasAttached(){return!!this._attachedPortal}attach(e){return e instanceof Ww?(this._attachedPortal=e,this.attachComponentPortal(e)):e instanceof qT?(this._attachedPortal=e,this.attachTemplatePortal(e)):this.attachDomPortal&&e instanceof xK?(this._attachedPortal=e,this.attachDomPortal(e)):void 0}detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(e){this._disposeFn=e}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}}class wK extends KT{constructor(e,t,i,r,s){super(),this.outletElement=e,this._componentFactoryResolver=t,this._appRef=i,this._defaultInjector=r,this.attachDomPortal=o=>{const a=o.element,c=this._document.createComment("dom-portal");a.parentNode.insertBefore(c,a),this.outletElement.appendChild(a),this._attachedPortal=o,super.setDisposeFn(()=>{c.parentNode&&c.parentNode.replaceChild(a,c)})},this._document=s}attachComponentPortal(e){const i=(e.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(e.component);let r;return e.viewContainerRef?(r=e.viewContainerRef.createComponent(i,e.viewContainerRef.length,e.injector||e.viewContainerRef.injector,e.projectableNodes||void 0),this.setDisposeFn(()=>r.destroy())):(r=i.create(e.injector||this._defaultInjector||ts.NULL),this._appRef.attachView(r.hostView),this.setDisposeFn(()=>{this._appRef.viewCount>0&&this._appRef.detachView(r.hostView),r.destroy()})),this.outletElement.appendChild(this._getComponentRootNode(r)),this._attachedPortal=e,r}attachTemplatePortal(e){let t=e.viewContainerRef,i=t.createEmbeddedView(e.templateRef,e.context,{injector:e.injector});return i.rootNodes.forEach(r=>this.outletElement.appendChild(r)),i.detectChanges(),this.setDisposeFn(()=>{let r=t.indexOf(i);-1!==r&&t.remove(r)}),this._attachedPortal=e,i}dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(e){return e.hostView.rootNodes[0]}}let $w=(()=>{class n extends KT{constructor(t,i,r){super(),this._componentFactoryResolver=t,this._viewContainerRef=i,this._isInitialized=!1,this.attached=new Pn,this.attachDomPortal=s=>{const o=s.element,a=this._document.createComment("dom-portal");s.setAttachedHost(this),o.parentNode.insertBefore(a,o),this._getRootNode().appendChild(o),this._attachedPortal=s,super.setDisposeFn(()=>{a.parentNode&&a.parentNode.replaceChild(o,a)})},this._document=r}get portal(){return this._attachedPortal}set portal(t){this.hasAttached()&&!t&&!this._isInitialized||(this.hasAttached()&&super.detach(),t&&super.attach(t),this._attachedPortal=t||null)}get attachedRef(){return this._attachedRef}ngOnInit(){this._isInitialized=!0}ngOnDestroy(){super.dispose(),this._attachedRef=this._attachedPortal=null}attachComponentPortal(t){t.setAttachedHost(this);const i=null!=t.viewContainerRef?t.viewContainerRef:this._viewContainerRef,s=(t.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(t.component),o=i.createComponent(s,i.length,t.injector||i.injector,t.projectableNodes||void 0);return i!==this._viewContainerRef&&this._getRootNode().appendChild(o.hostView.rootNodes[0]),super.setDisposeFn(()=>o.destroy()),this._attachedPortal=t,this._attachedRef=o,this.attached.emit(o),o}attachTemplatePortal(t){t.setAttachedHost(this);const i=this._viewContainerRef.createEmbeddedView(t.templateRef,t.context,{injector:t.injector});return super.setDisposeFn(()=>this._viewContainerRef.clear()),this._attachedPortal=t,this._attachedRef=i,this.attached.emit(i),i}_getRootNode(){const t=this._viewContainerRef.element.nativeElement;return t.nodeType===t.ELEMENT_NODE?t:t.parentNode}}return n.\u0275fac=function(t){return new(t||n)(ie(Fd),ie(Sa),ie(Mn))},n.\u0275dir=ut({type:n,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:["cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[Z]}),n})(),Kv=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({}),n})();function AN(n,e=!1){return t=>t.lift(new SK(n,e))}class SK{constructor(e,t){this.predicate=e,this.inclusive=t}call(e,t){return t.subscribe(new EK(e,this.predicate,this.inclusive))}}class EK extends di{constructor(e,t,i){super(e),this.predicate=t,this.inclusive=i,this.index=0}_next(e){const t=this.destination;let i;try{i=this.predicate(e,this.index++)}catch(r){return void t.error(r)}this.nextOrComplete(e,i)}nextOrComplete(e,t){const i=this.destination;Boolean(t)?i.next(e):(this.inclusive&&i.next(e),i.complete())}}const kN=SL();class MK{constructor(e,t){this._viewportRuler=e,this._previousHTMLStyles={top:"",left:""},this._isEnabled=!1,this._document=t}attach(){}enable(){if(this._canBeEnabled()){const e=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=e.style.left||"",this._previousHTMLStyles.top=e.style.top||"",e.style.left=Cs(-this._previousScrollPosition.left),e.style.top=Cs(-this._previousScrollPosition.top),e.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}disable(){if(this._isEnabled){const e=this._document.documentElement,i=e.style,r=this._document.body.style,s=i.scrollBehavior||"",o=r.scrollBehavior||"";this._isEnabled=!1,i.left=this._previousHTMLStyles.left,i.top=this._previousHTMLStyles.top,e.classList.remove("cdk-global-scrollblock"),kN&&(i.scrollBehavior=r.scrollBehavior="auto"),window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),kN&&(i.scrollBehavior=s,r.scrollBehavior=o)}}_canBeEnabled(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;const t=this._document.body,i=this._viewportRuler.getViewportSize();return t.scrollHeight>i.height||t.scrollWidth>i.width}}class CK{constructor(e,t,i,r){this._scrollDispatcher=e,this._ngZone=t,this._viewportRuler=i,this._config=r,this._scrollSubscription=null,this._detach=()=>{this.disable(),this._overlayRef.hasAttached()&&this._ngZone.run(()=>this._overlayRef.detach())}}attach(e){this._overlayRef=e}enable(){if(this._scrollSubscription)return;const e=this._scrollDispatcher.scrolled(0);this._config&&this._config.threshold&&this._config.threshold>1?(this._initialScrollPosition=this._viewportRuler.getViewportScrollPosition().top,this._scrollSubscription=e.subscribe(()=>{const t=this._viewportRuler.getViewportScrollPosition().top;Math.abs(t-this._initialScrollPosition)>this._config.threshold?this._detach():this._overlayRef.updatePosition()})):this._scrollSubscription=e.subscribe(this._detach)}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}}class IN{enable(){}disable(){}attach(){}}function YT(n,e){return e.some(t=>n.bottomt.bottom||n.rightt.right)}function FN(n,e){return e.some(t=>n.topt.bottom||n.leftt.right)}class DK{constructor(e,t,i,r){this._scrollDispatcher=e,this._viewportRuler=t,this._ngZone=i,this._config=r,this._scrollSubscription=null}attach(e){this._overlayRef=e}enable(){this._scrollSubscription||(this._scrollSubscription=this._scrollDispatcher.scrolled(this._config?this._config.scrollThrottle:0).subscribe(()=>{if(this._overlayRef.updatePosition(),this._config&&this._config.autoClose){const t=this._overlayRef.overlayElement.getBoundingClientRect(),{width:i,height:r}=this._viewportRuler.getViewportSize();YT(t,[{width:i,height:r,bottom:r,right:i,top:0,left:0}])&&(this.disable(),this._ngZone.run(()=>this._overlayRef.detach()))}}))}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}}let TK=(()=>{class n{constructor(t,i,r,s){this._scrollDispatcher=t,this._viewportRuler=i,this._ngZone=r,this.noop=()=>new IN,this.close=o=>new CK(this._scrollDispatcher,this._ngZone,this._viewportRuler,o),this.block=()=>new MK(this._viewportRuler,this._document),this.reposition=o=>new DK(this._scrollDispatcher,this._viewportRuler,this._ngZone,o),this._document=s}}return n.\u0275fac=function(t){return new(t||n)(xe(qv),xe(Gw),xe(Xt),xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();class XT{constructor(e){if(this.scrollStrategy=new IN,this.panelClass="",this.hasBackdrop=!1,this.backdropClass="cdk-overlay-dark-backdrop",this.disposeOnNavigation=!1,e){const t=Object.keys(e);for(const i of t)void 0!==e[i]&&(this[i]=e[i])}}}class AK{constructor(e,t){this.connectionPair=e,this.scrollableViewProperties=t}}let RN=(()=>{class n{constructor(t){this._attachedOverlays=[],this._document=t}ngOnDestroy(){this.detach()}add(t){this.remove(t),this._attachedOverlays.push(t)}remove(t){const i=this._attachedOverlays.indexOf(t);i>-1&&this._attachedOverlays.splice(i,1),0===this._attachedOverlays.length&&this.detach()}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),kK=(()=>{class n extends RN{constructor(t,i){super(t),this._ngZone=i,this._keydownListener=r=>{const s=this._attachedOverlays;for(let o=s.length-1;o>-1;o--)if(s[o]._keydownEvents.observers.length>0){const a=s[o]._keydownEvents;this._ngZone?this._ngZone.run(()=>a.next(r)):a.next(r);break}}}add(t){super.add(t),this._isAttached||(this._ngZone?this._ngZone.runOutsideAngular(()=>this._document.body.addEventListener("keydown",this._keydownListener)):this._document.body.addEventListener("keydown",this._keydownListener),this._isAttached=!0)}detach(){this._isAttached&&(this._document.body.removeEventListener("keydown",this._keydownListener),this._isAttached=!1)}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn),xe(Xt,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),IK=(()=>{class n extends RN{constructor(t,i,r){super(t),this._platform=i,this._ngZone=r,this._cursorStyleIsSet=!1,this._pointerDownListener=s=>{this._pointerDownEventTarget=th(s)},this._clickListener=s=>{const o=th(s),a="click"===s.type&&this._pointerDownEventTarget?this._pointerDownEventTarget:o;this._pointerDownEventTarget=null;const c=this._attachedOverlays.slice();for(let u=c.length-1;u>-1;u--){const p=c[u];if(p._outsidePointerEvents.observers.length<1||!p.hasAttached())continue;if(p.overlayElement.contains(o)||p.overlayElement.contains(a))break;const g=p._outsidePointerEvents;this._ngZone?this._ngZone.run(()=>g.next(s)):g.next(s)}}}add(t){if(super.add(t),!this._isAttached){const i=this._document.body;this._ngZone?this._ngZone.runOutsideAngular(()=>this._addEventListeners(i)):this._addEventListeners(i),this._platform.IOS&&!this._cursorStyleIsSet&&(this._cursorOriginalValue=i.style.cursor,i.style.cursor="pointer",this._cursorStyleIsSet=!0),this._isAttached=!0}}detach(){if(this._isAttached){const t=this._document.body;t.removeEventListener("pointerdown",this._pointerDownListener,!0),t.removeEventListener("click",this._clickListener,!0),t.removeEventListener("auxclick",this._clickListener,!0),t.removeEventListener("contextmenu",this._clickListener,!0),this._platform.IOS&&this._cursorStyleIsSet&&(t.style.cursor=this._cursorOriginalValue,this._cursorStyleIsSet=!1),this._isAttached=!1}}_addEventListeners(t){t.addEventListener("pointerdown",this._pointerDownListener,!0),t.addEventListener("click",this._clickListener,!0),t.addEventListener("auxclick",this._clickListener,!0),t.addEventListener("contextmenu",this._clickListener,!0)}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn),xe(as),xe(Xt,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),qw=(()=>{class n{constructor(t,i){this._platform=i,this._document=t}ngOnDestroy(){this._containerElement?.remove()}getContainerElement(){return this._containerElement||this._createContainer(),this._containerElement}_createContainer(){const t="cdk-overlay-container";if(this._platform.isBrowser||CT()){const r=this._document.querySelectorAll(`.${t}[platform="server"], .${t}[platform="test"]`);for(let s=0;sthis._backdropClick.next(g),this._backdropTransitionendHandler=g=>{this._disposeBackdrop(g.target)},this._keydownEvents=new cn,this._outsidePointerEvents=new cn,r.scrollStrategy&&(this._scrollStrategy=r.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=r.positionStrategy}get overlayElement(){return this._pane}get backdropElement(){return this._backdropElement}get hostElement(){return this._host}attach(e){!this._host.parentElement&&this._previousHostParent&&this._previousHostParent.appendChild(this._host);const t=this._portalOutlet.attach(e);return this._positionStrategy&&this._positionStrategy.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._ngZone.onStable.pipe(Gr(1)).subscribe(()=>{this.hasAttached()&&this.updatePosition()}),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&(this._locationChanges=this._location.subscribe(()=>this.dispose())),this._outsideClickDispatcher.add(this),"function"==typeof t?.onDestroy&&t.onDestroy(()=>{this.hasAttached()&&this._ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>this.detach()))}),t}detach(){if(!this.hasAttached())return;this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();const e=this._portalOutlet.detach();return this._detachments.next(),this._keyboardDispatcher.remove(this),this._detachContentWhenStable(),this._locationChanges.unsubscribe(),this._outsideClickDispatcher.remove(this),e}dispose(){const e=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this._disposeBackdrop(this._backdropElement),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._outsidePointerEvents.complete(),this._outsideClickDispatcher.remove(this),this._host?.remove(),this._previousHostParent=this._pane=this._host=null,e&&this._detachments.next(),this._detachments.complete()}hasAttached(){return this._portalOutlet.hasAttached()}backdropClick(){return this._backdropClick}attachments(){return this._attachments}detachments(){return this._detachments}keydownEvents(){return this._keydownEvents}outsidePointerEvents(){return this._outsidePointerEvents}getConfig(){return this._config}updatePosition(){this._positionStrategy&&this._positionStrategy.apply()}updatePositionStrategy(e){e!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=e,this.hasAttached()&&(e.attach(this),this.updatePosition()))}updateSize(e){this._config={...this._config,...e},this._updateElementSize()}setDirection(e){this._config={...this._config,direction:e},this._updateElementDirection()}addPanelClass(e){this._pane&&this._toggleClasses(this._pane,e,!0)}removePanelClass(e){this._pane&&this._toggleClasses(this._pane,e,!1)}getDirection(){const e=this._config.direction;return e?"string"==typeof e?e:e.value:"ltr"}updateScrollStrategy(e){e!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=e,this.hasAttached()&&(e.attach(this),e.enable()))}_updateElementDirection(){this._host.setAttribute("dir",this.getDirection())}_updateElementSize(){if(!this._pane)return;const e=this._pane.style;e.width=Cs(this._config.width),e.height=Cs(this._config.height),e.minWidth=Cs(this._config.minWidth),e.minHeight=Cs(this._config.minHeight),e.maxWidth=Cs(this._config.maxWidth),e.maxHeight=Cs(this._config.maxHeight)}_togglePointerEvents(e){this._pane.style.pointerEvents=e?"":"none"}_attachBackdrop(){const e="cdk-overlay-backdrop-showing";this._backdropElement=this._document.createElement("div"),this._backdropElement.classList.add("cdk-overlay-backdrop"),this._animationsDisabled&&this._backdropElement.classList.add("cdk-overlay-backdrop-noop-animation"),this._config.backdropClass&&this._toggleClasses(this._backdropElement,this._config.backdropClass,!0),this._host.parentElement.insertBefore(this._backdropElement,this._host),this._backdropElement.addEventListener("click",this._backdropClickHandler),!this._animationsDisabled&&typeof requestAnimationFrame<"u"?this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>{this._backdropElement&&this._backdropElement.classList.add(e)})}):this._backdropElement.classList.add(e)}_updateStackingOrder(){this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}detachBackdrop(){const e=this._backdropElement;if(e){if(this._animationsDisabled)return void this._disposeBackdrop(e);e.classList.remove("cdk-overlay-backdrop-showing"),this._ngZone.runOutsideAngular(()=>{e.addEventListener("transitionend",this._backdropTransitionendHandler)}),e.style.pointerEvents="none",this._backdropTimeout=this._ngZone.runOutsideAngular(()=>setTimeout(()=>{this._disposeBackdrop(e)},500))}}_toggleClasses(e,t,i){const r=Iw(t||[]).filter(s=>!!s);r.length&&(i?e.classList.add(...r):e.classList.remove(...r))}_detachContentWhenStable(){this._ngZone.runOutsideAngular(()=>{const e=this._ngZone.onStable.pipe(Tr(fa(this._attachments,this._detachments))).subscribe(()=>{(!this._pane||!this._host||0===this._pane.children.length)&&(this._pane&&this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!1),this._host&&this._host.parentElement&&(this._previousHostParent=this._host.parentElement,this._host.remove()),e.unsubscribe())})})}_disposeScrollStrategy(){const e=this._scrollStrategy;e&&(e.disable(),e.detach&&e.detach())}_disposeBackdrop(e){e&&(e.removeEventListener("click",this._backdropClickHandler),e.removeEventListener("transitionend",this._backdropTransitionendHandler),e.remove(),this._backdropElement===e&&(this._backdropElement=null)),this._backdropTimeout&&(clearTimeout(this._backdropTimeout),this._backdropTimeout=void 0)}}const PN="cdk-overlay-connected-position-bounding-box",FK=/([A-Za-z%]+)$/;class RK{get positions(){return this._preferredPositions}constructor(e,t,i,r,s){this._viewportRuler=t,this._document=i,this._platform=r,this._overlayContainer=s,this._lastBoundingBoxSize={width:0,height:0},this._isPushed=!1,this._canPush=!0,this._growAfterOpen=!1,this._hasFlexibleDimensions=!0,this._positionLocked=!1,this._viewportMargin=0,this._scrollables=[],this._preferredPositions=[],this._positionChanges=new cn,this._resizeSubscription=Tn.EMPTY,this._offsetX=0,this._offsetY=0,this._appliedPanelClasses=[],this.positionChanges=this._positionChanges,this.setOrigin(e)}attach(e){this._validatePositions(),e.hostElement.classList.add(PN),this._overlayRef=e,this._boundingBox=e.hostElement,this._pane=e.overlayElement,this._isDisposed=!1,this._isInitialRender=!0,this._lastPosition=null,this._resizeSubscription.unsubscribe(),this._resizeSubscription=this._viewportRuler.change().subscribe(()=>{this._isInitialRender=!0,this.apply()})}apply(){if(this._isDisposed||!this._platform.isBrowser)return;if(!this._isInitialRender&&this._positionLocked&&this._lastPosition)return void this.reapplyLastPosition();this._clearPanelClasses(),this._resetOverlayElementStyles(),this._resetBoundingBoxStyles(),this._viewportRect=this._getNarrowedViewportRect(),this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const e=this._originRect,t=this._overlayRect,i=this._viewportRect,r=this._containerRect,s=[];let o;for(let a of this._preferredPositions){let c=this._getOriginPoint(e,r,a),u=this._getOverlayPoint(c,t,a),p=this._getOverlayFit(u,t,i,a);if(p.isCompletelyWithinViewport)return this._isPushed=!1,void this._applyPosition(a,c);this._canFitWithFlexibleDimensions(p,u,i)?s.push({position:a,origin:c,overlayRect:t,boundingBoxRect:this._calculateBoundingBoxRect(c,a)}):(!o||o.overlayFit.visibleAreac&&(c=p,a=u)}return this._isPushed=!1,void this._applyPosition(a.position,a.origin)}if(this._canPush)return this._isPushed=!0,void this._applyPosition(o.position,o.originPoint);this._applyPosition(o.position,o.originPoint)}detach(){this._clearPanelClasses(),this._lastPosition=null,this._previousPushAmount=null,this._resizeSubscription.unsubscribe()}dispose(){this._isDisposed||(this._boundingBox&&Hf(this._boundingBox.style,{top:"",left:"",right:"",bottom:"",height:"",width:"",alignItems:"",justifyContent:""}),this._pane&&this._resetOverlayElementStyles(),this._overlayRef&&this._overlayRef.hostElement.classList.remove(PN),this.detach(),this._positionChanges.complete(),this._overlayRef=this._boundingBox=null,this._isDisposed=!0)}reapplyLastPosition(){if(this._isDisposed||!this._platform.isBrowser)return;const e=this._lastPosition;if(e){this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._viewportRect=this._getNarrowedViewportRect(),this._containerRect=this._overlayContainer.getContainerElement().getBoundingClientRect();const t=this._getOriginPoint(this._originRect,this._containerRect,e);this._applyPosition(e,t)}else this.apply()}withScrollableContainers(e){return this._scrollables=e,this}withPositions(e){return this._preferredPositions=e,-1===e.indexOf(this._lastPosition)&&(this._lastPosition=null),this._validatePositions(),this}withViewportMargin(e){return this._viewportMargin=e,this}withFlexibleDimensions(e=!0){return this._hasFlexibleDimensions=e,this}withGrowAfterOpen(e=!0){return this._growAfterOpen=e,this}withPush(e=!0){return this._canPush=e,this}withLockedPosition(e=!0){return this._positionLocked=e,this}setOrigin(e){return this._origin=e,this}withDefaultOffsetX(e){return this._offsetX=e,this}withDefaultOffsetY(e){return this._offsetY=e,this}withTransformOriginOn(e){return this._transformOriginSelector=e,this}_getOriginPoint(e,t,i){let r,s;if("center"==i.originX)r=e.left+e.width/2;else{const o=this._isRtl()?e.right:e.left,a=this._isRtl()?e.left:e.right;r="start"==i.originX?o:a}return t.left<0&&(r-=t.left),s="center"==i.originY?e.top+e.height/2:"top"==i.originY?e.top:e.bottom,t.top<0&&(s-=t.top),{x:r,y:s}}_getOverlayPoint(e,t,i){let r,s;return r="center"==i.overlayX?-t.width/2:"start"===i.overlayX?this._isRtl()?-t.width:0:this._isRtl()?0:-t.width,s="center"==i.overlayY?-t.height/2:"top"==i.overlayY?0:-t.height,{x:e.x+r,y:e.y+s}}_getOverlayFit(e,t,i,r){const s=LN(t);let{x:o,y:a}=e,c=this._getOffset(r,"x"),u=this._getOffset(r,"y");c&&(o+=c),u&&(a+=u);let v=0-a,y=a+s.height-i.height,x=this._subtractOverflows(s.width,0-o,o+s.width-i.width),T=this._subtractOverflows(s.height,v,y),N=x*T;return{visibleArea:N,isCompletelyWithinViewport:s.width*s.height===N,fitsInViewportVertically:T===s.height,fitsInViewportHorizontally:x==s.width}}_canFitWithFlexibleDimensions(e,t,i){if(this._hasFlexibleDimensions){const r=i.bottom-t.y,s=i.right-t.x,o=ON(this._overlayRef.getConfig().minHeight),a=ON(this._overlayRef.getConfig().minWidth);return(e.fitsInViewportVertically||null!=o&&o<=r)&&(e.fitsInViewportHorizontally||null!=a&&a<=s)}return!1}_pushOverlayOnScreen(e,t,i){if(this._previousPushAmount&&this._positionLocked)return{x:e.x+this._previousPushAmount.x,y:e.y+this._previousPushAmount.y};const r=LN(t),s=this._viewportRect,o=Math.max(e.x+r.width-s.width,0),a=Math.max(e.y+r.height-s.height,0),c=Math.max(s.top-i.top-e.y,0),u=Math.max(s.left-i.left-e.x,0);let p=0,g=0;return p=r.width<=s.width?u||-o:e.xx&&!this._isInitialRender&&!this._growAfterOpen&&(o=e.y-x/2)}if("end"===t.overlayX&&!r||"start"===t.overlayX&&r)v=i.width-e.x+this._viewportMargin,p=e.x-this._viewportMargin;else if("start"===t.overlayX&&!r||"end"===t.overlayX&&r)g=e.x,p=i.right-e.x;else{const y=Math.min(i.right-e.x+i.left,e.x),x=this._lastBoundingBoxSize.width;p=2*y,g=e.x-y,p>x&&!this._isInitialRender&&!this._growAfterOpen&&(g=e.x-x/2)}return{top:o,left:g,bottom:a,right:v,width:p,height:s}}_setBoundingBoxStyles(e,t){const i=this._calculateBoundingBoxRect(e,t);!this._isInitialRender&&!this._growAfterOpen&&(i.height=Math.min(i.height,this._lastBoundingBoxSize.height),i.width=Math.min(i.width,this._lastBoundingBoxSize.width));const r={};if(this._hasExactPosition())r.top=r.left="0",r.bottom=r.right=r.maxHeight=r.maxWidth="",r.width=r.height="100%";else{const s=this._overlayRef.getConfig().maxHeight,o=this._overlayRef.getConfig().maxWidth;r.height=Cs(i.height),r.top=Cs(i.top),r.bottom=Cs(i.bottom),r.width=Cs(i.width),r.left=Cs(i.left),r.right=Cs(i.right),r.alignItems="center"===t.overlayX?"center":"end"===t.overlayX?"flex-end":"flex-start",r.justifyContent="center"===t.overlayY?"center":"bottom"===t.overlayY?"flex-end":"flex-start",s&&(r.maxHeight=Cs(s)),o&&(r.maxWidth=Cs(o))}this._lastBoundingBoxSize=i,Hf(this._boundingBox.style,r)}_resetBoundingBoxStyles(){Hf(this._boundingBox.style,{top:"0",left:"0",right:"0",bottom:"0",height:"",width:"",alignItems:"",justifyContent:""})}_resetOverlayElementStyles(){Hf(this._pane.style,{top:"",left:"",bottom:"",right:"",position:"",transform:""})}_setOverlayElementStyles(e,t){const i={},r=this._hasExactPosition(),s=this._hasFlexibleDimensions,o=this._overlayRef.getConfig();if(r){const p=this._viewportRuler.getViewportScrollPosition();Hf(i,this._getExactOverlayY(t,e,p)),Hf(i,this._getExactOverlayX(t,e,p))}else i.position="static";let a="",c=this._getOffset(t,"x"),u=this._getOffset(t,"y");c&&(a+=`translateX(${c}px) `),u&&(a+=`translateY(${u}px)`),i.transform=a.trim(),o.maxHeight&&(r?i.maxHeight=Cs(o.maxHeight):s&&(i.maxHeight="")),o.maxWidth&&(r?i.maxWidth=Cs(o.maxWidth):s&&(i.maxWidth="")),Hf(this._pane.style,i)}_getExactOverlayY(e,t,i){let r={top:"",bottom:""},s=this._getOverlayPoint(t,this._overlayRect,e);return this._isPushed&&(s=this._pushOverlayOnScreen(s,this._overlayRect,i)),"bottom"===e.overlayY?r.bottom=this._document.documentElement.clientHeight-(s.y+this._overlayRect.height)+"px":r.top=Cs(s.y),r}_getExactOverlayX(e,t,i){let o,r={left:"",right:""},s=this._getOverlayPoint(t,this._overlayRect,e);return this._isPushed&&(s=this._pushOverlayOnScreen(s,this._overlayRect,i)),o=this._isRtl()?"end"===e.overlayX?"left":"right":"end"===e.overlayX?"right":"left","right"===o?r.right=this._document.documentElement.clientWidth-(s.x+this._overlayRect.width)+"px":r.left=Cs(s.x),r}_getScrollVisibility(){const e=this._getOriginRect(),t=this._pane.getBoundingClientRect(),i=this._scrollables.map(r=>r.getElementRef().nativeElement.getBoundingClientRect());return{isOriginClipped:FN(e,i),isOriginOutsideView:YT(e,i),isOverlayClipped:FN(t,i),isOverlayOutsideView:YT(t,i)}}_subtractOverflows(e,...t){return t.reduce((i,r)=>i-Math.max(r,0),e)}_getNarrowedViewportRect(){const e=this._document.documentElement.clientWidth,t=this._document.documentElement.clientHeight,i=this._viewportRuler.getViewportScrollPosition();return{top:i.top+this._viewportMargin,left:i.left+this._viewportMargin,right:i.left+e-this._viewportMargin,bottom:i.top+t-this._viewportMargin,width:e-2*this._viewportMargin,height:t-2*this._viewportMargin}}_isRtl(){return"rtl"===this._overlayRef.getDirection()}_hasExactPosition(){return!this._hasFlexibleDimensions||this._isPushed}_getOffset(e,t){return"x"===t?null==e.offsetX?this._offsetX:e.offsetX:null==e.offsetY?this._offsetY:e.offsetY}_validatePositions(){}_addPanelClasses(e){this._pane&&Iw(e).forEach(t=>{""!==t&&-1===this._appliedPanelClasses.indexOf(t)&&(this._appliedPanelClasses.push(t),this._pane.classList.add(t))})}_clearPanelClasses(){this._pane&&(this._appliedPanelClasses.forEach(e=>{this._pane.classList.remove(e)}),this._appliedPanelClasses=[])}_getOriginRect(){const e=this._origin;if(e instanceof _n)return e.nativeElement.getBoundingClientRect();if(e instanceof Element)return e.getBoundingClientRect();const t=e.width||0,i=e.height||0;return{top:e.y,bottom:e.y+i,left:e.x,right:e.x+t,height:i,width:t}}}function Hf(n,e){for(let t in e)e.hasOwnProperty(t)&&(n[t]=e[t]);return n}function ON(n){if("number"!=typeof n&&null!=n){const[e,t]=n.split(FK);return t&&"px"!==t?null:parseFloat(e)}return n||null}function LN(n){return{top:Math.floor(n.top),right:Math.floor(n.right),bottom:Math.floor(n.bottom),left:Math.floor(n.left),width:Math.floor(n.width),height:Math.floor(n.height)}}const NN="cdk-global-overlay-wrapper";class PK{constructor(){this._cssPosition="static",this._topOffset="",this._bottomOffset="",this._alignItems="",this._xPosition="",this._xOffset="",this._width="",this._height="",this._isDisposed=!1}attach(e){const t=e.getConfig();this._overlayRef=e,this._width&&!t.width&&e.updateSize({width:this._width}),this._height&&!t.height&&e.updateSize({height:this._height}),e.hostElement.classList.add(NN),this._isDisposed=!1}top(e=""){return this._bottomOffset="",this._topOffset=e,this._alignItems="flex-start",this}left(e=""){return this._xOffset=e,this._xPosition="left",this}bottom(e=""){return this._topOffset="",this._bottomOffset=e,this._alignItems="flex-end",this}right(e=""){return this._xOffset=e,this._xPosition="right",this}start(e=""){return this._xOffset=e,this._xPosition="start",this}end(e=""){return this._xOffset=e,this._xPosition="end",this}width(e=""){return this._overlayRef?this._overlayRef.updateSize({width:e}):this._width=e,this}height(e=""){return this._overlayRef?this._overlayRef.updateSize({height:e}):this._height=e,this}centerHorizontally(e=""){return this.left(e),this._xPosition="center",this}centerVertically(e=""){return this.top(e),this._alignItems="center",this}apply(){if(!this._overlayRef||!this._overlayRef.hasAttached())return;const e=this._overlayRef.overlayElement.style,t=this._overlayRef.hostElement.style,i=this._overlayRef.getConfig(),{width:r,height:s,maxWidth:o,maxHeight:a}=i,c=!("100%"!==r&&"100vw"!==r||o&&"100%"!==o&&"100vw"!==o),u=!("100%"!==s&&"100vh"!==s||a&&"100%"!==a&&"100vh"!==a),p=this._xPosition,g=this._xOffset,v="rtl"===this._overlayRef.getConfig().direction;let y="",x="",T="";c?T="flex-start":"center"===p?(T="center",v?x=g:y=g):v?"left"===p||"end"===p?(T="flex-end",y=g):("right"===p||"start"===p)&&(T="flex-start",x=g):"left"===p||"start"===p?(T="flex-start",y=g):("right"===p||"end"===p)&&(T="flex-end",x=g),e.position=this._cssPosition,e.marginLeft=c?"0":y,e.marginTop=u?"0":this._topOffset,e.marginBottom=this._bottomOffset,e.marginRight=c?"0":x,t.justifyContent=T,t.alignItems=u?"flex-start":this._alignItems}dispose(){if(this._isDisposed||!this._overlayRef)return;const e=this._overlayRef.overlayElement.style,t=this._overlayRef.hostElement,i=t.style;t.classList.remove(NN),i.justifyContent=i.alignItems=e.marginTop=e.marginBottom=e.marginLeft=e.marginRight=e.position="",this._overlayRef=null,this._isDisposed=!0}}let OK=(()=>{class n{constructor(t,i,r,s){this._viewportRuler=t,this._document=i,this._platform=r,this._overlayContainer=s}global(){return new PK}flexibleConnectedTo(t){return new RK(t,this._viewportRuler,this._document,this._platform,this._overlayContainer)}}return n.\u0275fac=function(t){return new(t||n)(xe(Gw),xe(Mn),xe(as),xe(qw))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),LK=0,hl=(()=>{class n{constructor(t,i,r,s,o,a,c,u,p,g,v,y){this.scrollStrategies=t,this._overlayContainer=i,this._componentFactoryResolver=r,this._positionBuilder=s,this._keyboardDispatcher=o,this._injector=a,this._ngZone=c,this._document=u,this._directionality=p,this._location=g,this._outsideClickDispatcher=v,this._animationsModuleType=y}create(t){const i=this._createHostElement(),r=this._createPaneElement(i),s=this._createPortalOutlet(r),o=new XT(t);return o.direction=o.direction||this._directionality.value,new hg(s,i,r,o,this._ngZone,this._keyboardDispatcher,this._document,this._location,this._outsideClickDispatcher,"NoopAnimations"===this._animationsModuleType)}position(){return this._positionBuilder}_createPaneElement(t){const i=this._document.createElement("div");return i.id="cdk-overlay-"+LK++,i.classList.add("cdk-overlay-pane"),t.appendChild(i),i}_createHostElement(){const t=this._document.createElement("div");return this._overlayContainer.getContainerElement().appendChild(t),t}_createPortalOutlet(t){return this._appRef||(this._appRef=this._injector.get(Jm)),new wK(t,this._componentFactoryResolver,this._appRef,this._injector,this._document)}}return n.\u0275fac=function(t){return new(t||n)(xe(TK),xe(qw),xe(Fd),xe(OK),xe(kK),xe(ts),xe(Xt),xe(Mn),xe(Yl),xe(Mv),xe(IK),xe(bo,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const NK=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],BN=new Ze("cdk-connected-overlay-scroll-strategy");let ZT=(()=>{class n{constructor(t){this.elementRef=t}}return n.\u0275fac=function(t){return new(t||n)(ie(_n))},n.\u0275dir=ut({type:n,selectors:[["","cdk-overlay-origin",""],["","overlay-origin",""],["","cdkOverlayOrigin",""]],exportAs:["cdkOverlayOrigin"],standalone:!0}),n})(),VN=(()=>{class n{get offsetX(){return this._offsetX}set offsetX(t){this._offsetX=t,this._position&&this._updatePositionStrategy(this._position)}get offsetY(){return this._offsetY}set offsetY(t){this._offsetY=t,this._position&&this._updatePositionStrategy(this._position)}get hasBackdrop(){return this._hasBackdrop}set hasBackdrop(t){this._hasBackdrop=bi(t)}get lockPosition(){return this._lockPosition}set lockPosition(t){this._lockPosition=bi(t)}get flexibleDimensions(){return this._flexibleDimensions}set flexibleDimensions(t){this._flexibleDimensions=bi(t)}get growAfterOpen(){return this._growAfterOpen}set growAfterOpen(t){this._growAfterOpen=bi(t)}get push(){return this._push}set push(t){this._push=bi(t)}constructor(t,i,r,s,o){this._overlay=t,this._dir=o,this._hasBackdrop=!1,this._lockPosition=!1,this._growAfterOpen=!1,this._flexibleDimensions=!1,this._push=!1,this._backdropSubscription=Tn.EMPTY,this._attachSubscription=Tn.EMPTY,this._detachSubscription=Tn.EMPTY,this._positionSubscription=Tn.EMPTY,this.viewportMargin=0,this.open=!1,this.disableClose=!1,this.backdropClick=new Pn,this.positionChange=new Pn,this.attach=new Pn,this.detach=new Pn,this.overlayKeydown=new Pn,this.overlayOutsideClick=new Pn,this._templatePortal=new qT(i,r),this._scrollStrategyFactory=s,this.scrollStrategy=this._scrollStrategyFactory()}get overlayRef(){return this._overlayRef}get dir(){return this._dir?this._dir.value:"ltr"}ngOnDestroy(){this._attachSubscription.unsubscribe(),this._detachSubscription.unsubscribe(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this._overlayRef&&this._overlayRef.dispose()}ngOnChanges(t){this._position&&(this._updatePositionStrategy(this._position),this._overlayRef.updateSize({width:this.width,minWidth:this.minWidth,height:this.height,minHeight:this.minHeight}),t.origin&&this.open&&this._position.apply()),t.open&&(this.open?this._attachOverlay():this._detachOverlay())}_createOverlay(){(!this.positions||!this.positions.length)&&(this.positions=NK);const t=this._overlayRef=this._overlay.create(this._buildConfig());this._attachSubscription=t.attachments().subscribe(()=>this.attach.emit()),this._detachSubscription=t.detachments().subscribe(()=>this.detach.emit()),t.keydownEvents().subscribe(i=>{this.overlayKeydown.next(i),27===i.keyCode&&!this.disableClose&&!ql(i)&&(i.preventDefault(),this._detachOverlay())}),this._overlayRef.outsidePointerEvents().subscribe(i=>{this.overlayOutsideClick.next(i)})}_buildConfig(){const t=this._position=this.positionStrategy||this._createPositionStrategy(),i=new XT({direction:this._dir,positionStrategy:t,scrollStrategy:this.scrollStrategy,hasBackdrop:this.hasBackdrop});return(this.width||0===this.width)&&(i.width=this.width),(this.height||0===this.height)&&(i.height=this.height),(this.minWidth||0===this.minWidth)&&(i.minWidth=this.minWidth),(this.minHeight||0===this.minHeight)&&(i.minHeight=this.minHeight),this.backdropClass&&(i.backdropClass=this.backdropClass),this.panelClass&&(i.panelClass=this.panelClass),i}_updatePositionStrategy(t){const i=this.positions.map(r=>({originX:r.originX,originY:r.originY,overlayX:r.overlayX,overlayY:r.overlayY,offsetX:r.offsetX||this.offsetX,offsetY:r.offsetY||this.offsetY,panelClass:r.panelClass||void 0}));return t.setOrigin(this._getFlexibleConnectedPositionStrategyOrigin()).withPositions(i).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector)}_createPositionStrategy(){const t=this._overlay.position().flexibleConnectedTo(this._getFlexibleConnectedPositionStrategyOrigin());return this._updatePositionStrategy(t),t}_getFlexibleConnectedPositionStrategyOrigin(){return this.origin instanceof ZT?this.origin.elementRef:this.origin}_attachOverlay(){this._overlayRef?this._overlayRef.getConfig().hasBackdrop=this.hasBackdrop:this._createOverlay(),this._overlayRef.hasAttached()||this._overlayRef.attach(this._templatePortal),this.hasBackdrop?this._backdropSubscription=this._overlayRef.backdropClick().subscribe(t=>{this.backdropClick.emit(t)}):this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.positionChange.observers.length>0&&(this._positionSubscription=this._position.positionChanges.pipe(AN(()=>this.positionChange.observers.length>0)).subscribe(t=>{this.positionChange.emit(t),0===this.positionChange.observers.length&&this._positionSubscription.unsubscribe()}))}_detachOverlay(){this._overlayRef&&this._overlayRef.detach(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe()}}return n.\u0275fac=function(t){return new(t||n)(ie(hl),ie(al),ie(Sa),ie(BN),ie(Yl,8))},n.\u0275dir=ut({type:n,selectors:[["","cdk-connected-overlay",""],["","connected-overlay",""],["","cdkConnectedOverlay",""]],inputs:{origin:["cdkConnectedOverlayOrigin","origin"],positions:["cdkConnectedOverlayPositions","positions"],positionStrategy:["cdkConnectedOverlayPositionStrategy","positionStrategy"],offsetX:["cdkConnectedOverlayOffsetX","offsetX"],offsetY:["cdkConnectedOverlayOffsetY","offsetY"],width:["cdkConnectedOverlayWidth","width"],height:["cdkConnectedOverlayHeight","height"],minWidth:["cdkConnectedOverlayMinWidth","minWidth"],minHeight:["cdkConnectedOverlayMinHeight","minHeight"],backdropClass:["cdkConnectedOverlayBackdropClass","backdropClass"],panelClass:["cdkConnectedOverlayPanelClass","panelClass"],viewportMargin:["cdkConnectedOverlayViewportMargin","viewportMargin"],scrollStrategy:["cdkConnectedOverlayScrollStrategy","scrollStrategy"],open:["cdkConnectedOverlayOpen","open"],disableClose:["cdkConnectedOverlayDisableClose","disableClose"],transformOriginSelector:["cdkConnectedOverlayTransformOriginOn","transformOriginSelector"],hasBackdrop:["cdkConnectedOverlayHasBackdrop","hasBackdrop"],lockPosition:["cdkConnectedOverlayLockPosition","lockPosition"],flexibleDimensions:["cdkConnectedOverlayFlexibleDimensions","flexibleDimensions"],growAfterOpen:["cdkConnectedOverlayGrowAfterOpen","growAfterOpen"],push:["cdkConnectedOverlayPush","push"]},outputs:{backdropClick:"backdropClick",positionChange:"positionChange",attach:"attach",detach:"detach",overlayKeydown:"overlayKeydown",overlayOutsideClick:"overlayOutsideClick"},exportAs:["cdkConnectedOverlay"],standalone:!0,features:[Cn]}),n})();const VK={provide:BN,deps:[hl],useFactory:function BK(n){return()=>n.scrollStrategies.reposition()}};let Kw=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[hl,VK],imports:[jv,Kv,TN,TN]}),n})();function Yv(n){return new un(e=>{let t;try{t=n()}catch(r){return void e.error(r)}return(t?dr(t):kw()).subscribe(e)})}function HK(n,e){}class Xv{constructor(){this.role="dialog",this.panelClass="",this.hasBackdrop=!0,this.backdropClass="",this.disableClose=!1,this.width="",this.height="",this.data=null,this.ariaDescribedBy=null,this.ariaLabelledBy=null,this.ariaLabel=null,this.ariaModal=!0,this.autoFocus="first-tabbable",this.restoreFocus=!0,this.closeOnNavigation=!0,this.closeOnDestroy=!0,this.closeOnOverlayDetachments=!0}}let JT=(()=>{class n extends KT{constructor(t,i,r,s,o,a,c,u){super(),this._elementRef=t,this._focusTrapFactory=i,this._config=s,this._interactivityChecker=o,this._ngZone=a,this._overlayRef=c,this._focusMonitor=u,this._elementFocusedBeforeDialogWasOpened=null,this._closeInteractionType=null,this.attachDomPortal=p=>{this._portalOutlet.hasAttached();const g=this._portalOutlet.attachDomPortal(p);return this._contentAttached(),g},this._ariaLabelledBy=this._config.ariaLabelledBy||null,this._document=r}_contentAttached(){this._initializeFocusTrap(),this._handleBackdropClicks(),this._captureInitialFocus()}_captureInitialFocus(){this._trapFocus()}ngOnDestroy(){this._restoreFocus()}attachComponentPortal(t){this._portalOutlet.hasAttached();const i=this._portalOutlet.attachComponentPortal(t);return this._contentAttached(),i}attachTemplatePortal(t){this._portalOutlet.hasAttached();const i=this._portalOutlet.attachTemplatePortal(t);return this._contentAttached(),i}_recaptureFocus(){this._containsFocus()||this._trapFocus()}_forceFocus(t,i){this._interactivityChecker.isFocusable(t)||(t.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{const r=()=>{t.removeEventListener("blur",r),t.removeEventListener("mousedown",r),t.removeAttribute("tabindex")};t.addEventListener("blur",r),t.addEventListener("mousedown",r)})),t.focus(i)}_focusByCssSelector(t,i){let r=this._elementRef.nativeElement.querySelector(t);r&&this._forceFocus(r,i)}_trapFocus(){const t=this._elementRef.nativeElement;switch(this._config.autoFocus){case!1:case"dialog":this._containsFocus()||t.focus();break;case!0:case"first-tabbable":this._focusTrap.focusInitialElementWhenReady().then(i=>{i||this._focusDialogContainer()});break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]');break;default:this._focusByCssSelector(this._config.autoFocus)}}_restoreFocus(){const t=this._config.restoreFocus;let i=null;if("string"==typeof t?i=this._document.querySelector(t):"boolean"==typeof t?i=t?this._elementFocusedBeforeDialogWasOpened:null:t&&(i=t),this._config.restoreFocus&&i&&"function"==typeof i.focus){const r=Dw(),s=this._elementRef.nativeElement;(!r||r===this._document.body||r===s||s.contains(r))&&(this._focusMonitor?(this._focusMonitor.focusVia(i,this._closeInteractionType),this._closeInteractionType=null):i.focus())}this._focusTrap&&this._focusTrap.destroy()}_focusDialogContainer(){this._elementRef.nativeElement.focus&&this._elementRef.nativeElement.focus()}_containsFocus(){const t=this._elementRef.nativeElement,i=Dw();return t===i||t.contains(i)}_initializeFocusTrap(){this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._document&&(this._elementFocusedBeforeDialogWasOpened=Dw())}_handleBackdropClicks(){this._overlayRef.backdropClick().subscribe(()=>{this._config.disableClose&&this._recaptureFocus()})}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Lw),ie(Mn,8),ie(Xv),ie(Gv),ie(Xt),ie(hg),ie(Vf))},n.\u0275cmp=Ln({type:n,selectors:[["cdk-dialog-container"]],viewQuery:function(t,i){if(1&t&&zr($w,7),2&t){let r;Yn(r=Xn())&&(i._portalOutlet=r.first)}},hostAttrs:["tabindex","-1",1,"cdk-dialog-container"],hostVars:6,hostBindings:function(t,i){2&t&&Di("id",i._config.id||null)("role",i._config.role)("aria-modal",i._config.ariaModal)("aria-labelledby",i._config.ariaLabel?null:i._ariaLabelledBy)("aria-label",i._config.ariaLabel)("aria-describedby",i._config.ariaDescribedBy||null)},features:[Z],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(t,i){1&t&&mt(0,HK,0,0,"ng-template",0)},dependencies:[$w],styles:[".cdk-dialog-container{display:block;width:100%;height:100%;min-height:inherit;max-height:inherit}"],encapsulation:2}),n})();class QT{constructor(e,t){this.overlayRef=e,this.config=t,this.closed=new cn,this.disableClose=t.disableClose,this.backdropClick=e.backdropClick(),this.keydownEvents=e.keydownEvents(),this.outsidePointerEvents=e.outsidePointerEvents(),this.id=t.id,this.keydownEvents.subscribe(i=>{27===i.keyCode&&!this.disableClose&&!ql(i)&&(i.preventDefault(),this.close(void 0,{focusOrigin:"keyboard"}))}),this.backdropClick.subscribe(()=>{this.disableClose||this.close(void 0,{focusOrigin:"mouse"})}),this._detachSubscription=e.detachments().subscribe(()=>{!1!==t.closeOnOverlayDetachments&&this.close()})}close(e,t){if(this.containerInstance){const i=this.closed;this.containerInstance._closeInteractionType=t?.focusOrigin||"program",this._detachSubscription.unsubscribe(),this.overlayRef.dispose(),i.next(e),i.complete(),this.componentInstance=this.containerInstance=null}}updatePosition(){return this.overlayRef.updatePosition(),this}updateSize(e="",t=""){return this.overlayRef.updateSize({width:e,height:t}),this}addPanelClass(e){return this.overlayRef.addPanelClass(e),this}removePanelClass(e){return this.overlayRef.removePanelClass(e),this}}const HN=new Ze("DialogScrollStrategy"),UK=new Ze("DialogData"),zK=new Ze("DefaultDialogConfig"),jK={provide:HN,deps:[hl],useFactory:function GK(n){return()=>n.scrollStrategies.block()}};let WK=0,eA=(()=>{class n{get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}constructor(t,i,r,s,o,a){this._overlay=t,this._injector=i,this._defaultOptions=r,this._parentDialog=s,this._overlayContainer=o,this._openDialogsAtThisLevel=[],this._afterAllClosedAtThisLevel=new cn,this._afterOpenedAtThisLevel=new cn,this._ariaHiddenElements=new Map,this.afterAllClosed=Yv(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(Bf(void 0))),this._scrollStrategy=a}open(t,i){(i={...this._defaultOptions||new Xv,...i}).id=i.id||"cdk-dialog-"+WK++,i.id&&this.getDialogById(i.id);const s=this._getOverlayConfig(i),o=this._overlay.create(s),a=new QT(o,i),c=this._attachContainer(o,a,i);return a.containerInstance=c,this._attachDialogContent(t,a,c,i),this.openDialogs.length||this._hideNonDialogContentFromAssistiveTechnology(),this.openDialogs.push(a),a.closed.subscribe(()=>this._removeOpenDialog(a,!0)),this.afterOpened.next(a),a}closeAll(){tA(this.openDialogs,t=>t.close())}getDialogById(t){return this.openDialogs.find(i=>i.id===t)}ngOnDestroy(){tA(this._openDialogsAtThisLevel,t=>{!1===t.config.closeOnDestroy&&this._removeOpenDialog(t,!1)}),tA(this._openDialogsAtThisLevel,t=>t.close()),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete(),this._openDialogsAtThisLevel=[]}_getOverlayConfig(t){const i=new XT({positionStrategy:t.positionStrategy||this._overlay.position().global().centerHorizontally().centerVertically(),scrollStrategy:t.scrollStrategy||this._scrollStrategy(),panelClass:t.panelClass,hasBackdrop:t.hasBackdrop,direction:t.direction,minWidth:t.minWidth,minHeight:t.minHeight,maxWidth:t.maxWidth,maxHeight:t.maxHeight,width:t.width,height:t.height,disposeOnNavigation:t.closeOnNavigation});return t.backdropClass&&(i.backdropClass=t.backdropClass),i}_attachContainer(t,i,r){const s=r.injector||r.viewContainerRef?.injector,o=[{provide:Xv,useValue:r},{provide:QT,useValue:i},{provide:hg,useValue:t}];let a;r.container?"function"==typeof r.container?a=r.container:(a=r.container.type,o.push(...r.container.providers(r))):a=JT;const c=new Ww(a,r.viewContainerRef,ts.create({parent:s||this._injector,providers:o}),r.componentFactoryResolver);return t.attach(c).instance}_attachDialogContent(t,i,r,s){if(t instanceof al){const o=this._createInjector(s,i,r,void 0);let a={$implicit:s.data,dialogRef:i};s.templateContext&&(a={...a,..."function"==typeof s.templateContext?s.templateContext():s.templateContext}),r.attachTemplatePortal(new qT(t,null,a,o))}else{const o=this._createInjector(s,i,r,this._injector),a=r.attachComponentPortal(new Ww(t,s.viewContainerRef,o,s.componentFactoryResolver));i.componentInstance=a.instance}}_createInjector(t,i,r,s){const o=t.injector||t.viewContainerRef?.injector,a=[{provide:UK,useValue:t.data},{provide:QT,useValue:i}];return t.providers&&("function"==typeof t.providers?a.push(...t.providers(i,t,r)):a.push(...t.providers)),t.direction&&(!o||!o.get(Yl,null,{optional:!0}))&&a.push({provide:Yl,useValue:{value:t.direction,change:Tt()}}),ts.create({parent:o||s,providers:a})}_removeOpenDialog(t,i){const r=this.openDialogs.indexOf(t);r>-1&&(this.openDialogs.splice(r,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((s,o)=>{s?o.setAttribute("aria-hidden",s):o.removeAttribute("aria-hidden")}),this._ariaHiddenElements.clear(),i&&this._getAfterAllClosed().next()))}_hideNonDialogContentFromAssistiveTechnology(){const t=this._overlayContainer.getContainerElement();if(t.parentElement){const i=t.parentElement.children;for(let r=i.length-1;r>-1;r--){const s=i[r];s!==t&&"SCRIPT"!==s.nodeName&&"STYLE"!==s.nodeName&&!s.hasAttribute("aria-live")&&(this._ariaHiddenElements.set(s,s.getAttribute("aria-hidden")),s.setAttribute("aria-hidden","true"))}}}_getAfterAllClosed(){const t=this._parentDialog;return t?t._getAfterAllClosed():this._afterAllClosedAtThisLevel}}return n.\u0275fac=function(t){return new(t||n)(xe(hl),xe(ts),xe(zK,8),xe(n,12),xe(qw),xe(HN))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();function tA(n,e){let t=n.length;for(;t--;)e(n[t])}let UN=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[eA,jK],imports:[Kw,Kv,$L,Kv]}),n})();class zN{}class $K{}const Ud="*";function fg(n,e){return{type:7,name:n,definitions:e,options:{}}}function zd(n,e=null){return{type:4,styles:e,timings:n}}function Yw(n,e=null){return{type:3,steps:n,options:e}}function GN(n,e=null){return{type:2,steps:n,options:e}}function la(n){return{type:6,styles:n,offset:null}}function sh(n,e,t){return{type:0,name:n,styles:e,options:t}}function Xl(n,e,t=null){return{type:1,expr:n,animation:e,options:t}}function Zv(n=null){return{type:9,options:n}}function Jv(n,e,t=null){return{type:11,selector:n,animation:e,options:t}}function jN(n){Promise.resolve().then(n)}class Qv{constructor(e=0,t=0){this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._originalOnDoneFns=[],this._originalOnStartFns=[],this._started=!1,this._destroyed=!1,this._finished=!1,this._position=0,this.parentPlayer=null,this.totalTime=e+t}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}onStart(e){this._originalOnStartFns.push(e),this._onStartFns.push(e)}onDone(e){this._originalOnDoneFns.push(e),this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}hasStarted(){return this._started}init(){}play(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}triggerMicrotask(){jN(()=>this._onFinish())}_onStart(){this._onStartFns.forEach(e=>e()),this._onStartFns=[]}pause(){}restart(){}finish(){this._onFinish()}destroy(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}reset(){this._started=!1,this._finished=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}setPosition(e){this._position=this.totalTime?e*this.totalTime:1}getPosition(){return this.totalTime?this._position/this.totalTime:1}triggerCallback(e){const t="start"==e?this._onStartFns:this._onDoneFns;t.forEach(i=>i()),t.length=0}}class WN{constructor(e){this._onDoneFns=[],this._onStartFns=[],this._finished=!1,this._started=!1,this._destroyed=!1,this._onDestroyFns=[],this.parentPlayer=null,this.totalTime=0,this.players=e;let t=0,i=0,r=0;const s=this.players.length;0==s?jN(()=>this._onFinish()):this.players.forEach(o=>{o.onDone(()=>{++t==s&&this._onFinish()}),o.onDestroy(()=>{++i==s&&this._onDestroy()}),o.onStart(()=>{++r==s&&this._onStart()})}),this.totalTime=this.players.reduce((o,a)=>Math.max(o,a.totalTime),0)}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this.players.forEach(e=>e.init())}onStart(e){this._onStartFns.push(e)}_onStart(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach(e=>e()),this._onStartFns=[])}onDone(e){this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}hasStarted(){return this._started}play(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach(e=>e.play())}pause(){this.players.forEach(e=>e.pause())}restart(){this.players.forEach(e=>e.restart())}finish(){this._onFinish(),this.players.forEach(e=>e.finish())}destroy(){this._onDestroy()}_onDestroy(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach(e=>e.destroy()),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}reset(){this.players.forEach(e=>e.reset()),this._destroyed=!1,this._finished=!1,this._started=!1}setPosition(e){const t=e*this.totalTime;this.players.forEach(i=>{const r=i.totalTime?Math.min(1,t/i.totalTime):1;i.setPosition(r)})}getPosition(){const e=this.players.reduce((t,i)=>null===t||i.totalTime>t.totalTime?i:t,null);return null!=e?e.getPosition():0}beforeDestroy(){this.players.forEach(e=>{e.beforeDestroy&&e.beforeDestroy()})}triggerCallback(e){const t="start"==e?this._onStartFns:this._onDoneFns;t.forEach(i=>i()),t.length=0}}const nA="!";function qK(n,e){}class Xw{constructor(){this.role="dialog",this.panelClass="",this.hasBackdrop=!0,this.backdropClass="",this.disableClose=!1,this.width="",this.height="",this.maxWidth="80vw",this.data=null,this.ariaDescribedBy=null,this.ariaLabelledBy=null,this.ariaLabel=null,this.ariaModal=!0,this.autoFocus="first-tabbable",this.restoreFocus=!0,this.delayFocusTrap=!0,this.closeOnNavigation=!0}}const iA="mdc-dialog--open",$N="mdc-dialog--opening",qN="mdc-dialog--closing";let XK=(()=>{class n extends JT{constructor(t,i,r,s,o,a,c,u){super(t,i,r,s,o,a,c,u),this._animationStateChanged=new Pn}_captureInitialFocus(){this._config.delayFocusTrap||this._trapFocus()}_openAnimationDone(t){this._config.delayFocusTrap&&this._trapFocus(),this._animationStateChanged.next({state:"opened",totalTime:t})}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Lw),ie(Mn,8),ie(Xw),ie(Gv),ie(Xt),ie(hg),ie(Vf))},n.\u0275cmp=Ln({type:n,selectors:[["ng-component"]],features:[Z],decls:0,vars:0,template:function(t,i){},encapsulation:2}),n})();const KN="--mat-dialog-transition-duration";function YN(n){return null==n?null:"number"==typeof n?n:n.endsWith("ms")?ih(n.substring(0,n.length-2)):n.endsWith("s")?1e3*ih(n.substring(0,n.length-1)):"0"===n?0:null}let ZK=(()=>{class n extends XK{constructor(t,i,r,s,o,a,c,u,p){super(t,i,r,s,o,a,c,p),this._animationMode=u,this._animationsEnabled="NoopAnimations"!==this._animationMode,this._hostElement=this._elementRef.nativeElement,this._openAnimationDuration=this._animationsEnabled?YN(this._config.enterAnimationDuration)??150:0,this._closeAnimationDuration=this._animationsEnabled?YN(this._config.exitAnimationDuration)??75:0,this._animationTimer=null,this._finishDialogOpen=()=>{this._clearAnimationClasses(),this._openAnimationDone(this._openAnimationDuration)},this._finishDialogClose=()=>{this._clearAnimationClasses(),this._animationStateChanged.emit({state:"closed",totalTime:this._closeAnimationDuration})}}_contentAttached(){super._contentAttached(),this._startOpenAnimation()}ngOnDestroy(){super.ngOnDestroy(),null!==this._animationTimer&&clearTimeout(this._animationTimer)}_startOpenAnimation(){this._animationStateChanged.emit({state:"opening",totalTime:this._openAnimationDuration}),this._animationsEnabled?(this._hostElement.style.setProperty(KN,`${this._openAnimationDuration}ms`),this._hostElement.classList.add($N),this._hostElement.classList.add(iA),this._waitForAnimationToComplete(this._openAnimationDuration,this._finishDialogOpen)):(this._hostElement.classList.add(iA),Promise.resolve().then(()=>this._finishDialogOpen()))}_startExitAnimation(){this._animationStateChanged.emit({state:"closing",totalTime:this._closeAnimationDuration}),this._hostElement.classList.remove(iA),this._animationsEnabled?(this._hostElement.style.setProperty(KN,`${this._openAnimationDuration}ms`),this._hostElement.classList.add(qN),this._waitForAnimationToComplete(this._closeAnimationDuration,this._finishDialogClose)):Promise.resolve().then(()=>this._finishDialogClose())}_clearAnimationClasses(){this._hostElement.classList.remove($N),this._hostElement.classList.remove(qN)}_waitForAnimationToComplete(t,i){null!==this._animationTimer&&clearTimeout(this._animationTimer),this._animationTimer=setTimeout(i,t)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Lw),ie(Mn,8),ie(Xw),ie(Gv),ie(Xt),ie(hg),ie(bo,8),ie(Vf))},n.\u0275cmp=Ln({type:n,selectors:[["mat-dialog-container"]],hostAttrs:["tabindex","-1",1,"mat-mdc-dialog-container","mdc-dialog"],hostVars:8,hostBindings:function(t,i){2&t&&(Af("id",i._config.id),Di("aria-modal",i._config.ariaModal)("role",i._config.role)("aria-labelledby",i._config.ariaLabel?null:i._ariaLabelledBy)("aria-label",i._config.ariaLabel)("aria-describedby",i._config.ariaDescribedBy||null),hi("_mat-animation-noopable",!i._animationsEnabled))},features:[Z],decls:3,vars:0,consts:[[1,"mdc-dialog__container"],[1,"mat-mdc-dialog-surface","mdc-dialog__surface"],["cdkPortalOutlet",""]],template:function(t,i){1&t&&(ke(0,"div",0)(1,"div",1),mt(2,qK,0,0,"ng-template",2),Ne()())},dependencies:[$w],styles:['.mdc-elevation-overlay{position:absolute;border-radius:inherit;pointer-events:none;opacity:var(--mdc-elevation-overlay-opacity, 0);transition:opacity 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-dialog,.mdc-dialog__scrim{position:fixed;top:0;left:0;align-items:center;justify-content:center;box-sizing:border-box;width:100%;height:100%}.mdc-dialog{display:none;z-index:var(--mdc-dialog-z-index, 7)}.mdc-dialog .mdc-dialog__content{padding:20px 24px 20px 24px}.mdc-dialog .mdc-dialog__surface{min-width:280px}@media(max-width: 592px){.mdc-dialog .mdc-dialog__surface{max-width:calc(100vw - 32px)}}@media(min-width: 592px){.mdc-dialog .mdc-dialog__surface{max-width:560px}}.mdc-dialog .mdc-dialog__surface{max-height:calc(100% - 32px)}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{max-width:none}@media(max-width: 960px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{max-height:560px;width:560px}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__close{right:-12px}}@media(max-width: 720px)and (max-width: 672px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{width:calc(100vw - 112px)}}@media(max-width: 720px)and (min-width: 672px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{width:560px}}@media(max-width: 720px)and (max-height: 720px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{max-height:calc(100vh - 160px)}}@media(max-width: 720px)and (min-height: 720px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{max-height:560px}}@media(max-width: 720px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__close{right:-12px}}@media(max-width: 720px)and (max-height: 400px),(max-width: 600px),(min-width: 720px)and (max-height: 400px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{height:100%;max-height:100vh;max-width:100vw;width:100vw;border-radius:0}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__close{order:-1;left:-12px}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__header{padding:0 16px 9px;justify-content:flex-start}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__title{margin-left:calc(16px - 2 * 12px)}}@media(min-width: 960px){.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface{width:calc(100vw - 400px)}.mdc-dialog.mdc-dialog--fullscreen .mdc-dialog__surface .mdc-dialog__close{right:-12px}}.mdc-dialog.mdc-dialog__scrim--hidden .mdc-dialog__scrim{opacity:0}.mdc-dialog__scrim{opacity:0;z-index:-1}.mdc-dialog__container{display:flex;flex-direction:row;align-items:center;justify-content:space-around;box-sizing:border-box;height:100%;transform:scale(0.8);opacity:0;pointer-events:none}.mdc-dialog__surface{position:relative;display:flex;flex-direction:column;flex-grow:0;flex-shrink:0;box-sizing:border-box;max-width:100%;max-height:100%;pointer-events:auto;overflow-y:auto}.mdc-dialog__surface .mdc-elevation-overlay{width:100%;height:100%;top:0;left:0}[dir=rtl] .mdc-dialog__surface,.mdc-dialog__surface[dir=rtl]{text-align:right}@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-dialog__surface{outline:2px solid windowText}}.mdc-dialog__surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:2px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-dialog__surface::before{border-color:CanvasText}}@media screen and (-ms-high-contrast: active),screen and (-ms-high-contrast: none){.mdc-dialog__surface::before{content:none}}.mdc-dialog__title{display:block;margin-top:0;position:relative;flex-shrink:0;box-sizing:border-box;margin:0 0 1px;padding:0 24px 9px}.mdc-dialog__title::before{display:inline-block;width:0;height:40px;content:"";vertical-align:0}[dir=rtl] .mdc-dialog__title,.mdc-dialog__title[dir=rtl]{text-align:right}.mdc-dialog--scrollable .mdc-dialog__title{margin-bottom:1px;padding-bottom:15px}.mdc-dialog--fullscreen .mdc-dialog__header{align-items:baseline;border-bottom:1px solid rgba(0,0,0,0);display:inline-flex;justify-content:space-between;padding:0 24px 9px;z-index:1}@media screen and (forced-colors: active){.mdc-dialog--fullscreen .mdc-dialog__header{border-bottom-color:CanvasText}}.mdc-dialog--fullscreen .mdc-dialog__header .mdc-dialog__close{right:-12px}.mdc-dialog--fullscreen .mdc-dialog__title{margin-bottom:0;padding:0;border-bottom:0}.mdc-dialog--fullscreen.mdc-dialog--scrollable .mdc-dialog__title{border-bottom:0;margin-bottom:0}.mdc-dialog--fullscreen .mdc-dialog__close{top:5px}.mdc-dialog--fullscreen.mdc-dialog--scrollable .mdc-dialog__actions{border-top:1px solid rgba(0,0,0,0)}@media screen and (forced-colors: active){.mdc-dialog--fullscreen.mdc-dialog--scrollable .mdc-dialog__actions{border-top-color:CanvasText}}.mdc-dialog--fullscreen--titleless .mdc-dialog__close{margin-top:4px}.mdc-dialog--fullscreen--titleless.mdc-dialog--scrollable .mdc-dialog__close{margin-top:0}.mdc-dialog__content{flex-grow:1;box-sizing:border-box;margin:0;overflow:auto}.mdc-dialog__content>:first-child{margin-top:0}.mdc-dialog__content>:last-child{margin-bottom:0}.mdc-dialog__title+.mdc-dialog__content,.mdc-dialog__header+.mdc-dialog__content{padding-top:0}.mdc-dialog--scrollable .mdc-dialog__title+.mdc-dialog__content{padding-top:8px;padding-bottom:8px}.mdc-dialog__content .mdc-deprecated-list:first-child:last-child{padding:6px 0 0}.mdc-dialog--scrollable .mdc-dialog__content .mdc-deprecated-list:first-child:last-child{padding:0}.mdc-dialog__actions{display:flex;position:relative;flex-shrink:0;flex-wrap:wrap;align-items:center;justify-content:flex-end;box-sizing:border-box;min-height:52px;margin:0;padding:8px;border-top:1px solid rgba(0,0,0,0)}@media screen and (forced-colors: active){.mdc-dialog__actions{border-top-color:CanvasText}}.mdc-dialog--stacked .mdc-dialog__actions{flex-direction:column;align-items:flex-end}.mdc-dialog__button{margin-left:8px;margin-right:0;max-width:100%;text-align:right}[dir=rtl] .mdc-dialog__button,.mdc-dialog__button[dir=rtl]{margin-left:0;margin-right:8px}.mdc-dialog__button:first-child{margin-left:0;margin-right:0}[dir=rtl] .mdc-dialog__button:first-child,.mdc-dialog__button:first-child[dir=rtl]{margin-left:0;margin-right:0}[dir=rtl] .mdc-dialog__button,.mdc-dialog__button[dir=rtl]{text-align:left}.mdc-dialog--stacked .mdc-dialog__button:not(:first-child){margin-top:12px}.mdc-dialog--open,.mdc-dialog--opening,.mdc-dialog--closing{display:flex}.mdc-dialog--opening .mdc-dialog__scrim{transition:opacity 150ms linear}.mdc-dialog--opening .mdc-dialog__container{transition:opacity 75ms linear,transform 150ms 0ms cubic-bezier(0, 0, 0.2, 1)}.mdc-dialog--closing .mdc-dialog__scrim,.mdc-dialog--closing .mdc-dialog__container{transition:opacity 75ms linear}.mdc-dialog--closing .mdc-dialog__container{transform:none}.mdc-dialog--open .mdc-dialog__scrim{opacity:1}.mdc-dialog--open .mdc-dialog__container{transform:none;opacity:1}.mdc-dialog--open.mdc-dialog__surface-scrim--shown .mdc-dialog__surface-scrim{opacity:1}.mdc-dialog--open.mdc-dialog__surface-scrim--hiding .mdc-dialog__surface-scrim{transition:opacity 75ms linear}.mdc-dialog--open.mdc-dialog__surface-scrim--showing .mdc-dialog__surface-scrim{transition:opacity 150ms linear}.mdc-dialog__surface-scrim{display:none;opacity:0;position:absolute;width:100%;height:100%;z-index:1}.mdc-dialog__surface-scrim--shown .mdc-dialog__surface-scrim,.mdc-dialog__surface-scrim--showing .mdc-dialog__surface-scrim,.mdc-dialog__surface-scrim--hiding .mdc-dialog__surface-scrim{display:block}.mdc-dialog-scroll-lock{overflow:hidden}.mdc-dialog--no-content-padding .mdc-dialog__content{padding:0}.mdc-dialog--sheet .mdc-dialog__close{right:12px;top:9px;position:absolute;z-index:1}.mdc-dialog__scrim--removed{pointer-events:none}.mdc-dialog__scrim--removed .mdc-dialog__scrim,.mdc-dialog__scrim--removed .mdc-dialog__surface-scrim{display:none}.mat-mdc-dialog-content{max-height:65vh}.mat-mdc-dialog-container{position:static;display:block}.mat-mdc-dialog-container,.mat-mdc-dialog-container .mdc-dialog__container,.mat-mdc-dialog-container .mdc-dialog__surface{max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit}.mat-mdc-dialog-container .mdc-dialog__surface{display:block;width:100%;height:100%}.mat-mdc-dialog-container{outline:0}.mat-mdc-dialog-container .mdc-dialog__surface{background-color:var(--mdc-dialog-container-color, white)}.mat-mdc-dialog-container .mdc-dialog__surface{box-shadow:var(--mdc-dialog-container-elevation, 0px 11px 15px -7px rgba(0, 0, 0, 0.2), 0px 24px 38px 3px rgba(0, 0, 0, 0.14), 0px 9px 46px 8px rgba(0, 0, 0, 0.12))}.mat-mdc-dialog-container .mdc-dialog__surface{border-radius:var(--mdc-dialog-container-shape, var(--mdc-shape-medium, 4px))}.mat-mdc-dialog-container.mdc-dialog--scrollable .mdc-dialog__title,.mat-mdc-dialog-container.mdc-dialog--scrollable .mdc-dialog__actions,.mat-mdc-dialog-container.mdc-dialog--scrollable.mdc-dialog-scroll-divider-footer .mdc-dialog__actions{border-color:var(--mdc-dialog-with-divider-divider-color, black)}.mat-mdc-dialog-container.mdc-dialog--scrollable .mdc-dialog__title{border-bottom-color:var(--mdc-dialog-with-divider-divider-color, black)}.mat-mdc-dialog-container .mdc-dialog__title{font-family:var(--mdc-dialog-subhead-font, "Arial");line-height:var(--mdc-dialog-subhead-line-height, 14px);font-size:var(--mdc-dialog-subhead-size, 14px);font-weight:var(--mdc-dialog-subhead-weight, 500);letter-spacing:var(--mdc-dialog-subhead-tracking, 1px)}.mat-mdc-dialog-container .mdc-dialog__title{color:var(--mdc-dialog-subhead-color, black)}.mat-mdc-dialog-container .mdc-dialog__content{font-family:var(--mdc-dialog-supporting-text-font, "Arial");line-height:var(--mdc-dialog-supporting-text-line-height, 14px);font-size:var(--mdc-dialog-supporting-text-size, 14px);font-weight:var(--mdc-dialog-supporting-text-weight, 500);letter-spacing:var(--mdc-dialog-supporting-text-tracking, 1px)}.mat-mdc-dialog-container .mdc-dialog__content{color:var(--mdc-dialog-supporting-text-color, black)}.mat-mdc-dialog-container .mdc-dialog__container{transition-duration:var(--mat-dialog-transition-duration, 0ms)}.mat-mdc-dialog-container._mat-animation-noopable .mdc-dialog__container{transition:none}.mat-mdc-dialog-content{display:block}.mat-mdc-dialog-actions{justify-content:start}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-center,.mat-mdc-dialog-actions[align=center]{justify-content:center}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-end,.mat-mdc-dialog-actions[align=end]{justify-content:flex-end}.mat-mdc-dialog-actions .mat-button-base+.mat-button-base,.mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-mdc-dialog-actions .mat-button-base+.mat-button-base,[dir=rtl] .mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:0;margin-right:8px}'],encapsulation:2}),n})();class XN{constructor(e,t,i){this._ref=e,this._containerInstance=i,this._afterOpened=new cn,this._beforeClosed=new cn,this._state=0,this.disableClose=t.disableClose,this.id=e.id,i._animationStateChanged.pipe(Ui(r=>"opened"===r.state),Gr(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),i._animationStateChanged.pipe(Ui(r=>"closed"===r.state),Gr(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose()}),e.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose()}),fa(this.backdropClick(),this.keydownEvents().pipe(Ui(r=>27===r.keyCode&&!this.disableClose&&!ql(r)))).subscribe(r=>{this.disableClose||(r.preventDefault(),function JK(n,e,t){n._closeInteractionType=e,n.close(t)}(this,"keydown"===r.type?"keyboard":"mouse"))})}close(e){this._result=e,this._containerInstance._animationStateChanged.pipe(Ui(t=>"closing"===t.state),Gr(1)).subscribe(t=>{this._beforeClosed.next(e),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),t.totalTime+100)}),this._state=1,this._containerInstance._startExitAnimation()}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(e){let t=this._ref.config.positionStrategy;return e&&(e.left||e.right)?e.left?t.left(e.left):t.right(e.right):t.centerHorizontally(),e&&(e.top||e.bottom)?e.top?t.top(e.top):t.bottom(e.bottom):t.centerVertically(),this._ref.updatePosition(),this}updateSize(e="",t=""){return this._ref.updateSize(e,t),this}addPanelClass(e){return this._ref.addPanelClass(e),this}removePanelClass(e){return this._ref.removePanelClass(e),this}getState(){return this._state}_finishDialogClose(){this._state=2,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null}}const ZN=new Ze("MatMdcDialogData"),QK=new Ze("mat-mdc-dialog-default-options"),JN=new Ze("mat-mdc-dialog-scroll-strategy"),tY={provide:JN,deps:[hl],useFactory:function eY(n){return()=>n.scrollStrategies.block()}};let nY=0,iY=(()=>{class n{get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){const t=this._parentDialog;return t?t._getAfterAllClosed():this._afterAllClosedAtThisLevel}constructor(t,i,r,s,o,a,c,u,p,g){this._overlay=t,this._defaultOptions=r,this._parentDialog=s,this._dialogRefConstructor=c,this._dialogContainerType=u,this._dialogDataToken=p,this._openDialogsAtThisLevel=[],this._afterAllClosedAtThisLevel=new cn,this._afterOpenedAtThisLevel=new cn,this._idPrefix="mat-dialog-",this.dialogConfigClass=Xw,this.afterAllClosed=Yv(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(Bf(void 0))),this._scrollStrategy=a,this._dialog=i.get(eA)}open(t,i){let r;(i={...this._defaultOptions||new Xw,...i}).id=i.id||`${this._idPrefix}${nY++}`,i.scrollStrategy=i.scrollStrategy||this._scrollStrategy();const s=this._dialog.open(t,{...i,positionStrategy:this._overlay.position().global().centerHorizontally().centerVertically(),disableClose:!0,closeOnDestroy:!1,closeOnOverlayDetachments:!1,container:{type:this._dialogContainerType,providers:()=>[{provide:this.dialogConfigClass,useValue:i},{provide:Xv,useValue:i}]},templateContext:()=>({dialogRef:r}),providers:(o,a,c)=>(r=new this._dialogRefConstructor(o,i,c),r.updatePosition(i?.position),[{provide:this._dialogContainerType,useValue:c},{provide:this._dialogDataToken,useValue:a.data},{provide:this._dialogRefConstructor,useValue:r}])});return r.componentInstance=s.componentInstance,this.openDialogs.push(r),this.afterOpened.next(r),r.afterClosed().subscribe(()=>{const o=this.openDialogs.indexOf(r);o>-1&&(this.openDialogs.splice(o,1),this.openDialogs.length||this._getAfterAllClosed().next())}),r}closeAll(){this._closeDialogs(this.openDialogs)}getDialogById(t){return this.openDialogs.find(i=>i.id===t)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete()}_closeDialogs(t){let i=t.length;for(;i--;)t[i].close()}}return n.\u0275fac=function(t){Gl()},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),Zw=(()=>{class n extends iY{constructor(t,i,r,s,o,a,c,u){super(t,i,s,a,c,o,XN,ZK,ZN,u),this._idPrefix="mat-mdc-dialog-"}}return n.\u0275fac=function(t){return new(t||n)(xe(hl),xe(ts),xe(Mv,8),xe(QK,8),xe(JN),xe(n,12),xe(qw),xe(bo,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),rY=0,sY=(()=>{class n{constructor(t,i,r){this._dialogRef=t,this._elementRef=i,this._dialog=r,this.id="mat-mdc-dialog-title-"+rY++}ngOnInit(){this._dialogRef||(this._dialogRef=function aY(n,e){let t=n.nativeElement.parentElement;for(;t&&!t.classList.contains("mat-mdc-dialog-container");)t=t.parentElement;return t?e.find(i=>i.id===t.id):null}(this._elementRef,this._dialog.openDialogs)),this._dialogRef&&Promise.resolve().then(()=>{const t=this._dialogRef._containerInstance;t&&!t._ariaLabelledBy&&(t._ariaLabelledBy=this.id)})}}return n.\u0275fac=function(t){return new(t||n)(ie(XN,8),ie(_n),ie(Zw))},n.\u0275dir=ut({type:n,selectors:[["","mat-dialog-title",""],["","matDialogTitle",""]],hostAttrs:[1,"mat-mdc-dialog-title","mdc-dialog__title"],hostVars:1,hostBindings:function(t,i){2&t&&Af("id",i.id)},inputs:{id:"id"},exportAs:["matDialogTitle"]}),n})(),oY=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["","mat-dialog-content",""],["mat-dialog-content"],["","matDialogContent",""]],hostAttrs:[1,"mat-mdc-dialog-content","mdc-dialog__content"]}),n})(),cY=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[Zw,tY],imports:[UN,Kw,Kv,rr,rr]}),n})();function Pc(n,e){return new un(e?t=>e.schedule(lY,0,{error:n,subscriber:t}):t=>t.error(n))}function lY({error:n,subscriber:e}){e.error(n)}function da(n){return function(t){const i=new dY(n),r=t.lift(i);return i.caught=r}}class dY{constructor(e){this.selector=e}call(e,t){return t.subscribe(new uY(e,this.selector,this.caught))}}class uY extends Fs{constructor(e,t,i){super(e),this.selector=t,this.caught=i}error(e){if(!this.isStopped){let t;try{t=this.selector(e,this.caught)}catch(s){return void super.error(s)}this._unsubscribeAndRecycle();const i=new Pt(this,void 0,void 0);this.add(i);const r=$o(this,t,void 0,void 0,i);r!==i&&this.add(r)}}}function Jw(n){return e=>e.lift(new hY(n))}class hY{constructor(e){this.callback=e}call(e,t){return t.subscribe(new fY(e,this.callback))}}class fY extends di{constructor(e,t){super(e),this.add(new Tn(t))}}const pY=["*"];let Qw;function ey(n){return function mY(){if(void 0===Qw&&(Qw=null,typeof window<"u")){const n=window;void 0!==n.trustedTypes&&(Qw=n.trustedTypes.createPolicy("angular#components",{createHTML:e=>e}))}return Qw}()?.createHTML(n)||n}function e4(n){return Error(`Unable to find icon with the name "${n}"`)}function t4(n){return Error(`The URL provided to MatIconRegistry was not trusted as a resource URL via Angular's DomSanitizer. Attempted URL was "${n}".`)}function n4(n){return Error(`The literal provided to MatIconRegistry was not trusted as safe HTML by Angular's DomSanitizer. Attempted literal was "${n}".`)}class Uf{constructor(e,t,i){this.url=e,this.svgText=t,this.options=i}}let eS=(()=>{class n{constructor(t,i,r,s){this._httpClient=t,this._sanitizer=i,this._errorHandler=s,this._svgIconConfigs=new Map,this._iconSetConfigs=new Map,this._cachedIconsByUrl=new Map,this._inProgressUrlFetches=new Map,this._fontCssClassesByAlias=new Map,this._resolvers=[],this._defaultFontSetClass=["material-icons","mat-ligature-font"],this._document=r}addSvgIcon(t,i,r){return this.addSvgIconInNamespace("",t,i,r)}addSvgIconLiteral(t,i,r){return this.addSvgIconLiteralInNamespace("",t,i,r)}addSvgIconInNamespace(t,i,r,s){return this._addSvgIconConfig(t,i,new Uf(r,null,s))}addSvgIconResolver(t){return this._resolvers.push(t),this}addSvgIconLiteralInNamespace(t,i,r,s){const o=this._sanitizer.sanitize(Ri.HTML,r);if(!o)throw n4(r);const a=ey(o);return this._addSvgIconConfig(t,i,new Uf("",a,s))}addSvgIconSet(t,i){return this.addSvgIconSetInNamespace("",t,i)}addSvgIconSetLiteral(t,i){return this.addSvgIconSetLiteralInNamespace("",t,i)}addSvgIconSetInNamespace(t,i,r){return this._addSvgIconSetConfig(t,new Uf(i,null,r))}addSvgIconSetLiteralInNamespace(t,i,r){const s=this._sanitizer.sanitize(Ri.HTML,i);if(!s)throw n4(i);const o=ey(s);return this._addSvgIconSetConfig(t,new Uf("",o,r))}registerFontClassAlias(t,i=t){return this._fontCssClassesByAlias.set(t,i),this}classNameForFontAlias(t){return this._fontCssClassesByAlias.get(t)||t}setDefaultFontSetClass(...t){return this._defaultFontSetClass=t,this}getDefaultFontSetClass(){return this._defaultFontSetClass}getSvgIconFromUrl(t){const i=this._sanitizer.sanitize(Ri.RESOURCE_URL,t);if(!i)throw t4(t);const r=this._cachedIconsByUrl.get(i);return r?Tt(tS(r)):this._loadSvgIconFromConfig(new Uf(t,null)).pipe(Dr(s=>this._cachedIconsByUrl.set(i,s)),_t(s=>tS(s)))}getNamedSvgIcon(t,i=""){const r=i4(i,t);let s=this._svgIconConfigs.get(r);if(s)return this._getSvgFromConfig(s);if(s=this._getIconConfigFromResolvers(i,t),s)return this._svgIconConfigs.set(r,s),this._getSvgFromConfig(s);const o=this._iconSetConfigs.get(i);return o?this._getSvgFromIconSetConfigs(t,o):Pc(e4(r))}ngOnDestroy(){this._resolvers=[],this._svgIconConfigs.clear(),this._iconSetConfigs.clear(),this._cachedIconsByUrl.clear()}_getSvgFromConfig(t){return t.svgText?Tt(tS(this._svgElementFromConfig(t))):this._loadSvgIconFromConfig(t).pipe(_t(i=>tS(i)))}_getSvgFromIconSetConfigs(t,i){const r=this._extractIconWithNameFromAnySet(t,i);return r?Tt(r):ig(i.filter(o=>!o.svgText).map(o=>this._loadSvgIconSetFromConfig(o).pipe(da(a=>{const u=`Loading icon set URL: ${this._sanitizer.sanitize(Ri.RESOURCE_URL,o.url)} failed: ${a.message}`;return this._errorHandler.handleError(new Error(u)),Tt(null)})))).pipe(_t(()=>{const o=this._extractIconWithNameFromAnySet(t,i);if(!o)throw e4(t);return o}))}_extractIconWithNameFromAnySet(t,i){for(let r=i.length-1;r>=0;r--){const s=i[r];if(s.svgText&&s.svgText.toString().indexOf(t)>-1){const o=this._svgElementFromConfig(s),a=this._extractSvgIconFromSet(o,t,s.options);if(a)return a}}return null}_loadSvgIconFromConfig(t){return this._fetchIcon(t).pipe(Dr(i=>t.svgText=i),_t(()=>this._svgElementFromConfig(t)))}_loadSvgIconSetFromConfig(t){return t.svgText?Tt(null):this._fetchIcon(t).pipe(Dr(i=>t.svgText=i))}_extractSvgIconFromSet(t,i,r){const s=t.querySelector(`[id="${i}"]`);if(!s)return null;const o=s.cloneNode(!0);if(o.removeAttribute("id"),"svg"===o.nodeName.toLowerCase())return this._setSvgAttributes(o,r);if("symbol"===o.nodeName.toLowerCase())return this._setSvgAttributes(this._toSvgElement(o),r);const a=this._svgElementFromString(ey(""));return a.appendChild(o),this._setSvgAttributes(a,r)}_svgElementFromString(t){const i=this._document.createElement("DIV");i.innerHTML=t;const r=i.querySelector("svg");if(!r)throw Error(" tag not found");return r}_toSvgElement(t){const i=this._svgElementFromString(ey("")),r=t.attributes;for(let s=0;sey(u)),Jw(()=>this._inProgressUrlFetches.delete(o)),Dp());return this._inProgressUrlFetches.set(o,c),c}_addSvgIconConfig(t,i,r){return this._svgIconConfigs.set(i4(t,i),r),this}_addSvgIconSetConfig(t,i){const r=this._iconSetConfigs.get(t);return r?r.push(i):this._iconSetConfigs.set(t,[i]),this}_svgElementFromConfig(t){if(!t.svgElement){const i=this._svgElementFromString(t.svgText);this._setSvgAttributes(i,t.options),t.svgElement=i}return t.svgElement}_getIconConfigFromResolvers(t,i){for(let r=0;re?e.pathname+e.search:""}}}),r4=["clip-path","color-profile","src","cursor","fill","filter","marker","marker-start","marker-mid","marker-end","mask","stroke"],SY=r4.map(n=>`[${n}]`).join(", "),EY=/^url\(['"]?#(.*?)['"]?\)$/;let nS=(()=>{class n extends yY{get inline(){return this._inline}set inline(t){this._inline=bi(t)}get svgIcon(){return this._svgIcon}set svgIcon(t){t!==this._svgIcon&&(t?this._updateSvgIcon(t):this._svgIcon&&this._clearSvgElement(),this._svgIcon=t)}get fontSet(){return this._fontSet}set fontSet(t){const i=this._cleanupFontValue(t);i!==this._fontSet&&(this._fontSet=i,this._updateFontIconClasses())}get fontIcon(){return this._fontIcon}set fontIcon(t){const i=this._cleanupFontValue(t);i!==this._fontIcon&&(this._fontIcon=i,this._updateFontIconClasses())}constructor(t,i,r,s,o,a){super(t),this._iconRegistry=i,this._location=s,this._errorHandler=o,this._inline=!1,this._previousFontSetClass=[],this._currentIconFetch=Tn.EMPTY,a&&(a.color&&(this.color=this.defaultColor=a.color),a.fontSet&&(this.fontSet=a.fontSet)),r||t.nativeElement.setAttribute("aria-hidden","true")}_splitIconName(t){if(!t)return["",""];const i=t.split(":");switch(i.length){case 1:return["",i[0]];case 2:return i;default:throw Error(`Invalid icon name: "${t}"`)}}ngOnInit(){this._updateFontIconClasses()}ngAfterViewChecked(){const t=this._elementsWithExternalReferences;if(t&&t.size){const i=this._location.getPathname();i!==this._previousPath&&(this._previousPath=i,this._prependPathToReferences(i))}}ngOnDestroy(){this._currentIconFetch.unsubscribe(),this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear()}_usingFontIcon(){return!this.svgIcon}_setSvgElement(t){this._clearSvgElement();const i=this._location.getPathname();this._previousPath=i,this._cacheChildrenWithExternalReferences(t),this._prependPathToReferences(i),this._elementRef.nativeElement.appendChild(t)}_clearSvgElement(){const t=this._elementRef.nativeElement;let i=t.childNodes.length;for(this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear();i--;){const r=t.childNodes[i];(1!==r.nodeType||"svg"===r.nodeName.toLowerCase())&&r.remove()}}_updateFontIconClasses(){if(!this._usingFontIcon())return;const t=this._elementRef.nativeElement,i=(this.fontSet?this._iconRegistry.classNameForFontAlias(this.fontSet).split(/ +/):this._iconRegistry.getDefaultFontSetClass()).filter(r=>r.length>0);this._previousFontSetClass.forEach(r=>t.classList.remove(r)),i.forEach(r=>t.classList.add(r)),this._previousFontSetClass=i,this.fontIcon!==this._previousFontIconClass&&!i.includes("mat-ligature-font")&&(this._previousFontIconClass&&t.classList.remove(this._previousFontIconClass),this.fontIcon&&t.classList.add(this.fontIcon),this._previousFontIconClass=this.fontIcon)}_cleanupFontValue(t){return"string"==typeof t?t.trim().split(" ")[0]:t}_prependPathToReferences(t){const i=this._elementsWithExternalReferences;i&&i.forEach((r,s)=>{r.forEach(o=>{s.setAttribute(o.name,`url('${t}#${o.value}')`)})})}_cacheChildrenWithExternalReferences(t){const i=t.querySelectorAll(SY),r=this._elementsWithExternalReferences=this._elementsWithExternalReferences||new Map;for(let s=0;s{const a=i[s],c=a.getAttribute(o),u=c?c.match(EY):null;if(u){let p=r.get(a);p||(p=[],r.set(a,p)),p.push({name:o,value:u[1]})}})}_updateSvgIcon(t){if(this._svgNamespace=null,this._svgName=null,this._currentIconFetch.unsubscribe(),t){const[i,r]=this._splitIconName(t);i&&(this._svgNamespace=i),r&&(this._svgName=r),this._currentIconFetch=this._iconRegistry.getNamedSvgIcon(r,i).pipe(Gr(1)).subscribe(s=>this._setSvgElement(s),s=>{this._errorHandler.handleError(new Error(`Error retrieving icon ${i}:${r}! ${s.message}`))})}}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(eS),Kc("aria-hidden"),ie(xY),ie(tl),ie(bY,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-icon"]],hostAttrs:["role","img",1,"mat-icon","notranslate"],hostVars:8,hostBindings:function(t,i){2&t&&(Di("data-mat-icon-type",i._usingFontIcon()?"font":"svg")("data-mat-icon-name",i._svgName||i.fontIcon)("data-mat-icon-namespace",i._svgNamespace||i.fontSet)("fontIcon",i._usingFontIcon()?i.fontIcon:null),hi("mat-icon-inline",i.inline)("mat-icon-no-color","primary"!==i.color&&"accent"!==i.color&&"warn"!==i.color))},inputs:{color:"color",inline:"inline",svgIcon:"svgIcon",fontSet:"fontSet",fontIcon:"fontIcon"},exportAs:["matIcon"],features:[Z],ngContentSelectors:pY,decls:1,vars:0,template:function(t,i){1&t&&(Hs(),En(0))},styles:[".mat-icon{-webkit-user-select:none;user-select:none;background-repeat:no-repeat;display:inline-block;fill:currentColor;height:24px;width:24px;overflow:hidden}.mat-icon.mat-icon-inline{font-size:inherit;height:inherit;line-height:inherit;width:inherit}.mat-icon.mat-ligature-font[fontIcon]::before{content:attr(fontIcon)}[dir=rtl] .mat-icon-rtl-mirror{transform:scale(-1, 1)}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon{display:block}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button .mat-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mat-icon{margin:auto}"],encapsulation:2,changeDetection:0}),n})(),s4=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,rr]}),n})();const MY=["matFormFieldNotchedOutline",""],CY=["*"],DY=["textField"],TY=["iconPrefixContainer"],AY=["textPrefixContainer"];function kY(n,e){1&n&&qt(0,"span",19)}function IY(n,e){if(1&n){const t=Df();ke(0,"label",17),Gn("cdkObserveContent",function(){return R(t),V(Jt(2)._refreshOutlineNotchWidth())}),En(1,1),mt(2,kY,1,0,"span",18),Ne()}if(2&n){const t=Jt(2);$e("floating",t._shouldLabelFloat())("cdkObserveContentDisabled",!t._hasOutline())("id",t._labelId),Di("for",t._control.id)("aria-owns",t._control.id),Le(2),$e("ngIf",!t.hideRequiredMarker&&t._control.required)}}function FY(n,e){1&n&&mt(0,IY,3,6,"label",16),2&n&&$e("ngIf",Jt()._hasFloatingLabel())}function RY(n,e){1&n&&qt(0,"div",20)}function PY(n,e){}function OY(n,e){1&n&&mt(0,PY,0,0,"ng-template",22),2&n&&(Jt(2),$e("ngTemplateOutlet",Tc(1)))}function LY(n,e){if(1&n&&(ke(0,"div",21),mt(1,OY,1,1,"ng-template",9),Ne()),2&n){const t=Jt();$e("matFormFieldNotchedOutlineOpen",t._shouldLabelFloat())("matFormFieldNotchedOutlineLabelWidth",t._labelWidth),Le(1),$e("ngIf",!t._forceDisplayInfixLabel())}}function NY(n,e){1&n&&(ke(0,"div",23,24),En(2,2),Ne())}function BY(n,e){1&n&&(ke(0,"div",25,26),En(2,3),Ne())}function VY(n,e){}function HY(n,e){1&n&&mt(0,VY,0,0,"ng-template",22),2&n&&(Jt(),$e("ngTemplateOutlet",Tc(1)))}function UY(n,e){1&n&&(ke(0,"div",27),En(1,4),Ne())}function zY(n,e){1&n&&(ke(0,"div",28),En(1,5),Ne())}function GY(n,e){1&n&&qt(0,"div",29)}function jY(n,e){1&n&&(ke(0,"div",30),En(1,6),Ne()),2&n&&$e("@transitionMessages",Jt()._subscriptAnimationState)}function WY(n,e){if(1&n&&(ke(0,"mat-hint",34),it(1),Ne()),2&n){const t=Jt(2);$e("id",t._hintLabelId),Le(1),Hi(t.hintLabel)}}function $Y(n,e){if(1&n&&(ke(0,"div",31),mt(1,WY,2,2,"mat-hint",32),En(2,7),qt(3,"div",33),En(4,8),Ne()),2&n){const t=Jt();$e("@transitionMessages",t._subscriptAnimationState),Le(1),$e("ngIf",t.hintLabel)}}const qY=["*",[["mat-label"]],[["","matPrefix",""],["","matIconPrefix",""]],[["","matTextPrefix",""]],[["","matTextSuffix",""]],[["","matSuffix",""],["","matIconSuffix",""]],[["mat-error"],["","matError",""]],[["mat-hint",3,"align","end"]],[["mat-hint","align","end"]]],KY=["*","mat-label","[matPrefix], [matIconPrefix]","[matTextPrefix]","[matTextSuffix]","[matSuffix], [matIconSuffix]","mat-error, [matError]","mat-hint:not([align='end'])","mat-hint[align='end']"];let o4=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["mat-label"]]}),n})();const YY=new Ze("MatError");let XY=0,a4=(()=>{class n{constructor(){this.align="start",this.id="mat-mdc-hint-"+XY++}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["mat-hint"]],hostAttrs:[1,"mat-mdc-form-field-hint","mat-mdc-form-field-bottom-align"],hostVars:4,hostBindings:function(t,i){2&t&&(Af("id",i.id),Di("align",null),hi("mat-mdc-form-field-hint-end","end"===i.align))},inputs:{align:"align",id:"id"}}),n})();const ZY=new Ze("MatPrefix"),JY=new Ze("MatSuffix");let c4=(()=>{class n{constructor(t){this._elementRef=t,this.floating=!1}getWidth(){return function QY(n){if(null!==n.offsetParent)return n.scrollWidth;const t=n.cloneNode(!0);t.style.setProperty("position","absolute"),t.style.setProperty("transform","translate(-9999px, -9999px)"),document.documentElement.appendChild(t);const i=t.scrollWidth;return t.remove(),i}(this._elementRef.nativeElement)}get element(){return this._elementRef.nativeElement}}return n.\u0275fac=function(t){return new(t||n)(ie(_n))},n.\u0275dir=ut({type:n,selectors:[["label","matFormFieldFloatingLabel",""]],hostAttrs:[1,"mdc-floating-label","mat-mdc-floating-label"],hostVars:2,hostBindings:function(t,i){2&t&&hi("mdc-floating-label--float-above",i.floating)},inputs:{floating:"floating"}}),n})();const l4="mdc-line-ripple--active",iS="mdc-line-ripple--deactivating";let d4=(()=>{class n{constructor(t,i){this._elementRef=t,this._handleTransitionEnd=r=>{const s=this._elementRef.nativeElement.classList,o=s.contains(iS);"opacity"===r.propertyName&&o&&s.remove(l4,iS)},i.runOutsideAngular(()=>{t.nativeElement.addEventListener("transitionend",this._handleTransitionEnd)})}activate(){const t=this._elementRef.nativeElement.classList;t.remove(iS),t.add(l4)}deactivate(){this._elementRef.nativeElement.classList.add(iS)}ngOnDestroy(){this._elementRef.nativeElement.removeEventListener("transitionend",this._handleTransitionEnd)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Xt))},n.\u0275dir=ut({type:n,selectors:[["div","matFormFieldLineRipple",""]],hostAttrs:[1,"mdc-line-ripple"]}),n})(),u4=(()=>{class n{constructor(t,i){this._elementRef=t,this._ngZone=i,this.labelWidth=0,this.open=!1}ngAfterViewInit(){const t=this._elementRef.nativeElement.querySelector(".mdc-floating-label");t?(this._elementRef.nativeElement.classList.add("mdc-notched-outline--upgraded"),"function"==typeof requestAnimationFrame&&(t.style.transitionDuration="0s",this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>t.style.transitionDuration="")}))):this._elementRef.nativeElement.classList.add("mdc-notched-outline--no-label")}_getNotchWidth(){return this.open?this.labelWidth>0?`calc(${this.labelWidth}px * var(--mat-mdc-form-field-floating-label-scale, 0.75) + 9px)`:"0px":null}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Xt))},n.\u0275cmp=Ln({type:n,selectors:[["div","matFormFieldNotchedOutline",""]],hostAttrs:[1,"mdc-notched-outline"],hostVars:2,hostBindings:function(t,i){2&t&&hi("mdc-notched-outline--notched",i.open)},inputs:{labelWidth:["matFormFieldNotchedOutlineLabelWidth","labelWidth"],open:["matFormFieldNotchedOutlineOpen","open"]},attrs:MY,ngContentSelectors:CY,decls:4,vars:2,consts:[[1,"mdc-notched-outline__leading"],[1,"mdc-notched-outline__notch"],[1,"mdc-notched-outline__trailing"]],template:function(t,i){1&t&&(Hs(),qt(0,"div",0),ke(1,"div",1),En(2),Ne(),qt(3,"div",2)),2&t&&(Le(1),dv("width",i._getNotchWidth()))},encapsulation:2,changeDetection:0}),n})();const eX={transitionMessages:fg("transitionMessages",[sh("enter",la({opacity:1,transform:"translateY(0%)"})),Xl("void => enter",[la({opacity:0,transform:"translateY(-5px)"}),zd("300ms cubic-bezier(0.55, 0, 0.55, 0.2)")])])};let h4=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n}),n})();const f4=new Ze("MatFormField"),tX=new Ze("MAT_FORM_FIELD_DEFAULT_OPTIONS");let p4=0,_4=(()=>{class n{get hideRequiredMarker(){return this._hideRequiredMarker}set hideRequiredMarker(t){this._hideRequiredMarker=bi(t)}get floatLabel(){return this._floatLabel||this._defaults?.floatLabel||"auto"}set floatLabel(t){t!==this._floatLabel&&(this._floatLabel=t,this._changeDetectorRef.markForCheck())}get appearance(){return this._appearance}set appearance(t){const i=this._appearance;this._appearance=t||this._defaults?.appearance||"fill","outline"===this._appearance&&this._appearance!==i&&(this._refreshOutlineNotchWidth(),this._needsOutlineLabelOffsetUpdateOnStable=!0)}get subscriptSizing(){return this._subscriptSizing||this._defaults?.subscriptSizing||"fixed"}set subscriptSizing(t){this._subscriptSizing=t||this._defaults?.subscriptSizing||"fixed"}get hintLabel(){return this._hintLabel}set hintLabel(t){this._hintLabel=t,this._processHints()}get _control(){return this._explicitFormFieldControl||this._formFieldControl}set _control(t){this._explicitFormFieldControl=t}constructor(t,i,r,s,o,a,c,u){this._elementRef=t,this._changeDetectorRef=i,this._ngZone=r,this._dir=s,this._platform=o,this._defaults=a,this._animationMode=c,this._document=u,this._hideRequiredMarker=!1,this.color="primary",this._appearance="fill",this._subscriptSizing=null,this._hintLabel="",this._hasIconPrefix=!1,this._hasTextPrefix=!1,this._hasIconSuffix=!1,this._hasTextSuffix=!1,this._labelId="mat-mdc-form-field-label-"+p4++,this._hintLabelId="mat-mdc-hint-"+p4++,this._subscriptAnimationState="",this._labelWidth=0,this._destroyed=new cn,this._isFocused=null,this._needsOutlineLabelOffsetUpdateOnStable=!1,a&&(a.appearance&&(this.appearance=a.appearance),this._hideRequiredMarker=Boolean(a?.hideRequiredMarker),a.color&&(this.color=a.color))}ngAfterViewInit(){this._updateFocusState(),this._refreshOutlineNotchWidth(),this._document?.fonts?.ready?this._document.fonts.ready.then(()=>{this._refreshOutlineNotchWidth(),this._changeDetectorRef.markForCheck()}):setTimeout(()=>this._refreshOutlineNotchWidth(),100),this._subscriptAnimationState="enter",this._changeDetectorRef.detectChanges()}ngAfterContentInit(){this._assertFormFieldControl(),this._initializeControl(),this._initializeSubscript(),this._initializePrefixAndSuffix(),this._initializeOutlineLabelOffsetSubscriptions()}ngAfterContentChecked(){this._assertFormFieldControl()}ngOnDestroy(){this._destroyed.next(),this._destroyed.complete()}getLabelId(){return this._hasFloatingLabel()?this._labelId:null}getConnectedOverlayOrigin(){return this._textField||this._elementRef}_animateAndLockLabel(){this._hasFloatingLabel()&&(this.floatLabel="always")}_initializeControl(){const t=this._control;t.controlType&&this._elementRef.nativeElement.classList.add(`mat-mdc-form-field-type-${t.controlType}`),t.stateChanges.subscribe(()=>{this._updateFocusState(),this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),t.ngControl&&t.ngControl.valueChanges&&t.ngControl.valueChanges.pipe(Tr(this._destroyed)).subscribe(()=>this._changeDetectorRef.markForCheck())}_checkPrefixAndSuffixTypes(){this._hasIconPrefix=!!this._prefixChildren.find(t=>!t._isText),this._hasTextPrefix=!!this._prefixChildren.find(t=>t._isText),this._hasIconSuffix=!!this._suffixChildren.find(t=>!t._isText),this._hasTextSuffix=!!this._suffixChildren.find(t=>t._isText)}_initializePrefixAndSuffix(){this._checkPrefixAndSuffixTypes(),fa(this._prefixChildren.changes,this._suffixChildren.changes).subscribe(()=>{this._checkPrefixAndSuffixTypes(),this._changeDetectorRef.markForCheck()})}_initializeSubscript(){this._hintChildren.changes.subscribe(()=>{this._processHints(),this._changeDetectorRef.markForCheck()}),this._errorChildren.changes.subscribe(()=>{this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),this._validateHints(),this._syncDescribedByIds()}_assertFormFieldControl(){}_updateFocusState(){this._control.focused&&!this._isFocused?(this._isFocused=!0,this._lineRipple?.activate()):!this._control.focused&&(this._isFocused||null===this._isFocused)&&(this._isFocused=!1,this._lineRipple?.deactivate()),this._textField?.nativeElement.classList.toggle("mdc-text-field--focused",this._control.focused)}_initializeOutlineLabelOffsetSubscriptions(){this._prefixChildren.changes.subscribe(()=>this._needsOutlineLabelOffsetUpdateOnStable=!0),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.pipe(Tr(this._destroyed)).subscribe(()=>{this._needsOutlineLabelOffsetUpdateOnStable&&(this._needsOutlineLabelOffsetUpdateOnStable=!1,this._updateOutlineLabelOffset())})}),this._dir.change.pipe(Tr(this._destroyed)).subscribe(()=>this._needsOutlineLabelOffsetUpdateOnStable=!0)}_shouldAlwaysFloat(){return"always"===this.floatLabel}_hasOutline(){return"outline"===this.appearance}_forceDisplayInfixLabel(){return!this._platform.isBrowser&&this._prefixChildren.length&&!this._shouldLabelFloat()}_hasFloatingLabel(){return!!this._labelChildNonStatic||!!this._labelChildStatic}_shouldLabelFloat(){return this._control.shouldLabelFloat||this._shouldAlwaysFloat()}_shouldForward(t){const i=this._control?this._control.ngControl:null;return i&&i[t]}_getDisplayedMessages(){return this._errorChildren&&this._errorChildren.length>0&&this._control.errorState?"error":"hint"}_refreshOutlineNotchWidth(){!this._hasOutline()||!this._floatingLabel||(this._labelWidth=this._floatingLabel.getWidth())}_processHints(){this._validateHints(),this._syncDescribedByIds()}_validateHints(){}_syncDescribedByIds(){if(this._control){let t=[];if(this._control.userAriaDescribedBy&&"string"==typeof this._control.userAriaDescribedBy&&t.push(...this._control.userAriaDescribedBy.split(" ")),"hint"===this._getDisplayedMessages()){const i=this._hintChildren?this._hintChildren.find(s=>"start"===s.align):null,r=this._hintChildren?this._hintChildren.find(s=>"end"===s.align):null;i?t.push(i.id):this._hintLabel&&t.push(this._hintLabelId),r&&t.push(r.id)}else this._errorChildren&&t.push(...this._errorChildren.map(i=>i.id));this._control.setDescribedByIds(t)}}_updateOutlineLabelOffset(){if(!this._platform.isBrowser||!this._hasOutline()||!this._floatingLabel)return;const t=this._floatingLabel.element;if(!this._iconPrefixContainer&&!this._textPrefixContainer)return void(t.style.transform="");if(!this._isAttachedToDom())return void(this._needsOutlineLabelOffsetUpdateOnStable=!0);const i=this._iconPrefixContainer?.nativeElement,r=this._textPrefixContainer?.nativeElement,s=i?.getBoundingClientRect().width??0,o=r?.getBoundingClientRect().width??0;t.style.transform=`var(\n --mat-mdc-form-field-label-transform,\n translateY(-50%) translateX(calc(${"rtl"===this._dir.value?"-1":"1"} * (${s+o}px + var(--mat-mdc-form-field-label-offset-x, 0px))))\n )`}_isAttachedToDom(){const t=this._elementRef.nativeElement;if(t.getRootNode){const i=t.getRootNode();return i&&i!==t}return document.documentElement.contains(t)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(aa),ie(Xt),ie(Yl),ie(as),ie(tX,8),ie(bo,8),ie(Mn))},n.\u0275cmp=Ln({type:n,selectors:[["mat-form-field"]],contentQueries:function(t,i,r){if(1&t&&(is(r,o4,5),is(r,o4,7),is(r,h4,5),is(r,ZY,5),is(r,JY,5),is(r,YY,5),is(r,a4,5)),2&t){let s;Yn(s=Xn())&&(i._labelChildNonStatic=s.first),Yn(s=Xn())&&(i._labelChildStatic=s.first),Yn(s=Xn())&&(i._formFieldControl=s.first),Yn(s=Xn())&&(i._prefixChildren=s),Yn(s=Xn())&&(i._suffixChildren=s),Yn(s=Xn())&&(i._errorChildren=s),Yn(s=Xn())&&(i._hintChildren=s)}},viewQuery:function(t,i){if(1&t&&(zr(DY,5),zr(TY,5),zr(AY,5),zr(c4,5),zr(u4,5),zr(d4,5)),2&t){let r;Yn(r=Xn())&&(i._textField=r.first),Yn(r=Xn())&&(i._iconPrefixContainer=r.first),Yn(r=Xn())&&(i._textPrefixContainer=r.first),Yn(r=Xn())&&(i._floatingLabel=r.first),Yn(r=Xn())&&(i._notchedOutline=r.first),Yn(r=Xn())&&(i._lineRipple=r.first)}},hostAttrs:[1,"mat-mdc-form-field"],hostVars:42,hostBindings:function(t,i){2&t&&hi("mat-mdc-form-field-label-always-float",i._shouldAlwaysFloat())("mat-mdc-form-field-has-icon-prefix",i._hasIconPrefix)("mat-mdc-form-field-has-icon-suffix",i._hasIconSuffix)("mat-form-field-invalid",i._control.errorState)("mat-form-field-disabled",i._control.disabled)("mat-form-field-autofilled",i._control.autofilled)("mat-form-field-no-animations","NoopAnimations"===i._animationMode)("mat-form-field-appearance-fill","fill"==i.appearance)("mat-form-field-appearance-outline","outline"==i.appearance)("mat-form-field-hide-placeholder",i._hasFloatingLabel()&&!i._shouldLabelFloat())("mat-focused",i._control.focused)("mat-primary","accent"!==i.color&&"warn"!==i.color)("mat-accent","accent"===i.color)("mat-warn","warn"===i.color)("ng-untouched",i._shouldForward("untouched"))("ng-touched",i._shouldForward("touched"))("ng-pristine",i._shouldForward("pristine"))("ng-dirty",i._shouldForward("dirty"))("ng-valid",i._shouldForward("valid"))("ng-invalid",i._shouldForward("invalid"))("ng-pending",i._shouldForward("pending"))},inputs:{hideRequiredMarker:"hideRequiredMarker",color:"color",floatLabel:"floatLabel",appearance:"appearance",subscriptSizing:"subscriptSizing",hintLabel:"hintLabel"},exportAs:["matFormField"],features:[Oi([{provide:f4,useExisting:n}])],ngContentSelectors:KY,decls:18,vars:23,consts:[["labelTemplate",""],[1,"mat-mdc-text-field-wrapper","mdc-text-field",3,"click"],["textField",""],["class","mat-mdc-form-field-focus-overlay",4,"ngIf"],[1,"mat-mdc-form-field-flex"],["matFormFieldNotchedOutline","",3,"matFormFieldNotchedOutlineOpen","matFormFieldNotchedOutlineLabelWidth",4,"ngIf"],["class","mat-mdc-form-field-icon-prefix",4,"ngIf"],["class","mat-mdc-form-field-text-prefix",4,"ngIf"],[1,"mat-mdc-form-field-infix"],[3,"ngIf"],["class","mat-mdc-form-field-text-suffix",4,"ngIf"],["class","mat-mdc-form-field-icon-suffix",4,"ngIf"],["matFormFieldLineRipple","",4,"ngIf"],[1,"mat-mdc-form-field-subscript-wrapper","mat-mdc-form-field-bottom-align",3,"ngSwitch"],["class","mat-mdc-form-field-error-wrapper",4,"ngSwitchCase"],["class","mat-mdc-form-field-hint-wrapper",4,"ngSwitchCase"],["matFormFieldFloatingLabel","",3,"floating","cdkObserveContentDisabled","id","cdkObserveContent",4,"ngIf"],["matFormFieldFloatingLabel","",3,"floating","cdkObserveContentDisabled","id","cdkObserveContent"],["aria-hidden","true","class","mat-mdc-form-field-required-marker mdc-floating-label--required",4,"ngIf"],["aria-hidden","true",1,"mat-mdc-form-field-required-marker","mdc-floating-label--required"],[1,"mat-mdc-form-field-focus-overlay"],["matFormFieldNotchedOutline","",3,"matFormFieldNotchedOutlineOpen","matFormFieldNotchedOutlineLabelWidth"],[3,"ngTemplateOutlet"],[1,"mat-mdc-form-field-icon-prefix"],["iconPrefixContainer",""],[1,"mat-mdc-form-field-text-prefix"],["textPrefixContainer",""],[1,"mat-mdc-form-field-text-suffix"],[1,"mat-mdc-form-field-icon-suffix"],["matFormFieldLineRipple",""],[1,"mat-mdc-form-field-error-wrapper"],[1,"mat-mdc-form-field-hint-wrapper"],[3,"id",4,"ngIf"],[1,"mat-mdc-form-field-hint-spacer"],[3,"id"]],template:function(t,i){1&t&&(Hs(qY),mt(0,FY,1,1,"ng-template",null,0,wv),ke(2,"div",1,2),Gn("click",function(s){return i._control.onContainerClick&&i._control.onContainerClick(s)}),mt(4,RY,1,0,"div",3),ke(5,"div",4),mt(6,LY,2,3,"div",5),mt(7,NY,3,0,"div",6),mt(8,BY,3,0,"div",7),ke(9,"div",8),mt(10,HY,1,1,"ng-template",9),En(11),Ne(),mt(12,UY,2,0,"div",10),mt(13,zY,2,0,"div",11),Ne(),mt(14,GY,1,0,"div",12),Ne(),ke(15,"div",13),mt(16,jY,2,1,"div",14),mt(17,$Y,5,2,"div",15),Ne()),2&t&&(Le(2),hi("mdc-text-field--filled",!i._hasOutline())("mdc-text-field--outlined",i._hasOutline())("mdc-text-field--no-label",!i._hasFloatingLabel())("mdc-text-field--disabled",i._control.disabled)("mdc-text-field--invalid",i._control.errorState),Le(2),$e("ngIf",!i._hasOutline()&&!i._control.disabled),Le(2),$e("ngIf",i._hasOutline()),Le(1),$e("ngIf",i._hasIconPrefix),Le(1),$e("ngIf",i._hasTextPrefix),Le(2),$e("ngIf",!i._hasOutline()||i._forceDisplayInfixLabel()),Le(2),$e("ngIf",i._hasTextSuffix),Le(1),$e("ngIf",i._hasIconSuffix),Le(1),$e("ngIf",!i._hasOutline()),Le(1),hi("mat-mdc-form-field-subscript-dynamic-size","dynamic"===i.subscriptSizing),$e("ngSwitch",i._getDisplayedMessages()),Le(1),$e("ngSwitchCase","error"),Le(1),$e("ngSwitchCase","hint"))},dependencies:[Yu,BD,Tv,ND,IT,a4,c4,u4,d4],styles:['.mdc-text-field{border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:0;border-bottom-left-radius:0;display:inline-flex;align-items:baseline;padding:0 16px;position:relative;box-sizing:border-box;overflow:hidden;will-change:opacity,transform,color}.mdc-text-field .mdc-floating-label{top:50%;transform:translateY(-50%);pointer-events:none}.mdc-text-field__input{height:28px;width:100%;min-width:0;border:none;border-radius:0;background:none;appearance:none;padding:0}.mdc-text-field__input::-ms-clear{display:none}.mdc-text-field__input::-webkit-calendar-picker-indicator{display:none}.mdc-text-field__input:focus{outline:none}.mdc-text-field__input:invalid{box-shadow:none}@media all{.mdc-text-field__input::placeholder{opacity:0}}@media all{.mdc-text-field__input:-ms-input-placeholder{opacity:0}}@media all{.mdc-text-field--no-label .mdc-text-field__input::placeholder,.mdc-text-field--focused .mdc-text-field__input::placeholder{opacity:1}}@media all{.mdc-text-field--no-label .mdc-text-field__input:-ms-input-placeholder,.mdc-text-field--focused .mdc-text-field__input:-ms-input-placeholder{opacity:1}}.mdc-text-field__affix{height:28px;opacity:0;white-space:nowrap}.mdc-text-field--label-floating .mdc-text-field__affix,.mdc-text-field--no-label .mdc-text-field__affix{opacity:1}@supports(-webkit-hyphens: none){.mdc-text-field--outlined .mdc-text-field__affix{align-items:center;align-self:center;display:inline-flex;height:100%}}.mdc-text-field__affix--prefix{padding-left:0;padding-right:2px}[dir=rtl] .mdc-text-field__affix--prefix,.mdc-text-field__affix--prefix[dir=rtl]{padding-left:2px;padding-right:0}.mdc-text-field--end-aligned .mdc-text-field__affix--prefix{padding-left:0;padding-right:12px}[dir=rtl] .mdc-text-field--end-aligned .mdc-text-field__affix--prefix,.mdc-text-field--end-aligned .mdc-text-field__affix--prefix[dir=rtl]{padding-left:12px;padding-right:0}.mdc-text-field__affix--suffix{padding-left:12px;padding-right:0}[dir=rtl] .mdc-text-field__affix--suffix,.mdc-text-field__affix--suffix[dir=rtl]{padding-left:0;padding-right:12px}.mdc-text-field--end-aligned .mdc-text-field__affix--suffix{padding-left:2px;padding-right:0}[dir=rtl] .mdc-text-field--end-aligned .mdc-text-field__affix--suffix,.mdc-text-field--end-aligned .mdc-text-field__affix--suffix[dir=rtl]{padding-left:0;padding-right:2px}.mdc-text-field--filled{height:56px}.mdc-text-field--filled::before{display:inline-block;width:0;height:40px;content:"";vertical-align:0}.mdc-text-field--filled .mdc-floating-label{left:16px;right:initial}[dir=rtl] .mdc-text-field--filled .mdc-floating-label,.mdc-text-field--filled .mdc-floating-label[dir=rtl]{left:initial;right:16px}.mdc-text-field--filled .mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__input{height:100%}.mdc-text-field--filled.mdc-text-field--no-label .mdc-floating-label{display:none}.mdc-text-field--filled.mdc-text-field--no-label::before{display:none}@supports(-webkit-hyphens: none){.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__affix{align-items:center;align-self:center;display:inline-flex;height:100%}}.mdc-text-field--outlined{height:56px;overflow:visible}.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-37.25px) scale(1)}.mdc-text-field--outlined .mdc-floating-label--float-above{font-size:.75rem}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) scale(0.75)}.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-text-field--outlined .mdc-text-field__input{height:100%}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading{border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:var(--mdc-shape-small, 4px)}[dir=rtl] .mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading,.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading[dir=rtl]{border-top-left-radius:0;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:var(--mdc-shape-small, 4px);border-bottom-left-radius:0}@supports(top: max(0%)){.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__leading{width:max(12px, var(--mdc-shape-small, 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__notch{max-width:calc(100% - max(12px, var(--mdc-shape-small, 4px))*2)}}.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__trailing{border-top-left-radius:0;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:var(--mdc-shape-small, 4px);border-bottom-left-radius:0}[dir=rtl] .mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__trailing,.mdc-text-field--outlined .mdc-notched-outline .mdc-notched-outline__trailing[dir=rtl]{border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:var(--mdc-shape-small, 4px)}@supports(top: max(0%)){.mdc-text-field--outlined{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined{padding-right:max(16px, var(--mdc-shape-small, 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined+.mdc-text-field-helper-line{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}@supports(top: max(0%)){.mdc-text-field--outlined+.mdc-text-field-helper-line{padding-right:max(16px, var(--mdc-shape-small, 4px))}}.mdc-text-field--outlined.mdc-text-field--with-leading-icon{padding-left:0}@supports(top: max(0%)){.mdc-text-field--outlined.mdc-text-field--with-leading-icon{padding-right:max(16px, var(--mdc-shape-small, 4px))}}[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-leading-icon,.mdc-text-field--outlined.mdc-text-field--with-leading-icon[dir=rtl]{padding-right:0}@supports(top: max(0%)){[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-leading-icon,.mdc-text-field--outlined.mdc-text-field--with-leading-icon[dir=rtl]{padding-left:max(16px, var(--mdc-shape-small, 4px))}}.mdc-text-field--outlined.mdc-text-field--with-trailing-icon{padding-right:0}@supports(top: max(0%)){.mdc-text-field--outlined.mdc-text-field--with-trailing-icon{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-trailing-icon,.mdc-text-field--outlined.mdc-text-field--with-trailing-icon[dir=rtl]{padding-left:0}@supports(top: max(0%)){[dir=rtl] .mdc-text-field--outlined.mdc-text-field--with-trailing-icon,.mdc-text-field--outlined.mdc-text-field--with-trailing-icon[dir=rtl]{padding-right:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}.mdc-text-field--outlined.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon{padding-left:0;padding-right:0}.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:1px}.mdc-text-field--outlined .mdc-floating-label{left:4px;right:initial}[dir=rtl] .mdc-text-field--outlined .mdc-floating-label,.mdc-text-field--outlined .mdc-floating-label[dir=rtl]{left:initial;right:4px}.mdc-text-field--outlined .mdc-text-field__input{display:flex;border:none !important;background-color:rgba(0,0,0,0)}.mdc-text-field--outlined .mdc-notched-outline{z-index:1}.mdc-text-field--textarea{flex-direction:column;align-items:center;width:auto;height:auto;padding:0}.mdc-text-field--textarea .mdc-floating-label{top:19px}.mdc-text-field--textarea .mdc-floating-label:not(.mdc-floating-label--float-above){transform:none}.mdc-text-field--textarea .mdc-text-field__input{flex-grow:1;height:auto;min-height:1.5rem;overflow-x:hidden;overflow-y:auto;box-sizing:border-box;resize:none;padding:0 16px}.mdc-text-field--textarea.mdc-text-field--filled::before{display:none}.mdc-text-field--textarea.mdc-text-field--filled .mdc-floating-label--float-above{transform:translateY(-10.25px) scale(0.75)}.mdc-text-field--textarea.mdc-text-field--filled .mdc-text-field__input{margin-top:23px;margin-bottom:9px}.mdc-text-field--textarea.mdc-text-field--filled.mdc-text-field--no-label .mdc-text-field__input{margin-top:16px;margin-bottom:16px}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:0}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-27.25px) scale(1)}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label--float-above{font-size:.75rem}.mdc-text-field--textarea.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--textarea.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-24.75px) scale(0.75)}.mdc-text-field--textarea.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--textarea.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-text-field__input{margin-top:16px;margin-bottom:16px}.mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label{top:18px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field__input{margin-bottom:2px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field-character-counter{align-self:flex-end;padding:0 16px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field-character-counter::after{display:inline-block;width:0;height:16px;content:"";vertical-align:-16px}.mdc-text-field--textarea.mdc-text-field--with-internal-counter .mdc-text-field-character-counter::before{display:none}.mdc-text-field__resizer{align-self:stretch;display:inline-flex;flex-direction:column;flex-grow:1;max-height:100%;max-width:100%;min-height:56px;min-width:fit-content;min-width:-moz-available;min-width:-webkit-fill-available;overflow:hidden;resize:both}.mdc-text-field--filled .mdc-text-field__resizer{transform:translateY(-1px)}.mdc-text-field--filled .mdc-text-field__resizer .mdc-text-field__input,.mdc-text-field--filled .mdc-text-field__resizer .mdc-text-field-character-counter{transform:translateY(1px)}.mdc-text-field--outlined .mdc-text-field__resizer{transform:translateX(-1px) translateY(-1px)}[dir=rtl] .mdc-text-field--outlined .mdc-text-field__resizer,.mdc-text-field--outlined .mdc-text-field__resizer[dir=rtl]{transform:translateX(1px) translateY(-1px)}.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field__input,.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field-character-counter{transform:translateX(1px) translateY(1px)}[dir=rtl] .mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field__input,[dir=rtl] .mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field-character-counter,.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field__input[dir=rtl],.mdc-text-field--outlined .mdc-text-field__resizer .mdc-text-field-character-counter[dir=rtl]{transform:translateX(-1px) translateY(1px)}.mdc-text-field--with-leading-icon{padding-left:0;padding-right:16px}[dir=rtl] .mdc-text-field--with-leading-icon,.mdc-text-field--with-leading-icon[dir=rtl]{padding-left:16px;padding-right:0}.mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label{max-width:calc(100% - 48px);left:48px;right:initial}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label,.mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label[dir=rtl]{left:initial;right:48px}.mdc-text-field--with-leading-icon.mdc-text-field--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 64px / 0.75)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label{left:36px;right:initial}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label[dir=rtl]{left:initial;right:36px}.mdc-text-field--with-leading-icon.mdc-text-field--outlined :not(.mdc-notched-outline--notched) .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above{transform:translateY(-37.25px) translateX(-32px) scale(1)}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above[dir=rtl]{transform:translateY(-37.25px) translateX(32px) scale(1)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--float-above{font-size:.75rem}.mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{transform:translateY(-34.75px) translateX(-32px) scale(0.75)}[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,[dir=rtl] .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above[dir=rtl],.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above[dir=rtl]{transform:translateY(-34.75px) translateX(32px) scale(0.75)}.mdc-text-field--with-leading-icon.mdc-text-field--outlined.mdc-notched-outline--upgraded .mdc-floating-label--float-above,.mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-notched-outline--upgraded .mdc-floating-label--float-above{font-size:1rem}.mdc-text-field--with-trailing-icon{padding-left:16px;padding-right:0}[dir=rtl] .mdc-text-field--with-trailing-icon,.mdc-text-field--with-trailing-icon[dir=rtl]{padding-left:0;padding-right:16px}.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label{max-width:calc(100% - 64px)}.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 64px / 0.75)}.mdc-text-field--with-trailing-icon.mdc-text-field--outlined :not(.mdc-notched-outline--notched) .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon{padding-left:0;padding-right:0}.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label{max-width:calc(100% - 96px)}.mdc-text-field--with-leading-icon.mdc-text-field--with-trailing-icon.mdc-text-field--filled .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 96px / 0.75)}.mdc-text-field-helper-line{display:flex;justify-content:space-between;box-sizing:border-box}.mdc-text-field+.mdc-text-field-helper-line{padding-right:16px;padding-left:16px}.mdc-form-field>.mdc-text-field+label{align-self:flex-start}.mdc-text-field--focused .mdc-notched-outline__leading,.mdc-text-field--focused .mdc-notched-outline__notch,.mdc-text-field--focused .mdc-notched-outline__trailing{border-width:2px}.mdc-text-field--focused+.mdc-text-field-helper-line .mdc-text-field-helper-text:not(.mdc-text-field-helper-text--validation-msg){opacity:1}.mdc-text-field--focused.mdc-text-field--outlined .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:2px}.mdc-text-field--focused.mdc-text-field--outlined.mdc-text-field--textarea .mdc-notched-outline--notched .mdc-notched-outline__notch{padding-top:0}.mdc-text-field--invalid+.mdc-text-field-helper-line .mdc-text-field-helper-text--validation-msg{opacity:1}.mdc-text-field--disabled{pointer-events:none}@media screen and (forced-colors: active){.mdc-text-field--disabled .mdc-text-field__input{background-color:Window}.mdc-text-field--disabled .mdc-floating-label{z-index:1}}.mdc-text-field--disabled .mdc-floating-label{cursor:default}.mdc-text-field--disabled.mdc-text-field--filled .mdc-text-field__ripple{display:none}.mdc-text-field--disabled .mdc-text-field__input{pointer-events:auto}.mdc-text-field--end-aligned .mdc-text-field__input{text-align:right}[dir=rtl] .mdc-text-field--end-aligned .mdc-text-field__input,.mdc-text-field--end-aligned .mdc-text-field__input[dir=rtl]{text-align:left}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__input,[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__input,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix{direction:ltr}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--prefix{padding-left:0;padding-right:2px}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--suffix{padding-left:12px;padding-right:0}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__icon--leading,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__icon--leading{order:1}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--suffix{order:2}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__input,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__input{order:3}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__affix--prefix{order:4}[dir=rtl] .mdc-text-field--ltr-text .mdc-text-field__icon--trailing,.mdc-text-field--ltr-text[dir=rtl] .mdc-text-field__icon--trailing{order:5}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__input,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__input{text-align:right}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__affix--prefix,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__affix--prefix{padding-right:12px}[dir=rtl] .mdc-text-field--ltr-text.mdc-text-field--end-aligned .mdc-text-field__affix--suffix,.mdc-text-field--ltr-text.mdc-text-field--end-aligned[dir=rtl] .mdc-text-field__affix--suffix{padding-left:2px}.mdc-floating-label{position:absolute;left:0;-webkit-transform-origin:left top;transform-origin:left top;line-height:1.15rem;text-align:left;text-overflow:ellipsis;white-space:nowrap;cursor:text;overflow:hidden;will-change:transform}[dir=rtl] .mdc-floating-label,.mdc-floating-label[dir=rtl]{right:0;left:auto;-webkit-transform-origin:right top;transform-origin:right top;text-align:right}.mdc-floating-label--float-above{cursor:auto}.mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)::after{margin-left:1px;margin-right:0px;content:"*"}[dir=rtl] .mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)::after,.mdc-floating-label--required:not(.mdc-floating-label--hide-required-marker)[dir=rtl]::after{margin-left:0;margin-right:1px}.mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-notched-outline{display:flex;position:absolute;top:0;right:0;left:0;box-sizing:border-box;width:100%;max-width:100%;height:100%;text-align:left;pointer-events:none}[dir=rtl] .mdc-notched-outline,.mdc-notched-outline[dir=rtl]{text-align:right}.mdc-notched-outline__leading,.mdc-notched-outline__notch,.mdc-notched-outline__trailing{box-sizing:border-box;height:100%;border-top:1px solid;border-bottom:1px solid;pointer-events:none}.mdc-notched-outline__leading{border-left:1px solid;border-right:none;width:12px}[dir=rtl] .mdc-notched-outline__leading,.mdc-notched-outline__leading[dir=rtl]{border-left:none;border-right:1px solid}.mdc-notched-outline__trailing{border-left:none;border-right:1px solid;flex-grow:1}[dir=rtl] .mdc-notched-outline__trailing,.mdc-notched-outline__trailing[dir=rtl]{border-left:1px solid;border-right:none}.mdc-notched-outline__notch{flex:0 0 auto;width:auto;max-width:calc(100% - 12px * 2)}.mdc-notched-outline .mdc-floating-label{display:inline-block;position:relative;max-width:100%}.mdc-notched-outline .mdc-floating-label--float-above{text-overflow:clip}.mdc-notched-outline--upgraded .mdc-floating-label--float-above{max-width:133.3333333333%}.mdc-notched-outline--notched .mdc-notched-outline__notch{padding-left:0;padding-right:8px;border-top:none}[dir=rtl] .mdc-notched-outline--notched .mdc-notched-outline__notch,.mdc-notched-outline--notched .mdc-notched-outline__notch[dir=rtl]{padding-left:8px;padding-right:0}.mdc-notched-outline--no-label .mdc-notched-outline__notch{display:none}.mdc-line-ripple::before,.mdc-line-ripple::after{position:absolute;bottom:0;left:0;width:100%;border-bottom-style:solid;content:""}.mdc-line-ripple::before{border-bottom-width:1px}.mdc-line-ripple::after{border-bottom-width:2px}.mdc-line-ripple::before{z-index:1}.mdc-line-ripple::after{transform:scaleX(0);opacity:0;z-index:2}.mdc-line-ripple--active::after{transform:scaleX(1);opacity:1}.mdc-line-ripple--deactivating::after{opacity:0}.mat-mdc-form-field-textarea-control{vertical-align:middle;resize:vertical;box-sizing:border-box;height:auto;margin:0;padding:0;border:none;overflow:auto}.mat-mdc-form-field-input-control.mat-mdc-form-field-input-control{font:inherit;letter-spacing:inherit;text-decoration:inherit;text-transform:inherit;border:none}.mat-mdc-form-field .mat-mdc-floating-label.mdc-floating-label{line-height:normal;pointer-events:all}.mdc-text-field--no-label:not(.mdc-text-field--textarea) .mat-mdc-form-field-input-control.mdc-text-field__input,.mat-mdc-text-field-wrapper .mat-mdc-form-field-input-control{height:auto}.mat-mdc-text-field-wrapper .mat-mdc-form-field-input-control.mdc-text-field__input[type=color]{height:23px}.mat-mdc-text-field-wrapper{height:auto;flex:auto}.mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper{padding-left:0;--mat-mdc-form-field-label-offset-x: -16px}.mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper{padding-right:0}[dir=rtl] .mat-mdc-text-field-wrapper{padding-left:16px;padding-right:16px}[dir=rtl] .mat-mdc-form-field-has-icon-suffix .mat-mdc-text-field-wrapper{padding-left:0}[dir=rtl] .mat-mdc-form-field-has-icon-prefix .mat-mdc-text-field-wrapper{padding-right:0}.mat-mdc-form-field-label-always-float .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms;opacity:1}.mat-mdc-text-field-wrapper .mat-mdc-form-field-infix .mat-mdc-floating-label{left:auto;right:auto}.mat-mdc-text-field-wrapper.mdc-text-field--outlined .mdc-text-field__input{display:inline-block}.mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field .mdc-notched-outline__notch{padding-top:0}.mat-mdc-text-field-wrapper::before{content:none}.mat-mdc-form-field-subscript-wrapper{box-sizing:border-box;width:100%;position:relative}.mat-mdc-form-field-hint-wrapper,.mat-mdc-form-field-error-wrapper{position:absolute;top:0;left:0;right:0;padding:0 16px}.mat-mdc-form-field-subscript-dynamic-size .mat-mdc-form-field-hint-wrapper,.mat-mdc-form-field-subscript-dynamic-size .mat-mdc-form-field-error-wrapper{position:static}.mat-mdc-form-field-bottom-align::before{content:"";display:inline-block;height:16px}.mat-mdc-form-field-bottom-align.mat-mdc-form-field-subscript-dynamic-size::before{content:unset}.mat-mdc-form-field-hint-end{order:1}.mat-mdc-form-field-hint-wrapper{display:flex}.mat-mdc-form-field-hint-spacer{flex:1 0 1em}.mat-mdc-form-field-error{display:block}.mat-mdc-form-field-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;opacity:0;pointer-events:none}select.mat-mdc-form-field-input-control{-moz-appearance:none;-webkit-appearance:none;background-color:rgba(0,0,0,0);display:inline-flex;box-sizing:border-box}select.mat-mdc-form-field-input-control:not(:disabled){cursor:pointer}.mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-infix::after{content:"";width:0;height:0;border-left:5px solid rgba(0,0,0,0);border-right:5px solid rgba(0,0,0,0);border-top:5px solid;position:absolute;right:0;top:50%;margin-top:-2.5px;pointer-events:none}[dir=rtl] .mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-infix::after{right:auto;left:0}.mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-input-control{padding-right:15px}[dir=rtl] .mat-mdc-form-field-type-mat-native-select .mat-mdc-form-field-input-control{padding-right:0;padding-left:15px}.cdk-high-contrast-active .mat-form-field-appearance-fill .mat-mdc-text-field-wrapper{outline:solid 1px}.cdk-high-contrast-active .mat-form-field-appearance-fill.mat-form-field-disabled .mat-mdc-text-field-wrapper{outline-color:GrayText}.cdk-high-contrast-active .mat-form-field-appearance-fill.mat-focused .mat-mdc-text-field-wrapper{outline:dashed 3px}.cdk-high-contrast-active .mat-mdc-form-field.mat-focused .mdc-notched-outline{border:dashed 3px}.mat-mdc-form-field{--mat-mdc-form-field-floating-label-scale: 0.75;display:inline-flex;flex-direction:column;min-width:0;text-align:left}[dir=rtl] .mat-mdc-form-field{text-align:right}.mat-mdc-form-field-flex{display:inline-flex;align-items:baseline;box-sizing:border-box;width:100%}.mat-mdc-text-field-wrapper{width:100%}.mat-mdc-form-field-icon-prefix,.mat-mdc-form-field-icon-suffix{align-self:center;line-height:0;pointer-events:auto}.mat-mdc-form-field-icon-prefix,[dir=rtl] .mat-mdc-form-field-icon-suffix{padding:0 4px 0 0}.mat-mdc-form-field-icon-suffix,[dir=rtl] .mat-mdc-form-field-icon-prefix{padding:0 0 0 4px}.mat-mdc-form-field-icon-prefix>.mat-icon,.mat-mdc-form-field-icon-suffix>.mat-icon{padding:12px;box-sizing:content-box}.mat-mdc-form-field-subscript-wrapper .mat-icon,.mat-mdc-form-field label .mat-icon{width:1em;height:1em;font-size:inherit}.mat-mdc-form-field-infix{flex:auto;min-width:0;width:180px;position:relative;box-sizing:border-box}.mat-mdc-form-field .mdc-notched-outline__notch{margin-left:-1px;-webkit-clip-path:inset(-9em -999em -9em 1px);clip-path:inset(-9em -999em -9em 1px)}[dir=rtl] .mat-mdc-form-field .mdc-notched-outline__notch{margin-left:0;margin-right:-1px;-webkit-clip-path:inset(-9em 1px -9em -999em);clip-path:inset(-9em 1px -9em -999em)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input{transition:opacity 150ms 0ms cubic-bezier(0.4, 0, 0.2, 1)}@media all{.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::placeholder{transition:opacity 67ms 0ms cubic-bezier(0.4, 0, 0.2, 1)}}@media all{.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input:-ms-input-placeholder{transition:opacity 67ms 0ms cubic-bezier(0.4, 0, 0.2, 1)}}@media all{.mdc-text-field--no-label .mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::placeholder,.mdc-text-field--focused .mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input::placeholder{transition-delay:40ms;transition-duration:110ms}}@media all{.mdc-text-field--no-label .mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input:-ms-input-placeholder,.mdc-text-field--focused .mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__input:-ms-input-placeholder{transition-delay:40ms;transition-duration:110ms}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field__affix{transition:opacity 150ms 0ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--filled.mdc-ripple-upgraded--background-focused .mdc-text-field__ripple::before,.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--filled:not(.mdc-ripple-upgraded):focus .mdc-text-field__ripple::before{transition-duration:75ms}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--outlined .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-text-field-outlined 250ms 1}@keyframes mdc-floating-label-shake-float-above-text-field-outlined{0%{transform:translateX(calc(0 - 0%)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-34.75px) scale(0.75)}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--textarea{transition:none}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--textarea.mdc-text-field--filled .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-textarea-filled 250ms 1}@keyframes mdc-floating-label-shake-float-above-textarea-filled{0%{transform:translateX(calc(0 - 0%)) translateY(-10.25px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-10.25px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-10.25px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-10.25px) scale(0.75)}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--textarea.mdc-text-field--outlined .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-textarea-outlined 250ms 1}@keyframes mdc-floating-label-shake-float-above-textarea-outlined{0%{transform:translateX(calc(0 - 0%)) translateY(-24.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-24.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-24.75px) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-24.75px) scale(0.75)}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-text-field-outlined-leading-icon 250ms 1}@keyframes mdc-floating-label-shake-float-above-text-field-outlined-leading-icon{0%{transform:translateX(calc(0 - 32px)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 32px)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 32px)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - 32px)) translateY(-34.75px) scale(0.75)}}[dir=rtl] .mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--with-leading-icon.mdc-text-field--outlined .mdc-floating-label--shake,.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-text-field--with-leading-icon.mdc-text-field--outlined[dir=rtl] .mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-text-field-outlined-leading-icon 250ms 1}@keyframes mdc-floating-label-shake-float-above-text-field-outlined-leading-icon-rtl{0%{transform:translateX(calc(0 - -32px)) translateY(-34.75px) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - -32px)) translateY(-34.75px) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - -32px)) translateY(-34.75px) scale(0.75)}100%{transform:translateX(calc(0 - -32px)) translateY(-34.75px) scale(0.75)}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-floating-label{transition:transform 150ms cubic-bezier(0.4, 0, 0.2, 1),color 150ms cubic-bezier(0.4, 0, 0.2, 1)}.mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-standard 250ms 1}@keyframes mdc-floating-label-shake-float-above-standard{0%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-106%) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-106%) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}}.mat-mdc-form-field:not(.mat-form-field-no-animations) .mdc-line-ripple::after{transition:transform 180ms cubic-bezier(0.4, 0, 0.2, 1),opacity 180ms cubic-bezier(0.4, 0, 0.2, 1)}'],encapsulation:2,data:{animation:[eX.transitionMessages]},changeDetection:0}),n})(),rX=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,ul,FT,rr]}),n})();function wo(n,e){return"function"==typeof e?t=>t.pipe(wo((i,r)=>dr(n(i,r)).pipe(_t((s,o)=>e(i,s,r,o))))):t=>t.lift(new sX(n))}class sX{constructor(e){this.project=e}call(e,t){return t.subscribe(new oX(e,this.project))}}class oX extends Fs{constructor(e,t){super(e),this.project=t,this.index=0}_next(e){let t;const i=this.index++;try{t=this.project(e,i)}catch(r){return void this.destination.error(r)}this._innerSub(t,e,i)}_innerSub(e,t,i){const r=this.innerSubscription;r&&r.unsubscribe();const s=new Pt(this,t,i),o=this.destination;o.add(s),this.innerSubscription=$o(this,e,void 0,void 0,s),this.innerSubscription!==s&&o.add(this.innerSubscription)}_complete(){const{innerSubscription:e}=this;(!e||e.closed)&&super._complete(),this.unsubscribe()}_unsubscribe(){this.innerSubscription=null}notifyComplete(e){this.destination.remove(e),this.innerSubscription=null,this.isStopped&&super._complete()}notifyNext(e,t,i,r,s){this.destination.next(t)}}const aX=["trigger"],cX=["panel"];function lX(n,e){if(1&n&&(ke(0,"span",10),it(1),Ne()),2&n){const t=Jt();Le(1),Hi(t.placeholder)}}function dX(n,e){if(1&n&&(ke(0,"span",14),it(1),Ne()),2&n){const t=Jt(2);Le(1),Hi(t.triggerValue)}}function uX(n,e){1&n&&En(0,0,["*ngSwitchCase","true"])}function hX(n,e){1&n&&(ke(0,"span",11),mt(1,dX,2,1,"span",12),mt(2,uX,1,0,"ng-content",13),Ne()),2&n&&($e("ngSwitch",!!Jt().customTrigger),Le(2),$e("ngSwitchCase",!0))}function fX(n,e){if(1&n){const t=Df();$i(),Xo(),ke(0,"div",15,16),Gn("@transformPanel.done",function(r){return R(t),V(Jt()._panelDoneAnimatingStream.next(r.toState))})("keydown",function(r){return R(t),V(Jt()._handleKeydown(r))}),En(2,1),Ne()}if(2&n){const t=Jt();dR("mat-mdc-select-panel mdc-menu-surface mdc-menu-surface--open ",t._getPanelTheme(),""),$e("ngClass",t.panelClass)("@transformPanel","showing"),Di("id",t.id+"-panel")("aria-multiselectable",t.multiple)("aria-label",t.ariaLabel||null)("aria-labelledby",t._getPanelAriaLabelledby())}}const pX=[[["mat-select-trigger"]],"*"],mX=["mat-select-trigger","*"],gX={transformPanelWrap:fg("transformPanelWrap",[Xl("* => void",Jv("@transformPanel",[Zv()],{optional:!0}))]),transformPanel:fg("transformPanel",[sh("void",la({opacity:0,transform:"scale(1, 0.8)"})),Xl("void => showing",zd("120ms cubic-bezier(0, 0, 0.2, 1)",la({opacity:1,transform:"scale(1, 1)"}))),Xl("* => void",zd("100ms linear",la({opacity:0})))])};let v4=0;const y4=new Ze("mat-select-scroll-strategy"),vX=new Ze("MAT_SELECT_CONFIG"),yX={provide:y4,deps:[hl],useFactory:function _X(n){return()=>n.scrollStrategies.reposition()}},bX=new Ze("MatSelectTrigger");class xX{constructor(e,t){this.source=e,this.value=t}}const wX=Bw(ZL(LT(W$(class{constructor(n,e,t,i,r){this._elementRef=n,this._defaultErrorStateMatcher=e,this._parentForm=t,this._parentFormGroup=i,this.ngControl=r,this.stateChanges=new cn}}))));let SX=(()=>{class n extends wX{get focused(){return this._focused||this._panelOpen}get placeholder(){return this._placeholder}set placeholder(t){this._placeholder=t,this.stateChanges.next()}get required(){return this._required??this.ngControl?.control?.hasValidator(Cj.required)??!1}set required(t){this._required=bi(t),this.stateChanges.next()}get multiple(){return this._multiple}set multiple(t){this._multiple=bi(t)}get disableOptionCentering(){return this._disableOptionCentering}set disableOptionCentering(t){this._disableOptionCentering=bi(t)}get compareWith(){return this._compareWith}set compareWith(t){this._compareWith=t,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(t){this._assignValue(t)&&this._onChange(t)}get typeaheadDebounceInterval(){return this._typeaheadDebounceInterval}set typeaheadDebounceInterval(t){this._typeaheadDebounceInterval=ih(t)}get id(){return this._id}set id(t){this._id=t||this._uid,this.stateChanges.next()}constructor(t,i,r,s,o,a,c,u,p,g,v,y,x,T){super(o,s,c,u,g),this._viewportRuler=t,this._changeDetectorRef=i,this._ngZone=r,this._dir=a,this._parentFormField=p,this._liveAnnouncer=x,this._defaultOptions=T,this._panelOpen=!1,this._compareWith=(N,k)=>N===k,this._uid="mat-select-"+v4++,this._triggerAriaLabelledBy=null,this._destroy=new cn,this._onChange=()=>{},this._onTouched=()=>{},this._valueId="mat-select-value-"+v4++,this._panelDoneAnimatingStream=new cn,this._overlayPanelClass=this._defaultOptions?.overlayPanelClass||"",this._focused=!1,this.controlType="mat-select",this._multiple=!1,this._disableOptionCentering=this._defaultOptions?.disableOptionCentering??!1,this.ariaLabel="",this.optionSelectionChanges=Yv(()=>{const N=this.options;return N?N.changes.pipe(Bf(N),wo(()=>fa(...N.map(k=>k.onSelectionChange)))):this._ngZone.onStable.pipe(Gr(1),wo(()=>this.optionSelectionChanges))}),this.openedChange=new Pn,this._openedStream=this.openedChange.pipe(Ui(N=>N),_t(()=>{})),this._closedStream=this.openedChange.pipe(Ui(N=>!N),_t(()=>{})),this.selectionChange=new Pn,this.valueChange=new Pn,this.ngControl&&(this.ngControl.valueAccessor=this),null!=T?.typeaheadDebounceInterval&&(this._typeaheadDebounceInterval=T.typeaheadDebounceInterval),this._scrollStrategyFactory=y,this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=parseInt(v)||0,this.id=this.id}ngOnInit(){this._selectionModel=new Hw(this.multiple),this.stateChanges.next(),this._panelDoneAnimatingStream.pipe(Rc(),Tr(this._destroy)).subscribe(()=>this._panelDoneAnimating(this.panelOpen))}ngAfterContentInit(){this._initKeyManager(),this._selectionModel.changed.pipe(Tr(this._destroy)).subscribe(t=>{t.added.forEach(i=>i.select()),t.removed.forEach(i=>i.deselect())}),this.options.changes.pipe(Bf(null),Tr(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection()})}ngDoCheck(){const t=this._getTriggerAriaLabelledby(),i=this.ngControl;if(t!==this._triggerAriaLabelledBy){const r=this._elementRef.nativeElement;this._triggerAriaLabelledBy=t,t?r.setAttribute("aria-labelledby",t):r.removeAttribute("aria-labelledby")}i&&(this._previousControl!==i.control&&(void 0!==this._previousControl&&null!==i.disabled&&i.disabled!==this.disabled&&(this.disabled=i.disabled),this._previousControl=i.control),this.updateErrorState())}ngOnChanges(t){(t.disabled||t.userAriaDescribedBy)&&this.stateChanges.next(),t.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this._typeaheadDebounceInterval)}ngOnDestroy(){this._keyManager?.destroy(),this._destroy.next(),this._destroy.complete(),this.stateChanges.complete()}toggle(){this.panelOpen?this.close():this.open()}open(){this._canOpen()&&(this._panelOpen=!0,this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck())}close(){this._panelOpen&&(this._panelOpen=!1,this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched())}writeValue(t){this._assignValue(t)}registerOnChange(t){this._onChange=t}registerOnTouched(t){this._onTouched=t}setDisabledState(t){this.disabled=t,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}get panelOpen(){return this._panelOpen}get selected(){return this.multiple?this._selectionModel?.selected||[]:this._selectionModel?.selected[0]}get triggerValue(){if(this.empty)return"";if(this._multiple){const t=this._selectionModel.selected.map(i=>i.viewValue);return this._isRtl()&&t.reverse(),t.join(", ")}return this._selectionModel.selected[0].viewValue}_isRtl(){return!!this._dir&&"rtl"===this._dir.value}_handleKeydown(t){this.disabled||(this.panelOpen?this._handleOpenKeydown(t):this._handleClosedKeydown(t))}_handleClosedKeydown(t){const i=t.keyCode,r=40===i||38===i||37===i||39===i,s=13===i||32===i,o=this._keyManager;if(!o.isTyping()&&s&&!ql(t)||(this.multiple||t.altKey)&&r)t.preventDefault(),this.open();else if(!this.multiple){const a=this.selected;o.onKeydown(t);const c=this.selected;c&&a!==c&&this._liveAnnouncer.announce(c.viewValue,1e4)}}_handleOpenKeydown(t){const i=this._keyManager,r=t.keyCode,s=40===r||38===r,o=i.isTyping();if(s&&t.altKey)t.preventDefault(),this.close();else if(o||13!==r&&32!==r||!i.activeItem||ql(t))if(!o&&this._multiple&&65===r&&t.ctrlKey){t.preventDefault();const a=this.options.some(c=>!c.disabled&&!c.selected);this.options.forEach(c=>{c.disabled||(a?c.select():c.deselect())})}else{const a=i.activeItemIndex;i.onKeydown(t),this._multiple&&s&&t.shiftKey&&i.activeItem&&i.activeItemIndex!==a&&i.activeItem._selectViaInteraction()}else t.preventDefault(),i.activeItem._selectViaInteraction()}_onFocus(){this.disabled||(this._focused=!0,this.stateChanges.next())}_onBlur(){this._focused=!1,this._keyManager?.cancelTypeahead(),!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}_onAttached(){this._overlayDir.positionChange.pipe(Gr(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled()})}_getPanelTheme(){return this._parentFormField?`mat-${this._parentFormField.color}`:""}get empty(){return!this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next()})}_setSelectionByValue(t){if(this.options.forEach(i=>i.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&t)Array.isArray(t),t.forEach(i=>this._selectOptionByValue(i)),this._sortValues();else{const i=this._selectOptionByValue(t);i?this._keyManager.updateActiveItem(i):this.panelOpen||this._keyManager.updateActiveItem(-1)}this._changeDetectorRef.markForCheck()}_selectOptionByValue(t){const i=this.options.find(r=>{if(this._selectionModel.isSelected(r))return!1;try{return null!=r.value&&this._compareWith(r.value,t)}catch{return!1}});return i&&this._selectionModel.select(i),i}_assignValue(t){return!!(t!==this._value||this._multiple&&Array.isArray(t))&&(this.options&&this._setSelectionByValue(t),this._value=t,!0)}_initKeyManager(){this._keyManager=new u$(this.options).withTypeAhead(this._typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withPageUpDown().withAllowedModifierKeys(["shiftKey"]),this._keyManager.tabOut.subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close())}),this._keyManager.change.subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction()})}_resetOptions(){const t=fa(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(Tr(t)).subscribe(i=>{this._onSelect(i.source,i.isUserInput),i.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus())}),fa(...this.options.map(i=>i._stateChanges)).pipe(Tr(t)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this.stateChanges.next()})}_onSelect(t,i){const r=this._selectionModel.isSelected(t);null!=t.value||this._multiple?(r!==t.selected&&(t.selected?this._selectionModel.select(t):this._selectionModel.deselect(t)),i&&this._keyManager.setActiveItem(t),this.multiple&&(this._sortValues(),i&&this.focus())):(t.deselect(),this._selectionModel.clear(),null!=this.value&&this._propagateChanges(t.value)),r!==this._selectionModel.isSelected(t)&&this._propagateChanges(),this.stateChanges.next()}_sortValues(){if(this.multiple){const t=this.options.toArray();this._selectionModel.sort((i,r)=>this.sortComparator?this.sortComparator(i,r,t):t.indexOf(i)-t.indexOf(r)),this.stateChanges.next()}}_propagateChanges(t){let i=null;i=this.multiple?this.selected.map(r=>r.value):this.selected?this.selected.value:t,this._value=i,this.valueChange.emit(i),this._onChange(i),this.selectionChange.emit(this._getChangeEvent(i)),this._changeDetectorRef.markForCheck()}_highlightCorrectOption(){this._keyManager&&(this.empty?this._keyManager.setFirstItemActive():this._keyManager.setActiveItem(this._selectionModel.selected[0]))}_canOpen(){return!this._panelOpen&&!this.disabled&&this.options?.length>0}focus(t){this._elementRef.nativeElement.focus(t)}_getPanelAriaLabelledby(){if(this.ariaLabel)return null;const t=this._parentFormField?.getLabelId();return this.ariaLabelledby?(t?t+" ":"")+this.ariaLabelledby:t}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){if(this.ariaLabel)return null;const t=this._parentFormField?.getLabelId();let i=(t?t+" ":"")+this._valueId;return this.ariaLabelledby&&(i+=" "+this.ariaLabelledby),i}_panelDoneAnimating(t){this.openedChange.emit(t)}setDescribedByIds(t){t.length?this._elementRef.nativeElement.setAttribute("aria-describedby",t.join(" ")):this._elementRef.nativeElement.removeAttribute("aria-describedby")}onContainerClick(){this.focus(),this.open()}get shouldLabelFloat(){return this._panelOpen||!this.empty||this._focused&&!!this._placeholder}}return n.\u0275fac=function(t){return new(t||n)(ie(Gw),ie(aa),ie(Xt),ie(q$),ie(_n),ie(Yl,8),ie(Sw,8),ie(Mw,8),ie(f4,8),ie(Hd,10),Kc("tabindex"),ie(y4),ie(I$),ie(vX,8))},n.\u0275dir=ut({type:n,viewQuery:function(t,i){if(1&t&&(zr(aX,5),zr(cX,5),zr(VN,5)),2&t){let r;Yn(r=Xn())&&(i.trigger=r.first),Yn(r=Xn())&&(i.panel=r.first),Yn(r=Xn())&&(i._overlayDir=r.first)}},inputs:{userAriaDescribedBy:["aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",placeholder:"placeholder",required:"required",multiple:"multiple",disableOptionCentering:"disableOptionCentering",compareWith:"compareWith",value:"value",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:"typeaheadDebounceInterval",sortComparator:"sortComparator",id:"id"},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},features:[Z,Cn]}),n})(),b4=(()=>{class n extends SX{constructor(){super(...arguments),this._positions=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"}],this._hideSingleSelectionIndicator=this._defaultOptions?.hideSingleSelectionIndicator??!1}get shouldLabelFloat(){return this.panelOpen||!this.empty||this.focused&&!!this.placeholder}ngOnInit(){super.ngOnInit(),this._viewportRuler.change().pipe(Tr(this._destroy)).subscribe(()=>{this.panelOpen&&(this._overlayWidth=this._getOverlayWidth(),this._changeDetectorRef.detectChanges())})}ngAfterViewInit(){this._parentFormField&&(this._preferredOverlayOrigin=this._parentFormField.getConnectedOverlayOrigin())}open(){this._overlayWidth=this._getOverlayWidth(),super.open(),this.stateChanges.next()}close(){super.close(),this.stateChanges.next()}_scrollOptionIntoView(t){const i=this.options.toArray()[t];if(i){const r=this.panel.nativeElement,s=function nq(n,e,t){if(t.length){let i=e.toArray(),r=t.toArray(),s=0;for(let o=0;ot+i?Math.max(0,n-i+e):t}(o.offsetTop,o.offsetHeight,r.scrollTop,r.offsetHeight)}}_positioningSettled(){this._scrollOptionIntoView(this._keyManager.activeItemIndex||0)}_getChangeEvent(t){return new xX(this,t)}_getOverlayWidth(){return(this._preferredOverlayOrigin instanceof ZT?this._preferredOverlayOrigin.elementRef:this._preferredOverlayOrigin||this._elementRef).nativeElement.getBoundingClientRect().width}get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(t){this._hideSingleSelectionIndicator=bi(t),this._syncParentProperties()}_syncParentProperties(){if(this.options)for(const t of this.options)t._changeDetectorRef.markForCheck()}}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275cmp=Ln({type:n,selectors:[["mat-select"]],contentQueries:function(t,i,r){if(1&t&&(is(r,bX,5),is(r,BT,5),is(r,sN,5)),2&t){let s;Yn(s=Xn())&&(i.customTrigger=s.first),Yn(s=Xn())&&(i.options=s),Yn(s=Xn())&&(i.optionGroups=s)}},hostAttrs:["role","combobox","aria-autocomplete","none","aria-haspopup","listbox",1,"mat-mdc-select"],hostVars:19,hostBindings:function(t,i){1&t&&Gn("keydown",function(s){return i._handleKeydown(s)})("focus",function(){return i._onFocus()})("blur",function(){return i._onBlur()}),2&t&&(Di("id",i.id)("tabindex",i.tabIndex)("aria-controls",i.panelOpen?i.id+"-panel":null)("aria-expanded",i.panelOpen)("aria-label",i.ariaLabel||null)("aria-required",i.required.toString())("aria-disabled",i.disabled.toString())("aria-invalid",i.errorState)("aria-activedescendant",i._getAriaActiveDescendant()),hi("mat-mdc-select-disabled",i.disabled)("mat-mdc-select-invalid",i.errorState)("mat-mdc-select-required",i.required)("mat-mdc-select-empty",i.empty)("mat-mdc-select-multiple",i.multiple))},inputs:{disabled:"disabled",disableRipple:"disableRipple",tabIndex:"tabIndex",hideSingleSelectionIndicator:"hideSingleSelectionIndicator"},exportAs:["matSelect"],features:[Oi([{provide:h4,useExisting:n},{provide:rN,useExisting:n}]),Z],ngContentSelectors:mX,decls:11,vars:11,consts:[["cdk-overlay-origin","",1,"mat-mdc-select-trigger",3,"click"],["fallbackOverlayOrigin","cdkOverlayOrigin","trigger",""],[1,"mat-mdc-select-value",3,"ngSwitch"],["class","mat-mdc-select-placeholder mat-mdc-select-min-line",4,"ngSwitchCase"],["class","mat-mdc-select-value-text",3,"ngSwitch",4,"ngSwitchCase"],[1,"mat-mdc-select-arrow-wrapper"],[1,"mat-mdc-select-arrow"],["viewBox","0 0 24 24","width","24px","height","24px","focusable","false"],["d","M7 10l5 5 5-5z"],["cdk-connected-overlay","","cdkConnectedOverlayLockPosition","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayOpen","cdkConnectedOverlayPositions","cdkConnectedOverlayWidth","backdropClick","attach","detach"],[1,"mat-mdc-select-placeholder","mat-mdc-select-min-line"],[1,"mat-mdc-select-value-text",3,"ngSwitch"],["class","mat-mdc-select-min-line",4,"ngSwitchDefault"],[4,"ngSwitchCase"],[1,"mat-mdc-select-min-line"],["role","listbox","tabindex","-1",3,"ngClass","keydown"],["panel",""]],template:function(t,i){if(1&t&&(Hs(pX),ke(0,"div",0,1),Gn("click",function(){return i.toggle()}),ke(3,"div",2),mt(4,lX,2,1,"span",3),mt(5,hX,3,2,"span",4),Ne(),ke(6,"div",5)(7,"div",6),$i(),ke(8,"svg",7),qt(9,"path",8),Ne()()()(),mt(10,fX,3,9,"ng-template",9),Gn("backdropClick",function(){return i.close()})("attach",function(){return i._onAttached()})("detach",function(){return i.close()})),2&t){const r=Tc(1);Di("aria-owns",i.panelOpen?i.id+"-panel":null),Le(3),$e("ngSwitch",i.empty),Di("id",i._valueId),Le(1),$e("ngSwitchCase",!0),Le(1),$e("ngSwitchCase",!1),Le(5),$e("cdkConnectedOverlayPanelClass",i._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",i._scrollStrategy)("cdkConnectedOverlayOrigin",i._preferredOverlayOrigin||r)("cdkConnectedOverlayOpen",i.panelOpen)("cdkConnectedOverlayPositions",i._positions)("cdkConnectedOverlayWidth",i._overlayWidth)}},dependencies:[eg,Tv,ND,T3,VN,ZT],styles:['.mdc-menu-surface{display:none;position:absolute;box-sizing:border-box;max-width:calc(100vw - 32px);max-width:var(--mdc-menu-max-width, calc(100vw - 32px));max-height:calc(100vh - 32px);max-height:var(--mdc-menu-max-height, calc(100vh - 32px));margin:0;padding:0;transform:scale(1);transform-origin:top left;opacity:0;overflow:auto;will-change:transform,opacity;z-index:8;border-radius:4px;border-radius:var(--mdc-shape-medium, 4px);transform-origin-left:top left;transform-origin-right:top right}.mdc-menu-surface:focus{outline:none}.mdc-menu-surface--animating-open{display:inline-block;transform:scale(0.8);opacity:0}.mdc-menu-surface--open{display:inline-block;transform:scale(1);opacity:1}.mdc-menu-surface--animating-closed{display:inline-block;opacity:0}[dir=rtl] .mdc-menu-surface,.mdc-menu-surface[dir=rtl]{transform-origin-left:top right;transform-origin-right:top left}.mdc-menu-surface--anchor{position:relative;overflow:visible}.mdc-menu-surface--fixed{position:fixed}.mdc-menu-surface--fullwidth{width:100%}.mat-mdc-select{display:inline-block;width:100%;outline:none}.mat-mdc-select-trigger{display:inline-flex;align-items:center;cursor:pointer;position:relative;box-sizing:border-box;width:100%}.mat-mdc-select-disabled .mat-mdc-select-trigger{-webkit-user-select:none;user-select:none;cursor:default}.mat-mdc-select-value{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mat-mdc-select-value-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mat-mdc-select-arrow-wrapper{height:24px;flex-shrink:0;display:inline-flex;align-items:center}.mat-form-field-appearance-fill .mat-mdc-select-arrow-wrapper{transform:translateY(-8px)}.mat-form-field-appearance-fill .mdc-text-field--no-label .mat-mdc-select-arrow-wrapper{transform:none}.mat-mdc-select-arrow{width:10px;height:5px;position:relative}.mat-mdc-select-arrow svg{fill:currentColor;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%)}.cdk-high-contrast-active .mat-mdc-select-arrow svg{fill:CanvasText}.mat-mdc-select-disabled .cdk-high-contrast-active .mat-mdc-select-arrow svg{fill:GrayText}.mdc-menu-surface.mat-mdc-select-panel{width:100%;max-height:275px;position:static;outline:0;margin:0;padding:8px 0;list-style-type:none}.mdc-menu-surface.mat-mdc-select-panel:focus{outline:none}.cdk-high-contrast-active .mdc-menu-surface.mat-mdc-select-panel{outline:solid 1px}.cdk-overlay-pane:not(.mat-mdc-select-panel-above) .mdc-menu-surface.mat-mdc-select-panel{border-top-left-radius:0;border-top-right-radius:0;transform-origin:top center}.mat-mdc-select-panel-above .mdc-menu-surface.mat-mdc-select-panel{border-bottom-left-radius:0;border-bottom-right-radius:0;transform-origin:bottom center}.mat-mdc-select-placeholder{transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1)}._mat-animation-noopable .mat-mdc-select-placeholder{transition:none}.mat-form-field-hide-placeholder .mat-mdc-select-placeholder{color:rgba(0,0,0,0);-webkit-text-fill-color:rgba(0,0,0,0);transition:none;display:block}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-fill .mat-mdc-floating-label{max-width:calc(100% - 18px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-fill .mdc-floating-label--float-above{max-width:calc(100% / 0.75 - 24px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-outline .mdc-notched-outline__notch{max-width:calc(100% - 60px)}.mat-mdc-form-field-type-mat-select.mat-form-field-appearance-outline .mdc-text-field--label-floating .mdc-notched-outline__notch{max-width:calc(100% - 24px)}.mat-mdc-select-min-line:empty::before{content:" ";white-space:pre;width:1px;display:inline-block;visibility:hidden}'],encapsulation:2,data:{animation:[gX.transformPanel]},changeDetection:0}),n})(),EX=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[yX],imports:[ul,Kw,oN,rr,jw,rX,oN,rr]}),n})();const MX=["tooltip"],x4=new Ze("mat-tooltip-scroll-strategy"),TX={provide:x4,deps:[hl],useFactory:function DX(n){return()=>n.scrollStrategies.reposition({scrollThrottle:20})}},kX=new Ze("mat-tooltip-default-options",{providedIn:"root",factory:function AX(){return{showDelay:0,hideDelay:0,touchendHideDelay:1500}}}),w4="tooltip-panel",S4=Vv({passive:!0});let LX=(()=>{class n{get position(){return this._position}set position(t){t!==this._position&&(this._position=t,this._overlayRef&&(this._updatePosition(this._overlayRef),this._tooltipInstance?.show(0),this._overlayRef.updatePosition()))}get positionAtOrigin(){return this._positionAtOrigin}set positionAtOrigin(t){this._positionAtOrigin=bi(t),this._detach(),this._overlayRef=null}get disabled(){return this._disabled}set disabled(t){this._disabled=bi(t),this._disabled?this.hide(0):this._setupPointerEnterEventsIfNeeded()}get showDelay(){return this._showDelay}set showDelay(t){this._showDelay=ih(t)}get hideDelay(){return this._hideDelay}set hideDelay(t){this._hideDelay=ih(t),this._tooltipInstance&&(this._tooltipInstance._mouseLeaveHideDelay=this._hideDelay)}get message(){return this._message}set message(t){this._ariaDescriber.removeDescription(this._elementRef.nativeElement,this._message,"tooltip"),this._message=null!=t?String(t).trim():"",!this._message&&this._isTooltipVisible()?this.hide(0):(this._setupPointerEnterEventsIfNeeded(),this._updateTooltipMessage(),this._ngZone.runOutsideAngular(()=>{Promise.resolve().then(()=>{this._ariaDescriber.describe(this._elementRef.nativeElement,this.message,"tooltip")})}))}get tooltipClass(){return this._tooltipClass}set tooltipClass(t){this._tooltipClass=t,this._tooltipInstance&&this._setTooltipClass(this._tooltipClass)}constructor(t,i,r,s,o,a,c,u,p,g,v,y){this._overlay=t,this._elementRef=i,this._scrollDispatcher=r,this._viewContainerRef=s,this._ngZone=o,this._platform=a,this._ariaDescriber=c,this._focusMonitor=u,this._dir=g,this._defaultOptions=v,this._position="below",this._positionAtOrigin=!1,this._disabled=!1,this._viewInitialized=!1,this._pointerExitEventsInitialized=!1,this._viewportMargin=8,this._cssClassPrefix="mat",this._showDelay=this._defaultOptions.showDelay,this._hideDelay=this._defaultOptions.hideDelay,this.touchGestures="auto",this._message="",this._passiveListeners=[],this._destroyed=new cn,this._scrollStrategy=p,this._document=y,v&&(v.position&&(this.position=v.position),v.positionAtOrigin&&(this.positionAtOrigin=v.positionAtOrigin),v.touchGestures&&(this.touchGestures=v.touchGestures)),g.change.pipe(Tr(this._destroyed)).subscribe(()=>{this._overlayRef&&this._updatePosition(this._overlayRef)})}ngAfterViewInit(){this._viewInitialized=!0,this._setupPointerEnterEventsIfNeeded(),this._focusMonitor.monitor(this._elementRef).pipe(Tr(this._destroyed)).subscribe(t=>{t?"keyboard"===t&&this._ngZone.run(()=>this.show()):this._ngZone.run(()=>this.hide(0))})}ngOnDestroy(){const t=this._elementRef.nativeElement;clearTimeout(this._touchstartTimeout),this._overlayRef&&(this._overlayRef.dispose(),this._tooltipInstance=null),this._passiveListeners.forEach(([i,r])=>{t.removeEventListener(i,r,S4)}),this._passiveListeners.length=0,this._destroyed.next(),this._destroyed.complete(),this._ariaDescriber.removeDescription(t,this.message,"tooltip"),this._focusMonitor.stopMonitoring(t)}show(t=this.showDelay,i){if(this.disabled||!this.message||this._isTooltipVisible())return void this._tooltipInstance?._cancelPendingAnimations();const r=this._createOverlay(i);this._detach(),this._portal=this._portal||new Ww(this._tooltipComponent,this._viewContainerRef);const s=this._tooltipInstance=r.attach(this._portal).instance;s._triggerElement=this._elementRef.nativeElement,s._mouseLeaveHideDelay=this._hideDelay,s.afterHidden().pipe(Tr(this._destroyed)).subscribe(()=>this._detach()),this._setTooltipClass(this._tooltipClass),this._updateTooltipMessage(),s.show(t)}hide(t=this.hideDelay){const i=this._tooltipInstance;i&&(i.isVisible()?i.hide(t):(i._cancelPendingAnimations(),this._detach()))}toggle(t){this._isTooltipVisible()?this.hide():this.show(void 0,t)}_isTooltipVisible(){return!!this._tooltipInstance&&this._tooltipInstance.isVisible()}_createOverlay(t){if(this._overlayRef){const s=this._overlayRef.getConfig().positionStrategy;if((!this.positionAtOrigin||!t)&&s._origin instanceof _n)return this._overlayRef;this._detach()}const i=this._scrollDispatcher.getAncestorScrollContainers(this._elementRef),r=this._overlay.position().flexibleConnectedTo(this.positionAtOrigin&&t||this._elementRef).withTransformOriginOn(`.${this._cssClassPrefix}-tooltip`).withFlexibleDimensions(!1).withViewportMargin(this._viewportMargin).withScrollableContainers(i);return r.positionChanges.pipe(Tr(this._destroyed)).subscribe(s=>{this._updateCurrentPositionClass(s.connectionPair),this._tooltipInstance&&s.scrollableViewProperties.isOverlayClipped&&this._tooltipInstance.isVisible()&&this._ngZone.run(()=>this.hide(0))}),this._overlayRef=this._overlay.create({direction:this._dir,positionStrategy:r,panelClass:`${this._cssClassPrefix}-${w4}`,scrollStrategy:this._scrollStrategy()}),this._updatePosition(this._overlayRef),this._overlayRef.detachments().pipe(Tr(this._destroyed)).subscribe(()=>this._detach()),this._overlayRef.outsidePointerEvents().pipe(Tr(this._destroyed)).subscribe(()=>this._tooltipInstance?._handleBodyInteraction()),this._overlayRef.keydownEvents().pipe(Tr(this._destroyed)).subscribe(s=>{this._isTooltipVisible()&&27===s.keyCode&&!ql(s)&&(s.preventDefault(),s.stopPropagation(),this._ngZone.run(()=>this.hide(0)))}),this._defaultOptions?.disableTooltipInteractivity&&this._overlayRef.addPanelClass(`${this._cssClassPrefix}-tooltip-panel-non-interactive`),this._overlayRef}_detach(){this._overlayRef&&this._overlayRef.hasAttached()&&this._overlayRef.detach(),this._tooltipInstance=null}_updatePosition(t){const i=t.getConfig().positionStrategy,r=this._getOrigin(),s=this._getOverlayPosition();i.withPositions([this._addOffset({...r.main,...s.main}),this._addOffset({...r.fallback,...s.fallback})])}_addOffset(t){return t}_getOrigin(){const t=!this._dir||"ltr"==this._dir.value,i=this.position;let r;"above"==i||"below"==i?r={originX:"center",originY:"above"==i?"top":"bottom"}:"before"==i||"left"==i&&t||"right"==i&&!t?r={originX:"start",originY:"center"}:("after"==i||"right"==i&&t||"left"==i&&!t)&&(r={originX:"end",originY:"center"});const{x:s,y:o}=this._invertPosition(r.originX,r.originY);return{main:r,fallback:{originX:s,originY:o}}}_getOverlayPosition(){const t=!this._dir||"ltr"==this._dir.value,i=this.position;let r;"above"==i?r={overlayX:"center",overlayY:"bottom"}:"below"==i?r={overlayX:"center",overlayY:"top"}:"before"==i||"left"==i&&t||"right"==i&&!t?r={overlayX:"end",overlayY:"center"}:("after"==i||"right"==i&&t||"left"==i&&!t)&&(r={overlayX:"start",overlayY:"center"});const{x:s,y:o}=this._invertPosition(r.overlayX,r.overlayY);return{main:r,fallback:{overlayX:s,overlayY:o}}}_updateTooltipMessage(){this._tooltipInstance&&(this._tooltipInstance.message=this.message,this._tooltipInstance._markForCheck(),this._ngZone.onMicrotaskEmpty.pipe(Gr(1),Tr(this._destroyed)).subscribe(()=>{this._tooltipInstance&&this._overlayRef.updatePosition()}))}_setTooltipClass(t){this._tooltipInstance&&(this._tooltipInstance.tooltipClass=t,this._tooltipInstance._markForCheck())}_invertPosition(t,i){return"above"===this.position||"below"===this.position?"top"===i?i="bottom":"bottom"===i&&(i="top"):"end"===t?t="start":"start"===t&&(t="end"),{x:t,y:i}}_updateCurrentPositionClass(t){const{overlayY:i,originX:r,originY:s}=t;let o;if(o="center"===i?this._dir&&"rtl"===this._dir.value?"end"===r?"left":"right":"start"===r?"left":"right":"bottom"===i&&"top"===s?"above":"below",o!==this._currentPosition){const a=this._overlayRef;if(a){const c=`${this._cssClassPrefix}-${w4}-`;a.removePanelClass(c+this._currentPosition),a.addPanelClass(c+o)}this._currentPosition=o}}_setupPointerEnterEventsIfNeeded(){this._disabled||!this.message||!this._viewInitialized||this._passiveListeners.length||(this._platformSupportsMouseEvents()?this._passiveListeners.push(["mouseenter",t=>{let i;this._setupPointerExitEventsIfNeeded(),void 0!==t.x&&void 0!==t.y&&(i=t),this.show(void 0,i)}]):"off"!==this.touchGestures&&(this._disableNativeGesturesIfNecessary(),this._passiveListeners.push(["touchstart",t=>{const i=t.targetTouches?.[0],r=i?{x:i.clientX,y:i.clientY}:void 0;this._setupPointerExitEventsIfNeeded(),clearTimeout(this._touchstartTimeout),this._touchstartTimeout=setTimeout(()=>this.show(void 0,r),500)}])),this._addListeners(this._passiveListeners))}_setupPointerExitEventsIfNeeded(){if(this._pointerExitEventsInitialized)return;this._pointerExitEventsInitialized=!0;const t=[];if(this._platformSupportsMouseEvents())t.push(["mouseleave",i=>{const r=i.relatedTarget;(!r||!this._overlayRef?.overlayElement.contains(r))&&this.hide()}],["wheel",i=>this._wheelListener(i)]);else if("off"!==this.touchGestures){this._disableNativeGesturesIfNecessary();const i=()=>{clearTimeout(this._touchstartTimeout),this.hide(this._defaultOptions.touchendHideDelay)};t.push(["touchend",i],["touchcancel",i])}this._addListeners(t),this._passiveListeners.push(...t)}_addListeners(t){t.forEach(([i,r])=>{this._elementRef.nativeElement.addEventListener(i,r,S4)})}_platformSupportsMouseEvents(){return!this._platform.IOS&&!this._platform.ANDROID}_wheelListener(t){if(this._isTooltipVisible()){const i=this._document.elementFromPoint(t.clientX,t.clientY),r=this._elementRef.nativeElement;i!==r&&!r.contains(i)&&this.hide()}}_disableNativeGesturesIfNecessary(){const t=this.touchGestures;if("off"!==t){const i=this._elementRef.nativeElement,r=i.style;("on"===t||"INPUT"!==i.nodeName&&"TEXTAREA"!==i.nodeName)&&(r.userSelect=r.msUserSelect=r.webkitUserSelect=r.MozUserSelect="none"),("on"===t||!i.draggable)&&(r.webkitUserDrag="none"),r.touchAction="none",r.webkitTapHighlightColor="transparent"}}}return n.\u0275fac=function(t){Gl()},n.\u0275dir=ut({type:n,inputs:{position:["matTooltipPosition","position"],positionAtOrigin:["matTooltipPositionAtOrigin","positionAtOrigin"],disabled:["matTooltipDisabled","disabled"],showDelay:["matTooltipShowDelay","showDelay"],hideDelay:["matTooltipHideDelay","hideDelay"],touchGestures:["matTooltipTouchGestures","touchGestures"],message:["matTooltip","message"],tooltipClass:["matTooltipClass","tooltipClass"]}}),n})(),rA=(()=>{class n extends LX{constructor(t,i,r,s,o,a,c,u,p,g,v,y){super(t,i,r,s,o,a,c,u,p,g,v,y),this._tooltipComponent=BX,this._cssClassPrefix="mat-mdc",this._viewportMargin=8}_addOffset(t){const r=!this._dir||"ltr"==this._dir.value;return"top"===t.originY?t.offsetY=-8:"bottom"===t.originY?t.offsetY=8:"start"===t.originX?t.offsetX=r?-8:8:"end"===t.originX&&(t.offsetX=r?8:-8),t}}return n.\u0275fac=function(t){return new(t||n)(ie(hl),ie(_n),ie(qv),ie(Sa),ie(Xt),ie(as),ie(d$),ie(Vf),ie(x4),ie(Yl,8),ie(kX,8),ie(Mn))},n.\u0275dir=ut({type:n,selectors:[["","matTooltip",""]],hostAttrs:[1,"mat-mdc-tooltip-trigger"],exportAs:["matTooltip"],features:[Z]}),n})(),NX=(()=>{class n{constructor(t,i){this._changeDetectorRef=t,this._closeOnInteraction=!1,this._isVisible=!1,this._onHide=new cn,this._animationsDisabled="NoopAnimations"===i}show(t){clearTimeout(this._hideTimeoutId),this._showTimeoutId=setTimeout(()=>{this._toggleVisibility(!0),this._showTimeoutId=void 0},t)}hide(t){clearTimeout(this._showTimeoutId),this._hideTimeoutId=setTimeout(()=>{this._toggleVisibility(!1),this._hideTimeoutId=void 0},t)}afterHidden(){return this._onHide}isVisible(){return this._isVisible}ngOnDestroy(){this._cancelPendingAnimations(),this._onHide.complete(),this._triggerElement=null}_handleBodyInteraction(){this._closeOnInteraction&&this.hide(0)}_markForCheck(){this._changeDetectorRef.markForCheck()}_handleMouseLeave({relatedTarget:t}){(!t||!this._triggerElement.contains(t))&&(this.isVisible()?this.hide(this._mouseLeaveHideDelay):this._finalizeAnimation(!1))}_onShow(){}_handleAnimationEnd({animationName:t}){(t===this._showAnimation||t===this._hideAnimation)&&this._finalizeAnimation(t===this._showAnimation)}_cancelPendingAnimations(){clearTimeout(this._showTimeoutId),clearTimeout(this._hideTimeoutId),this._showTimeoutId=this._hideTimeoutId=void 0}_finalizeAnimation(t){t?this._closeOnInteraction=!0:this.isVisible()||this._onHide.next()}_toggleVisibility(t){const i=this._tooltip.nativeElement,r=this._showAnimation,s=this._hideAnimation;if(i.classList.remove(t?s:r),i.classList.add(t?r:s),this._isVisible=t,t&&!this._animationsDisabled&&"function"==typeof getComputedStyle){const o=getComputedStyle(i);("0s"===o.getPropertyValue("animation-duration")||"none"===o.getPropertyValue("animation-name"))&&(this._animationsDisabled=!0)}t&&this._onShow(),this._animationsDisabled&&(i.classList.add("_mat-animation-noopable"),this._finalizeAnimation(t))}}return n.\u0275fac=function(t){return new(t||n)(ie(aa),ie(bo,8))},n.\u0275dir=ut({type:n}),n})(),BX=(()=>{class n extends NX{constructor(t,i,r){super(t,r),this._elementRef=i,this._isMultiline=!1,this._showAnimation="mat-mdc-tooltip-show",this._hideAnimation="mat-mdc-tooltip-hide"}_onShow(){this._isMultiline=this._isTooltipMultiline(),this._markForCheck()}_isTooltipMultiline(){const t=this._elementRef.nativeElement.getBoundingClientRect();return t.height>24&&t.width>=200}}return n.\u0275fac=function(t){return new(t||n)(ie(aa),ie(_n),ie(bo,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-tooltip-component"]],viewQuery:function(t,i){if(1&t&&zr(MX,7),2&t){let r;Yn(r=Xn())&&(i._tooltip=r.first)}},hostAttrs:["aria-hidden","true"],hostVars:2,hostBindings:function(t,i){1&t&&Gn("mouseleave",function(s){return i._handleMouseLeave(s)}),2&t&&dv("zoom",i.isVisible()?1:null)},features:[Z],decls:4,vars:4,consts:[[1,"mdc-tooltip","mdc-tooltip--shown","mat-mdc-tooltip",3,"ngClass","animationend"],["tooltip",""],[1,"mdc-tooltip__surface","mdc-tooltip__surface-animation"]],template:function(t,i){1&t&&(ke(0,"div",0,1),Gn("animationend",function(s){return i._handleAnimationEnd(s)}),ke(2,"div",2),it(3),Ne()()),2&t&&(hi("mdc-tooltip--multiline",i._isMultiline),$e("ngClass",i.tooltipClass),Le(3),Hi(i.message))},dependencies:[eg],styles:['.mdc-tooltip__surface{word-break:var(--mdc-tooltip-word-break, normal);overflow-wrap:anywhere}.mdc-tooltip{position:fixed;display:none;z-index:9}.mdc-tooltip-wrapper--rich{position:relative}.mdc-tooltip--shown,.mdc-tooltip--showing,.mdc-tooltip--hide{display:inline-flex}.mdc-tooltip--shown.mdc-tooltip--rich,.mdc-tooltip--showing.mdc-tooltip--rich,.mdc-tooltip--hide.mdc-tooltip--rich{display:inline-block;left:-320px;position:absolute}.mdc-tooltip__surface{line-height:16px;padding:4px 8px;min-width:40px;max-width:200px;min-height:24px;max-height:40vh;box-sizing:border-box;overflow:hidden;text-align:center}.mdc-tooltip__surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-tooltip__surface::before{border-color:CanvasText}}.mdc-tooltip--rich .mdc-tooltip__surface{align-items:flex-start;display:flex;flex-direction:column;min-height:24px;min-width:40px;max-width:320px;position:relative}.mdc-tooltip--multiline .mdc-tooltip__surface{text-align:left}[dir=rtl] .mdc-tooltip--multiline .mdc-tooltip__surface,.mdc-tooltip--multiline .mdc-tooltip__surface[dir=rtl]{text-align:right}.mdc-tooltip__surface .mdc-tooltip__title{margin:0 8px}.mdc-tooltip__surface .mdc-tooltip__content{max-width:calc(200px - (2 * 8px));margin:8px;text-align:left}[dir=rtl] .mdc-tooltip__surface .mdc-tooltip__content,.mdc-tooltip__surface .mdc-tooltip__content[dir=rtl]{text-align:right}.mdc-tooltip--rich .mdc-tooltip__surface .mdc-tooltip__content{max-width:calc(320px - (2 * 8px));align-self:stretch}.mdc-tooltip__surface .mdc-tooltip__content-link{text-decoration:none}.mdc-tooltip--rich-actions,.mdc-tooltip__content,.mdc-tooltip__title{z-index:1}.mdc-tooltip__surface-animation{opacity:0;transform:scale(0.8);will-change:transform,opacity}.mdc-tooltip--shown .mdc-tooltip__surface-animation{transform:scale(1);opacity:1}.mdc-tooltip--hide .mdc-tooltip__surface-animation{transform:scale(1)}.mdc-tooltip__caret-surface-top,.mdc-tooltip__caret-surface-bottom{position:absolute;height:24px;width:24px;transform:rotate(35deg) skewY(20deg) scaleX(0.9396926208)}.mdc-tooltip__caret-surface-top .mdc-elevation-overlay,.mdc-tooltip__caret-surface-bottom .mdc-elevation-overlay{width:100%;height:100%;top:0;left:0}.mdc-tooltip__caret-surface-bottom{outline:1px solid rgba(0,0,0,0);z-index:-1}@media screen and (forced-colors: active){.mdc-tooltip__caret-surface-bottom{outline-color:CanvasText}}.mdc-tooltip__surface{background-color:var(--mdc-plain-tooltip-container-color, #fff)}.mdc-tooltip__surface{border-radius:var(--mdc-plain-tooltip-container-shape, var(--mdc-shape-small, 4px))}.mdc-tooltip__caret-surface-top,.mdc-tooltip__caret-surface-bottom{border-radius:var(--mdc-plain-tooltip-container-shape, var(--mdc-shape-small, 4px))}.mdc-tooltip__surface{color:var(--mdc-plain-tooltip-supporting-text-color, #000)}.mdc-tooltip__surface{font-family:var(--mdc-plain-tooltip-supporting-text-font, inherit);font-size:var(--mdc-plain-tooltip-supporting-text-size, inherit);font-weight:var(--mdc-plain-tooltip-supporting-text-weight, inherit);letter-spacing:var(--mdc-plain-tooltip-supporting-text-tracking, inherit)}.mat-mdc-tooltip{position:relative;transform:scale(0)}.mat-mdc-tooltip::before{content:"";top:-8px;right:-8px;bottom:-8px;left:-8px;z-index:-1;position:absolute}.mat-mdc-tooltip._mat-animation-noopable{animation:none;transform:scale(1)}.mat-mdc-tooltip-panel-non-interactive{pointer-events:none}@keyframes mat-mdc-tooltip-show{0%{opacity:0;transform:scale(0.8)}100%{opacity:1;transform:scale(1)}}@keyframes mat-mdc-tooltip-hide{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(0.8)}}.mat-mdc-tooltip-show{animation:mat-mdc-tooltip-show 150ms cubic-bezier(0, 0, 0.2, 1) forwards}.mat-mdc-tooltip-hide{animation:mat-mdc-tooltip-hide 75ms cubic-bezier(0.4, 0, 1, 1) forwards}'],encapsulation:2,changeDetection:0}),n})(),VX=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:[TX],imports:[$L,ul,Kw,rr,rr,jw]}),n})();function E4(n){return new Ue(3e3,!1)}function bZ(){return typeof window<"u"&&typeof window.document<"u"}function sA(){return typeof process<"u"&&"[object process]"==={}.toString.call(process)}function oh(n){switch(n.length){case 0:return new Qv;case 1:return n[0];default:return new WN(n)}}function M4(n,e,t,i,r=new Map,s=new Map){const o=[],a=[];let c=-1,u=null;if(i.forEach(p=>{const g=p.get("offset"),v=g==c,y=v&&u||new Map;p.forEach((x,T)=>{let N=T,k=x;if("offset"!==T)switch(N=e.normalizePropertyName(N,o),k){case nA:k=r.get(T);break;case Ud:k=s.get(T);break;default:k=e.normalizeStyleValue(T,N,k,o)}y.set(N,k)}),v||a.push(y),u=y,c=g}),o.length)throw function cZ(n){return new Ue(3502,!1)}();return a}function oA(n,e,t,i){switch(e){case"start":n.onStart(()=>i(t&&aA(t,"start",n)));break;case"done":n.onDone(()=>i(t&&aA(t,"done",n)));break;case"destroy":n.onDestroy(()=>i(t&&aA(t,"destroy",n)))}}function aA(n,e,t){const s=cA(n.element,n.triggerName,n.fromState,n.toState,e||n.phaseName,t.totalTime??n.totalTime,!!t.disabled),o=n._data;return null!=o&&(s._data=o),s}function cA(n,e,t,i,r="",s=0,o){return{element:n,triggerName:e,fromState:t,toState:i,phaseName:r,totalTime:s,disabled:!!o}}function Qa(n,e,t){let i=n.get(e);return i||n.set(e,i=t),i}function C4(n){const e=n.indexOf(":");return[n.substring(1,e),n.slice(e+1)]}let lA=(n,e)=>!1,D4=(n,e,t)=>[],T4=null;function dA(n){const e=n.parentNode||n.host;return e===T4?null:e}(sA()||typeof Element<"u")&&(bZ()?(T4=(()=>document.documentElement)(),lA=(n,e)=>{for(;e;){if(e===n)return!0;e=dA(e)}return!1}):lA=(n,e)=>n.contains(e),D4=(n,e,t)=>{if(t)return Array.from(n.querySelectorAll(e));const i=n.querySelector(e);return i?[i]:[]});let zf=null,A4=!1;const k4=lA,I4=D4;let F4=(()=>{class n{validateStyleProperty(t){return function wZ(n){zf||(zf=function SZ(){return typeof document<"u"?document.body:null}()||{},A4=!!zf.style&&"WebkitAppearance"in zf.style);let e=!0;return zf.style&&!function xZ(n){return"ebkit"==n.substring(1,6)}(n)&&(e=n in zf.style,!e&&A4&&(e="Webkit"+n.charAt(0).toUpperCase()+n.slice(1)in zf.style)),e}(t)}matchesElement(t,i){return!1}containsElement(t,i){return k4(t,i)}getParentElement(t){return dA(t)}query(t,i,r){return I4(t,i,r)}computeStyle(t,i,r){return r||""}animate(t,i,r,s,o,a=[],c){return new Qv(r,s)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),uA=(()=>{class n{}return n.NOOP=new F4,n})();const EZ=1e3,hA="ng-enter",rS="ng-leave",sS="ng-trigger",oS=".ng-trigger",P4="ng-animating",fA=".ng-animating";function Gd(n){if("number"==typeof n)return n;const e=n.match(/^(-?[\.\d]+)(m?s)/);return!e||e.length<2?0:pA(parseFloat(e[1]),e[2])}function pA(n,e){return"s"===e?n*EZ:n}function aS(n,e,t){return n.hasOwnProperty("duration")?n:function CZ(n,e,t){let r,s=0,o="";if("string"==typeof n){const a=n.match(/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i);if(null===a)return e.push(E4()),{duration:0,delay:0,easing:""};r=pA(parseFloat(a[1]),a[2]);const c=a[3];null!=c&&(s=pA(parseFloat(c),a[4]));const u=a[5];u&&(o=u)}else r=n;if(!t){let a=!1,c=e.length;r<0&&(e.push(function HX(){return new Ue(3100,!1)}()),a=!0),s<0&&(e.push(function UX(){return new Ue(3101,!1)}()),a=!0),a&&e.splice(c,0,E4())}return{duration:r,delay:s,easing:o}}(n,e,t)}function ty(n,e={}){return Object.keys(n).forEach(t=>{e[t]=n[t]}),e}function O4(n){const e=new Map;return Object.keys(n).forEach(t=>{e.set(t,n[t])}),e}function ah(n,e=new Map,t){if(t)for(let[i,r]of t)e.set(i,r);for(let[i,r]of n)e.set(i,r);return e}function N4(n,e,t){return t?e+":"+t+";":""}function B4(n){let e="";for(let t=0;t{const s=gA(r);t&&!t.has(r)&&t.set(r,n.style[s]),n.style[s]=i}),sA()&&B4(n))}function Gf(n,e){n.style&&(e.forEach((t,i)=>{const r=gA(i);n.style[r]=""}),sA()&&B4(n))}function ny(n){return Array.isArray(n)?1==n.length?n[0]:GN(n):n}const mA=new RegExp("{{\\s*(.+?)\\s*}}","g");function V4(n){let e=[];if("string"==typeof n){let t;for(;t=mA.exec(n);)e.push(t[1]);mA.lastIndex=0}return e}function iy(n,e,t){const i=n.toString(),r=i.replace(mA,(s,o)=>{let a=e[o];return null==a&&(t.push(function GX(n){return new Ue(3003,!1)}()),a=""),a.toString()});return r==i?n:r}function cS(n){const e=[];let t=n.next();for(;!t.done;)e.push(t.value),t=n.next();return e}const AZ=/-+([a-z0-9])/g;function gA(n){return n.replace(AZ,(...e)=>e[1].toUpperCase())}function kZ(n){return n.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function ec(n,e,t){switch(e.type){case 7:return n.visitTrigger(e,t);case 0:return n.visitState(e,t);case 1:return n.visitTransition(e,t);case 2:return n.visitSequence(e,t);case 3:return n.visitGroup(e,t);case 4:return n.visitAnimate(e,t);case 5:return n.visitKeyframes(e,t);case 6:return n.visitStyle(e,t);case 8:return n.visitReference(e,t);case 9:return n.visitAnimateChild(e,t);case 10:return n.visitAnimateRef(e,t);case 11:return n.visitQuery(e,t);case 12:return n.visitStagger(e,t);default:throw function jX(n){return new Ue(3004,!1)}()}}function H4(n,e){return window.getComputedStyle(n)[e]}const uS="*";function LZ(n,e){const t=[];return"string"==typeof n?n.split(/\s*,\s*/).forEach(i=>function NZ(n,e,t){if(":"==n[0]){const c=function BZ(n,e){switch(n){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(t,i)=>parseFloat(i)>parseFloat(t);case":decrement":return(t,i)=>parseFloat(i) *"}}(n,t);if("function"==typeof c)return void e.push(c);n=c}const i=n.match(/^(\*|[-\w]+)\s*()\s*(\*|[-\w]+)$/);if(null==i||i.length<4)return t.push(function iZ(n){return new Ue(3015,!1)}()),e;const r=i[1],s=i[2],o=i[3];e.push(U4(r,o));"<"==s[0]&&!(r==uS&&o==uS)&&e.push(U4(o,r))}(i,t,e)):t.push(n),t}const hS=new Set(["true","1"]),fS=new Set(["false","0"]);function U4(n,e){const t=hS.has(n)||fS.has(n),i=hS.has(e)||fS.has(e);return(r,s)=>{let o=n==uS||n==r,a=e==uS||e==s;return!o&&t&&"boolean"==typeof r&&(o=r?hS.has(n):fS.has(n)),!a&&i&&"boolean"==typeof s&&(a=s?hS.has(e):fS.has(e)),o&&a}}const VZ=new RegExp("s*:selfs*,?","g");function _A(n,e,t,i){return new HZ(n).build(e,t,i)}class HZ{constructor(e){this._driver=e}build(e,t,i){const r=new GZ(t);return this._resetContextStyleTimingState(r),ec(this,ny(e),r)}_resetContextStyleTimingState(e){e.currentQuerySelector="",e.collectedStyles=new Map,e.collectedStyles.set("",new Map),e.currentTime=0}visitTrigger(e,t){let i=t.queryCount=0,r=t.depCount=0;const s=[],o=[];return"@"==e.name.charAt(0)&&t.errors.push(function $X(){return new Ue(3006,!1)}()),e.definitions.forEach(a=>{if(this._resetContextStyleTimingState(t),0==a.type){const c=a,u=c.name;u.toString().split(/\s*,\s*/).forEach(p=>{c.name=p,s.push(this.visitState(c,t))}),c.name=u}else if(1==a.type){const c=this.visitTransition(a,t);i+=c.queryCount,r+=c.depCount,o.push(c)}else t.errors.push(function qX(){return new Ue(3007,!1)}())}),{type:7,name:e.name,states:s,transitions:o,queryCount:i,depCount:r,options:null}}visitState(e,t){const i=this.visitStyle(e.styles,t),r=e.options&&e.options.params||null;if(i.containsDynamicStyles){const s=new Set,o=r||{};i.styles.forEach(a=>{a instanceof Map&&a.forEach(c=>{V4(c).forEach(u=>{o.hasOwnProperty(u)||s.add(u)})})}),s.size&&(cS(s.values()),t.errors.push(function KX(n,e){return new Ue(3008,!1)}()))}return{type:0,name:e.name,style:i,options:r?{params:r}:null}}visitTransition(e,t){t.queryCount=0,t.depCount=0;const i=ec(this,ny(e.animation),t);return{type:1,matchers:LZ(e.expr,t.errors),animation:i,queryCount:t.queryCount,depCount:t.depCount,options:jf(e.options)}}visitSequence(e,t){return{type:2,steps:e.steps.map(i=>ec(this,i,t)),options:jf(e.options)}}visitGroup(e,t){const i=t.currentTime;let r=0;const s=e.steps.map(o=>{t.currentTime=i;const a=ec(this,o,t);return r=Math.max(r,t.currentTime),a});return t.currentTime=r,{type:3,steps:s,options:jf(e.options)}}visitAnimate(e,t){const i=function WZ(n,e){if(n.hasOwnProperty("duration"))return n;if("number"==typeof n)return vA(aS(n,e).duration,0,"");const t=n;if(t.split(/\s+/).some(s=>"{"==s.charAt(0)&&"{"==s.charAt(1))){const s=vA(0,0,"");return s.dynamic=!0,s.strValue=t,s}const r=aS(t,e);return vA(r.duration,r.delay,r.easing)}(e.timings,t.errors);t.currentAnimateTimings=i;let r,s=e.styles?e.styles:la({});if(5==s.type)r=this.visitKeyframes(s,t);else{let o=e.styles,a=!1;if(!o){a=!0;const u={};i.easing&&(u.easing=i.easing),o=la(u)}t.currentTime+=i.duration+i.delay;const c=this.visitStyle(o,t);c.isEmptyStep=a,r=c}return t.currentAnimateTimings=null,{type:4,timings:i,style:r,options:null}}visitStyle(e,t){const i=this._makeStyleAst(e,t);return this._validateStyleAst(i,t),i}_makeStyleAst(e,t){const i=[],r=Array.isArray(e.styles)?e.styles:[e.styles];for(let a of r)"string"==typeof a?a===Ud?i.push(a):t.errors.push(new Ue(3002,!1)):i.push(O4(a));let s=!1,o=null;return i.forEach(a=>{if(a instanceof Map&&(a.has("easing")&&(o=a.get("easing"),a.delete("easing")),!s))for(let c of a.values())if(c.toString().indexOf("{{")>=0){s=!0;break}}),{type:6,styles:i,easing:o,offset:e.offset,containsDynamicStyles:s,options:null}}_validateStyleAst(e,t){const i=t.currentAnimateTimings;let r=t.currentTime,s=t.currentTime;i&&s>0&&(s-=i.duration+i.delay),e.styles.forEach(o=>{"string"!=typeof o&&o.forEach((a,c)=>{const u=t.collectedStyles.get(t.currentQuerySelector),p=u.get(c);let g=!0;p&&(s!=r&&s>=p.startTime&&r<=p.endTime&&(t.errors.push(function XX(n,e,t,i,r){return new Ue(3010,!1)}()),g=!1),s=p.startTime),g&&u.set(c,{startTime:s,endTime:r}),t.options&&function TZ(n,e,t){const i=e.params||{},r=V4(n);r.length&&r.forEach(s=>{i.hasOwnProperty(s)||t.push(function zX(n){return new Ue(3001,!1)}())})}(a,t.options,t.errors)})})}visitKeyframes(e,t){const i={type:5,styles:[],options:null};if(!t.currentAnimateTimings)return t.errors.push(function ZX(){return new Ue(3011,!1)}()),i;let s=0;const o=[];let a=!1,c=!1,u=0;const p=e.steps.map(k=>{const A=this._makeStyleAst(k,t);let H=null!=A.offset?A.offset:function jZ(n){if("string"==typeof n)return null;let e=null;if(Array.isArray(n))n.forEach(t=>{if(t instanceof Map&&t.has("offset")){const i=t;e=parseFloat(i.get("offset")),i.delete("offset")}});else if(n instanceof Map&&n.has("offset")){const t=n;e=parseFloat(t.get("offset")),t.delete("offset")}return e}(A.styles),G=0;return null!=H&&(s++,G=A.offset=H),c=c||G<0||G>1,a=a||G0&&s{const H=v>0?A==y?1:v*A:o[A],G=H*N;t.currentTime=x+T.delay+G,T.duration=G,this._validateStyleAst(k,t),k.offset=H,i.styles.push(k)}),i}visitReference(e,t){return{type:8,animation:ec(this,ny(e.animation),t),options:jf(e.options)}}visitAnimateChild(e,t){return t.depCount++,{type:9,options:jf(e.options)}}visitAnimateRef(e,t){return{type:10,animation:this.visitReference(e.animation,t),options:jf(e.options)}}visitQuery(e,t){const i=t.currentQuerySelector,r=e.options||{};t.queryCount++,t.currentQuery=e;const[s,o]=function UZ(n){const e=!!n.split(/\s*,\s*/).find(t=>":self"==t);return e&&(n=n.replace(VZ,"")),n=n.replace(/@\*/g,oS).replace(/@\w+/g,t=>oS+"-"+t.slice(1)).replace(/:animating/g,fA),[n,e]}(e.selector);t.currentQuerySelector=i.length?i+" "+s:s,Qa(t.collectedStyles,t.currentQuerySelector,new Map);const a=ec(this,ny(e.animation),t);return t.currentQuery=null,t.currentQuerySelector=i,{type:11,selector:s,limit:r.limit||0,optional:!!r.optional,includeSelf:o,animation:a,originalSelector:e.selector,options:jf(e.options)}}visitStagger(e,t){t.currentQuery||t.errors.push(function tZ(){return new Ue(3013,!1)}());const i="full"===e.timings?{duration:0,delay:0,easing:"full"}:aS(e.timings,t.errors,!0);return{type:12,animation:ec(this,ny(e.animation),t),timings:i,options:null}}}class GZ{constructor(e){this.errors=e,this.queryCount=0,this.depCount=0,this.currentTransition=null,this.currentQuery=null,this.currentQuerySelector=null,this.currentAnimateTimings=null,this.currentTime=0,this.collectedStyles=new Map,this.options=null,this.unsupportedCSSPropertiesFound=new Set}}function jf(n){return n?(n=ty(n)).params&&(n.params=function zZ(n){return n?ty(n):null}(n.params)):n={},n}function vA(n,e,t){return{duration:n,delay:e,easing:t}}function yA(n,e,t,i,r,s,o=null,a=!1){return{type:1,element:n,keyframes:e,preStyleProps:t,postStyleProps:i,duration:r,delay:s,totalTime:r+s,easing:o,subTimeline:a}}class pS{constructor(){this._map=new Map}get(e){return this._map.get(e)||[]}append(e,t){let i=this._map.get(e);i||this._map.set(e,i=[]),i.push(...t)}has(e){return this._map.has(e)}clear(){this._map.clear()}}const KZ=new RegExp(":enter","g"),XZ=new RegExp(":leave","g");function bA(n,e,t,i,r,s=new Map,o=new Map,a,c,u=[]){return(new ZZ).buildKeyframes(n,e,t,i,r,s,o,a,c,u)}class ZZ{buildKeyframes(e,t,i,r,s,o,a,c,u,p=[]){u=u||new pS;const g=new xA(e,t,u,r,s,p,[]);g.options=c;const v=c.delay?Gd(c.delay):0;g.currentTimeline.delayNextStep(v),g.currentTimeline.setStyles([o],null,g.errors,c),ec(this,i,g);const y=g.timelines.filter(x=>x.containsAnimation());if(y.length&&a.size){let x;for(let T=y.length-1;T>=0;T--){const N=y[T];if(N.element===t){x=N;break}}x&&!x.allowOnlyTimelineStyles()&&x.setStyles([a],null,g.errors,c)}return y.length?y.map(x=>x.buildKeyframes()):[yA(t,[],[],[],0,v,"",!1)]}visitTrigger(e,t){}visitState(e,t){}visitTransition(e,t){}visitAnimateChild(e,t){const i=t.subInstructions.get(t.element);if(i){const r=t.createSubContext(e.options),s=t.currentTimeline.currentTime,o=this._visitSubInstructions(i,r,r.options);s!=o&&t.transformIntoNewTimeline(o)}t.previousNode=e}visitAnimateRef(e,t){const i=t.createSubContext(e.options);i.transformIntoNewTimeline(),this._applyAnimationRefDelays([e.options,e.animation.options],t,i),this.visitReference(e.animation,i),t.transformIntoNewTimeline(i.currentTimeline.currentTime),t.previousNode=e}_applyAnimationRefDelays(e,t,i){for(const r of e){const s=r?.delay;if(s){const o="number"==typeof s?s:Gd(iy(s,r?.params??{},t.errors));i.delayNextStep(o)}}}_visitSubInstructions(e,t,i){let s=t.currentTimeline.currentTime;const o=null!=i.duration?Gd(i.duration):null,a=null!=i.delay?Gd(i.delay):null;return 0!==o&&e.forEach(c=>{const u=t.appendInstructionToTimeline(c,o,a);s=Math.max(s,u.duration+u.delay)}),s}visitReference(e,t){t.updateOptions(e.options,!0),ec(this,e.animation,t),t.previousNode=e}visitSequence(e,t){const i=t.subContextCount;let r=t;const s=e.options;if(s&&(s.params||s.delay)&&(r=t.createSubContext(s),r.transformIntoNewTimeline(),null!=s.delay)){6==r.previousNode.type&&(r.currentTimeline.snapshotCurrentStyles(),r.previousNode=mS);const o=Gd(s.delay);r.delayNextStep(o)}e.steps.length&&(e.steps.forEach(o=>ec(this,o,r)),r.currentTimeline.applyStylesToKeyframe(),r.subContextCount>i&&r.transformIntoNewTimeline()),t.previousNode=e}visitGroup(e,t){const i=[];let r=t.currentTimeline.currentTime;const s=e.options&&e.options.delay?Gd(e.options.delay):0;e.steps.forEach(o=>{const a=t.createSubContext(e.options);s&&a.delayNextStep(s),ec(this,o,a),r=Math.max(r,a.currentTimeline.currentTime),i.push(a.currentTimeline)}),i.forEach(o=>t.currentTimeline.mergeTimelineCollectedStyles(o)),t.transformIntoNewTimeline(r),t.previousNode=e}_visitTiming(e,t){if(e.dynamic){const i=e.strValue;return aS(t.params?iy(i,t.params,t.errors):i,t.errors)}return{duration:e.duration,delay:e.delay,easing:e.easing}}visitAnimate(e,t){const i=t.currentAnimateTimings=this._visitTiming(e.timings,t),r=t.currentTimeline;i.delay&&(t.incrementTime(i.delay),r.snapshotCurrentStyles());const s=e.style;5==s.type?this.visitKeyframes(s,t):(t.incrementTime(i.duration),this.visitStyle(s,t),r.applyStylesToKeyframe()),t.currentAnimateTimings=null,t.previousNode=e}visitStyle(e,t){const i=t.currentTimeline,r=t.currentAnimateTimings;!r&&i.hasCurrentStyleProperties()&&i.forwardFrame();const s=r&&r.easing||e.easing;e.isEmptyStep?i.applyEmptyStep(s):i.setStyles(e.styles,s,t.errors,t.options),t.previousNode=e}visitKeyframes(e,t){const i=t.currentAnimateTimings,r=t.currentTimeline.duration,s=i.duration,a=t.createSubContext().currentTimeline;a.easing=i.easing,e.styles.forEach(c=>{a.forwardTime((c.offset||0)*s),a.setStyles(c.styles,c.easing,t.errors,t.options),a.applyStylesToKeyframe()}),t.currentTimeline.mergeTimelineCollectedStyles(a),t.transformIntoNewTimeline(r+s),t.previousNode=e}visitQuery(e,t){const i=t.currentTimeline.currentTime,r=e.options||{},s=r.delay?Gd(r.delay):0;s&&(6===t.previousNode.type||0==i&&t.currentTimeline.hasCurrentStyleProperties())&&(t.currentTimeline.snapshotCurrentStyles(),t.previousNode=mS);let o=i;const a=t.invokeQuery(e.selector,e.originalSelector,e.limit,e.includeSelf,!!r.optional,t.errors);t.currentQueryTotal=a.length;let c=null;a.forEach((u,p)=>{t.currentQueryIndex=p;const g=t.createSubContext(e.options,u);s&&g.delayNextStep(s),u===t.element&&(c=g.currentTimeline),ec(this,e.animation,g),g.currentTimeline.applyStylesToKeyframe(),o=Math.max(o,g.currentTimeline.currentTime)}),t.currentQueryIndex=0,t.currentQueryTotal=0,t.transformIntoNewTimeline(o),c&&(t.currentTimeline.mergeTimelineCollectedStyles(c),t.currentTimeline.snapshotCurrentStyles()),t.previousNode=e}visitStagger(e,t){const i=t.parentContext,r=t.currentTimeline,s=e.timings,o=Math.abs(s.duration),a=o*(t.currentQueryTotal-1);let c=o*t.currentQueryIndex;switch(s.duration<0?"reverse":s.easing){case"reverse":c=a-c;break;case"full":c=i.currentStaggerTime}const p=t.currentTimeline;c&&p.delayNextStep(c);const g=p.currentTime;ec(this,e.animation,t),t.previousNode=e,i.currentStaggerTime=r.currentTime-g+(r.startTime-i.currentTimeline.startTime)}}const mS={};class xA{constructor(e,t,i,r,s,o,a,c){this._driver=e,this.element=t,this.subInstructions=i,this._enterClassName=r,this._leaveClassName=s,this.errors=o,this.timelines=a,this.parentContext=null,this.currentAnimateTimings=null,this.previousNode=mS,this.subContextCount=0,this.options={},this.currentQueryIndex=0,this.currentQueryTotal=0,this.currentStaggerTime=0,this.currentTimeline=c||new gS(this._driver,t,0),a.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(e,t){if(!e)return;const i=e;let r=this.options;null!=i.duration&&(r.duration=Gd(i.duration)),null!=i.delay&&(r.delay=Gd(i.delay));const s=i.params;if(s){let o=r.params;o||(o=this.options.params={}),Object.keys(s).forEach(a=>{(!t||!o.hasOwnProperty(a))&&(o[a]=iy(s[a],o,this.errors))})}}_copyOptions(){const e={};if(this.options){const t=this.options.params;if(t){const i=e.params={};Object.keys(t).forEach(r=>{i[r]=t[r]})}}return e}createSubContext(e=null,t,i){const r=t||this.element,s=new xA(this._driver,r,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(r,i||0));return s.previousNode=this.previousNode,s.currentAnimateTimings=this.currentAnimateTimings,s.options=this._copyOptions(),s.updateOptions(e),s.currentQueryIndex=this.currentQueryIndex,s.currentQueryTotal=this.currentQueryTotal,s.parentContext=this,this.subContextCount++,s}transformIntoNewTimeline(e){return this.previousNode=mS,this.currentTimeline=this.currentTimeline.fork(this.element,e),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(e,t,i){const r={duration:t??e.duration,delay:this.currentTimeline.currentTime+(i??0)+e.delay,easing:""},s=new JZ(this._driver,e.element,e.keyframes,e.preStyleProps,e.postStyleProps,r,e.stretchStartingKeyframe);return this.timelines.push(s),r}incrementTime(e){this.currentTimeline.forwardTime(this.currentTimeline.duration+e)}delayNextStep(e){e>0&&this.currentTimeline.delayNextStep(e)}invokeQuery(e,t,i,r,s,o){let a=[];if(r&&a.push(this.element),e.length>0){e=(e=e.replace(KZ,"."+this._enterClassName)).replace(XZ,"."+this._leaveClassName);let u=this._driver.query(this.element,e,1!=i);0!==i&&(u=i<0?u.slice(u.length+i,u.length):u.slice(0,i)),a.push(...u)}return!s&&0==a.length&&o.push(function nZ(n){return new Ue(3014,!1)}()),a}}class gS{constructor(e,t,i,r){this._driver=e,this.element=t,this.startTime=i,this._elementTimelineStylesLookup=r,this.duration=0,this._previousKeyframe=new Map,this._currentKeyframe=new Map,this._keyframes=new Map,this._styleSummary=new Map,this._localTimelineStyles=new Map,this._pendingStyles=new Map,this._backFill=new Map,this._currentEmptyStepKeyframe=null,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(t),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(t,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.hasCurrentStyleProperties();default:return!0}}hasCurrentStyleProperties(){return this._currentKeyframe.size>0}get currentTime(){return this.startTime+this.duration}delayNextStep(e){const t=1===this._keyframes.size&&this._pendingStyles.size;this.duration||t?(this.forwardTime(this.currentTime+e),t&&this.snapshotCurrentStyles()):this.startTime+=e}fork(e,t){return this.applyStylesToKeyframe(),new gS(this._driver,e,t||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=new Map,this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=1,this._loadKeyframe()}forwardTime(e){this.applyStylesToKeyframe(),this.duration=e,this._loadKeyframe()}_updateStyle(e,t){this._localTimelineStyles.set(e,t),this._globalTimelineStyles.set(e,t),this._styleSummary.set(e,{time:this.currentTime,value:t})}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(e){e&&this._previousKeyframe.set("easing",e);for(let[t,i]of this._globalTimelineStyles)this._backFill.set(t,i||Ud),this._currentKeyframe.set(t,Ud);this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(e,t,i,r){t&&this._previousKeyframe.set("easing",t);const s=r&&r.params||{},o=function QZ(n,e){const t=new Map;let i;return n.forEach(r=>{if("*"===r){i=i||e.keys();for(let s of i)t.set(s,Ud)}else ah(r,t)}),t}(e,this._globalTimelineStyles);for(let[a,c]of o){const u=iy(c,s,i);this._pendingStyles.set(a,u),this._localTimelineStyles.has(a)||this._backFill.set(a,this._globalTimelineStyles.get(a)??Ud),this._updateStyle(a,u)}}applyStylesToKeyframe(){0!=this._pendingStyles.size&&(this._pendingStyles.forEach((e,t)=>{this._currentKeyframe.set(t,e)}),this._pendingStyles.clear(),this._localTimelineStyles.forEach((e,t)=>{this._currentKeyframe.has(t)||this._currentKeyframe.set(t,e)}))}snapshotCurrentStyles(){for(let[e,t]of this._localTimelineStyles)this._pendingStyles.set(e,t),this._updateStyle(e,t)}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){const e=[];for(let t in this._currentKeyframe)e.push(t);return e}mergeTimelineCollectedStyles(e){e._styleSummary.forEach((t,i)=>{const r=this._styleSummary.get(i);(!r||t.time>r.time)&&this._updateStyle(i,t.value)})}buildKeyframes(){this.applyStylesToKeyframe();const e=new Set,t=new Set,i=1===this._keyframes.size&&0===this.duration;let r=[];this._keyframes.forEach((a,c)=>{const u=ah(a,new Map,this._backFill);u.forEach((p,g)=>{p===nA?e.add(g):p===Ud&&t.add(g)}),i||u.set("offset",c/this.duration),r.push(u)});const s=e.size?cS(e.values()):[],o=t.size?cS(t.values()):[];if(i){const a=r[0],c=new Map(a);a.set("offset",0),c.set("offset",1),r=[a,c]}return yA(this.element,r,s,o,this.duration,this.startTime,this.easing,!1)}}class JZ extends gS{constructor(e,t,i,r,s,o,a=!1){super(e,t,o.delay),this.keyframes=i,this.preStyleProps=r,this.postStyleProps=s,this._stretchStartingKeyframe=a,this.timings={duration:o.duration,delay:o.delay,easing:o.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let e=this.keyframes,{delay:t,duration:i,easing:r}=this.timings;if(this._stretchStartingKeyframe&&t){const s=[],o=i+t,a=t/o,c=ah(e[0]);c.set("offset",0),s.push(c);const u=ah(e[0]);u.set("offset",j4(a)),s.push(u);const p=e.length-1;for(let g=1;g<=p;g++){let v=ah(e[g]);const y=v.get("offset");v.set("offset",j4((t+y*i)/o)),s.push(v)}i=o,t=0,r="",e=s}return yA(this.element,e,this.preStyleProps,this.postStyleProps,i,t,r,!0)}}function j4(n,e=3){const t=Math.pow(10,e-1);return Math.round(n*t)/t}class wA{}const eJ=new Set(["width","height","minWidth","minHeight","maxWidth","maxHeight","left","top","bottom","right","fontSize","outlineWidth","outlineOffset","paddingTop","paddingLeft","paddingBottom","paddingRight","marginTop","marginLeft","marginBottom","marginRight","borderRadius","borderWidth","borderTopWidth","borderLeftWidth","borderRightWidth","borderBottomWidth","textIndent","perspective"]);class tJ extends wA{normalizePropertyName(e,t){return gA(e)}normalizeStyleValue(e,t,i,r){let s="";const o=i.toString().trim();if(eJ.has(t)&&0!==i&&"0"!==i)if("number"==typeof i)s="px";else{const a=i.match(/^[+-]?[\d\.]+([a-z]*)$/);a&&0==a[1].length&&r.push(function WX(n,e){return new Ue(3005,!1)}())}return o+s}}function W4(n,e,t,i,r,s,o,a,c,u,p,g,v){return{type:0,element:n,triggerName:e,isRemovalTransition:r,fromState:t,fromStyles:s,toState:i,toStyles:o,timelines:a,queriedElements:c,preStyleProps:u,postStyleProps:p,totalTime:g,errors:v}}const SA={};class $4{constructor(e,t,i){this._triggerName=e,this.ast=t,this._stateStyles=i}match(e,t,i,r){return function nJ(n,e,t,i,r){return n.some(s=>s(e,t,i,r))}(this.ast.matchers,e,t,i,r)}buildStyles(e,t,i){let r=this._stateStyles.get("*");return void 0!==e&&(r=this._stateStyles.get(e?.toString())||r),r?r.buildStyles(t,i):new Map}build(e,t,i,r,s,o,a,c,u,p){const g=[],v=this.ast.options&&this.ast.options.params||SA,x=this.buildStyles(i,a&&a.params||SA,g),T=c&&c.params||SA,N=this.buildStyles(r,T,g),k=new Set,A=new Map,H=new Map,G="void"===r,X={params:iJ(T,v),delay:this.ast.options?.delay},se=p?[]:bA(e,t,this.ast.animation,s,o,x,N,X,u,g);let K=0;if(se.forEach(De=>{K=Math.max(De.duration+De.delay,K)}),g.length)return W4(t,this._triggerName,i,r,G,x,N,[],[],A,H,K,g);se.forEach(De=>{const Te=De.element,ge=Qa(A,Te,new Set);De.preStyleProps.forEach(Pe=>ge.add(Pe));const Qe=Qa(H,Te,new Set);De.postStyleProps.forEach(Pe=>Qe.add(Pe)),Te!==t&&k.add(Te)});const he=cS(k.values());return W4(t,this._triggerName,i,r,G,x,N,se,he,A,H,K)}}function iJ(n,e){const t=ty(e);for(const i in n)n.hasOwnProperty(i)&&null!=n[i]&&(t[i]=n[i]);return t}class rJ{constructor(e,t,i){this.styles=e,this.defaultParams=t,this.normalizer=i}buildStyles(e,t){const i=new Map,r=ty(this.defaultParams);return Object.keys(e).forEach(s=>{const o=e[s];null!==o&&(r[s]=o)}),this.styles.styles.forEach(s=>{"string"!=typeof s&&s.forEach((o,a)=>{o&&(o=iy(o,r,t));const c=this.normalizer.normalizePropertyName(a,t);o=this.normalizer.normalizeStyleValue(a,c,o,t),i.set(a,o)})}),i}}class oJ{constructor(e,t,i){this.name=e,this.ast=t,this._normalizer=i,this.transitionFactories=[],this.states=new Map,t.states.forEach(r=>{this.states.set(r.name,new rJ(r.style,r.options&&r.options.params||{},i))}),q4(this.states,"true","1"),q4(this.states,"false","0"),t.transitions.forEach(r=>{this.transitionFactories.push(new $4(e,r,this.states))}),this.fallbackTransition=function aJ(n,e,t){return new $4(n,{type:1,animation:{type:2,steps:[],options:null},matchers:[(o,a)=>!0],options:null,queryCount:0,depCount:0},e)}(e,this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(e,t,i,r){return this.transitionFactories.find(o=>o.match(e,t,i,r))||null}matchStyles(e,t,i){return this.fallbackTransition.buildStyles(e,t,i)}}function q4(n,e,t){n.has(e)?n.has(t)||n.set(t,n.get(e)):n.has(t)&&n.set(e,n.get(t))}const cJ=new pS;class lJ{constructor(e,t,i){this.bodyNode=e,this._driver=t,this._normalizer=i,this._animations=new Map,this._playersById=new Map,this.players=[]}register(e,t){const i=[],r=[],s=_A(this._driver,t,i,r);if(i.length)throw function lZ(n){return new Ue(3503,!1)}();this._animations.set(e,s)}_buildPlayer(e,t,i){const r=e.element,s=M4(0,this._normalizer,0,e.keyframes,t,i);return this._driver.animate(r,s,e.duration,e.delay,e.easing,[],!0)}create(e,t,i={}){const r=[],s=this._animations.get(e);let o;const a=new Map;if(s?(o=bA(this._driver,t,s,hA,rS,new Map,new Map,i,cJ,r),o.forEach(p=>{const g=Qa(a,p.element,new Map);p.postStyleProps.forEach(v=>g.set(v,null))})):(r.push(function dZ(){return new Ue(3300,!1)}()),o=[]),r.length)throw function uZ(n){return new Ue(3504,!1)}();a.forEach((p,g)=>{p.forEach((v,y)=>{p.set(y,this._driver.computeStyle(g,y,Ud))})});const u=oh(o.map(p=>{const g=a.get(p.element);return this._buildPlayer(p,new Map,g)}));return this._playersById.set(e,u),u.onDestroy(()=>this.destroy(e)),this.players.push(u),u}destroy(e){const t=this._getPlayer(e);t.destroy(),this._playersById.delete(e);const i=this.players.indexOf(t);i>=0&&this.players.splice(i,1)}_getPlayer(e){const t=this._playersById.get(e);if(!t)throw function hZ(n){return new Ue(3301,!1)}();return t}listen(e,t,i,r){const s=cA(t,"","","");return oA(this._getPlayer(e),i,s,r),()=>{}}command(e,t,i,r){if("register"==i)return void this.register(e,r[0]);if("create"==i)return void this.create(e,t,r[0]||{});const s=this._getPlayer(e);switch(i){case"play":s.play();break;case"pause":s.pause();break;case"reset":s.reset();break;case"restart":s.restart();break;case"finish":s.finish();break;case"init":s.init();break;case"setPosition":s.setPosition(parseFloat(r[0]));break;case"destroy":this.destroy(e)}}}const K4="ng-animate-queued",EA="ng-animate-disabled",pJ=[],Y4={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},mJ={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},Oc="__ng_removed";class MA{get params(){return this.options.params}constructor(e,t=""){this.namespaceId=t;const i=e&&e.hasOwnProperty("value");if(this.value=function yJ(n){return n??null}(i?e.value:e),i){const s=ty(e);delete s.value,this.options=s}else this.options={};this.options.params||(this.options.params={})}absorbOptions(e){const t=e.params;if(t){const i=this.options.params;Object.keys(t).forEach(r=>{null==i[r]&&(i[r]=t[r])})}}}const ry="void",CA=new MA(ry);class gJ{constructor(e,t,i){this.id=e,this.hostElement=t,this._engine=i,this.players=[],this._triggers=new Map,this._queue=[],this._elementListeners=new Map,this._hostClassName="ng-tns-"+e,Lc(t,this._hostClassName)}listen(e,t,i,r){if(!this._triggers.has(t))throw function fZ(n,e){return new Ue(3302,!1)}();if(null==i||0==i.length)throw function pZ(n){return new Ue(3303,!1)}();if(!function bJ(n){return"start"==n||"done"==n}(i))throw function mZ(n,e){return new Ue(3400,!1)}();const s=Qa(this._elementListeners,e,[]),o={name:t,phase:i,callback:r};s.push(o);const a=Qa(this._engine.statesByElement,e,new Map);return a.has(t)||(Lc(e,sS),Lc(e,sS+"-"+t),a.set(t,CA)),()=>{this._engine.afterFlush(()=>{const c=s.indexOf(o);c>=0&&s.splice(c,1),this._triggers.has(t)||a.delete(t)})}}register(e,t){return!this._triggers.has(e)&&(this._triggers.set(e,t),!0)}_getTrigger(e){const t=this._triggers.get(e);if(!t)throw function gZ(n){return new Ue(3401,!1)}();return t}trigger(e,t,i,r=!0){const s=this._getTrigger(t),o=new DA(this.id,t,e);let a=this._engine.statesByElement.get(e);a||(Lc(e,sS),Lc(e,sS+"-"+t),this._engine.statesByElement.set(e,a=new Map));let c=a.get(t);const u=new MA(i,this.id);if(!(i&&i.hasOwnProperty("value"))&&c&&u.absorbOptions(c.options),a.set(t,u),c||(c=CA),u.value!==ry&&c.value===u.value){if(!function SJ(n,e){const t=Object.keys(n),i=Object.keys(e);if(t.length!=i.length)return!1;for(let r=0;r{Gf(e,N),Zl(e,k)})}return}const v=Qa(this._engine.playersByElement,e,[]);v.forEach(T=>{T.namespaceId==this.id&&T.triggerName==t&&T.queued&&T.destroy()});let y=s.matchTransition(c.value,u.value,e,u.params),x=!1;if(!y){if(!r)return;y=s.fallbackTransition,x=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:t,transition:y,fromState:c,toState:u,player:o,isFallbackTransition:x}),x||(Lc(e,K4),o.onStart(()=>{pg(e,K4)})),o.onDone(()=>{let T=this.players.indexOf(o);T>=0&&this.players.splice(T,1);const N=this._engine.playersByElement.get(e);if(N){let k=N.indexOf(o);k>=0&&N.splice(k,1)}}),this.players.push(o),v.push(o),o}deregister(e){this._triggers.delete(e),this._engine.statesByElement.forEach(t=>t.delete(e)),this._elementListeners.forEach((t,i)=>{this._elementListeners.set(i,t.filter(r=>r.name!=e))})}clearElementCache(e){this._engine.statesByElement.delete(e),this._elementListeners.delete(e);const t=this._engine.playersByElement.get(e);t&&(t.forEach(i=>i.destroy()),this._engine.playersByElement.delete(e))}_signalRemovalForInnerTriggers(e,t){const i=this._engine.driver.query(e,oS,!0);i.forEach(r=>{if(r[Oc])return;const s=this._engine.fetchNamespacesByElement(r);s.size?s.forEach(o=>o.triggerLeaveAnimation(r,t,!1,!0)):this.clearElementCache(r)}),this._engine.afterFlushAnimationsDone(()=>i.forEach(r=>this.clearElementCache(r)))}triggerLeaveAnimation(e,t,i,r){const s=this._engine.statesByElement.get(e),o=new Map;if(s){const a=[];if(s.forEach((c,u)=>{if(o.set(u,c.value),this._triggers.has(u)){const p=this.trigger(e,u,ry,r);p&&a.push(p)}}),a.length)return this._engine.markElementAsRemoved(this.id,e,!0,t,o),i&&oh(a).onDone(()=>this._engine.processLeaveNode(e)),!0}return!1}prepareLeaveAnimationListeners(e){const t=this._elementListeners.get(e),i=this._engine.statesByElement.get(e);if(t&&i){const r=new Set;t.forEach(s=>{const o=s.name;if(r.has(o))return;r.add(o);const c=this._triggers.get(o).fallbackTransition,u=i.get(o)||CA,p=new MA(ry),g=new DA(this.id,o,e);this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:o,transition:c,fromState:u,toState:p,player:g,isFallbackTransition:!0})})}}removeNode(e,t){const i=this._engine;if(e.childElementCount&&this._signalRemovalForInnerTriggers(e,t),this.triggerLeaveAnimation(e,t,!0))return;let r=!1;if(i.totalAnimations){const s=i.players.length?i.playersByQueriedElement.get(e):[];if(s&&s.length)r=!0;else{let o=e;for(;o=o.parentNode;)if(i.statesByElement.get(o)){r=!0;break}}}if(this.prepareLeaveAnimationListeners(e),r)i.markElementAsRemoved(this.id,e,!1,t);else{const s=e[Oc];(!s||s===Y4)&&(i.afterFlush(()=>this.clearElementCache(e)),i.destroyInnerAnimations(e),i._onRemovalComplete(e,t))}}insertNode(e,t){Lc(e,this._hostClassName)}drainQueuedTransitions(e){const t=[];return this._queue.forEach(i=>{const r=i.player;if(r.destroyed)return;const s=i.element,o=this._elementListeners.get(s);o&&o.forEach(a=>{if(a.name==i.triggerName){const c=cA(s,i.triggerName,i.fromState.value,i.toState.value);c._data=e,oA(i.player,a.phase,c,a.callback)}}),r.markedForDestroy?this._engine.afterFlush(()=>{r.destroy()}):t.push(i)}),this._queue=[],t.sort((i,r)=>{const s=i.transition.ast.depCount,o=r.transition.ast.depCount;return 0==s||0==o?s-o:this._engine.driver.containsElement(i.element,r.element)?1:-1})}destroy(e){this.players.forEach(t=>t.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,e)}elementContainsData(e){let t=!1;return this._elementListeners.has(e)&&(t=!0),t=!!this._queue.find(i=>i.element===e)||t,t}}class _J{_onRemovalComplete(e,t){this.onRemovalComplete(e,t)}constructor(e,t,i){this.bodyNode=e,this.driver=t,this._normalizer=i,this.players=[],this.newHostElements=new Map,this.playersByElement=new Map,this.playersByQueriedElement=new Map,this.statesByElement=new Map,this.disabledNodes=new Set,this.totalAnimations=0,this.totalQueuedPlayers=0,this._namespaceLookup={},this._namespaceList=[],this._flushFns=[],this._whenQuietFns=[],this.namespacesByHostElement=new Map,this.collectedEnterElements=[],this.collectedLeaveElements=[],this.onRemovalComplete=(r,s)=>{}}get queuedPlayers(){const e=[];return this._namespaceList.forEach(t=>{t.players.forEach(i=>{i.queued&&e.push(i)})}),e}createNamespace(e,t){const i=new gJ(e,t,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,t)?this._balanceNamespaceList(i,t):(this.newHostElements.set(t,i),this.collectEnterElement(t)),this._namespaceLookup[e]=i}_balanceNamespaceList(e,t){const i=this._namespaceList,r=this.namespacesByHostElement;if(i.length-1>=0){let o=!1,a=this.driver.getParentElement(t);for(;a;){const c=r.get(a);if(c){const u=i.indexOf(c);i.splice(u+1,0,e),o=!0;break}a=this.driver.getParentElement(a)}o||i.unshift(e)}else i.push(e);return r.set(t,e),e}register(e,t){let i=this._namespaceLookup[e];return i||(i=this.createNamespace(e,t)),i}registerTrigger(e,t,i){let r=this._namespaceLookup[e];r&&r.register(t,i)&&this.totalAnimations++}destroy(e,t){if(!e)return;const i=this._fetchNamespace(e);this.afterFlush(()=>{this.namespacesByHostElement.delete(i.hostElement),delete this._namespaceLookup[e];const r=this._namespaceList.indexOf(i);r>=0&&this._namespaceList.splice(r,1)}),this.afterFlushAnimationsDone(()=>i.destroy(t))}_fetchNamespace(e){return this._namespaceLookup[e]}fetchNamespacesByElement(e){const t=new Set,i=this.statesByElement.get(e);if(i)for(let r of i.values())if(r.namespaceId){const s=this._fetchNamespace(r.namespaceId);s&&t.add(s)}return t}trigger(e,t,i,r){if(_S(t)){const s=this._fetchNamespace(e);if(s)return s.trigger(t,i,r),!0}return!1}insertNode(e,t,i,r){if(!_S(t))return;const s=t[Oc];if(s&&s.setForRemoval){s.setForRemoval=!1,s.setForMove=!0;const o=this.collectedLeaveElements.indexOf(t);o>=0&&this.collectedLeaveElements.splice(o,1)}if(e){const o=this._fetchNamespace(e);o&&o.insertNode(t,i)}r&&this.collectEnterElement(t)}collectEnterElement(e){this.collectedEnterElements.push(e)}markElementAsDisabled(e,t){t?this.disabledNodes.has(e)||(this.disabledNodes.add(e),Lc(e,EA)):this.disabledNodes.has(e)&&(this.disabledNodes.delete(e),pg(e,EA))}removeNode(e,t,i,r){if(_S(t)){const s=e?this._fetchNamespace(e):null;if(s?s.removeNode(t,r):this.markElementAsRemoved(e,t,!1,r),i){const o=this.namespacesByHostElement.get(t);o&&o.id!==e&&o.removeNode(t,r)}}else this._onRemovalComplete(t,r)}markElementAsRemoved(e,t,i,r,s){this.collectedLeaveElements.push(t),t[Oc]={namespaceId:e,setForRemoval:r,hasAnimation:i,removedBeforeQueried:!1,previousTriggersValues:s}}listen(e,t,i,r,s){return _S(t)?this._fetchNamespace(e).listen(t,i,r,s):()=>{}}_buildInstruction(e,t,i,r,s){return e.transition.build(this.driver,e.element,e.fromState.value,e.toState.value,i,r,e.fromState.options,e.toState.options,t,s)}destroyInnerAnimations(e){let t=this.driver.query(e,oS,!0);t.forEach(i=>this.destroyActiveAnimationsForElement(i)),0!=this.playersByQueriedElement.size&&(t=this.driver.query(e,fA,!0),t.forEach(i=>this.finishActiveQueriedAnimationOnElement(i)))}destroyActiveAnimationsForElement(e){const t=this.playersByElement.get(e);t&&t.forEach(i=>{i.queued?i.markedForDestroy=!0:i.destroy()})}finishActiveQueriedAnimationOnElement(e){const t=this.playersByQueriedElement.get(e);t&&t.forEach(i=>i.finish())}whenRenderingDone(){return new Promise(e=>{if(this.players.length)return oh(this.players).onDone(()=>e());e()})}processLeaveNode(e){const t=e[Oc];if(t&&t.setForRemoval){if(e[Oc]=Y4,t.namespaceId){this.destroyInnerAnimations(e);const i=this._fetchNamespace(t.namespaceId);i&&i.clearElementCache(e)}this._onRemovalComplete(e,t.setForRemoval)}e.classList?.contains(EA)&&this.markElementAsDisabled(e,!1),this.driver.query(e,".ng-animate-disabled",!0).forEach(i=>{this.markElementAsDisabled(i,!1)})}flush(e=-1){let t=[];if(this.newHostElements.size&&(this.newHostElements.forEach((i,r)=>this._balanceNamespaceList(i,r)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let i=0;ii()),this._flushFns=[],this._whenQuietFns.length){const i=this._whenQuietFns;this._whenQuietFns=[],t.length?oh(t).onDone(()=>{i.forEach(r=>r())}):i.forEach(r=>r())}}reportError(e){throw function _Z(n){return new Ue(3402,!1)}()}_flushAnimations(e,t){const i=new pS,r=[],s=new Map,o=[],a=new Map,c=new Map,u=new Map,p=new Set;this.disabledNodes.forEach(ye=>{p.add(ye);const Me=this.driver.query(ye,".ng-animate-queued",!0);for(let je=0;je{const je=hA+T++;x.set(Me,je),ye.forEach(lt=>Lc(lt,je))});const N=[],k=new Set,A=new Set;for(let ye=0;yek.add(lt)):A.add(Me))}const H=new Map,G=J4(v,Array.from(k));G.forEach((ye,Me)=>{const je=rS+T++;H.set(Me,je),ye.forEach(lt=>Lc(lt,je))}),e.push(()=>{y.forEach((ye,Me)=>{const je=x.get(Me);ye.forEach(lt=>pg(lt,je))}),G.forEach((ye,Me)=>{const je=H.get(Me);ye.forEach(lt=>pg(lt,je))}),N.forEach(ye=>{this.processLeaveNode(ye)})});const X=[],se=[];for(let ye=this._namespaceList.length-1;ye>=0;ye--)this._namespaceList[ye].drainQueuedTransitions(t).forEach(je=>{const lt=je.player,ze=je.element;if(X.push(lt),this.collectedEnterElements.length){const Qt=ze[Oc];if(Qt&&Qt.setForMove){if(Qt.previousTriggersValues&&Qt.previousTriggersValues.has(je.triggerName)){const sn=Qt.previousTriggersValues.get(je.triggerName),It=this.statesByElement.get(je.element);if(It&&It.has(je.triggerName)){const on=It.get(je.triggerName);on.value=sn,It.set(je.triggerName,on)}}return void lt.destroy()}}const Ke=!g||!this.driver.containsElement(g,ze),vt=H.get(ze),yt=x.get(ze),gt=this._buildInstruction(je,i,yt,vt,Ke);if(gt.errors&>.errors.length)return void se.push(gt);if(Ke)return lt.onStart(()=>Gf(ze,gt.fromStyles)),lt.onDestroy(()=>Zl(ze,gt.toStyles)),void r.push(lt);if(je.isFallbackTransition)return lt.onStart(()=>Gf(ze,gt.fromStyles)),lt.onDestroy(()=>Zl(ze,gt.toStyles)),void r.push(lt);const mi=[];gt.timelines.forEach(Qt=>{Qt.stretchStartingKeyframe=!0,this.disabledNodes.has(Qt.element)||mi.push(Qt)}),gt.timelines=mi,i.append(ze,gt.timelines),o.push({instruction:gt,player:lt,element:ze}),gt.queriedElements.forEach(Qt=>Qa(a,Qt,[]).push(lt)),gt.preStyleProps.forEach((Qt,sn)=>{if(Qt.size){let It=c.get(sn);It||c.set(sn,It=new Set),Qt.forEach((on,gi)=>It.add(gi))}}),gt.postStyleProps.forEach((Qt,sn)=>{let It=u.get(sn);It||u.set(sn,It=new Set),Qt.forEach((on,gi)=>It.add(gi))})});if(se.length){const ye=[];se.forEach(Me=>{ye.push(function vZ(n,e){return new Ue(3505,!1)}())}),X.forEach(Me=>Me.destroy()),this.reportError(ye)}const K=new Map,he=new Map;o.forEach(ye=>{const Me=ye.element;i.has(Me)&&(he.set(Me,Me),this._beforeAnimationBuild(ye.player.namespaceId,ye.instruction,K))}),r.forEach(ye=>{const Me=ye.element;this._getPreviousPlayers(Me,!1,ye.namespaceId,ye.triggerName,null).forEach(lt=>{Qa(K,Me,[]).push(lt),lt.destroy()})});const De=N.filter(ye=>e5(ye,c,u)),Te=new Map;Z4(Te,this.driver,A,u,Ud).forEach(ye=>{e5(ye,c,u)&&De.push(ye)});const Qe=new Map;y.forEach((ye,Me)=>{Z4(Qe,this.driver,new Set(ye),c,nA)}),De.forEach(ye=>{const Me=Te.get(ye),je=Qe.get(ye);Te.set(ye,new Map([...Array.from(Me?.entries()??[]),...Array.from(je?.entries()??[])]))});const Pe=[],Oe=[],Ve={};o.forEach(ye=>{const{element:Me,player:je,instruction:lt}=ye;if(i.has(Me)){if(p.has(Me))return je.onDestroy(()=>Zl(Me,lt.toStyles)),je.disabled=!0,je.overrideTotalTime(lt.totalTime),void r.push(je);let ze=Ve;if(he.size>1){let vt=Me;const yt=[];for(;vt=vt.parentNode;){const gt=he.get(vt);if(gt){ze=gt;break}yt.push(vt)}yt.forEach(gt=>he.set(gt,ze))}const Ke=this._buildAnimation(je.namespaceId,lt,K,s,Qe,Te);if(je.setRealPlayer(Ke),ze===Ve)Pe.push(je);else{const vt=this.playersByElement.get(ze);vt&&vt.length&&(je.parentPlayer=oh(vt)),r.push(je)}}else Gf(Me,lt.fromStyles),je.onDestroy(()=>Zl(Me,lt.toStyles)),Oe.push(je),p.has(Me)&&r.push(je)}),Oe.forEach(ye=>{const Me=s.get(ye.element);if(Me&&Me.length){const je=oh(Me);ye.setRealPlayer(je)}}),r.forEach(ye=>{ye.parentPlayer?ye.syncPlayerEvents(ye.parentPlayer):ye.destroy()});for(let ye=0;ye!Ke.destroyed);ze.length?xJ(this,Me,ze):this.processLeaveNode(Me)}return N.length=0,Pe.forEach(ye=>{this.players.push(ye),ye.onDone(()=>{ye.destroy();const Me=this.players.indexOf(ye);this.players.splice(Me,1)}),ye.play()}),Pe}elementContainsData(e,t){let i=!1;const r=t[Oc];return r&&r.setForRemoval&&(i=!0),this.playersByElement.has(t)&&(i=!0),this.playersByQueriedElement.has(t)&&(i=!0),this.statesByElement.has(t)&&(i=!0),this._fetchNamespace(e).elementContainsData(t)||i}afterFlush(e){this._flushFns.push(e)}afterFlushAnimationsDone(e){this._whenQuietFns.push(e)}_getPreviousPlayers(e,t,i,r,s){let o=[];if(t){const a=this.playersByQueriedElement.get(e);a&&(o=a)}else{const a=this.playersByElement.get(e);if(a){const c=!s||s==ry;a.forEach(u=>{u.queued||!c&&u.triggerName!=r||o.push(u)})}}return(i||r)&&(o=o.filter(a=>!(i&&i!=a.namespaceId||r&&r!=a.triggerName))),o}_beforeAnimationBuild(e,t,i){const s=t.element,o=t.isRemovalTransition?void 0:e,a=t.isRemovalTransition?void 0:t.triggerName;for(const c of t.timelines){const u=c.element,p=u!==s,g=Qa(i,u,[]);this._getPreviousPlayers(u,p,o,a,t.toState).forEach(y=>{const x=y.getRealPlayer();x.beforeDestroy&&x.beforeDestroy(),y.destroy(),g.push(y)})}Gf(s,t.fromStyles)}_buildAnimation(e,t,i,r,s,o){const a=t.triggerName,c=t.element,u=[],p=new Set,g=new Set,v=t.timelines.map(x=>{const T=x.element;p.add(T);const N=T[Oc];if(N&&N.removedBeforeQueried)return new Qv(x.duration,x.delay);const k=T!==c,A=function wJ(n){const e=[];return Q4(n,e),e}((i.get(T)||pJ).map(K=>K.getRealPlayer())).filter(K=>!!K.element&&K.element===T),H=s.get(T),G=o.get(T),X=M4(0,this._normalizer,0,x.keyframes,H,G),se=this._buildPlayer(x,X,A);if(x.subTimeline&&r&&g.add(T),k){const K=new DA(e,a,T);K.setRealPlayer(se),u.push(K)}return se});u.forEach(x=>{Qa(this.playersByQueriedElement,x.element,[]).push(x),x.onDone(()=>function vJ(n,e,t){let i=n.get(e);if(i){if(i.length){const r=i.indexOf(t);i.splice(r,1)}0==i.length&&n.delete(e)}return i}(this.playersByQueriedElement,x.element,x))}),p.forEach(x=>Lc(x,P4));const y=oh(v);return y.onDestroy(()=>{p.forEach(x=>pg(x,P4)),Zl(c,t.toStyles)}),g.forEach(x=>{Qa(r,x,[]).push(y)}),y}_buildPlayer(e,t,i){return t.length>0?this.driver.animate(e.element,t,e.duration,e.delay,e.easing,i):new Qv(e.duration,e.delay)}}class DA{constructor(e,t,i){this.namespaceId=e,this.triggerName=t,this.element=i,this._player=new Qv,this._containsRealPlayer=!1,this._queuedCallbacks=new Map,this.destroyed=!1,this.markedForDestroy=!1,this.disabled=!1,this.queued=!0,this.totalTime=0}setRealPlayer(e){this._containsRealPlayer||(this._player=e,this._queuedCallbacks.forEach((t,i)=>{t.forEach(r=>oA(e,i,void 0,r))}),this._queuedCallbacks.clear(),this._containsRealPlayer=!0,this.overrideTotalTime(e.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(e){this.totalTime=e}syncPlayerEvents(e){const t=this._player;t.triggerCallback&&e.onStart(()=>t.triggerCallback("start")),e.onDone(()=>this.finish()),e.onDestroy(()=>this.destroy())}_queueEvent(e,t){Qa(this._queuedCallbacks,e,[]).push(t)}onDone(e){this.queued&&this._queueEvent("done",e),this._player.onDone(e)}onStart(e){this.queued&&this._queueEvent("start",e),this._player.onStart(e)}onDestroy(e){this.queued&&this._queueEvent("destroy",e),this._player.onDestroy(e)}init(){this._player.init()}hasStarted(){return!this.queued&&this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(e){this.queued||this._player.setPosition(e)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(e){const t=this._player;t.triggerCallback&&t.triggerCallback(e)}}function _S(n){return n&&1===n.nodeType}function X4(n,e){const t=n.style.display;return n.style.display=e??"none",t}function Z4(n,e,t,i,r){const s=[];t.forEach(c=>s.push(X4(c)));const o=[];i.forEach((c,u)=>{const p=new Map;c.forEach(g=>{const v=e.computeStyle(u,g,r);p.set(g,v),(!v||0==v.length)&&(u[Oc]=mJ,o.push(u))}),n.set(u,p)});let a=0;return t.forEach(c=>X4(c,s[a++])),o}function J4(n,e){const t=new Map;if(n.forEach(a=>t.set(a,[])),0==e.length)return t;const i=1,r=new Set(e),s=new Map;function o(a){if(!a)return i;let c=s.get(a);if(c)return c;const u=a.parentNode;return c=t.has(u)?u:r.has(u)?i:o(u),s.set(a,c),c}return e.forEach(a=>{const c=o(a);c!==i&&t.get(c).push(a)}),t}function Lc(n,e){n.classList?.add(e)}function pg(n,e){n.classList?.remove(e)}function xJ(n,e,t){oh(t).onDone(()=>n.processLeaveNode(e))}function Q4(n,e){for(let t=0;tr.add(s)):e.set(n,i),t.delete(n),!0}class vS{constructor(e,t,i){this.bodyNode=e,this._driver=t,this._normalizer=i,this._triggerCache={},this.onRemovalComplete=(r,s)=>{},this._transitionEngine=new _J(e,t,i),this._timelineEngine=new lJ(e,t,i),this._transitionEngine.onRemovalComplete=(r,s)=>this.onRemovalComplete(r,s)}registerTrigger(e,t,i,r,s){const o=e+"-"+r;let a=this._triggerCache[o];if(!a){const c=[],u=[],p=_A(this._driver,s,c,u);if(c.length)throw function aZ(n,e){return new Ue(3404,!1)}();a=function sJ(n,e,t){return new oJ(n,e,t)}(r,p,this._normalizer),this._triggerCache[o]=a}this._transitionEngine.registerTrigger(t,r,a)}register(e,t){this._transitionEngine.register(e,t)}destroy(e,t){this._transitionEngine.destroy(e,t)}onInsert(e,t,i,r){this._transitionEngine.insertNode(e,t,i,r)}onRemove(e,t,i,r){this._transitionEngine.removeNode(e,t,r||!1,i)}disableAnimations(e,t){this._transitionEngine.markElementAsDisabled(e,t)}process(e,t,i,r){if("@"==i.charAt(0)){const[s,o]=C4(i);this._timelineEngine.command(s,t,o,r)}else this._transitionEngine.trigger(e,t,i,r)}listen(e,t,i,r,s){if("@"==i.charAt(0)){const[o,a]=C4(i);return this._timelineEngine.listen(o,t,a,s)}return this._transitionEngine.listen(e,t,i,r,s)}flush(e=-1){this._transitionEngine.flush(e)}get players(){return this._transitionEngine.players.concat(this._timelineEngine.players)}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}}let MJ=(()=>{class n{constructor(t,i,r){this._element=t,this._startStyles=i,this._endStyles=r,this._state=0;let s=n.initialStylesByElement.get(t);s||n.initialStylesByElement.set(t,s=new Map),this._initialStyles=s}start(){this._state<1&&(this._startStyles&&Zl(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(Zl(this._element,this._initialStyles),this._endStyles&&(Zl(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(n.initialStylesByElement.delete(this._element),this._startStyles&&(Gf(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(Gf(this._element,this._endStyles),this._endStyles=null),Zl(this._element,this._initialStyles),this._state=3)}}return n.initialStylesByElement=new WeakMap,n})();function TA(n){let e=null;return n.forEach((t,i)=>{(function CJ(n){return"display"===n||"position"===n})(i)&&(e=e||new Map,e.set(i,t))}),e}class t5{constructor(e,t,i,r){this.element=e,this.keyframes=t,this.options=i,this._specialStyles=r,this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._initialized=!1,this._finished=!1,this._started=!1,this._destroyed=!1,this._originalOnDoneFns=[],this._originalOnStartFns=[],this.time=0,this.parentPlayer=null,this.currentSnapshot=new Map,this._duration=i.duration,this._delay=i.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this._buildPlayer(),this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return;this._initialized=!0;const e=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,e,this.options),this._finalKeyframe=e.length?e[e.length-1]:new Map,this.domPlayer.addEventListener("finish",()=>this._onFinish())}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}_convertKeyframesToObject(e){const t=[];return e.forEach(i=>{t.push(Object.fromEntries(i))}),t}_triggerWebAnimation(e,t,i){return e.animate(this._convertKeyframesToObject(t),i)}onStart(e){this._originalOnStartFns.push(e),this._onStartFns.push(e)}onDone(e){this._originalOnDoneFns.push(e),this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}play(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach(e=>e()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}pause(){this.init(),this.domPlayer.pause()}finish(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}_resetDomPlayerState(){this.domPlayer&&this.domPlayer.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}setPosition(e){void 0===this.domPlayer&&this.init(),this.domPlayer.currentTime=e*this.time}getPosition(){return this.domPlayer.currentTime/this.time}get totalTime(){return this._delay+this._duration}beforeDestroy(){const e=new Map;this.hasStarted()&&this._finalKeyframe.forEach((i,r)=>{"offset"!==r&&e.set(r,this._finished?i:H4(this.element,r))}),this.currentSnapshot=e}triggerCallback(e){const t="start"===e?this._onStartFns:this._onDoneFns;t.forEach(i=>i()),t.length=0}}class DJ{validateStyleProperty(e){return!0}validateAnimatableStyleProperty(e){return!0}matchesElement(e,t){return!1}containsElement(e,t){return k4(e,t)}getParentElement(e){return dA(e)}query(e,t,i){return I4(e,t,i)}computeStyle(e,t,i){return window.getComputedStyle(e)[t]}animate(e,t,i,r,s,o=[]){const c={duration:i,delay:r,fill:0==r?"both":"forwards"};s&&(c.easing=s);const u=new Map,p=o.filter(y=>y instanceof t5);(function IZ(n,e){return 0===n||0===e})(i,r)&&p.forEach(y=>{y.currentSnapshot.forEach((x,T)=>u.set(T,x))});let g=function DZ(n){return n.length?n[0]instanceof Map?n:n.map(e=>O4(e)):[]}(t).map(y=>ah(y));g=function FZ(n,e,t){if(t.size&&e.length){let i=e[0],r=[];if(t.forEach((s,o)=>{i.has(o)||r.push(o),i.set(o,s)}),r.length)for(let s=1;so.set(a,H4(n,a)))}}return e}(e,g,u);const v=function EJ(n,e){let t=null,i=null;return Array.isArray(e)&&e.length?(t=TA(e[0]),e.length>1&&(i=TA(e[e.length-1]))):e instanceof Map&&(t=TA(e)),t||i?new MJ(n,t,i):null}(e,g);return new t5(e,g,c,v)}}let TJ=(()=>{class n extends zN{constructor(t,i){super(),this._nextAnimationId=0,this._renderer=t.createRenderer(i.body,{id:"0",encapsulation:Ko.None,styles:[],data:{animation:[]}})}build(t){const i=this._nextAnimationId.toString();this._nextAnimationId++;const r=Array.isArray(t)?GN(t):t;return n5(this._renderer,null,i,"register",[r]),new AJ(i,this._renderer)}}return n.\u0275fac=function(t){return new(t||n)(xe(yn),xe(Mn))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class AJ extends $K{constructor(e,t){super(),this._id=e,this._renderer=t}create(e,t){return new kJ(this._id,e,t||{},this._renderer)}}class kJ{constructor(e,t,i,r){this.id=e,this.element=t,this._renderer=r,this.parentPlayer=null,this._started=!1,this.totalTime=0,this._command("create",i)}_listen(e,t){return this._renderer.listen(this.element,`@@${this.id}:${e}`,t)}_command(e,...t){return n5(this._renderer,this.element,this.id,e,t)}onDone(e){this._listen("done",e)}onStart(e){this._listen("start",e)}onDestroy(e){this._listen("destroy",e)}init(){this._command("init")}hasStarted(){return this._started}play(){this._command("play"),this._started=!0}pause(){this._command("pause")}restart(){this._command("restart")}finish(){this._command("finish")}destroy(){this._command("destroy")}reset(){this._command("reset"),this._started=!1}setPosition(e){this._command("setPosition",e)}getPosition(){return this._renderer.engine.players[+this.id]?.getPosition()??0}}function n5(n,e,t,i,r){return n.setProperty(e,`@@${t}:${i}`,r)}const i5="@.disabled";let IJ=(()=>{class n{constructor(t,i,r){this.delegate=t,this.engine=i,this._zone=r,this._currentId=0,this._microtaskId=1,this._animationCallbacksBuffer=[],this._rendererCache=new Map,this._cdRecurDepth=0,this.promise=Promise.resolve(0),i.onRemovalComplete=(s,o)=>{const a=o?.parentNode(s);a&&o.removeChild(a,s)}}createRenderer(t,i){const s=this.delegate.createRenderer(t,i);if(!(t&&i&&i.data&&i.data.animation)){let p=this._rendererCache.get(s);return p||(p=new r5("",s,this.engine,()=>this._rendererCache.delete(s)),this._rendererCache.set(s,p)),p}const o=i.id,a=i.id+"-"+this._currentId;this._currentId++,this.engine.register(a,t);const c=p=>{Array.isArray(p)?p.forEach(c):this.engine.registerTrigger(o,a,t,p.name,p)};return i.data.animation.forEach(c),new FJ(this,a,s,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){this.promise.then(()=>{this._microtaskId++})}scheduleListenerCallback(t,i,r){t>=0&&ti(r)):(0==this._animationCallbacksBuffer.length&&Promise.resolve(null).then(()=>{this._zone.run(()=>{this._animationCallbacksBuffer.forEach(s=>{const[o,a]=s;o(a)}),this._animationCallbacksBuffer=[]})}),this._animationCallbacksBuffer.push([i,r]))}end(){this._cdRecurDepth--,0==this._cdRecurDepth&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}}return n.\u0275fac=function(t){return new(t||n)(xe(yn),xe(vS),xe(Xt))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class r5{constructor(e,t,i,r){this.namespaceId=e,this.delegate=t,this.engine=i,this._onDestroy=r,this.destroyNode=this.delegate.destroyNode?s=>t.destroyNode(s):null}get data(){return this.delegate.data}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.delegate.destroy(),this._onDestroy?.()}createElement(e,t){return this.delegate.createElement(e,t)}createComment(e){return this.delegate.createComment(e)}createText(e){return this.delegate.createText(e)}appendChild(e,t){this.delegate.appendChild(e,t),this.engine.onInsert(this.namespaceId,t,e,!1)}insertBefore(e,t,i,r=!0){this.delegate.insertBefore(e,t,i),this.engine.onInsert(this.namespaceId,t,e,r)}removeChild(e,t,i){this.engine.onRemove(this.namespaceId,t,this.delegate,i)}selectRootElement(e,t){return this.delegate.selectRootElement(e,t)}parentNode(e){return this.delegate.parentNode(e)}nextSibling(e){return this.delegate.nextSibling(e)}setAttribute(e,t,i,r){this.delegate.setAttribute(e,t,i,r)}removeAttribute(e,t,i){this.delegate.removeAttribute(e,t,i)}addClass(e,t){this.delegate.addClass(e,t)}removeClass(e,t){this.delegate.removeClass(e,t)}setStyle(e,t,i,r){this.delegate.setStyle(e,t,i,r)}removeStyle(e,t,i){this.delegate.removeStyle(e,t,i)}setProperty(e,t,i){"@"==t.charAt(0)&&t==i5?this.disableAnimations(e,!!i):this.delegate.setProperty(e,t,i)}setValue(e,t){this.delegate.setValue(e,t)}listen(e,t,i){return this.delegate.listen(e,t,i)}disableAnimations(e,t){this.engine.disableAnimations(e,t)}}class FJ extends r5{constructor(e,t,i,r,s){super(t,i,r,s),this.factory=e,this.namespaceId=t}setProperty(e,t,i){"@"==t.charAt(0)?"."==t.charAt(1)&&t==i5?this.disableAnimations(e,i=void 0===i||!!i):this.engine.process(this.namespaceId,e,t.slice(1),i):this.delegate.setProperty(e,t,i)}listen(e,t,i){if("@"==t.charAt(0)){const r=function RJ(n){switch(n){case"body":return document.body;case"document":return document;case"window":return window;default:return n}}(e);let s=t.slice(1),o="";return"@"!=s.charAt(0)&&([s,o]=function PJ(n){const e=n.indexOf(".");return[n.substring(0,e),n.slice(e+1)]}(s)),this.engine.listen(this.namespaceId,r,s,o,a=>{this.factory.scheduleListenerCallback(a._data||-1,i,a)})}return this.delegate.listen(e,t,i)}}let OJ=(()=>{class n extends vS{constructor(t,i,r,s){super(t.body,i,r)}ngOnDestroy(){this.flush()}}return n.\u0275fac=function(t){return new(t||n)(xe(Mn),xe(uA),xe(wA),xe(Jm))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();const s5=[{provide:zN,useClass:TJ},{provide:wA,useFactory:function LJ(){return new tJ}},{provide:vS,useClass:OJ},{provide:yn,useFactory:function NJ(n,e,t){return new IJ(n,e,t)},deps:[cw,vS,Xt]}],AA=[{provide:uA,useFactory:()=>new DJ},{provide:bo,useValue:"BrowserAnimations"},...s5],o5=[{provide:uA,useClass:F4},{provide:bo,useValue:"NoopAnimations"},...s5];let BJ=(()=>{class n{static withConfig(t){return{ngModule:n,providers:t.disableAnimations?o5:AA}}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({providers:AA,imports:[nO]}),n})();function a5(n,e,t,i,r,s,o){try{var a=n[s](o),c=a.value}catch(u){return void t(u)}a.done?e(c):Promise.resolve(c).then(i,r)}function fl(n){return function(){var e=this,t=arguments;return new Promise(function(i,r){var s=n.apply(e,t);function o(c){a5(s,i,r,o,a,"next",c)}function a(c){a5(s,i,r,o,a,"throw",c)}o(void 0)})}}var kA=dt(2573);class HJ{call(e,t){return t.subscribe(new UJ(e))}}class UJ extends Fs{constructor(e){super(e),this.hasFirst=!1,this.observables=[],this.subscriptions=[]}_next(e){this.observables.push(e)}_complete(){const e=this.observables,t=e.length;if(0===t)this.destination.complete();else{for(let i=0;ir.lift(new zJ(i,e))}pl.completeNotification=new pl("C"),pl.undefinedValueNotification=new pl("N",void 0);class zJ{constructor(e,t){this.delay=e,this.scheduler=t}call(e,t){return t.subscribe(new FA(e,this.delay,this.scheduler))}}class FA extends di{constructor(e,t,i){super(e),this.delay=t,this.scheduler=i,this.queue=[],this.active=!1,this.errored=!1}static dispatch(e){const t=e.source,i=t.queue,r=e.scheduler,s=e.destination;for(;i.length>0&&i[0].time-r.now()<=0;)i.shift().notification.observe(s);if(i.length>0){const o=Math.max(0,i[0].time-r.now());this.schedule(e,o)}else this.unsubscribe(),t.active=!1}_schedule(e){this.active=!0,this.destination.add(e.schedule(FA.dispatch,this.delay,{source:this,destination:this.destination,scheduler:e}))}scheduleNotification(e){if(!0===this.errored)return;const t=this.scheduler,i=new GJ(t.now()+this.delay,e);this.queue.push(i),!1===this.active&&this._schedule(t)}_next(e){this.scheduleNotification(pl.createNext(e))}_error(e){this.errored=!0,this.queue=[],this.destination.error(e),this.unsubscribe()}_complete(){this.scheduleNotification(pl.createComplete()),this.unsubscribe()}}class GJ{constructor(e,t){this.time=e,this.notification=t}}const bS=(()=>{function n(){return Error.call(this),this.message="no elements in sequence",this.name="EmptyError",this}return n.prototype=Object.create(Error.prototype),n})();function xS(n=null){return e=>e.lift(new jJ(n))}class jJ{constructor(e){this.defaultValue=e}call(e,t){return t.subscribe(new WJ(e,this.defaultValue))}}class WJ extends di{constructor(e,t){super(e),this.defaultValue=t,this.isEmpty=!0}_next(e){this.isEmpty=!1,this.destination.next(e)}_complete(){this.isEmpty&&this.destination.next(this.defaultValue),this.destination.complete()}}function l5(n=KJ){return e=>e.lift(new $J(n))}class $J{constructor(e){this.errorFactory=e}call(e,t){return t.subscribe(new qJ(e,this.errorFactory))}}class qJ extends di{constructor(e,t){super(e),this.errorFactory=t,this.hasValue=!1}_next(e){this.hasValue=!0,this.destination.next(e)}_complete(){if(this.hasValue)return this.destination.complete();{let e;try{e=this.errorFactory()}catch(t){e=t}this.destination.error(e)}}}function KJ(){return new bS}function ml(n,e){const t=arguments.length>=2;return i=>i.pipe(n?Ui((r,s)=>n(r,s,i)):Is,Gr(1),t?xS(e):l5(()=>new bS))}const YJ=(()=>{function n(){return Error.call(this),this.message="Timeout has occurred",this.name="TimeoutError",this}return n.prototype=Object.create(Error.prototype),n})();class ZJ{constructor(e,t,i,r){this.waitFor=e,this.absoluteTimeout=t,this.withObservable=i,this.scheduler=r}call(e,t){return t.subscribe(new RA(e,this.absoluteTimeout,this.waitFor,this.withObservable,this.scheduler))}}class RA extends Fs{constructor(e,t,i,r,s){super(e),this.absoluteTimeout=t,this.waitFor=i,this.withObservable=r,this.scheduler=s,this.action=null,this.scheduleTimeout()}static dispatchTimeout(e){const{withObservable:t}=e;e._unsubscribeAndRecycle(),e.add($o(e,t))}scheduleTimeout(){const{action:e}=this;e?this.action=e.schedule(this,this.waitFor):this.add(this.action=this.scheduler.schedule(RA.dispatchTimeout,this.waitFor,this))}_next(e){this.absoluteTimeout||this.scheduleTimeout(),super._next(e)}_unsubscribe(){this.action=null,this.scheduler=null,this.withObservable=null}}class d5{validateSignature(e){return Promise.resolve(null)}validateAtHash(e){return Promise.resolve(!0)}}class u5{}class PA{}let QJ=(()=>{class n extends PA{now(){return Date.now()}new(){return new Date}}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class h5{}class OA{}let eQ=(()=>{class n{constructor(){this.data=new Map}getItem(t){return this.data.get(t)}removeItem(t){this.data.delete(t)}setItem(t,i){this.data.set(t,i)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class LA{constructor(e){this.type=e}}class tc extends LA{constructor(e,t=null){super(e),this.info=t}}class jd extends LA{constructor(e,t=null){super(e),this.info=t}}class cs extends LA{constructor(e,t,i=null){super(e),this.reason=t,this.params=i}}function f5(n){const e=n.replace(/\-/g,"+").replace(/\_/g,"/");return decodeURIComponent(atob(e).split("").map(function(t){return"%"+("00"+t.charCodeAt(0).toString(16)).slice(-2)}).join(""))}function NA(n){return btoa(n).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}class wS{constructor(e){this.clientId="",this.redirectUri="",this.postLogoutRedirectUri="",this.redirectUriAsPostLogoutRedirectUriFallback=!0,this.loginUrl="",this.scope="openid profile",this.resource="",this.rngUrl="",this.oidc=!0,this.requestAccessToken=!0,this.options=null,this.issuer="",this.logoutUrl="",this.clearHashAfterLogin=!0,this.tokenEndpoint=null,this.revocationEndpoint=null,this.customTokenParameters=[],this.userinfoEndpoint=null,this.responseType="",this.showDebugInformation=!1,this.silentRefreshRedirectUri="",this.silentRefreshMessagePrefix="",this.silentRefreshShowIFrame=!1,this.siletRefreshTimeout=2e4,this.silentRefreshTimeout=2e4,this.dummyClientSecret="",this.requireHttps="remoteOnly",this.strictDiscoveryDocumentValidation=!0,this.jwks=null,this.customQueryParams=null,this.silentRefreshIFrameName="angular-oauth-oidc-silent-refresh-iframe",this.timeoutFactor=.75,this.sessionChecksEnabled=!1,this.sessionCheckIntervall=3e3,this.sessionCheckIFrameUrl=null,this.sessionCheckIFrameName="angular-oauth-oidc-check-session-iframe",this.disableAtHashCheck=!1,this.skipSubjectCheck=!1,this.useIdTokenHintForSilentRefresh=!1,this.skipIssuerCheck=!1,this.nonceStateSeparator=";",this.useHttpBasicAuth=!1,this.decreaseExpirationBySec=0,this.waitForTokenInMsec=0,this.disablePKCE=!1,this.preserveRequestedRoute=!1,this.disableIdTokenTimer=!1,this.checkOrigin=!1,this.openUri=t=>{location.href=t},e&&Object.assign(this,e)}}class sy{encodeKey(e){return encodeURIComponent(e)}encodeValue(e){return encodeURIComponent(e)}decodeKey(e){return decodeURIComponent(e)}decodeValue(e){return decodeURIComponent(e)}}class p5{}class tQ{validateAtHash(e){var t=this;return fl(function*(){let i=t.inferHashAlgorithm(e.idTokenHeader),r=yield t.calcHash(e.accessToken,i),o=NA(r.substr(0,r.length/2)),a=e.idTokenClaims.at_hash.replace(/=/g,"");return o!==a&&(console.error("exptected at_hash: "+o),console.error("actual at_hash: "+a)),o===a})()}inferHashAlgorithm(e){let t=e.alg;if(!t.match(/^.S[0-9]{3}$/))throw new Error("Algorithm not supported: "+t);return"sha-"+t.substr(2)}}let m5=(()=>{class n{getHashFragmentParams(t){let i=t||window.location.hash;if(i=decodeURIComponent(i),0!==i.indexOf("#"))return{};const r=i.indexOf("?");return i=i.substr(r>-1?r+1:1),this.parseQueryString(i)}parseQueryString(t){const i={};let r,s,o,a,c,u,p;if(null===t)return i;r=t.split("&");for(let g=0;g=64;){for(s=e[0],o=e[1],a=e[2],c=e[3],u=e[4],p=e[5],g=e[6],v=e[7],x=0;x<16;x++)T=i+4*x,n[x]=(255&t[T])<<24|(255&t[T+1])<<16|(255&t[T+2])<<8|255&t[T+3];for(x=16;x<64;x++)y=n[x-2],N=(y>>>17|y<<15)^(y>>>19|y<<13)^y>>>10,y=n[x-15],k=(y>>>7|y<<25)^(y>>>18|y<<14)^y>>>3,n[x]=(N+n[x-7]|0)+(k+n[x-16]|0);for(x=0;x<64;x++)N=(((u>>>6|u<<26)^(u>>>11|u<<21)^(u>>>25|u<<7))+(u&p^~u&g)|0)+(v+(iQ[x]+n[x]|0)|0)|0,k=((s>>>2|s<<30)^(s>>>13|s<<19)^(s>>>22|s<<10))+(s&o^s&a^o&a)|0,v=g,g=p,p=u,u=c+N|0,c=a,a=o,o=s,s=N+k|0;e[0]+=s,e[1]+=o,e[2]+=a,e[3]+=c,e[4]+=u,e[5]+=p,e[6]+=g,e[7]+=v,i+=64,r-=64}return i}class SS{constructor(){this.digestLength=32,this.blockSize=64,this.state=new Int32Array(8),this.temp=new Int32Array(64),this.buffer=new Uint8Array(128),this.bufferLength=0,this.bytesHashed=0,this.finished=!1,this.reset()}reset(){return this.state[0]=1779033703,this.state[1]=3144134277,this.state[2]=1013904242,this.state[3]=2773480762,this.state[4]=1359893119,this.state[5]=2600822924,this.state[6]=528734635,this.state[7]=1541459225,this.bufferLength=0,this.bytesHashed=0,this.finished=!1,this}clean(){for(let e=0;e0){for(;this.bufferLength<64&&t>0;)this.buffer[this.bufferLength++]=e[i++],t--;64===this.bufferLength&&(BA(this.temp,this.state,this.buffer,0,64),this.bufferLength=0)}for(t>=64&&(i=BA(this.temp,this.state,e,i,t),t%=64);t>0;)this.buffer[this.bufferLength++]=e[i++],t--;return this}finish(e){if(!this.finished){const t=this.bytesHashed,i=this.bufferLength,r=t/536870912|0,s=t<<3,o=t%64<56?64:128;this.buffer[i]=128;for(let a=i+1;a>>24&255,this.buffer[o-7]=r>>>16&255,this.buffer[o-6]=r>>>8&255,this.buffer[o-5]=r>>>0&255,this.buffer[o-4]=s>>>24&255,this.buffer[o-3]=s>>>16&255,this.buffer[o-2]=s>>>8&255,this.buffer[o-1]=s>>>0&255,BA(this.temp,this.state,this.buffer,0,o),this.finished=!0}for(let t=0;t<8;t++)e[4*t+0]=this.state[t]>>>24&255,e[4*t+1]=this.state[t]>>>16&255,e[4*t+2]=this.state[t]>>>8&255,e[4*t+3]=this.state[t]>>>0&255;return this}digest(){const e=new Uint8Array(this.digestLength);return this.finish(e),e}_saveState(e){for(let t=0;t{class n{calcHash(t,i){return fl(function*(){return function lQ(n){var e,t=[];for(e=0;e{class n extends wS{constructor(t,i,r,s,o,a,c,u,p,g){super(),this.ngZone=t,this.http=i,this.config=o,this.urlHelper=a,this.logger=c,this.crypto=u,this.dateTimeService=g,this.discoveryDocumentLoaded=!1,this.state="",this.eventsSubject=new cn,this.discoveryDocumentLoadedSubject=new cn,this.grantTypesSupported=[],this.inImplicitFlow=!1,this.saveNoncesInLocalStorage=!1,this.debug("angular-oauth2-oidc v10"),this.document=p,o||(o={}),this.discoveryDocumentLoaded$=this.discoveryDocumentLoadedSubject.asObservable(),this.events=this.eventsSubject.asObservable(),s&&(this.tokenValidationHandler=s),o&&this.configure(o);try{r?this.setStorage(r):typeof sessionStorage<"u"&&this.setStorage(sessionStorage)}catch(v){console.error("No OAuthStorage provided and cannot access default (sessionStorage).Consider providing a custom OAuthStorage implementation in your module.",v)}if(this.checkLocalStorageAccessable()){const v=window?.navigator?.userAgent;(v?.includes("MSIE ")||v?.includes("Trident"))&&(this.saveNoncesInLocalStorage=!0)}this.setupRefreshTimer()}checkLocalStorageAccessable(){if(typeof window>"u")return!1;const t="test";try{return!(typeof window.localStorage>"u"||(localStorage.setItem(t,t),localStorage.removeItem(t),0))}catch{return!1}}configure(t){Object.assign(this,new wS,t),this.config=Object.assign({},new wS,t),this.sessionChecksEnabled&&this.setupSessionCheck(),this.configChanged()}configChanged(){this.setupRefreshTimer()}restartSessionChecksIfStillLoggedIn(){this.hasValidIdToken()&&this.initSessionCheck()}restartRefreshTimerIfStillLoggedIn(){this.setupExpirationTimers()}setupSessionCheck(){this.events.pipe(Ui(t=>"token_received"===t.type)).subscribe(t=>{this.initSessionCheck()})}setupAutomaticSilentRefresh(t={},i,r=!0){let s=!0;this.clearAutomaticRefreshTimer(),this.automaticRefreshSubscription=this.events.pipe(Dr(o=>{"token_received"===o.type?s=!0:"logout"===o.type&&(s=!1)}),Ui(o=>"token_expires"===o.type&&(null==i||"any"===i||o.info===i)),zv(1e3)).subscribe(o=>{s&&this.refreshInternal(t,r).catch(a=>{this.debug("Automatic silent refresh did not work")})}),this.restartRefreshTimerIfStillLoggedIn()}refreshInternal(t,i){return this.useSilentRefresh||"code"!==this.responseType?this.silentRefresh(t,i):this.refreshToken()}loadDiscoveryDocumentAndTryLogin(t=null){return this.loadDiscoveryDocument().then(i=>this.tryLogin(t))}loadDiscoveryDocumentAndLogin(t=null){return this.loadDiscoveryDocumentAndTryLogin(t=t||{}).then(i=>!(!this.hasValidIdToken()||!this.hasValidAccessToken())||(this.initLoginFlow("string"==typeof t.state?t.state:""),!1))}debug(...t){this.showDebugInformation&&this.logger.debug.apply(this.logger,t)}validateUrlFromDiscoveryDocument(t){const i=[],r=this.validateUrlForHttps(t),s=this.validateUrlAgainstIssuer(t);return r||i.push("https for all urls required. Also for urls received by discovery."),s||i.push("Every url in discovery document has to start with the issuer url.Also see property strictDiscoveryDocumentValidation."),i}validateUrlForHttps(t){if(!t)return!0;const i=t.toLowerCase();return!(!1!==this.requireHttps&&(!i.match(/^http:\/\/localhost($|[:\/])/)&&!i.match(/^http:\/\/localhost($|[:\/])/)||"remoteOnly"!==this.requireHttps))||i.startsWith("https://")}assertUrlNotNullAndCorrectProtocol(t,i){if(!t)throw new Error(`'${i}' should not be null`);if(!this.validateUrlForHttps(t))throw new Error(`'${i}' must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).`)}validateUrlAgainstIssuer(t){return!this.strictDiscoveryDocumentValidation||!t||t.toLowerCase().startsWith(this.issuer.toLowerCase())}setupRefreshTimer(){typeof window>"u"?this.debug("timer not supported on this plattform"):((this.hasValidIdToken()||this.hasValidAccessToken())&&(this.clearAccessTokenTimer(),this.clearIdTokenTimer(),this.setupExpirationTimers()),this.tokenReceivedSubscription&&this.tokenReceivedSubscription.unsubscribe(),this.tokenReceivedSubscription=this.events.pipe(Ui(t=>"token_received"===t.type)).subscribe(t=>{this.clearAccessTokenTimer(),this.clearIdTokenTimer(),this.setupExpirationTimers()}))}setupExpirationTimers(){this.hasValidAccessToken()&&this.setupAccessTokenTimer(),!this.disableIdTokenTimer&&this.hasValidIdToken()&&this.setupIdTokenTimer()}setupAccessTokenTimer(){const t=this.getAccessTokenExpiration(),i=this.getAccessTokenStoredAt(),r=this.calcTimeout(i,t);this.ngZone.runOutsideAngular(()=>{this.accessTokenTimeoutSubscription=Tt(new jd("token_expires","access_token")).pipe(IA(r)).subscribe(s=>{this.ngZone.run(()=>{this.eventsSubject.next(s)})})})}setupIdTokenTimer(){const t=this.getIdTokenExpiration(),i=this.getIdTokenStoredAt(),r=this.calcTimeout(i,t);this.ngZone.runOutsideAngular(()=>{this.idTokenTimeoutSubscription=Tt(new jd("token_expires","id_token")).pipe(IA(r)).subscribe(s=>{this.ngZone.run(()=>{this.eventsSubject.next(s)})})})}stopAutomaticRefresh(){this.clearAccessTokenTimer(),this.clearIdTokenTimer(),this.clearAutomaticRefreshTimer()}clearAccessTokenTimer(){this.accessTokenTimeoutSubscription&&this.accessTokenTimeoutSubscription.unsubscribe()}clearIdTokenTimer(){this.idTokenTimeoutSubscription&&this.idTokenTimeoutSubscription.unsubscribe()}clearAutomaticRefreshTimer(){this.automaticRefreshSubscription&&this.automaticRefreshSubscription.unsubscribe()}calcTimeout(t,i){const r=this.dateTimeService.now(),o=Math.max(0,(i-t)*this.timeoutFactor-(r-t)),a=2147483647;return o>a?a:o}setStorage(t){this._storage=t,this.configChanged()}loadDiscoveryDocument(t=null){return new Promise((i,r)=>{t||((t=this.issuer||"").endsWith("/")||(t+="/"),t+=".well-known/openid-configuration"),this.validateUrlForHttps(t)?this.http.get(t).subscribe(s=>{if(!this.validateDiscoveryDocument(s))return this.eventsSubject.next(new cs("discovery_document_validation_error",null)),void r("discovery_document_validation_error");this.loginUrl=s.authorization_endpoint,this.logoutUrl=s.end_session_endpoint||this.logoutUrl,this.grantTypesSupported=s.grant_types_supported,this.issuer=s.issuer,this.tokenEndpoint=s.token_endpoint,this.userinfoEndpoint=s.userinfo_endpoint||this.userinfoEndpoint,this.jwksUri=s.jwks_uri,this.sessionCheckIFrameUrl=s.check_session_iframe||this.sessionCheckIFrameUrl,this.discoveryDocumentLoaded=!0,this.discoveryDocumentLoadedSubject.next(s),this.revocationEndpoint=s.revocation_endpoint||this.revocationEndpoint,this.sessionChecksEnabled&&this.restartSessionChecksIfStillLoggedIn(),this.loadJwks().then(o=>{const c=new tc("discovery_document_loaded",{discoveryDocument:s,jwks:o});this.eventsSubject.next(c),i(c)}).catch(o=>{this.eventsSubject.next(new cs("discovery_document_load_error",o)),r(o)})},s=>{this.logger.error("error loading discovery document",s),this.eventsSubject.next(new cs("discovery_document_load_error",s)),r(s)}):r("issuer must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).")})}loadJwks(){return new Promise((t,i)=>{this.jwksUri?this.http.get(this.jwksUri).subscribe(r=>{this.jwks=r,t(r)},r=>{this.logger.error("error loading jwks",r),this.eventsSubject.next(new cs("jwks_load_error",r)),i(r)}):t(null)})}validateDiscoveryDocument(t){let i;return this.skipIssuerCheck||t.issuer===this.issuer?(i=this.validateUrlFromDiscoveryDocument(t.authorization_endpoint),i.length>0?(this.logger.error("error validating authorization_endpoint in discovery document",i),!1):(i=this.validateUrlFromDiscoveryDocument(t.end_session_endpoint),i.length>0?(this.logger.error("error validating end_session_endpoint in discovery document",i),!1):(i=this.validateUrlFromDiscoveryDocument(t.token_endpoint),i.length>0&&this.logger.error("error validating token_endpoint in discovery document",i),i=this.validateUrlFromDiscoveryDocument(t.revocation_endpoint),i.length>0&&this.logger.error("error validating revocation_endpoint in discovery document",i),i=this.validateUrlFromDiscoveryDocument(t.userinfo_endpoint),i.length>0?(this.logger.error("error validating userinfo_endpoint in discovery document",i),!1):(i=this.validateUrlFromDiscoveryDocument(t.jwks_uri),i.length>0?(this.logger.error("error validating jwks_uri in discovery document",i),!1):(this.sessionChecksEnabled&&!t.check_session_iframe&&this.logger.warn("sessionChecksEnabled is activated but discovery document does not contain a check_session_iframe field"),!0))))):(this.logger.error("invalid issuer in discovery document","expected: "+this.issuer,"current: "+t.issuer),!1)}fetchTokenUsingPasswordFlowAndLoadUserProfile(t,i,r=new Ho){return this.fetchTokenUsingPasswordFlow(t,i,r).then(()=>this.loadUserProfile())}loadUserProfile(){if(!this.hasValidAccessToken())throw new Error("Can not load User Profile without access_token");if(!this.validateUrlForHttps(this.userinfoEndpoint))throw new Error("userinfoEndpoint must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).");return new Promise((t,i)=>{const r=(new Ho).set("Authorization","Bearer "+this.getAccessToken());this.http.get(this.userinfoEndpoint,{headers:r,observe:"response",responseType:"text"}).subscribe(s=>{if(this.debug("userinfo received",JSON.stringify(s)),s.headers.get("content-type").startsWith("application/json")){let o=JSON.parse(s.body);const a=this.getIdentityClaims()||{};if(!this.skipSubjectCheck&&this.oidc&&(!a.sub||o.sub!==a.sub))return void i("if property oidc is true, the received user-id (sub) has to be the user-id of the user that has logged in with oidc.\nif you are not using oidc but just oauth2 password flow set oidc to false");o=Object.assign({},a,o),this._storage.setItem("id_token_claims_obj",JSON.stringify(o)),this.eventsSubject.next(new tc("user_profile_loaded")),t({info:o})}else this.debug("userinfo is not JSON, treating it as JWE/JWS"),this.eventsSubject.next(new tc("user_profile_loaded")),t(JSON.parse(s.body))},s=>{this.logger.error("error loading user info",s),this.eventsSubject.next(new cs("user_profile_load_error",s)),i(s)})})}fetchTokenUsingPasswordFlow(t,i,r=new Ho){return this.fetchTokenUsingGrant("password",{username:t,password:i},r)}fetchTokenUsingGrant(t,i,r=new Ho){this.assertUrlNotNullAndCorrectProtocol(this.tokenEndpoint,"tokenEndpoint");let s=new Za({encoder:new sy}).set("grant_type",t).set("scope",this.scope);if(this.useHttpBasicAuth){const o=btoa(`${this.clientId}:${this.dummyClientSecret}`);r=r.set("Authorization","Basic "+o)}if(this.useHttpBasicAuth||(s=s.set("client_id",this.clientId)),!this.useHttpBasicAuth&&this.dummyClientSecret&&(s=s.set("client_secret",this.dummyClientSecret)),this.customQueryParams)for(const o of Object.getOwnPropertyNames(this.customQueryParams))s=s.set(o,this.customQueryParams[o]);for(const o of Object.keys(i))s=s.set(o,i[o]);return r=r.set("Content-Type","application/x-www-form-urlencoded"),new Promise((o,a)=>{this.http.post(this.tokenEndpoint,s,{headers:r}).subscribe(c=>{this.debug("tokenResponse",c),this.storeAccessTokenResponse(c.access_token,c.refresh_token,c.expires_in||this.fallbackAccessTokenExpirationTimeInSec,c.scope,this.extractRecognizedCustomParameters(c)),this.oidc&&c.id_token&&this.processIdToken(c.id_token,c.access_token).then(u=>{this.storeIdToken(u),o(c)}),this.eventsSubject.next(new tc("token_received")),o(c)},c=>{this.logger.error("Error performing ${grantType} flow",c),this.eventsSubject.next(new cs("token_error",c)),a(c)})})}refreshToken(){return this.assertUrlNotNullAndCorrectProtocol(this.tokenEndpoint,"tokenEndpoint"),new Promise((t,i)=>{let r=new Za({encoder:new sy}).set("grant_type","refresh_token").set("scope",this.scope).set("refresh_token",this._storage.getItem("refresh_token")),s=(new Ho).set("Content-Type","application/x-www-form-urlencoded");if(this.useHttpBasicAuth){const o=btoa(`${this.clientId}:${this.dummyClientSecret}`);s=s.set("Authorization","Basic "+o)}if(this.useHttpBasicAuth||(r=r.set("client_id",this.clientId)),!this.useHttpBasicAuth&&this.dummyClientSecret&&(r=r.set("client_secret",this.dummyClientSecret)),this.customQueryParams)for(const o of Object.getOwnPropertyNames(this.customQueryParams))r=r.set(o,this.customQueryParams[o]);this.http.post(this.tokenEndpoint,r,{headers:s}).pipe(wo(o=>this.oidc&&o.id_token?dr(this.processIdToken(o.id_token,o.access_token,!0)).pipe(Dr(a=>this.storeIdToken(a)),_t(a=>o)):Tt(o))).subscribe(o=>{this.debug("refresh tokenResponse",o),this.storeAccessTokenResponse(o.access_token,o.refresh_token,o.expires_in||this.fallbackAccessTokenExpirationTimeInSec,o.scope,this.extractRecognizedCustomParameters(o)),this.eventsSubject.next(new tc("token_received")),this.eventsSubject.next(new tc("token_refreshed")),t(o)},o=>{this.logger.error("Error refreshing token",o),this.eventsSubject.next(new cs("token_refresh_error",o)),i(o)})})}removeSilentRefreshEventListener(){this.silentRefreshPostMessageEventListener&&(window.removeEventListener("message",this.silentRefreshPostMessageEventListener),this.silentRefreshPostMessageEventListener=null)}setupSilentRefreshEventListener(){this.removeSilentRefreshEventListener(),this.silentRefreshPostMessageEventListener=t=>{const i=this.processMessageEventMessage(t);this.checkOrigin&&t.origin!==location.origin&&console.error("wrong origin requested silent refresh!"),this.tryLogin({customHashFragment:i,preventClearHashAfterLogin:!0,customRedirectUri:this.silentRefreshRedirectUri||this.redirectUri}).catch(r=>this.debug("tryLogin during silent refresh failed",r))},window.addEventListener("message",this.silentRefreshPostMessageEventListener)}silentRefresh(t={},i=!0){const r=this.getIdentityClaims()||{};if(this.useIdTokenHintForSilentRefresh&&this.hasValidIdToken()&&(t.id_token_hint=this.getIdToken()),!this.validateUrlForHttps(this.loginUrl))throw new Error("loginUrl must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).");if(typeof this.document>"u")throw new Error("silent refresh is not supported on this platform");const s=this.document.getElementById(this.silentRefreshIFrameName);s&&this.document.body.removeChild(s),this.silentRefreshSubject=r.sub;const o=this.document.createElement("iframe");return o.id=this.silentRefreshIFrameName,this.setupSilentRefreshEventListener(),this.createLoginUrl(null,null,this.silentRefreshRedirectUri||this.redirectUri,i,t).then(g=>{o.setAttribute("src",g),this.silentRefreshShowIFrame||(o.style.display="none"),this.document.body.appendChild(o)}),function VJ(...n){if(1===n.length){if(!_i(n[0]))return n[0];n=n[0]}return uc(n,void 0).lift(new HJ)}([this.events.pipe(Ui(g=>g instanceof cs),ml()),this.events.pipe(Ui(g=>"token_received"===g.type),ml()),Tt(new cs("silent_refresh_timeout",null)).pipe(IA(this.silentRefreshTimeout))]).pipe(_t(g=>{if(g instanceof cs)throw"silent_refresh_timeout"===g.type||(g=new cs("silent_refresh_error",g)),this.eventsSubject.next(g),g;return"token_received"===g.type&&(g=new tc("silently_refreshed"),this.eventsSubject.next(g)),g})).toPromise()}initImplicitFlowInPopup(t){return this.initLoginFlowInPopup(t)}initLoginFlowInPopup(t){return t=t||{},this.createLoginUrl(null,null,this.silentRefreshRedirectUri,!1,{display:"popup"}).then(i=>new Promise((r,s)=>{let c,a=null;t.windowRef?t.windowRef&&!t.windowRef.closed&&(a=t.windowRef,a.location.href=i):a=window.open(i,"ngx-oauth2-oidc-login",this.calculatePopupFeatures(t));const u=x=>{this.tryLogin({customHashFragment:x,preventClearHashAfterLogin:!0,customRedirectUri:this.silentRefreshRedirectUri}).then(()=>{g(),r(!0)},T=>{g(),s(T)})};a?c=window.setInterval(()=>{(!a||a.closed)&&(g(),s(new cs("popup_closed",{})))},500):s(new cs("popup_blocked",{}));const g=()=>{window.clearInterval(c),window.removeEventListener("storage",y),window.removeEventListener("message",v),null!==a&&a.close(),a=null},v=x=>{const T=this.processMessageEventMessage(x);T&&null!==T?(window.removeEventListener("storage",y),u(T)):console.log("false event firing")},y=x=>{"auth_hash"===x.key&&(window.removeEventListener("message",v),u(x.newValue))};window.addEventListener("message",v),window.addEventListener("storage",y)}))}calculatePopupFeatures(t){const i=t.height||470,r=t.width||500,s=window.screenLeft+(window.outerWidth-r)/2;return`location=no,toolbar=no,width=${r},height=${i},top=${window.screenTop+(window.outerHeight-i)/2},left=${s}`}processMessageEventMessage(t){let i="#";if(this.silentRefreshMessagePrefix&&(i+=this.silentRefreshMessagePrefix),!t||!t.data||"string"!=typeof t.data)return;const r=t.data;return r.startsWith(i)?"#"+r.substr(i.length):void 0}canPerformSessionCheck(){return!(!this.sessionChecksEnabled||(this.sessionCheckIFrameUrl?this.getSessionState()?typeof this.document>"u":(console.warn("sessionChecksEnabled is activated but there is no session_state"),1):(console.warn("sessionChecksEnabled is activated but there is no sessionCheckIFrameUrl"),1)))}setupSessionCheckEventListener(){this.removeSessionCheckEventListener(),this.sessionCheckEventListener=t=>{const i=t.origin.toLowerCase(),r=this.issuer.toLowerCase();if(this.debug("sessionCheckEventListener"),r.startsWith(i)){switch(t.data){case"unchanged":this.ngZone.run(()=>{this.handleSessionUnchanged()});break;case"changed":this.ngZone.run(()=>{this.handleSessionChange()});break;case"error":this.ngZone.run(()=>{this.handleSessionError()})}this.debug("got info from session check inframe",t)}else this.debug("sessionCheckEventListener","wrong origin",i,"expected",r,"event",t)},this.ngZone.runOutsideAngular(()=>{window.addEventListener("message",this.sessionCheckEventListener)})}handleSessionUnchanged(){this.debug("session check","session unchanged"),this.eventsSubject.next(new jd("session_unchanged"))}handleSessionChange(){this.eventsSubject.next(new jd("session_changed")),this.stopSessionCheckTimer(),this.useSilentRefresh||"code"!==this.responseType?this.silentRefreshRedirectUri?(this.silentRefresh().catch(t=>this.debug("silent refresh failed after session changed")),this.waitForSilentRefreshAfterSessionChange()):(this.eventsSubject.next(new jd("session_terminated")),this.logOut(!0)):this.refreshToken().then(t=>{this.debug("token refresh after session change worked")}).catch(t=>{this.debug("token refresh did not work after session changed"),this.eventsSubject.next(new jd("session_terminated")),this.logOut(!0)})}waitForSilentRefreshAfterSessionChange(){this.events.pipe(Ui(t=>"silently_refreshed"===t.type||"silent_refresh_timeout"===t.type||"silent_refresh_error"===t.type),ml()).subscribe(t=>{"silently_refreshed"!==t.type&&(this.debug("silent refresh did not work after session changed"),this.eventsSubject.next(new jd("session_terminated")),this.logOut(!0))})}handleSessionError(){this.stopSessionCheckTimer(),this.eventsSubject.next(new jd("session_error"))}removeSessionCheckEventListener(){this.sessionCheckEventListener&&(window.removeEventListener("message",this.sessionCheckEventListener),this.sessionCheckEventListener=null)}initSessionCheck(){if(!this.canPerformSessionCheck())return;const t=this.document.getElementById(this.sessionCheckIFrameName);t&&this.document.body.removeChild(t);const i=this.document.createElement("iframe");i.id=this.sessionCheckIFrameName,this.setupSessionCheckEventListener(),i.setAttribute("src",this.sessionCheckIFrameUrl),i.style.display="none",this.document.body.appendChild(i),this.startSessionCheckTimer()}startSessionCheckTimer(){this.stopSessionCheckTimer(),this.ngZone.runOutsideAngular(()=>{this.sessionCheckTimer=setInterval(this.checkSession.bind(this),this.sessionCheckIntervall)})}stopSessionCheckTimer(){this.sessionCheckTimer&&(clearInterval(this.sessionCheckTimer),this.sessionCheckTimer=null)}checkSession(){const t=this.document.getElementById(this.sessionCheckIFrameName);t||this.logger.warn("checkSession did not find iframe",this.sessionCheckIFrameName);const i=this.getSessionState();i||this.stopSessionCheckTimer(),t.contentWindow.postMessage(this.clientId+" "+i,this.issuer)}createLoginUrl(t="",i="",r="",s=!1,o={}){var a=this;return fl(function*(){const c=a;let u;u=r||a.redirectUri;const p=yield a.createAndSaveNonce();if(t=t?p+a.config.nonceStateSeparator+encodeURIComponent(t):p,!a.requestAccessToken&&!a.oidc)throw new Error("Either requestAccessToken or oidc or both must be true");a.responseType=a.config.responseType?a.config.responseType:a.oidc&&a.requestAccessToken?"id_token token":a.oidc&&!a.requestAccessToken?"id_token":"token";const g=c.loginUrl.indexOf("?")>-1?"&":"?";let v=c.scope;a.oidc&&!v.match(/(^|\s)openid($|\s)/)&&(v="openid "+v);let y=c.loginUrl+g+"response_type="+encodeURIComponent(c.responseType)+"&client_id="+encodeURIComponent(c.clientId)+"&state="+encodeURIComponent(t)+"&redirect_uri="+encodeURIComponent(u)+"&scope="+encodeURIComponent(v);if(a.responseType.includes("code")&&!a.disablePKCE){const[x,T]=yield a.createChallangeVerifierPairForPKCE();a.saveNoncesInLocalStorage&&typeof window.localStorage<"u"?localStorage.setItem("PKCE_verifier",T):a._storage.setItem("PKCE_verifier",T),y+="&code_challenge="+x,y+="&code_challenge_method=S256"}i&&(y+="&login_hint="+encodeURIComponent(i)),c.resource&&(y+="&resource="+encodeURIComponent(c.resource)),c.oidc&&(y+="&nonce="+encodeURIComponent(p)),s&&(y+="&prompt=none");for(const x of Object.keys(o))y+="&"+encodeURIComponent(x)+"="+encodeURIComponent(o[x]);if(a.customQueryParams)for(const x of Object.getOwnPropertyNames(a.customQueryParams))y+="&"+x+"="+encodeURIComponent(a.customQueryParams[x]);return y})()}initImplicitFlowInternal(t="",i=""){if(this.inImplicitFlow)return;if(this.inImplicitFlow=!0,!this.validateUrlForHttps(this.loginUrl))throw new Error("loginUrl must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).");let r={},s=null;"string"==typeof i?s=i:"object"==typeof i&&(r=i),this.createLoginUrl(t,s,null,!1,r).then(this.config.openUri).catch(o=>{console.error("Error in initImplicitFlow",o),this.inImplicitFlow=!1})}initImplicitFlow(t="",i=""){""!==this.loginUrl?this.initImplicitFlowInternal(t,i):this.events.pipe(Ui(r=>"discovery_document_loaded"===r.type)).subscribe(r=>this.initImplicitFlowInternal(t,i))}resetImplicitFlow(){this.inImplicitFlow=!1}callOnTokenReceivedIfExists(t){const i=this;if(t.onTokenReceived){const r={idClaims:i.getIdentityClaims(),idToken:i.getIdToken(),accessToken:i.getAccessToken(),state:i.state};t.onTokenReceived(r)}}storeAccessTokenResponse(t,i,r,s,o){if(this._storage.setItem("access_token",t),s&&!Array.isArray(s)?this._storage.setItem("granted_scopes",JSON.stringify(s.split(" "))):s&&Array.isArray(s)&&this._storage.setItem("granted_scopes",JSON.stringify(s)),this._storage.setItem("access_token_stored_at",""+this.dateTimeService.now()),r){const a=1e3*r,u=this.dateTimeService.new().getTime()+a;this._storage.setItem("expires_at",""+u)}i&&this._storage.setItem("refresh_token",i),o&&o.forEach((a,c)=>{this._storage.setItem(c,a)})}tryLogin(t=null){return"code"===this.config.responseType?this.tryLoginCodeFlow(t).then(i=>!0):this.tryLoginImplicitFlow(t)}parseQueryString(t){return t&&0!==t.length?("?"===t.charAt(0)&&(t=t.substr(1)),this.urlHelper.parseQueryString(t)):{}}tryLoginCodeFlow(t=null){var i=this;return fl(function*(){const r=(t=t||{}).customHashFragment?t.customHashFragment.substring(1):window.location.search,s=i.getCodePartsFromUrl(r),o=s.code,a=s.state,c=s.session_state;if(!t.preventClearHashAfterLogin){const g=location.origin+location.pathname+location.search.replace(/code=[^&\$]*/,"").replace(/scope=[^&\$]*/,"").replace(/state=[^&\$]*/,"").replace(/session_state=[^&\$]*/,"").replace(/^\?&/,"?").replace(/&$/,"").replace(/^\?$/,"").replace(/&+/g,"&").replace(/\?&/,"?").replace(/\?$/,"")+location.hash;history.replaceState(null,window.name,g)}let[u,p]=i.parseState(a);if(i.state=p,s.error){i.debug("error trying to login"),i.handleLoginError(t,s);const g=new cs("code_error",{},s);return i.eventsSubject.next(g),Promise.reject(g)}if(!t.disableNonceCheck){if(!u)return i.saveRequestedRoute(),Promise.resolve();if(!t.disableOAuth2StateCheck&&!i.validateNonce(u)){const v=new cs("invalid_nonce_in_state",null);return i.eventsSubject.next(v),Promise.reject(v)}}return i.storeSessionState(c),o&&(yield i.getTokenFromCode(o,t),i.restoreRequestedRoute()),Promise.resolve()})()}saveRequestedRoute(){this.config.preserveRequestedRoute&&this._storage.setItem("requested_route",window.location.pathname+window.location.search)}restoreRequestedRoute(){const t=this._storage.getItem("requested_route");t&&history.replaceState(null,"",window.location.origin+t)}getCodePartsFromUrl(t){return t&&0!==t.length?("?"===t.charAt(0)&&(t=t.substr(1)),this.urlHelper.parseQueryString(t)):this.urlHelper.getHashFragmentParams()}getTokenFromCode(t,i){let r=new Za({encoder:new sy}).set("grant_type","authorization_code").set("code",t).set("redirect_uri",i.customRedirectUri||this.redirectUri);if(!this.disablePKCE){let s;s=this.saveNoncesInLocalStorage&&typeof window.localStorage<"u"?localStorage.getItem("PKCE_verifier"):this._storage.getItem("PKCE_verifier"),s?r=r.set("code_verifier",s):console.warn("No PKCE verifier found in oauth storage!")}return this.fetchAndProcessToken(r,i)}fetchAndProcessToken(t,i){i=i||{},this.assertUrlNotNullAndCorrectProtocol(this.tokenEndpoint,"tokenEndpoint");let r=(new Ho).set("Content-Type","application/x-www-form-urlencoded");if(this.useHttpBasicAuth){const s=btoa(`${this.clientId}:${this.dummyClientSecret}`);r=r.set("Authorization","Basic "+s)}return this.useHttpBasicAuth||(t=t.set("client_id",this.clientId)),!this.useHttpBasicAuth&&this.dummyClientSecret&&(t=t.set("client_secret",this.dummyClientSecret)),new Promise((s,o)=>{if(this.customQueryParams)for(let a of Object.getOwnPropertyNames(this.customQueryParams))t=t.set(a,this.customQueryParams[a]);this.http.post(this.tokenEndpoint,t,{headers:r}).subscribe(a=>{this.debug("refresh tokenResponse",a),this.storeAccessTokenResponse(a.access_token,a.refresh_token,a.expires_in||this.fallbackAccessTokenExpirationTimeInSec,a.scope,this.extractRecognizedCustomParameters(a)),this.oidc&&a.id_token?this.processIdToken(a.id_token,a.access_token,i.disableNonceCheck).then(c=>{this.storeIdToken(c),this.eventsSubject.next(new tc("token_received")),this.eventsSubject.next(new tc("token_refreshed")),s(a)}).catch(c=>{this.eventsSubject.next(new cs("token_validation_error",c)),console.error("Error validating tokens"),console.error(c),o(c)}):(this.eventsSubject.next(new tc("token_received")),this.eventsSubject.next(new tc("token_refreshed")),s(a))},a=>{console.error("Error getting token",a),this.eventsSubject.next(new cs("token_refresh_error",a)),o(a)})})}tryLoginImplicitFlow(t=null){let i;i=(t=t||{}).customHashFragment?this.urlHelper.getHashFragmentParams(t.customHashFragment):this.urlHelper.getHashFragmentParams(),this.debug("parsed url",i);const r=i.state;let[s,o]=this.parseState(r);if(this.state=o,i.error){this.debug("error trying to login"),this.handleLoginError(t,i);const g=new cs("token_error",{},i);return this.eventsSubject.next(g),Promise.reject(g)}const a=i.access_token,c=i.id_token,u=i.session_state,p=i.scope;if(!this.requestAccessToken&&!this.oidc)return Promise.reject("Either requestAccessToken or oidc (or both) must be true.");if(this.requestAccessToken&&!a||this.requestAccessToken&&!t.disableOAuth2StateCheck&&!r||this.oidc&&!c)return Promise.resolve(!1);if(this.sessionChecksEnabled&&!u&&this.logger.warn("session checks (Session Status Change Notification) were activated in the configuration but the id_token does not contain a session_state claim"),this.requestAccessToken&&!t.disableNonceCheck&&!this.validateNonce(s)){const v=new cs("invalid_nonce_in_state",null);return this.eventsSubject.next(v),Promise.reject(v)}return this.requestAccessToken&&this.storeAccessTokenResponse(a,null,i.expires_in||this.fallbackAccessTokenExpirationTimeInSec,p),this.oidc?this.processIdToken(c,a,t.disableNonceCheck).then(g=>t.validationHandler?t.validationHandler({accessToken:a,idClaims:g.idTokenClaims,idToken:g.idToken,state:r}).then(v=>g):g).then(g=>(this.storeIdToken(g),this.storeSessionState(u),this.clearHashAfterLogin&&!t.preventClearHashAfterLogin&&this.clearLocationHash(),this.eventsSubject.next(new tc("token_received")),this.callOnTokenReceivedIfExists(t),this.inImplicitFlow=!1,!0)).catch(g=>(this.eventsSubject.next(new cs("token_validation_error",g)),this.logger.error("Error validating tokens"),this.logger.error(g),Promise.reject(g))):(this.eventsSubject.next(new tc("token_received")),this.clearHashAfterLogin&&!t.preventClearHashAfterLogin&&this.clearLocationHash(),this.callOnTokenReceivedIfExists(t),Promise.resolve(!0))}parseState(t){let i=t,r="";if(t){const s=t.indexOf(this.config.nonceStateSeparator);s>-1&&(i=t.substr(0,s),r=t.substr(s+this.config.nonceStateSeparator.length))}return[i,r]}validateNonce(t){let i;return i=this.saveNoncesInLocalStorage&&typeof window.localStorage<"u"?localStorage.getItem("nonce"):this._storage.getItem("nonce"),i===t||(console.error("Validating access_token failed, wrong state/nonce.",i,t),!1)}storeIdToken(t){this._storage.setItem("id_token",t.idToken),this._storage.setItem("id_token_claims_obj",t.idTokenClaimsJson),this._storage.setItem("id_token_expires_at",""+t.idTokenExpiresAt),this._storage.setItem("id_token_stored_at",""+this.dateTimeService.now())}storeSessionState(t){this._storage.setItem("session_state",t)}getSessionState(){return this._storage.getItem("session_state")}handleLoginError(t,i){t.onLoginError&&t.onLoginError(i),this.clearHashAfterLogin&&!t.preventClearHashAfterLogin&&this.clearLocationHash()}getClockSkewInMsec(t=6e5){return this.clockSkewInSec||0===this.clockSkewInSec?1e3*this.clockSkewInSec:t}processIdToken(t,i,r=!1){const s=t.split("."),a=f5(this.padBase64(s[0])),c=JSON.parse(a),p=f5(this.padBase64(s[1])),g=JSON.parse(p);let v;if(v=this.saveNoncesInLocalStorage&&typeof window.localStorage<"u"?localStorage.getItem("nonce"):this._storage.getItem("nonce"),Array.isArray(g.aud)){if(g.aud.every(A=>A!==this.clientId)){const A="Wrong audience: "+g.aud.join(",");return this.logger.warn(A),Promise.reject(A)}}else if(g.aud!==this.clientId){const A="Wrong audience: "+g.aud;return this.logger.warn(A),Promise.reject(A)}if(!g.sub){const A="No sub claim in id_token";return this.logger.warn(A),Promise.reject(A)}if(this.sessionChecksEnabled&&this.silentRefreshSubject&&this.silentRefreshSubject!==g.sub){const A=`After refreshing, we got an id_token for another user (sub). Expected sub: ${this.silentRefreshSubject}, received sub: ${g.sub}`;return this.logger.warn(A),Promise.reject(A)}if(!g.iat){const A="No iat claim in id_token";return this.logger.warn(A),Promise.reject(A)}if(!this.skipIssuerCheck&&g.iss!==this.issuer){const A="Wrong issuer: "+g.iss;return this.logger.warn(A),Promise.reject(A)}if(!r&&g.nonce!==v){const A="Wrong nonce: "+g.nonce;return this.logger.warn(A),Promise.reject(A)}if(this.hasOwnProperty("responseType")&&("code"===this.responseType||"id_token"===this.responseType)&&(this.disableAtHashCheck=!0),!this.disableAtHashCheck&&this.requestAccessToken&&!g.at_hash){const A="An at_hash is needed!";return this.logger.warn(A),Promise.reject(A)}const y=this.dateTimeService.now(),x=1e3*g.iat,T=1e3*g.exp,N=this.getClockSkewInMsec();if(x-N>=y||T+N-this.decreaseExpirationBySec<=y){const A="Token has expired";return console.error(A),console.error({now:y,issuedAtMSec:x,expiresAtMSec:T}),Promise.reject(A)}const k={accessToken:i,idToken:t,jwks:this.jwks,idTokenClaims:g,idTokenHeader:c,loadKeys:()=>this.loadJwks()};return this.disableAtHashCheck?this.checkSignature(k).then(A=>({idToken:t,idTokenClaims:g,idTokenClaimsJson:p,idTokenHeader:c,idTokenHeaderJson:a,idTokenExpiresAt:T})):this.checkAtHash(k).then(A=>{if(!this.disableAtHashCheck&&this.requestAccessToken&&!A){const H="Wrong at_hash";return this.logger.warn(H),Promise.reject(H)}return this.checkSignature(k).then(H=>{const X={idToken:t,idTokenClaims:g,idTokenClaimsJson:p,idTokenHeader:c,idTokenHeaderJson:a,idTokenExpiresAt:T};return this.disableAtHashCheck?X:this.checkAtHash(k).then(se=>{if(this.requestAccessToken&&!se){const K="Wrong at_hash";return this.logger.warn(K),Promise.reject(K)}return X})})})}getIdentityClaims(){const t=this._storage.getItem("id_token_claims_obj");return t?JSON.parse(t):null}getGrantedScopes(){const t=this._storage.getItem("granted_scopes");return t?JSON.parse(t):null}getIdToken(){return this._storage?this._storage.getItem("id_token"):null}padBase64(t){for(;t.length%4!=0;)t+="=";return t}getAccessToken(){return this._storage?this._storage.getItem("access_token"):null}getRefreshToken(){return this._storage?this._storage.getItem("refresh_token"):null}getAccessTokenExpiration(){return this._storage.getItem("expires_at")?parseInt(this._storage.getItem("expires_at"),10):null}getAccessTokenStoredAt(){return parseInt(this._storage.getItem("access_token_stored_at"),10)}getIdTokenStoredAt(){return parseInt(this._storage.getItem("id_token_stored_at"),10)}getIdTokenExpiration(){return this._storage.getItem("id_token_expires_at")?parseInt(this._storage.getItem("id_token_expires_at"),10):null}hasValidAccessToken(){if(this.getAccessToken()){const t=this._storage.getItem("expires_at"),i=this.dateTimeService.new();return!(t&&parseInt(t,10)-this.decreaseExpirationBySec=0&&null!==this._storage.getItem(t)?JSON.parse(this._storage.getItem(t)):null}authorizationHeader(){return"Bearer "+this.getAccessToken()}logOut(t={},i=""){let r=!1;"boolean"==typeof t&&(r=t,t={});const s=this.getIdToken();if(this._storage.removeItem("access_token"),this._storage.removeItem("id_token"),this._storage.removeItem("refresh_token"),this.saveNoncesInLocalStorage?(localStorage.removeItem("nonce"),localStorage.removeItem("PKCE_verifier")):(this._storage.removeItem("nonce"),this._storage.removeItem("PKCE_verifier")),this._storage.removeItem("expires_at"),this._storage.removeItem("id_token_claims_obj"),this._storage.removeItem("id_token_expires_at"),this._storage.removeItem("id_token_stored_at"),this._storage.removeItem("access_token_stored_at"),this._storage.removeItem("granted_scopes"),this._storage.removeItem("session_state"),this.config.customTokenParameters&&this.config.customTokenParameters.forEach(a=>this._storage.removeItem(a)),this.silentRefreshSubject=null,this.eventsSubject.next(new jd("logout")),!this.logoutUrl||r)return;let o;if(!this.validateUrlForHttps(this.logoutUrl))throw new Error("logoutUrl must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).");if(this.logoutUrl.indexOf("{{")>-1)o=this.logoutUrl.replace(/\{\{id_token\}\}/,encodeURIComponent(s)).replace(/\{\{client_id\}\}/,encodeURIComponent(this.clientId));else{let a=new Za({encoder:new sy});s&&(a=a.set("id_token_hint",s));const c=this.postLogoutRedirectUri||this.redirectUriAsPostLogoutRedirectUriFallback&&this.redirectUri||"";c&&(a=a.set("post_logout_redirect_uri",c),i&&(a=a.set("state",i)));for(let u in t)a=a.set(u,t[u]);o=this.logoutUrl+(this.logoutUrl.indexOf("?")>-1?"&":"?")+a.toString()}this.config.openUri(o)}createAndSaveNonce(){const t=this;return this.createNonce().then(function(i){return t.saveNoncesInLocalStorage&&typeof window.localStorage<"u"?localStorage.setItem("nonce",i):t._storage.setItem("nonce",i),i})}ngOnDestroy(){this.clearAccessTokenTimer(),this.clearIdTokenTimer(),this.removeSilentRefreshEventListener();const t=this.document.getElementById(this.silentRefreshIFrameName);t&&t.remove(),this.stopSessionCheckTimer(),this.removeSessionCheckEventListener();const i=this.document.getElementById(this.sessionCheckIFrameName);i&&i.remove()}createNonce(){return new Promise(t=>{if(this.rngUrl)throw new Error("createNonce with rng-web-api has not been implemented so far");const i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~";let r=45,s="";const o=typeof self>"u"?null:self.crypto||self.msCrypto;if(o){let a=new Uint8Array(r);o.getRandomValues(a),a.map||(a.map=Array.prototype.map),a=a.map(c=>i.charCodeAt(c%i.length)),s=String.fromCharCode.apply(null,a)}else for(;0"discovery_document_loaded"===r.type)).subscribe(r=>this.initCodeFlowInternal(t,i))}initCodeFlowInternal(t="",i={}){if(!this.validateUrlForHttps(this.loginUrl))throw new Error("loginUrl must use HTTPS (with TLS), or config value for property 'requireHttps' must be set to 'false' and allow HTTP (without TLS).");let r={},s=null;"string"==typeof i?s=i:"object"==typeof i&&(r=i),this.createLoginUrl(t,s,null,!1,r).then(this.config.openUri).catch(o=>{console.error("Error in initAuthorizationCodeFlow"),console.error(o)})}createChallangeVerifierPairForPKCE(){var t=this;return fl(function*(){if(!t.crypto)throw new Error("PKCE support for code flow needs a CryptoHander. Did you import the OAuthModule using forRoot() ?");const i=yield t.createNonce();return[NA(yield t.crypto.calcHash(i,"sha-256")),i]})()}extractRecognizedCustomParameters(t){let i=new Map;return this.config.customTokenParameters&&this.config.customTokenParameters.forEach(r=>{t[r]&&i.set(r,JSON.stringify(t[r]))}),i}revokeTokenAndLogout(t={},i=!1){let r=this.revocationEndpoint,s=this.getAccessToken(),o=this.getRefreshToken();if(!s)return Promise.resolve();let a=new Za({encoder:new sy}),c=(new Ho).set("Content-Type","application/x-www-form-urlencoded");if(this.useHttpBasicAuth){const u=btoa(`${this.clientId}:${this.dummyClientSecret}`);c=c.set("Authorization","Basic "+u)}if(this.useHttpBasicAuth||(a=a.set("client_id",this.clientId)),!this.useHttpBasicAuth&&this.dummyClientSecret&&(a=a.set("client_secret",this.dummyClientSecret)),this.customQueryParams)for(const u of Object.getOwnPropertyNames(this.customQueryParams))a=a.set(u,this.customQueryParams[u]);return new Promise((u,p)=>{let g,v;if(s){let y=a.set("token",s).set("token_type_hint","access_token");g=this.http.post(r,y,{headers:c})}else g=Tt(null);if(o){let y=a.set("token",o).set("token_type_hint","refresh_token");v=this.http.post(r,y,{headers:c})}else v=Tt(null);i&&(g=g.pipe(da(y=>0===y.status?Tt(null):Pc(y))),v=v.pipe(da(y=>0===y.status?Tt(null):Pc(y)))),Fw([g,v]).subscribe(y=>{this.logOut(t),u(y),this.logger.info("Token successfully revoked")},y=>{this.logger.error("Error revoking token",y),this.eventsSubject.next(new cs("token_revoke_error",y)),p(y)})})}clearLocationHash(){""!=location.hash&&(location.hash="")}}return n.\u0275fac=function(t){return new(t||n)(xe(Xt),xe(Ju),xe(OA,8),xe(p5,8),xe(wS,8),xe(m5),xe(h5),xe(_5,8),xe(Mn),xe(PA))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();class v5{}class uQ{handleError(e){return Pc(e)}}let hQ=(()=>{class n{constructor(t,i,r){this.oAuthService=t,this.errorHandler=i,this.moduleConfig=r}checkUrl(t){return this.moduleConfig.resourceServer.customUrlValidation?this.moduleConfig.resourceServer.customUrlValidation(t):!this.moduleConfig.resourceServer.allowedUrls||!!this.moduleConfig.resourceServer.allowedUrls.find(i=>t.toLowerCase().startsWith(i.toLowerCase()))}intercept(t,i){const r=t.url.toLowerCase();return this.moduleConfig&&this.moduleConfig.resourceServer&&this.checkUrl(r)?this.moduleConfig.resourceServer.sendAccessToken?fa(Tt(this.oAuthService.getAccessToken()).pipe(Ui(o=>!!o)),this.oAuthService.events.pipe(Ui(o=>"token_received"===o.type),function JJ(n,e=ag){return function XJ(n,e,t=ag){return i=>{let r=c5(n),s=r?+n-t.now():Math.abs(n);return i.lift(new ZJ(s,r,e,t))}}(n,Pc(new YJ),e)}(this.oAuthService.waitForTokenInMsec||0),da(o=>Tt(null)),_t(o=>this.oAuthService.getAccessToken()))).pipe(Gr(1),ur(o=>{if(o){const c=t.headers.set("Authorization","Bearer "+o);t=t.clone({headers:c})}return i.handle(t).pipe(da(a=>this.errorHandler.handleError(a)))})):i.handle(t).pipe(da(o=>this.errorHandler.handleError(o))):i.handle(t)}}return n.\u0275fac=function(t){return new(t||n)(xe(HA),xe(v5),xe(u5,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();function fQ(){return console}function pQ(){return typeof sessionStorage<"u"?sessionStorage:new eQ}function mQ(n=null,e=d5){return Fx([HA,m5,{provide:h5,useFactory:fQ},{provide:OA,useFactory:pQ},{provide:p5,useClass:e},{provide:_5,useClass:dQ},{provide:v5,useClass:uQ},{provide:u5,useValue:n},{provide:tT,useClass:hQ,multi:!0},{provide:PA,useClass:QJ}])}let gQ=(()=>{class n{static forRoot(t=null,i=d5){return{ngModule:n,providers:[mQ(t,i)]}}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[ul]}),n})();new Ze("AUTH_CONFIG");class vQ extends tQ{constructor(){super(...arguments),this.allowedAlgorithms=["HS256","HS384","HS512","RS256","RS384","RS512","ES256","ES384","PS256","PS384","PS512"],this.gracePeriodInSec=600}validateSignature(e,t=!1){if(!e.idToken)throw new Error("Parameter idToken expected!");if(!e.idTokenHeader)throw new Error("Parameter idTokenHandler expected.");if(!e.jwks)throw new Error("Parameter jwks expected!");if(!e.jwks.keys||!Array.isArray(e.jwks.keys)||0===e.jwks.keys.length)throw new Error("Array keys in jwks missing!");let s,i=e.idTokenHeader.kid,r=e.jwks.keys,o=e.idTokenHeader.alg;if(i)s=r.find(p=>p.kid===i);else{let p=this.alg2kty(o),g=r.filter(v=>v.kty===p&&"sig"===v.use);if(g.length>1){let v="More than one matching key found. Please specify a kid in the id_token header.";return console.error(v),Promise.reject(v)}1===g.length&&(s=g[0])}if(!s&&!t&&e.loadKeys)return e.loadKeys().then(p=>e.jwks=p).then(p=>this.validateSignature(e,!0));if(!s&&t&&!i){let p="No matching key found.";return console.error(p),Promise.reject(p)}if(!s&&t&&i){let p="expected key not found in property jwks. This property is most likely loaded with the discovery document. Expected key id (kid): "+i;return console.error(p),Promise.reject(p)}let a=kA.KZ.getKey(s);return kA.fs.jws.JWS.verifyJWT(e.idToken,a,{alg:this.allowedAlgorithms,gracePeriod:this.gracePeriodInSec})?Promise.resolve():Promise.reject("Signature not valid")}alg2kty(e){switch(e.charAt(0)){case"R":return"RSA";case"E":return"EC";default:throw new Error("Cannot infer kty from alg: "+e)}}calcHash(e,t){let r=new kA.fs.crypto.MessageDigest({alg:t}).digestString(e),s=this.toByteArrayAsString(r);return Promise.resolve(s)}toByteArrayAsString(e){let t="";for(let i=0;ie.startsWith(r))}intercept(e,t){let i=e.url.toLowerCase();if(!this.checkUrl(i))return t.handle(e);let r=e.headers;return i.indexOf("common/destiny2_content")>0||(r=r.set("X-API-Key",oy_bungie_apiKey),"https://www.bungie.net/platform/app/oauth/token/"===i||i.indexOf("getmembershipsbyid")>0||this.authStorage.getItem("access_token")&&(r=r.set("Authorization",`Bearer ${this.authStorage.getItem("access_token")}`)),i.indexOf("/Stats/Activities/")>-1&&(i=i.replace("www.bungie","stats.bungie"))),e=e.clone({headers:r}),t.handle(e)}}mg.\u0275fac=function(e){return new(e||mg)(xe(Wd))},mg.\u0275prov=Je({token:mg,factory:mg.\u0275fac,providedIn:"root"});const y5=new Ze("bungie service");class gg{}function b5(n,e){let t=!1;return arguments.length>=2&&(t=!0),function(r){return r.lift(new yQ(n,e,t))}}gg.\u0275fac=function(e){return new(e||gg)},gg.\u0275mod=Mt({type:gg}),gg.\u0275inj=On({providers:[Wd,{provide:y5,useClass:HA},{provide:tT,useClass:mg,multi:!0}],imports:[ul,gQ.forRoot()]});class yQ{constructor(e,t,i=!1){this.accumulator=e,this.seed=t,this.hasSeed=i}call(e,t){return t.subscribe(new bQ(e,this.accumulator,this.seed,this.hasSeed))}}class bQ extends di{constructor(e,t,i,r){super(e),this.accumulator=t,this._seed=i,this.hasSeed=r,this.index=0}get seed(){return this._seed}set seed(e){this.hasSeed=!0,this._seed=e}_next(e){if(this.hasSeed)return this._tryNext(e);this.seed=e,this.destination.next(e)}_tryNext(e){const t=this.index++;let i;try{i=this.accumulator(this.seed,e,t)}catch(r){this.destination.error(r)}this.seed=i,this.destination.next(i)}}function UA(n){return function(t){return 0===n?kw():t.lift(new xQ(n))}}class xQ{constructor(e){if(this.total=e,this.total<0)throw new DL}call(e,t){return t.subscribe(new wQ(e,this.total))}}class wQ extends di{constructor(e,t){super(e),this.total=t,this.ring=new Array,this.count=0}_next(e){const t=this.ring,i=this.total,r=this.count++;t.length0){const i=this.count>=this.total?this.total:this.count,r=this.ring;for(let s=0;s=2;return i=>i.pipe(n?Ui((r,s)=>n(r,s,i)):Is,UA(1),t?xS(e):l5(()=>new bS))}class EQ{constructor(e){this.value=e}call(e,t){return t.subscribe(new MQ(e,this.value))}}class MQ extends di{constructor(e,t){super(e),this.value=t}_next(e){this.destination.next(this.value)}}const jn="primary",ay=Symbol("RouteTitle");class CQ{constructor(e){this.params=e||{}}has(e){return Object.prototype.hasOwnProperty.call(this.params,e)}get(e){if(this.has(e)){const t=this.params[e];return Array.isArray(t)?t[0]:t}return null}getAll(e){if(this.has(e)){const t=this.params[e];return Array.isArray(t)?t:[t]}return[]}get keys(){return Object.keys(this.params)}}function _g(n){return new CQ(n)}function DQ(n,e,t){const i=t.path.split("/");if(i.length>n.length||"full"===t.pathMatch&&(e.hasChildren()||i.lengthi[s]===r)}return n===e}function S5(n){return Array.prototype.concat.apply([],n)}function E5(n){return n.length>0?n[n.length-1]:null}function So(n,e){for(const t in n)n.hasOwnProperty(t)&&e(n[t],t)}function ch(n){return PC(n)?n:lv(n)?dr(Promise.resolve(n)):Tt(n)}const ES=!1,AQ={exact:function D5(n,e,t){if(!Wf(n.segments,e.segments)||!MS(n.segments,e.segments,t)||n.numberOfChildren!==e.numberOfChildren)return!1;for(const i in e.children)if(!n.children[i]||!D5(n.children[i],e.children[i],t))return!1;return!0},subset:T5},M5={exact:function kQ(n,e){return Jl(n,e)},subset:function IQ(n,e){return Object.keys(e).length<=Object.keys(n).length&&Object.keys(e).every(t=>w5(n[t],e[t]))},ignored:()=>!0};function C5(n,e,t){return AQ[t.paths](n.root,e.root,t.matrixParams)&&M5[t.queryParams](n.queryParams,e.queryParams)&&!("exact"===t.fragment&&n.fragment!==e.fragment)}function T5(n,e,t){return A5(n,e,e.segments,t)}function A5(n,e,t,i){if(n.segments.length>t.length){const r=n.segments.slice(0,t.length);return!(!Wf(r,t)||e.hasChildren()||!MS(r,t,i))}if(n.segments.length===t.length){if(!Wf(n.segments,t)||!MS(n.segments,t,i))return!1;for(const r in e.children)if(!n.children[r]||!T5(n.children[r],e.children[r],i))return!1;return!0}{const r=t.slice(0,n.segments.length),s=t.slice(n.segments.length);return!!(Wf(n.segments,r)&&MS(n.segments,r,i)&&n.children[jn])&&A5(n.children[jn],e,s,i)}}function MS(n,e,t){return e.every((i,r)=>M5[t](n[r].parameters,i.parameters))}class lh{constructor(e=new ai([],{}),t={},i=null){this.root=e,this.queryParams=t,this.fragment=i}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=_g(this.queryParams)),this._queryParamMap}toString(){return PQ.serialize(this)}}class ai{constructor(e,t){this.segments=e,this.children=t,this.parent=null,So(t,(i,r)=>i.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return CS(this)}}class cy{constructor(e,t){this.path=e,this.parameters=t}get parameterMap(){return this._parameterMap||(this._parameterMap=_g(this.parameters)),this._parameterMap}toString(){return F5(this)}}function Wf(n,e){return n.length===e.length&&n.every((t,i)=>t.path===e[i].path)}let ly=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return new zA},providedIn:"root"}),n})();class zA{parse(e){const t=new GQ(e);return new lh(t.parseRootSegment(),t.parseQueryParams(),t.parseFragment())}serialize(e){const t=`/${dy(e.root,!0)}`,i=function NQ(n){const e=Object.keys(n).map(t=>{const i=n[t];return Array.isArray(i)?i.map(r=>`${DS(t)}=${DS(r)}`).join("&"):`${DS(t)}=${DS(i)}`}).filter(t=>!!t);return e.length?`?${e.join("&")}`:""}(e.queryParams),r="string"==typeof e.fragment?`#${function OQ(n){return encodeURI(n)}(e.fragment)}`:"";return`${t}${i}${r}`}}const PQ=new zA;function CS(n){return n.segments.map(e=>F5(e)).join("/")}function dy(n,e){if(!n.hasChildren())return CS(n);if(e){const t=n.children[jn]?dy(n.children[jn],!1):"",i=[];return So(n.children,(r,s)=>{s!==jn&&i.push(`${s}:${dy(r,!1)}`)}),i.length>0?`${t}(${i.join("//")})`:t}{const t=function RQ(n,e){let t=[];return So(n.children,(i,r)=>{r===jn&&(t=t.concat(e(i,r)))}),So(n.children,(i,r)=>{r!==jn&&(t=t.concat(e(i,r)))}),t}(n,(i,r)=>r===jn?[dy(n.children[jn],!1)]:[`${r}:${dy(i,!1)}`]);return 1===Object.keys(n.children).length&&null!=n.children[jn]?`${CS(n)}/${t[0]}`:`${CS(n)}/(${t.join("//")})`}}function k5(n){return encodeURIComponent(n).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function DS(n){return k5(n).replace(/%3B/gi,";")}function GA(n){return k5(n).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function TS(n){return decodeURIComponent(n)}function I5(n){return TS(n.replace(/\+/g,"%20"))}function F5(n){return`${GA(n.path)}${function LQ(n){return Object.keys(n).map(e=>`;${GA(e)}=${GA(n[e])}`).join("")}(n.parameters)}`}const BQ=/^[^\/()?;=#]+/;function AS(n){const e=n.match(BQ);return e?e[0]:""}const VQ=/^[^=?&#]+/,UQ=/^[^&#]+/;class GQ{constructor(e){this.url=e,this.remaining=e}parseRootSegment(){return this.consumeOptional("/"),""===this.remaining||this.peekStartsWith("?")||this.peekStartsWith("#")?new ai([],{}):new ai([],this.parseChildren())}parseQueryParams(){const e={};if(this.consumeOptional("?"))do{this.parseQueryParam(e)}while(this.consumeOptional("&"));return e}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(""===this.remaining)return{};this.consumeOptional("/");const e=[];for(this.peekStartsWith("(")||e.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),e.push(this.parseSegment());let t={};this.peekStartsWith("/(")&&(this.capture("/"),t=this.parseParens(!0));let i={};return this.peekStartsWith("(")&&(i=this.parseParens(!1)),(e.length>0||Object.keys(t).length>0)&&(i[jn]=new ai(e,t)),i}parseSegment(){const e=AS(this.remaining);if(""===e&&this.peekStartsWith(";"))throw new Ue(4009,ES);return this.capture(e),new cy(TS(e),this.parseMatrixParams())}parseMatrixParams(){const e={};for(;this.consumeOptional(";");)this.parseParam(e);return e}parseParam(e){const t=AS(this.remaining);if(!t)return;this.capture(t);let i="";if(this.consumeOptional("=")){const r=AS(this.remaining);r&&(i=r,this.capture(i))}e[TS(t)]=TS(i)}parseQueryParam(e){const t=function HQ(n){const e=n.match(VQ);return e?e[0]:""}(this.remaining);if(!t)return;this.capture(t);let i="";if(this.consumeOptional("=")){const o=function zQ(n){const e=n.match(UQ);return e?e[0]:""}(this.remaining);o&&(i=o,this.capture(i))}const r=I5(t),s=I5(i);if(e.hasOwnProperty(r)){let o=e[r];Array.isArray(o)||(o=[o],e[r]=o),o.push(s)}else e[r]=s}parseParens(e){const t={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){const i=AS(this.remaining),r=this.remaining[i.length];if("/"!==r&&")"!==r&&";"!==r)throw new Ue(4010,ES);let s;i.indexOf(":")>-1?(s=i.slice(0,i.indexOf(":")),this.capture(s),this.capture(":")):e&&(s=jn);const o=this.parseChildren();t[s]=1===Object.keys(o).length?o[jn]:new ai([],o),this.consumeOptional("//")}return t}peekStartsWith(e){return this.remaining.startsWith(e)}consumeOptional(e){return!!this.peekStartsWith(e)&&(this.remaining=this.remaining.substring(e.length),!0)}capture(e){if(!this.consumeOptional(e))throw new Ue(4011,ES)}}function jA(n){return n.segments.length>0?new ai([],{[jn]:n}):n}function kS(n){const e={};for(const i of Object.keys(n.children)){const s=kS(n.children[i]);(s.segments.length>0||s.hasChildren())&&(e[i]=s)}return function jQ(n){if(1===n.numberOfChildren&&n.children[jn]){const e=n.children[jn];return new ai(n.segments.concat(e.segments),e.children)}return n}(new ai(n.segments,e))}function $f(n){return n instanceof lh}const WA=!1;function WQ(n,e,t,i,r){if(0===t.length)return vg(e.root,e.root,e.root,i,r);const s=function N5(n){if("string"==typeof n[0]&&1===n.length&&"/"===n[0])return new L5(!0,0,n);let e=0,t=!1;const i=n.reduce((r,s,o)=>{if("object"==typeof s&&null!=s){if(s.outlets){const a={};return So(s.outlets,(c,u)=>{a[u]="string"==typeof c?c.split("/"):c}),[...r,{outlets:a}]}if(s.segmentPath)return[...r,s.segmentPath]}return"string"!=typeof s?[...r,s]:0===o?(s.split("/").forEach((a,c)=>{0==c&&"."===a||(0==c&&""===a?t=!0:".."===a?e++:""!=a&&r.push(a))}),r):[...r,s]},[]);return new L5(t,e,i)}(t);return s.toRoot()?vg(e.root,e.root,new ai([],{}),i,r):function o(c){const u=function qQ(n,e,t,i){if(n.isAbsolute)return new yg(e.root,!0,0);if(-1===i)return new yg(t,t===e.root,0);return function B5(n,e,t){let i=n,r=e,s=t;for(;s>r;){if(s-=r,i=i.parent,!i)throw new Ue(4005,WA&&"Invalid number of '../'");r=i.segments.length}return new yg(i,!1,r-s)}(t,i+(uy(n.commands[0])?0:1),n.numberOfDoubleDots)}(s,e,n.snapshot?._urlSegment,c),p=u.processChildren?bg(u.segmentGroup,u.index,s.commands):$A(u.segmentGroup,u.index,s.commands);return vg(e.root,u.segmentGroup,p,i,r)}(n.snapshot?._lastPathIndex)}function uy(n){return"object"==typeof n&&null!=n&&!n.outlets&&!n.segmentPath}function hy(n){return"object"==typeof n&&null!=n&&n.outlets}function vg(n,e,t,i,r){let o,s={};i&&So(i,(c,u)=>{s[u]=Array.isArray(c)?c.map(p=>`${p}`):`${c}`}),o=n===e?t:O5(n,e,t);const a=jA(kS(o));return new lh(a,s,r)}function O5(n,e,t){const i={};return So(n.children,(r,s)=>{i[s]=r===e?t:O5(r,e,t)}),new ai(n.segments,i)}class L5{constructor(e,t,i){if(this.isAbsolute=e,this.numberOfDoubleDots=t,this.commands=i,e&&i.length>0&&uy(i[0]))throw new Ue(4003,WA&&"Root segment cannot have matrix parameters");const r=i.find(hy);if(r&&r!==E5(i))throw new Ue(4004,WA&&"{outlets:{}} has to be the last command")}toRoot(){return this.isAbsolute&&1===this.commands.length&&"/"==this.commands[0]}}class yg{constructor(e,t,i){this.segmentGroup=e,this.processChildren=t,this.index=i}}function $A(n,e,t){if(n||(n=new ai([],{})),0===n.segments.length&&n.hasChildren())return bg(n,e,t);const i=function YQ(n,e,t){let i=0,r=e;const s={match:!1,pathIndex:0,commandIndex:0};for(;r=t.length)return s;const o=n.segments[r],a=t[i];if(hy(a))break;const c=`${a}`,u=i0&&void 0===c)break;if(c&&u&&"object"==typeof u&&void 0===u.outlets){if(!H5(c,u,o))return s;i+=2}else{if(!H5(c,{},o))return s;i++}r++}return{match:!0,pathIndex:r,commandIndex:i}}(n,e,t),r=t.slice(i.commandIndex);if(i.match&&i.pathIndex{"string"==typeof s&&(s=[s]),null!==s&&(r[o]=$A(n.children[o],e,s))}),So(n.children,(s,o)=>{void 0===i[o]&&(r[o]=s)}),new ai(n.segments,r))}}function qA(n,e,t){const i=n.segments.slice(0,e);let r=0;for(;r{"string"==typeof t&&(t=[t]),null!==t&&(e[i]=qA(new ai([],{}),0,t))}),e}function V5(n){const e={};return So(n,(t,i)=>e[i]=`${t}`),e}function H5(n,e,t){return n==t.path&&Jl(e,t.parameters)}const fy="imperative";class Ql{constructor(e,t){this.id=e,this.url=t}}class KA extends Ql{constructor(e,t,i="imperative",r=null){super(e,t),this.type=0,this.navigationTrigger=i,this.restoredState=r}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}}class qf extends Ql{constructor(e,t,i){super(e,t),this.urlAfterRedirects=i,this.type=1}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}}class IS extends Ql{constructor(e,t,i,r){super(e,t),this.reason=i,this.code=r,this.type=2}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}}class FS extends Ql{constructor(e,t,i,r){super(e,t),this.reason=i,this.code=r,this.type=16}}class YA extends Ql{constructor(e,t,i,r){super(e,t),this.error=i,this.target=r,this.type=3}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}}class ZQ extends Ql{constructor(e,t,i,r){super(e,t),this.urlAfterRedirects=i,this.state=r,this.type=4}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class JQ extends Ql{constructor(e,t,i,r){super(e,t),this.urlAfterRedirects=i,this.state=r,this.type=7}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class QQ extends Ql{constructor(e,t,i,r,s){super(e,t),this.urlAfterRedirects=i,this.state=r,this.shouldActivate=s,this.type=8}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}}class eee extends Ql{constructor(e,t,i,r){super(e,t),this.urlAfterRedirects=i,this.state=r,this.type=5}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class tee extends Ql{constructor(e,t,i,r){super(e,t),this.urlAfterRedirects=i,this.state=r,this.type=6}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class nee{constructor(e){this.route=e,this.type=9}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}}class iee{constructor(e){this.route=e,this.type=10}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}}class ree{constructor(e){this.snapshot=e,this.type=11}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class see{constructor(e){this.snapshot=e,this.type=12}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class oee{constructor(e){this.snapshot=e,this.type=13}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class aee{constructor(e){this.snapshot=e,this.type=14}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class U5{constructor(e,t,i){this.routerEvent=e,this.position=t,this.anchor=i,this.type=15}toString(){return`Scroll(anchor: '${this.anchor}', position: '${this.position?`${this.position[0]}, ${this.position[1]}`:null}')`}}let dee=(()=>{class n{createUrlTree(t,i,r,s,o,a){return WQ(t||i.root,r,s,o,a)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})(),hee=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(e){return dee.\u0275fac(e)},providedIn:"root"}),n})();class z5{constructor(e){this._root=e}get root(){return this._root.value}parent(e){const t=this.pathFromRoot(e);return t.length>1?t[t.length-2]:null}children(e){const t=XA(e,this._root);return t?t.children.map(i=>i.value):[]}firstChild(e){const t=XA(e,this._root);return t&&t.children.length>0?t.children[0].value:null}siblings(e){const t=ZA(e,this._root);return t.length<2?[]:t[t.length-2].children.map(r=>r.value).filter(r=>r!==e)}pathFromRoot(e){return ZA(e,this._root).map(t=>t.value)}}function XA(n,e){if(n===e.value)return e;for(const t of e.children){const i=XA(n,t);if(i)return i}return null}function ZA(n,e){if(n===e.value)return[e];for(const t of e.children){const i=ZA(n,t);if(i.length)return i.unshift(e),i}return[]}class $d{constructor(e,t){this.value=e,this.children=t}toString(){return`TreeNode(${this.value})`}}function xg(n){const e={};return n&&n.children.forEach(t=>e[t.value.outlet]=t),e}class G5 extends z5{constructor(e,t){super(e),this.snapshot=t,JA(this,e)}toString(){return this.snapshot.toString()}}function j5(n,e){const t=function fee(n,e){const o=new RS([],{},{},"",{},jn,e,null,n.root,-1,{});return new $5("",new $d(o,[]))}(n,e),i=new er([new cy("",{})]),r=new er({}),s=new er({}),o=new er({}),a=new er(""),c=new Kf(i,r,o,a,s,jn,e,t.root);return c.snapshot=t.root,new G5(new $d(c,[]),t)}class Kf{constructor(e,t,i,r,s,o,a,c){this.url=e,this.params=t,this.queryParams=i,this.fragment=r,this.data=s,this.outlet=o,this.component=a,this.title=this.data?.pipe(_t(u=>u[ay]))??Tt(void 0),this._futureSnapshot=c}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap||(this._paramMap=this.params.pipe(_t(e=>_g(e)))),this._paramMap}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=this.queryParams.pipe(_t(e=>_g(e)))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}}function W5(n,e="emptyOnly"){const t=n.pathFromRoot;let i=0;if("always"!==e)for(i=t.length-1;i>=1;){const r=t[i],s=t[i-1];if(r.routeConfig&&""===r.routeConfig.path)i--;else{if(s.component)break;i--}}return function pee(n){return n.reduce((e,t)=>({params:{...e.params,...t.params},data:{...e.data,...t.data},resolve:{...t.data,...e.resolve,...t.routeConfig?.data,...t._resolvedData}}),{params:{},data:{},resolve:{}})}(t.slice(i))}class RS{get title(){return this.data?.[ay]}constructor(e,t,i,r,s,o,a,c,u,p,g){this.url=e,this.params=t,this.queryParams=i,this.fragment=r,this.data=s,this.outlet=o,this.component=a,this.routeConfig=c,this._urlSegment=u,this._lastPathIndex=p,this._resolve=g}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap||(this._paramMap=_g(this.params)),this._paramMap}get queryParamMap(){return this._queryParamMap||(this._queryParamMap=_g(this.queryParams)),this._queryParamMap}toString(){return`Route(url:'${this.url.map(i=>i.toString()).join("/")}', path:'${this.routeConfig?this.routeConfig.path:""}')`}}class $5 extends z5{constructor(e,t){super(t),this.url=e,JA(this,t)}toString(){return q5(this._root)}}function JA(n,e){e.value._routerState=n,e.children.forEach(t=>JA(n,t))}function q5(n){const e=n.children.length>0?` { ${n.children.map(q5).join(", ")} } `:"";return`${n.value}${e}`}function QA(n){if(n.snapshot){const e=n.snapshot,t=n._futureSnapshot;n.snapshot=t,Jl(e.queryParams,t.queryParams)||n.queryParams.next(t.queryParams),e.fragment!==t.fragment&&n.fragment.next(t.fragment),Jl(e.params,t.params)||n.params.next(t.params),function TQ(n,e){if(n.length!==e.length)return!1;for(let t=0;tJl(t.parameters,e[i].parameters))}(n.url,e.url);return t&&!(!n.parent!=!e.parent)&&(!n.parent||ek(n.parent,e.parent))}function py(n,e,t){if(t&&n.shouldReuseRoute(e.value,t.value.snapshot)){const i=t.value;i._futureSnapshot=e.value;const r=function gee(n,e,t){return e.children.map(i=>{for(const r of t.children)if(n.shouldReuseRoute(i.value,r.value.snapshot))return py(n,i,r);return py(n,i)})}(n,e,t);return new $d(i,r)}{if(n.shouldAttach(e.value)){const s=n.retrieve(e.value);if(null!==s){const o=s.route;return o.value._futureSnapshot=e.value,o.children=e.children.map(a=>py(n,a)),o}}const i=function _ee(n){return new Kf(new er(n.url),new er(n.params),new er(n.queryParams),new er(n.fragment),new er(n.data),n.outlet,n.component,n)}(e.value),r=e.children.map(s=>py(n,s));return new $d(i,r)}}const tk="ngNavigationCancelingError";function K5(n,e){const{redirectTo:t,navigationBehaviorOptions:i}=$f(e)?{redirectTo:e,navigationBehaviorOptions:void 0}:e,r=Y5(!1,0,e);return r.url=t,r.navigationBehaviorOptions=i,r}function Y5(n,e,t){const i=new Error("NavigationCancelingError: "+(n||""));return i[tk]=!0,i.cancellationCode=e,t&&(i.url=t),i}function X5(n){return Z5(n)&&$f(n.url)}function Z5(n){return n&&n[tk]}class vee{constructor(){this.outlet=null,this.route=null,this.resolver=null,this.injector=null,this.children=new my,this.attachRef=null}}let my=(()=>{class n{constructor(){this.contexts=new Map}onChildOutletCreated(t,i){const r=this.getOrCreateContext(t);r.outlet=i,this.contexts.set(t,r)}onChildOutletDestroyed(t){const i=this.getContext(t);i&&(i.outlet=null,i.attachRef=null)}onOutletDeactivated(){const t=this.contexts;return this.contexts=new Map,t}onOutletReAttached(t){this.contexts=t}getOrCreateContext(t){let i=this.getContext(t);return i||(i=new vee,this.contexts.set(t,i)),i}getContext(t){return this.contexts.get(t)||null}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const PS=!1;let J5=(()=>{class n{constructor(){this.activated=null,this._activatedRoute=null,this.name=jn,this.activateEvents=new Pn,this.deactivateEvents=new Pn,this.attachEvents=new Pn,this.detachEvents=new Pn,this.parentContexts=hn(my),this.location=hn(Sa),this.changeDetector=hn(aa),this.environmentInjector=hn(na)}ngOnChanges(t){if(t.name){const{firstChange:i,previousValue:r}=t.name;if(i)return;this.isTrackedInParentContexts(r)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(r)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name)}isTrackedInParentContexts(t){return this.parentContexts.getContext(t)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;const t=this.parentContexts.getContext(this.name);t?.route&&(t.attachRef?this.attach(t.attachRef,t.route):this.activateWith(t.route,t.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new Ue(4012,PS);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new Ue(4012,PS);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new Ue(4012,PS);this.location.detach();const t=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(t.instance),t}attach(t,i){this.activated=t,this._activatedRoute=i,this.location.insert(t.hostView),this.attachEvents.emit(t.instance)}deactivate(){if(this.activated){const t=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(t)}}activateWith(t,i){if(this.isActivated)throw new Ue(4013,PS);this._activatedRoute=t;const r=this.location,o=t.snapshot.component,a=this.parentContexts.getOrCreateContext(this.name).children,c=new yee(t,a,r.injector);if(i&&function bee(n){return!!n.resolveComponentFactory}(i)){const u=i.resolveComponentFactory(o);this.activated=r.createComponent(u,r.length,c)}else this.activated=r.createComponent(o,{index:r.length,injector:c,environmentInjector:i??this.environmentInjector});this.changeDetector.markForCheck(),this.activateEvents.emit(this.activated.instance)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["router-outlet"]],inputs:{name:"name"},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],standalone:!0,features:[Cn]}),n})();class yee{constructor(e,t,i){this.route=e,this.childContexts=t,this.parent=i}get(e,t){return e===Kf?this.route:e===my?this.childContexts:this.parent.get(e,t)}}let nk=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275cmp=Ln({type:n,selectors:[["ng-component"]],standalone:!0,features:[_v],decls:1,vars:0,template:function(t,i){1&t&&qt(0,"router-outlet")},dependencies:[J5],encapsulation:2}),n})();function Q5(n,e){return n.providers&&!n._injector&&(n._injector=O1(n.providers,e,`Route: ${n.path}`)),n._injector??e}function rk(n){const e=n.children&&n.children.map(rk),t=e?{...n,children:e}:{...n};return!t.component&&!t.loadComponent&&(e||t.loadChildren)&&t.outlet&&t.outlet!==jn&&(t.component=nk),t}function Nc(n){return n.outlet||jn}function e8(n,e){const t=n.filter(i=>Nc(i)===e);return t.push(...n.filter(i=>Nc(i)!==e)),t}function gy(n){if(!n)return null;if(n.routeConfig?._injector)return n.routeConfig._injector;for(let e=n.parent;e;e=e.parent){const t=e.routeConfig;if(t?._loadedInjector)return t._loadedInjector;if(t?._injector)return t._injector}return null}class Mee{constructor(e,t,i,r){this.routeReuseStrategy=e,this.futureState=t,this.currState=i,this.forwardEvent=r}activate(e){const t=this.futureState._root,i=this.currState?this.currState._root:null;this.deactivateChildRoutes(t,i,e),QA(this.futureState.root),this.activateChildRoutes(t,i,e)}deactivateChildRoutes(e,t,i){const r=xg(t);e.children.forEach(s=>{const o=s.value.outlet;this.deactivateRoutes(s,r[o],i),delete r[o]}),So(r,(s,o)=>{this.deactivateRouteAndItsChildren(s,i)})}deactivateRoutes(e,t,i){const r=e.value,s=t?t.value:null;if(r===s)if(r.component){const o=i.getContext(r.outlet);o&&this.deactivateChildRoutes(e,t,o.children)}else this.deactivateChildRoutes(e,t,i);else s&&this.deactivateRouteAndItsChildren(t,i)}deactivateRouteAndItsChildren(e,t){e.value.component&&this.routeReuseStrategy.shouldDetach(e.value.snapshot)?this.detachAndStoreRouteSubtree(e,t):this.deactivateRouteAndOutlet(e,t)}detachAndStoreRouteSubtree(e,t){const i=t.getContext(e.value.outlet),r=i&&e.value.component?i.children:t,s=xg(e);for(const o of Object.keys(s))this.deactivateRouteAndItsChildren(s[o],r);if(i&&i.outlet){const o=i.outlet.detach(),a=i.children.onOutletDeactivated();this.routeReuseStrategy.store(e.value.snapshot,{componentRef:o,route:e,contexts:a})}}deactivateRouteAndOutlet(e,t){const i=t.getContext(e.value.outlet),r=i&&e.value.component?i.children:t,s=xg(e);for(const o of Object.keys(s))this.deactivateRouteAndItsChildren(s[o],r);i&&i.outlet&&(i.outlet.deactivate(),i.children.onOutletDeactivated(),i.attachRef=null,i.resolver=null,i.route=null)}activateChildRoutes(e,t,i){const r=xg(t);e.children.forEach(s=>{this.activateRoutes(s,r[s.value.outlet],i),this.forwardEvent(new aee(s.value.snapshot))}),e.children.length&&this.forwardEvent(new see(e.value.snapshot))}activateRoutes(e,t,i){const r=e.value,s=t?t.value:null;if(QA(r),r===s)if(r.component){const o=i.getOrCreateContext(r.outlet);this.activateChildRoutes(e,t,o.children)}else this.activateChildRoutes(e,t,i);else if(r.component){const o=i.getOrCreateContext(r.outlet);if(this.routeReuseStrategy.shouldAttach(r.snapshot)){const a=this.routeReuseStrategy.retrieve(r.snapshot);this.routeReuseStrategy.store(r.snapshot,null),o.children.onOutletReAttached(a.contexts),o.attachRef=a.componentRef,o.route=a.route.value,o.outlet&&o.outlet.attach(a.componentRef,a.route.value),QA(a.route.value),this.activateChildRoutes(e,null,o.children)}else{const a=gy(r.snapshot),c=a?.get(Fd)??null;o.attachRef=null,o.route=r,o.resolver=c,o.injector=a,o.outlet&&o.outlet.activateWith(r,o.injector),this.activateChildRoutes(e,null,o.children)}}else this.activateChildRoutes(e,null,i)}}class t8{constructor(e){this.path=e,this.route=this.path[this.path.length-1]}}class OS{constructor(e,t){this.component=e,this.route=t}}function Cee(n,e,t){const i=n._root;return _y(i,e?e._root:null,t,[i.value])}function wg(n,e){const t=Symbol(),i=e.get(n,t);return i===t?"function"!=typeof n||function B0(n){return null!==_u(n)}(n)?e.get(n):n:i}function _y(n,e,t,i,r={canDeactivateChecks:[],canActivateChecks:[]}){const s=xg(e);return n.children.forEach(o=>{(function Tee(n,e,t,i,r={canDeactivateChecks:[],canActivateChecks:[]}){const s=n.value,o=e?e.value:null,a=t?t.getContext(n.value.outlet):null;if(o&&s.routeConfig===o.routeConfig){const c=function Aee(n,e,t){if("function"==typeof t)return t(n,e);switch(t){case"pathParamsChange":return!Wf(n.url,e.url);case"pathParamsOrQueryParamsChange":return!Wf(n.url,e.url)||!Jl(n.queryParams,e.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!ek(n,e)||!Jl(n.queryParams,e.queryParams);default:return!ek(n,e)}}(o,s,s.routeConfig.runGuardsAndResolvers);c?r.canActivateChecks.push(new t8(i)):(s.data=o.data,s._resolvedData=o._resolvedData),_y(n,e,s.component?a?a.children:null:t,i,r),c&&a&&a.outlet&&a.outlet.isActivated&&r.canDeactivateChecks.push(new OS(a.outlet.component,o))}else o&&vy(e,a,r),r.canActivateChecks.push(new t8(i)),_y(n,null,s.component?a?a.children:null:t,i,r)})(o,s[o.value.outlet],t,i.concat([o.value]),r),delete s[o.value.outlet]}),So(s,(o,a)=>vy(o,t.getContext(a),r)),r}function vy(n,e,t){const i=xg(n),r=n.value;So(i,(s,o)=>{vy(s,r.component?e?e.children.getContext(o):null:e,t)}),t.canDeactivateChecks.push(new OS(r.component&&e&&e.outlet&&e.outlet.isActivated?e.outlet.component:null,r))}function yy(n){return"function"==typeof n}function sk(n){return n instanceof bS||"EmptyError"===n?.name}const LS=Symbol("INITIAL_VALUE");function Sg(){return wo(n=>Fw(n.map(e=>e.pipe(Gr(1),Bf(LS)))).pipe(_t(e=>{for(const t of e)if(!0!==t){if(t===LS)return LS;if(!1===t||t instanceof lh)return t}return!0}),Ui(e=>e!==LS),Gr(1)))}function n8(n){return function Yr(...n){return Sr(n)}(Dr(e=>{if($f(e))throw K5(0,e)}),_t(e=>!0===e))}const ok={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function i8(n,e,t,i,r){const s=ak(n,e,t);return s.matched?function $ee(n,e,t,i){const r=e.canMatch;return r&&0!==r.length?Tt(r.map(o=>{const a=wg(o,n);return ch(function Oee(n){return n&&yy(n.canMatch)}(a)?a.canMatch(e,t):n.runInContext(()=>a(e,t)))})).pipe(Sg(),n8()):Tt(!0)}(i=Q5(e,i),e,t).pipe(_t(o=>!0===o?s:{...ok})):Tt(s)}function ak(n,e,t){if(""===e.path)return"full"===e.pathMatch&&(n.hasChildren()||t.length>0)?{...ok}:{matched:!0,consumedSegments:[],remainingSegments:t,parameters:{},positionalParamSegments:{}};const r=(e.matcher||DQ)(t,n,e);if(!r)return{...ok};const s={};So(r.posParams,(a,c)=>{s[c]=a.path});const o=r.consumed.length>0?{...s,...r.consumed[r.consumed.length-1].parameters}:s;return{matched:!0,consumedSegments:r.consumed,remainingSegments:t.slice(r.consumed.length),parameters:o,positionalParamSegments:r.posParams??{}}}function NS(n,e,t,i){if(t.length>0&&function Yee(n,e,t){return t.some(i=>BS(n,e,i)&&Nc(i)!==jn)}(n,t,i)){const s=new ai(e,function Kee(n,e,t,i){const r={};r[jn]=i,i._sourceSegment=n,i._segmentIndexShift=e.length;for(const s of t)if(""===s.path&&Nc(s)!==jn){const o=new ai([],{});o._sourceSegment=n,o._segmentIndexShift=e.length,r[Nc(s)]=o}return r}(n,e,i,new ai(t,n.children)));return s._sourceSegment=n,s._segmentIndexShift=e.length,{segmentGroup:s,slicedSegments:[]}}if(0===t.length&&function Xee(n,e,t){return t.some(i=>BS(n,e,i))}(n,t,i)){const s=new ai(n.segments,function qee(n,e,t,i,r){const s={};for(const o of i)if(BS(n,t,o)&&!r[Nc(o)]){const a=new ai([],{});a._sourceSegment=n,a._segmentIndexShift=e.length,s[Nc(o)]=a}return{...r,...s}}(n,e,t,i,n.children));return s._sourceSegment=n,s._segmentIndexShift=e.length,{segmentGroup:s,slicedSegments:t}}const r=new ai(n.segments,n.children);return r._sourceSegment=n,r._segmentIndexShift=e.length,{segmentGroup:r,slicedSegments:t}}function BS(n,e,t){return(!(n.hasChildren()||e.length>0)||"full"!==t.pathMatch)&&""===t.path}function r8(n,e,t,i){return!!(Nc(n)===i||i!==jn&&BS(e,t,n))&&("**"===n.path||ak(e,n,t).matched)}function s8(n,e,t){return 0===e.length&&!n.children[t]}const VS=!1;class HS{constructor(e){this.segmentGroup=e||null}}class o8{constructor(e){this.urlTree=e}}function by(n){return Pc(new HS(n))}function a8(n){return Pc(new o8(n))}function Zee(n){return Pc(new Ue(4e3,VS&&`Only absolute redirects can have named outlets. redirectTo: '${n}'`))}class ete{constructor(e,t,i,r,s){this.injector=e,this.configLoader=t,this.urlSerializer=i,this.urlTree=r,this.config=s,this.allowRedirects=!0}apply(){const e=NS(this.urlTree.root,[],[],this.config).segmentGroup,t=new ai(e.segments,e.children);return this.expandSegmentGroup(this.injector,this.config,t,jn).pipe(_t(s=>this.createUrlTree(kS(s),this.urlTree.queryParams,this.urlTree.fragment))).pipe(da(s=>{if(s instanceof o8)return this.allowRedirects=!1,this.match(s.urlTree);throw s instanceof HS?this.noMatchError(s):s}))}match(e){return this.expandSegmentGroup(this.injector,this.config,e.root,jn).pipe(_t(r=>this.createUrlTree(kS(r),e.queryParams,e.fragment))).pipe(da(r=>{throw r instanceof HS?this.noMatchError(r):r}))}noMatchError(e){return new Ue(4002,VS&&`Cannot match any routes. URL Segment: '${e.segmentGroup}'`)}createUrlTree(e,t,i){const r=jA(e);return new lh(r,t,i)}expandSegmentGroup(e,t,i,r){return 0===i.segments.length&&i.hasChildren()?this.expandChildren(e,t,i).pipe(_t(s=>new ai([],s))):this.expandSegment(e,i,t,i.segments,r,!0)}expandChildren(e,t,i){const r=[];for(const s of Object.keys(i.children))"primary"===s?r.unshift(s):r.push(s);return dr(r).pipe(Zu(s=>{const o=i.children[s],a=e8(t,s);return this.expandSegmentGroup(e,a,o,s).pipe(_t(c=>({segment:c,outlet:s})))}),b5((s,o)=>(s[o.outlet]=o.segment,s),{}),x5())}expandSegment(e,t,i,r,s,o){return dr(i).pipe(Zu(a=>this.expandSegmentAgainstRoute(e,t,i,a,r,s,o).pipe(da(u=>{if(u instanceof HS)return Tt(null);throw u}))),ml(a=>!!a),da((a,c)=>{if(sk(a))return s8(t,r,s)?Tt(new ai([],{})):by(t);throw a}))}expandSegmentAgainstRoute(e,t,i,r,s,o,a){return r8(r,t,s,o)?void 0===r.redirectTo?this.matchSegmentAgainstRoute(e,t,r,s,o):a&&this.allowRedirects?this.expandSegmentAgainstRouteUsingRedirect(e,t,i,r,s,o):by(t):by(t)}expandSegmentAgainstRouteUsingRedirect(e,t,i,r,s,o){return"**"===r.path?this.expandWildCardWithParamsAgainstRouteUsingRedirect(e,i,r,o):this.expandRegularSegmentAgainstRouteUsingRedirect(e,t,i,r,s,o)}expandWildCardWithParamsAgainstRouteUsingRedirect(e,t,i,r){const s=this.applyRedirectCommands([],i.redirectTo,{});return i.redirectTo.startsWith("/")?a8(s):this.lineralizeSegments(i,s).pipe(ur(o=>{const a=new ai(o,{});return this.expandSegment(e,a,t,o,r,!1)}))}expandRegularSegmentAgainstRouteUsingRedirect(e,t,i,r,s,o){const{matched:a,consumedSegments:c,remainingSegments:u,positionalParamSegments:p}=ak(t,r,s);if(!a)return by(t);const g=this.applyRedirectCommands(c,r.redirectTo,p);return r.redirectTo.startsWith("/")?a8(g):this.lineralizeSegments(r,g).pipe(ur(v=>this.expandSegment(e,t,i,v.concat(u),o,!1)))}matchSegmentAgainstRoute(e,t,i,r,s){return"**"===i.path?(e=Q5(i,e),i.loadChildren?(i._loadedRoutes?Tt({routes:i._loadedRoutes,injector:i._loadedInjector}):this.configLoader.loadChildren(e,i)).pipe(_t(a=>(i._loadedRoutes=a.routes,i._loadedInjector=a.injector,new ai(r,{})))):Tt(new ai(r,{}))):i8(t,i,r,e).pipe(wo(({matched:o,consumedSegments:a,remainingSegments:c})=>o?this.getChildConfig(e=i._injector??e,i,r).pipe(ur(p=>{const g=p.injector??e,v=p.routes,{segmentGroup:y,slicedSegments:x}=NS(t,a,c,v),T=new ai(y.segments,y.children);if(0===x.length&&T.hasChildren())return this.expandChildren(g,v,T).pipe(_t(H=>new ai(a,H)));if(0===v.length&&0===x.length)return Tt(new ai(a,{}));const N=Nc(i)===s;return this.expandSegment(g,T,v,x,N?jn:s,!0).pipe(_t(A=>new ai(a.concat(A.segments),A.children)))})):by(t)))}getChildConfig(e,t,i){return t.children?Tt({routes:t.children,injector:e}):t.loadChildren?void 0!==t._loadedRoutes?Tt({routes:t._loadedRoutes,injector:t._loadedInjector}):function Wee(n,e,t,i){const r=e.canLoad;return void 0===r||0===r.length?Tt(!0):Tt(r.map(o=>{const a=wg(o,n);return ch(function Iee(n){return n&&yy(n.canLoad)}(a)?a.canLoad(e,t):n.runInContext(()=>a(e,t)))})).pipe(Sg(),n8())}(e,t,i).pipe(ur(r=>r?this.configLoader.loadChildren(e,t).pipe(Dr(s=>{t._loadedRoutes=s.routes,t._loadedInjector=s.injector})):function Jee(n){return Pc(Y5(VS&&`Cannot load children because the guard of the route "path: '${n.path}'" returned false`,3))}(t))):Tt({routes:[],injector:e})}lineralizeSegments(e,t){let i=[],r=t.root;for(;;){if(i=i.concat(r.segments),0===r.numberOfChildren)return Tt(i);if(r.numberOfChildren>1||!r.children[jn])return Zee(e.redirectTo);r=r.children[jn]}}applyRedirectCommands(e,t,i){return this.applyRedirectCreateUrlTree(t,this.urlSerializer.parse(t),e,i)}applyRedirectCreateUrlTree(e,t,i,r){const s=this.createSegmentGroup(e,t.root,i,r);return new lh(s,this.createQueryParams(t.queryParams,this.urlTree.queryParams),t.fragment)}createQueryParams(e,t){const i={};return So(e,(r,s)=>{if("string"==typeof r&&r.startsWith(":")){const a=r.substring(1);i[s]=t[a]}else i[s]=r}),i}createSegmentGroup(e,t,i,r){const s=this.createSegments(e,t.segments,i,r);let o={};return So(t.children,(a,c)=>{o[c]=this.createSegmentGroup(e,a,i,r)}),new ai(s,o)}createSegments(e,t,i,r){return t.map(s=>s.path.startsWith(":")?this.findPosParam(e,s,r):this.findOrReturn(s,i))}findPosParam(e,t,i){const r=i[t.path.substring(1)];if(!r)throw new Ue(4001,VS&&`Cannot redirect to '${e}'. Cannot find '${t.path}'.`);return r}findOrReturn(e,t){let i=0;for(const r of t){if(r.path===e.path)return t.splice(i),r;i++}return e}}class nte{}class ste{constructor(e,t,i,r,s,o,a){this.injector=e,this.rootComponentType=t,this.config=i,this.urlTree=r,this.url=s,this.paramsInheritanceStrategy=o,this.urlSerializer=a}recognize(){const e=NS(this.urlTree.root,[],[],this.config.filter(t=>void 0===t.redirectTo)).segmentGroup;return this.processSegmentGroup(this.injector,this.config,e,jn).pipe(_t(t=>{if(null===t)return null;const i=new RS([],Object.freeze({}),Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,{},jn,this.rootComponentType,null,this.urlTree.root,-1,{}),r=new $d(i,t),s=new $5(this.url,r);return this.inheritParamsAndData(s._root),s}))}inheritParamsAndData(e){const t=e.value,i=W5(t,this.paramsInheritanceStrategy);t.params=Object.freeze(i.params),t.data=Object.freeze(i.data),e.children.forEach(r=>this.inheritParamsAndData(r))}processSegmentGroup(e,t,i,r){return 0===i.segments.length&&i.hasChildren()?this.processChildren(e,t,i):this.processSegment(e,t,i,i.segments,r)}processChildren(e,t,i){return dr(Object.keys(i.children)).pipe(Zu(r=>{const s=i.children[r],o=e8(t,r);return this.processSegmentGroup(e,o,s,r)}),b5((r,s)=>r&&s?(r.push(...s),r):null),AN(r=>null!==r),xS(null),x5(),_t(r=>{if(null===r)return null;const s=l8(r);return function ote(n){n.sort((e,t)=>e.value.outlet===jn?-1:t.value.outlet===jn?1:e.value.outlet.localeCompare(t.value.outlet))}(s),s}))}processSegment(e,t,i,r,s){return dr(t).pipe(Zu(o=>this.processSegmentAgainstRoute(o._injector??e,o,i,r,s)),ml(o=>!!o),da(o=>{if(sk(o))return s8(i,r,s)?Tt([]):Tt(null);throw o}))}processSegmentAgainstRoute(e,t,i,r,s){if(t.redirectTo||!r8(t,i,r,s))return Tt(null);let o;if("**"===t.path){const a=r.length>0?E5(r).parameters:{},c=u8(i)+r.length;o=Tt({snapshot:new RS(r,a,Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,h8(t),Nc(t),t.component??t._loadedComponent??null,t,d8(i),c,f8(t)),consumedSegments:[],remainingSegments:[]})}else o=i8(i,t,r,e).pipe(_t(({matched:a,consumedSegments:c,remainingSegments:u,parameters:p})=>{if(!a)return null;const g=u8(i)+c.length;return{snapshot:new RS(c,p,Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,h8(t),Nc(t),t.component??t._loadedComponent??null,t,d8(i),g,f8(t)),consumedSegments:c,remainingSegments:u}}));return o.pipe(wo(a=>{if(null===a)return Tt(null);const{snapshot:c,consumedSegments:u,remainingSegments:p}=a;e=t._injector??e;const g=t._loadedInjector??e,v=function ate(n){return n.children?n.children:n.loadChildren?n._loadedRoutes:[]}(t),{segmentGroup:y,slicedSegments:x}=NS(i,u,p,v.filter(N=>void 0===N.redirectTo));if(0===x.length&&y.hasChildren())return this.processChildren(g,v,y).pipe(_t(N=>null===N?null:[new $d(c,N)]));if(0===v.length&&0===x.length)return Tt([new $d(c,[])]);const T=Nc(t)===s;return this.processSegment(g,v,y,x,T?jn:s).pipe(_t(N=>null===N?null:[new $d(c,N)]))}))}}function cte(n){const e=n.value.routeConfig;return e&&""===e.path&&void 0===e.redirectTo}function l8(n){const e=[],t=new Set;for(const i of n){if(!cte(i)){e.push(i);continue}const r=e.find(s=>i.value.routeConfig===s.value.routeConfig);void 0!==r?(r.children.push(...i.children),t.add(r)):e.push(i)}for(const i of t){const r=l8(i.children);e.push(new $d(i.value,r))}return e.filter(i=>!t.has(i))}function d8(n){let e=n;for(;e._sourceSegment;)e=e._sourceSegment;return e}function u8(n){let e=n,t=e._segmentIndexShift??0;for(;e._sourceSegment;)e=e._sourceSegment,t+=e._segmentIndexShift??0;return t-1}function h8(n){return n.data||{}}function f8(n){return n.resolve||{}}function p8(n){return"string"==typeof n.title||null===n.title}function ck(n){return wo(e=>{const t=n(e);return t?dr(t).pipe(_t(()=>e)):Tt(e)})}const Eg=new Ze("ROUTES");let lk=(()=>{class n{constructor(t,i){this.injector=t,this.compiler=i,this.componentLoaders=new WeakMap,this.childrenLoaders=new WeakMap}loadComponent(t){if(this.componentLoaders.get(t))return this.componentLoaders.get(t);if(t._loadedComponent)return Tt(t._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(t);const i=ch(t.loadComponent()).pipe(_t(g8),Dr(s=>{this.onLoadEndListener&&this.onLoadEndListener(t),t._loadedComponent=s}),Jw(()=>{this.componentLoaders.delete(t)})),r=new ld(i,()=>new cn).pipe(hc());return this.componentLoaders.set(t,r),r}loadChildren(t,i){if(this.childrenLoaders.get(i))return this.childrenLoaders.get(i);if(i._loadedRoutes)return Tt({routes:i._loadedRoutes,injector:i._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(i);const s=this.loadModuleFactoryOrRoutes(i.loadChildren).pipe(_t(a=>{this.onLoadEndListener&&this.onLoadEndListener(i);let c,u,p=!1;Array.isArray(a)?u=a:(c=a.create(t).injector,u=S5(c.get(Eg,[],tn.Self|tn.Optional)));return{routes:u.map(rk),injector:c}}),Jw(()=>{this.childrenLoaders.delete(i)})),o=new ld(s,()=>new cn).pipe(hc());return this.childrenLoaders.set(i,o),o}loadModuleFactoryOrRoutes(t){return ch(t()).pipe(_t(g8),ur(r=>r instanceof KR||Array.isArray(r)?Tt(r):dr(this.compiler.compileModuleAsync(r))))}}return n.\u0275fac=function(t){return new(t||n)(xe(ts),xe(LP))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function g8(n){return function _te(n){return n&&"object"==typeof n&&"default"in n}(n)?n.default:n}let zS=(()=>{class n{get hasRequestedNavigation(){return 0!==this.navigationId}constructor(){this.currentNavigation=null,this.lastSuccessfulNavigation=null,this.events=new cn,this.configLoader=hn(lk),this.environmentInjector=hn(na),this.urlSerializer=hn(ly),this.rootContexts=hn(my),this.navigationId=0,this.afterPreactivation=()=>Tt(void 0),this.rootComponentType=null,this.configLoader.onLoadEndListener=r=>this.events.next(new iee(r)),this.configLoader.onLoadStartListener=r=>this.events.next(new nee(r))}complete(){this.transitions?.complete()}handleNavigationRequest(t){const i=++this.navigationId;this.transitions?.next({...this.transitions.value,...t,id:i})}setupNavigations(t){return this.transitions=new er({id:0,targetPageId:0,currentUrlTree:t.currentUrlTree,currentRawUrl:t.currentUrlTree,extractedUrl:t.urlHandlingStrategy.extract(t.currentUrlTree),urlAfterRedirects:t.urlHandlingStrategy.extract(t.currentUrlTree),rawUrl:t.currentUrlTree,extras:{},resolve:null,reject:null,promise:Promise.resolve(!0),source:fy,restoredState:null,currentSnapshot:t.routerState.snapshot,targetSnapshot:null,currentRouterState:t.routerState,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.transitions.pipe(Ui(i=>0!==i.id),_t(i=>({...i,extractedUrl:t.urlHandlingStrategy.extract(i.rawUrl)})),wo(i=>{let r=!1,s=!1;return Tt(i).pipe(Dr(o=>{this.currentNavigation={id:o.id,initialUrl:o.rawUrl,extractedUrl:o.extractedUrl,trigger:o.source,extras:o.extras,previousNavigation:this.lastSuccessfulNavigation?{...this.lastSuccessfulNavigation,previousNavigation:null}:null}}),wo(o=>{const a=t.browserUrlTree.toString(),c=!t.navigated||o.extractedUrl.toString()!==a||a!==t.currentUrlTree.toString();if(!c&&"reload"!==(o.extras.onSameUrlNavigation??t.onSameUrlNavigation)){const p="";return this.events.next(new FS(o.id,t.serializeUrl(i.rawUrl),p,0)),t.rawUrlTree=o.rawUrl,o.resolve(null),Fc}if(t.urlHandlingStrategy.shouldProcessUrl(o.rawUrl))return _8(o.source)&&(t.browserUrlTree=o.extractedUrl),Tt(o).pipe(wo(p=>{const g=this.transitions?.getValue();return this.events.next(new KA(p.id,this.urlSerializer.serialize(p.extractedUrl),p.source,p.restoredState)),g!==this.transitions?.getValue()?Fc:Promise.resolve(p)}),function tte(n,e,t,i){return wo(r=>function Qee(n,e,t,i,r){return new ete(n,e,t,i,r).apply()}(n,e,t,r.extractedUrl,i).pipe(_t(s=>({...r,urlAfterRedirects:s}))))}(this.environmentInjector,this.configLoader,this.urlSerializer,t.config),Dr(p=>{this.currentNavigation={...this.currentNavigation,finalUrl:p.urlAfterRedirects},i.urlAfterRedirects=p.urlAfterRedirects}),function dte(n,e,t,i,r){return ur(s=>function rte(n,e,t,i,r,s,o="emptyOnly"){return new ste(n,e,t,i,r,o,s).recognize().pipe(wo(a=>null===a?function ite(n){return new un(e=>e.error(n))}(new nte):Tt(a)))}(n,e,t,s.urlAfterRedirects,i.serialize(s.urlAfterRedirects),i,r).pipe(_t(o=>({...s,targetSnapshot:o}))))}(this.environmentInjector,this.rootComponentType,t.config,this.urlSerializer,t.paramsInheritanceStrategy),Dr(p=>{if(i.targetSnapshot=p.targetSnapshot,"eager"===t.urlUpdateStrategy){if(!p.extras.skipLocationChange){const v=t.urlHandlingStrategy.merge(p.urlAfterRedirects,p.rawUrl);t.setBrowserUrl(v,p)}t.browserUrlTree=p.urlAfterRedirects}const g=new ZQ(p.id,this.urlSerializer.serialize(p.extractedUrl),this.urlSerializer.serialize(p.urlAfterRedirects),p.targetSnapshot);this.events.next(g)}));if(c&&t.urlHandlingStrategy.shouldProcessUrl(t.rawUrlTree)){const{id:p,extractedUrl:g,source:v,restoredState:y,extras:x}=o,T=new KA(p,this.urlSerializer.serialize(g),v,y);this.events.next(T);const N=j5(g,this.rootComponentType).snapshot;return Tt(i={...o,targetSnapshot:N,urlAfterRedirects:g,extras:{...x,skipLocationChange:!1,replaceUrl:!1}})}{const p="";return this.events.next(new FS(o.id,t.serializeUrl(i.extractedUrl),p,1)),t.rawUrlTree=o.rawUrl,o.resolve(null),Fc}}),Dr(o=>{const a=new JQ(o.id,this.urlSerializer.serialize(o.extractedUrl),this.urlSerializer.serialize(o.urlAfterRedirects),o.targetSnapshot);this.events.next(a)}),_t(o=>i={...o,guards:Cee(o.targetSnapshot,o.currentSnapshot,this.rootContexts)}),function Nee(n,e){return ur(t=>{const{targetSnapshot:i,currentSnapshot:r,guards:{canActivateChecks:s,canDeactivateChecks:o}}=t;return 0===o.length&&0===s.length?Tt({...t,guardsResult:!0}):function Bee(n,e,t,i){return dr(n).pipe(ur(r=>function jee(n,e,t,i,r){const s=e&&e.routeConfig?e.routeConfig.canDeactivate:null;return s&&0!==s.length?Tt(s.map(a=>{const c=gy(e)??r,u=wg(a,c);return ch(function Pee(n){return n&&yy(n.canDeactivate)}(u)?u.canDeactivate(n,e,t,i):c.runInContext(()=>u(n,e,t,i))).pipe(ml())})).pipe(Sg()):Tt(!0)}(r.component,r.route,t,e,i)),ml(r=>!0!==r,!0))}(o,i,r,n).pipe(ur(a=>a&&function kee(n){return"boolean"==typeof n}(a)?function Vee(n,e,t,i){return dr(e).pipe(Zu(r=>Rw(function Uee(n,e){return null!==n&&e&&e(new ree(n)),Tt(!0)}(r.route.parent,i),function Hee(n,e){return null!==n&&e&&e(new oee(n)),Tt(!0)}(r.route,i),function Gee(n,e,t){const i=e[e.length-1],s=e.slice(0,e.length-1).reverse().map(o=>function Dee(n){const e=n.routeConfig?n.routeConfig.canActivateChild:null;return e&&0!==e.length?{node:n,guards:e}:null}(o)).filter(o=>null!==o).map(o=>Yv(()=>Tt(o.guards.map(c=>{const u=gy(o.node)??t,p=wg(c,u);return ch(function Ree(n){return n&&yy(n.canActivateChild)}(p)?p.canActivateChild(i,n):u.runInContext(()=>p(i,n))).pipe(ml())})).pipe(Sg())));return Tt(s).pipe(Sg())}(n,r.path,t),function zee(n,e,t){const i=e.routeConfig?e.routeConfig.canActivate:null;if(!i||0===i.length)return Tt(!0);const r=i.map(s=>Yv(()=>{const o=gy(e)??t,a=wg(s,o);return ch(function Fee(n){return n&&yy(n.canActivate)}(a)?a.canActivate(e,n):o.runInContext(()=>a(e,n))).pipe(ml())}));return Tt(r).pipe(Sg())}(n,r.route,t))),ml(r=>!0!==r,!0))}(i,s,n,e):Tt(a)),_t(a=>({...t,guardsResult:a})))})}(this.environmentInjector,o=>this.events.next(o)),Dr(o=>{if(i.guardsResult=o.guardsResult,$f(o.guardsResult))throw K5(0,o.guardsResult);const a=new QQ(o.id,this.urlSerializer.serialize(o.extractedUrl),this.urlSerializer.serialize(o.urlAfterRedirects),o.targetSnapshot,!!o.guardsResult);this.events.next(a)}),Ui(o=>!!o.guardsResult||(t.restoreHistory(o),this.cancelNavigationTransition(o,"",3),!1)),ck(o=>{if(o.guards.canActivateChecks.length)return Tt(o).pipe(Dr(a=>{const c=new eee(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);this.events.next(c)}),wo(a=>{let c=!1;return Tt(a).pipe(function ute(n,e){return ur(t=>{const{targetSnapshot:i,guards:{canActivateChecks:r}}=t;if(!r.length)return Tt(t);let s=0;return dr(r).pipe(Zu(o=>function hte(n,e,t,i){const r=n.routeConfig,s=n._resolve;return void 0!==r?.title&&!p8(r)&&(s[ay]=r.title),function fte(n,e,t,i){const r=function pte(n){return[...Object.keys(n),...Object.getOwnPropertySymbols(n)]}(n);if(0===r.length)return Tt({});const s={};return dr(r).pipe(ur(o=>function mte(n,e,t,i){const r=gy(e)??i,s=wg(n,r);return ch(s.resolve?s.resolve(e,t):r.runInContext(()=>s(e,t)))}(n[o],e,t,i).pipe(ml(),Dr(a=>{s[o]=a}))),UA(1),function SQ(n){return e=>e.lift(new EQ(n))}(s),da(o=>sk(o)?Fc:Pc(o)))}(s,n,e,i).pipe(_t(o=>(n._resolvedData=o,n.data=W5(n,t).resolve,r&&p8(r)&&(n.data[ay]=r.title),null)))}(o.route,i,n,e)),Dr(()=>s++),UA(1),ur(o=>s===r.length?Tt(t):Fc))})}(t.paramsInheritanceStrategy,this.environmentInjector),Dr({next:()=>c=!0,complete:()=>{c||(t.restoreHistory(a),this.cancelNavigationTransition(a,"",2))}}))}),Dr(a=>{const c=new tee(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);this.events.next(c)}))}),ck(o=>{const a=c=>{const u=[];c.routeConfig?.loadComponent&&!c.routeConfig._loadedComponent&&u.push(this.configLoader.loadComponent(c.routeConfig).pipe(Dr(p=>{c.component=p}),_t(()=>{})));for(const p of c.children)u.push(...a(p));return u};return Fw(a(o.targetSnapshot.root)).pipe(xS(),Gr(1))}),ck(()=>this.afterPreactivation()),_t(o=>{const a=function mee(n,e,t){const i=py(n,e._root,t?t._root:void 0);return new G5(i,e)}(t.routeReuseStrategy,o.targetSnapshot,o.currentRouterState);return i={...o,targetRouterState:a}}),Dr(o=>{t.currentUrlTree=o.urlAfterRedirects,t.rawUrlTree=t.urlHandlingStrategy.merge(o.urlAfterRedirects,o.rawUrl),t.routerState=o.targetRouterState,"deferred"===t.urlUpdateStrategy&&(o.extras.skipLocationChange||t.setBrowserUrl(t.rawUrlTree,o),t.browserUrlTree=o.urlAfterRedirects)}),((n,e,t)=>_t(i=>(new Mee(e,i.targetRouterState,i.currentRouterState,t).activate(n),i)))(this.rootContexts,t.routeReuseStrategy,o=>this.events.next(o)),Dr({next:o=>{r=!0,this.lastSuccessfulNavigation=this.currentNavigation,t.navigated=!0,this.events.next(new qf(o.id,this.urlSerializer.serialize(o.extractedUrl),this.urlSerializer.serialize(t.currentUrlTree))),t.titleStrategy?.updateTitle(o.targetRouterState.snapshot),o.resolve(!0)},complete:()=>{r=!0}}),Jw(()=>{r||s||this.cancelNavigationTransition(i,"",1),this.currentNavigation?.id===i.id&&(this.currentNavigation=null)}),da(o=>{if(s=!0,Z5(o)){X5(o)||(t.navigated=!0,t.restoreHistory(i,!0));const a=new IS(i.id,this.urlSerializer.serialize(i.extractedUrl),o.message,o.cancellationCode);if(this.events.next(a),X5(o)){const c=t.urlHandlingStrategy.merge(o.url,t.rawUrlTree),u={skipLocationChange:i.extras.skipLocationChange,replaceUrl:"eager"===t.urlUpdateStrategy||_8(i.source)};t.scheduleNavigation(c,fy,null,u,{resolve:i.resolve,reject:i.reject,promise:i.promise})}else i.resolve(!1)}else{t.restoreHistory(i,!0);const a=new YA(i.id,this.urlSerializer.serialize(i.extractedUrl),o,i.targetSnapshot??void 0);this.events.next(a);try{i.resolve(t.errorHandler(o))}catch(c){i.reject(c)}}return Fc}))}))}cancelNavigationTransition(t,i,r){const s=new IS(t.id,this.urlSerializer.serialize(t.extractedUrl),i,r);this.events.next(s),t.resolve(!1)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function _8(n){return n!==fy}let v8=(()=>{class n{buildTitle(t){let i,r=t.root;for(;void 0!==r;)i=this.getResolvedTitleForRoute(r)??i,r=r.children.find(s=>s.outlet===jn);return i}getResolvedTitleForRoute(t){return t.data[ay]}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return hn(vte)},providedIn:"root"}),n})(),vte=(()=>{class n extends v8{constructor(t){super(),this.title=t}updateTitle(t){const i=this.buildTitle(t);void 0!==i&&this.title.setTitle(i)}}return n.\u0275fac=function(t){return new(t||n)(xe(iO))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})(),yte=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return hn(xte)},providedIn:"root"}),n})();class bte{shouldDetach(e){return!1}store(e,t){}shouldAttach(e){return!1}retrieve(e){return null}shouldReuseRoute(e,t){return e.routeConfig===t.routeConfig}}let xte=(()=>{class n extends bte{}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const GS=new Ze("",{providedIn:"root",factory:()=>({})});let Ste=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:function(){return hn(Ete)},providedIn:"root"}),n})(),Ete=(()=>{class n{shouldProcessUrl(t){return!0}extract(t){return t}merge(t,i){return t}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();function Mte(n){throw n}function Cte(n,e,t){return e.parse("/")}const Dte={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},Tte={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"};let nc=(()=>{class n{get navigationId(){return this.navigationTransitions.navigationId}get browserPageId(){return this.location.getState()?.\u0275routerPageId}get events(){return this.navigationTransitions.events}constructor(){this.disposed=!1,this.currentPageId=0,this.console=hn(G9),this.isNgZoneEnabled=!1,this.options=hn(GS,{optional:!0})||{},this.errorHandler=this.options.errorHandler||Mte,this.malformedUriErrorHandler=this.options.malformedUriErrorHandler||Cte,this.navigated=!1,this.lastSuccessfulId=-1,this.urlHandlingStrategy=hn(Ste),this.routeReuseStrategy=hn(yte),this.urlCreationStrategy=hn(hee),this.titleStrategy=hn(v8),this.onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore",this.paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly",this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.canceledNavigationResolution=this.options.canceledNavigationResolution||"replace",this.config=S5(hn(Eg,{optional:!0})??[]),this.navigationTransitions=hn(zS),this.urlSerializer=hn(ly),this.location=hn(Mv),this.isNgZoneEnabled=hn(Xt)instanceof Xt&&Xt.isInAngularZone(),this.resetConfig(this.config),this.currentUrlTree=new lh,this.rawUrlTree=this.currentUrlTree,this.browserUrlTree=this.currentUrlTree,this.routerState=j5(this.currentUrlTree,null),this.navigationTransitions.setupNavigations(this).subscribe(t=>{this.lastSuccessfulId=t.id,this.currentPageId=t.targetPageId},t=>{this.console.warn(`Unhandled Navigation Error: ${t}`)})}resetRootComponentType(t){this.routerState.root.component=t,this.navigationTransitions.rootComponentType=t}initialNavigation(){if(this.setUpLocationChangeListener(),!this.navigationTransitions.hasRequestedNavigation){const t=this.location.getState();this.navigateToSyncWithBrowser(this.location.path(!0),fy,t)}}setUpLocationChangeListener(){this.locationSubscription||(this.locationSubscription=this.location.subscribe(t=>{const i="popstate"===t.type?"popstate":"hashchange";"popstate"===i&&setTimeout(()=>{this.navigateToSyncWithBrowser(t.url,i,t.state)},0)}))}navigateToSyncWithBrowser(t,i,r){const s={replaceUrl:!0},o=r?.navigationId?r:null;if(r){const c={...r};delete c.navigationId,delete c.\u0275routerPageId,0!==Object.keys(c).length&&(s.state=c)}const a=this.parseUrl(t);this.scheduleNavigation(a,i,o,s)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}resetConfig(t){this.config=t.map(rk),this.navigated=!1,this.lastSuccessfulId=-1}ngOnDestroy(){this.dispose()}dispose(){this.navigationTransitions.complete(),this.locationSubscription&&(this.locationSubscription.unsubscribe(),this.locationSubscription=void 0),this.disposed=!0}createUrlTree(t,i={}){const{relativeTo:r,queryParams:s,fragment:o,queryParamsHandling:a,preserveFragment:c}=i,u=c?this.currentUrlTree.fragment:o;let p=null;switch(a){case"merge":p={...this.currentUrlTree.queryParams,...s};break;case"preserve":p=this.currentUrlTree.queryParams;break;default:p=s||null}return null!==p&&(p=this.removeEmptyProps(p)),this.urlCreationStrategy.createUrlTree(r,this.routerState,this.currentUrlTree,t,p,u??null)}navigateByUrl(t,i={skipLocationChange:!1}){const r=$f(t)?t:this.parseUrl(t),s=this.urlHandlingStrategy.merge(r,this.rawUrlTree);return this.scheduleNavigation(s,fy,null,i)}navigate(t,i={skipLocationChange:!1}){return function Ate(n){for(let e=0;e{const s=t[r];return null!=s&&(i[r]=s),i},{})}scheduleNavigation(t,i,r,s,o){if(this.disposed)return Promise.resolve(!1);let a,c,u,p;return o?(a=o.resolve,c=o.reject,u=o.promise):u=new Promise((g,v)=>{a=g,c=v}),p="computed"===this.canceledNavigationResolution?r&&r.\u0275routerPageId?r.\u0275routerPageId:s.replaceUrl||s.skipLocationChange?this.browserPageId??0:(this.browserPageId??0)+1:0,this.navigationTransitions.handleNavigationRequest({targetPageId:p,source:i,restoredState:r,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:t,extras:s,resolve:a,reject:c,promise:u,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),u.catch(g=>Promise.reject(g))}setBrowserUrl(t,i){const r=this.urlSerializer.serialize(t),s={...i.extras.state,...this.generateNgRouterState(i.id,i.targetPageId)};this.location.isCurrentPathEqualTo(r)||i.extras.replaceUrl?this.location.replaceState(r,"",s):this.location.go(r,"",s)}restoreHistory(t,i=!1){if("computed"===this.canceledNavigationResolution){const r=this.currentPageId-t.targetPageId;"popstate"!==t.source&&"eager"!==this.urlUpdateStrategy&&this.currentUrlTree!==this.getCurrentNavigation()?.finalUrl||0===r?this.currentUrlTree===this.getCurrentNavigation()?.finalUrl&&0===r&&(this.resetState(t),this.browserUrlTree=t.currentUrlTree,this.resetUrlToCurrentUrlTree()):this.location.historyGo(r)}else"replace"===this.canceledNavigationResolution&&(i&&this.resetState(t),this.resetUrlToCurrentUrlTree())}resetState(t){this.routerState=t.currentRouterState,this.currentUrlTree=t.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,t.rawUrl)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(t,i){return"computed"===this.canceledNavigationResolution?{navigationId:t,\u0275routerPageId:i}:{navigationId:t}}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();class y8{}let Fte=(()=>{class n{constructor(t,i,r,s,o){this.router=t,this.injector=r,this.preloadingStrategy=s,this.loader=o}setUpPreloading(){this.subscription=this.router.events.pipe(Ui(t=>t instanceof qf),Zu(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(t,i){const r=[];for(const s of i){s.providers&&!s._injector&&(s._injector=O1(s.providers,t,`Route: ${s.path}`));const o=s._injector??t,a=s._loadedInjector??o;s.loadChildren&&!s._loadedRoutes&&void 0===s.canLoad||s.loadComponent&&!s._loadedComponent?r.push(this.preloadConfig(o,s)):(s.children||s._loadedRoutes)&&r.push(this.processRoutes(a,s.children??s._loadedRoutes))}return dr(r).pipe(Ml())}preloadConfig(t,i){return this.preloadingStrategy.preload(i,()=>{let r;r=i.loadChildren&&void 0===i.canLoad?this.loader.loadChildren(t,i):Tt(null);const s=r.pipe(ur(o=>null===o?Tt(void 0):(i._loadedRoutes=o.routes,i._loadedInjector=o.injector,this.processRoutes(o.injector??t,o.routes))));return i.loadComponent&&!i._loadedComponent?dr([s,this.loader.loadComponent(i)]).pipe(Ml()):s})}}return n.\u0275fac=function(t){return new(t||n)(xe(nc),xe(LP),xe(na),xe(y8),xe(lk))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();const hk=new Ze("");let b8=(()=>{class n{constructor(t,i,r,s,o={}){this.urlSerializer=t,this.transitions=i,this.viewportScroller=r,this.zone=s,this.options=o,this.lastId=0,this.lastSource="imperative",this.restoredId=0,this.store={},o.scrollPositionRestoration=o.scrollPositionRestoration||"disabled",o.anchorScrolling=o.anchorScrolling||"disabled"}init(){"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.transitions.events.subscribe(t=>{t instanceof KA?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=t.navigationTrigger,this.restoredId=t.restoredState?t.restoredState.navigationId:0):t instanceof qf&&(this.lastId=t.id,this.scheduleScrollEvent(t,this.urlSerializer.parse(t.urlAfterRedirects).fragment))})}consumeScrollEvents(){return this.transitions.events.subscribe(t=>{t instanceof U5&&(t.position?"top"===this.options.scrollPositionRestoration?this.viewportScroller.scrollToPosition([0,0]):"enabled"===this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition(t.position):t.anchor&&"enabled"===this.options.anchorScrolling?this.viewportScroller.scrollToAnchor(t.anchor):"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(t,i){this.zone.runOutsideAngular(()=>{setTimeout(()=>{this.zone.run(()=>{this.transitions.events.next(new U5(t,"popstate"===this.lastSource?this.store[this.restoredId]:null,i))})},0)})}ngOnDestroy(){this.routerEventsSubscription?.unsubscribe(),this.scrollEventsSubscription?.unsubscribe()}}return n.\u0275fac=function(t){Gl()},n.\u0275prov=Je({token:n,factory:n.\u0275fac}),n})();var ic=(()=>((ic=ic||{})[ic.COMPLETE=0]="COMPLETE",ic[ic.FAILED=1]="FAILED",ic[ic.REDIRECTING=2]="REDIRECTING",ic))();const Mg=!1;function dh(n,e){return{\u0275kind:n,\u0275providers:e}}const fk=new Ze("",{providedIn:"root",factory:()=>!1});function w8(){const n=hn(ts);return e=>{const t=n.get(Jm);if(e!==t.components[0])return;const i=n.get(nc),r=n.get(S8);1===n.get(pk)&&i.initialNavigation(),n.get(E8,null,tn.Optional)?.setUpPreloading(),n.get(hk,null,tn.Optional)?.init(),i.resetRootComponentType(t.componentTypes[0]),r.closed||(r.next(),r.unsubscribe())}}const S8=new Ze(Mg?"bootstrap done indicator":"",{factory:()=>new cn}),pk=new Ze(Mg?"initial navigation":"",{providedIn:"root",factory:()=>1});function Nte(){let n=[];return n=Mg?[{provide:ym,multi:!0,useFactory:()=>{const e=hn(nc);return()=>e.events.subscribe(t=>{console.group?.(`Router Event: ${t.constructor.name}`),console.log(function cee(n){if(!("type"in n))return`Unknown Router Event: ${n.constructor.name}`;switch(n.type){case 14:return`ActivationEnd(path: '${n.snapshot.routeConfig?.path||""}')`;case 13:return`ActivationStart(path: '${n.snapshot.routeConfig?.path||""}')`;case 12:return`ChildActivationEnd(path: '${n.snapshot.routeConfig?.path||""}')`;case 11:return`ChildActivationStart(path: '${n.snapshot.routeConfig?.path||""}')`;case 8:return`GuardsCheckEnd(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}', state: ${n.state}, shouldActivate: ${n.shouldActivate})`;case 7:return`GuardsCheckStart(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}', state: ${n.state})`;case 2:return`NavigationCancel(id: ${n.id}, url: '${n.url}')`;case 16:return`NavigationSkipped(id: ${n.id}, url: '${n.url}')`;case 1:return`NavigationEnd(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}')`;case 3:return`NavigationError(id: ${n.id}, url: '${n.url}', error: ${n.error})`;case 0:return`NavigationStart(id: ${n.id}, url: '${n.url}')`;case 6:return`ResolveEnd(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}', state: ${n.state})`;case 5:return`ResolveStart(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}', state: ${n.state})`;case 10:return`RouteConfigLoadEnd(path: ${n.route.path})`;case 9:return`RouteConfigLoadStart(path: ${n.route.path})`;case 4:return`RoutesRecognized(id: ${n.id}, url: '${n.url}', urlAfterRedirects: '${n.urlAfterRedirects}', state: ${n.state})`;case 15:return`Scroll(anchor: '${n.anchor}', position: '${n.position?`${n.position[0]}, ${n.position[1]}`:null}')`}}(t)),console.log(t),console.groupEnd?.()})}}]:[],dh(1,n)}const E8=new Ze(Mg?"router preloader":"");function Bte(n){return dh(0,[{provide:E8,useExisting:Fte},{provide:y8,useExisting:n}])}const xy=!1,M8=new Ze(xy?"router duplicate forRoot guard":"ROUTER_FORROOT_GUARD"),Vte=[Mv,{provide:ly,useClass:zA},nc,my,{provide:Kf,useFactory:function x8(n){return n.routerState.root},deps:[nc]},lk,xy?{provide:fk,useValue:!0}:[]];function Hte(){return new GP("Router",nc)}let C8=(()=>{class n{constructor(t){}static forRoot(t,i){return{ngModule:n,providers:[Vte,xy&&i?.enableTracing?Nte().\u0275providers:[],{provide:Eg,multi:!0,useValue:t},{provide:M8,useFactory:jte,deps:[[nc,new ba,new Pl]]},{provide:GS,useValue:i||{}},i?.useHash?{provide:Ff,useClass:k7}:{provide:Ff,useClass:h3},{provide:hk,useFactory:()=>{const n=hn(jz),e=hn(Xt),t=hn(GS),i=hn(zS),r=hn(ly);return t.scrollOffset&&n.setOffset(t.scrollOffset),new b8(r,i,n,e,t)}},i?.preloadingStrategy?Bte(i.preloadingStrategy).\u0275providers:[],{provide:GP,multi:!0,useFactory:Hte},i?.initialNavigation?Wte(i):[],[{provide:D8,useFactory:w8},{provide:OP,multi:!0,useExisting:D8}]]}}static forChild(t){return{ngModule:n,providers:[{provide:Eg,multi:!0,useValue:t}]}}}return n.\u0275fac=function(t){return new(t||n)(xe(M8,8))},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[nk]}),n})();function jte(n){if(xy&&n)throw new Ue(4007,"The Router was provided more than once. This can happen if 'forRoot' is used outside of the root injector. Lazy loaded modules should use RouterModule.forChild() instead.");return"guarded"}function Wte(n){return["disabled"===n.initialNavigation?dh(3,[{provide:V1,multi:!0,useFactory:()=>{const e=hn(nc);return()=>{e.setUpLocationChangeListener()}}},{provide:pk,useValue:2}]).\u0275providers:[],"enabledBlocking"===n.initialNavigation?dh(2,[{provide:pk,useValue:0},{provide:V1,multi:!0,deps:[ts],useFactory:e=>{const t=e.get(T7,Promise.resolve());return()=>t.then(()=>new Promise(i=>{const r=e.get(nc),s=e.get(S8);(function Rte(n,e){n.events.pipe(Ui(t=>t instanceof qf||t instanceof IS||t instanceof YA||t instanceof FS),_t(t=>t instanceof qf||t instanceof FS?ic.COMPLETE:t instanceof IS&&(0===t.code||1===t.code)?ic.REDIRECTING:ic.FAILED),Ui(t=>t!==ic.REDIRECTING),Gr(1)).subscribe(()=>{e()})})(r,()=>{i(!0)}),e.get(zS).afterPreactivation=()=>(i(!0),s.closed?Tt(void 0):s),r.initialNavigation()}))}}]).\u0275providers:[]]}const D8=new Ze(xy?"Router Initializer":"");class qd{constructor(e,t,i){this.document=e,this.oAuthService=t,this.route=i,this.hasValidAccessToken$=new er(!1),this.oAuthService.setStorage(new Wd),this.oAuthService.configure({issuer:"https://www.bungie.net/en/OAuth/Authorize",loginUrl:"https://www.bungie.net/en/OAuth/Authorize",tokenEndpoint:"https://www.bungie.net/Platform/App/OAuth/token/",redirectUri:oy_bungie_redirect,clientId:oy_bungie_clientId,responseType:"code",scope:""}),this.oAuthService.tokenValidationHandler=new vQ,this.tryLogin()}tryLogin(){var e=this;return fl(function*(){e.route.queryParams.subscribe(function(){var t=fl(function*(i){i.state&&i.state===localStorage.getItem("bungie-nonce")&&(yield e.oAuthService.tryLoginCodeFlow()),e.oAuthService.hasValidAccessToken()&&(e.oAuthService.setupAutomaticSilentRefresh(),e.hasValidAccessToken$.next(!0))});return function(i){return t.apply(this,arguments)}}())})()}login(){var e=this;return fl(function*(){yield e.oAuthService.createAndSaveNonce(),e.document.location.href=`https://www.bungie.net/en/OAuth/Authorize?response_type=code&client_id=${oy_bungie_clientId}&state=${localStorage.getItem("bungie-nonce")}`})()}logout(){this.oAuthService.logOut(),this.hasValidAccessToken$.next(!1)}}function qte(n,e){}qd.\u0275fac=function(e){return new(e||qd)(xe(Mn),xe(y5),xe(Kf))},qd.\u0275prov=Je({token:qd,factory:qd.\u0275fac,providedIn:"root"});const Kte={bottomSheetState:fg("state",[sh("void, hidden",la({transform:"translateY(100%)"})),sh("visible",la({transform:"translateY(0%)"})),Xl("visible => void, visible => hidden",Yw([zd(`${XL.COMPLEX} ${YL.ACCELERATION_CURVE}`),Jv("@*",Zv(),{optional:!0})])),Xl("void => visible",Yw([zd(`${XL.EXITING} ${YL.DECELERATION_CURVE}`),Jv("@*",Zv(),{optional:!0})]))])};let Yte=(()=>{class n extends JT{constructor(t,i,r,s,o,a,c,u,p,g){super(t,i,r,s,o,a,c,g),this._changeDetectorRef=p,this._animationState="void",this._animationStateChanged=new Pn,this._breakpointSubscription=u.observe([lg_Medium,lg_Large,"(min-width: 1920px)"]).subscribe(()=>{this._toggleClass("mat-bottom-sheet-container-medium",u.isMatched(lg_Medium)),this._toggleClass("mat-bottom-sheet-container-large",u.isMatched(lg_Large)),this._toggleClass("mat-bottom-sheet-container-xlarge",u.isMatched("(min-width: 1920px)"))})}enter(){this._destroyed||(this._animationState="visible",this._changeDetectorRef.detectChanges())}exit(){this._destroyed||(this._animationState="hidden",this._changeDetectorRef.markForCheck())}ngOnDestroy(){super.ngOnDestroy(),this._breakpointSubscription.unsubscribe(),this._destroyed=!0}_onAnimationDone(t){"visible"===t.toState&&this._trapFocus(),this._animationStateChanged.emit(t)}_onAnimationStart(t){this._animationStateChanged.emit(t)}_captureInitialFocus(){}_toggleClass(t,i){this._elementRef.nativeElement.classList.toggle(t,i)}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Lw),ie(Mn,8),ie(Xv),ie(Gv),ie(Xt),ie(hg),ie(FL),ie(aa),ie(Vf))},n.\u0275cmp=Ln({type:n,selectors:[["mat-bottom-sheet-container"]],hostAttrs:["tabindex","-1",1,"mat-bottom-sheet-container"],hostVars:4,hostBindings:function(t,i){1&t&&OC("@state.start",function(s){return i._onAnimationStart(s)})("@state.done",function(s){return i._onAnimationDone(s)}),2&t&&(Di("role",i._config.role)("aria-modal",i._config.ariaModal)("aria-label",i._config.ariaLabel),UC("@state",i._animationState))},features:[Z],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(t,i){1&t&&mt(0,qte,0,0,"ng-template",0)},dependencies:[$w],styles:[".mat-bottom-sheet-container{padding:8px 16px;min-width:100vw;box-sizing:border-box;display:block;outline:0;max-height:80vh;overflow:auto}.cdk-high-contrast-active .mat-bottom-sheet-container{outline:1px solid}.mat-bottom-sheet-container-xlarge,.mat-bottom-sheet-container-large,.mat-bottom-sheet-container-medium{border-top-left-radius:4px;border-top-right-radius:4px}.mat-bottom-sheet-container-medium{min-width:384px;max-width:calc(100vw - 128px)}.mat-bottom-sheet-container-large{min-width:512px;max-width:calc(100vw - 256px)}.mat-bottom-sheet-container-xlarge{min-width:576px;max-width:calc(100vw - 384px)}"],encapsulation:2,data:{animation:[Kte.bottomSheetState]}}),n})(),T8=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[UN,rr,Kv,rr]}),n})();const Xte=new Ze("MatBottomSheetData");class Zte{constructor(){this.data=null,this.hasBackdrop=!0,this.disableClose=!1,this.ariaLabel=null,this.ariaModal=!0,this.closeOnNavigation=!0,this.autoFocus="dialog",this.restoreFocus=!0}}class mk{get instance(){return this._ref.componentInstance}constructor(e,t,i){this._ref=e,this._afterOpened=new cn,this.containerInstance=i,this.disableClose=t.disableClose,i._animationStateChanged.pipe(Ui(r=>"done"===r.phaseName&&"visible"===r.toState),Gr(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),i._animationStateChanged.pipe(Ui(r=>"done"===r.phaseName&&"hidden"===r.toState),Gr(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._ref.close(this._result)}),e.overlayRef.detachments().subscribe(()=>{this._ref.close(this._result)}),fa(this.backdropClick(),this.keydownEvents().pipe(Ui(r=>27===r.keyCode))).subscribe(r=>{!this.disableClose&&("keydown"!==r.type||!ql(r))&&(r.preventDefault(),this.dismiss())})}dismiss(e){this.containerInstance&&(this.containerInstance._animationStateChanged.pipe(Ui(t=>"start"===t.phaseName),Gr(1)).subscribe(t=>{this._closeFallbackTimeout=setTimeout(()=>{this._ref.close(this._result)},t.totalTime+100),this._ref.overlayRef.detachBackdrop()}),this._result=e,this.containerInstance.exit(),this.containerInstance=null)}afterDismissed(){return this._ref.closed}afterOpened(){return this._afterOpened}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}}const Jte=new Ze("mat-bottom-sheet-default-options");let Qte=(()=>{class n{get _openedBottomSheetRef(){const t=this._parentBottomSheet;return t?t._openedBottomSheetRef:this._bottomSheetRefAtThisLevel}set _openedBottomSheetRef(t){this._parentBottomSheet?this._parentBottomSheet._openedBottomSheetRef=t:this._bottomSheetRefAtThisLevel=t}constructor(t,i,r,s){this._overlay=t,this._parentBottomSheet=r,this._defaultOptions=s,this._bottomSheetRefAtThisLevel=null,this._dialog=i.get(eA)}open(t,i){const r={...this._defaultOptions||new Zte,...i};let s;return this._dialog.open(t,{...r,disableClose:!0,closeOnOverlayDetachments:!1,maxWidth:"100%",container:Yte,scrollStrategy:r.scrollStrategy||this._overlay.scrollStrategies.block(),positionStrategy:this._overlay.position().global().centerHorizontally().bottom("0"),templateContext:()=>({bottomSheetRef:s}),providers:(o,a,c)=>(s=new mk(o,r,c),[{provide:mk,useValue:s},{provide:Xte,useValue:r.data}])}),s.afterDismissed().subscribe(()=>{this._openedBottomSheetRef===s&&(this._openedBottomSheetRef=null)}),this._openedBottomSheetRef?(this._openedBottomSheetRef.afterDismissed().subscribe(()=>s.containerInstance?.enter()),this._openedBottomSheetRef.dismiss()):s.containerInstance.enter(),this._openedBottomSheetRef=s,s}dismiss(t){this._openedBottomSheetRef&&this._openedBottomSheetRef.dismiss(t)}ngOnDestroy(){this._bottomSheetRefAtThisLevel&&this._bottomSheetRefAtThisLevel.dismiss()}}return n.\u0275fac=function(t){return new(t||n)(xe(hl),xe(ts),xe(n,12),xe(Jte,8))},n.\u0275prov=Je({token:n,factory:n.\u0275fac,providedIn:T8}),n})(),ene=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[rr,rr]}),n})();const A8=["*"],I8=["unscopedContent"],tne=["text"],nne=[[["","matListItemAvatar",""],["","matListItemIcon",""]],[["","matListItemTitle",""]],[["","matListItemLine",""]],"*",[["","matListItemMeta",""]],[["mat-divider"]]],ine=["[matListItemAvatar],[matListItemIcon]","[matListItemTitle]","[matListItemLine]","*","[matListItemMeta]","mat-divider"],F8=new Ze("ListOption");let gk=(()=>{class n{constructor(t){this._elementRef=t}}return n.\u0275fac=function(t){return new(t||n)(ie(_n))},n.\u0275dir=ut({type:n,selectors:[["","matListItemTitle",""]],hostAttrs:[1,"mat-mdc-list-item-title","mdc-list-item__primary-text"]}),n})(),_k=(()=>{class n{constructor(t){this._elementRef=t}}return n.\u0275fac=function(t){return new(t||n)(ie(_n))},n.\u0275dir=ut({type:n,selectors:[["","matListItemLine",""]],hostAttrs:[1,"mat-mdc-list-item-line","mdc-list-item__secondary-text"]}),n})(),xne=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,selectors:[["","matListItemMeta",""]],hostAttrs:[1,"mat-mdc-list-item-meta","mdc-list-item__end"]}),n})(),R8=(()=>{class n{constructor(t){this._listOption=t}_isAlignedAtStart(){return!this._listOption||"after"===this._listOption?._getTogglePosition()}}return n.\u0275fac=function(t){return new(t||n)(ie(F8,8))},n.\u0275dir=ut({type:n,hostVars:4,hostBindings:function(t,i){2&t&&hi("mdc-list-item__start",i._isAlignedAtStart())("mdc-list-item__end",!i._isAlignedAtStart())}}),n})(),P8=(()=>{class n extends R8{}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275dir=ut({type:n,selectors:[["","matListItemAvatar",""]],hostAttrs:[1,"mat-mdc-list-item-avatar"],features:[Z]}),n})(),wne=(()=>{class n extends R8{}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275dir=ut({type:n,selectors:[["","matListItemIcon",""]],hostAttrs:[1,"mat-mdc-list-item-icon"],features:[Z]}),n})();const Sne=new Ze("MAT_LIST_CONFIG");let Cg=(()=>{class n{constructor(){this._isNonInteractive=!0,this._disableRipple=!1,this._disabled=!1,this._defaultOptions=hn(Sne,{optional:!0})}get disableRipple(){return this._disableRipple}set disableRipple(t){this._disableRipple=bi(t)}get disabled(){return this._disabled}set disabled(t){this._disabled=bi(t)}}return n.\u0275fac=function(t){return new(t||n)},n.\u0275dir=ut({type:n,hostVars:1,hostBindings:function(t,i){2&t&&Di("aria-disabled",i.disabled)},inputs:{disableRipple:"disableRipple",disabled:"disabled"}}),n})(),vk=(()=>{class n{set lines(t){this._explicitLines=ih(t,null),this._updateItemLines(!1)}get disableRipple(){return this.disabled||this._disableRipple||this._noopAnimations||!!this._listBase?.disableRipple}set disableRipple(t){this._disableRipple=bi(t)}get disabled(){return this._disabled||!!this._listBase?.disabled}set disabled(t){this._disabled=bi(t)}get rippleDisabled(){return this.disableRipple||!!this.rippleConfig.disabled}constructor(t,i,r,s,o,a){this._elementRef=t,this._ngZone=i,this._listBase=r,this._platform=s,this._explicitLines=null,this._disableRipple=!1,this._disabled=!1,this._subscriptions=new Tn,this._rippleRenderer=null,this._hasUnscopedTextContent=!1,this.rippleConfig=o||{},this._hostElement=this._elementRef.nativeElement,this._isButtonElement="button"===this._hostElement.nodeName.toLowerCase(),this._noopAnimations="NoopAnimations"===a,r&&!r._isNonInteractive&&this._initInteractiveListItem(),this._isButtonElement&&!this._hostElement.hasAttribute("type")&&this._hostElement.setAttribute("type","button")}ngAfterViewInit(){this._monitorProjectedLinesAndTitle(),this._updateItemLines(!0)}ngOnDestroy(){this._subscriptions.unsubscribe(),null!==this._rippleRenderer&&this._rippleRenderer._removeTriggerEvents()}_hasIconOrAvatar(){return!(!this._avatars.length&&!this._icons.length)}_initInteractiveListItem(){this._hostElement.classList.add("mat-mdc-list-item-interactive"),this._rippleRenderer=new ug(this,this._ngZone,this._hostElement,this._platform),this._rippleRenderer.setupTriggerEvents(this._hostElement)}_monitorProjectedLinesAndTitle(){this._ngZone.runOutsideAngular(()=>{this._subscriptions.add(fa(this._lines.changes,this._titles.changes).subscribe(()=>this._updateItemLines(!1)))})}_updateItemLines(t){if(!this._lines||!this._titles||!this._unscopedContent)return;t&&this._checkDomForUnscopedTextContent();const i=this._explicitLines??this._inferLinesFromContent(),r=this._unscopedContent.nativeElement;if(this._hostElement.classList.toggle("mat-mdc-list-item-single-line",i<=1),this._hostElement.classList.toggle("mdc-list-item--with-one-line",i<=1),this._hostElement.classList.toggle("mdc-list-item--with-two-lines",2===i),this._hostElement.classList.toggle("mdc-list-item--with-three-lines",3===i),this._hasUnscopedTextContent){const s=0===this._titles.length&&1===i;r.classList.toggle("mdc-list-item__primary-text",s),r.classList.toggle("mdc-list-item__secondary-text",!s)}else r.classList.remove("mdc-list-item__primary-text"),r.classList.remove("mdc-list-item__secondary-text")}_inferLinesFromContent(){let t=this._titles.length+this._lines.length;return this._hasUnscopedTextContent&&(t+=1),t}_checkDomForUnscopedTextContent(){this._hasUnscopedTextContent=Array.from(this._unscopedContent.nativeElement.childNodes).filter(t=>t.nodeType!==t.COMMENT_NODE).some(t=>!(!t.textContent||!t.textContent.trim()))}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Xt),ie(Cg,8),ie(as),ie(Vw,8),ie(bo,8))},n.\u0275dir=ut({type:n,contentQueries:function(t,i,r){if(1&t&&(is(r,P8,4),is(r,wne,4)),2&t){let s;Yn(s=Xn())&&(i._avatars=s),Yn(s=Xn())&&(i._icons=s)}},hostVars:4,hostBindings:function(t,i){2&t&&(Di("aria-disabled",i.disabled)("disabled",i._isButtonElement&&i.disabled||null),hi("mdc-list-item--disabled",i.disabled))},inputs:{lines:"lines",disableRipple:"disableRipple",disabled:"disabled"}}),n})(),Ene=(()=>{class n extends vk{get activated(){return this._activated}set activated(t){this._activated=bi(t)}constructor(t,i,r,s,o,a){super(t,i,r,s,o,a),this._activated=!1}_getAriaCurrent(){return"A"===this._hostElement.nodeName&&this._activated?"page":null}}return n.\u0275fac=function(t){return new(t||n)(ie(_n),ie(Xt),ie(Cg,8),ie(as),ie(Vw,8),ie(bo,8))},n.\u0275cmp=Ln({type:n,selectors:[["mat-list-item"],["a","mat-list-item",""],["button","mat-list-item",""]],contentQueries:function(t,i,r){if(1&t&&(is(r,_k,5),is(r,gk,5),is(r,xne,5)),2&t){let s;Yn(s=Xn())&&(i._lines=s),Yn(s=Xn())&&(i._titles=s),Yn(s=Xn())&&(i._meta=s)}},viewQuery:function(t,i){if(1&t&&(zr(I8,5),zr(tne,5)),2&t){let r;Yn(r=Xn())&&(i._unscopedContent=r.first),Yn(r=Xn())&&(i._itemText=r.first)}},hostAttrs:[1,"mat-mdc-list-item","mdc-list-item"],hostVars:11,hostBindings:function(t,i){2&t&&(Di("aria-current",i._getAriaCurrent()),hi("mdc-list-item--activated",i.activated)("mdc-list-item--with-leading-avatar",0!==i._avatars.length)("mdc-list-item--with-leading-icon",0!==i._icons.length)("mdc-list-item--with-trailing-meta",0!==i._meta.length)("_mat-animation-noopable",i._noopAnimations))},inputs:{activated:"activated"},exportAs:["matListItem"],features:[Z],ngContentSelectors:ine,decls:10,vars:0,consts:[[1,"mdc-list-item__content"],[1,"mat-mdc-list-item-unscoped-content",3,"cdkObserveContent"],["unscopedContent",""],[1,"mat-mdc-focus-indicator"]],template:function(t,i){1&t&&(Hs(nne),En(0),ke(1,"span",0),En(2,1),En(3,2),ke(4,"span",1,2),Gn("cdkObserveContent",function(){return i._updateItemLines(!0)}),En(6,3),Ne()(),En(7,4),En(8,5),qt(9,"div",3))},dependencies:[IT],encapsulation:2,changeDetection:0}),n})(),Cne=(()=>{class n extends Cg{constructor(){super(...arguments),this._isNonInteractive=!1}}return n.\u0275fac=function(){let e;return function(i){return(e||(e=or(n)))(i||n)}}(),n.\u0275cmp=Ln({type:n,selectors:[["mat-nav-list"]],hostAttrs:["role","navigation",1,"mat-mdc-nav-list","mat-mdc-list-base","mdc-list"],exportAs:["matNavList"],features:[Oi([{provide:Cg,useExisting:n}]),Z],ngContentSelectors:A8,decls:1,vars:0,template:function(t,i){1&t&&(Hs(),En(0))},styles:['@media screen and (forced-colors: active),(-ms-high-contrast: active){.mdc-list-divider::after{content:"";display:block;border-bottom-width:1px;border-bottom-style:solid}}.mdc-list{margin:0;padding:8px 0;list-style-type:none}.mdc-list:focus{outline:none}.mdc-list-item__wrapper{display:block}.mdc-list-item{display:flex;position:relative;align-items:center;justify-content:flex-start;overflow:hidden;padding:0;align-items:stretch;cursor:pointer}.mdc-list-item:focus{outline:none}.mdc-list-item.mdc-list-item--with-one-line{height:48px}.mdc-list-item.mdc-list-item--with-two-lines{height:64px}.mdc-list-item.mdc-list-item--with-three-lines{height:88px}.mdc-list-item.mdc-list-item--with-one-line .mdc-list-item__start{align-self:center;margin-top:0}.mdc-list-item.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:16px}.mdc-list-item.mdc-list-item--with-three-lines .mdc-list-item__start{align-self:flex-start;margin-top:16px}.mdc-list-item.mdc-list-item--with-one-line .mdc-list-item__end{align-self:center;margin-top:0}.mdc-list-item.mdc-list-item--with-two-lines .mdc-list-item__end{align-self:center;margin-top:0}.mdc-list-item.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:16px}.mdc-list-item.mdc-list-item--disabled,.mdc-list-item.mdc-list-item--non-interactive{cursor:auto}.mdc-list-item:not(.mdc-list-item--selected):focus::before,.mdc-list-item.mdc-ripple-upgraded--background-focused::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-list-item:not(.mdc-list-item--selected):focus::before,.mdc-list-item.mdc-ripple-upgraded--background-focused::before{border-color:CanvasText}}.mdc-list-item.mdc-list-item--selected::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:3px double rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-list-item.mdc-list-item--selected::before{border-color:CanvasText}}.mdc-list-item.mdc-list-item--selected:focus::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:3px solid rgba(0,0,0,0);border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-list-item.mdc-list-item--selected:focus::before{border-color:CanvasText}}a.mdc-list-item{color:inherit;text-decoration:none}.mdc-list-item__start{fill:currentColor;flex-shrink:0;pointer-events:none}.mdc-list-item__end{flex-shrink:0;pointer-events:none}.mdc-list-item__content{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;align-self:center;flex:1;pointer-events:none}.mdc-list-item--with-two-lines .mdc-list-item__content,.mdc-list-item--with-three-lines .mdc-list-item__content{align-self:stretch}.mdc-list-item__content[for]{pointer-events:none}.mdc-list-item__primary-text{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.mdc-list-item--with-two-lines .mdc-list-item__primary-text,.mdc-list-item--with-three-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before,.mdc-list-item--with-three-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after,.mdc-list-item--with-three-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item__secondary-text{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;display:block;margin-top:0;line-height:normal}.mdc-list-item__secondary-text::before{display:inline-block;width:0;height:20px;content:"";vertical-align:0}.mdc-list-item--with-three-lines .mdc-list-item__secondary-text{white-space:normal;line-height:20px}.mdc-list-item--with-overline .mdc-list-item__secondary-text{white-space:nowrap;line-height:auto}.mdc-list-item__overline-text{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:24px;content:"";vertical-align:0}.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-three-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-three-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-three-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-avatar.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-avatar.mdc-list-item,.mdc-list-item--with-leading-avatar.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-avatar .mdc-list-item__start{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-leading-avatar .mdc-list-item__start,.mdc-list-item--with-leading-avatar .mdc-list-item__start[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-avatar.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-avatar.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-avatar .mdc-list-item__start{border-radius:50%}.mdc-list-item--with-leading-icon.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-icon.mdc-list-item,.mdc-list-item--with-leading-icon.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-icon .mdc-list-item__start{margin-left:16px;margin-right:32px}[dir=rtl] .mdc-list-item--with-leading-icon .mdc-list-item__start,.mdc-list-item--with-leading-icon .mdc-list-item__start[dir=rtl]{margin-left:32px;margin-right:16px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-icon.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-icon.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-thumbnail.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-thumbnail.mdc-list-item,.mdc-list-item--with-leading-thumbnail.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-thumbnail .mdc-list-item__start{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-leading-thumbnail .mdc-list-item__start,.mdc-list-item--with-leading-thumbnail .mdc-list-item__start[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-thumbnail.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-image.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-image.mdc-list-item,.mdc-list-item--with-leading-image.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-image .mdc-list-item__start{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-leading-image .mdc-list-item__start,.mdc-list-item--with-leading-image .mdc-list-item__start[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-image.mdc-list-item--with-one-line{height:72px}.mdc-list-item--with-leading-image.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:8px}.mdc-list-item--with-leading-video.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-video.mdc-list-item,.mdc-list-item--with-leading-video.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-video .mdc-list-item__start{margin-left:0;margin-right:16px}[dir=rtl] .mdc-list-item--with-leading-video .mdc-list-item__start,.mdc-list-item--with-leading-video .mdc-list-item__start[dir=rtl]{margin-left:16px;margin-right:0}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-video.mdc-list-item--with-one-line{height:72px}.mdc-list-item--with-leading-video.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-checkbox.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-checkbox.mdc-list-item,.mdc-list-item--with-leading-checkbox.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-checkbox .mdc-list-item__start{margin-left:8px;margin-right:24px}[dir=rtl] .mdc-list-item--with-leading-checkbox .mdc-list-item__start,.mdc-list-item--with-leading-checkbox .mdc-list-item__start[dir=rtl]{margin-left:24px;margin-right:8px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:8px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-checkbox.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-radio.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-radio.mdc-list-item,.mdc-list-item--with-leading-radio.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-radio .mdc-list-item__start{margin-left:8px;margin-right:24px}[dir=rtl] .mdc-list-item--with-leading-radio .mdc-list-item__start,.mdc-list-item--with-leading-radio .mdc-list-item__start[dir=rtl]{margin-left:24px;margin-right:8px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:8px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-radio.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-radio.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-leading-switch.mdc-list-item{padding-left:0;padding-right:auto}[dir=rtl] .mdc-list-item--with-leading-switch.mdc-list-item,.mdc-list-item--with-leading-switch.mdc-list-item[dir=rtl]{padding-left:auto;padding-right:0}.mdc-list-item--with-leading-switch .mdc-list-item__start{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-leading-switch .mdc-list-item__start,.mdc-list-item--with-leading-switch .mdc-list-item__start[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__start{align-self:flex-start;margin-top:16px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__primary-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__overline-text{display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__overline-text::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines .mdc-list-item__overline-text::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines.mdc-list-item--with-trailing-meta .mdc-list-item__end::before{display:inline-block;width:0;height:32px;content:"";vertical-align:0}.mdc-list-item--with-leading-switch.mdc-list-item--with-one-line{height:56px}.mdc-list-item--with-leading-switch.mdc-list-item--with-two-lines{height:72px}.mdc-list-item--with-trailing-icon.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-icon.mdc-list-item,.mdc-list-item--with-trailing-icon.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-list-item--with-trailing-icon .mdc-list-item__end{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-trailing-icon .mdc-list-item__end,.mdc-list-item--with-trailing-icon .mdc-list-item__end[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-trailing-meta.mdc-list-item--with-two-lines .mdc-list-item__end{align-self:flex-start;margin-top:0}.mdc-list-item--with-trailing-meta.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:0}.mdc-list-item--with-trailing-meta.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-meta.mdc-list-item,.mdc-list-item--with-trailing-meta.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-list-item--with-trailing-meta .mdc-list-item__end{margin-left:28px;margin-right:16px}[dir=rtl] .mdc-list-item--with-trailing-meta .mdc-list-item__end,.mdc-list-item--with-trailing-meta .mdc-list-item__end[dir=rtl]{margin-left:16px;margin-right:28px}.mdc-list-item--with-trailing-meta.mdc-list-item--with-two-lines .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-trailing-meta.mdc-list-item--with-two-lines .mdc-list-item__end::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-trailing-meta.mdc-list-item--with-three-lines .mdc-list-item__end{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-trailing-meta.mdc-list-item--with-three-lines .mdc-list-item__end::before{display:inline-block;width:0;height:28px;content:"";vertical-align:0}.mdc-list-item--with-trailing-meta .mdc-list-item__end{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--mdc-typography-caption-font-family);font-size:var(--mdc-typography-caption-font-size);line-height:var(--mdc-typography-caption-line-height);font-weight:var(--mdc-typography-caption-font-weight);letter-spacing:var(--mdc-typography-caption-letter-spacing);text-decoration:var(--mdc-typography-caption-text-decoration);text-transform:var(--mdc-typography-caption-text-transform)}.mdc-list-item--with-trailing-checkbox.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-checkbox.mdc-list-item,.mdc-list-item--with-trailing-checkbox.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-list-item--with-trailing-checkbox .mdc-list-item__end{margin-left:24px;margin-right:8px}[dir=rtl] .mdc-list-item--with-trailing-checkbox .mdc-list-item__end,.mdc-list-item--with-trailing-checkbox .mdc-list-item__end[dir=rtl]{margin-left:8px;margin-right:24px}.mdc-list-item--with-trailing-checkbox.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:8px}.mdc-list-item--with-trailing-radio.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-radio.mdc-list-item,.mdc-list-item--with-trailing-radio.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-list-item--with-trailing-radio .mdc-list-item__end{margin-left:24px;margin-right:8px}[dir=rtl] .mdc-list-item--with-trailing-radio .mdc-list-item__end,.mdc-list-item--with-trailing-radio .mdc-list-item__end[dir=rtl]{margin-left:8px;margin-right:24px}.mdc-list-item--with-trailing-radio.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:8px}.mdc-list-item--with-trailing-switch.mdc-list-item{padding-left:auto;padding-right:0}[dir=rtl] .mdc-list-item--with-trailing-switch.mdc-list-item,.mdc-list-item--with-trailing-switch.mdc-list-item[dir=rtl]{padding-left:0;padding-right:auto}.mdc-list-item--with-trailing-switch .mdc-list-item__end{margin-left:16px;margin-right:16px}[dir=rtl] .mdc-list-item--with-trailing-switch .mdc-list-item__end,.mdc-list-item--with-trailing-switch .mdc-list-item__end[dir=rtl]{margin-left:16px;margin-right:16px}.mdc-list-item--with-trailing-switch.mdc-list-item--with-three-lines .mdc-list-item__end{align-self:flex-start;margin-top:16px}.mdc-list-item--with-overline.mdc-list-item--with-two-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-overline.mdc-list-item--with-two-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:20px;content:"";vertical-align:0}.mdc-list-item--with-overline.mdc-list-item--with-three-lines .mdc-list-item__primary-text{display:block;margin-top:0;line-height:normal}.mdc-list-item--with-overline.mdc-list-item--with-three-lines .mdc-list-item__primary-text::before{display:inline-block;width:0;height:20px;content:"";vertical-align:0}.mdc-list-item{padding-left:16px;padding-right:16px}[dir=rtl] .mdc-list-item,.mdc-list-item[dir=rtl]{padding-left:16px;padding-right:16px}.mdc-list-group .mdc-deprecated-list{padding:0}.mdc-list-group__subheader{margin:calc((3rem - 1.5rem)/2) 16px}.mdc-list-divider{padding:0;background-clip:content-box}.mdc-list-divider.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-text.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-icon.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-image.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-avatar.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-switch.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-radio.mdc-list-divider--with-leading-inset{padding-left:16px;padding-right:auto}[dir=rtl] .mdc-list-divider.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-text.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-icon.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-image.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-avatar.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-switch.mdc-list-divider--with-leading-inset,[dir=rtl] .mdc-list-divider--with-leading-radio.mdc-list-divider--with-leading-inset,.mdc-list-divider.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-text.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-icon.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-image.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-avatar.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-switch.mdc-list-divider--with-leading-inset[dir=rtl],.mdc-list-divider--with-leading-radio.mdc-list-divider--with-leading-inset[dir=rtl]{padding-left:auto;padding-right:16px}.mdc-list-divider.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-text.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-icon.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-image.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-avatar.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-switch.mdc-list-divider--with-trailing-inset,.mdc-list-divider--with-leading-radio.mdc-list-divider--with-trailing-inset{padding-left:auto;padding-right:16px}[dir=rtl] .mdc-list-divider.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-text.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-icon.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-image.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-avatar.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-switch.mdc-list-divider--with-trailing-inset,[dir=rtl] .mdc-list-divider--with-leading-radio.mdc-list-divider--with-trailing-inset,.mdc-list-divider.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-text.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-icon.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-image.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-thumbnail.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-avatar.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-checkbox.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-switch.mdc-list-divider--with-trailing-inset[dir=rtl],.mdc-list-divider--with-leading-radio.mdc-list-divider--with-trailing-inset[dir=rtl]{padding-left:16px;padding-right:auto}.mdc-list-divider--with-leading-video.mdc-list-divider--with-leading-inset{padding-left:0px;padding-right:auto}[dir=rtl] .mdc-list-divider--with-leading-video.mdc-list-divider--with-leading-inset,.mdc-list-divider--with-leading-video.mdc-list-divider--with-leading-inset[dir=rtl]{padding-left:auto;padding-right:0px}[dir=rtl] .mdc-list-divider,.mdc-list-divider[dir=rtl]{padding:0}.mdc-list-item{background-color:var(--mdc-list-list-item-container-color)}.mdc-list-item.mdc-list-item--selected{background-color:var(--mdc-list-list-item-selected-container-color)}.mdc-list-item--with-one-line{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item--with-one-line.mdc-list-item--with-leading-avatar,.mdc-list-item--with-one-line.mdc-list-item--with-leading-icon,.mdc-list-item--with-one-line.mdc-list-item--with-leading-thumbnail,.mdc-list-item--with-one-line.mdc-list-item--with-leading-checkbox,.mdc-list-item--with-one-line.mdc-list-item--with-leading-radio,.mdc-list-item--with-one-line.mdc-list-item--with-leading-switch{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item--with-one-line.mdc-list-item--with-leading-image,.mdc-list-item--with-one-line.mdc-list-item--with-leading-video{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item--with-two-lines{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item--with-two-lines.mdc-list-item--with-leading-avatar,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-icon,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-thumbnail,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-checkbox,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-radio,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-switch,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-image,.mdc-list-item--with-two-lines.mdc-list-item--with-leading-video{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item--with-three-lines{border-radius:var(--mdc-list-list-item-container-shape)}.mdc-list-item.mdc-list-item--with-one-line{height:var(--mdc-list-list-item-one-line-container-height)}.mdc-list-item.mdc-list-item--with-two-lines{height:var(--mdc-list-list-item-two-line-container-height)}.mdc-list-item.mdc-list-item--with-three-lines{height:var(--mdc-list-list-item-three-line-container-height)}.mdc-list-item__primary-text{color:var(--mdc-list-list-item-label-text-color)}.mdc-list-item__primary-text{font-family:var(--mdc-list-list-item-label-text-font);line-height:var(--mdc-list-list-item-label-text-line-height);font-size:var(--mdc-list-list-item-label-text-size);font-weight:var(--mdc-list-list-item-label-text-weight);letter-spacing:var(--mdc-list-list-item-label-text-tracking)}.mdc-list-item__secondary-text{color:var(--mdc-list-list-item-supporting-text-color)}.mdc-list-item__secondary-text{font-family:var(--mdc-list-list-item-supporting-text-font);line-height:var(--mdc-list-list-item-supporting-text-line-height);font-size:var(--mdc-list-list-item-supporting-text-size);font-weight:var(--mdc-list-list-item-supporting-text-weight);letter-spacing:var(--mdc-list-list-item-supporting-text-tracking)}.mdc-list-item--with-leading-icon .mdc-list-item__start{color:var(--mdc-list-list-item-leading-icon-color)}.mdc-list-item--with-leading-icon .mdc-list-item__start{width:var(--mdc-list-list-item-leading-icon-size);height:var(--mdc-list-list-item-leading-icon-size)}.mdc-list-item--with-leading-icon .mdc-list-item__start>i{font-size:var(--mdc-list-list-item-leading-icon-size)}.mdc-list-item--with-leading-icon .mdc-list-item__start .mdc-list-item__icon{font-size:var(--mdc-list-list-item-leading-icon-size);width:var(--mdc-list-list-item-leading-icon-size);height:var(--mdc-list-list-item-leading-icon-size)}.mdc-list-item--with-leading-avatar .mdc-list-item__start{width:var(--mdc-list-list-item-leading-avatar-size);height:var(--mdc-list-list-item-leading-avatar-size)}.mdc-list-item.mdc-list-item--with-trailing-meta .mdc-list-item__end{color:var(--mdc-list-list-item-trailing-supporting-text-color)}.mdc-list-item--with-trailing-meta .mdc-list-item__end{font-family:var(--mdc-list-list-item-trailing-supporting-text-font);line-height:var(--mdc-list-list-item-trailing-supporting-text-line-height);font-size:var(--mdc-list-list-item-trailing-supporting-text-size);font-weight:var(--mdc-list-list-item-trailing-supporting-text-weight);letter-spacing:var(--mdc-list-list-item-trailing-supporting-text-tracking)}.mdc-list-item--with-trailing-icon .mdc-list-item__end{color:var(--mdc-list-list-item-trailing-icon-color)}.mdc-list-item--with-trailing-icon .mdc-list-item__end{width:var(--mdc-list-list-item-trailing-icon-size);height:var(--mdc-list-list-item-trailing-icon-size)}.mdc-list-item--with-trailing-icon .mdc-list-item__end>i{font-size:var(--mdc-list-list-item-trailing-icon-size)}.mdc-list-item--with-trailing-icon .mdc-list-item__end .mdc-list-item__icon{font-size:var(--mdc-list-list-item-trailing-icon-size);width:var(--mdc-list-list-item-trailing-icon-size);height:var(--mdc-list-list-item-trailing-icon-size)}.mdc-list-item--selected.mdc-list-item--with-trailing-icon .mdc-list-item__end{color:var(--mdc-list-list-item-selected-trailing-icon-color)}.mdc-list-item--disabled .mdc-list-item__start,.mdc-list-item--disabled .mdc-list-item__content,.mdc-list-item--disabled .mdc-list-item__end{opacity:1}.mdc-list-item--disabled .mdc-list-item__primary-text,.mdc-list-item--disabled .mdc-list-item__secondary-text,.mdc-list-item--disabled .mdc-list-item__overline-text{opacity:var(--mdc-list-list-item-disabled-label-text-opacity)}.mdc-list-item--disabled.mdc-list-item--with-leading-icon .mdc-list-item__start{color:var(--mdc-list-list-item-disabled-leading-icon-color)}.mdc-list-item--disabled.mdc-list-item--with-leading-icon .mdc-list-item__start{opacity:var(--mdc-list-list-item-disabled-leading-icon-opacity)}.mdc-list-item--disabled.mdc-list-item--with-trailing-icon .mdc-list-item__end{color:var(--mdc-list-list-item-disabled-trailing-icon-color)}.mdc-list-item--disabled.mdc-list-item--with-trailing-icon .mdc-list-item__end{opacity:var(--mdc-list-list-item-disabled-trailing-icon-opacity)}.mdc-list-item:hover .mdc-list-item__primary-text{color:var(--mdc-list-list-item-hover-label-text-color)}.mdc-list-item--with-leading-icon:hover .mdc-list-item__start{color:var(--mdc-list-list-item-hover-leading-icon-color)}.mdc-list-item--with-trailing-icon:hover .mdc-list-item__end{color:var(--mdc-list-list-item-hover-trailing-icon-color)}.mdc-list-item:focus .mdc-list-item__primary-text{color:var(--mdc-list-list-item-focus-label-text-color)}.mdc-list-item.mdc-list-item--disabled .mdc-list-item__primary-text{color:var(--mdc-list-list-item-disabled-label-text-color)}.mdc-list-item:hover::before{background-color:var(--mdc-list-list-item-hover-state-layer-color);opacity:var(--mdc-list-list-item-hover-state-layer-opacity)}.mdc-list-item.mdc-list-item--disabled::before{background-color:var(--mdc-list-list-item-disabled-state-layer-color);opacity:var(--mdc-list-list-item-disabled-state-layer-opacity)}.mdc-list-item:focus::before{background-color:var(--mdc-list-list-item-focus-state-layer-color);opacity:var(--mdc-list-list-item-focus-state-layer-opacity)}.mdc-list-item--disabled .mdc-radio,.mdc-list-item--disabled .mdc-checkbox{opacity:var(--mdc-list-list-item-disabled-label-text-opacity)}.mdc-list-item--with-leading-avatar .mat-mdc-list-item-avatar{border-radius:var(--mdc-list-list-item-leading-avatar-shape);background-color:var(--mdc-list-list-item-leading-avatar-color)}.mat-mdc-list-base{--mdc-list-list-item-container-shape:0;--mdc-list-list-item-leading-avatar-shape:50%;--mdc-list-list-item-container-color:transparent;--mdc-list-list-item-selected-container-color:transparent;--mdc-list-list-item-leading-avatar-color:transparent;--mdc-list-list-item-leading-icon-size:24px;--mdc-list-list-item-leading-avatar-size:40px;--mdc-list-list-item-trailing-icon-size:24px;--mdc-list-list-item-disabled-state-layer-color:transparent;--mdc-list-list-item-disabled-state-layer-opacity:0;--mdc-list-list-item-disabled-label-text-opacity:0.38;--mdc-list-list-item-disabled-leading-icon-opacity:0.38;--mdc-list-list-item-disabled-trailing-icon-opacity:0.38}.cdk-high-contrast-active a.mdc-list-item--activated::after{content:"";position:absolute;top:50%;right:16px;transform:translateY(-50%);width:10px;height:0;border-bottom:solid 10px;border-radius:10px}.cdk-high-contrast-active a.mdc-list-item--activated [dir=rtl]::after{right:auto;left:16px}.mat-mdc-list-base{display:block}.mat-mdc-list-base .mdc-list-item__start,.mat-mdc-list-base .mdc-list-item__end,.mat-mdc-list-base .mdc-list-item__content{pointer-events:auto}.mat-mdc-list-item,.mat-mdc-list-option{width:100%;box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mat-mdc-list-item:not(.mat-mdc-list-item-interactive),.mat-mdc-list-option:not(.mat-mdc-list-item-interactive){cursor:default}.mat-mdc-list-item .mat-divider-inset,.mat-mdc-list-option .mat-divider-inset{position:absolute;left:0;right:0;bottom:0}.mat-mdc-list-item .mat-mdc-list-item-avatar~.mat-divider-inset,.mat-mdc-list-option .mat-mdc-list-item-avatar~.mat-divider-inset{margin-left:72px}[dir=rtl] .mat-mdc-list-item .mat-mdc-list-item-avatar~.mat-divider-inset,[dir=rtl] .mat-mdc-list-option .mat-mdc-list-item-avatar~.mat-divider-inset{margin-right:72px}.mat-mdc-list-item-interactive::before{top:0;left:0;right:0;bottom:0;position:absolute;content:"";opacity:0;pointer-events:none}.mat-mdc-list-item>.mat-mdc-focus-indicator{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.mat-mdc-list-item:focus>.mat-mdc-focus-indicator::before{content:""}.mat-mdc-list-item.mdc-list-item--with-three-lines .mat-mdc-list-item-line.mdc-list-item__secondary-text{white-space:nowrap;line-height:normal}.mat-mdc-list-item.mdc-list-item--with-three-lines .mat-mdc-list-item-unscoped-content.mdc-list-item__secondary-text{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}mat-action-list button{background:none;color:inherit;border:none;font:inherit;outline:inherit;-webkit-tap-highlight-color:rgba(0,0,0,0);text-align:left}[dir=rtl] mat-action-list button{text-align:right}mat-action-list button::-moz-focus-inner{border:0}'],encapsulation:2,changeDetection:0}),n})(),kne=(()=>{class n{}return n.\u0275fac=function(t){return new(t||n)},n.\u0275mod=Mt({type:n}),n.\u0275inj=On({imports:[FT,ul,rr,$v,iN,ene]}),n})();function Ine(n,e){if(1&n&&(ke(0,"a",1),qt(1,"img",2),ke(2,"h3",3),it(3),Ne(),ke(4,"p",4)(5,"span"),it(6),Ne()()()),2&n){const t=e.$implicit;$e("href",t.url,Id),Le(1),$e("src",t.icon,Id)("alt",t.name),Le(2),Hi(t.name),Le(3),Hi(t.description)}}class Dg{constructor(e){this._bottomSheet=e}openBottomSheet(){this._bottomSheet.open(wy)}}Dg.\u0275fac=function(e){return new(e||Dg)(ie(Qte))},Dg.\u0275cmp=Ln({type:Dg,selectors:[["destiny-webring"]],standalone:!0,features:[_v],decls:3,vars:0,consts:[["mat-mini-fab","","color","accent","aria-label","More from Chris Fried",3,"click"]],template:function(e,t){1&e&&(ke(0,"button",0),Gn("click",function(){return t.openBottomSheet()}),ke(1,"mat-icon"),it(2,"apps"),Ne()())},dependencies:[ul,s4,nS,uN,pq,T8],styles:["button[_ngcontent-%COMP%]{position:fixed;top:1em;right:1em;z-index:20}"]});class wy{constructor(e){this._bottomSheetRef=e,this.links=[{url:"https://guardian.theater/",name:"Guardian Theater",description:"Find yourself in Twitch and Xbox videos",icon:"./assets/webring/gt.png"},{url:"https://d2srl.club/",name:"SRL\xb2",description:"2: Synchronized Random Loadouts",icon:"./assets/webring/srl2.png"},{url:"https://github.com/chrisfried/secret-scrublandeux",name:"Scrublandeux on GitHub",description:"The source isn't pretty, but it's open",icon:"./assets/webring/github-mark-white.png"},{url:"https://mastodon.chateaude.luxe/@chrisfried",name:"Chris Fried",description:"Follow me on Mastodon",icon:"./assets/webring/logo-purple.svg"}]}openLink(e){this._bottomSheetRef.dismiss(),e.preventDefault()}}function Fne(n,e){if(1&n){const t=Df();ke(0,"button",9),Gn("click",function(){return R(t),V(Jt().login())}),it(1," Login with Bungie "),ke(2,"mat-icon",10),it(3,"login"),Ne()()}}function Rne(n,e){if(1&n){const t=Df();ke(0,"button",11),Gn("click",function(){return R(t),V(Jt().logout())}),it(1," Logout "),ke(2,"mat-icon",12),it(3,"logout"),Ne()()}}wy.\u0275fac=function(e){return new(e||wy)(ie(mk))},wy.\u0275cmp=Ln({type:wy,selectors:[["destiny-webring-sheet"]],standalone:!0,features:[_v],decls:2,vars:1,consts:[["mat-list-item","","rel","me","target","_blank",3,"href",4,"ngFor","ngForOf"],["mat-list-item","","rel","me","target","_blank",3,"href"],["matListItemAvatar","",3,"src","alt"],["matListItemTitle",""],["matListItemLine",""]],template:function(e,t){1&e&&(ke(0,"mat-nav-list"),mt(1,Ine,7,5,"a",0),Ne()),2&e&&(Le(1),$e("ngForOf",t.links))},dependencies:[ul,tg,kne,Cne,Ene,P8,_k,gk],encapsulation:2});class Sy{constructor(e){this.bungieAuth=e,this.calendarChange=new Pn}ngOnInit(){this.searchString=""}login(){this.bungieAuth.login()}logout(){this.bungieAuth.logout()}}function Ey(n,e,t){return n(t?{method:"GET",url:e,params:t}:{method:"GET",url:e})}Sy.\u0275fac=function(e){return new(e||Sy)(ie(qd))},Sy.\u0275cmp=Ln({type:Sy,selectors:[["app-nav"]],inputs:{calendar:"calendar"},outputs:{calendarChange:"calendarChange"},decls:18,vars:6,consts:[[1,"mat-headline-5","headline"],["mat-raised-button","","href","https://chrisfried.github.io/secret-scrubland/",1,"switch-game"],[2,"margin-bottom","1em"],["mat-raised-button","","color","primary","class","button",3,"click",4,"ngIf"],["mat-raised-button","","class","button",3,"click",4,"ngIf"],[1,"mat-body-2"],["name","calendar","aria-label","Calendar"],["value","gregorian",3,"click"],["value","bungie",3,"click"],["mat-raised-button","","color","primary",1,"button",3,"click"],["aria-label","Login with Bungie"],["mat-raised-button","",1,"button",3,"click"],["aria-label","Logout"]],template:function(e,t){1&e&&(ke(0,"span",0),it(1,"Destiny 2 Historical Heatmap"),Ne(),ke(2,"a",1),it(3,"Switch to Destiny 1"),Ne(),ke(4,"div",2),mt(5,Fne,4,0,"button",3),ft(6,"async"),mt(7,Rne,4,0,"button",4),ft(8,"async"),Ne(),ke(9,"div",5),it(10," Calendar Type:"),qt(11,"br"),ke(12,"mat-button-toggle-group",6)(13,"mat-button-toggle",7),Gn("click",function(){return t.calendarChange.emit("gregorian")}),it(14,"Gregorian"),Ne(),ke(15,"mat-button-toggle",8),Gn("click",function(){return t.calendarChange.emit("bungie")}),it(16,"Bungie"),Ne()()(),qt(17,"br")),2&e&&(Le(5),$e("ngIf",!1===vn(6,2,t.bungieAuth.hasValidAccessToken$)),Le(2),$e("ngIf",vn(8,4,t.bungieAuth.hasValidAccessToken$)))},dependencies:[Yu,hq,cN,gN,_N,nS,Rf],styles:[".switch-game[_ngcontent-%COMP%]{margin-bottom:1em}.headline[_ngcontent-%COMP%]{margin-right:1em}"]});const Jn="https://www.bungie.net/Platform/Destiny2/";function L8(n,e){return Ey(n,`${Jn}${e.membershipType}/Profile/${e.destinyMembershipId}/Character/${e.characterId}/`,{components:e.components?e.components.join(","):void 0})}function N8(n,e){return Ey(n,`${Jn}${e.membershipType}/Account/${e.destinyMembershipId}/Stats/`,{groups:e.groups?e.groups.join(","):void 0})}function B8(n,e){return Ey(n,`${Jn}${e.membershipType}/Account/${e.destinyMembershipId}/Character/${e.characterId}/Stats/Activities/`,{count:e.count,mode:e.mode,page:e.page})}const Kd="https://www.bungie.net/Platform/User/";function V8(n){return Ey(n,`${Kd}GetMembershipsForCurrentUser/`)}class Yf{transform(e,t){let i=0;return e.forEach(r=>{(!t||0===t||"0"===t||t===r.activityDetails.mode||r.activityDetails.modes.indexOf(+t)>-1)&&(i+=r.values.timePlayedSeconds.basic.value)}),i}}Yf.\u0275fac=function(e){return new(e||Yf)},Yf.\u0275pipe=Yi({name:"addTime",type:Yf,pure:!1});var One=dt(8410);class Lne{constructor(e="keyval-store",t="keyval"){this.storeName=t,this._dbp=new Promise((i,r)=>{const s=indexedDB.open(e,1);s.onerror=()=>r(s.error),s.onsuccess=()=>i(s.result),s.onupgradeneeded=()=>{s.result.createObjectStore(t)}})}_withIDBStore(e,t){return this._dbp.then(i=>new Promise((r,s)=>{const o=i.transaction(this.storeName,e);o.oncomplete=()=>r(),o.onabort=o.onerror=()=>s(o.error),t(o.objectStore(this.storeName))}))}}let yk;function My(){return yk||(yk=new Lne),yk}var Hne=dt(7489),Une=dt.n(Hne);class uh{constructor(e){this.http=e,this.alwaysLoadRemote=!1,this.version=null,this.state={loaded:!1},this.state$=new er(this.state),this.newManifest$=new cn,this.localStorageKey="d2-manifest-version",this.idbKey="d2-manifest";const t=["Activity","ActivityMode"];dr(function Pne(n){return Ey(n,`${Jn}Manifest/`)}(i=>this.http.request(i.method,i.url,{params:i.params,body:i.body}).toPromise())).pipe(wo(i=>{const r=i.Response,o=r.jsonWorldContentPaths.en||r.jsonWorldContentPaths.en,a=o;this.version=a;try{if(this.alwaysLoadRemote)throw new Error("Testing - always load remote");const c=localStorage.getItem(this.localStorageKey),u=JSON.parse(localStorage.getItem(this.localStorageKey+"-whitelist")||"[]");if(c===a&&(0,One.deepEqual)(u,t)){const p=function Nne(n,e=My()){let t;return e._withIDBStore("readonly",i=>{t=i.get(n)}).then(()=>t.result)}(this.idbKey);if(!p)throw new Error("Empty cached manifest file");return p}throw new Error(`version mismatch: ${a} ${c}`)}catch{return this.http.get(`https://www.bungie.net${o}`,{withCredentials:!1}).pipe(_t(u=>{const p=Une().pick(u,...t.map(g=>`Destiny${g}Definition`));return this.saveManifestToIndexedDB(p,a,t),this.newManifest$.next(),p}))}}),_t(i=>{if(!i.DestinyActivityDefinition)throw new Error("Manifest corrupted, please reload");this.defs={},t.forEach(r=>{const s=`Destiny${r}Definition`;this.defs[r]="ActivityMode"===r?{get(o){const a=i[s];if(!a)throw new Error(`Table ${s} does not exist in the manifest`);for(const c in a)if(a[c].modeType===o)return a[c];throw new Error(`ModeType ${o} does not exist in the manifest`)},dbTable:i[s]}:{get(o){const a=i[s];if(!a)throw new Error(`Table ${s} does not exist in the manifest`);return a[o]},dbTable:i[s]}}),this.loaded=!0}),da((i,r)=>(console.error(i.message||i),i instanceof TypeError||-1===i.status||503===i.status||522===i.status||i.status<200||i.status>=400||this.deleteManifestFile(),Fc))).subscribe()}set loaded(e){this.setState({loaded:e,error:void 0})}set statusText(e){this.setState({statusText:e})}saveManifestToIndexedDB(e,t,i){var r=this;return fl(function*(){try{yield function Bne(n,e,t=My()){return t._withIDBStore("readwrite",i=>{i.put(e,n)})}(r.idbKey,e),localStorage.setItem(r.localStorageKey,t),localStorage.setItem(r.localStorageKey+"-whitelist",JSON.stringify(i))}catch(s){console.error("Error saving manifest file",s)}})()}deleteManifestFile(){localStorage.removeItem(this.localStorageKey),function Vne(n,e=My()){e._withIDBStore("readwrite",t=>{t.delete(n)})}(this.idbKey)}setState(e){this.state={...this.state,...e},this.state$.next(this.state)}}uh.\u0275fac=function(e){return new(e||uh)(xe(Ju))},uh.\u0275prov=Je({token:uh,factory:uh.\u0275fac,providedIn:"root"});class Xf{constructor(e){this.manifestService=e}transform(e,t){return this.manifestService.state$.pipe(_t(i=>{if(i.loaded)switch(t){case"activityName":return this.manifestService.defs.Activity.get(e)?.displayProperties.name;case"activityMode":return this.manifestService.defs.ActivityMode.get(e)?.displayProperties.name;case"activityIcon":return this.manifestService.defs.Activity.get(e)?.displayProperties.hasIcon?`https://bungie.net${this.manifestService.defs.Activity.get(e).displayProperties.icon}`:"";case"activityModeIcon":return this.manifestService.defs.ActivityMode.get(e)?.displayProperties.hasIcon?`https://bungie.net${this.manifestService.defs.ActivityMode.get(e).displayProperties.icon}`:"";default:return""}}))}}Xf.\u0275fac=function(e){return new(e||Xf)(ie(uh,16))},Xf.\u0275pipe=Yi({name:"manifest",type:Xf,pure:!0});class Zf{transform(e,t){switch(t){case"class":switch(e){case"2017-9-6":case"2017-09-06":case"2017-10-24":case"2017-12-5":case"2017-12-05":case"2018-5-8":case"2018-05-08":case"2018-9-4":case"2018-09-04":case"2018-12-4":case"2018-12-04":case"2019-3-5":case"2019-03-05":case"2019-6-4":case"2019-06-04":case"2019-10-1":case"2019-10-01":case"2019-12-10":case"2020-3-10":case"2020-03-10":case"2020-6-9":case"2020-06-09":case"2020-11-10":case"2021-2-9":case"2021-02-09":case"2021-5-11":case"2021-05-11":case"2021-8-24":case"2021-08-24":case"2021-12-7":case"2021-12-07":case"2022-2-22":case"2022-02-22":case"2022-5-24":case"2022-05-24":case"2022-8-23":case"2022-08-23":case"2022-12-6":case"2022-12-06":case"2023-2-28":case"2023-02-28":case"2023-5-23":case"2023-05-23":return"release";case"2017-9-13":case"2017-09-13":case"2017-12-6":case"2017-12-06":case"2018-5-11":case"2018-05-11":case"2018-9-14":case"2018-09-14":case"2018-12-7":case"2018-12-07":case"2019-6-4":case"2019-06-04":case"2019-10-5":case"2019-10-05":case"2020-11-21":case"2021-5-22":case"2021-05-22":case"2022-3-5":case"2022-03-05":case"2022-8-26":case"2022-08-26":case"2023-3-10":case"2023-03-10":return"raid";case"2017-12-19":case"2018-2-13":case"2018-02-13":case"2018-7-8":case"2018-07-08":case"2018-7-20":case"2018-07-20":case"2018-7-31":case"2018-07-31":case"2018-9-25":case"2018-09-25":case"2018-10-16":case"2018-12-4":case"2018-12-04":case"2018-12-7":case"2018-12-07":case"2018-12-11":case"2018-12-18":case"2019-1-8":case"2019-01-08":case"2019-1-29":case"2019-01-29":case"2019-2-5":case"2019-02-05":case"2019-3-5":case"2019-03-05":case"2019-3-8":case"2019-03-08":case"2019-3-12":case"2019-03-12":case"2019-3-15":case"2019-03-15":case"2019-3-19":case"2019-03-19":case"2019-3-26":case"2019-03-26":case"2019-4-2":case"2019-04-02":case"2019-4-9":case"2019-04-09":case"2019-4-16":case"2019-04-16":case"2019-6-4":case"2019-06-04":case"2019-6-11":case"2019-06-11":case"2019-6-18":case"2019-06-18":case"2019-6-25":case"2019-06-25":case"2019-7-2":case"2019-07-02":case"2019-7-9":case"2019-07-09":case"2019-7-30":case"2019-07-30":case"2019-10-5":case"2019-10-05":case"2019-10-22":case"2019-10-29":case"2019-11-19":case"2019-12-17":case"2020-1-7":case"2020-01-07":case"2020-1-28":case"2020-01-28":case"2020-2-4":case"2020-02-04":case"2020-2-11":case"2020-02-11":case"2020-3-13":case"2020-03-13":case"2020-3-17":case"2020-03-17":case"2020-3-24":case"2020-03-24":case"2020-4-7":case"2020-04-07":case"2020-4-21":case"2020-04-21":case"2020-6-6":case"2020-06-06":case"2020-7-7":case"2020-07-07":case"2020-8-11":case"2020-08-11":case"2020-9-8":case"2020-09-08":case"2020-10-6":case"2020-10-06":case"2020-11-9":case"2020-11-09":case"2020-11-17":case"2020-12-15":case"2021-2-16":case"2021-02-16":case"2021-2-23":case"2021-02-23":case"2021-3-23":case"2021-03-23":case"2021-4-20":case"2021-04-20":case"2021-5-7":case"2021-05-07":case"2021-5-18":case"2021-05-18":case"2021-5-25":case"2021-05-25":case"2021-6-1":case"2021-06-01":case"2021-6-8":case"2021-06-08":case"2021-6-29":case"2021-06-29":case"2021-7-6":case"2021-07-06":case"2021-8-10":case"2021-08-10":case"2021-8-31":case"2021-08-31":case"2021-9-7":case"2021-09-07":case"2021-10-12":case"2021-12-14":case"2022-2-15":case"2022-02-15":case"2022-3-1":case"2022-03-01":case"2022-3-22":case"2022-03-22":case"2022-5-3":case"2022-05-03":case"2022-5-27":case"2022-05-27":case"2022-5-31":case"2022-05-31":case"2022-7-12":case"2022-07-12":case"2022-7-19":case"2022-07-19":case"2022-9-6":case"2022-09-06":case"2022-11-15":case"2022-10-18":case"2022-12-9":case"2022-12-09":case"2022-12-13":case"2023-1-3":case"2023-01-03":case"2023-1-31":case"2023-01-31":case"2023-3-7":case"2023-03-07":case"2023-3-14":case"2023-03-14":case"2023-4-4":case"2023-04-04":case"2023-4-25":case"2023-04-25":case"2023-5-2":case"2023-05-02":return"event";default:return""}case"text":switch(e){case"2017-9-6":case"2017-09-06":return" | Destiny 2 Console";case"2017-9-13":case"2017-09-13":return" | Leviathan Raid";case"2017-10-24":return" | Destiny 2 PC";case"2017-12-5":case"2017-12-05":return" | Launch: Curse of Osiris";case"2017-12-6":case"2017-12-06":return" | Eater of Worlds Raid Lair";case"2017-12-19":case"2018-12-11":case"2019-12-17":case"2020-12-15":case"2021-12-14":case"2022-12-13":case"2023-12-12":return" | The Dawning";case"2018-2-13":case"2018-02-13":case"2019-2-5":case"2019-02-05":case"2020-2-11":case"2020-02-11":return" | Crimson Days";case"2018-5-8":case"2018-05-08":return" | Launch: Warmind";case"2018-5-11":case"2018-05-11":return" | Spire of Stars Raid Lair";case"2018-7-8":case"2018-07-08":return" | Moments of Triumph";case"2018-7-20":case"2018-07-20":return" | The Whisper";case"2018-7-31":case"2018-07-31":case"2019-7-30":case"2019-07-30":case"2020-8-11":case"2020-08-11":case"2021-7-6":case"2021-07-06":return" | Solstice of Heroes";case"2018-9-4":case"2018-09-04":return" | Launch: Forsaken | Season of the Outlaw";case"2018-9-14":case"2018-09-14":return" | Last Wish Raid";case"2018-9-25":case"2018-09-25":return" | Shattered Throne Dungeon";case"2018-10-16":case"2020-10-6":case"2020-10-06":case"2021-10-12":case"2022-10-18":return" | Festival of the Lost";case"2018-12-4":case"2018-12-04":return" | Season of the Forge | Volundr Forge";case"2018-12-7":case"2018-12-07":return" | Scourge of the Past Raid | Gofannon Forge";case"2018-12-18":return" | Izanami Forge";case"2019-1-8":case"2019-01-08":return" | Niobe Labs";case"2019-1-29":case"2019-01-29":return" | Exotic Quest: The Last Word";case"2019-3-5":case"2019-03-05":return" | Season of the Drifter | Gambit Prime: New Arcadia & Reckoning Tier 1";case"2019-3-8":case"2019-03-08":return" | Reckoning Tier 2";case"2019-3-12":case"2019-03-12":return" | Gambit Prime: Deep Six | Exotic Quest: Thorn";case"2019-3-15":case"2019-03-15":return" | Invitations of the Nine | Reckoning Tier 3";case"2019-3-19":case"2019-03-19":return" | Gambit Prime: Legion's Folly";case"2019-3-26":case"2019-03-26":return" | Gambit Prime: Emerald Coast";case"2019-4-2":case"2019-04-02":return" | Gambit Prime: All Maps";case"2019-4-9":case"2019-04-09":return" | Arc Week";case"2019-4-16":case"2019-04-16":return" | The Revelry";case"2019-6-4":case"2019-06-04":return" | Season of Opulence | Menagerie & Crown of Sorrow Raid";case"2019-6-11":case"2019-06-11":return" | New Menagerie Boss | Exotic Quest: Truth";case"2019-6-18":case"2019-06-18":return" | New Menagerie Boss | Iron Banner Quest";case"2019-6-25":case"2019-06-25":return" | Menagerie Heroic Mode";case"2019-7-2":case"2019-07-02":return" | Exotic Quest: Lumina";case"2019-7-9":case"2019-07-09":return" | Tribute Hall | Moments of Triumph";case"2019-10-1":case"2019-10-01":return" | Launch: Shadowkeep | Season of Undying";case"2019-10-5":case"2019-10-05":return" | Garden of Salvation Raid | Vex Offensive";case"2019-10-22":return" | Exotic Quest: Leviathan's Breath | Master Nightmare Hunts";case"2019-10-29":return" | Festival of the Lost | Pit of Heresy Dungeon | Exotic Quest: Xenophage";case"2019-11-19":return" | Vex Offensive: Final Assault";case"2019-12-10":return" | Season of Dawn";case"2020-1-7":case"2020-01-07":return" | Exotic Quest: Devil's Ruin";case"2020-1-28":case"2020-01-28":return" | Exotic Quest: Bastion";case"2020-2-4":case"2020-02-04":return" | Empyrean Foundation";case"2020-3-10":case"2020-03-10":return" | Season of the Worthy | Seraph Bunker: EDZ";case"2020-3-13":case"2020-03-13":return" | Trials of Osiris Returns";case"2020-3-17":case"2020-03-17":return" | Exotic Quest: The Fourth Horseman";case"2020-3-24":case"2020-03-24":return" | Seraph Bunker: Moon";case"2020-4-7":case"2020-04-07":return" | Seraph Bunker: Io";case"2020-4-21":case"2020-04-21":return" | Guardian Games | Grandmaster Nightfalls";case"2020-6-6":case"2020-06-06":return" | Live Event: Almighty's Destruction";case"2020-6-9":case"2020-06-09":return" | Season of Arrivals | Contact Event: Io | Prophecy Dungeon";case"2020-7-7":case"2020-07-07":return" | Moments of Triumph | Exotic Quest: Ruinous Effigy | Contact Event: Titan";case"2020-9-8":case"2020-09-08":return" | Exotic Quest: Traveler's Chosen";case"2020-11-9":case"2020-11-09":return" | Live Event: Traveler Reforged";case"2020-11-10":return" | Launch: Beyond Light | Season of the Hunt";case"2020-11-17":return" | Wrathborn Hunts";case"2020-11-21":return" | Deep Stone Crypt Raid";case"2020-12-8":case"2020-12-08":return" | Exotic Quest: Hawkmoon";case"2021-2-9":case"2021-02-09":return" | Season of the Chosen | H.E.L.M. Opens | Behemoth & Hailstone Battlegrounds";case"2021-2-16":case"2021-02-16":return" | Foothold Battleground | Exotic Quest: Dead Man's Tale";case"2021-2-23":case"2021-02-23":return" | Oracle Battleground";case"2021-3-23":case"2021-03-23":return" | Proving Grounds Strike";case"2021-4-20":case"2021-04-20":case"2022-5-3":case"2022-05-03":case"2023-5-2":case"2023-05-02":return" | Guardian Games";case"2021-5-7":case"2021-05-07":return" | Guardian Games Closing Ceremony";case"2021-5-11":case"2021-05-11":return" | Season of the Splicer | Override: Europa";case"2021-5-18":case"2021-05-18":return" | Override: Moon";case"2021-5-22":case"2021-05-22":return" | Vault of Glass Raid";case"2021-5-25":case"2021-05-25":return" | Override: Tangled Shore | Expunge: Labyrinth";case"2021-6-1":case"2021-06-01":return" | Expunge: Styx";case"2021-6-8":case"2021-06-08":return" | Expunge: Tartarus";case"2021-6-29":case"2021-06-29":return" | Expunge: Delphi";case"2021-8-10":case"2021-08-10":return" | Season of the Splicer Epilogue";case"2021-8-24":case"2021-08-24":return" | Season of the Lost | Exotic Quest: Ager's Scepter | Shattered Realm: Forest of Echoes";case"2021-8-31":case"2021-08-31":return" | Shattered Realm: Debris of Dreams";case"2021-9-7":case"2021-09-07":return" | Shattered Realm: Ruins of Wrath";case"2021-12-7":case"2021-12-07":return" | Bungie 30th Anniversary | Grasp of Avarice Dungeon | Moments of Triumph | Exotic Quest: Gjallarhorn";case"2022-2-15":case"2022-02-15":return" | The Exorcism";case"2022-2-22":case"2022-02-22":return" | Launch: The Witch Queen | Season of the Risen | Exotic Quest: Dead Messenger | PsiOps Battleground: EDZ";case"2022-3-1":case"2022-03-01":return" | PsiOps Battleground: Cosmodrome";case"2022-3-5":case"2022-03-05":return" | Vow of the Disciple Raid";case"2022-3-22":case"2022-03-22":return" | PsiOps Battleground: Moon";case"2022-5-24":case"2022-05-24":return" | Season of the Haunted";case"2022-5-27":case"2022-05-27":return" | Duality Dungeon";case"2022-5-31":case"2022-05-31":case"2022-7-12":case"2022-07-12":case"2022-9-6":case"2022-09-06":case"2022-11-15":case"2023-1-3":case"2023-01-03":case"2023-1-31":case"2023-01-31":case"2023-3-14":case"2023-03-14":case"2023-4-4":case"2023-04-04":case"2023-4-25":case"2023-04-25":case"2023-5-30":case"2023-05-30":case"2023-6-20":case"2023-06-20":case"2023-7-11":case"2023-07-11":case"2023-9-5":case"2023-09-05":case"2023-10-10":case"2023-11-14":case"2023-12-5":case"2023-12-05":case"2024-1-2":case"2024-01-02":case"2024-1-23":case"2024-01-23":case"2024-04-02":case"2024-4-2":return" | Iron Banner";case"2022-7-19":case"2022-07-19":case"2023-7-18":case"2023-07-18":return" | Solstice";case"2022-8-23":case"2022-08-23":return" | Season of Plunder";case"2022-8-26":case"2022-08-26":return" | King's Fall Raid";case"2022-11-27":return" | Eliksni Quarter Community Event";case"2022-12-6":case"2022-12-06":return" | Season of the Seraph | Moments of Triumph";case"2022-12-9":case"2022-12-09":return" | Spire of the Watcher Dungeon";case"2022-12-20":return" | Exotic Quest: Revision Zero";case"2023-2-28":case"2023-02-28":return" | Launch: Lightfall | Season of Defiance";case"2023-3-7":case"2023-03-07":return" | Exotic Quest: Vexcalibur";case"2023-03-10":case"2023-3-10":return" | Root of Nightmares Raid";case"2023-5-23":case"2023-05-23":return" | Season of the Deep";case"2023-5-26":case"2023-05-26":return" | Ghosts of the Deep Dungeon";case"2023-7-4":case"2023-07-04":return" | Exotic Quest: Wicked Implement";case"2023-8-22":case"2023-08-22":return" | Season of the Witch";case"2023-9-1":case"2023-09-01":return" | Crota's End Raid";case"2023-11-28":return" | Season of the Wish";case"2023-12-1":case"2023-12-01":return" | Warlord's Ruin Dungeon";case"2023-12-19":return" | Exotic Quest: Wish-Keeper";case"2024-1-30":case"2024-01-30":return" | Riven's Wishes";case"2024-3-5":case"2024-03-05":return" | Guardian Games All-Stars";default:return""}case"icon":let i="icon ";switch(e){case"2017-9-6":case"2017-09-06":case"2017-10-24":return i+="red-war";case"2017-12-5":case"2017-12-05":return i+="curse-of-osiris";case"2017-12-19":case"2018-12-11":case"2019-12-17":case"2020-12-15":case"2021-12-14":case"2022-12-13":case"2023-12-12":return i+="dawning";case"2018-2-13":case"2018-02-13":case"2019-2-5":case"2019-02-05":case"2020-2-11":case"2020-02-11":return i+="crimson-days";case"2018-5-8":case"2018-05-08":return i+="warmind";case"2018-7-8":case"2018-07-08":case"2019-7-9":case"2019-07-09":case"2020-7-7":case"2020-07-07":return i+="moments-of-triumph";case"2018-7-31":case"2018-07-31":case"2019-7-30":case"2019-07-30":case"2020-8-11":case"2020-08-11":case"2021-7-6":case"2021-07-06":return i+="solstice";case"2018-9-4":case"2018-09-04":return i+="forsaken";case"2018-10-16":case"2019-10-29":case"2020-10-6":case"2020-10-06":case"2021-10-12":case"2022-10-18":return i+="festival-of-the-lost";case"2018-12-4":case"2018-12-04":return i+="season-of-the-forge";case"2019-3-5":case"2019-03-05":return i+="season-of-the-drifter";case"2019-4-16":case"2019-04-16":return i+="revelry";case"2019-6-4":case"2019-06-04":return i+="season-of-opulence";case"2019-10-1":case"2019-10-01":return i+="shadowkeep";case"2019-10-5":case"2019-10-05":return i+="season-of-the-undying";case"2019-12-10":return i+="season-of-dawn";case"2020-3-10":case"2020-03-10":return i+="season-of-the-worthy";case"2020-4-21":case"2020-04-21":case"2021-4-20":case"2021-04-20":case"2022-5-3":case"2022-05-03":case"2023-5-2":case"2023-05-02":case"2024-3-5":case"2024-03-05":return i+="guardian-games";case"2020-6-9":case"2020-06-09":return i+="season-of-arrivals";case"2020-11-10":return i+="beyond-light";case"2020-11-17":return i+="season-of-the-hunt";case"2021-2-9":case"2021-02-09":return i+="season-of-the-chosen";case"2021-5-11":case"2021-05-11":return i+="season-of-the-splicer";case"2021-8-24":case"2021-08-24":return i+="season-of-the-lost";case"2021-12-7":case"2021-12-07":return i+="thirtieth-anniversary";case"2022-2-22":case"2022-02-22":return i+="witch-queen";case"2022-5-24":case"2022-05-24":return i+="season-of-the-haunted";case"2022-5-31":case"2022-05-31":case"2022-7-12":case"2022-07-12":case"2022-9-6":case"2022-09-06":case"2022-11-15":case"2023-1-3":case"2023-01-03":case"2023-1-31":case"2023-01-31":case"2023-3-14":case"2023-03-14":case"2023-4-4":case"2023-04-04":case"2023-4-25":case"2023-04-25":case"2023-5-30":case"2023-05-30":case"2023-6-20":case"2023-06-20":case"2023-7-11":case"2023-07-11":case"2023-9-5":case"2023-09-05":case"2023-10-10":case"2023-11-14":case"2023-12-5":case"2023-12-05":case"2024-1-2":case"2024-01-02":case"2024-1-23":case"2024-01-23":case"2024-04-02":case"2024-4-2":return i+="iron-banner";case"2022-7-19":case"2022-07-19":case"2023-7-18":case"2023-07-18":return i+="solstice2022";case"2017-9-13":case"2017-09-13":case"2017-12-6":case"2017-12-06":case"2018-5-11":case"2018-05-11":case"2018-9-14":case"2018-09-14":case"2018-12-7":case"2018-12-07":case"2020-11-21":case"2021-5-22":case"2021-05-22":case"2022-3-5":case"2022-03-05":case"2022-8-26":case"2022-08-26":case"2023-3-10":case"2023-03-10":case"2023-9-1":case"2023-09-01":return i+="raid";case"2022-8-23":case"2022-08-23":return i+="season-of-plunder";case"2018-9-25":case"2018-09-25":case"2022-5-27":case"2022-05-27":case"2022-12-9":case"2022-12-09":case"2023-5-26":case"2023-05-26":case"2023-12-1":case"2023-12-01":return i+="dungeon";case"2022-12-6":case"2022-12-06":return i+="season-of-the-seraph";case"2023-2-28":case"2023-02-28":return i+="lightfall";case"2023-5-23":case"2023-05-23":return i+="season-of-the-deep";case"2019-1-29":case"2019-01-29":case"2019-3-12":case"2019-03-12":case"2019-6-11":case"2019-06-11":case"2019-7-2":case"2019-07-02":case"2019-10-22":case"2019-10-29":case"2020-1-7":case"2020-01-07":case"2020-1-28":case"2020-01-28":case"2020-3-17":case"2020-03-17":case"2020-7-7":case"2020-07-07":case"2020-9-8":case"2020-09-08":case"2020-12-8":case"2020-12-08":case"2021-2-16":case"2021-02-16":case"2021-8-24":case"2021-08-24":case"2021-12-7":case"2021-12-07":case"2022-2-22":case"2022-02-22":case"2022-12-20":case"2023-3-7":case"2023-03-07":case"2023-7-4":case"2023-07-04":case"2023-12-19":return i+="exotic-quest";case"2023-8-22":case"2023-08-22":return i+="season-of-the-witch";case"2023-11-28":return i+="season-of-the-wish";default:return""}default:return""}}}Zf.\u0275fac=function(e){return new(e||Zf)},Zf.\u0275pipe=Yi({name:"milestone",type:Zf,pure:!0});const zne=function(n){return{top:n}};function Gne(n,e){if(1&n&&(ke(0,"div",4)(1,"span",5),it(2),Ne()()),2&n){const t=e.$implicit,i=Jt();$e("ngStyle",qu(2,zne,i.gameHours[t].offset+"px")),Le(2),Hi(i.gameHours[t].display)}}const jne=function(n,e){return{height:n,top:e}};function Wne(n,e){if(1&n&&(qt(0,"a",6),ft(1,"async"),ft(2,"manifest"),ft(3,"async"),ft(4,"manifest")),2&n){const t=e.$implicit,i=Jt();$e("ngClass","mode-"+t.activityDetails.mode)("ngStyle",function nP(n,e,t,i,r){return rP(C(),ee(),n,e,t,i,r)}(14,jne,(i.Math.floor(t.values.timePlayedSeconds.basic.value/60)||1)+"px",t.offset+"px"))("matTooltip",vn(1,4,Ti(2,6,t.activityDetails.mode,"activityMode"))+" | "+vn(3,9,Ti(4,11,t.activityDetails.referenceId,"activityName")))("href","https://www.bungie.net/en/PGCR/"+t.activityDetails.instanceId+"?character="+t.characterId,Id)}}const $ne=function(n){return{height:n}};class Cy{constructor(e){this.data=e,this.allHours=[],this.gameHours={},this.gameHourKeys=[],this.Math=Math}ngOnInit(){this.dayStart=new Date(this.data.date+"T00:00:00");const e=new Date(this.dayStart.getTime());for(let r=0;r<24;r++){const s=e.getTime(),o=e.toLocaleTimeString(void 0,{hour:"numeric"});e.setHours(r+1);const a=e.getTime();this.allHours.push({id:r,display:o,start:s,stop:a})}for(const r of this.data.activities)for(const s of this.allHours)r.startDate.getTime()=s.start&&(this.gameHours[s.id]=s);let i,t=0;for(const r of Object.keys(this.gameHours))i&&this.gameHours[r].id-i>1&&(t+=10),this.gameHours[r].offset=t,t+=60,i=this.gameHours[r].id,this.modalHeight=t;this.gameHourKeys=Object.keys(this.gameHours);for(const r of this.data.activities)r.offset=this.gameHours[r.startDate.getHours()].offset+r.startDate.getMinutes()}}Cy.\u0275fac=function(e){return new(e||Cy)(ie(ZN))},Cy.\u0275cmp=Ln({type:Cy,selectors:[["app-day-modal"]],decls:9,vars:15,consts:[["mat-dialog-title",""],[1,"timelineBase",3,"ngStyle"],["class","timelineLabels",3,"ngStyle",4,"ngFor","ngForOf"],["class","timelineActivity","matTooltipPosition","after","target","_blank",3,"ngClass","ngStyle","matTooltip","href",4,"ngFor","ngForOf"],[1,"timelineLabels",3,"ngStyle"],[1,"time","mat-caption"],["matTooltipPosition","after","target","_blank",1,"timelineActivity",3,"ngClass","ngStyle","matTooltip","href"]],template:function(e,t){1&e&&(ke(0,"h2",0),it(1),ft(2,"milestone"),ft(3,"addTime"),ft(4,"addTime"),Ne(),ke(5,"mat-dialog-content")(6,"div",1),mt(7,Gne,3,4,"div",2),mt(8,Wne,5,17,"a",3),Ne()()),2&e&&(Le(1),xs(" ",t.data.date+Ti(2,4,t.data.date,"text")+": "+t.Math.floor(Ti(3,7,t.data.activities,"0")/86400*24)+"h "+t.Math.floor(Ti(4,10,t.data.activities,"0")%3600/60)+"m","\n"),Le(5),$e("ngStyle",qu(13,$ne,t.modalHeight+"px")),Le(1),$e("ngForOf",t.gameHourKeys),Le(1),$e("ngForOf",t.data.activities))},dependencies:[eg,tg,nw,rA,sY,oY,Rf,Yf,Xf,Zf],styles:[".timelineBase[_ngcontent-%COMP%]{width:59px;display:block;position:relative;margin-left:3em}.timelineLabels[_ngcontent-%COMP%]{display:block;position:absolute;height:59px;width:60px;background-color:#e6e6e6}.timelineLabels[_ngcontent-%COMP%] .time[_ngcontent-%COMP%]{margin-left:-3.5em;width:3em;display:block;text-align:right}.timelineActivity[_ngcontent-%COMP%]{display:block;width:60px;position:absolute;left:.5em;background-color:#323296}.mode-42[_ngcontent-%COMP%], .mode-39[_ngcontent-%COMP%], .mode-41[_ngcontent-%COMP%]{background-color:#00ded1}.mode-31[_ngcontent-%COMP%], .mode-5[_ngcontent-%COMP%], .mode-38[_ngcontent-%COMP%], .mode-12[_ngcontent-%COMP%], .mode-37[_ngcontent-%COMP%], .mode-10[_ngcontent-%COMP%]{background-color:#ca1c1b}.mode-45[_ngcontent-%COMP%], .mode-44[_ngcontent-%COMP%], .mode-43[_ngcontent-%COMP%], .mode-19[_ngcontent-%COMP%]{background-color:#485537}.mode-3[_ngcontent-%COMP%], .mode-18[_ngcontent-%COMP%]{background-color:#3d526f}.mode-17[_ngcontent-%COMP%], .mode-16[_ngcontent-%COMP%]{background-color:#1f3043}.mode-2[_ngcontent-%COMP%]{background-color:#ed8129}.mode-40[_ngcontent-%COMP%]{background-color:#fff}.mode-6[_ngcontent-%COMP%]{background-color:#cacaca}.mode-4[_ngcontent-%COMP%]{background-color:#461044}.mode-63[_ngcontent-%COMP%]{background-color:#2b8e69}@media (prefers-color-scheme: dark){.mode-40[_ngcontent-%COMP%]{background-color:#000}.mode-6[_ngcontent-%COMP%]{background-color:#888}}"]});class Jf{constructor(e){this.http=e,this.queue$=new er({getGlobalAlerts:[],getDestinyManifest:[],getMembershipDataForCurrentUser:[],getMembershipDataById:[],getProfile:[],getActivityHistory:[],getPostGameCarnageReport:[]}),this.actionPriority=["getGlobalAlerts","getDestinyManifest","getMembershipDataForCurrentUser","getMembershipDataById","getProfile","getActivityHistory","getPostGameCarnageReport"],this.queueCount={getGlobalAlerts:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getDestinyManifest:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getMembershipDataForCurrentUser:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getMembershipDataById:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getProfile:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getActivityHistory:{queued:0,completed:0,errors:0,percentage:0,color:"primary"},getPostGameCarnageReport:{queued:0,completed:0,errors:0,percentage:0,color:"primary"}},this.queue$.pipe(zv(40)).subscribe(t=>{for(const i of this.actionPriority){const r=t[i];if("getPostGameCarnageReport"===i&&r.sort((s,o)=>parseInt(o.params.activityId,10)-parseInt(s.params.activityId,10)),r.length){const s=r.shift();this.queue$.next(t),s&&s.actionFunction(o=>this.http.request(o.method,o.url,{params:o.params,body:o.body}).toPromise(),s.params).then(o=>{s.callback(o),this.queueCount[i].completed++,this.updateQueue(this.queueCount[i])}).catch(o=>{s.callback(o),this.queueCount[i].errors++,this.updateQueue(this.queueCount[i])});break}}})}addToQueue(e,t,i,r){this.queue$.pipe(Gr(1)).subscribe(s=>{s[e]=[...s[e],{actionFunction:t,callback:i,params:r}],this.queue$.next(s),this.queueCount[e].queued++,this.updateQueue(this.queueCount[e])})}updateQueue(e){e.percentage=e.queued?(e.completed+e.errors)/e.queued*100:100;let t=!1;for(const i of this.actionPriority)this.queueCount[i].color=t||0===this.queueCount[i].queued||100===this.queueCount[i].percentage?"primary":"accent",this.queueCount[i].percentage>0&&this.queueCount[i].percentage<100&&(t=!0)}}Jf.\u0275fac=function(e){return new(e||Jf)(xe(Ju))},Jf.\u0275prov=Je({token:Jf,factory:Jf.\u0275fac,providedIn:"root"});class Tg{transform(e,t){const i=e.reduce(function(a,c){return a+ +c.values.timePlayedSeconds.basic.value},0);return Math.floor(i/86400)+"d "+Math.floor(i%86400/3600)+"h "+Math.floor(i%86400%3600/60)+"m"}}Tg.\u0275fac=function(e){return new(e||Tg)},Tg.\u0275pipe=Yi({name:"activitiesTotalTime",type:Tg,pure:!1});class Ag{transform(e,t){return Math.floor(e/1440)+"d "+Math.floor(e%1440/60)+"h "+Math.floor(e%1440%60)+"m"}}Ag.\u0275fac=function(e){return new(e||Ag)},Ag.\u0275pipe=Yi({name:"parseMinutesPlayed",type:Ag,pure:!0});class kg{transform(e,t){const i=e.reduce(function(s,o){return s+ +o.values.timePlayedSeconds.basic.value},0);return Math.floor(i/3600)+"h"}}kg.\u0275fac=function(e){return new(e||kg)},kg.\u0275pipe=Yi({name:"activitiesTotalHours",type:kg,pure:!1});class Ig{transform(e,t){return Math.floor(e/60)+"h"}}Ig.\u0275fac=function(e){return new(e||Ig)},Ig.\u0275pipe=Yi({name:"hoursPlayed",type:Ig,pure:!0});class Fg{transform(e,t){return e.some(function(i,r,s){return i.loading})}}Fg.\u0275fac=function(e){return new(e||Fg)},Fg.\u0275pipe=Yi({name:"loadingReduce",type:Fg,pure:!1});class Rg{transform(e,t){let i="inactive",r=1;e[e.length-1].length>0&&(i="active");for(let s=e.length-2;s>-1&&("active"===i&&e[s].length>0||"inactive"===i&&e[s].length<1);s--)r++;return r+" days "+i}}Rg.\u0275fac=function(e){return new(e||Rg)},Rg.\u0275pipe=Yi({name:"currentStreak",type:Rg,pure:!1});class Pg{transform(e,t){let i=0,r=0,s=0,o=0;for(let a=0;a0?(r=0,i++,i>s&&(s=i)):s>0&&(i=0,r++,r>o&&(o=r));return s+" days active | "+o+" days inactive"}}function qne(n,e){if(1&n&&(ke(0,"mat-card",10)(1,"mat-card-title"),it(2),Ne(),ke(3,"mat-card-subtitle"),it(4),Ne()()),2&n){const t=Jt();Le(2),Hi(t.errorStatus),Le(2),Hi(t.errorMessage)}}function Kne(n,e){1&n&&(ke(0,"mat-icon",11),it(1,"refresh"),Ne())}function Yne(n,e){if(1&n&&(ke(0,"mat-option",12),it(1),ft(2,"async"),ft(3,"manifest"),Ne()),2&n){const t=e.$implicit;$e("value",t),Le(1),xs("",vn(2,2,Ti(3,4,t,"activityMode"))," ")}}Pg.\u0275fac=function(e){return new(e||Pg)},Pg.\u0275pipe=Yi({name:"longestStreaks",type:Pg,pure:!1});const Xne=function(n,e,t){return[n,e,t]},Zne=function(n){return{"background-color":n}};function Jne(n,e){if(1&n){const t=Df();ke(0,"div",21),Gn("click",function(){const s=R(t).$implicit,o=Jt().$implicit,a=Jt().$implicit,c=Jt();return V(c.openDay(a+"-"+(o<10?"0":"")+o+"-"+(s<10?"0":"")+s,c.days[a][o][s]))}),ft(1,"milestone"),ft(2,"addTime"),ft(3,"milestone"),ft(4,"addTime"),ft(5,"addTime"),ft(6,"addTime"),ft(7,"addTime"),ft(8,"addTime"),ft(9,"milestone"),ft(10,"addTime"),ft(11,"addTime"),Ne()}if(2&n){const t=e.$implicit,i=Jt().$implicit,r=Jt().$implicit,s=Jt();$e("ngClass",XC(35,Xne,Ti(1,3,r+"-"+i+"-"+t,"class"),Ti(2,6,s.days[r][i][t],s.calendarFilter)>0?"active":"inactive",Ti(3,9,r+"-"+i+"-"+t,"icon")))("ngStyle",qu(39,Zne,"hsl("+(120*(100-Ti(4,12,s.days[r][i][t],s.calendarFilter)/864)/50-120)+", "+(Ti(5,15,s.days[r][i][t],s.calendarFilter)>0?"100%":"0%")+", "+(Ti(6,18,s.days[r][i][t],s.calendarFilter)>0?Ti(7,21,s.days[r][i][t],s.calendarFilter)/864>50?100-vn(8,24,s.days[r][i][t])/864+"%":"50%":"90%")+")"))("matTooltip",r+"-"+i+"-"+t+Ti(9,26,r+"-"+i+"-"+t,"text")+": "+s.Math.floor(Ti(10,29,s.days[r][i][t],s.calendarFilter)/86400*24)+"h "+s.Math.floor(Ti(11,32,s.days[r][i][t],s.calendarFilter)%3600/60)+"m")}}const Qne=function(n){return{width:n}},eie=function(n){return{height:n}};function tie(n,e){if(1&n&&(ke(0,"div",16)(1,"div",17),it(2),Ne(),ke(3,"div",18),ft(4,"loadingReduce"),qt(5,"div",19),mt(6,Jne,12,41,"div",20),Ne()()),2&n){const t=e.$implicit,i=Jt().$implicit,r=Jt();$e("ngStyle",qu(7,Qne,r.Math.ceil((r.dayKeys[i][t].length+r.monthOffsets[i][t])/7)+"em")),Le(2),Hi(t),Le(1),$e("ngClass",vn(4,5,r.loadingArray)?"loading":""),Le(2),$e("ngStyle",qu(9,eie,r.monthOffsets[i][t]+"em")),Le(1),$e("ngForOf",r.dayKeys[i][t])}}function nie(n,e){if(1&n&&(ke(0,"div",13)(1,"div",14)(2,"span"),it(3),Ne()(),mt(4,tie,7,11,"div",15),Ne()),2&n){const t=e.$implicit,i=Jt();Le(3),Hi(t),Le(1),$e("ngForOf",i.monthKeys[t])}}function iie(n,e){1&n&&(ke(0,"mat-icon",22),it(1,"refresh"),Ne())}function rie(n,e){1&n&&(ke(0,"mat-icon",37),it(1," trending_up "),Ne())}function sie(n,e){1&n&&(ke(0,"mat-icon",38),it(1," trending_flat "),Ne())}function oie(n,e){1&n&&(ke(0,"mat-icon",39),it(1," trending_down "),Ne())}function aie(n,e){1&n&&(ke(0,"mat-icon",37),it(1," trending_up "),Ne())}function cie(n,e){1&n&&(ke(0,"mat-icon",38),it(1," trending_flat "),Ne())}function lie(n,e){1&n&&(ke(0,"mat-icon",39),it(1," trending_down "),Ne())}function die(n,e){if(1&n&&(ke(0,"div",24),mt(1,aie,2,0,"mat-icon",25),mt(2,cie,2,0,"mat-icon",26),mt(3,lie,2,0,"mat-icon",27),ke(4,"div",28)(5,"div",29)(6,"div",30),it(7),ft(8,"async"),ft(9,"manifest"),Ne(),qt(10,"img",41),ft(11,"async"),ft(12,"manifest"),ft(13,"async"),ft(14,"manifest"),Ne(),ke(15,"div",31)(16,"div",32)(17,"div",33),it(18),Ne(),ke(19,"div",34),it(20,"13 week avg"),Ne()(),ke(21,"div",35)(22,"div",33),it(23),Ne(),ke(24,"div",34),it(25,"52 week avg"),Ne()()()()()),2&n){const t=Jt().$implicit,i=Jt(2);Le(1),$e("ngIf",t.quarter>t.year),Le(1),$e("ngIf",t.quarter===t.year),Le(1),$e("ngIf",t.quarter60?i.Math.floor(t.quarter/60)+"h"+t.quarter%60:t.quarter,"m/week"),Le(5),xs("",t.year>60?i.Math.floor(t.year/60)+"h"+t.year%60:t.year,"m/week")}}function uie(n,e){if(1&n&&(av(0),mt(1,die,26,23,"div",40),cv()),2&n){const t=e.$implicit;Le(1),$e("ngIf",t.quarter>0||t.year>0)}}function hie(n,e){if(1&n&&(ke(0,"div",23)(1,"div",24),mt(2,rie,2,0,"mat-icon",25),ft(3,"loadingReduce"),mt(4,sie,2,0,"mat-icon",26),ft(5,"loadingReduce"),mt(6,oie,2,0,"mat-icon",27),ft(7,"loadingReduce"),ke(8,"div",28)(9,"div",29)(10,"div",30),it(11,"All Activities"),Ne()(),ke(12,"div",31)(13,"div",32)(14,"div",33),it(15),Ne(),ke(16,"div",34),it(17,"13 week avg"),Ne()(),ke(18,"div",35)(19,"div",33),it(20),Ne(),ke(21,"div",34),it(22,"52 week avg"),Ne()()()()(),mt(23,uie,2,1,"ng-container",36),Ne()),2&n){const t=Jt();Le(2),$e("ngIf",!vn(3,6,t.loadingArray)&&t.getOverallTrend().quarter>t.getOverallTrend().year),Le(2),$e("ngIf",!vn(5,8,t.loadingArray)&&t.getOverallTrend().quarter===t.getOverallTrend().year),Le(2),$e("ngIf",!vn(7,10,t.loadingArray)&&t.getOverallTrend().quarter60?t.Math.floor(t.getOverallTrend().quarter/60)+"h"+t.getOverallTrend().quarter%60:t.getOverallTrend().quarter,"m/week"),Le(5),xs("",t.getOverallTrend().year>60?t.Math.floor(t.getOverallTrend().year/60)+"h"+t.getOverallTrend().year%60:t.getOverallTrend().year,"m/week"),Le(3),$e("ngForOf",t.getModeTrends())}}class Dy{constructor(e,t,i,r,s){this.http=e,this.dialog=t,this.manifestService=i,this.bungieQueue=r,this.bungieAuth=s,this.membershipDataForCurrentUser$=new er(void 0),this.accountResponse$=new er([]),this.displayName="",this.Math=Math}addDay(e){this.days[e.getFullYear()]||(this.days[e.getFullYear()]={}),this.days[e.getFullYear()][e.getMonth()+1]||(this.days[e.getFullYear()][e.getMonth()+1]={}),this.days[e.getFullYear()][e.getMonth()+1][e.getDate()]||(this.days[e.getFullYear()][e.getMonth()+1][e.getDate()]=[]),this.flatDays.push(this.days[e.getFullYear()][e.getMonth()+1][e.getDate()])}ngOnInit(){this.loadingArray=[],this.calendarFilter="0",this.subs=[],this.activities=[],this.days={},this.flatDays=[],this.oneQuarterAgo=new Date((new Date).setDate((new Date).getDate()-91)),this.oneYearAgo=new Date((new Date).setDate((new Date).getDate()-364)),this.modeTrends={},this.overallTrend={quarter:[],year:[]},this.flatDaysBS=new er([]),this.manifestService.state$.subscribe(s=>{s.loaded&&(this.modeOptions=Object.keys(this.manifestService.defs.ActivityMode.dbTable).map(o=>this.manifestService.defs.ActivityMode.dbTable[o].modeType).sort())}),this.errorStatus="",this.errorMessage="";const e=new Date("Sept 1, 2017"),t=new Date;for(;e<=t;)this.addDay(e),e.setDate(e.getDate()+1);this.flatDaysBS.next(this.flatDays),this.yearKeys=Object.keys(this.days),this.monthKeys={},this.monthOffsets={2017:{9:5}};let i=5,r=30;this.dayKeys={},this.yearKeys.forEach(s=>{this.monthKeys[s]=Object.keys(this.days[s]),this.monthOffsets[s]||(this.monthOffsets[s]={}),this.dayKeys[s]={},this.monthKeys[s].forEach(o=>{this.monthOffsets[s][o]||(this.monthOffsets[s][o]=(r+i)%7,r=Object.keys(this.days[s][o]).length,i=this.monthOffsets[s][o]),this.dayKeys[s][o]=Object.keys(this.days[s][o])})}),this.subs.push(this.bungieAuth.hasValidAccessToken$.pipe(Rc(),Dr(s=>{s&&this.bungieQueue.addToQueue("getProfile",V8,c=>{this.membershipDataForCurrentUser$.next(c)})})).subscribe()),this.subs.push(this.membershipDataForCurrentUser$.pipe(Rc(),wo(s=>ig(s?.Response?.destinyMemberships.map(o=>{const a={loading:!0};this.loadingArray.push(a);const c=new er(void 0),{membershipId:u,membershipType:p}=o;return this.bungieQueue.addToQueue("getProfile",N8,x=>{x&&1===x.ErrorCode&&x?.Response?.characters?.length>0?ig(x?.Response?.characters.map(T=>{const N={loading:!0};this.loadingArray.push(N);const k=new er(void 0),{characterId:A}=T,H=T.merged?.allTime?.secondsPlayed?.basic?.value;return this.bungieQueue.addToQueue("getProfile",L8,K=>{if(1===K.ErrorCode){const he=K;he.Response.character=K.Response.character??{data:{characterId:A,membershipId:u,membershipType:p,minutesPlayedTotal:H?this.Math.floor(H/60):0}},k.next(he)}N.loading=!1,k.complete()},{characterId:A,destinyMembershipId:u,membershipType:p,components:[200]}),k})??Fc).pipe(Gr(1)).subscribe(T=>{c.next(T),a.loading=!1,c.complete()}):(a.loading=!1,c.complete())},{destinyMembershipId:u,membershipType:p,groups:[1]}),c})??Fc)),_t(s=>this.accountResponse$.next(s))).subscribe()),this.membershipDataForCurrentUser$.pipe(Rc(),_t(s=>{this.displayName=s?.Response?.bungieNetUser?.displayName})).subscribe(),this.characters$=this.accountResponse$.pipe(Rc(),_t(s=>{const o=[];for(const a of s)if(a)for(const c of a)try{o.push(c.Response.character.data)}catch{}return o})),this.minutesPlayedTotal=this.characters$.pipe(_t(s=>{let o=0;return s.forEach(a=>{o+=+a.minutesPlayedTotal}),o})),this.subs.push(this.characters$.pipe(Rc()).subscribe(s=>{this.activities=[],s.forEach(o=>{const a={destinyMembershipId:o.membershipId,membershipType:o.membershipType,characterId:o.characterId,mode:0,count:250};this.addHistorySub({...a,page:0}),this.addHistorySub({...a,page:1}),this.addHistorySub({...a,page:2})})}))}addHistorySub(e){const t={loading:!0};this.loadingArray.push(t);const{page:i}=e,r=new er(void 0);this.bungieQueue.addToQueue("getActivityHistory",B8,a=>{r.next(a)},e),this.subs.push(r.subscribe(a=>{1!==a?.ErrorCode&&a?.ErrorStatus&&(this.errorStatus=a.ErrorStatus,this.errorMessage=a.Message),a?.Response.activities&&a?.Response.activities.length&&(this.addHistorySub({...e,page:i+3}),a.Response.activities.forEach(c=>{c.characterId=e.characterId;const p=new Date(c.period).getTime()/1e3+c.values.startSeconds.basic.value,g=p+c.values.timePlayedSeconds.basic.value;c.startDate=new Date(1e3*p),c.endDate=new Date(1e3*g),this.activities.push(c);try{this.days[c.startDate.getFullYear()][c.startDate.getMonth()+1][c.startDate.getDate()].push(c),c.endDate>this.oneYearAgo&&(c.activityDetails.modes.forEach(v=>{this.modeTrends[v]||(this.modeTrends[v]={quarter:[],year:[]}),this.modeTrends[v].year.push(c),c.endDate>this.oneQuarterAgo&&this.modeTrends[v].quarter.push(c)}),this.overallTrend.year.push(c),c.endDate>this.oneQuarterAgo&&this.overallTrend.quarter.push(c))}catch{}this.flatDaysBS.next(this.flatDays)})),a&&(t.loading=!1)}))}openDay(e,t){this.loadingArray.length&&!this.loadingArray.some(i=>i.loading)&&this.dialog.open(Cy,{data:{date:e,activities:t},width:"300px"})}ngOnDestroy(){this.subs.forEach(e=>e.unsubscribe())}getModeTrends(){return Object.keys(this.modeTrends).map(e=>({mode:Number(e),quarter:Math.round(this.modeTrends[Number(e)].quarter.reduce((t,i)=>t+(i.endDate-i.startDate),0)/13),year:Math.round(this.modeTrends[Number(e)].year.reduce((t,i)=>t+(i.endDate-i.startDate),0)/52)})).sort((e,t)=>t.year-e.year).sort((e,t)=>t.quarter-e.quarter).map(e=>({...e,quarter:Math.round(e.quarter/6e4),year:Math.round(e.year/6e4)}))}getOverallTrend(){return{quarter:Math.round(this.overallTrend.quarter.reduce((e,t)=>e+(t.endDate-t.startDate),0)/13/6e4),year:Math.round(this.overallTrend.year.reduce((e,t)=>e+(t.endDate-t.startDate),0)/52/6e4)}}}Dy.\u0275fac=function(e){return new(e||Dy)(ie(Ju),ie(Zw),ie(uh),ie(Jf),ie(qd))},Dy.\u0275cmp=Ln({type:Dy,selectors:[["app-guardian"]],decls:49,vars:37,consts:[["appearance","outlined","class","errorStatus",4,"ngIf"],[1,"mat-body-2"],[1,"mat-subtitle-2"],["aria-label","Search for Guardian","class","spinner",4,"ngIf"],[3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["class","calYear",4,"ngFor","ngForOf"],[1,"trends-header"],["class","trending_loading",4,"ngIf"],["class","trends",4,"ngIf"],["appearance","outlined",1,"errorStatus"],["aria-label","Search for Guardian",1,"spinner"],[3,"value"],[1,"calYear"],[1,"yearLabel","mat-caption"],["class","calMonth",3,"ngStyle",4,"ngFor","ngForOf"],[1,"calMonth",3,"ngStyle"],[1,"monthLabel","mat-caption"],[1,"dayWrapper",3,"ngClass"],[1,"monthSpacer",3,"ngStyle"],["class","calDay","matTooltipPosition","after",3,"ngClass","ngStyle","matTooltip","click",4,"ngFor","ngForOf"],["matTooltipPosition","after",1,"calDay",3,"ngClass","ngStyle","matTooltip","click"],[1,"trending_loading"],[1,"trends"],[1,"trend"],["class","trend-up",4,"ngIf"],["class","trend-flat",4,"ngIf"],["class","trend-down",4,"ngIf"],[1,"trend-main"],[1,"trend-header"],[1,"trend-name"],[1,"trend-values"],[1,"trend-quarter"],[1,"trend-value"],[1,"trend-time"],[1,"trend-year"],[4,"ngFor","ngForOf"],[1,"trend-up"],[1,"trend-flat"],[1,"trend-down"],["class","trend",4,"ngIf"],[1,"trend-icon",3,"src","alt"]],template:function(e,t){1&e&&(mt(0,qne,5,2,"mat-card",0),ke(1,"div",1),it(2," Name: "),ke(3,"span",2),it(4),Ne(),qt(5,"br"),it(6," Total Time in Destiny 2: "),ke(7,"span",2),it(8),ft(9,"hoursPlayed"),ft(10,"async"),Ne(),it(11," = "),ke(12,"span",2),it(13),ft(14,"parseMinutesPlayed"),ft(15,"async"),Ne(),qt(16,"br"),it(17," Total Time in Activities: "),ke(18,"span",2),it(19),ft(20,"activitiesTotalHours"),Ne(),it(21," = "),ke(22,"span",2),it(23),ft(24,"activitiesTotalTime"),Ne(),qt(25,"br"),it(26," Destiny 2 Activity Count: "),ke(27,"span",2),it(28),Ne(),mt(29,Kne,2,0,"mat-icon",3),ft(30,"loadingReduce"),qt(31,"br"),it(32),ft(33,"currentStreak"),qt(34,"br"),it(35),ft(36,"longestStreaks"),qt(37,"br"),it(38," Filter Heatmap: "),ke(39,"mat-form-field")(40,"mat-select",4),Gn("ngModelChange",function(r){return t.calendarFilter=r}),mt(41,Yne,4,7,"mat-option",5),Ne()()(),mt(42,nie,5,2,"div",6),ke(43,"h3",7),it(44,"Trends"),Ne(),mt(45,iie,2,0,"mat-icon",8),ft(46,"loadingReduce"),mt(47,hie,24,12,"div",9),ft(48,"loadingReduce")),2&e&&($e("ngIf",t.errorStatus),Le(4),Hi(t.displayName),Le(4),Hi(vn(9,15,vn(10,17,t.minutesPlayedTotal))),Le(5),Hi(vn(14,19,vn(15,21,t.minutesPlayedTotal))),Le(6),Hi(vn(20,23,t.activities)),Le(4),Hi(vn(24,25,t.activities)),Le(5),Hi(t.activities.length),Le(1),$e("ngIf",vn(30,27,t.loadingArray)),Le(3),xs(" Current Streak: ",vn(33,29,t.flatDays),""),Le(3),xs(" Longest Streaks: ",vn(36,31,t.flatDays),""),Le(5),$e("ngModel",t.calendarFilter),Le(1),$e("ngForOf",t.modeOptions),Le(1),$e("ngForOf",t.yearKeys),Le(3),$e("ngIf",vn(46,33,t.loadingArray)),Le(2),$e("ngIf",!vn(48,35,t.loadingArray)))},dependencies:[eg,tg,Yu,nw,nS,rA,_4,b4,BT,Uw,GT,zT,aT,Ew,Rf,Yf,Xf,Tg,Ag,kg,Ig,Zf,Fg,Rg,Pg],styles:['.calYear[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;margin-top:1em}.calMonth[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin-right:.5em;margin-bottom:.5em}.dayWrapper[_ngcontent-%COMP%]{display:flex;flex-direction:column;height:7em;flex-wrap:wrap}.calDay[_ngcontent-%COMP%]{display:block;width:1em;height:1em;box-sizing:border-box;cursor:pointer;transition:transform .2s;background-position:center;background-size:16px}.calDay[_ngcontent-%COMP%]:hover.icon{transform:scale(1.5);z-index:999;box-shadow:0 0 8px 3px #696969;opacity:1}.calDay[_ngcontent-%COMP%]:before{content:" ";top:0;left:0;width:100%;height:100%;filter:invert(1);display:block;-webkit-mask-size:contain;mask-size:contain}.calDay.red-war[_ngcontent-%COMP%]:before{-webkit-mask-image:url(red-war.3eff2acca21c93ca.png);mask-image:url(red-war.3eff2acca21c93ca.png);background-color:inherit}.calDay.curse-of-osiris[_ngcontent-%COMP%]:before{-webkit-mask-image:url(curse-of-osiris.6c410487c8c1193b.png);mask-image:url(curse-of-osiris.6c410487c8c1193b.png);background-color:inherit}.calDay.dawning[_ngcontent-%COMP%]:before{-webkit-mask-image:url(dawning.645be67ef31d090a.png);mask-image:url(dawning.645be67ef31d090a.png);background-color:inherit}.calDay.crimson-days[_ngcontent-%COMP%]:before{-webkit-mask-image:url(crimson-days.aa88f4d939be6b4f.png);mask-image:url(crimson-days.aa88f4d939be6b4f.png);background-color:inherit}.calDay.warmind[_ngcontent-%COMP%]:before{-webkit-mask-image:url(warmind.af5f3877c551d0a9.png);mask-image:url(warmind.af5f3877c551d0a9.png);background-color:inherit}.calDay.moments-of-triumph[_ngcontent-%COMP%]:before{-webkit-mask-image:url(moments-of-triumph.3dd2b9684009007a.png);mask-image:url(moments-of-triumph.3dd2b9684009007a.png);background-color:inherit}.calDay.solstice[_ngcontent-%COMP%]:before{-webkit-mask-image:url(solstice.cb7917ad27da3310.png);mask-image:url(solstice.cb7917ad27da3310.png);background-color:inherit}.calDay.forsaken[_ngcontent-%COMP%]:before{-webkit-mask-image:url(forsaken.f61a352f91528263.png);mask-image:url(forsaken.f61a352f91528263.png);background-color:inherit}.calDay.festival-of-the-lost[_ngcontent-%COMP%]:before{-webkit-mask-image:url(festival-of-the-lost.656fb66ff23db261.png);mask-image:url(festival-of-the-lost.656fb66ff23db261.png);background-color:inherit}.calDay.season-of-the-forge[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-forge.a88ddb98b2a97a0e.png);mask-image:url(season-of-the-forge.a88ddb98b2a97a0e.png);background-color:inherit}.calDay.season-of-the-drifter[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-drifter.1867ff7e8c88eda5.png);mask-image:url(season-of-the-drifter.1867ff7e8c88eda5.png);background-color:inherit}.calDay.revelry[_ngcontent-%COMP%]:before{-webkit-mask-image:url(revelry.4a84f0f680e2599d.png);mask-image:url(revelry.4a84f0f680e2599d.png);background-color:inherit}.calDay.season-of-opulence[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-opulence.3b878d66365d9cc6.png);mask-image:url(season-of-opulence.3b878d66365d9cc6.png);background-color:inherit}.calDay.shadowkeep[_ngcontent-%COMP%]:before{-webkit-mask-image:url(shadowkeep.2412f7e9615345e8.png);mask-image:url(shadowkeep.2412f7e9615345e8.png);background-color:inherit}.calDay.season-of-the-undying[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-undying.a0948d4e1e5532ab.png);mask-image:url(season-of-the-undying.a0948d4e1e5532ab.png);background-color:inherit}.calDay.season-of-dawn[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-dawn.152fa5fa97203b11.png);mask-image:url(season-of-dawn.152fa5fa97203b11.png);background-color:inherit}.calDay.season-of-the-worthy[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-worthy.97fe2af14ad98313.png);mask-image:url(season-of-the-worthy.97fe2af14ad98313.png);background-color:inherit}.calDay.guardian-games[_ngcontent-%COMP%]:before{-webkit-mask-image:url(guardian-games.1458a297ee32ae52.png);mask-image:url(guardian-games.1458a297ee32ae52.png);background-color:inherit}.calDay.season-of-arrivals[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-arrivals.649a4db068c154bf.png);mask-image:url(season-of-arrivals.649a4db068c154bf.png);background-color:inherit}.calDay.beyond-light[_ngcontent-%COMP%]:before{-webkit-mask-image:url(beyond-light.8fb053c5e78ee3c1.png);mask-image:url(beyond-light.8fb053c5e78ee3c1.png);background-color:inherit}.calDay.season-of-the-hunt[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-hunt.23c0a09811c2dd46.png);mask-image:url(season-of-the-hunt.23c0a09811c2dd46.png);background-color:inherit}.calDay.season-of-the-chosen[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-chosen.9d73f0c6a48c8b28.png);mask-image:url(season-of-the-chosen.9d73f0c6a48c8b28.png);background-color:inherit}.calDay.season-of-the-splicer[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-splicer.5cff32b822f61b20.png);mask-image:url(season-of-the-splicer.5cff32b822f61b20.png);background-color:inherit}.calDay.season-of-the-lost[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-lost.10a416eb34d1915e.png);mask-image:url(season-of-the-lost.10a416eb34d1915e.png);background-color:inherit}.calDay.thirtieth-anniversary[_ngcontent-%COMP%]:before{-webkit-mask-image:url(thirtieth-anniversary.3aa725ceedf9157d.png);mask-image:url(thirtieth-anniversary.3aa725ceedf9157d.png);background-color:inherit}.calDay.witch-queen[_ngcontent-%COMP%]:before{-webkit-mask-image:url(witch-queen.4fdd67baed2eb636.png);mask-image:url(witch-queen.4fdd67baed2eb636.png);background-color:inherit}.calDay.season-of-the-haunted[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-haunted.d4556f3df7022cf7.png);mask-image:url(season-of-the-haunted.d4556f3df7022cf7.png);background-color:inherit}.calDay.iron-banner[_ngcontent-%COMP%]:before{-webkit-mask-image:url(iron-banner.0cccf5ef6d1f8153.png);mask-image:url(iron-banner.0cccf5ef6d1f8153.png);background-color:inherit}.calDay.solstice2022[_ngcontent-%COMP%]:before{-webkit-mask-image:url(solstice2022.4129b7a862b1dd62.png);mask-image:url(solstice2022.4129b7a862b1dd62.png);background-color:inherit}.calDay.raid[_ngcontent-%COMP%]:before{-webkit-mask-image:url(raid.c24a762febb5d48f.png);mask-image:url(raid.c24a762febb5d48f.png);background-color:inherit}.calDay.season-of-plunder[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-plunder.a82a4f350d3ff629.png);mask-image:url(season-of-plunder.a82a4f350d3ff629.png);background-color:inherit}.calDay.dungeon[_ngcontent-%COMP%]:before{-webkit-mask-image:url(dungeon.1e3bb371bcf5c37b.png);mask-image:url(dungeon.1e3bb371bcf5c37b.png);background-color:inherit}.calDay.season-of-the-seraph[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-seraph.30ab5d205a09f6c4.png);mask-image:url(season-of-the-seraph.30ab5d205a09f6c4.png);background-color:inherit}.calDay.lightfall[_ngcontent-%COMP%]:before{-webkit-mask-image:url(lightfall.cbc105e4dbc42ae7.png);mask-image:url(lightfall.cbc105e4dbc42ae7.png);background-color:inherit}.calDay.season-of-the-deep[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-deep.c79c733175700d33.png);mask-image:url(season-of-the-deep.c79c733175700d33.png);background-color:inherit}.calDay.exotic-quest[_ngcontent-%COMP%]:before{-webkit-mask-image:url(exotic-quest.bb278fc19eb3104c.png);mask-image:url(exotic-quest.bb278fc19eb3104c.png);background-color:inherit}.calDay.season-of-the-witch[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-witch.7978d2dee322e4cf.png);mask-image:url(season-of-the-witch.7978d2dee322e4cf.png);background-color:inherit}.calDay.season-of-the-wish[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-wish.97577548fcd7897c.png);mask-image:url(season-of-the-wish.97577548fcd7897c.png);background-color:inherit}@media (prefers-reduced-motion){.calDay[_ngcontent-%COMP%]{transition:none}.calDay[_ngcontent-%COMP%]:hover{transform:none;box-shadow:none;background-image:none}}.loading[_ngcontent-%COMP%] > .calDay[_ngcontent-%COMP%]{cursor:progress}.yearLabel[_ngcontent-%COMP%]{display:flex;align-items:center}.yearLabel[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:.75em;display:block;transform:rotate(-90deg)}.monthSpacer[_ngcontent-%COMP%]{width:1em}.monthLabel[_ngcontent-%COMP%]{font-size:.75em;text-align:center}.release[_ngcontent-%COMP%]:before{width:100%;height:100%}.raid[_ngcontent-%COMP%]:before, .event[_ngcontent-%COMP%]:before{width:100%;height:100%}@media (prefers-color-scheme: dark){.release[_ngcontent-%COMP%], .raid[_ngcontent-%COMP%], .event[_ngcontent-%COMP%]{border-color:#333}.inactive[_ngcontent-%COMP%]{opacity:.15}}.spinner[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_spin 3s infinite linear;height:1em;width:1em;display:inline-block;line-height:1em;font-size:.75em}@keyframes _ngcontent-%COMP%_spin{0%{-webkit-transform:rotate(0deg)}to{-webkit-transform:rotate(360deg)}}@keyframes _ngcontent-%COMP%_spinX{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.errorStatus[_ngcontent-%COMP%]{margin-bottom:.5em}.trends-header[_ngcontent-%COMP%]{font-family:Roboto,Helvetica Neue,sans-serif}.trending_loading[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_spin 3s infinite linear}.trends[_ngcontent-%COMP%]{font-family:Roboto,Helvetica Neue,sans-serif;display:flex;flex-wrap:wrap;gap:1em}.trends[_ngcontent-%COMP%] .trend-up[_ngcontent-%COMP%]{color:green}.trends[_ngcontent-%COMP%] .trend-down[_ngcontent-%COMP%]{color:red}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.75em;min-width:17em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-header[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{height:1em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-time[_ngcontent-%COMP%]{font-size:.75em;opacity:.6}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-values[_ngcontent-%COMP%]{display:flex;gap:.75em}']});const bk="135",fie=0,H8=1,pie=2,U8=1,mie=2,Ty=3,Og=0,Ds=1,Lg=2,hh=0,Ay=1,G8=2,j8=3,W8=4,gie=5,Ng=100,_ie=101,vie=102,$8=103,q8=104,yie=200,bie=201,xie=202,wie=203,K8=204,Y8=205,Sie=206,Eie=207,Mie=208,Cie=209,Die=210,Tie=0,Aie=1,kie=2,xk=3,Iie=4,Fie=5,Rie=6,Pie=7,jS=0,Oie=1,Lie=2,Qf=0,Nie=1,Bie=2,Vie=3,Hie=4,Uie=5,Bg=301,Vg=302,WS=303,$S=304,ky=306,qS=307,KS=1e3,Uo=1001,YS=1002,Gs=1003,Sk=1004,Ek=1005,no=1006,X8=1007,Hg=1008,fh=1009,zie=1010,Gie=1011,Iy=1012,jie=1013,XS=1014,Yd=1015,Ug=1016,Wie=1017,$ie=1018,qie=1019,zg=1020,Kie=1021,ep=1022,zo=1023,Yie=1024,Xie=1025,Zie=zo,tp=1026,Gg=1027,Jie=1028,Qie=1029,ere=1030,tre=1031,nre=1032,ire=1033,Z8=33776,J8=33777,Q8=33778,eB=33779,tB=35840,nB=35841,iB=35842,rB=35843,rre=36196,sB=37492,oB=37496,sre=37808,ore=37809,are=37810,cre=37811,lre=37812,dre=37813,ure=37814,hre=37815,fre=37816,pre=37817,mre=37818,gre=37819,_re=37820,vre=37821,yre=36492,bre=37840,xre=37841,wre=37842,Sre=37843,Ere=37844,Mre=37845,Cre=37846,Dre=37847,Tre=37848,Are=37849,kre=37850,Ire=37851,Fre=37852,Rre=37853,jg=2400,Wg=2401,Ma=3e3,e2=3001,Dk=3007,Tk=3002,cB=3004,lB=3005,dB=3006,Vre=3201,$g=0,Hre=1,Fy=35044,Ry=35048,uB="300 es";class np{addEventListener(e,t){void 0===this._listeners&&(this._listeners={});const i=this._listeners;void 0===i[e]&&(i[e]=[]),-1===i[e].indexOf(t)&&i[e].push(t)}hasEventListener(e,t){if(void 0===this._listeners)return!1;const i=this._listeners;return void 0!==i[e]&&-1!==i[e].indexOf(t)}removeEventListener(e,t){if(void 0===this._listeners)return;const r=this._listeners[e];if(void 0!==r){const s=r.indexOf(t);-1!==s&&r.splice(s,1)}}dispatchEvent(e){if(void 0===this._listeners)return;const i=this._listeners[e.type];if(void 0!==i){e.target=this;const r=i.slice(0);for(let s=0,o=r.length;s>8&255]+Eo[n>>16&255]+Eo[n>>24&255]+"-"+Eo[255&e]+Eo[e>>8&255]+"-"+Eo[e>>16&15|64]+Eo[e>>24&255]+"-"+Eo[63&t|128]+Eo[t>>8&255]+"-"+Eo[t>>16&255]+Eo[t>>24&255]+Eo[255&i]+Eo[i>>8&255]+Eo[i>>16&255]+Eo[i>>24&255]).toUpperCase()}function Mo(n,e,t){return Math.max(e,Math.min(t,n))}function Oy(n,e,t){return(1-t)*n+t*e}function Ik(n){return 0==(n&n-1)&&0!==n}function fB(n){return Math.pow(2,Math.floor(Math.log(n)/Math.LN2))}class tt{constructor(e=0,t=0){this.x=e,this.y=t}get width(){return this.x}set width(e){this.x=e}get height(){return this.y}set height(e){this.y=e}set(e,t){return this.x=e,this.y=t,this}setScalar(e){return this.x=e,this.y=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y)}copy(e){return this.x=e.x,this.y=e.y,this}add(e,t){return void 0!==t?(console.warn("THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this)}addScalar(e){return this.x+=e,this.y+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this}sub(e,t){return void 0!==t?(console.warn("THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this)}subScalar(e){return this.x-=e,this.y-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this}multiply(e){return this.x*=e.x,this.y*=e.y,this}multiplyScalar(e){return this.x*=e,this.y*=e,this}divide(e){return this.x/=e.x,this.y/=e.y,this}divideScalar(e){return this.multiplyScalar(1/e)}applyMatrix3(e){const t=this.x,i=this.y,r=e.elements;return this.x=r[0]*t+r[3]*i+r[6],this.y=r[1]*t+r[4]*i+r[7],this}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this}clampLength(e,t){const i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(e,Math.min(t,i)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this}negate(){return this.x=-this.x,this.y=-this.y,this}dot(e){return this.x*e.x+this.y*e.y}cross(e){return this.x*e.y-this.y*e.x}lengthSq(){return this.x*this.x+this.y*this.y}length(){return Math.sqrt(this.x*this.x+this.y*this.y)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)}normalize(){return this.divideScalar(this.length()||1)}angle(){return Math.atan2(-this.y,-this.x)+Math.PI}distanceTo(e){return Math.sqrt(this.distanceToSquared(e))}distanceToSquared(e){const t=this.x-e.x,i=this.y-e.y;return t*t+i*i}manhattanDistanceTo(e){return Math.abs(this.x-e.x)+Math.abs(this.y-e.y)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this}lerpVectors(e,t,i){return this.x=e.x+(t.x-e.x)*i,this.y=e.y+(t.y-e.y)*i,this}equals(e){return e.x===this.x&&e.y===this.y}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e}fromBufferAttribute(e,t,i){return void 0!==i&&console.warn("THREE.Vector2: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this}rotateAround(e,t){const i=Math.cos(t),r=Math.sin(t),s=this.x-e.x,o=this.y-e.y;return this.x=s*i-o*r+e.x,this.y=s*r+o*i+e.y,this}random(){return this.x=Math.random(),this.y=Math.random(),this}*[Symbol.iterator](){yield this.x,yield this.y}}tt.prototype.isVector2=!0;class js{constructor(){this.elements=[1,0,0,0,1,0,0,0,1],arguments.length>0&&console.error("THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.")}set(e,t,i,r,s,o,a,c,u){const p=this.elements;return p[0]=e,p[1]=r,p[2]=a,p[3]=t,p[4]=s,p[5]=c,p[6]=i,p[7]=o,p[8]=u,this}identity(){return this.set(1,0,0,0,1,0,0,0,1),this}copy(e){const t=this.elements,i=e.elements;return t[0]=i[0],t[1]=i[1],t[2]=i[2],t[3]=i[3],t[4]=i[4],t[5]=i[5],t[6]=i[6],t[7]=i[7],t[8]=i[8],this}extractBasis(e,t,i){return e.setFromMatrix3Column(this,0),t.setFromMatrix3Column(this,1),i.setFromMatrix3Column(this,2),this}setFromMatrix4(e){const t=e.elements;return this.set(t[0],t[4],t[8],t[1],t[5],t[9],t[2],t[6],t[10]),this}multiply(e){return this.multiplyMatrices(this,e)}premultiply(e){return this.multiplyMatrices(e,this)}multiplyMatrices(e,t){const i=e.elements,r=t.elements,s=this.elements,o=i[0],a=i[3],c=i[6],u=i[1],p=i[4],g=i[7],v=i[2],y=i[5],x=i[8],T=r[0],N=r[3],k=r[6],A=r[1],H=r[4],G=r[7],X=r[2],se=r[5],K=r[8];return s[0]=o*T+a*A+c*X,s[3]=o*N+a*H+c*se,s[6]=o*k+a*G+c*K,s[1]=u*T+p*A+g*X,s[4]=u*N+p*H+g*se,s[7]=u*k+p*G+g*K,s[2]=v*T+y*A+x*X,s[5]=v*N+y*H+x*se,s[8]=v*k+y*G+x*K,this}multiplyScalar(e){const t=this.elements;return t[0]*=e,t[3]*=e,t[6]*=e,t[1]*=e,t[4]*=e,t[7]*=e,t[2]*=e,t[5]*=e,t[8]*=e,this}determinant(){const e=this.elements,t=e[0],i=e[1],r=e[2],s=e[3],o=e[4],a=e[5],c=e[6],u=e[7],p=e[8];return t*o*p-t*a*u-i*s*p+i*a*c+r*s*u-r*o*c}invert(){const e=this.elements,t=e[0],i=e[1],r=e[2],s=e[3],o=e[4],a=e[5],c=e[6],u=e[7],p=e[8],g=p*o-a*u,v=a*c-p*s,y=u*s-o*c,x=t*g+i*v+r*y;if(0===x)return this.set(0,0,0,0,0,0,0,0,0);const T=1/x;return e[0]=g*T,e[1]=(r*u-p*i)*T,e[2]=(a*i-r*o)*T,e[3]=v*T,e[4]=(p*t-r*c)*T,e[5]=(r*s-a*t)*T,e[6]=y*T,e[7]=(i*c-u*t)*T,e[8]=(o*t-i*s)*T,this}transpose(){let e;const t=this.elements;return e=t[1],t[1]=t[3],t[3]=e,e=t[2],t[2]=t[6],t[6]=e,e=t[5],t[5]=t[7],t[7]=e,this}getNormalMatrix(e){return this.setFromMatrix4(e).invert().transpose()}transposeIntoArray(e){const t=this.elements;return e[0]=t[0],e[1]=t[3],e[2]=t[6],e[3]=t[1],e[4]=t[4],e[5]=t[7],e[6]=t[2],e[7]=t[5],e[8]=t[8],this}setUvTransform(e,t,i,r,s,o,a){const c=Math.cos(s),u=Math.sin(s);return this.set(i*c,i*u,-i*(c*o+u*a)+o+e,-r*u,r*c,-r*(-u*o+c*a)+a+t,0,0,1),this}scale(e,t){const i=this.elements;return i[0]*=e,i[3]*=e,i[6]*=e,i[1]*=t,i[4]*=t,i[7]*=t,this}rotate(e){const t=Math.cos(e),i=Math.sin(e),r=this.elements,s=r[0],o=r[3],a=r[6],c=r[1],u=r[4],p=r[7];return r[0]=t*s+i*c,r[3]=t*o+i*u,r[6]=t*a+i*p,r[1]=-i*s+t*c,r[4]=-i*o+t*u,r[7]=-i*a+t*p,this}translate(e,t){const i=this.elements;return i[0]+=e*i[2],i[3]+=e*i[5],i[6]+=e*i[8],i[1]+=t*i[2],i[4]+=t*i[5],i[7]+=t*i[8],this}equals(e){const t=this.elements,i=e.elements;for(let r=0;r<9;r++)if(t[r]!==i[r])return!1;return!0}fromArray(e,t=0){for(let i=0;i<9;i++)this.elements[i]=e[i+t];return this}toArray(e=[],t=0){const i=this.elements;return e[t]=i[0],e[t+1]=i[1],e[t+2]=i[2],e[t+3]=i[3],e[t+4]=i[4],e[t+5]=i[5],e[t+6]=i[6],e[t+7]=i[7],e[t+8]=i[8],e}clone(){return(new this.constructor).fromArray(this.elements)}}function pB(n){if(0===n.length)return-1/0;let e=n[0];for(let t=1,i=n.length;te&&(e=n[t]);return e}function n2(n){return document.createElementNS("http://www.w3.org/1999/xhtml",n)}function mB(n,e=0){let t=3735928559^e,i=1103547991^e;for(let s,r=0;r>>16,2246822507)^Math.imul(i^i>>>13,3266489909),i=Math.imul(i^i>>>16,2246822507)^Math.imul(t^t>>>13,3266489909),4294967296*(2097151&i)+(t>>>0)}let Kg;js.prototype.isMatrix3=!0,Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array;class Yg{static getDataURL(e){if(/^data:/i.test(e.src)||typeof HTMLCanvasElement>"u")return e.src;let t;if(e instanceof HTMLCanvasElement)t=e;else{void 0===Kg&&(Kg=n2("canvas")),Kg.width=e.width,Kg.height=e.height;const i=Kg.getContext("2d");e instanceof ImageData?i.putImageData(e,0,0):i.drawImage(e,0,0,e.width,e.height),t=Kg}return t.width>2048||t.height>2048?(console.warn("THREE.ImageUtils.getDataURL: Image converted to jpg for performance reasons",e),t.toDataURL("image/jpeg",.6)):t.toDataURL("image/png")}}let nse=0;class io extends np{constructor(e=io.DEFAULT_IMAGE,t=io.DEFAULT_MAPPING,i=Uo,r=Uo,s=no,o=Hg,a=zo,c=fh,u=1,p=Ma){super(),Object.defineProperty(this,"id",{value:nse++}),this.uuid=rc(),this.name="",this.image=e,this.mipmaps=[],this.mapping=t,this.wrapS=i,this.wrapT=r,this.magFilter=s,this.minFilter=o,this.anisotropy=u,this.format=a,this.internalFormat=null,this.type=c,this.offset=new tt(0,0),this.repeat=new tt(1,1),this.center=new tt(0,0),this.rotation=0,this.matrixAutoUpdate=!0,this.matrix=new js,this.generateMipmaps=!0,this.premultiplyAlpha=!1,this.flipY=!0,this.unpackAlignment=4,this.encoding=p,this.userData={},this.version=0,this.onUpdate=null,this.isRenderTargetTexture=!1}updateMatrix(){this.matrix.setUvTransform(this.offset.x,this.offset.y,this.repeat.x,this.repeat.y,this.rotation,this.center.x,this.center.y)}clone(){return(new this.constructor).copy(this)}copy(e){return this.name=e.name,this.image=e.image,this.mipmaps=e.mipmaps.slice(0),this.mapping=e.mapping,this.wrapS=e.wrapS,this.wrapT=e.wrapT,this.magFilter=e.magFilter,this.minFilter=e.minFilter,this.anisotropy=e.anisotropy,this.format=e.format,this.internalFormat=e.internalFormat,this.type=e.type,this.offset.copy(e.offset),this.repeat.copy(e.repeat),this.center.copy(e.center),this.rotation=e.rotation,this.matrixAutoUpdate=e.matrixAutoUpdate,this.matrix.copy(e.matrix),this.generateMipmaps=e.generateMipmaps,this.premultiplyAlpha=e.premultiplyAlpha,this.flipY=e.flipY,this.unpackAlignment=e.unpackAlignment,this.encoding=e.encoding,this.userData=JSON.parse(JSON.stringify(e.userData)),this}toJSON(e){const t=void 0===e||"string"==typeof e;if(!t&&void 0!==e.textures[this.uuid])return e.textures[this.uuid];const i={metadata:{version:4.5,type:"Texture",generator:"Texture.toJSON"},uuid:this.uuid,name:this.name,mapping:this.mapping,repeat:[this.repeat.x,this.repeat.y],offset:[this.offset.x,this.offset.y],center:[this.center.x,this.center.y],rotation:this.rotation,wrap:[this.wrapS,this.wrapT],format:this.format,type:this.type,encoding:this.encoding,minFilter:this.minFilter,magFilter:this.magFilter,anisotropy:this.anisotropy,flipY:this.flipY,premultiplyAlpha:this.premultiplyAlpha,unpackAlignment:this.unpackAlignment};if(void 0!==this.image){const r=this.image;if(void 0===r.uuid&&(r.uuid=rc()),!t&&void 0===e.images[r.uuid]){let s;if(Array.isArray(r)){s=[];for(let o=0,a=r.length;o1)switch(this.wrapS){case KS:e.x=e.x-Math.floor(e.x);break;case Uo:e.x=e.x<0?0:1;break;case YS:e.x=1===Math.abs(Math.floor(e.x)%2)?Math.ceil(e.x)-e.x:e.x-Math.floor(e.x)}if(e.y<0||e.y>1)switch(this.wrapT){case KS:e.y=e.y-Math.floor(e.y);break;case Uo:e.y=e.y<0?0:1;break;case YS:e.y=1===Math.abs(Math.floor(e.y)%2)?Math.ceil(e.y)-e.y:e.y-Math.floor(e.y)}return this.flipY&&(e.y=1-e.y),e}set needsUpdate(e){!0===e&&this.version++}}function Fk(n){return typeof HTMLImageElement<"u"&&n instanceof HTMLImageElement||typeof HTMLCanvasElement<"u"&&n instanceof HTMLCanvasElement||typeof ImageBitmap<"u"&&n instanceof ImageBitmap?Yg.getDataURL(n):n.data?{data:Array.prototype.slice.call(n.data),width:n.width,height:n.height,type:n.data.constructor.name}:(console.warn("THREE.Texture: Unable to serialize Texture."),{})}io.DEFAULT_IMAGE=void 0,io.DEFAULT_MAPPING=300,io.prototype.isTexture=!0;class tr{constructor(e=0,t=0,i=0,r=1){this.x=e,this.y=t,this.z=i,this.w=r}get width(){return this.z}set width(e){this.z=e}get height(){return this.w}set height(e){this.w=e}set(e,t,i,r){return this.x=e,this.y=t,this.z=i,this.w=r,this}setScalar(e){return this.x=e,this.y=e,this.z=e,this.w=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setZ(e){return this.z=e,this}setW(e){return this.w=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;case 2:this.z=t;break;case 3:this.w=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;case 2:return this.z;case 3:return this.w;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y,this.z,this.w)}copy(e){return this.x=e.x,this.y=e.y,this.z=e.z,this.w=void 0!==e.w?e.w:1,this}add(e,t){return void 0!==t?(console.warn("THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this.z+=e.z,this.w+=e.w,this)}addScalar(e){return this.x+=e,this.y+=e,this.z+=e,this.w+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this.z=e.z+t.z,this.w=e.w+t.w,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this.z+=e.z*t,this.w+=e.w*t,this}sub(e,t){return void 0!==t?(console.warn("THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this.z-=e.z,this.w-=e.w,this)}subScalar(e){return this.x-=e,this.y-=e,this.z-=e,this.w-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this.z=e.z-t.z,this.w=e.w-t.w,this}multiply(e){return this.x*=e.x,this.y*=e.y,this.z*=e.z,this.w*=e.w,this}multiplyScalar(e){return this.x*=e,this.y*=e,this.z*=e,this.w*=e,this}applyMatrix4(e){const t=this.x,i=this.y,r=this.z,s=this.w,o=e.elements;return this.x=o[0]*t+o[4]*i+o[8]*r+o[12]*s,this.y=o[1]*t+o[5]*i+o[9]*r+o[13]*s,this.z=o[2]*t+o[6]*i+o[10]*r+o[14]*s,this.w=o[3]*t+o[7]*i+o[11]*r+o[15]*s,this}divideScalar(e){return this.multiplyScalar(1/e)}setAxisAngleFromQuaternion(e){this.w=2*Math.acos(e.w);const t=Math.sqrt(1-e.w*e.w);return t<1e-4?(this.x=1,this.y=0,this.z=0):(this.x=e.x/t,this.y=e.y/t,this.z=e.z/t),this}setAxisAngleFromRotationMatrix(e){let t,i,r,s;const c=e.elements,u=c[0],p=c[4],g=c[8],v=c[1],y=c[5],x=c[9],T=c[2],N=c[6],k=c[10];if(Math.abs(p-v)<.01&&Math.abs(g-T)<.01&&Math.abs(x-N)<.01){if(Math.abs(p+v)<.1&&Math.abs(g+T)<.1&&Math.abs(x+N)<.1&&Math.abs(u+y+k-3)<.1)return this.set(1,0,0,0),this;t=Math.PI;const H=(u+1)/2,G=(y+1)/2,X=(k+1)/2,se=(p+v)/4,K=(g+T)/4,he=(x+N)/4;return H>G&&H>X?H<.01?(i=0,r=.707106781,s=.707106781):(i=Math.sqrt(H),r=se/i,s=K/i):G>X?G<.01?(i=.707106781,r=0,s=.707106781):(r=Math.sqrt(G),i=se/r,s=he/r):X<.01?(i=.707106781,r=.707106781,s=0):(s=Math.sqrt(X),i=K/s,r=he/s),this.set(i,r,s,t),this}let A=Math.sqrt((N-x)*(N-x)+(g-T)*(g-T)+(v-p)*(v-p));return Math.abs(A)<.001&&(A=1),this.x=(N-x)/A,this.y=(g-T)/A,this.z=(v-p)/A,this.w=Math.acos((u+y+k-1)/2),this}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this.z=Math.min(this.z,e.z),this.w=Math.min(this.w,e.w),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this.z=Math.max(this.z,e.z),this.w=Math.max(this.w,e.w),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this.z=Math.max(e.z,Math.min(t.z,this.z)),this.w=Math.max(e.w,Math.min(t.w,this.w)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this.z=Math.max(e,Math.min(t,this.z)),this.w=Math.max(e,Math.min(t,this.w)),this}clampLength(e,t){const i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(e,Math.min(t,i)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this.w=Math.floor(this.w),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this.w=Math.ceil(this.w),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this.w=Math.round(this.w),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this.w=this.w<0?Math.ceil(this.w):Math.floor(this.w),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this.w=-this.w,this}dot(e){return this.x*e.x+this.y*e.y+this.z*e.z+this.w*e.w}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)+Math.abs(this.w)}normalize(){return this.divideScalar(this.length()||1)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this.z+=(e.z-this.z)*t,this.w+=(e.w-this.w)*t,this}lerpVectors(e,t,i){return this.x=e.x+(t.x-e.x)*i,this.y=e.y+(t.y-e.y)*i,this.z=e.z+(t.z-e.z)*i,this.w=e.w+(t.w-e.w)*i,this}equals(e){return e.x===this.x&&e.y===this.y&&e.z===this.z&&e.w===this.w}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this.z=e[t+2],this.w=e[t+3],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e[t+2]=this.z,e[t+3]=this.w,e}fromBufferAttribute(e,t,i){return void 0!==i&&console.warn("THREE.Vector4: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this.z=e.getZ(t),this.w=e.getW(t),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this.w=Math.random(),this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z,yield this.w}}tr.prototype.isVector4=!0;class Bc extends np{constructor(e,t,i={}){super(),this.width=e,this.height=t,this.depth=1,this.scissor=new tr(0,0,e,t),this.scissorTest=!1,this.viewport=new tr(0,0,e,t),this.texture=new io(void 0,i.mapping,i.wrapS,i.wrapT,i.magFilter,i.minFilter,i.format,i.type,i.anisotropy,i.encoding),this.texture.isRenderTargetTexture=!0,this.texture.image={width:e,height:t,depth:1},this.texture.generateMipmaps=void 0!==i.generateMipmaps&&i.generateMipmaps,this.texture.internalFormat=void 0!==i.internalFormat?i.internalFormat:null,this.texture.minFilter=void 0!==i.minFilter?i.minFilter:no,this.depthBuffer=void 0===i.depthBuffer||i.depthBuffer,this.stencilBuffer=void 0!==i.stencilBuffer&&i.stencilBuffer,this.depthTexture=void 0!==i.depthTexture?i.depthTexture:null}setTexture(e){e.image={width:this.width,height:this.height,depth:this.depth},this.texture=e}setSize(e,t,i=1){(this.width!==e||this.height!==t||this.depth!==i)&&(this.width=e,this.height=t,this.depth=i,this.texture.image.width=e,this.texture.image.height=t,this.texture.image.depth=i,this.dispose()),this.viewport.set(0,0,e,t),this.scissor.set(0,0,e,t)}clone(){return(new this.constructor).copy(this)}copy(e){return this.width=e.width,this.height=e.height,this.depth=e.depth,this.viewport.copy(e.viewport),this.texture=e.texture.clone(),this.texture.image={...this.texture.image},this.depthBuffer=e.depthBuffer,this.stencilBuffer=e.stencilBuffer,this.depthTexture=e.depthTexture,this}dispose(){this.dispatchEvent({type:"dispose"})}}Bc.prototype.isWebGLRenderTarget=!0,class ise extends Bc{constructor(e,t,i){super(e,t);const r=this.texture;this.texture=[];for(let s=0;s=0?1:-1,H=1-k*k;if(H>Number.EPSILON){const X=Math.sqrt(H),se=Math.atan2(X,k*A);N=Math.sin(N*se)/X,a=Math.sin(a*se)/X}const G=a*A;if(c=c*N+v*G,u=u*N+y*G,p=p*N+x*G,g=g*N+T*G,N===1-a){const X=1/Math.sqrt(c*c+u*u+p*p+g*g);c*=X,u*=X,p*=X,g*=X}}e[t]=c,e[t+1]=u,e[t+2]=p,e[t+3]=g}static multiplyQuaternionsFlat(e,t,i,r,s,o){const a=i[r],c=i[r+1],u=i[r+2],p=i[r+3],g=s[o],v=s[o+1],y=s[o+2],x=s[o+3];return e[t]=a*x+p*g+c*y-u*v,e[t+1]=c*x+p*v+u*g-a*y,e[t+2]=u*x+p*y+a*v-c*g,e[t+3]=p*x-a*g-c*v-u*y,e}get x(){return this._x}set x(e){this._x=e,this._onChangeCallback()}get y(){return this._y}set y(e){this._y=e,this._onChangeCallback()}get z(){return this._z}set z(e){this._z=e,this._onChangeCallback()}get w(){return this._w}set w(e){this._w=e,this._onChangeCallback()}set(e,t,i,r){return this._x=e,this._y=t,this._z=i,this._w=r,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._w)}copy(e){return this._x=e.x,this._y=e.y,this._z=e.z,this._w=e.w,this._onChangeCallback(),this}setFromEuler(e,t){if(!e||!e.isEuler)throw new Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");const i=e._x,r=e._y,s=e._z,o=e._order,a=Math.cos,c=Math.sin,u=a(i/2),p=a(r/2),g=a(s/2),v=c(i/2),y=c(r/2),x=c(s/2);switch(o){case"XYZ":this._x=v*p*g+u*y*x,this._y=u*y*g-v*p*x,this._z=u*p*x+v*y*g,this._w=u*p*g-v*y*x;break;case"YXZ":this._x=v*p*g+u*y*x,this._y=u*y*g-v*p*x,this._z=u*p*x-v*y*g,this._w=u*p*g+v*y*x;break;case"ZXY":this._x=v*p*g-u*y*x,this._y=u*y*g+v*p*x,this._z=u*p*x+v*y*g,this._w=u*p*g-v*y*x;break;case"ZYX":this._x=v*p*g-u*y*x,this._y=u*y*g+v*p*x,this._z=u*p*x-v*y*g,this._w=u*p*g+v*y*x;break;case"YZX":this._x=v*p*g+u*y*x,this._y=u*y*g+v*p*x,this._z=u*p*x-v*y*g,this._w=u*p*g-v*y*x;break;case"XZY":this._x=v*p*g-u*y*x,this._y=u*y*g-v*p*x,this._z=u*p*x+v*y*g,this._w=u*p*g+v*y*x;break;default:console.warn("THREE.Quaternion: .setFromEuler() encountered an unknown order: "+o)}return!1!==t&&this._onChangeCallback(),this}setFromAxisAngle(e,t){const i=t/2,r=Math.sin(i);return this._x=e.x*r,this._y=e.y*r,this._z=e.z*r,this._w=Math.cos(i),this._onChangeCallback(),this}setFromRotationMatrix(e){const t=e.elements,i=t[0],r=t[4],s=t[8],o=t[1],a=t[5],c=t[9],u=t[2],p=t[6],g=t[10],v=i+a+g;if(v>0){const y=.5/Math.sqrt(v+1);this._w=.25/y,this._x=(p-c)*y,this._y=(s-u)*y,this._z=(o-r)*y}else if(i>a&&i>g){const y=2*Math.sqrt(1+i-a-g);this._w=(p-c)/y,this._x=.25*y,this._y=(r+o)/y,this._z=(s+u)/y}else if(a>g){const y=2*Math.sqrt(1+a-i-g);this._w=(s-u)/y,this._x=(r+o)/y,this._y=.25*y,this._z=(c+p)/y}else{const y=2*Math.sqrt(1+g-i-a);this._w=(o-r)/y,this._x=(s+u)/y,this._y=(c+p)/y,this._z=.25*y}return this._onChangeCallback(),this}setFromUnitVectors(e,t){let i=e.dot(t)+1;return iMath.abs(e.z)?(this._x=-e.y,this._y=e.x,this._z=0,this._w=i):(this._x=0,this._y=-e.z,this._z=e.y,this._w=i)):(this._x=e.y*t.z-e.z*t.y,this._y=e.z*t.x-e.x*t.z,this._z=e.x*t.y-e.y*t.x,this._w=i),this.normalize()}angleTo(e){return 2*Math.acos(Math.abs(Mo(this.dot(e),-1,1)))}rotateTowards(e,t){const i=this.angleTo(e);if(0===i)return this;const r=Math.min(1,t/i);return this.slerp(e,r),this}identity(){return this.set(0,0,0,1)}invert(){return this.conjugate()}conjugate(){return this._x*=-1,this._y*=-1,this._z*=-1,this._onChangeCallback(),this}dot(e){return this._x*e._x+this._y*e._y+this._z*e._z+this._w*e._w}lengthSq(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w}length(){return Math.sqrt(this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w)}normalize(){let e=this.length();return 0===e?(this._x=0,this._y=0,this._z=0,this._w=1):(e=1/e,this._x=this._x*e,this._y=this._y*e,this._z=this._z*e,this._w=this._w*e),this._onChangeCallback(),this}multiply(e,t){return void 0!==t?(console.warn("THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead."),this.multiplyQuaternions(e,t)):this.multiplyQuaternions(this,e)}premultiply(e){return this.multiplyQuaternions(e,this)}multiplyQuaternions(e,t){const i=e._x,r=e._y,s=e._z,o=e._w,a=t._x,c=t._y,u=t._z,p=t._w;return this._x=i*p+o*a+r*u-s*c,this._y=r*p+o*c+s*a-i*u,this._z=s*p+o*u+i*c-r*a,this._w=o*p-i*a-r*c-s*u,this._onChangeCallback(),this}slerp(e,t){if(0===t)return this;if(1===t)return this.copy(e);const i=this._x,r=this._y,s=this._z,o=this._w;let a=o*e._w+i*e._x+r*e._y+s*e._z;if(a<0?(this._w=-e._w,this._x=-e._x,this._y=-e._y,this._z=-e._z,a=-a):this.copy(e),a>=1)return this._w=o,this._x=i,this._y=r,this._z=s,this;const c=1-a*a;if(c<=Number.EPSILON){const y=1-t;return this._w=y*o+t*this._w,this._x=y*i+t*this._x,this._y=y*r+t*this._y,this._z=y*s+t*this._z,this.normalize(),this._onChangeCallback(),this}const u=Math.sqrt(c),p=Math.atan2(u,a),g=Math.sin((1-t)*p)/u,v=Math.sin(t*p)/u;return this._w=o*g+this._w*v,this._x=i*g+this._x*v,this._y=r*g+this._y*v,this._z=s*g+this._z*v,this._onChangeCallback(),this}slerpQuaternions(e,t,i){this.copy(e).slerp(t,i)}random(){const e=Math.random(),t=Math.sqrt(1-e),i=Math.sqrt(e),r=2*Math.PI*Math.random(),s=2*Math.PI*Math.random();return this.set(t*Math.cos(r),i*Math.sin(s),i*Math.cos(s),t*Math.sin(r))}equals(e){return e._x===this._x&&e._y===this._y&&e._z===this._z&&e._w===this._w}fromArray(e,t=0){return this._x=e[t],this._y=e[t+1],this._z=e[t+2],this._w=e[t+3],this._onChangeCallback(),this}toArray(e=[],t=0){return e[t]=this._x,e[t+1]=this._y,e[t+2]=this._z,e[t+3]=this._w,e}fromBufferAttribute(e,t){return this._x=e.getX(t),this._y=e.getY(t),this._z=e.getZ(t),this._w=e.getW(t),this}_onChange(e){return this._onChangeCallback=e,this}_onChangeCallback(){}}Go.prototype.isQuaternion=!0;class ne{constructor(e=0,t=0,i=0){this.x=e,this.y=t,this.z=i}set(e,t,i){return void 0===i&&(i=this.z),this.x=e,this.y=t,this.z=i,this}setScalar(e){return this.x=e,this.y=e,this.z=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setZ(e){return this.z=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;case 2:this.z=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y,this.z)}copy(e){return this.x=e.x,this.y=e.y,this.z=e.z,this}add(e,t){return void 0!==t?(console.warn("THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this.z+=e.z,this)}addScalar(e){return this.x+=e,this.y+=e,this.z+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this.z=e.z+t.z,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this.z+=e.z*t,this}sub(e,t){return void 0!==t?(console.warn("THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this.z-=e.z,this)}subScalar(e){return this.x-=e,this.y-=e,this.z-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this.z=e.z-t.z,this}multiply(e,t){return void 0!==t?(console.warn("THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead."),this.multiplyVectors(e,t)):(this.x*=e.x,this.y*=e.y,this.z*=e.z,this)}multiplyScalar(e){return this.x*=e,this.y*=e,this.z*=e,this}multiplyVectors(e,t){return this.x=e.x*t.x,this.y=e.y*t.y,this.z=e.z*t.z,this}applyEuler(e){return e&&e.isEuler||console.error("THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order."),this.applyQuaternion(gB.setFromEuler(e))}applyAxisAngle(e,t){return this.applyQuaternion(gB.setFromAxisAngle(e,t))}applyMatrix3(e){const t=this.x,i=this.y,r=this.z,s=e.elements;return this.x=s[0]*t+s[3]*i+s[6]*r,this.y=s[1]*t+s[4]*i+s[7]*r,this.z=s[2]*t+s[5]*i+s[8]*r,this}applyNormalMatrix(e){return this.applyMatrix3(e).normalize()}applyMatrix4(e){const t=this.x,i=this.y,r=this.z,s=e.elements,o=1/(s[3]*t+s[7]*i+s[11]*r+s[15]);return this.x=(s[0]*t+s[4]*i+s[8]*r+s[12])*o,this.y=(s[1]*t+s[5]*i+s[9]*r+s[13])*o,this.z=(s[2]*t+s[6]*i+s[10]*r+s[14])*o,this}applyQuaternion(e){const t=this.x,i=this.y,r=this.z,s=e.x,o=e.y,a=e.z,c=e.w,u=c*t+o*r-a*i,p=c*i+a*t-s*r,g=c*r+s*i-o*t,v=-s*t-o*i-a*r;return this.x=u*c+v*-s+p*-a-g*-o,this.y=p*c+v*-o+g*-s-u*-a,this.z=g*c+v*-a+u*-o-p*-s,this}project(e){return this.applyMatrix4(e.matrixWorldInverse).applyMatrix4(e.projectionMatrix)}unproject(e){return this.applyMatrix4(e.projectionMatrixInverse).applyMatrix4(e.matrixWorld)}transformDirection(e){const t=this.x,i=this.y,r=this.z,s=e.elements;return this.x=s[0]*t+s[4]*i+s[8]*r,this.y=s[1]*t+s[5]*i+s[9]*r,this.z=s[2]*t+s[6]*i+s[10]*r,this.normalize()}divide(e){return this.x/=e.x,this.y/=e.y,this.z/=e.z,this}divideScalar(e){return this.multiplyScalar(1/e)}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this.z=Math.min(this.z,e.z),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this.z=Math.max(this.z,e.z),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this.z=Math.max(e.z,Math.min(t.z,this.z)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this.z=Math.max(e,Math.min(t,this.z)),this}clampLength(e,t){const i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(e,Math.min(t,i)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this}dot(e){return this.x*e.x+this.y*e.y+this.z*e.z}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)}normalize(){return this.divideScalar(this.length()||1)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this.z+=(e.z-this.z)*t,this}lerpVectors(e,t,i){return this.x=e.x+(t.x-e.x)*i,this.y=e.y+(t.y-e.y)*i,this.z=e.z+(t.z-e.z)*i,this}cross(e,t){return void 0!==t?(console.warn("THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead."),this.crossVectors(e,t)):this.crossVectors(this,e)}crossVectors(e,t){const i=e.x,r=e.y,s=e.z,o=t.x,a=t.y,c=t.z;return this.x=r*c-s*a,this.y=s*o-i*c,this.z=i*a-r*o,this}projectOnVector(e){const t=e.lengthSq();if(0===t)return this.set(0,0,0);const i=e.dot(this)/t;return this.copy(e).multiplyScalar(i)}projectOnPlane(e){return Pk.copy(this).projectOnVector(e),this.sub(Pk)}reflect(e){return this.sub(Pk.copy(e).multiplyScalar(2*this.dot(e)))}angleTo(e){const t=Math.sqrt(this.lengthSq()*e.lengthSq());if(0===t)return Math.PI/2;const i=this.dot(e)/t;return Math.acos(Mo(i,-1,1))}distanceTo(e){return Math.sqrt(this.distanceToSquared(e))}distanceToSquared(e){const t=this.x-e.x,i=this.y-e.y,r=this.z-e.z;return t*t+i*i+r*r}manhattanDistanceTo(e){return Math.abs(this.x-e.x)+Math.abs(this.y-e.y)+Math.abs(this.z-e.z)}setFromSpherical(e){return this.setFromSphericalCoords(e.radius,e.phi,e.theta)}setFromSphericalCoords(e,t,i){const r=Math.sin(t)*e;return this.x=r*Math.sin(i),this.y=Math.cos(t)*e,this.z=r*Math.cos(i),this}setFromCylindrical(e){return this.setFromCylindricalCoords(e.radius,e.theta,e.y)}setFromCylindricalCoords(e,t,i){return this.x=e*Math.sin(t),this.y=i,this.z=e*Math.cos(t),this}setFromMatrixPosition(e){const t=e.elements;return this.x=t[12],this.y=t[13],this.z=t[14],this}setFromMatrixScale(e){const t=this.setFromMatrixColumn(e,0).length(),i=this.setFromMatrixColumn(e,1).length(),r=this.setFromMatrixColumn(e,2).length();return this.x=t,this.y=i,this.z=r,this}setFromMatrixColumn(e,t){return this.fromArray(e.elements,4*t)}setFromMatrix3Column(e,t){return this.fromArray(e.elements,3*t)}equals(e){return e.x===this.x&&e.y===this.y&&e.z===this.z}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this.z=e[t+2],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e[t+2]=this.z,e}fromBufferAttribute(e,t,i){return void 0!==i&&console.warn("THREE.Vector3: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this.z=e.getZ(t),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this}randomDirection(){const e=2*(Math.random()-.5),t=Math.random()*Math.PI*2,i=Math.sqrt(1-e**2);return this.x=i*Math.cos(t),this.y=i*Math.sin(t),this.z=e,this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z}}ne.prototype.isVector3=!0;const Pk=new ne,gB=new Go;class Vc{constructor(e=new ne(1/0,1/0,1/0),t=new ne(-1/0,-1/0,-1/0)){this.min=e,this.max=t}set(e,t){return this.min.copy(e),this.max.copy(t),this}setFromArray(e){let t=1/0,i=1/0,r=1/0,s=-1/0,o=-1/0,a=-1/0;for(let c=0,u=e.length;cs&&(s=p),g>o&&(o=g),v>a&&(a=v)}return this.min.set(t,i,r),this.max.set(s,o,a),this}setFromBufferAttribute(e){let t=1/0,i=1/0,r=1/0,s=-1/0,o=-1/0,a=-1/0;for(let c=0,u=e.count;cs&&(s=p),g>o&&(o=g),v>a&&(a=v)}return this.min.set(t,i,r),this.max.set(s,o,a),this}setFromPoints(e){this.makeEmpty();for(let t=0,i=e.length;tthis.max.x||e.ythis.max.y||e.zthis.max.z)}containsBox(e){return this.min.x<=e.min.x&&e.max.x<=this.max.x&&this.min.y<=e.min.y&&e.max.y<=this.max.y&&this.min.z<=e.min.z&&e.max.z<=this.max.z}getParameter(e,t){return t.set((e.x-this.min.x)/(this.max.x-this.min.x),(e.y-this.min.y)/(this.max.y-this.min.y),(e.z-this.min.z)/(this.max.z-this.min.z))}intersectsBox(e){return!(e.max.xthis.max.x||e.max.ythis.max.y||e.max.zthis.max.z)}intersectsSphere(e){return this.clampPoint(e.center,Ly),Ly.distanceToSquared(e.center)<=e.radius*e.radius}intersectsPlane(e){let t,i;return e.normal.x>0?(t=e.normal.x*this.min.x,i=e.normal.x*this.max.x):(t=e.normal.x*this.max.x,i=e.normal.x*this.min.x),e.normal.y>0?(t+=e.normal.y*this.min.y,i+=e.normal.y*this.max.y):(t+=e.normal.y*this.max.y,i+=e.normal.y*this.min.y),e.normal.z>0?(t+=e.normal.z*this.min.z,i+=e.normal.z*this.max.z):(t+=e.normal.z*this.max.z,i+=e.normal.z*this.min.z),t<=-e.constant&&i>=-e.constant}intersectsTriangle(e){if(this.isEmpty())return!1;this.getCenter(Ny),r2.subVectors(this.max,Ny),Xg.subVectors(e.a,Ny),Zg.subVectors(e.b,Ny),Jg.subVectors(e.c,Ny),ph.subVectors(Zg,Xg),mh.subVectors(Jg,Zg),rp.subVectors(Xg,Jg);let t=[0,-ph.z,ph.y,0,-mh.z,mh.y,0,-rp.z,rp.y,ph.z,0,-ph.x,mh.z,0,-mh.x,rp.z,0,-rp.x,-ph.y,ph.x,0,-mh.y,mh.x,0,-rp.y,rp.x,0];return!(!Lk(t,Xg,Zg,Jg,r2)||(t=[1,0,0,0,1,0,0,0,1],!Lk(t,Xg,Zg,Jg,r2)))&&(s2.crossVectors(ph,mh),t=[s2.x,s2.y,s2.z],Lk(t,Xg,Zg,Jg,r2))}clampPoint(e,t){return t.copy(e).clamp(this.min,this.max)}distanceToPoint(e){return Ly.copy(e).clamp(this.min,this.max).sub(e).length()}getBoundingSphere(e){return this.getCenter(e.center),e.radius=.5*this.getSize(Ly).length(),e}intersect(e){return this.min.max(e.min),this.max.min(e.max),this.isEmpty()&&this.makeEmpty(),this}union(e){return this.min.min(e.min),this.max.max(e.max),this}applyMatrix4(e){return this.isEmpty()||(Xd[0].set(this.min.x,this.min.y,this.min.z).applyMatrix4(e),Xd[1].set(this.min.x,this.min.y,this.max.z).applyMatrix4(e),Xd[2].set(this.min.x,this.max.y,this.min.z).applyMatrix4(e),Xd[3].set(this.min.x,this.max.y,this.max.z).applyMatrix4(e),Xd[4].set(this.max.x,this.min.y,this.min.z).applyMatrix4(e),Xd[5].set(this.max.x,this.min.y,this.max.z).applyMatrix4(e),Xd[6].set(this.max.x,this.max.y,this.min.z).applyMatrix4(e),Xd[7].set(this.max.x,this.max.y,this.max.z).applyMatrix4(e),this.setFromPoints(Xd)),this}translate(e){return this.min.add(e),this.max.add(e),this}equals(e){return e.min.equals(this.min)&&e.max.equals(this.max)}}Vc.prototype.isBox3=!0;const Xd=[new ne,new ne,new ne,new ne,new ne,new ne,new ne,new ne],Ly=new ne,Ok=new Vc,Xg=new ne,Zg=new ne,Jg=new ne,ph=new ne,mh=new ne,rp=new ne,Ny=new ne,r2=new ne,s2=new ne,sp=new ne;function Lk(n,e,t,i,r){for(let s=0,o=n.length-3;s<=o;s+=3){sp.fromArray(n,s);const a=r.x*Math.abs(sp.x)+r.y*Math.abs(sp.y)+r.z*Math.abs(sp.z),c=e.dot(sp),u=t.dot(sp),p=i.dot(sp);if(Math.max(-Math.max(c,u,p),Math.min(c,u,p))>a)return!1}return!0}const rse=new Vc,_B=new ne,Nk=new ne,Bk=new ne;class op{constructor(e=new ne,t=-1){this.center=e,this.radius=t}set(e,t){return this.center.copy(e),this.radius=t,this}setFromPoints(e,t){const i=this.center;void 0!==t?i.copy(t):rse.setFromPoints(e).getCenter(i);let r=0;for(let s=0,o=e.length;sthis.radius*this.radius&&(t.sub(this.center).normalize(),t.multiplyScalar(this.radius).add(this.center)),t}getBoundingBox(e){return this.isEmpty()?(e.makeEmpty(),e):(e.set(this.center,this.center),e.expandByScalar(this.radius),e)}applyMatrix4(e){return this.center.applyMatrix4(e),this.radius=this.radius*e.getMaxScaleOnAxis(),this}translate(e){return this.center.add(e),this}expandByPoint(e){Bk.subVectors(e,this.center);const t=Bk.lengthSq();if(t>this.radius*this.radius){const i=Math.sqrt(t),r=.5*(i-this.radius);this.center.add(Bk.multiplyScalar(r/i)),this.radius+=r}return this}union(e){return Nk.subVectors(e.center,this.center).normalize().multiplyScalar(e.radius),this.expandByPoint(_B.copy(e.center).add(Nk)),this.expandByPoint(_B.copy(e.center).sub(Nk)),this}equals(e){return e.center.equals(this.center)&&e.radius===this.radius}clone(){return(new this.constructor).copy(this)}}const Zd=new ne,Vk=new ne,o2=new ne,gh=new ne,Hk=new ne,a2=new ne,Uk=new ne;class ap{constructor(e=new ne,t=new ne(0,0,-1)){this.origin=e,this.direction=t}set(e,t){return this.origin.copy(e),this.direction.copy(t),this}copy(e){return this.origin.copy(e.origin),this.direction.copy(e.direction),this}at(e,t){return t.copy(this.direction).multiplyScalar(e).add(this.origin)}lookAt(e){return this.direction.copy(e).sub(this.origin).normalize(),this}recast(e){return this.origin.copy(this.at(e,Zd)),this}closestPointToPoint(e,t){t.subVectors(e,this.origin);const i=t.dot(this.direction);return i<0?t.copy(this.origin):t.copy(this.direction).multiplyScalar(i).add(this.origin)}distanceToPoint(e){return Math.sqrt(this.distanceSqToPoint(e))}distanceSqToPoint(e){const t=Zd.subVectors(e,this.origin).dot(this.direction);return t<0?this.origin.distanceToSquared(e):(Zd.copy(this.direction).multiplyScalar(t).add(this.origin),Zd.distanceToSquared(e))}distanceSqToSegment(e,t,i,r){Vk.copy(e).add(t).multiplyScalar(.5),o2.copy(t).sub(e).normalize(),gh.copy(this.origin).sub(Vk);const s=.5*e.distanceTo(t),o=-this.direction.dot(o2),a=gh.dot(this.direction),c=-gh.dot(o2),u=gh.lengthSq(),p=Math.abs(1-o*o);let g,v,y,x;if(p>0)if(g=o*c-a,v=o*a-c,x=s*p,g>=0)if(v>=-x)if(v<=x){const T=1/p;g*=T,v*=T,y=g*(g+o*v+2*a)+v*(o*g+v+2*c)+u}else v=s,g=Math.max(0,-(o*v+a)),y=-g*g+v*(v+2*c)+u;else v=-s,g=Math.max(0,-(o*v+a)),y=-g*g+v*(v+2*c)+u;else v<=-x?(g=Math.max(0,-(-o*s+a)),v=g>0?-s:Math.min(Math.max(-s,-c),s),y=-g*g+v*(v+2*c)+u):v<=x?(g=0,v=Math.min(Math.max(-s,-c),s),y=v*(v+2*c)+u):(g=Math.max(0,-(o*s+a)),v=g>0?s:Math.min(Math.max(-s,-c),s),y=-g*g+v*(v+2*c)+u);else v=o>0?-s:s,g=Math.max(0,-(o*v+a)),y=-g*g+v*(v+2*c)+u;return i&&i.copy(this.direction).multiplyScalar(g).add(this.origin),r&&r.copy(o2).multiplyScalar(v).add(Vk),y}intersectSphere(e,t){Zd.subVectors(e.center,this.origin);const i=Zd.dot(this.direction),r=Zd.dot(Zd)-i*i,s=e.radius*e.radius;if(r>s)return null;const o=Math.sqrt(s-r),a=i-o,c=i+o;return a<0&&c<0?null:this.at(a<0?c:a,t)}intersectsSphere(e){return this.distanceSqToPoint(e.center)<=e.radius*e.radius}distanceToPlane(e){const t=e.normal.dot(this.direction);if(0===t)return 0===e.distanceToPoint(this.origin)?0:null;const i=-(this.origin.dot(e.normal)+e.constant)/t;return i>=0?i:null}intersectPlane(e,t){const i=this.distanceToPlane(e);return null===i?null:this.at(i,t)}intersectsPlane(e){const t=e.distanceToPoint(this.origin);return 0===t||e.normal.dot(this.direction)*t<0}intersectBox(e,t){let i,r,s,o,a,c;const u=1/this.direction.x,p=1/this.direction.y,g=1/this.direction.z,v=this.origin;return u>=0?(i=(e.min.x-v.x)*u,r=(e.max.x-v.x)*u):(i=(e.max.x-v.x)*u,r=(e.min.x-v.x)*u),p>=0?(s=(e.min.y-v.y)*p,o=(e.max.y-v.y)*p):(s=(e.max.y-v.y)*p,o=(e.min.y-v.y)*p),i>o||s>r||((s>i||i!=i)&&(i=s),(o=0?(a=(e.min.z-v.z)*g,c=(e.max.z-v.z)*g):(a=(e.max.z-v.z)*g,c=(e.min.z-v.z)*g),i>c||a>r)||((a>i||i!=i)&&(i=a),(c=0?i:r,t)}intersectsBox(e){return null!==this.intersectBox(e,Zd)}intersectTriangle(e,t,i,r,s){Hk.subVectors(t,e),a2.subVectors(i,e),Uk.crossVectors(Hk,a2);let a,o=this.direction.dot(Uk);if(o>0){if(r)return null;a=1}else{if(!(o<0))return null;a=-1,o=-o}gh.subVectors(this.origin,e);const c=a*this.direction.dot(a2.crossVectors(gh,a2));if(c<0)return null;const u=a*this.direction.dot(Hk.cross(gh));if(u<0||c+u>o)return null;const p=-a*gh.dot(Uk);return p<0?null:this.at(p/o,s)}applyMatrix4(e){return this.origin.applyMatrix4(e),this.direction.transformDirection(e),this}equals(e){return e.origin.equals(this.origin)&&e.direction.equals(this.direction)}clone(){return(new this.constructor).copy(this)}}class Gt{constructor(){this.elements=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],arguments.length>0&&console.error("THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.")}set(e,t,i,r,s,o,a,c,u,p,g,v,y,x,T,N){const k=this.elements;return k[0]=e,k[4]=t,k[8]=i,k[12]=r,k[1]=s,k[5]=o,k[9]=a,k[13]=c,k[2]=u,k[6]=p,k[10]=g,k[14]=v,k[3]=y,k[7]=x,k[11]=T,k[15]=N,this}identity(){return this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1),this}clone(){return(new Gt).fromArray(this.elements)}copy(e){const t=this.elements,i=e.elements;return t[0]=i[0],t[1]=i[1],t[2]=i[2],t[3]=i[3],t[4]=i[4],t[5]=i[5],t[6]=i[6],t[7]=i[7],t[8]=i[8],t[9]=i[9],t[10]=i[10],t[11]=i[11],t[12]=i[12],t[13]=i[13],t[14]=i[14],t[15]=i[15],this}copyPosition(e){const t=this.elements,i=e.elements;return t[12]=i[12],t[13]=i[13],t[14]=i[14],this}setFromMatrix3(e){const t=e.elements;return this.set(t[0],t[3],t[6],0,t[1],t[4],t[7],0,t[2],t[5],t[8],0,0,0,0,1),this}extractBasis(e,t,i){return e.setFromMatrixColumn(this,0),t.setFromMatrixColumn(this,1),i.setFromMatrixColumn(this,2),this}makeBasis(e,t,i){return this.set(e.x,t.x,i.x,0,e.y,t.y,i.y,0,e.z,t.z,i.z,0,0,0,0,1),this}extractRotation(e){const t=this.elements,i=e.elements,r=1/Qg.setFromMatrixColumn(e,0).length(),s=1/Qg.setFromMatrixColumn(e,1).length(),o=1/Qg.setFromMatrixColumn(e,2).length();return t[0]=i[0]*r,t[1]=i[1]*r,t[2]=i[2]*r,t[3]=0,t[4]=i[4]*s,t[5]=i[5]*s,t[6]=i[6]*s,t[7]=0,t[8]=i[8]*o,t[9]=i[9]*o,t[10]=i[10]*o,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,this}makeRotationFromEuler(e){e&&e.isEuler||console.error("THREE.Matrix4: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.");const t=this.elements,i=e.x,r=e.y,s=e.z,o=Math.cos(i),a=Math.sin(i),c=Math.cos(r),u=Math.sin(r),p=Math.cos(s),g=Math.sin(s);if("XYZ"===e.order){const v=o*p,y=o*g,x=a*p,T=a*g;t[0]=c*p,t[4]=-c*g,t[8]=u,t[1]=y+x*u,t[5]=v-T*u,t[9]=-a*c,t[2]=T-v*u,t[6]=x+y*u,t[10]=o*c}else if("YXZ"===e.order){const v=c*p,y=c*g,x=u*p,T=u*g;t[0]=v+T*a,t[4]=x*a-y,t[8]=o*u,t[1]=o*g,t[5]=o*p,t[9]=-a,t[2]=y*a-x,t[6]=T+v*a,t[10]=o*c}else if("ZXY"===e.order){const v=c*p,y=c*g,x=u*p,T=u*g;t[0]=v-T*a,t[4]=-o*g,t[8]=x+y*a,t[1]=y+x*a,t[5]=o*p,t[9]=T-v*a,t[2]=-o*u,t[6]=a,t[10]=o*c}else if("ZYX"===e.order){const v=o*p,y=o*g,x=a*p,T=a*g;t[0]=c*p,t[4]=x*u-y,t[8]=v*u+T,t[1]=c*g,t[5]=T*u+v,t[9]=y*u-x,t[2]=-u,t[6]=a*c,t[10]=o*c}else if("YZX"===e.order){const v=o*c,y=o*u,x=a*c,T=a*u;t[0]=c*p,t[4]=T-v*g,t[8]=x*g+y,t[1]=g,t[5]=o*p,t[9]=-a*p,t[2]=-u*p,t[6]=y*g+x,t[10]=v-T*g}else if("XZY"===e.order){const v=o*c,y=o*u,x=a*c,T=a*u;t[0]=c*p,t[4]=-g,t[8]=u*p,t[1]=v*g+T,t[5]=o*p,t[9]=y*g-x,t[2]=x*g-y,t[6]=a*p,t[10]=T*g+v}return t[3]=0,t[7]=0,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,this}makeRotationFromQuaternion(e){return this.compose(sse,e,ose)}lookAt(e,t,i){const r=this.elements;return sc.subVectors(e,t),0===sc.lengthSq()&&(sc.z=1),sc.normalize(),_h.crossVectors(i,sc),0===_h.lengthSq()&&(1===Math.abs(i.z)?sc.x+=1e-4:sc.z+=1e-4,sc.normalize(),_h.crossVectors(i,sc)),_h.normalize(),c2.crossVectors(sc,_h),r[0]=_h.x,r[4]=c2.x,r[8]=sc.x,r[1]=_h.y,r[5]=c2.y,r[9]=sc.y,r[2]=_h.z,r[6]=c2.z,r[10]=sc.z,this}multiply(e,t){return void 0!==t?(console.warn("THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead."),this.multiplyMatrices(e,t)):this.multiplyMatrices(this,e)}premultiply(e){return this.multiplyMatrices(e,this)}multiplyMatrices(e,t){const i=e.elements,r=t.elements,s=this.elements,o=i[0],a=i[4],c=i[8],u=i[12],p=i[1],g=i[5],v=i[9],y=i[13],x=i[2],T=i[6],N=i[10],k=i[14],A=i[3],H=i[7],G=i[11],X=i[15],se=r[0],K=r[4],he=r[8],De=r[12],Te=r[1],ge=r[5],Qe=r[9],Pe=r[13],Oe=r[2],Ve=r[6],ye=r[10],Me=r[14],je=r[3],lt=r[7],ze=r[11],Ke=r[15];return s[0]=o*se+a*Te+c*Oe+u*je,s[4]=o*K+a*ge+c*Ve+u*lt,s[8]=o*he+a*Qe+c*ye+u*ze,s[12]=o*De+a*Pe+c*Me+u*Ke,s[1]=p*se+g*Te+v*Oe+y*je,s[5]=p*K+g*ge+v*Ve+y*lt,s[9]=p*he+g*Qe+v*ye+y*ze,s[13]=p*De+g*Pe+v*Me+y*Ke,s[2]=x*se+T*Te+N*Oe+k*je,s[6]=x*K+T*ge+N*Ve+k*lt,s[10]=x*he+T*Qe+N*ye+k*ze,s[14]=x*De+T*Pe+N*Me+k*Ke,s[3]=A*se+H*Te+G*Oe+X*je,s[7]=A*K+H*ge+G*Ve+X*lt,s[11]=A*he+H*Qe+G*ye+X*ze,s[15]=A*De+H*Pe+G*Me+X*Ke,this}multiplyScalar(e){const t=this.elements;return t[0]*=e,t[4]*=e,t[8]*=e,t[12]*=e,t[1]*=e,t[5]*=e,t[9]*=e,t[13]*=e,t[2]*=e,t[6]*=e,t[10]*=e,t[14]*=e,t[3]*=e,t[7]*=e,t[11]*=e,t[15]*=e,this}determinant(){const e=this.elements,t=e[0],i=e[4],r=e[8],s=e[12],o=e[1],a=e[5],c=e[9],u=e[13],p=e[2],g=e[6],v=e[10],y=e[14];return e[3]*(+s*c*g-r*u*g-s*a*v+i*u*v+r*a*y-i*c*y)+e[7]*(+t*c*y-t*u*v+s*o*v-r*o*y+r*u*p-s*c*p)+e[11]*(+t*u*g-t*a*y-s*o*g+i*o*y+s*a*p-i*u*p)+e[15]*(-r*a*p-t*c*g+t*a*v+r*o*g-i*o*v+i*c*p)}transpose(){const e=this.elements;let t;return t=e[1],e[1]=e[4],e[4]=t,t=e[2],e[2]=e[8],e[8]=t,t=e[6],e[6]=e[9],e[9]=t,t=e[3],e[3]=e[12],e[12]=t,t=e[7],e[7]=e[13],e[13]=t,t=e[11],e[11]=e[14],e[14]=t,this}setPosition(e,t,i){const r=this.elements;return e.isVector3?(r[12]=e.x,r[13]=e.y,r[14]=e.z):(r[12]=e,r[13]=t,r[14]=i),this}invert(){const e=this.elements,t=e[0],i=e[1],r=e[2],s=e[3],o=e[4],a=e[5],c=e[6],u=e[7],p=e[8],g=e[9],v=e[10],y=e[11],x=e[12],T=e[13],N=e[14],k=e[15],A=g*N*u-T*v*u+T*c*y-a*N*y-g*c*k+a*v*k,H=x*v*u-p*N*u-x*c*y+o*N*y+p*c*k-o*v*k,G=p*T*u-x*g*u+x*a*y-o*T*y-p*a*k+o*g*k,X=x*g*c-p*T*c-x*a*v+o*T*v+p*a*N-o*g*N,se=t*A+i*H+r*G+s*X;if(0===se)return this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);const K=1/se;return e[0]=A*K,e[1]=(T*v*s-g*N*s-T*r*y+i*N*y+g*r*k-i*v*k)*K,e[2]=(a*N*s-T*c*s+T*r*u-i*N*u-a*r*k+i*c*k)*K,e[3]=(g*c*s-a*v*s-g*r*u+i*v*u+a*r*y-i*c*y)*K,e[4]=H*K,e[5]=(p*N*s-x*v*s+x*r*y-t*N*y-p*r*k+t*v*k)*K,e[6]=(x*c*s-o*N*s-x*r*u+t*N*u+o*r*k-t*c*k)*K,e[7]=(o*v*s-p*c*s+p*r*u-t*v*u-o*r*y+t*c*y)*K,e[8]=G*K,e[9]=(x*g*s-p*T*s-x*i*y+t*T*y+p*i*k-t*g*k)*K,e[10]=(o*T*s-x*a*s+x*i*u-t*T*u-o*i*k+t*a*k)*K,e[11]=(p*a*s-o*g*s-p*i*u+t*g*u+o*i*y-t*a*y)*K,e[12]=X*K,e[13]=(p*T*r-x*g*r+x*i*v-t*T*v-p*i*N+t*g*N)*K,e[14]=(x*a*r-o*T*r-x*i*c+t*T*c+o*i*N-t*a*N)*K,e[15]=(o*g*r-p*a*r+p*i*c-t*g*c-o*i*v+t*a*v)*K,this}scale(e){const t=this.elements,i=e.x,r=e.y,s=e.z;return t[0]*=i,t[4]*=r,t[8]*=s,t[1]*=i,t[5]*=r,t[9]*=s,t[2]*=i,t[6]*=r,t[10]*=s,t[3]*=i,t[7]*=r,t[11]*=s,this}getMaxScaleOnAxis(){const e=this.elements;return Math.sqrt(Math.max(e[0]*e[0]+e[1]*e[1]+e[2]*e[2],e[4]*e[4]+e[5]*e[5]+e[6]*e[6],e[8]*e[8]+e[9]*e[9]+e[10]*e[10]))}makeTranslation(e,t,i){return this.set(1,0,0,e,0,1,0,t,0,0,1,i,0,0,0,1),this}makeRotationX(e){const t=Math.cos(e),i=Math.sin(e);return this.set(1,0,0,0,0,t,-i,0,0,i,t,0,0,0,0,1),this}makeRotationY(e){const t=Math.cos(e),i=Math.sin(e);return this.set(t,0,i,0,0,1,0,0,-i,0,t,0,0,0,0,1),this}makeRotationZ(e){const t=Math.cos(e),i=Math.sin(e);return this.set(t,-i,0,0,i,t,0,0,0,0,1,0,0,0,0,1),this}makeRotationAxis(e,t){const i=Math.cos(t),r=Math.sin(t),s=1-i,o=e.x,a=e.y,c=e.z,u=s*o,p=s*a;return this.set(u*o+i,u*a-r*c,u*c+r*a,0,u*a+r*c,p*a+i,p*c-r*o,0,u*c-r*a,p*c+r*o,s*c*c+i,0,0,0,0,1),this}makeScale(e,t,i){return this.set(e,0,0,0,0,t,0,0,0,0,i,0,0,0,0,1),this}makeShear(e,t,i,r,s,o){return this.set(1,i,s,0,e,1,o,0,t,r,1,0,0,0,0,1),this}compose(e,t,i){const r=this.elements,s=t._x,o=t._y,a=t._z,c=t._w,u=s+s,p=o+o,g=a+a,v=s*u,y=s*p,x=s*g,T=o*p,N=o*g,k=a*g,A=c*u,H=c*p,G=c*g,X=i.x,se=i.y,K=i.z;return r[0]=(1-(T+k))*X,r[1]=(y+G)*X,r[2]=(x-H)*X,r[3]=0,r[4]=(y-G)*se,r[5]=(1-(v+k))*se,r[6]=(N+A)*se,r[7]=0,r[8]=(x+H)*K,r[9]=(N-A)*K,r[10]=(1-(v+T))*K,r[11]=0,r[12]=e.x,r[13]=e.y,r[14]=e.z,r[15]=1,this}decompose(e,t,i){const r=this.elements;let s=Qg.set(r[0],r[1],r[2]).length();const o=Qg.set(r[4],r[5],r[6]).length(),a=Qg.set(r[8],r[9],r[10]).length();this.determinant()<0&&(s=-s),e.x=r[12],e.y=r[13],e.z=r[14],gl.copy(this);const u=1/s,p=1/o,g=1/a;return gl.elements[0]*=u,gl.elements[1]*=u,gl.elements[2]*=u,gl.elements[4]*=p,gl.elements[5]*=p,gl.elements[6]*=p,gl.elements[8]*=g,gl.elements[9]*=g,gl.elements[10]*=g,t.setFromRotationMatrix(gl),i.x=s,i.y=o,i.z=a,this}makePerspective(e,t,i,r,s,o){void 0===o&&console.warn("THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.");const a=this.elements,u=2*s/(i-r),p=(t+e)/(t-e),g=(i+r)/(i-r),v=-(o+s)/(o-s),y=-2*o*s/(o-s);return a[0]=2*s/(t-e),a[4]=0,a[8]=p,a[12]=0,a[1]=0,a[5]=u,a[9]=g,a[13]=0,a[2]=0,a[6]=0,a[10]=v,a[14]=y,a[3]=0,a[7]=0,a[11]=-1,a[15]=0,this}makeOrthographic(e,t,i,r,s,o){const a=this.elements,c=1/(t-e),u=1/(i-r),p=1/(o-s),g=(t+e)*c,v=(i+r)*u,y=(o+s)*p;return a[0]=2*c,a[4]=0,a[8]=0,a[12]=-g,a[1]=0,a[5]=2*u,a[9]=0,a[13]=-v,a[2]=0,a[6]=0,a[10]=-2*p,a[14]=-y,a[3]=0,a[7]=0,a[11]=0,a[15]=1,this}equals(e){const t=this.elements,i=e.elements;for(let r=0;r<16;r++)if(t[r]!==i[r])return!1;return!0}fromArray(e,t=0){for(let i=0;i<16;i++)this.elements[i]=e[i+t];return this}toArray(e=[],t=0){const i=this.elements;return e[t]=i[0],e[t+1]=i[1],e[t+2]=i[2],e[t+3]=i[3],e[t+4]=i[4],e[t+5]=i[5],e[t+6]=i[6],e[t+7]=i[7],e[t+8]=i[8],e[t+9]=i[9],e[t+10]=i[10],e[t+11]=i[11],e[t+12]=i[12],e[t+13]=i[13],e[t+14]=i[14],e[t+15]=i[15],e}}Gt.prototype.isMatrix4=!0;const Qg=new ne,gl=new Gt,sse=new ne(0,0,0),ose=new ne(1,1,1),_h=new ne,c2=new ne,sc=new ne,vB=new Gt,yB=new Go;class e0{constructor(e=0,t=0,i=0,r=e0.DefaultOrder){this._x=e,this._y=t,this._z=i,this._order=r}get x(){return this._x}set x(e){this._x=e,this._onChangeCallback()}get y(){return this._y}set y(e){this._y=e,this._onChangeCallback()}get z(){return this._z}set z(e){this._z=e,this._onChangeCallback()}get order(){return this._order}set order(e){this._order=e,this._onChangeCallback()}set(e,t,i,r=this._order){return this._x=e,this._y=t,this._z=i,this._order=r,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._order)}copy(e){return this._x=e._x,this._y=e._y,this._z=e._z,this._order=e._order,this._onChangeCallback(),this}setFromRotationMatrix(e,t=this._order,i=!0){const r=e.elements,s=r[0],o=r[4],a=r[8],c=r[1],u=r[5],p=r[9],g=r[2],v=r[6],y=r[10];switch(t){case"XYZ":this._y=Math.asin(Mo(a,-1,1)),Math.abs(a)<.9999999?(this._x=Math.atan2(-p,y),this._z=Math.atan2(-o,s)):(this._x=Math.atan2(v,u),this._z=0);break;case"YXZ":this._x=Math.asin(-Mo(p,-1,1)),Math.abs(p)<.9999999?(this._y=Math.atan2(a,y),this._z=Math.atan2(c,u)):(this._y=Math.atan2(-g,s),this._z=0);break;case"ZXY":this._x=Math.asin(Mo(v,-1,1)),Math.abs(v)<.9999999?(this._y=Math.atan2(-g,y),this._z=Math.atan2(-o,u)):(this._y=0,this._z=Math.atan2(c,s));break;case"ZYX":this._y=Math.asin(-Mo(g,-1,1)),Math.abs(g)<.9999999?(this._x=Math.atan2(v,y),this._z=Math.atan2(c,s)):(this._x=0,this._z=Math.atan2(-o,u));break;case"YZX":this._z=Math.asin(Mo(c,-1,1)),Math.abs(c)<.9999999?(this._x=Math.atan2(-p,u),this._y=Math.atan2(-g,s)):(this._x=0,this._y=Math.atan2(a,y));break;case"XZY":this._z=Math.asin(-Mo(o,-1,1)),Math.abs(o)<.9999999?(this._x=Math.atan2(v,u),this._y=Math.atan2(a,s)):(this._x=Math.atan2(-p,y),this._y=0);break;default:console.warn("THREE.Euler: .setFromRotationMatrix() encountered an unknown order: "+t)}return this._order=t,!0===i&&this._onChangeCallback(),this}setFromQuaternion(e,t,i){return vB.makeRotationFromQuaternion(e),this.setFromRotationMatrix(vB,t,i)}setFromVector3(e,t=this._order){return this.set(e.x,e.y,e.z,t)}reorder(e){return yB.setFromEuler(this),this.setFromQuaternion(yB,e)}equals(e){return e._x===this._x&&e._y===this._y&&e._z===this._z&&e._order===this._order}fromArray(e){return this._x=e[0],this._y=e[1],this._z=e[2],void 0!==e[3]&&(this._order=e[3]),this._onChangeCallback(),this}toArray(e=[],t=0){return e[t]=this._x,e[t+1]=this._y,e[t+2]=this._z,e[t+3]=this._order,e}toVector3(e){return e?e.set(this._x,this._y,this._z):new ne(this._x,this._y,this._z)}_onChange(e){return this._onChangeCallback=e,this}_onChangeCallback(){}}e0.prototype.isEuler=!0,e0.DefaultOrder="XYZ",e0.RotationOrders=["XYZ","YZX","ZXY","XZY","YXZ","ZYX"];class bB{constructor(){this.mask=1}set(e){this.mask=(1<>>0}enable(e){this.mask|=1<1){for(let t=0;t1){for(let i=0;i0){r.children=[];for(let a=0;a0){r.animations=[];for(let a=0;a0&&(i.geometries=a),c.length>0&&(i.materials=c),u.length>0&&(i.textures=u),p.length>0&&(i.images=p),g.length>0&&(i.shapes=g),v.length>0&&(i.skeletons=v),y.length>0&&(i.animations=y)}return i.object=r,i;function o(a){const c=[];for(const u in a){const p=a[u];delete p.metadata,c.push(p)}return c}}clone(e){return(new this.constructor).copy(this,e)}copy(e,t=!0){if(this.name=e.name,this.up.copy(e.up),this.position.copy(e.position),this.rotation.order=e.rotation.order,this.quaternion.copy(e.quaternion),this.scale.copy(e.scale),this.matrix.copy(e.matrix),this.matrixWorld.copy(e.matrixWorld),this.matrixAutoUpdate=e.matrixAutoUpdate,this.matrixWorldNeedsUpdate=e.matrixWorldNeedsUpdate,this.layers.mask=e.layers.mask,this.visible=e.visible,this.castShadow=e.castShadow,this.receiveShadow=e.receiveShadow,this.frustumCulled=e.frustumCulled,this.renderOrder=e.renderOrder,this.userData=JSON.parse(JSON.stringify(e.userData)),!0===t)for(let i=0;i0?r.multiplyScalar(1/Math.sqrt(s)):r.set(0,0,0)}static getBarycoord(e,t,i,r,s){_l.subVectors(r,t),Qd.subVectors(i,t),zk.subVectors(e,t);const o=_l.dot(_l),a=_l.dot(Qd),c=_l.dot(zk),u=Qd.dot(Qd),p=Qd.dot(zk),g=o*u-a*a;if(0===g)return s.set(-2,-1,-1);const v=1/g,y=(u*c-a*p)*v,x=(o*p-a*c)*v;return s.set(1-y-x,x,y)}static containsPoint(e,t,i,r){return this.getBarycoord(e,t,i,r,eu),eu.x>=0&&eu.y>=0&&eu.x+eu.y<=1}static getUV(e,t,i,r,s,o,a,c){return this.getBarycoord(e,t,i,r,eu),c.set(0,0),c.addScaledVector(s,eu.x),c.addScaledVector(o,eu.y),c.addScaledVector(a,eu.z),c}static isFrontFacing(e,t,i,r){return _l.subVectors(i,t),Qd.subVectors(e,t),_l.cross(Qd).dot(r)<0}set(e,t,i){return this.a.copy(e),this.b.copy(t),this.c.copy(i),this}setFromPointsAndIndices(e,t,i,r){return this.a.copy(e[t]),this.b.copy(e[i]),this.c.copy(e[r]),this}setFromAttributeAndIndices(e,t,i,r){return this.a.fromBufferAttribute(e,t),this.b.fromBufferAttribute(e,i),this.c.fromBufferAttribute(e,r),this}clone(){return(new this.constructor).copy(this)}copy(e){return this.a.copy(e.a),this.b.copy(e.b),this.c.copy(e.c),this}getArea(){return _l.subVectors(this.c,this.b),Qd.subVectors(this.a,this.b),.5*_l.cross(Qd).length()}getMidpoint(e){return e.addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)}getNormal(e){return Ts.getNormal(this.a,this.b,this.c,e)}getPlane(e){return e.setFromCoplanarPoints(this.a,this.b,this.c)}getBarycoord(e,t){return Ts.getBarycoord(e,this.a,this.b,this.c,t)}getUV(e,t,i,r,s){return Ts.getUV(e,this.a,this.b,this.c,t,i,r,s)}containsPoint(e){return Ts.containsPoint(e,this.a,this.b,this.c)}isFrontFacing(e){return Ts.isFrontFacing(this.a,this.b,this.c,e)}intersectsBox(e){return e.intersectsTriangle(this)}closestPointToPoint(e,t){const i=this.a,r=this.b,s=this.c;let o,a;n0.subVectors(r,i),r0.subVectors(s,i),Gk.subVectors(e,i);const c=n0.dot(Gk),u=r0.dot(Gk);if(c<=0&&u<=0)return t.copy(i);jk.subVectors(e,r);const p=n0.dot(jk),g=r0.dot(jk);if(p>=0&&g<=p)return t.copy(r);const v=c*g-p*u;if(v<=0&&c>=0&&p<=0)return o=c/(c-p),t.copy(i).addScaledVector(n0,o);Wk.subVectors(e,s);const y=n0.dot(Wk),x=r0.dot(Wk);if(x>=0&&y<=x)return t.copy(s);const T=y*u-c*x;if(T<=0&&u>=0&&x<=0)return a=u/(u-x),t.copy(i).addScaledVector(r0,a);const N=p*x-y*g;if(N<=0&&g-p>=0&&y-x>=0)return CB.subVectors(s,r),a=(g-p)/(g-p+(y-x)),t.copy(r).addScaledVector(CB,a);const k=1/(N+T+v);return o=T*k,a=v*k,t.copy(i).addScaledVector(n0,o).addScaledVector(r0,a)}equals(e){return e.a.equals(this.a)&&e.b.equals(this.b)&&e.c.equals(this.c)}}let use=0;class Co extends np{constructor(){super(),Object.defineProperty(this,"id",{value:use++}),this.uuid=rc(),this.name="",this.type="Material",this.fog=!0,this.blending=Ay,this.side=Og,this.vertexColors=!1,this.opacity=1,this.format=zo,this.transparent=!1,this.blendSrc=K8,this.blendDst=Y8,this.blendEquation=Ng,this.blendSrcAlpha=null,this.blendDstAlpha=null,this.blendEquationAlpha=null,this.depthFunc=xk,this.depthTest=!0,this.depthWrite=!0,this.stencilWriteMask=255,this.stencilFunc=519,this.stencilRef=0,this.stencilFuncMask=255,this.stencilFail=7680,this.stencilZFail=7680,this.stencilZPass=7680,this.stencilWrite=!1,this.clippingPlanes=null,this.clipIntersection=!1,this.clipShadows=!1,this.shadowSide=null,this.colorWrite=!0,this.precision=null,this.polygonOffset=!1,this.polygonOffsetFactor=0,this.polygonOffsetUnits=0,this.dithering=!1,this.alphaToCoverage=!1,this.premultipliedAlpha=!1,this.visible=!0,this.toneMapped=!0,this.userData={},this.version=0,this._alphaTest=0}get alphaTest(){return this._alphaTest}set alphaTest(e){this._alphaTest>0!=e>0&&this.version++,this._alphaTest=e}onBuild(){}onBeforeRender(){}onBeforeCompile(){}customProgramCacheKey(){return this.onBeforeCompile.toString()}setValues(e){if(void 0!==e)for(const t in e){const i=e[t];if(void 0===i){console.warn("THREE.Material: '"+t+"' parameter is undefined.");continue}if("shading"===t){console.warn("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead."),this.flatShading=1===i;continue}const r=this[t];void 0!==r?r&&r.isColor?r.set(i):r&&r.isVector3&&i&&i.isVector3?r.copy(i):this[t]=i:console.warn("THREE."+this.type+": '"+t+"' is not a property of this material.")}}toJSON(e){const t=void 0===e||"string"==typeof e;t&&(e={textures:{},images:{}});const i={metadata:{version:4.5,type:"Material",generator:"Material.toJSON"}};function r(s){const o=[];for(const a in s){const c=s[a];delete c.metadata,o.push(c)}return o}if(i.uuid=this.uuid,i.type=this.type,""!==this.name&&(i.name=this.name),this.color&&this.color.isColor&&(i.color=this.color.getHex()),void 0!==this.roughness&&(i.roughness=this.roughness),void 0!==this.metalness&&(i.metalness=this.metalness),void 0!==this.sheen&&(i.sheen=this.sheen),this.sheenColor&&this.sheenColor.isColor&&(i.sheenColor=this.sheenColor.getHex()),void 0!==this.sheenRoughness&&(i.sheenRoughness=this.sheenRoughness),this.emissive&&this.emissive.isColor&&(i.emissive=this.emissive.getHex()),this.emissiveIntensity&&1!==this.emissiveIntensity&&(i.emissiveIntensity=this.emissiveIntensity),this.specular&&this.specular.isColor&&(i.specular=this.specular.getHex()),void 0!==this.specularIntensity&&(i.specularIntensity=this.specularIntensity),this.specularColor&&this.specularColor.isColor&&(i.specularColor=this.specularColor.getHex()),void 0!==this.shininess&&(i.shininess=this.shininess),void 0!==this.clearcoat&&(i.clearcoat=this.clearcoat),void 0!==this.clearcoatRoughness&&(i.clearcoatRoughness=this.clearcoatRoughness),this.clearcoatMap&&this.clearcoatMap.isTexture&&(i.clearcoatMap=this.clearcoatMap.toJSON(e).uuid),this.clearcoatRoughnessMap&&this.clearcoatRoughnessMap.isTexture&&(i.clearcoatRoughnessMap=this.clearcoatRoughnessMap.toJSON(e).uuid),this.clearcoatNormalMap&&this.clearcoatNormalMap.isTexture&&(i.clearcoatNormalMap=this.clearcoatNormalMap.toJSON(e).uuid,i.clearcoatNormalScale=this.clearcoatNormalScale.toArray()),this.map&&this.map.isTexture&&(i.map=this.map.toJSON(e).uuid),this.matcap&&this.matcap.isTexture&&(i.matcap=this.matcap.toJSON(e).uuid),this.alphaMap&&this.alphaMap.isTexture&&(i.alphaMap=this.alphaMap.toJSON(e).uuid),this.lightMap&&this.lightMap.isTexture&&(i.lightMap=this.lightMap.toJSON(e).uuid,i.lightMapIntensity=this.lightMapIntensity),this.aoMap&&this.aoMap.isTexture&&(i.aoMap=this.aoMap.toJSON(e).uuid,i.aoMapIntensity=this.aoMapIntensity),this.bumpMap&&this.bumpMap.isTexture&&(i.bumpMap=this.bumpMap.toJSON(e).uuid,i.bumpScale=this.bumpScale),this.normalMap&&this.normalMap.isTexture&&(i.normalMap=this.normalMap.toJSON(e).uuid,i.normalMapType=this.normalMapType,i.normalScale=this.normalScale.toArray()),this.displacementMap&&this.displacementMap.isTexture&&(i.displacementMap=this.displacementMap.toJSON(e).uuid,i.displacementScale=this.displacementScale,i.displacementBias=this.displacementBias),this.roughnessMap&&this.roughnessMap.isTexture&&(i.roughnessMap=this.roughnessMap.toJSON(e).uuid),this.metalnessMap&&this.metalnessMap.isTexture&&(i.metalnessMap=this.metalnessMap.toJSON(e).uuid),this.emissiveMap&&this.emissiveMap.isTexture&&(i.emissiveMap=this.emissiveMap.toJSON(e).uuid),this.specularMap&&this.specularMap.isTexture&&(i.specularMap=this.specularMap.toJSON(e).uuid),this.specularIntensityMap&&this.specularIntensityMap.isTexture&&(i.specularIntensityMap=this.specularIntensityMap.toJSON(e).uuid),this.specularColorMap&&this.specularColorMap.isTexture&&(i.specularColorMap=this.specularColorMap.toJSON(e).uuid),this.envMap&&this.envMap.isTexture&&(i.envMap=this.envMap.toJSON(e).uuid,void 0!==this.combine&&(i.combine=this.combine)),void 0!==this.envMapIntensity&&(i.envMapIntensity=this.envMapIntensity),void 0!==this.reflectivity&&(i.reflectivity=this.reflectivity),void 0!==this.refractionRatio&&(i.refractionRatio=this.refractionRatio),this.gradientMap&&this.gradientMap.isTexture&&(i.gradientMap=this.gradientMap.toJSON(e).uuid),void 0!==this.transmission&&(i.transmission=this.transmission),this.transmissionMap&&this.transmissionMap.isTexture&&(i.transmissionMap=this.transmissionMap.toJSON(e).uuid),void 0!==this.thickness&&(i.thickness=this.thickness),this.thicknessMap&&this.thicknessMap.isTexture&&(i.thicknessMap=this.thicknessMap.toJSON(e).uuid),void 0!==this.attenuationDistance&&(i.attenuationDistance=this.attenuationDistance),void 0!==this.attenuationColor&&(i.attenuationColor=this.attenuationColor.getHex()),void 0!==this.size&&(i.size=this.size),null!==this.shadowSide&&(i.shadowSide=this.shadowSide),void 0!==this.sizeAttenuation&&(i.sizeAttenuation=this.sizeAttenuation),this.blending!==Ay&&(i.blending=this.blending),this.side!==Og&&(i.side=this.side),this.vertexColors&&(i.vertexColors=!0),this.opacity<1&&(i.opacity=this.opacity),this.format!==zo&&(i.format=this.format),!0===this.transparent&&(i.transparent=this.transparent),i.depthFunc=this.depthFunc,i.depthTest=this.depthTest,i.depthWrite=this.depthWrite,i.colorWrite=this.colorWrite,i.stencilWrite=this.stencilWrite,i.stencilWriteMask=this.stencilWriteMask,i.stencilFunc=this.stencilFunc,i.stencilRef=this.stencilRef,i.stencilFuncMask=this.stencilFuncMask,i.stencilFail=this.stencilFail,i.stencilZFail=this.stencilZFail,i.stencilZPass=this.stencilZPass,this.rotation&&0!==this.rotation&&(i.rotation=this.rotation),!0===this.polygonOffset&&(i.polygonOffset=!0),0!==this.polygonOffsetFactor&&(i.polygonOffsetFactor=this.polygonOffsetFactor),0!==this.polygonOffsetUnits&&(i.polygonOffsetUnits=this.polygonOffsetUnits),this.linewidth&&1!==this.linewidth&&(i.linewidth=this.linewidth),void 0!==this.dashSize&&(i.dashSize=this.dashSize),void 0!==this.gapSize&&(i.gapSize=this.gapSize),void 0!==this.scale&&(i.scale=this.scale),!0===this.dithering&&(i.dithering=!0),this.alphaTest>0&&(i.alphaTest=this.alphaTest),!0===this.alphaToCoverage&&(i.alphaToCoverage=this.alphaToCoverage),!0===this.premultipliedAlpha&&(i.premultipliedAlpha=this.premultipliedAlpha),!0===this.wireframe&&(i.wireframe=this.wireframe),this.wireframeLinewidth>1&&(i.wireframeLinewidth=this.wireframeLinewidth),"round"!==this.wireframeLinecap&&(i.wireframeLinecap=this.wireframeLinecap),"round"!==this.wireframeLinejoin&&(i.wireframeLinejoin=this.wireframeLinejoin),!0===this.flatShading&&(i.flatShading=this.flatShading),!1===this.visible&&(i.visible=!1),!1===this.toneMapped&&(i.toneMapped=!1),"{}"!==JSON.stringify(this.userData)&&(i.userData=this.userData),t){const s=r(e.textures),o=r(e.images);s.length>0&&(i.textures=s),o.length>0&&(i.images=o)}return i}clone(){return(new this.constructor).copy(this)}copy(e){this.name=e.name,this.fog=e.fog,this.blending=e.blending,this.side=e.side,this.vertexColors=e.vertexColors,this.opacity=e.opacity,this.format=e.format,this.transparent=e.transparent,this.blendSrc=e.blendSrc,this.blendDst=e.blendDst,this.blendEquation=e.blendEquation,this.blendSrcAlpha=e.blendSrcAlpha,this.blendDstAlpha=e.blendDstAlpha,this.blendEquationAlpha=e.blendEquationAlpha,this.depthFunc=e.depthFunc,this.depthTest=e.depthTest,this.depthWrite=e.depthWrite,this.stencilWriteMask=e.stencilWriteMask,this.stencilFunc=e.stencilFunc,this.stencilRef=e.stencilRef,this.stencilFuncMask=e.stencilFuncMask,this.stencilFail=e.stencilFail,this.stencilZFail=e.stencilZFail,this.stencilZPass=e.stencilZPass,this.stencilWrite=e.stencilWrite;const t=e.clippingPlanes;let i=null;if(null!==t){const r=t.length;i=new Array(r);for(let s=0;s!==r;++s)i[s]=t[s].clone()}return this.clippingPlanes=i,this.clipIntersection=e.clipIntersection,this.clipShadows=e.clipShadows,this.shadowSide=e.shadowSide,this.colorWrite=e.colorWrite,this.precision=e.precision,this.polygonOffset=e.polygonOffset,this.polygonOffsetFactor=e.polygonOffsetFactor,this.polygonOffsetUnits=e.polygonOffsetUnits,this.dithering=e.dithering,this.alphaTest=e.alphaTest,this.alphaToCoverage=e.alphaToCoverage,this.premultipliedAlpha=e.premultipliedAlpha,this.visible=e.visible,this.toneMapped=e.toneMapped,this.userData=JSON.parse(JSON.stringify(e.userData)),this}dispose(){this.dispatchEvent({type:"dispose"})}set needsUpdate(e){!0===e&&this.version++}}Co.prototype.isMaterial=!0;const DB={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074},vl={h:0,s:0,l:0},d2={h:0,s:0,l:0};function $k(n,e,t){return t<0&&(t+=1),t>1&&(t-=1),t<1/6?n+6*(e-n)*t:t<.5?e:t<2/3?n+6*(e-n)*(2/3-t):n}function qk(n){return n<.04045?.0773993808*n:Math.pow(.9478672986*n+.0521327014,2.4)}function Kk(n){return n<.0031308?12.92*n:1.055*Math.pow(n,.41666)-.055}let Rt=(()=>{class n{constructor(t,i,r){return void 0===i&&void 0===r?this.set(t):this.setRGB(t,i,r)}set(t){return t&&t.isColor?this.copy(t):"number"==typeof t?this.setHex(t):"string"==typeof t&&this.setStyle(t),this}setScalar(t){return this.r=t,this.g=t,this.b=t,this}setHex(t){return t=Math.floor(t),this.r=(t>>16&255)/255,this.g=(t>>8&255)/255,this.b=(255&t)/255,this}setRGB(t,i,r){return this.r=t,this.g=i,this.b=r,this}setHSL(t,i,r){if(t=function kk(n,e){return(n%e+e)%e}(t,1),i=Mo(i,0,1),r=Mo(r,0,1),0===i)this.r=this.g=this.b=r;else{const s=r<=.5?r*(1+i):r+i-r*i,o=2*r-s;this.r=$k(o,s,t+1/3),this.g=$k(o,s,t),this.b=$k(o,s,t-1/3)}return this}setStyle(t){function i(s){void 0!==s&&parseFloat(s)<1&&console.warn("THREE.Color: Alpha component of "+t+" will be ignored.")}let r;if(r=/^((?:rgb|hsl)a?)\(([^\)]*)\)/.exec(t)){let s;const a=r[2];switch(r[1]){case"rgb":case"rgba":if(s=/^\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(a))return this.r=Math.min(255,parseInt(s[1],10))/255,this.g=Math.min(255,parseInt(s[2],10))/255,this.b=Math.min(255,parseInt(s[3],10))/255,i(s[4]),this;if(s=/^\s*(\d+)\%\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(a))return this.r=Math.min(100,parseInt(s[1],10))/100,this.g=Math.min(100,parseInt(s[2],10))/100,this.b=Math.min(100,parseInt(s[3],10))/100,i(s[4]),this;break;case"hsl":case"hsla":if(s=/^\s*(\d*\.?\d+)\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(a)){const c=parseFloat(s[1])/360,u=parseInt(s[2],10)/100,p=parseInt(s[3],10)/100;return i(s[4]),this.setHSL(c,u,p)}}}else if(r=/^\#([A-Fa-f\d]+)$/.exec(t)){const s=r[1],o=s.length;if(3===o)return this.r=parseInt(s.charAt(0)+s.charAt(0),16)/255,this.g=parseInt(s.charAt(1)+s.charAt(1),16)/255,this.b=parseInt(s.charAt(2)+s.charAt(2),16)/255,this;if(6===o)return this.r=parseInt(s.charAt(0)+s.charAt(1),16)/255,this.g=parseInt(s.charAt(2)+s.charAt(3),16)/255,this.b=parseInt(s.charAt(4)+s.charAt(5),16)/255,this}return t&&t.length>0?this.setColorName(t):this}setColorName(t){const i=DB[t.toLowerCase()];return void 0!==i?this.setHex(i):console.warn("THREE.Color: Unknown color "+t),this}clone(){return new this.constructor(this.r,this.g,this.b)}copy(t){return this.r=t.r,this.g=t.g,this.b=t.b,this}copyGammaToLinear(t,i=2){return this.r=Math.pow(t.r,i),this.g=Math.pow(t.g,i),this.b=Math.pow(t.b,i),this}copyLinearToGamma(t,i=2){const r=i>0?1/i:1;return this.r=Math.pow(t.r,r),this.g=Math.pow(t.g,r),this.b=Math.pow(t.b,r),this}convertGammaToLinear(t){return this.copyGammaToLinear(this,t),this}convertLinearToGamma(t){return this.copyLinearToGamma(this,t),this}copySRGBToLinear(t){return this.r=qk(t.r),this.g=qk(t.g),this.b=qk(t.b),this}copyLinearToSRGB(t){return this.r=Kk(t.r),this.g=Kk(t.g),this.b=Kk(t.b),this}convertSRGBToLinear(){return this.copySRGBToLinear(this),this}convertLinearToSRGB(){return this.copyLinearToSRGB(this),this}getHex(){return 255*this.r<<16^255*this.g<<8^255*this.b<<0}getHexString(){return("000000"+this.getHex().toString(16)).slice(-6)}getHSL(t){const i=this.r,r=this.g,s=this.b,o=Math.max(i,r,s),a=Math.min(i,r,s);let c,u;const p=(a+o)/2;if(a===o)c=0,u=0;else{const g=o-a;switch(u=p<=.5?g/(o+a):g/(2-o-a),o){case i:c=(r-s)/g+(r65535?Xk:Yk)(e,1):e,this}getAttribute(e){return this.attributes[e]}setAttribute(e,t){return this.attributes[e]=t,this}deleteAttribute(e){return delete this.attributes[e],this}hasAttribute(e){return void 0!==this.attributes[e]}addGroup(e,t,i=0){this.groups.push({start:e,count:t,materialIndex:i})}clearGroups(){this.groups=[]}setDrawRange(e,t){this.drawRange.start=e,this.drawRange.count=t}applyMatrix4(e){const t=this.attributes.position;void 0!==t&&(t.applyMatrix4(e),t.needsUpdate=!0);const i=this.attributes.normal;if(void 0!==i){const s=(new js).getNormalMatrix(e);i.applyNormalMatrix(s),i.needsUpdate=!0}const r=this.attributes.tangent;return void 0!==r&&(r.transformDirection(e),r.needsUpdate=!0),null!==this.boundingBox&&this.computeBoundingBox(),null!==this.boundingSphere&&this.computeBoundingSphere(),this}applyQuaternion(e){return Hc.makeRotationFromQuaternion(e),this.applyMatrix4(Hc),this}rotateX(e){return Hc.makeRotationX(e),this.applyMatrix4(Hc),this}rotateY(e){return Hc.makeRotationY(e),this.applyMatrix4(Hc),this}rotateZ(e){return Hc.makeRotationZ(e),this.applyMatrix4(Hc),this}translate(e,t,i){return Hc.makeTranslation(e,t,i),this.applyMatrix4(Hc),this}scale(e,t,i){return Hc.makeScale(e,t,i),this.applyMatrix4(Hc),this}lookAt(e){return Zk.lookAt(e),Zk.updateMatrix(),this.applyMatrix4(Zk.matrix),this}center(){return this.computeBoundingBox(),this.boundingBox.getCenter(s0).negate(),this.translate(s0.x,s0.y,s0.z),this}setFromPoints(e){const t=[];for(let i=0,r=e.length;i0&&(e.userData=this.userData),void 0!==this.parameters){const c=this.parameters;for(const u in c)void 0!==c[u]&&(e[u]=c[u]);return e}e.data={attributes:{}};const t=this.index;null!==t&&(e.data.index={type:t.array.constructor.name,array:Array.prototype.slice.call(t.array)});const i=this.attributes;for(const c in i)e.data.attributes[c]=i[c].toJSON(e.data);const r={};let s=!1;for(const c in this.morphAttributes){const u=this.morphAttributes[c],p=[];for(let g=0,v=u.length;g0&&(r[c]=p,s=!0)}s&&(e.data.morphAttributes=r,e.data.morphTargetsRelative=this.morphTargetsRelative);const o=this.groups;o.length>0&&(e.data.groups=JSON.parse(JSON.stringify(o)));const a=this.boundingSphere;return null!==a&&(e.data.boundingSphere={center:a.center.toArray(),radius:a.radius}),e}clone(){return(new this.constructor).copy(this)}copy(e){this.index=null,this.attributes={},this.morphAttributes={},this.groups=[],this.boundingBox=null,this.boundingSphere=null;const t={};this.name=e.name;const i=e.index;null!==i&&this.setIndex(i.clone(t));const r=e.attributes;for(const u in r)this.setAttribute(u,r[u].clone(t));const s=e.morphAttributes;for(const u in s){const p=[],g=s[u];for(let v=0,y=g.length;v0){const r=t[i[0]];if(void 0!==r){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Mesh.updateMorphTargets() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}}raycast(e,t){const i=this.geometry,r=this.material,s=this.matrixWorld;if(void 0===r||(null===i.boundingSphere&&i.computeBoundingSphere(),Jk.copy(i.boundingSphere),Jk.applyMatrix4(s),!1===e.ray.intersectsSphere(Jk))||(TB.copy(s).invert(),o0.copy(e.ray).applyMatrix4(TB),null!==i.boundingBox&&!1===o0.intersectsBox(i.boundingBox)))return;let o;if(i.isBufferGeometry){const a=i.index,c=i.attributes.position,u=i.morphAttributes.position,p=i.morphTargetsRelative,g=i.attributes.uv,v=i.attributes.uv2,y=i.groups,x=i.drawRange;if(null!==a)if(Array.isArray(r))for(let T=0,N=y.length;Tt.far?null:{distance:u,point:v2.clone(),object:n}}(n,e,t,i,yh,bh,xh,nI);if(y){a&&(m2.fromBufferAttribute(a,u),g2.fromBufferAttribute(a,p),_2.fromBufferAttribute(a,g),y.uv=Ts.getUV(nI,yh,bh,xh,m2,g2,_2,new tt)),c&&(m2.fromBufferAttribute(c,u),g2.fromBufferAttribute(c,p),_2.fromBufferAttribute(c,g),y.uv2=Ts.getUV(nI,yh,bh,xh,m2,g2,_2,new tt));const x={a:u,b:p,c:g,normal:new ne,materialIndex:0};Ts.getNormal(yh,bh,xh,x.normal),y.face=x}return y}vr.prototype.isMesh=!0;class tu extends gn{constructor(e=1,t=1,i=1,r=1,s=1,o=1){super(),this.type="BoxGeometry",this.parameters={width:e,height:t,depth:i,widthSegments:r,heightSegments:s,depthSegments:o};const a=this;r=Math.floor(r),s=Math.floor(s),o=Math.floor(o);const c=[],u=[],p=[],g=[];let v=0,y=0;function x(T,N,k,A,H,G,X,se,K,he,De){const Te=G/K,ge=X/he,Qe=G/2,Pe=X/2,Oe=se/2,Ve=K+1,ye=he+1;let Me=0,je=0;const lt=new ne;for(let ze=0;ze0?1:-1,p.push(lt.x,lt.y,lt.z),g.push(vt/K),g.push(1-ze/he),Me+=1}for(let ze=0;ze0&&(t.defines=this.defines),t.vertexShader=this.vertexShader,t.fragmentShader=this.fragmentShader;const i={};for(const r in this.extensions)!0===this.extensions[r]&&(i[r]=!0);return Object.keys(i).length>0&&(t.extensions=i),t}}wh.prototype.isShaderMaterial=!0;class b2 extends qi{constructor(){super(),this.type="Camera",this.matrixWorldInverse=new Gt,this.projectionMatrix=new Gt,this.projectionMatrixInverse=new Gt}copy(e,t){return super.copy(e,t),this.matrixWorldInverse.copy(e.matrixWorldInverse),this.projectionMatrix.copy(e.projectionMatrix),this.projectionMatrixInverse.copy(e.projectionMatrixInverse),this}getWorldDirection(e){this.updateWorldMatrix(!0,!1);const t=this.matrixWorld.elements;return e.set(-t[8],-t[9],-t[10]).normalize()}updateMatrixWorld(e){super.updateMatrixWorld(e),this.matrixWorldInverse.copy(this.matrixWorld).invert()}updateWorldMatrix(e,t){super.updateWorldMatrix(e,t),this.matrixWorldInverse.copy(this.matrixWorld).invert()}clone(){return(new this.constructor).copy(this)}}b2.prototype.isCamera=!0;class Do extends b2{constructor(e=50,t=1,i=.1,r=2e3){super(),this.type="PerspectiveCamera",this.fov=e,this.zoom=1,this.near=i,this.far=r,this.focus=10,this.aspect=t,this.view=null,this.filmGauge=35,this.filmOffset=0,this.updateProjectionMatrix()}copy(e,t){return super.copy(e,t),this.fov=e.fov,this.zoom=e.zoom,this.near=e.near,this.far=e.far,this.focus=e.focus,this.aspect=e.aspect,this.view=null===e.view?null:Object.assign({},e.view),this.filmGauge=e.filmGauge,this.filmOffset=e.filmOffset,this}setFocalLength(e){const t=.5*this.getFilmHeight()/e;this.fov=2*Py*Math.atan(t),this.updateProjectionMatrix()}getFocalLength(){const e=Math.tan(.5*ip*this.fov);return.5*this.getFilmHeight()/e}getEffectiveFOV(){return 2*Py*Math.atan(Math.tan(.5*ip*this.fov)/this.zoom)}getFilmWidth(){return this.filmGauge*Math.min(this.aspect,1)}getFilmHeight(){return this.filmGauge/Math.max(this.aspect,1)}setViewOffset(e,t,i,r,s,o){this.aspect=e/t,null===this.view&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=e,this.view.fullHeight=t,this.view.offsetX=i,this.view.offsetY=r,this.view.width=s,this.view.height=o,this.updateProjectionMatrix()}clearViewOffset(){null!==this.view&&(this.view.enabled=!1),this.updateProjectionMatrix()}updateProjectionMatrix(){const e=this.near;let t=e*Math.tan(.5*ip*this.fov)/this.zoom,i=2*t,r=this.aspect*i,s=-.5*r;const o=this.view;if(null!==this.view&&this.view.enabled){const c=o.fullWidth,u=o.fullHeight;s+=o.offsetX*r/c,t-=o.offsetY*i/u,r*=o.width/c,i*=o.height/u}const a=this.filmOffset;0!==a&&(s+=e*a/this.getFilmWidth()),this.projectionMatrix.makePerspective(s,s+r,t,t-i,e,this.far),this.projectionMatrixInverse.copy(this.projectionMatrix).invert()}toJSON(e){const t=super.toJSON(e);return t.object.fov=this.fov,t.object.zoom=this.zoom,t.object.near=this.near,t.object.far=this.far,t.object.focus=this.focus,t.object.aspect=this.aspect,null!==this.view&&(t.object.view=Object.assign({},this.view)),t.object.filmGauge=this.filmGauge,t.object.filmOffset=this.filmOffset,t}}Do.prototype.isPerspectiveCamera=!0;class iI extends qi{constructor(e,t,i){if(super(),this.type="CubeCamera",!0!==i.isWebGLCubeRenderTarget)return void console.error("THREE.CubeCamera: The constructor now expects an instance of WebGLCubeRenderTarget as third parameter.");this.renderTarget=i;const r=new Do(90,1,e,t);r.layers=this.layers,r.up.set(0,-1,0),r.lookAt(new ne(1,0,0)),this.add(r);const s=new Do(90,1,e,t);s.layers=this.layers,s.up.set(0,-1,0),s.lookAt(new ne(-1,0,0)),this.add(s);const o=new Do(90,1,e,t);o.layers=this.layers,o.up.set(0,0,1),o.lookAt(new ne(0,1,0)),this.add(o);const a=new Do(90,1,e,t);a.layers=this.layers,a.up.set(0,0,-1),a.lookAt(new ne(0,-1,0)),this.add(a);const c=new Do(90,1,e,t);c.layers=this.layers,c.up.set(0,-1,0),c.lookAt(new ne(0,0,1)),this.add(c);const u=new Do(90,1,e,t);u.layers=this.layers,u.up.set(0,-1,0),u.lookAt(new ne(0,0,-1)),this.add(u)}update(e,t){null===this.parent&&this.updateMatrixWorld();const i=this.renderTarget,[r,s,o,a,c,u]=this.children,p=e.xr.enabled,g=e.getRenderTarget();e.xr.enabled=!1;const v=i.texture.generateMipmaps;i.texture.generateMipmaps=!1,e.setRenderTarget(i,0),e.render(t,r),e.setRenderTarget(i,1),e.render(t,s),e.setRenderTarget(i,2),e.render(t,o),e.setRenderTarget(i,3),e.render(t,a),e.setRenderTarget(i,4),e.render(t,c),i.texture.generateMipmaps=v,e.setRenderTarget(i,5),e.render(t,u),e.setRenderTarget(g),e.xr.enabled=p}}class Hy extends io{constructor(e,t,i,r,s,o,a,c,u,p){super(e=void 0!==e?e:[],t=void 0!==t?t:Bg,i,r,s,o,a,c,u,p),this.flipY=!1}get images(){return this.image}set images(e){this.image=e}}Hy.prototype.isCubeTexture=!0;class rI extends Bc{constructor(e,t,i){Number.isInteger(t)&&(console.warn("THREE.WebGLCubeRenderTarget: constructor signature is now WebGLCubeRenderTarget( size, options )"),t=i),super(e,e,t),this.texture=new Hy(void 0,(t=t||{}).mapping,t.wrapS,t.wrapT,t.magFilter,t.minFilter,t.format,t.type,t.anisotropy,t.encoding),this.texture.isRenderTargetTexture=!0,this.texture.generateMipmaps=void 0!==t.generateMipmaps&&t.generateMipmaps,this.texture.minFilter=void 0!==t.minFilter?t.minFilter:no,this.texture._needsFlipEnvMap=!1}fromEquirectangularTexture(e,t){this.texture.type=t.type,this.texture.format=zo,this.texture.encoding=t.encoding,this.texture.generateMipmaps=t.generateMipmaps,this.texture.minFilter=t.minFilter,this.texture.magFilter=t.magFilter;const i_uniforms={tEquirect:{value:null}},i_vertexShader="\n\n\t\t\t\tvarying vec3 vWorldDirection;\n\n\t\t\t\tvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\n\t\t\t\t\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n\n\t\t\t\t}\n\n\t\t\t\tvoid main() {\n\n\t\t\t\t\tvWorldDirection = transformDirection( position, modelMatrix );\n\n\t\t\t\t\t#include \n\t\t\t\t\t#include \n\n\t\t\t\t}\n\t\t\t",i_fragmentShader="\n\n\t\t\t\tuniform sampler2D tEquirect;\n\n\t\t\t\tvarying vec3 vWorldDirection;\n\n\t\t\t\t#include \n\n\t\t\t\tvoid main() {\n\n\t\t\t\t\tvec3 direction = normalize( vWorldDirection );\n\n\t\t\t\t\tvec2 sampleUV = equirectUv( direction );\n\n\t\t\t\t\tgl_FragColor = texture2D( tEquirect, sampleUV );\n\n\t\t\t\t}\n\t\t\t",r=new tu(5,5,5),s=new wh({name:"CubemapFromEquirect",uniforms:a0(i_uniforms),vertexShader:i_vertexShader,fragmentShader:i_fragmentShader,side:Ds,blending:hh});s.uniforms.tEquirect.value=t;const o=new vr(r,s),a=t.minFilter;return t.minFilter===Hg&&(t.minFilter=no),new iI(1,10,this).update(e,o),t.minFilter=a,o.geometry.dispose(),o.material.dispose(),this}clear(e,t,i,r){const s=e.getRenderTarget();for(let o=0;o<6;o++)e.setRenderTarget(this,o),e.clear(t,i,r);e.setRenderTarget(s)}}rI.prototype.isWebGLCubeRenderTarget=!0;const sI=new ne,Ese=new ne,Mse=new js;class nu{constructor(e=new ne(1,0,0),t=0){this.normal=e,this.constant=t}set(e,t){return this.normal.copy(e),this.constant=t,this}setComponents(e,t,i,r){return this.normal.set(e,t,i),this.constant=r,this}setFromNormalAndCoplanarPoint(e,t){return this.normal.copy(e),this.constant=-t.dot(this.normal),this}setFromCoplanarPoints(e,t,i){const r=sI.subVectors(i,t).cross(Ese.subVectors(e,t)).normalize();return this.setFromNormalAndCoplanarPoint(r,e),this}copy(e){return this.normal.copy(e.normal),this.constant=e.constant,this}normalize(){const e=1/this.normal.length();return this.normal.multiplyScalar(e),this.constant*=e,this}negate(){return this.constant*=-1,this.normal.negate(),this}distanceToPoint(e){return this.normal.dot(e)+this.constant}distanceToSphere(e){return this.distanceToPoint(e.center)-e.radius}projectPoint(e,t){return t.copy(this.normal).multiplyScalar(-this.distanceToPoint(e)).add(e)}intersectLine(e,t){const i=e.delta(sI),r=this.normal.dot(i);if(0===r)return 0===this.distanceToPoint(e.start)?t.copy(e.start):null;const s=-(e.start.dot(this.normal)+this.constant)/r;return s<0||s>1?null:t.copy(i).multiplyScalar(s).add(e.start)}intersectsLine(e){const t=this.distanceToPoint(e.start),i=this.distanceToPoint(e.end);return t<0&&i>0||i<0&&t>0}intersectsBox(e){return e.intersectsPlane(this)}intersectsSphere(e){return e.intersectsPlane(this)}coplanarPoint(e){return e.copy(this.normal).multiplyScalar(-this.constant)}applyMatrix4(e,t){const i=t||Mse.getNormalMatrix(e),r=this.coplanarPoint(sI).applyMatrix4(e),s=this.normal.applyMatrix3(i).normalize();return this.constant=-r.dot(s),this}translate(e){return this.constant-=e.dot(this.normal),this}equals(e){return e.normal.equals(this.normal)&&e.constant===this.constant}clone(){return(new this.constructor).copy(this)}}nu.prototype.isPlane=!0;const d0=new op,x2=new ne;class w2{constructor(e=new nu,t=new nu,i=new nu,r=new nu,s=new nu,o=new nu){this.planes=[e,t,i,r,s,o]}set(e,t,i,r,s,o){const a=this.planes;return a[0].copy(e),a[1].copy(t),a[2].copy(i),a[3].copy(r),a[4].copy(s),a[5].copy(o),this}copy(e){const t=this.planes;for(let i=0;i<6;i++)t[i].copy(e.planes[i]);return this}setFromProjectionMatrix(e){const t=this.planes,i=e.elements,r=i[0],s=i[1],o=i[2],a=i[3],c=i[4],u=i[5],p=i[6],g=i[7],v=i[8],y=i[9],x=i[10],T=i[11],N=i[12],k=i[13],A=i[14],H=i[15];return t[0].setComponents(a-r,g-c,T-v,H-N).normalize(),t[1].setComponents(a+r,g+c,T+v,H+N).normalize(),t[2].setComponents(a+s,g+u,T+y,H+k).normalize(),t[3].setComponents(a-s,g-u,T-y,H-k).normalize(),t[4].setComponents(a-o,g-p,T-x,H-A).normalize(),t[5].setComponents(a+o,g+p,T+x,H+A).normalize(),this}intersectsObject(e){const t=e.geometry;return null===t.boundingSphere&&t.computeBoundingSphere(),d0.copy(t.boundingSphere).applyMatrix4(e.matrixWorld),this.intersectsSphere(d0)}intersectsSprite(e){return d0.center.set(0,0,0),d0.radius=.7071067811865476,d0.applyMatrix4(e.matrixWorld),this.intersectsSphere(d0)}intersectsSphere(e){const t=this.planes,i=e.center,r=-e.radius;for(let s=0;s<6;s++)if(t[s].distanceToPoint(i)0?e.max.x:e.min.x,x2.y=r.normal.y>0?e.max.y:e.min.y,x2.z=r.normal.z>0?e.max.z:e.min.z,r.distanceToPoint(x2)<0)return!1}return!0}containsPoint(e){const t=this.planes;for(let i=0;i<6;i++)if(t[i].distanceToPoint(e)<0)return!1;return!0}clone(){return(new this.constructor).copy(this)}}function AB(){let n=null,e=!1,t=null,i=null;function r(s,o){t(s,o),i=n.requestAnimationFrame(r)}return{start:function(){!0!==e&&null!==t&&(i=n.requestAnimationFrame(r),e=!0)},stop:function(){n.cancelAnimationFrame(i),e=!1},setAnimationLoop:function(s){t=s},setContext:function(s){n=s}}}function Cse(n,e){const t=e.isWebGL2,i=new WeakMap;return{get:function o(u){return u.isInterleavedBufferAttribute&&(u=u.data),i.get(u)},remove:function a(u){u.isInterleavedBufferAttribute&&(u=u.data);const p=i.get(u);p&&(n.deleteBuffer(p.buffer),i.delete(u))},update:function c(u,p){if(u.isGLBufferAttribute){const v=i.get(u);return void((!v||v.version 0.0 ) ? v : 0.5 * inversesqrt( max( 1.0 - x * x, 1e-7 ) ) - v;\n\treturn cross( v1, v2 ) * theta_sintheta;\n}\nvec3 LTC_Evaluate( const in vec3 N, const in vec3 V, const in vec3 P, const in mat3 mInv, const in vec3 rectCoords[ 4 ] ) {\n\tvec3 v1 = rectCoords[ 1 ] - rectCoords[ 0 ];\n\tvec3 v2 = rectCoords[ 3 ] - rectCoords[ 0 ];\n\tvec3 lightNormal = cross( v1, v2 );\n\tif( dot( lightNormal, P - rectCoords[ 0 ] ) < 0.0 ) return vec3( 0.0 );\n\tvec3 T1, T2;\n\tT1 = normalize( V - N * dot( V, N ) );\n\tT2 = - cross( N, T1 );\n\tmat3 mat = mInv * transposeMat3( mat3( T1, T2, N ) );\n\tvec3 coords[ 4 ];\n\tcoords[ 0 ] = mat * ( rectCoords[ 0 ] - P );\n\tcoords[ 1 ] = mat * ( rectCoords[ 1 ] - P );\n\tcoords[ 2 ] = mat * ( rectCoords[ 2 ] - P );\n\tcoords[ 3 ] = mat * ( rectCoords[ 3 ] - P );\n\tcoords[ 0 ] = normalize( coords[ 0 ] );\n\tcoords[ 1 ] = normalize( coords[ 1 ] );\n\tcoords[ 2 ] = normalize( coords[ 2 ] );\n\tcoords[ 3 ] = normalize( coords[ 3 ] );\n\tvec3 vectorFormFactor = vec3( 0.0 );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 0 ], coords[ 1 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 1 ], coords[ 2 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 2 ], coords[ 3 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 3 ], coords[ 0 ] );\n\tfloat result = LTC_ClippedSphereFormFactor( vectorFormFactor );\n\treturn vec3( result );\n}\nfloat G_BlinnPhong_Implicit( ) {\n\treturn 0.25;\n}\nfloat D_BlinnPhong( const in float shininess, const in float dotNH ) {\n\treturn RECIPROCAL_PI * ( shininess * 0.5 + 1.0 ) * pow( dotNH, shininess );\n}\nvec3 BRDF_BlinnPhong( const in vec3 lightDir, const in vec3 viewDir, const in vec3 normal, const in vec3 specularColor, const in float shininess ) {\n\tvec3 halfDir = normalize( lightDir + viewDir );\n\tfloat dotNH = saturate( dot( normal, halfDir ) );\n\tfloat dotVH = saturate( dot( viewDir, halfDir ) );\n\tvec3 F = F_Schlick( specularColor, 1.0, dotVH );\n\tfloat G = G_BlinnPhong_Implicit( );\n\tfloat D = D_BlinnPhong( shininess, dotNH );\n\treturn F * ( G * D );\n}\n#if defined( USE_SHEEN )\nfloat D_Charlie( float roughness, float dotNH ) {\n\tfloat alpha = pow2( roughness );\n\tfloat invAlpha = 1.0 / alpha;\n\tfloat cos2h = dotNH * dotNH;\n\tfloat sin2h = max( 1.0 - cos2h, 0.0078125 );\n\treturn ( 2.0 + invAlpha ) * pow( sin2h, invAlpha * 0.5 ) / ( 2.0 * PI );\n}\nfloat V_Neubelt( float dotNV, float dotNL ) {\n\treturn saturate( 1.0 / ( 4.0 * ( dotNL + dotNV - dotNL * dotNV ) ) );\n}\nvec3 BRDF_Sheen( const in vec3 lightDir, const in vec3 viewDir, const in vec3 normal, vec3 sheenColor, const in float sheenRoughness ) {\n\tvec3 halfDir = normalize( lightDir + viewDir );\n\tfloat dotNL = saturate( dot( normal, lightDir ) );\n\tfloat dotNV = saturate( dot( normal, viewDir ) );\n\tfloat dotNH = saturate( dot( normal, halfDir ) );\n\tfloat D = D_Charlie( sheenRoughness, dotNH );\n\tfloat V = V_Neubelt( dotNV, dotNL );\n\treturn sheenColor * ( D * V );\n}\n#endif",bumpmap_pars_fragment:"#ifdef USE_BUMPMAP\n\tuniform sampler2D bumpMap;\n\tuniform float bumpScale;\n\tvec2 dHdxy_fwd() {\n\t\tvec2 dSTdx = dFdx( vUv );\n\t\tvec2 dSTdy = dFdy( vUv );\n\t\tfloat Hll = bumpScale * texture2D( bumpMap, vUv ).x;\n\t\tfloat dBx = bumpScale * texture2D( bumpMap, vUv + dSTdx ).x - Hll;\n\t\tfloat dBy = bumpScale * texture2D( bumpMap, vUv + dSTdy ).x - Hll;\n\t\treturn vec2( dBx, dBy );\n\t}\n\tvec3 perturbNormalArb( vec3 surf_pos, vec3 surf_norm, vec2 dHdxy, float faceDirection ) {\n\t\tvec3 vSigmaX = vec3( dFdx( surf_pos.x ), dFdx( surf_pos.y ), dFdx( surf_pos.z ) );\n\t\tvec3 vSigmaY = vec3( dFdy( surf_pos.x ), dFdy( surf_pos.y ), dFdy( surf_pos.z ) );\n\t\tvec3 vN = surf_norm;\n\t\tvec3 R1 = cross( vSigmaY, vN );\n\t\tvec3 R2 = cross( vN, vSigmaX );\n\t\tfloat fDet = dot( vSigmaX, R1 ) * faceDirection;\n\t\tvec3 vGrad = sign( fDet ) * ( dHdxy.x * R1 + dHdxy.y * R2 );\n\t\treturn normalize( abs( fDet ) * surf_norm - vGrad );\n\t}\n#endif",clipping_planes_fragment:"#if NUM_CLIPPING_PLANES > 0\n\tvec4 plane;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < UNION_CLIPPING_PLANES; i ++ ) {\n\t\tplane = clippingPlanes[ i ];\n\t\tif ( dot( vClipPosition, plane.xyz ) > plane.w ) discard;\n\t}\n\t#pragma unroll_loop_end\n\t#if UNION_CLIPPING_PLANES < NUM_CLIPPING_PLANES\n\t\tbool clipped = true;\n\t\t#pragma unroll_loop_start\n\t\tfor ( int i = UNION_CLIPPING_PLANES; i < NUM_CLIPPING_PLANES; i ++ ) {\n\t\t\tplane = clippingPlanes[ i ];\n\t\t\tclipped = ( dot( vClipPosition, plane.xyz ) > plane.w ) && clipped;\n\t\t}\n\t\t#pragma unroll_loop_end\n\t\tif ( clipped ) discard;\n\t#endif\n#endif",clipping_planes_pars_fragment:"#if NUM_CLIPPING_PLANES > 0\n\tvarying vec3 vClipPosition;\n\tuniform vec4 clippingPlanes[ NUM_CLIPPING_PLANES ];\n#endif",clipping_planes_pars_vertex:"#if NUM_CLIPPING_PLANES > 0\n\tvarying vec3 vClipPosition;\n#endif",clipping_planes_vertex:"#if NUM_CLIPPING_PLANES > 0\n\tvClipPosition = - mvPosition.xyz;\n#endif",color_fragment:"#if defined( USE_COLOR_ALPHA )\n\tdiffuseColor *= vColor;\n#elif defined( USE_COLOR )\n\tdiffuseColor.rgb *= vColor;\n#endif",color_pars_fragment:"#if defined( USE_COLOR_ALPHA )\n\tvarying vec4 vColor;\n#elif defined( USE_COLOR )\n\tvarying vec3 vColor;\n#endif",color_pars_vertex:"#if defined( USE_COLOR_ALPHA )\n\tvarying vec4 vColor;\n#elif defined( USE_COLOR ) || defined( USE_INSTANCING_COLOR )\n\tvarying vec3 vColor;\n#endif",color_vertex:"#if defined( USE_COLOR_ALPHA )\n\tvColor = vec4( 1.0 );\n#elif defined( USE_COLOR ) || defined( USE_INSTANCING_COLOR )\n\tvColor = vec3( 1.0 );\n#endif\n#ifdef USE_COLOR\n\tvColor *= color;\n#endif\n#ifdef USE_INSTANCING_COLOR\n\tvColor.xyz *= instanceColor.xyz;\n#endif",common:"#define PI 3.141592653589793\n#define PI2 6.283185307179586\n#define PI_HALF 1.5707963267948966\n#define RECIPROCAL_PI 0.3183098861837907\n#define RECIPROCAL_PI2 0.15915494309189535\n#define EPSILON 1e-6\n#ifndef saturate\n#define saturate( a ) clamp( a, 0.0, 1.0 )\n#endif\n#define whiteComplement( a ) ( 1.0 - saturate( a ) )\nfloat pow2( const in float x ) { return x*x; }\nfloat pow3( const in float x ) { return x*x*x; }\nfloat pow4( const in float x ) { float x2 = x*x; return x2*x2; }\nfloat max3( const in vec3 v ) { return max( max( v.x, v.y ), v.z ); }\nfloat average( const in vec3 color ) { return dot( color, vec3( 0.3333 ) ); }\nhighp float rand( const in vec2 uv ) {\n\tconst highp float a = 12.9898, b = 78.233, c = 43758.5453;\n\thighp float dt = dot( uv.xy, vec2( a,b ) ), sn = mod( dt, PI );\n\treturn fract( sin( sn ) * c );\n}\n#ifdef HIGH_PRECISION\n\tfloat precisionSafeLength( vec3 v ) { return length( v ); }\n#else\n\tfloat precisionSafeLength( vec3 v ) {\n\t\tfloat maxComponent = max3( abs( v ) );\n\t\treturn length( v / maxComponent ) * maxComponent;\n\t}\n#endif\nstruct IncidentLight {\n\tvec3 color;\n\tvec3 direction;\n\tbool visible;\n};\nstruct ReflectedLight {\n\tvec3 directDiffuse;\n\tvec3 directSpecular;\n\tvec3 indirectDiffuse;\n\tvec3 indirectSpecular;\n};\nstruct GeometricContext {\n\tvec3 position;\n\tvec3 normal;\n\tvec3 viewDir;\n#ifdef USE_CLEARCOAT\n\tvec3 clearcoatNormal;\n#endif\n};\nvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n}\nvec3 inverseTransformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( vec4( dir, 0.0 ) * matrix ).xyz );\n}\nmat3 transposeMat3( const in mat3 m ) {\n\tmat3 tmp;\n\ttmp[ 0 ] = vec3( m[ 0 ].x, m[ 1 ].x, m[ 2 ].x );\n\ttmp[ 1 ] = vec3( m[ 0 ].y, m[ 1 ].y, m[ 2 ].y );\n\ttmp[ 2 ] = vec3( m[ 0 ].z, m[ 1 ].z, m[ 2 ].z );\n\treturn tmp;\n}\nfloat linearToRelativeLuminance( const in vec3 color ) {\n\tvec3 weights = vec3( 0.2126, 0.7152, 0.0722 );\n\treturn dot( weights, color.rgb );\n}\nbool isPerspectiveMatrix( mat4 m ) {\n\treturn m[ 2 ][ 3 ] == - 1.0;\n}\nvec2 equirectUv( in vec3 dir ) {\n\tfloat u = atan( dir.z, dir.x ) * RECIPROCAL_PI2 + 0.5;\n\tfloat v = asin( clamp( dir.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;\n\treturn vec2( u, v );\n}",cube_uv_reflection_fragment:"#ifdef ENVMAP_TYPE_CUBE_UV\n\t#define cubeUV_maxMipLevel 8.0\n\t#define cubeUV_minMipLevel 4.0\n\t#define cubeUV_maxTileSize 256.0\n\t#define cubeUV_minTileSize 16.0\n\tfloat getFace( vec3 direction ) {\n\t\tvec3 absDirection = abs( direction );\n\t\tfloat face = - 1.0;\n\t\tif ( absDirection.x > absDirection.z ) {\n\t\t\tif ( absDirection.x > absDirection.y )\n\t\t\t\tface = direction.x > 0.0 ? 0.0 : 3.0;\n\t\t\telse\n\t\t\t\tface = direction.y > 0.0 ? 1.0 : 4.0;\n\t\t} else {\n\t\t\tif ( absDirection.z > absDirection.y )\n\t\t\t\tface = direction.z > 0.0 ? 2.0 : 5.0;\n\t\t\telse\n\t\t\t\tface = direction.y > 0.0 ? 1.0 : 4.0;\n\t\t}\n\t\treturn face;\n\t}\n\tvec2 getUV( vec3 direction, float face ) {\n\t\tvec2 uv;\n\t\tif ( face == 0.0 ) {\n\t\t\tuv = vec2( direction.z, direction.y ) / abs( direction.x );\n\t\t} else if ( face == 1.0 ) {\n\t\t\tuv = vec2( - direction.x, - direction.z ) / abs( direction.y );\n\t\t} else if ( face == 2.0 ) {\n\t\t\tuv = vec2( - direction.x, direction.y ) / abs( direction.z );\n\t\t} else if ( face == 3.0 ) {\n\t\t\tuv = vec2( - direction.z, direction.y ) / abs( direction.x );\n\t\t} else if ( face == 4.0 ) {\n\t\t\tuv = vec2( - direction.x, direction.z ) / abs( direction.y );\n\t\t} else {\n\t\t\tuv = vec2( direction.x, direction.y ) / abs( direction.z );\n\t\t}\n\t\treturn 0.5 * ( uv + 1.0 );\n\t}\n\tvec3 bilinearCubeUV( sampler2D envMap, vec3 direction, float mipInt ) {\n\t\tfloat face = getFace( direction );\n\t\tfloat filterInt = max( cubeUV_minMipLevel - mipInt, 0.0 );\n\t\tmipInt = max( mipInt, cubeUV_minMipLevel );\n\t\tfloat faceSize = exp2( mipInt );\n\t\tfloat texelSize = 1.0 / ( 3.0 * cubeUV_maxTileSize );\n\t\tvec2 uv = getUV( direction, face ) * ( faceSize - 1.0 );\n\t\tvec2 f = fract( uv );\n\t\tuv += 0.5 - f;\n\t\tif ( face > 2.0 ) {\n\t\t\tuv.y += faceSize;\n\t\t\tface -= 3.0;\n\t\t}\n\t\tuv.x += face * faceSize;\n\t\tif ( mipInt < cubeUV_maxMipLevel ) {\n\t\t\tuv.y += 2.0 * cubeUV_maxTileSize;\n\t\t}\n\t\tuv.y += filterInt * 2.0 * cubeUV_minTileSize;\n\t\tuv.x += 3.0 * max( 0.0, cubeUV_maxTileSize - 2.0 * faceSize );\n\t\tuv *= texelSize;\n\t\tvec3 tl = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tuv.x += texelSize;\n\t\tvec3 tr = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tuv.y += texelSize;\n\t\tvec3 br = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tuv.x -= texelSize;\n\t\tvec3 bl = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tvec3 tm = mix( tl, tr, f.x );\n\t\tvec3 bm = mix( bl, br, f.x );\n\t\treturn mix( tm, bm, f.y );\n\t}\n\t#define r0 1.0\n\t#define v0 0.339\n\t#define m0 - 2.0\n\t#define r1 0.8\n\t#define v1 0.276\n\t#define m1 - 1.0\n\t#define r4 0.4\n\t#define v4 0.046\n\t#define m4 2.0\n\t#define r5 0.305\n\t#define v5 0.016\n\t#define m5 3.0\n\t#define r6 0.21\n\t#define v6 0.0038\n\t#define m6 4.0\n\tfloat roughnessToMip( float roughness ) {\n\t\tfloat mip = 0.0;\n\t\tif ( roughness >= r1 ) {\n\t\t\tmip = ( r0 - roughness ) * ( m1 - m0 ) / ( r0 - r1 ) + m0;\n\t\t} else if ( roughness >= r4 ) {\n\t\t\tmip = ( r1 - roughness ) * ( m4 - m1 ) / ( r1 - r4 ) + m1;\n\t\t} else if ( roughness >= r5 ) {\n\t\t\tmip = ( r4 - roughness ) * ( m5 - m4 ) / ( r4 - r5 ) + m4;\n\t\t} else if ( roughness >= r6 ) {\n\t\t\tmip = ( r5 - roughness ) * ( m6 - m5 ) / ( r5 - r6 ) + m5;\n\t\t} else {\n\t\t\tmip = - 2.0 * log2( 1.16 * roughness );\t\t}\n\t\treturn mip;\n\t}\n\tvec4 textureCubeUV( sampler2D envMap, vec3 sampleDir, float roughness ) {\n\t\tfloat mip = clamp( roughnessToMip( roughness ), m0, cubeUV_maxMipLevel );\n\t\tfloat mipF = fract( mip );\n\t\tfloat mipInt = floor( mip );\n\t\tvec3 color0 = bilinearCubeUV( envMap, sampleDir, mipInt );\n\t\tif ( mipF == 0.0 ) {\n\t\t\treturn vec4( color0, 1.0 );\n\t\t} else {\n\t\t\tvec3 color1 = bilinearCubeUV( envMap, sampleDir, mipInt + 1.0 );\n\t\t\treturn vec4( mix( color0, color1, mipF ), 1.0 );\n\t\t}\n\t}\n#endif",defaultnormal_vertex:"vec3 transformedNormal = objectNormal;\n#ifdef USE_INSTANCING\n\tmat3 m = mat3( instanceMatrix );\n\ttransformedNormal /= vec3( dot( m[ 0 ], m[ 0 ] ), dot( m[ 1 ], m[ 1 ] ), dot( m[ 2 ], m[ 2 ] ) );\n\ttransformedNormal = m * transformedNormal;\n#endif\ntransformedNormal = normalMatrix * transformedNormal;\n#ifdef FLIP_SIDED\n\ttransformedNormal = - transformedNormal;\n#endif\n#ifdef USE_TANGENT\n\tvec3 transformedTangent = ( modelViewMatrix * vec4( objectTangent, 0.0 ) ).xyz;\n\t#ifdef FLIP_SIDED\n\t\ttransformedTangent = - transformedTangent;\n\t#endif\n#endif",displacementmap_pars_vertex:"#ifdef USE_DISPLACEMENTMAP\n\tuniform sampler2D displacementMap;\n\tuniform float displacementScale;\n\tuniform float displacementBias;\n#endif",displacementmap_vertex:"#ifdef USE_DISPLACEMENTMAP\n\ttransformed += normalize( objectNormal ) * ( texture2D( displacementMap, vUv ).x * displacementScale + displacementBias );\n#endif",emissivemap_fragment:"#ifdef USE_EMISSIVEMAP\n\tvec4 emissiveColor = texture2D( emissiveMap, vUv );\n\temissiveColor.rgb = emissiveMapTexelToLinear( emissiveColor ).rgb;\n\ttotalEmissiveRadiance *= emissiveColor.rgb;\n#endif",emissivemap_pars_fragment:"#ifdef USE_EMISSIVEMAP\n\tuniform sampler2D emissiveMap;\n#endif",encodings_fragment:"gl_FragColor = linearToOutputTexel( gl_FragColor );",encodings_pars_fragment:"\nvec4 LinearToLinear( in vec4 value ) {\n\treturn value;\n}\nvec4 GammaToLinear( in vec4 value, in float gammaFactor ) {\n\treturn vec4( pow( value.rgb, vec3( gammaFactor ) ), value.a );\n}\nvec4 LinearToGamma( in vec4 value, in float gammaFactor ) {\n\treturn vec4( pow( value.rgb, vec3( 1.0 / gammaFactor ) ), value.a );\n}\nvec4 sRGBToLinear( in vec4 value ) {\n\treturn vec4( mix( pow( value.rgb * 0.9478672986 + vec3( 0.0521327014 ), vec3( 2.4 ) ), value.rgb * 0.0773993808, vec3( lessThanEqual( value.rgb, vec3( 0.04045 ) ) ) ), value.a );\n}\nvec4 LinearTosRGB( in vec4 value ) {\n\treturn vec4( mix( pow( value.rgb, vec3( 0.41666 ) ) * 1.055 - vec3( 0.055 ), value.rgb * 12.92, vec3( lessThanEqual( value.rgb, vec3( 0.0031308 ) ) ) ), value.a );\n}\nvec4 RGBEToLinear( in vec4 value ) {\n\treturn vec4( value.rgb * exp2( value.a * 255.0 - 128.0 ), 1.0 );\n}\nvec4 LinearToRGBE( in vec4 value ) {\n\tfloat maxComponent = max( max( value.r, value.g ), value.b );\n\tfloat fExp = clamp( ceil( log2( maxComponent ) ), -128.0, 127.0 );\n\treturn vec4( value.rgb / exp2( fExp ), ( fExp + 128.0 ) / 255.0 );\n}\nvec4 RGBMToLinear( in vec4 value, in float maxRange ) {\n\treturn vec4( value.rgb * value.a * maxRange, 1.0 );\n}\nvec4 LinearToRGBM( in vec4 value, in float maxRange ) {\n\tfloat maxRGB = max( value.r, max( value.g, value.b ) );\n\tfloat M = clamp( maxRGB / maxRange, 0.0, 1.0 );\n\tM = ceil( M * 255.0 ) / 255.0;\n\treturn vec4( value.rgb / ( M * maxRange ), M );\n}\nvec4 RGBDToLinear( in vec4 value, in float maxRange ) {\n\treturn vec4( value.rgb * ( ( maxRange / 255.0 ) / value.a ), 1.0 );\n}\nvec4 LinearToRGBD( in vec4 value, in float maxRange ) {\n\tfloat maxRGB = max( value.r, max( value.g, value.b ) );\n\tfloat D = max( maxRange / maxRGB, 1.0 );\n\tD = clamp( floor( D ) / 255.0, 0.0, 1.0 );\n\treturn vec4( value.rgb * ( D * ( 255.0 / maxRange ) ), D );\n}",envmap_fragment:"#ifdef USE_ENVMAP\n\t#ifdef ENV_WORLDPOS\n\t\tvec3 cameraToFrag;\n\t\tif ( isOrthographic ) {\n\t\t\tcameraToFrag = normalize( vec3( - viewMatrix[ 0 ][ 2 ], - viewMatrix[ 1 ][ 2 ], - viewMatrix[ 2 ][ 2 ] ) );\n\t\t} else {\n\t\t\tcameraToFrag = normalize( vWorldPosition - cameraPosition );\n\t\t}\n\t\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvec3 reflectVec = reflect( cameraToFrag, worldNormal );\n\t\t#else\n\t\t\tvec3 reflectVec = refract( cameraToFrag, worldNormal, refractionRatio );\n\t\t#endif\n\t#else\n\t\tvec3 reflectVec = vReflect;\n\t#endif\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tvec4 envColor = textureCube( envMap, vec3( flipEnvMap * reflectVec.x, reflectVec.yz ) );\n\t\tenvColor = envMapTexelToLinear( envColor );\n\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\tvec4 envColor = textureCubeUV( envMap, reflectVec, 0.0 );\n\t#else\n\t\tvec4 envColor = vec4( 0.0 );\n\t#endif\n\t#ifdef ENVMAP_BLENDING_MULTIPLY\n\t\toutgoingLight = mix( outgoingLight, outgoingLight * envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_MIX )\n\t\toutgoingLight = mix( outgoingLight, envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_ADD )\n\t\toutgoingLight += envColor.xyz * specularStrength * reflectivity;\n\t#endif\n#endif",envmap_common_pars_fragment:"#ifdef USE_ENVMAP\n\tuniform float envMapIntensity;\n\tuniform float flipEnvMap;\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tuniform samplerCube envMap;\n\t#else\n\t\tuniform sampler2D envMap;\n\t#endif\n\t\n#endif",envmap_pars_fragment:"#ifdef USE_ENVMAP\n\tuniform float reflectivity;\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\t#define ENV_WORLDPOS\n\t#endif\n\t#ifdef ENV_WORLDPOS\n\t\tvarying vec3 vWorldPosition;\n\t\tuniform float refractionRatio;\n\t#else\n\t\tvarying vec3 vReflect;\n\t#endif\n#endif",envmap_pars_vertex:"#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) ||defined( PHONG )\n\t\t#define ENV_WORLDPOS\n\t#endif\n\t#ifdef ENV_WORLDPOS\n\t\t\n\t\tvarying vec3 vWorldPosition;\n\t#else\n\t\tvarying vec3 vReflect;\n\t\tuniform float refractionRatio;\n\t#endif\n#endif",envmap_physical_pars_fragment:"#if defined( USE_ENVMAP )\n\t#ifdef ENVMAP_MODE_REFRACTION\n\t\tuniform float refractionRatio;\n\t#endif\n\tvec3 getIBLIrradiance( const in vec3 normal ) {\n\t\t#if defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\n\t\t\tvec4 envMapColor = textureCubeUV( envMap, worldNormal, 1.0 );\n\t\t\treturn PI * envMapColor.rgb * envMapIntensity;\n\t\t#else\n\t\t\treturn vec3( 0.0 );\n\t\t#endif\n\t}\n\tvec3 getIBLRadiance( const in vec3 viewDir, const in vec3 normal, const in float roughness ) {\n\t\t#if defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec3 reflectVec;\n\t\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\t\treflectVec = reflect( - viewDir, normal );\n\t\t\t\treflectVec = normalize( mix( reflectVec, normal, roughness * roughness) );\n\t\t\t#else\n\t\t\t\treflectVec = refract( - viewDir, normal, refractionRatio );\n\t\t\t#endif\n\t\t\treflectVec = inverseTransformDirection( reflectVec, viewMatrix );\n\t\t\tvec4 envMapColor = textureCubeUV( envMap, reflectVec, roughness );\n\t\t\treturn envMapColor.rgb * envMapIntensity;\n\t\t#else\n\t\t\treturn vec3( 0.0 );\n\t\t#endif\n\t}\n#endif",envmap_vertex:"#ifdef USE_ENVMAP\n\t#ifdef ENV_WORLDPOS\n\t\tvWorldPosition = worldPosition.xyz;\n\t#else\n\t\tvec3 cameraToVertex;\n\t\tif ( isOrthographic ) {\n\t\t\tcameraToVertex = normalize( vec3( - viewMatrix[ 0 ][ 2 ], - viewMatrix[ 1 ][ 2 ], - viewMatrix[ 2 ][ 2 ] ) );\n\t\t} else {\n\t\t\tcameraToVertex = normalize( worldPosition.xyz - cameraPosition );\n\t\t}\n\t\tvec3 worldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvReflect = reflect( cameraToVertex, worldNormal );\n\t\t#else\n\t\t\tvReflect = refract( cameraToVertex, worldNormal, refractionRatio );\n\t\t#endif\n\t#endif\n#endif",fog_vertex:"#ifdef USE_FOG\n\tvFogDepth = - mvPosition.z;\n#endif",fog_pars_vertex:"#ifdef USE_FOG\n\tvarying float vFogDepth;\n#endif",fog_fragment:"#ifdef USE_FOG\n\t#ifdef FOG_EXP2\n\t\tfloat fogFactor = 1.0 - exp( - fogDensity * fogDensity * vFogDepth * vFogDepth );\n\t#else\n\t\tfloat fogFactor = smoothstep( fogNear, fogFar, vFogDepth );\n\t#endif\n\tgl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );\n#endif",fog_pars_fragment:"#ifdef USE_FOG\n\tuniform vec3 fogColor;\n\tvarying float vFogDepth;\n\t#ifdef FOG_EXP2\n\t\tuniform float fogDensity;\n\t#else\n\t\tuniform float fogNear;\n\t\tuniform float fogFar;\n\t#endif\n#endif",gradientmap_pars_fragment:"#ifdef USE_GRADIENTMAP\n\tuniform sampler2D gradientMap;\n#endif\nvec3 getGradientIrradiance( vec3 normal, vec3 lightDirection ) {\n\tfloat dotNL = dot( normal, lightDirection );\n\tvec2 coord = vec2( dotNL * 0.5 + 0.5, 0.0 );\n\t#ifdef USE_GRADIENTMAP\n\t\treturn texture2D( gradientMap, coord ).rgb;\n\t#else\n\t\treturn ( coord.x < 0.7 ) ? vec3( 0.7 ) : vec3( 1.0 );\n\t#endif\n}",lightmap_fragment:"#ifdef USE_LIGHTMAP\n\tvec4 lightMapTexel = texture2D( lightMap, vUv2 );\n\tvec3 lightMapIrradiance = lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tlightMapIrradiance *= PI;\n\t#endif\n\treflectedLight.indirectDiffuse += lightMapIrradiance;\n#endif",lightmap_pars_fragment:"#ifdef USE_LIGHTMAP\n\tuniform sampler2D lightMap;\n\tuniform float lightMapIntensity;\n#endif",lights_lambert_vertex:"vec3 diffuse = vec3( 1.0 );\nGeometricContext geometry;\ngeometry.position = mvPosition.xyz;\ngeometry.normal = normalize( transformedNormal );\ngeometry.viewDir = ( isOrthographic ) ? vec3( 0, 0, 1 ) : normalize( -mvPosition.xyz );\nGeometricContext backGeometry;\nbackGeometry.position = geometry.position;\nbackGeometry.normal = -geometry.normal;\nbackGeometry.viewDir = geometry.viewDir;\nvLightFront = vec3( 0.0 );\nvIndirectFront = vec3( 0.0 );\n#ifdef DOUBLE_SIDED\n\tvLightBack = vec3( 0.0 );\n\tvIndirectBack = vec3( 0.0 );\n#endif\nIncidentLight directLight;\nfloat dotNL;\nvec3 directLightColor_Diffuse;\nvIndirectFront += getAmbientLightIrradiance( ambientLightColor );\nvIndirectFront += getLightProbeIrradiance( lightProbe, geometry.normal );\n#ifdef DOUBLE_SIDED\n\tvIndirectBack += getAmbientLightIrradiance( ambientLightColor );\n\tvIndirectBack += getLightProbeIrradiance( lightProbe, backGeometry.normal );\n#endif\n#if NUM_POINT_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tgetPointLightInfo( pointLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( - dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tgetSpotLightInfo( spotLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( - dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if NUM_DIR_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tgetDirectionalLightInfo( directionalLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( - dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\tvIndirectFront += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry.normal );\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvIndirectBack += getHemisphereLightIrradiance( hemisphereLights[ i ], backGeometry.normal );\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif",lights_pars_begin:"uniform bool receiveShadow;\nuniform vec3 ambientLightColor;\nuniform vec3 lightProbe[ 9 ];\nvec3 shGetIrradianceAt( in vec3 normal, in vec3 shCoefficients[ 9 ] ) {\n\tfloat x = normal.x, y = normal.y, z = normal.z;\n\tvec3 result = shCoefficients[ 0 ] * 0.886227;\n\tresult += shCoefficients[ 1 ] * 2.0 * 0.511664 * y;\n\tresult += shCoefficients[ 2 ] * 2.0 * 0.511664 * z;\n\tresult += shCoefficients[ 3 ] * 2.0 * 0.511664 * x;\n\tresult += shCoefficients[ 4 ] * 2.0 * 0.429043 * x * y;\n\tresult += shCoefficients[ 5 ] * 2.0 * 0.429043 * y * z;\n\tresult += shCoefficients[ 6 ] * ( 0.743125 * z * z - 0.247708 );\n\tresult += shCoefficients[ 7 ] * 2.0 * 0.429043 * x * z;\n\tresult += shCoefficients[ 8 ] * 0.429043 * ( x * x - y * y );\n\treturn result;\n}\nvec3 getLightProbeIrradiance( const in vec3 lightProbe[ 9 ], const in vec3 normal ) {\n\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\n\tvec3 irradiance = shGetIrradianceAt( worldNormal, lightProbe );\n\treturn irradiance;\n}\nvec3 getAmbientLightIrradiance( const in vec3 ambientLightColor ) {\n\tvec3 irradiance = ambientLightColor;\n\treturn irradiance;\n}\nfloat getDistanceAttenuation( const in float lightDistance, const in float cutoffDistance, const in float decayExponent ) {\n\t#if defined ( PHYSICALLY_CORRECT_LIGHTS )\n\t\tfloat distanceFalloff = 1.0 / max( pow( lightDistance, decayExponent ), 0.01 );\n\t\tif ( cutoffDistance > 0.0 ) {\n\t\t\tdistanceFalloff *= pow2( saturate( 1.0 - pow4( lightDistance / cutoffDistance ) ) );\n\t\t}\n\t\treturn distanceFalloff;\n\t#else\n\t\tif ( cutoffDistance > 0.0 && decayExponent > 0.0 ) {\n\t\t\treturn pow( saturate( - lightDistance / cutoffDistance + 1.0 ), decayExponent );\n\t\t}\n\t\treturn 1.0;\n\t#endif\n}\nfloat getSpotAttenuation( const in float coneCosine, const in float penumbraCosine, const in float angleCosine ) {\n\treturn smoothstep( coneCosine, penumbraCosine, angleCosine );\n}\n#if NUM_DIR_LIGHTS > 0\n\tstruct DirectionalLight {\n\t\tvec3 direction;\n\t\tvec3 color;\n\t};\n\tuniform DirectionalLight directionalLights[ NUM_DIR_LIGHTS ];\n\tvoid getDirectionalLightInfo( const in DirectionalLight directionalLight, const in GeometricContext geometry, out IncidentLight light ) {\n\t\tlight.color = directionalLight.color;\n\t\tlight.direction = directionalLight.direction;\n\t\tlight.visible = true;\n\t}\n#endif\n#if NUM_POINT_LIGHTS > 0\n\tstruct PointLight {\n\t\tvec3 position;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t};\n\tuniform PointLight pointLights[ NUM_POINT_LIGHTS ];\n\tvoid getPointLightInfo( const in PointLight pointLight, const in GeometricContext geometry, out IncidentLight light ) {\n\t\tvec3 lVector = pointLight.position - geometry.position;\n\t\tlight.direction = normalize( lVector );\n\t\tfloat lightDistance = length( lVector );\n\t\tlight.color = pointLight.color;\n\t\tlight.color *= getDistanceAttenuation( lightDistance, pointLight.distance, pointLight.decay );\n\t\tlight.visible = ( light.color != vec3( 0.0 ) );\n\t}\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\tstruct SpotLight {\n\t\tvec3 position;\n\t\tvec3 direction;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t\tfloat coneCos;\n\t\tfloat penumbraCos;\n\t};\n\tuniform SpotLight spotLights[ NUM_SPOT_LIGHTS ];\n\tvoid getSpotLightInfo( const in SpotLight spotLight, const in GeometricContext geometry, out IncidentLight light ) {\n\t\tvec3 lVector = spotLight.position - geometry.position;\n\t\tlight.direction = normalize( lVector );\n\t\tfloat angleCos = dot( light.direction, spotLight.direction );\n\t\tfloat spotAttenuation = getSpotAttenuation( spotLight.coneCos, spotLight.penumbraCos, angleCos );\n\t\tif ( spotAttenuation > 0.0 ) {\n\t\t\tfloat lightDistance = length( lVector );\n\t\t\tlight.color = spotLight.color * spotAttenuation;\n\t\t\tlight.color *= getDistanceAttenuation( lightDistance, spotLight.distance, spotLight.decay );\n\t\t\tlight.visible = ( light.color != vec3( 0.0 ) );\n\t\t} else {\n\t\t\tlight.color = vec3( 0.0 );\n\t\t\tlight.visible = false;\n\t\t}\n\t}\n#endif\n#if NUM_RECT_AREA_LIGHTS > 0\n\tstruct RectAreaLight {\n\t\tvec3 color;\n\t\tvec3 position;\n\t\tvec3 halfWidth;\n\t\tvec3 halfHeight;\n\t};\n\tuniform sampler2D ltc_1;\tuniform sampler2D ltc_2;\n\tuniform RectAreaLight rectAreaLights[ NUM_RECT_AREA_LIGHTS ];\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\tstruct HemisphereLight {\n\t\tvec3 direction;\n\t\tvec3 skyColor;\n\t\tvec3 groundColor;\n\t};\n\tuniform HemisphereLight hemisphereLights[ NUM_HEMI_LIGHTS ];\n\tvec3 getHemisphereLightIrradiance( const in HemisphereLight hemiLight, const in vec3 normal ) {\n\t\tfloat dotNL = dot( normal, hemiLight.direction );\n\t\tfloat hemiDiffuseWeight = 0.5 * dotNL + 0.5;\n\t\tvec3 irradiance = mix( hemiLight.groundColor, hemiLight.skyColor, hemiDiffuseWeight );\n\t\treturn irradiance;\n\t}\n#endif",lights_toon_fragment:"ToonMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb;",lights_toon_pars_fragment:"varying vec3 vViewPosition;\nstruct ToonMaterial {\n\tvec3 diffuseColor;\n};\nvoid RE_Direct_Toon( const in IncidentLight directLight, const in GeometricContext geometry, const in ToonMaterial material, inout ReflectedLight reflectedLight ) {\n\tvec3 irradiance = getGradientIrradiance( geometry.normal, directLight.direction ) * directLight.color;\n\treflectedLight.directDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectDiffuse_Toon( const in vec3 irradiance, const in GeometricContext geometry, const in ToonMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n}\n#define RE_Direct\t\t\t\tRE_Direct_Toon\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_Toon\n#define Material_LightProbeLOD( material )\t(0)",lights_phong_fragment:"BlinnPhongMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb;\nmaterial.specularColor = specular;\nmaterial.specularShininess = shininess;\nmaterial.specularStrength = specularStrength;",lights_phong_pars_fragment:"varying vec3 vViewPosition;\nstruct BlinnPhongMaterial {\n\tvec3 diffuseColor;\n\tvec3 specularColor;\n\tfloat specularShininess;\n\tfloat specularStrength;\n};\nvoid RE_Direct_BlinnPhong( const in IncidentLight directLight, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\tvec3 irradiance = dotNL * directLight.color;\n\treflectedLight.directDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n\treflectedLight.directSpecular += irradiance * BRDF_BlinnPhong( directLight.direction, geometry.viewDir, geometry.normal, material.specularColor, material.specularShininess ) * material.specularStrength;\n}\nvoid RE_IndirectDiffuse_BlinnPhong( const in vec3 irradiance, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n}\n#define RE_Direct\t\t\t\tRE_Direct_BlinnPhong\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_BlinnPhong\n#define Material_LightProbeLOD( material )\t(0)",lights_physical_fragment:"PhysicalMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb * ( 1.0 - metalnessFactor );\nvec3 dxy = max( abs( dFdx( geometryNormal ) ), abs( dFdy( geometryNormal ) ) );\nfloat geometryRoughness = max( max( dxy.x, dxy.y ), dxy.z );\nmaterial.roughness = max( roughnessFactor, 0.0525 );material.roughness += geometryRoughness;\nmaterial.roughness = min( material.roughness, 1.0 );\n#ifdef IOR\n\t#ifdef SPECULAR\n\t\tfloat specularIntensityFactor = specularIntensity;\n\t\tvec3 specularColorFactor = specularColor;\n\t\t#ifdef USE_SPECULARINTENSITYMAP\n\t\t\tspecularIntensityFactor *= texture2D( specularIntensityMap, vUv ).a;\n\t\t#endif\n\t\t#ifdef USE_SPECULARCOLORMAP\n\t\t\tspecularColorFactor *= specularColorMapTexelToLinear( texture2D( specularColorMap, vUv ) ).rgb;\n\t\t#endif\n\t\tmaterial.specularF90 = mix( specularIntensityFactor, 1.0, metalnessFactor );\n\t#else\n\t\tfloat specularIntensityFactor = 1.0;\n\t\tvec3 specularColorFactor = vec3( 1.0 );\n\t\tmaterial.specularF90 = 1.0;\n\t#endif\n\tmaterial.specularColor = mix( min( pow2( ( ior - 1.0 ) / ( ior + 1.0 ) ) * specularColorFactor, vec3( 1.0 ) ) * specularIntensityFactor, diffuseColor.rgb, metalnessFactor );\n#else\n\tmaterial.specularColor = mix( vec3( 0.04 ), diffuseColor.rgb, metalnessFactor );\n\tmaterial.specularF90 = 1.0;\n#endif\n#ifdef USE_CLEARCOAT\n\tmaterial.clearcoat = clearcoat;\n\tmaterial.clearcoatRoughness = clearcoatRoughness;\n\tmaterial.clearcoatF0 = vec3( 0.04 );\n\tmaterial.clearcoatF90 = 1.0;\n\t#ifdef USE_CLEARCOATMAP\n\t\tmaterial.clearcoat *= texture2D( clearcoatMap, vUv ).x;\n\t#endif\n\t#ifdef USE_CLEARCOAT_ROUGHNESSMAP\n\t\tmaterial.clearcoatRoughness *= texture2D( clearcoatRoughnessMap, vUv ).y;\n\t#endif\n\tmaterial.clearcoat = saturate( material.clearcoat );\tmaterial.clearcoatRoughness = max( material.clearcoatRoughness, 0.0525 );\n\tmaterial.clearcoatRoughness += geometryRoughness;\n\tmaterial.clearcoatRoughness = min( material.clearcoatRoughness, 1.0 );\n#endif\n#ifdef USE_SHEEN\n\tmaterial.sheenColor = sheenColor;\n\t#ifdef USE_SHEENCOLORMAP\n\t\tmaterial.sheenColor *= sheenColorMapTexelToLinear( texture2D( sheenColorMap, vUv ) ).rgb;\n\t#endif\n\tmaterial.sheenRoughness = clamp( sheenRoughness, 0.07, 1.0 );\n\t#ifdef USE_SHEENROUGHNESSMAP\n\t\tmaterial.sheenRoughness *= texture2D( sheenRoughnessMap, vUv ).a;\n\t#endif\n#endif",lights_physical_pars_fragment:"struct PhysicalMaterial {\n\tvec3 diffuseColor;\n\tfloat roughness;\n\tvec3 specularColor;\n\tfloat specularF90;\n\t#ifdef USE_CLEARCOAT\n\t\tfloat clearcoat;\n\t\tfloat clearcoatRoughness;\n\t\tvec3 clearcoatF0;\n\t\tfloat clearcoatF90;\n\t#endif\n\t#ifdef USE_SHEEN\n\t\tvec3 sheenColor;\n\t\tfloat sheenRoughness;\n\t#endif\n};\nvec3 clearcoatSpecular = vec3( 0.0 );\nvec2 DFGApprox( const in vec3 normal, const in vec3 viewDir, const in float roughness ) {\n\tfloat dotNV = saturate( dot( normal, viewDir ) );\n\tconst vec4 c0 = vec4( - 1, - 0.0275, - 0.572, 0.022 );\n\tconst vec4 c1 = vec4( 1, 0.0425, 1.04, - 0.04 );\n\tvec4 r = roughness * c0 + c1;\n\tfloat a004 = min( r.x * r.x, exp2( - 9.28 * dotNV ) ) * r.x + r.y;\n\tvec2 fab = vec2( - 1.04, 1.04 ) * a004 + r.zw;\n\treturn fab;\n}\nvec3 EnvironmentBRDF( const in vec3 normal, const in vec3 viewDir, const in vec3 specularColor, const in float specularF90, const in float roughness ) {\n\tvec2 fab = DFGApprox( normal, viewDir, roughness );\n\treturn specularColor * fab.x + specularF90 * fab.y;\n}\nvoid computeMultiscattering( const in vec3 normal, const in vec3 viewDir, const in vec3 specularColor, const in float specularF90, const in float roughness, inout vec3 singleScatter, inout vec3 multiScatter ) {\n\tvec2 fab = DFGApprox( normal, viewDir, roughness );\n\tvec3 FssEss = specularColor * fab.x + specularF90 * fab.y;\n\tfloat Ess = fab.x + fab.y;\n\tfloat Ems = 1.0 - Ess;\n\tvec3 Favg = specularColor + ( 1.0 - specularColor ) * 0.047619;\tvec3 Fms = FssEss * Favg / ( 1.0 - Ems * Favg );\n\tsingleScatter += FssEss;\n\tmultiScatter += Fms * Ems;\n}\n#if NUM_RECT_AREA_LIGHTS > 0\n\tvoid RE_Direct_RectArea_Physical( const in RectAreaLight rectAreaLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\t\tvec3 normal = geometry.normal;\n\t\tvec3 viewDir = geometry.viewDir;\n\t\tvec3 position = geometry.position;\n\t\tvec3 lightPos = rectAreaLight.position;\n\t\tvec3 halfWidth = rectAreaLight.halfWidth;\n\t\tvec3 halfHeight = rectAreaLight.halfHeight;\n\t\tvec3 lightColor = rectAreaLight.color;\n\t\tfloat roughness = material.roughness;\n\t\tvec3 rectCoords[ 4 ];\n\t\trectCoords[ 0 ] = lightPos + halfWidth - halfHeight;\t\trectCoords[ 1 ] = lightPos - halfWidth - halfHeight;\n\t\trectCoords[ 2 ] = lightPos - halfWidth + halfHeight;\n\t\trectCoords[ 3 ] = lightPos + halfWidth + halfHeight;\n\t\tvec2 uv = LTC_Uv( normal, viewDir, roughness );\n\t\tvec4 t1 = texture2D( ltc_1, uv );\n\t\tvec4 t2 = texture2D( ltc_2, uv );\n\t\tmat3 mInv = mat3(\n\t\t\tvec3( t1.x, 0, t1.y ),\n\t\t\tvec3( 0, 1, 0 ),\n\t\t\tvec3( t1.z, 0, t1.w )\n\t\t);\n\t\tvec3 fresnel = ( material.specularColor * t2.x + ( vec3( 1.0 ) - material.specularColor ) * t2.y );\n\t\treflectedLight.directSpecular += lightColor * fresnel * LTC_Evaluate( normal, viewDir, position, mInv, rectCoords );\n\t\treflectedLight.directDiffuse += lightColor * material.diffuseColor * LTC_Evaluate( normal, viewDir, position, mat3( 1.0 ), rectCoords );\n\t}\n#endif\nvoid RE_Direct_Physical( const in IncidentLight directLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\tvec3 irradiance = dotNL * directLight.color;\n\t#ifdef USE_CLEARCOAT\n\t\tfloat dotNLcc = saturate( dot( geometry.clearcoatNormal, directLight.direction ) );\n\t\tvec3 ccIrradiance = dotNLcc * directLight.color;\n\t\tclearcoatSpecular += ccIrradiance * BRDF_GGX( directLight.direction, geometry.viewDir, geometry.clearcoatNormal, material.clearcoatF0, material.clearcoatF90, material.clearcoatRoughness );\n\t#endif\n\t#ifdef USE_SHEEN\n\t\treflectedLight.directSpecular += irradiance * BRDF_Sheen( directLight.direction, geometry.viewDir, geometry.normal, material.sheenColor, material.sheenRoughness );\n\t#endif\n\treflectedLight.directSpecular += irradiance * BRDF_GGX( directLight.direction, geometry.viewDir, geometry.normal, material.specularColor, material.specularF90, material.roughness );\n\treflectedLight.directDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectDiffuse_Physical( const in vec3 irradiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectSpecular_Physical( const in vec3 radiance, const in vec3 irradiance, const in vec3 clearcoatRadiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight) {\n\t#ifdef USE_CLEARCOAT\n\t\tclearcoatSpecular += clearcoatRadiance * EnvironmentBRDF( geometry.clearcoatNormal, geometry.viewDir, material.clearcoatF0, material.clearcoatF90, material.clearcoatRoughness );\n\t#endif\n\tvec3 singleScattering = vec3( 0.0 );\n\tvec3 multiScattering = vec3( 0.0 );\n\tvec3 cosineWeightedIrradiance = irradiance * RECIPROCAL_PI;\n\tcomputeMultiscattering( geometry.normal, geometry.viewDir, material.specularColor, material.specularF90, material.roughness, singleScattering, multiScattering );\n\tvec3 diffuse = material.diffuseColor * ( 1.0 - ( singleScattering + multiScattering ) );\n\treflectedLight.indirectSpecular += radiance * singleScattering;\n\treflectedLight.indirectSpecular += multiScattering * cosineWeightedIrradiance;\n\treflectedLight.indirectDiffuse += diffuse * cosineWeightedIrradiance;\n}\n#define RE_Direct\t\t\t\tRE_Direct_Physical\n#define RE_Direct_RectArea\t\tRE_Direct_RectArea_Physical\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_Physical\n#define RE_IndirectSpecular\t\tRE_IndirectSpecular_Physical\nfloat computeSpecularOcclusion( const in float dotNV, const in float ambientOcclusion, const in float roughness ) {\n\treturn saturate( pow( dotNV + ambientOcclusion, exp2( - 16.0 * roughness - 1.0 ) ) - 1.0 + ambientOcclusion );\n}",lights_fragment_begin:"\nGeometricContext geometry;\ngeometry.position = - vViewPosition;\ngeometry.normal = normal;\ngeometry.viewDir = ( isOrthographic ) ? vec3( 0, 0, 1 ) : normalize( vViewPosition );\n#ifdef USE_CLEARCOAT\n\tgeometry.clearcoatNormal = clearcoatNormal;\n#endif\nIncidentLight directLight;\n#if ( NUM_POINT_LIGHTS > 0 ) && defined( RE_Direct )\n\tPointLight pointLight;\n\t#if defined( USE_SHADOWMAP ) && NUM_POINT_LIGHT_SHADOWS > 0\n\tPointLightShadow pointLightShadow;\n\t#endif\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tpointLight = pointLights[ i ];\n\t\tgetPointLightInfo( pointLight, geometry, directLight );\n\t\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_POINT_LIGHT_SHADOWS )\n\t\tpointLightShadow = pointLightShadows[ i ];\n\t\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getPointShadow( pointShadowMap[ i ], pointLightShadow.shadowMapSize, pointLightShadow.shadowBias, pointLightShadow.shadowRadius, vPointShadowCoord[ i ], pointLightShadow.shadowCameraNear, pointLightShadow.shadowCameraFar ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if ( NUM_SPOT_LIGHTS > 0 ) && defined( RE_Direct )\n\tSpotLight spotLight;\n\t#if defined( USE_SHADOWMAP ) && NUM_SPOT_LIGHT_SHADOWS > 0\n\tSpotLightShadow spotLightShadow;\n\t#endif\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tspotLight = spotLights[ i ];\n\t\tgetSpotLightInfo( spotLight, geometry, directLight );\n\t\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_SPOT_LIGHT_SHADOWS )\n\t\tspotLightShadow = spotLightShadows[ i ];\n\t\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getShadow( spotShadowMap[ i ], spotLightShadow.shadowMapSize, spotLightShadow.shadowBias, spotLightShadow.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if ( NUM_DIR_LIGHTS > 0 ) && defined( RE_Direct )\n\tDirectionalLight directionalLight;\n\t#if defined( USE_SHADOWMAP ) && NUM_DIR_LIGHT_SHADOWS > 0\n\tDirectionalLightShadow directionalLightShadow;\n\t#endif\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tdirectionalLight = directionalLights[ i ];\n\t\tgetDirectionalLightInfo( directionalLight, geometry, directLight );\n\t\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_DIR_LIGHT_SHADOWS )\n\t\tdirectionalLightShadow = directionalLightShadows[ i ];\n\t\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getShadow( directionalShadowMap[ i ], directionalLightShadow.shadowMapSize, directionalLightShadow.shadowBias, directionalLightShadow.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if ( NUM_RECT_AREA_LIGHTS > 0 ) && defined( RE_Direct_RectArea )\n\tRectAreaLight rectAreaLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_RECT_AREA_LIGHTS; i ++ ) {\n\t\trectAreaLight = rectAreaLights[ i ];\n\t\tRE_Direct_RectArea( rectAreaLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if defined( RE_IndirectDiffuse )\n\tvec3 iblIrradiance = vec3( 0.0 );\n\tvec3 irradiance = getAmbientLightIrradiance( ambientLightColor );\n\tirradiance += getLightProbeIrradiance( lightProbe, geometry.normal );\n\t#if ( NUM_HEMI_LIGHTS > 0 )\n\t\t#pragma unroll_loop_start\n\t\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\t\tirradiance += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry.normal );\n\t\t}\n\t\t#pragma unroll_loop_end\n\t#endif\n#endif\n#if defined( RE_IndirectSpecular )\n\tvec3 radiance = vec3( 0.0 );\n\tvec3 clearcoatRadiance = vec3( 0.0 );\n#endif",lights_fragment_maps:"#if defined( RE_IndirectDiffuse )\n\t#ifdef USE_LIGHTMAP\n\t\tvec4 lightMapTexel = texture2D( lightMap, vUv2 );\n\t\tvec3 lightMapIrradiance = lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tlightMapIrradiance *= PI;\n\t\t#endif\n\t\tirradiance += lightMapIrradiance;\n\t#endif\n\t#if defined( USE_ENVMAP ) && defined( STANDARD ) && defined( ENVMAP_TYPE_CUBE_UV )\n\t\tiblIrradiance += getIBLIrradiance( geometry.normal );\n\t#endif\n#endif\n#if defined( USE_ENVMAP ) && defined( RE_IndirectSpecular )\n\tradiance += getIBLRadiance( geometry.viewDir, geometry.normal, material.roughness );\n\t#ifdef USE_CLEARCOAT\n\t\tclearcoatRadiance += getIBLRadiance( geometry.viewDir, geometry.clearcoatNormal, material.clearcoatRoughness );\n\t#endif\n#endif",lights_fragment_end:"#if defined( RE_IndirectDiffuse )\n\tRE_IndirectDiffuse( irradiance, geometry, material, reflectedLight );\n#endif\n#if defined( RE_IndirectSpecular )\n\tRE_IndirectSpecular( radiance, iblIrradiance, clearcoatRadiance, geometry, material, reflectedLight );\n#endif",logdepthbuf_fragment:"#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )\n\tgl_FragDepthEXT = vIsPerspective == 0.0 ? gl_FragCoord.z : log2( vFragDepth ) * logDepthBufFC * 0.5;\n#endif",logdepthbuf_pars_fragment:"#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )\n\tuniform float logDepthBufFC;\n\tvarying float vFragDepth;\n\tvarying float vIsPerspective;\n#endif",logdepthbuf_pars_vertex:"#ifdef USE_LOGDEPTHBUF\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvarying float vFragDepth;\n\t\tvarying float vIsPerspective;\n\t#else\n\t\tuniform float logDepthBufFC;\n\t#endif\n#endif",logdepthbuf_vertex:"#ifdef USE_LOGDEPTHBUF\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvFragDepth = 1.0 + gl_Position.w;\n\t\tvIsPerspective = float( isPerspectiveMatrix( projectionMatrix ) );\n\t#else\n\t\tif ( isPerspectiveMatrix( projectionMatrix ) ) {\n\t\t\tgl_Position.z = log2( max( EPSILON, gl_Position.w + 1.0 ) ) * logDepthBufFC - 1.0;\n\t\t\tgl_Position.z *= gl_Position.w;\n\t\t}\n\t#endif\n#endif",map_fragment:"#ifdef USE_MAP\n\tvec4 texelColor = texture2D( map, vUv );\n\ttexelColor = mapTexelToLinear( texelColor );\n\tdiffuseColor *= texelColor;\n#endif",map_pars_fragment:"#ifdef USE_MAP\n\tuniform sampler2D map;\n#endif",map_particle_fragment:"#if defined( USE_MAP ) || defined( USE_ALPHAMAP )\n\tvec2 uv = ( uvTransform * vec3( gl_PointCoord.x, 1.0 - gl_PointCoord.y, 1 ) ).xy;\n#endif\n#ifdef USE_MAP\n\tvec4 mapTexel = texture2D( map, uv );\n\tdiffuseColor *= mapTexelToLinear( mapTexel );\n#endif\n#ifdef USE_ALPHAMAP\n\tdiffuseColor.a *= texture2D( alphaMap, uv ).g;\n#endif",map_particle_pars_fragment:"#if defined( USE_MAP ) || defined( USE_ALPHAMAP )\n\tuniform mat3 uvTransform;\n#endif\n#ifdef USE_MAP\n\tuniform sampler2D map;\n#endif\n#ifdef USE_ALPHAMAP\n\tuniform sampler2D alphaMap;\n#endif",metalnessmap_fragment:"float metalnessFactor = metalness;\n#ifdef USE_METALNESSMAP\n\tvec4 texelMetalness = texture2D( metalnessMap, vUv );\n\tmetalnessFactor *= texelMetalness.b;\n#endif",metalnessmap_pars_fragment:"#ifdef USE_METALNESSMAP\n\tuniform sampler2D metalnessMap;\n#endif",morphnormal_vertex:"#ifdef USE_MORPHNORMALS\n\tobjectNormal *= morphTargetBaseInfluence;\n\t#ifdef MORPHTARGETS_TEXTURE\n\t\tfor ( int i = 0; i < MORPHTARGETS_COUNT; i ++ ) {\n\t\t\tif ( morphTargetInfluences[ i ] > 0.0 ) objectNormal += getMorph( gl_VertexID, i, 1, 2 ) * morphTargetInfluences[ i ];\n\t\t}\n\t#else\n\t\tobjectNormal += morphNormal0 * morphTargetInfluences[ 0 ];\n\t\tobjectNormal += morphNormal1 * morphTargetInfluences[ 1 ];\n\t\tobjectNormal += morphNormal2 * morphTargetInfluences[ 2 ];\n\t\tobjectNormal += morphNormal3 * morphTargetInfluences[ 3 ];\n\t#endif\n#endif",morphtarget_pars_vertex:"#ifdef USE_MORPHTARGETS\n\tuniform float morphTargetBaseInfluence;\n\t#ifdef MORPHTARGETS_TEXTURE\n\t\tuniform float morphTargetInfluences[ MORPHTARGETS_COUNT ];\n\t\tuniform sampler2DArray morphTargetsTexture;\n\t\tuniform vec2 morphTargetsTextureSize;\n\t\tvec3 getMorph( const in int vertexIndex, const in int morphTargetIndex, const in int offset, const in int stride ) {\n\t\t\tfloat texelIndex = float( vertexIndex * stride + offset );\n\t\t\tfloat y = floor( texelIndex / morphTargetsTextureSize.x );\n\t\t\tfloat x = texelIndex - y * morphTargetsTextureSize.x;\n\t\t\tvec3 morphUV = vec3( ( x + 0.5 ) / morphTargetsTextureSize.x, y / morphTargetsTextureSize.y, morphTargetIndex );\n\t\t\treturn texture( morphTargetsTexture, morphUV ).xyz;\n\t\t}\n\t#else\n\t\t#ifndef USE_MORPHNORMALS\n\t\t\tuniform float morphTargetInfluences[ 8 ];\n\t\t#else\n\t\t\tuniform float morphTargetInfluences[ 4 ];\n\t\t#endif\n\t#endif\n#endif",morphtarget_vertex:"#ifdef USE_MORPHTARGETS\n\ttransformed *= morphTargetBaseInfluence;\n\t#ifdef MORPHTARGETS_TEXTURE\n\t\tfor ( int i = 0; i < MORPHTARGETS_COUNT; i ++ ) {\n\t\t\t#ifndef USE_MORPHNORMALS\n\t\t\t\tif ( morphTargetInfluences[ i ] > 0.0 ) transformed += getMorph( gl_VertexID, i, 0, 1 ) * morphTargetInfluences[ i ];\n\t\t\t#else\n\t\t\t\tif ( morphTargetInfluences[ i ] > 0.0 ) transformed += getMorph( gl_VertexID, i, 0, 2 ) * morphTargetInfluences[ i ];\n\t\t\t#endif\n\t\t}\n\t#else\n\t\ttransformed += morphTarget0 * morphTargetInfluences[ 0 ];\n\t\ttransformed += morphTarget1 * morphTargetInfluences[ 1 ];\n\t\ttransformed += morphTarget2 * morphTargetInfluences[ 2 ];\n\t\ttransformed += morphTarget3 * morphTargetInfluences[ 3 ];\n\t\t#ifndef USE_MORPHNORMALS\n\t\t\ttransformed += morphTarget4 * morphTargetInfluences[ 4 ];\n\t\t\ttransformed += morphTarget5 * morphTargetInfluences[ 5 ];\n\t\t\ttransformed += morphTarget6 * morphTargetInfluences[ 6 ];\n\t\t\ttransformed += morphTarget7 * morphTargetInfluences[ 7 ];\n\t\t#endif\n\t#endif\n#endif",normal_fragment_begin:"float faceDirection = gl_FrontFacing ? 1.0 : - 1.0;\n#ifdef FLAT_SHADED\n\tvec3 fdx = vec3( dFdx( vViewPosition.x ), dFdx( vViewPosition.y ), dFdx( vViewPosition.z ) );\n\tvec3 fdy = vec3( dFdy( vViewPosition.x ), dFdy( vViewPosition.y ), dFdy( vViewPosition.z ) );\n\tvec3 normal = normalize( cross( fdx, fdy ) );\n#else\n\tvec3 normal = normalize( vNormal );\n\t#ifdef DOUBLE_SIDED\n\t\tnormal = normal * faceDirection;\n\t#endif\n\t#ifdef USE_TANGENT\n\t\tvec3 tangent = normalize( vTangent );\n\t\tvec3 bitangent = normalize( vBitangent );\n\t\t#ifdef DOUBLE_SIDED\n\t\t\ttangent = tangent * faceDirection;\n\t\t\tbitangent = bitangent * faceDirection;\n\t\t#endif\n\t\t#if defined( TANGENTSPACE_NORMALMAP ) || defined( USE_CLEARCOAT_NORMALMAP )\n\t\t\tmat3 vTBN = mat3( tangent, bitangent, normal );\n\t\t#endif\n\t#endif\n#endif\nvec3 geometryNormal = normal;",normal_fragment_maps:"#ifdef OBJECTSPACE_NORMALMAP\n\tnormal = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\n\t#ifdef FLIP_SIDED\n\t\tnormal = - normal;\n\t#endif\n\t#ifdef DOUBLE_SIDED\n\t\tnormal = normal * faceDirection;\n\t#endif\n\tnormal = normalize( normalMatrix * normal );\n#elif defined( TANGENTSPACE_NORMALMAP )\n\tvec3 mapN = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\n\tmapN.xy *= normalScale;\n\t#ifdef USE_TANGENT\n\t\tnormal = normalize( vTBN * mapN );\n\t#else\n\t\tnormal = perturbNormal2Arb( - vViewPosition, normal, mapN, faceDirection );\n\t#endif\n#elif defined( USE_BUMPMAP )\n\tnormal = perturbNormalArb( - vViewPosition, normal, dHdxy_fwd(), faceDirection );\n#endif",normal_pars_fragment:"#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n\t#ifdef USE_TANGENT\n\t\tvarying vec3 vTangent;\n\t\tvarying vec3 vBitangent;\n\t#endif\n#endif",normal_pars_vertex:"#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n\t#ifdef USE_TANGENT\n\t\tvarying vec3 vTangent;\n\t\tvarying vec3 vBitangent;\n\t#endif\n#endif",normal_vertex:"#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n\t#ifdef USE_TANGENT\n\t\tvTangent = normalize( transformedTangent );\n\t\tvBitangent = normalize( cross( vNormal, vTangent ) * tangent.w );\n\t#endif\n#endif",normalmap_pars_fragment:"#ifdef USE_NORMALMAP\n\tuniform sampler2D normalMap;\n\tuniform vec2 normalScale;\n#endif\n#ifdef OBJECTSPACE_NORMALMAP\n\tuniform mat3 normalMatrix;\n#endif\n#if ! defined ( USE_TANGENT ) && ( defined ( TANGENTSPACE_NORMALMAP ) || defined ( USE_CLEARCOAT_NORMALMAP ) )\n\tvec3 perturbNormal2Arb( vec3 eye_pos, vec3 surf_norm, vec3 mapN, float faceDirection ) {\n\t\tvec3 q0 = vec3( dFdx( eye_pos.x ), dFdx( eye_pos.y ), dFdx( eye_pos.z ) );\n\t\tvec3 q1 = vec3( dFdy( eye_pos.x ), dFdy( eye_pos.y ), dFdy( eye_pos.z ) );\n\t\tvec2 st0 = dFdx( vUv.st );\n\t\tvec2 st1 = dFdy( vUv.st );\n\t\tvec3 N = surf_norm;\n\t\tvec3 q1perp = cross( q1, N );\n\t\tvec3 q0perp = cross( N, q0 );\n\t\tvec3 T = q1perp * st0.x + q0perp * st1.x;\n\t\tvec3 B = q1perp * st0.y + q0perp * st1.y;\n\t\tfloat det = max( dot( T, T ), dot( B, B ) );\n\t\tfloat scale = ( det == 0.0 ) ? 0.0 : faceDirection * inversesqrt( det );\n\t\treturn normalize( T * ( mapN.x * scale ) + B * ( mapN.y * scale ) + N * mapN.z );\n\t}\n#endif",clearcoat_normal_fragment_begin:"#ifdef USE_CLEARCOAT\n\tvec3 clearcoatNormal = geometryNormal;\n#endif",clearcoat_normal_fragment_maps:"#ifdef USE_CLEARCOAT_NORMALMAP\n\tvec3 clearcoatMapN = texture2D( clearcoatNormalMap, vUv ).xyz * 2.0 - 1.0;\n\tclearcoatMapN.xy *= clearcoatNormalScale;\n\t#ifdef USE_TANGENT\n\t\tclearcoatNormal = normalize( vTBN * clearcoatMapN );\n\t#else\n\t\tclearcoatNormal = perturbNormal2Arb( - vViewPosition, clearcoatNormal, clearcoatMapN, faceDirection );\n\t#endif\n#endif",clearcoat_pars_fragment:"#ifdef USE_CLEARCOATMAP\n\tuniform sampler2D clearcoatMap;\n#endif\n#ifdef USE_CLEARCOAT_ROUGHNESSMAP\n\tuniform sampler2D clearcoatRoughnessMap;\n#endif\n#ifdef USE_CLEARCOAT_NORMALMAP\n\tuniform sampler2D clearcoatNormalMap;\n\tuniform vec2 clearcoatNormalScale;\n#endif",output_fragment:"#ifdef OPAQUE\ndiffuseColor.a = 1.0;\n#endif\n#ifdef USE_TRANSMISSION\ndiffuseColor.a *= transmissionAlpha + 0.1;\n#endif\ngl_FragColor = vec4( outgoingLight, diffuseColor.a );",packing:"vec3 packNormalToRGB( const in vec3 normal ) {\n\treturn normalize( normal ) * 0.5 + 0.5;\n}\nvec3 unpackRGBToNormal( const in vec3 rgb ) {\n\treturn 2.0 * rgb.xyz - 1.0;\n}\nconst float PackUpscale = 256. / 255.;const float UnpackDownscale = 255. / 256.;\nconst vec3 PackFactors = vec3( 256. * 256. * 256., 256. * 256., 256. );\nconst vec4 UnpackFactors = UnpackDownscale / vec4( PackFactors, 1. );\nconst float ShiftRight8 = 1. / 256.;\nvec4 packDepthToRGBA( const in float v ) {\n\tvec4 r = vec4( fract( v * PackFactors ), v );\n\tr.yzw -= r.xyz * ShiftRight8;\treturn r * PackUpscale;\n}\nfloat unpackRGBAToDepth( const in vec4 v ) {\n\treturn dot( v, UnpackFactors );\n}\nvec4 pack2HalfToRGBA( vec2 v ) {\n\tvec4 r = vec4( v.x, fract( v.x * 255.0 ), v.y, fract( v.y * 255.0 ) );\n\treturn vec4( r.x - r.y / 255.0, r.y, r.z - r.w / 255.0, r.w );\n}\nvec2 unpackRGBATo2Half( vec4 v ) {\n\treturn vec2( v.x + ( v.y / 255.0 ), v.z + ( v.w / 255.0 ) );\n}\nfloat viewZToOrthographicDepth( const in float viewZ, const in float near, const in float far ) {\n\treturn ( viewZ + near ) / ( near - far );\n}\nfloat orthographicDepthToViewZ( const in float linearClipZ, const in float near, const in float far ) {\n\treturn linearClipZ * ( near - far ) - near;\n}\nfloat viewZToPerspectiveDepth( const in float viewZ, const in float near, const in float far ) {\n\treturn ( ( near + viewZ ) * far ) / ( ( far - near ) * viewZ );\n}\nfloat perspectiveDepthToViewZ( const in float invClipZ, const in float near, const in float far ) {\n\treturn ( near * far ) / ( ( far - near ) * invClipZ - far );\n}",premultiplied_alpha_fragment:"#ifdef PREMULTIPLIED_ALPHA\n\tgl_FragColor.rgb *= gl_FragColor.a;\n#endif",project_vertex:"vec4 mvPosition = vec4( transformed, 1.0 );\n#ifdef USE_INSTANCING\n\tmvPosition = instanceMatrix * mvPosition;\n#endif\nmvPosition = modelViewMatrix * mvPosition;\ngl_Position = projectionMatrix * mvPosition;",dithering_fragment:"#ifdef DITHERING\n\tgl_FragColor.rgb = dithering( gl_FragColor.rgb );\n#endif",dithering_pars_fragment:"#ifdef DITHERING\n\tvec3 dithering( vec3 color ) {\n\t\tfloat grid_position = rand( gl_FragCoord.xy );\n\t\tvec3 dither_shift_RGB = vec3( 0.25 / 255.0, -0.25 / 255.0, 0.25 / 255.0 );\n\t\tdither_shift_RGB = mix( 2.0 * dither_shift_RGB, -2.0 * dither_shift_RGB, grid_position );\n\t\treturn color + dither_shift_RGB;\n\t}\n#endif",roughnessmap_fragment:"float roughnessFactor = roughness;\n#ifdef USE_ROUGHNESSMAP\n\tvec4 texelRoughness = texture2D( roughnessMap, vUv );\n\troughnessFactor *= texelRoughness.g;\n#endif",roughnessmap_pars_fragment:"#ifdef USE_ROUGHNESSMAP\n\tuniform sampler2D roughnessMap;\n#endif",shadowmap_pars_fragment:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\t\tuniform sampler2D directionalShadowMap[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tstruct DirectionalLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform DirectionalLightShadow directionalLightShadows[ NUM_DIR_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\t\tuniform sampler2D spotShadowMap[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tstruct SpotLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform SpotLightShadow spotLightShadows[ NUM_SPOT_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\t\tuniform sampler2D pointShadowMap[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tstruct PointLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t\tfloat shadowCameraNear;\n\t\t\tfloat shadowCameraFar;\n\t\t};\n\t\tuniform PointLightShadow pointLightShadows[ NUM_POINT_LIGHT_SHADOWS ];\n\t#endif\n\tfloat texture2DCompare( sampler2D depths, vec2 uv, float compare ) {\n\t\treturn step( compare, unpackRGBAToDepth( texture2D( depths, uv ) ) );\n\t}\n\tvec2 texture2DDistribution( sampler2D shadow, vec2 uv ) {\n\t\treturn unpackRGBATo2Half( texture2D( shadow, uv ) );\n\t}\n\tfloat VSMShadow (sampler2D shadow, vec2 uv, float compare ){\n\t\tfloat occlusion = 1.0;\n\t\tvec2 distribution = texture2DDistribution( shadow, uv );\n\t\tfloat hard_shadow = step( compare , distribution.x );\n\t\tif (hard_shadow != 1.0 ) {\n\t\t\tfloat distance = compare - distribution.x ;\n\t\t\tfloat variance = max( 0.00000, distribution.y * distribution.y );\n\t\t\tfloat softness_probability = variance / (variance + distance * distance );\t\t\tsoftness_probability = clamp( ( softness_probability - 0.3 ) / ( 0.95 - 0.3 ), 0.0, 1.0 );\t\t\tocclusion = clamp( max( hard_shadow, softness_probability ), 0.0, 1.0 );\n\t\t}\n\t\treturn occlusion;\n\t}\n\tfloat getShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord ) {\n\t\tfloat shadow = 1.0;\n\t\tshadowCoord.xyz /= shadowCoord.w;\n\t\tshadowCoord.z += shadowBias;\n\t\tbvec4 inFrustumVec = bvec4 ( shadowCoord.x >= 0.0, shadowCoord.x <= 1.0, shadowCoord.y >= 0.0, shadowCoord.y <= 1.0 );\n\t\tbool inFrustum = all( inFrustumVec );\n\t\tbvec2 frustumTestVec = bvec2( inFrustum, shadowCoord.z <= 1.0 );\n\t\tbool frustumTest = all( frustumTestVec );\n\t\tif ( frustumTest ) {\n\t\t#if defined( SHADOWMAP_TYPE_PCF )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx0 = - texelSize.x * shadowRadius;\n\t\t\tfloat dy0 = - texelSize.y * shadowRadius;\n\t\t\tfloat dx1 = + texelSize.x * shadowRadius;\n\t\t\tfloat dy1 = + texelSize.y * shadowRadius;\n\t\t\tfloat dx2 = dx0 / 2.0;\n\t\t\tfloat dy2 = dy0 / 2.0;\n\t\t\tfloat dx3 = dx1 / 2.0;\n\t\t\tfloat dy3 = dy1 / 2.0;\n\t\t\tshadow = (\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, dy2 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy2 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, dy2 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, dy3 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy3 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, dy3 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )\n\t\t\t) * ( 1.0 / 17.0 );\n\t\t#elif defined( SHADOWMAP_TYPE_PCF_SOFT )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx = texelSize.x;\n\t\t\tfloat dy = texelSize.y;\n\t\t\tvec2 uv = shadowCoord.xy;\n\t\t\tvec2 f = fract( uv * shadowMapSize + 0.5 );\n\t\t\tuv -= f * texelSize;\n\t\t\tshadow = (\n\t\t\t\ttexture2DCompare( shadowMap, uv, shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, uv + vec2( dx, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, uv + vec2( 0.0, dy ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, uv + texelSize, shadowCoord.z ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( -dx, 0.0 ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, 0.0 ), shadowCoord.z ),\n\t\t\t\t\t f.x ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( -dx, dy ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, dy ), shadowCoord.z ),\n\t\t\t\t\t f.x ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( 0.0, -dy ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 0.0, 2.0 * dy ), shadowCoord.z ),\n\t\t\t\t\t f.y ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( dx, -dy ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( dx, 2.0 * dy ), shadowCoord.z ),\n\t\t\t\t\t f.y ) +\n\t\t\t\tmix( mix( texture2DCompare( shadowMap, uv + vec2( -dx, -dy ), shadowCoord.z ), \n\t\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, -dy ), shadowCoord.z ),\n\t\t\t\t\t\t f.x ),\n\t\t\t\t\t mix( texture2DCompare( shadowMap, uv + vec2( -dx, 2.0 * dy ), shadowCoord.z ), \n\t\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, 2.0 * dy ), shadowCoord.z ),\n\t\t\t\t\t\t f.x ),\n\t\t\t\t\t f.y )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#elif defined( SHADOWMAP_TYPE_VSM )\n\t\t\tshadow = VSMShadow( shadowMap, shadowCoord.xy, shadowCoord.z );\n\t\t#else\n\t\t\tshadow = texture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z );\n\t\t#endif\n\t\t}\n\t\treturn shadow;\n\t}\n\tvec2 cubeToUV( vec3 v, float texelSizeY ) {\n\t\tvec3 absV = abs( v );\n\t\tfloat scaleToCube = 1.0 / max( absV.x, max( absV.y, absV.z ) );\n\t\tabsV *= scaleToCube;\n\t\tv *= scaleToCube * ( 1.0 - 2.0 * texelSizeY );\n\t\tvec2 planar = v.xy;\n\t\tfloat almostATexel = 1.5 * texelSizeY;\n\t\tfloat almostOne = 1.0 - almostATexel;\n\t\tif ( absV.z >= almostOne ) {\n\t\t\tif ( v.z > 0.0 )\n\t\t\t\tplanar.x = 4.0 - v.x;\n\t\t} else if ( absV.x >= almostOne ) {\n\t\t\tfloat signX = sign( v.x );\n\t\t\tplanar.x = v.z * signX + 2.0 * signX;\n\t\t} else if ( absV.y >= almostOne ) {\n\t\t\tfloat signY = sign( v.y );\n\t\t\tplanar.x = v.x + 2.0 * signY + 2.0;\n\t\t\tplanar.y = v.z * signY - 2.0;\n\t\t}\n\t\treturn vec2( 0.125, 0.25 ) * planar + vec2( 0.375, 0.75 );\n\t}\n\tfloat getPointShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord, float shadowCameraNear, float shadowCameraFar ) {\n\t\tvec2 texelSize = vec2( 1.0 ) / ( shadowMapSize * vec2( 4.0, 2.0 ) );\n\t\tvec3 lightToPosition = shadowCoord.xyz;\n\t\tfloat dp = ( length( lightToPosition ) - shadowCameraNear ) / ( shadowCameraFar - shadowCameraNear );\t\tdp += shadowBias;\n\t\tvec3 bd3D = normalize( lightToPosition );\n\t\t#if defined( SHADOWMAP_TYPE_PCF ) || defined( SHADOWMAP_TYPE_PCF_SOFT ) || defined( SHADOWMAP_TYPE_VSM )\n\t\t\tvec2 offset = vec2( - 1, 1 ) * shadowRadius * texelSize.y;\n\t\t\treturn (\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxx, texelSize.y ), dp )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#else\n\t\t\treturn texture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp );\n\t\t#endif\n\t}\n#endif",shadowmap_pars_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\t\tuniform mat4 directionalShadowMatrix[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tstruct DirectionalLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform DirectionalLightShadow directionalLightShadows[ NUM_DIR_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\t\tuniform mat4 spotShadowMatrix[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tstruct SpotLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform SpotLightShadow spotLightShadows[ NUM_SPOT_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\t\tuniform mat4 pointShadowMatrix[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tstruct PointLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t\tfloat shadowCameraNear;\n\t\t\tfloat shadowCameraFar;\n\t\t};\n\t\tuniform PointLightShadow pointLightShadows[ NUM_POINT_LIGHT_SHADOWS ];\n\t#endif\n#endif",shadowmap_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0 || NUM_SPOT_LIGHT_SHADOWS > 0 || NUM_POINT_LIGHT_SHADOWS > 0\n\t\tvec3 shadowWorldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\n\t\tvec4 shadowWorldPosition;\n\t#endif\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {\n\t\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * directionalLightShadows[ i ].shadowNormalBias, 0 );\n\t\tvDirectionalShadowCoord[ i ] = directionalShadowMatrix[ i ] * shadowWorldPosition;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {\n\t\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * spotLightShadows[ i ].shadowNormalBias, 0 );\n\t\tvSpotShadowCoord[ i ] = spotShadowMatrix[ i ] * shadowWorldPosition;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {\n\t\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * pointLightShadows[ i ].shadowNormalBias, 0 );\n\t\tvPointShadowCoord[ i ] = pointShadowMatrix[ i ] * shadowWorldPosition;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n#endif",shadowmask_pars_fragment:"float getShadowMask() {\n\tfloat shadow = 1.0;\n\t#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\tDirectionalLightShadow directionalLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {\n\t\tdirectionalLight = directionalLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\tSpotLightShadow spotLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {\n\t\tspotLight = spotLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\tPointLightShadow pointLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {\n\t\tpointLight = pointLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ], pointLight.shadowCameraNear, pointLight.shadowCameraFar ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#endif\n\treturn shadow;\n}",skinbase_vertex:"#ifdef USE_SKINNING\n\tmat4 boneMatX = getBoneMatrix( skinIndex.x );\n\tmat4 boneMatY = getBoneMatrix( skinIndex.y );\n\tmat4 boneMatZ = getBoneMatrix( skinIndex.z );\n\tmat4 boneMatW = getBoneMatrix( skinIndex.w );\n#endif",skinning_pars_vertex:"#ifdef USE_SKINNING\n\tuniform mat4 bindMatrix;\n\tuniform mat4 bindMatrixInverse;\n\t#ifdef BONE_TEXTURE\n\t\tuniform highp sampler2D boneTexture;\n\t\tuniform int boneTextureSize;\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tfloat j = i * 4.0;\n\t\t\tfloat x = mod( j, float( boneTextureSize ) );\n\t\t\tfloat y = floor( j / float( boneTextureSize ) );\n\t\t\tfloat dx = 1.0 / float( boneTextureSize );\n\t\t\tfloat dy = 1.0 / float( boneTextureSize );\n\t\t\ty = dy * ( y + 0.5 );\n\t\t\tvec4 v1 = texture2D( boneTexture, vec2( dx * ( x + 0.5 ), y ) );\n\t\t\tvec4 v2 = texture2D( boneTexture, vec2( dx * ( x + 1.5 ), y ) );\n\t\t\tvec4 v3 = texture2D( boneTexture, vec2( dx * ( x + 2.5 ), y ) );\n\t\t\tvec4 v4 = texture2D( boneTexture, vec2( dx * ( x + 3.5 ), y ) );\n\t\t\tmat4 bone = mat4( v1, v2, v3, v4 );\n\t\t\treturn bone;\n\t\t}\n\t#else\n\t\tuniform mat4 boneMatrices[ MAX_BONES ];\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tmat4 bone = boneMatrices[ int(i) ];\n\t\t\treturn bone;\n\t\t}\n\t#endif\n#endif",skinning_vertex:"#ifdef USE_SKINNING\n\tvec4 skinVertex = bindMatrix * vec4( transformed, 1.0 );\n\tvec4 skinned = vec4( 0.0 );\n\tskinned += boneMatX * skinVertex * skinWeight.x;\n\tskinned += boneMatY * skinVertex * skinWeight.y;\n\tskinned += boneMatZ * skinVertex * skinWeight.z;\n\tskinned += boneMatW * skinVertex * skinWeight.w;\n\ttransformed = ( bindMatrixInverse * skinned ).xyz;\n#endif",skinnormal_vertex:"#ifdef USE_SKINNING\n\tmat4 skinMatrix = mat4( 0.0 );\n\tskinMatrix += skinWeight.x * boneMatX;\n\tskinMatrix += skinWeight.y * boneMatY;\n\tskinMatrix += skinWeight.z * boneMatZ;\n\tskinMatrix += skinWeight.w * boneMatW;\n\tskinMatrix = bindMatrixInverse * skinMatrix * bindMatrix;\n\tobjectNormal = vec4( skinMatrix * vec4( objectNormal, 0.0 ) ).xyz;\n\t#ifdef USE_TANGENT\n\t\tobjectTangent = vec4( skinMatrix * vec4( objectTangent, 0.0 ) ).xyz;\n\t#endif\n#endif",specularmap_fragment:"float specularStrength;\n#ifdef USE_SPECULARMAP\n\tvec4 texelSpecular = texture2D( specularMap, vUv );\n\tspecularStrength = texelSpecular.r;\n#else\n\tspecularStrength = 1.0;\n#endif",specularmap_pars_fragment:"#ifdef USE_SPECULARMAP\n\tuniform sampler2D specularMap;\n#endif",tonemapping_fragment:"#if defined( TONE_MAPPING )\n\tgl_FragColor.rgb = toneMapping( gl_FragColor.rgb );\n#endif",tonemapping_pars_fragment:"#ifndef saturate\n#define saturate( a ) clamp( a, 0.0, 1.0 )\n#endif\nuniform float toneMappingExposure;\nvec3 LinearToneMapping( vec3 color ) {\n\treturn toneMappingExposure * color;\n}\nvec3 ReinhardToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\treturn saturate( color / ( vec3( 1.0 ) + color ) );\n}\nvec3 OptimizedCineonToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\tcolor = max( vec3( 0.0 ), color - 0.004 );\n\treturn pow( ( color * ( 6.2 * color + 0.5 ) ) / ( color * ( 6.2 * color + 1.7 ) + 0.06 ), vec3( 2.2 ) );\n}\nvec3 RRTAndODTFit( vec3 v ) {\n\tvec3 a = v * ( v + 0.0245786 ) - 0.000090537;\n\tvec3 b = v * ( 0.983729 * v + 0.4329510 ) + 0.238081;\n\treturn a / b;\n}\nvec3 ACESFilmicToneMapping( vec3 color ) {\n\tconst mat3 ACESInputMat = mat3(\n\t\tvec3( 0.59719, 0.07600, 0.02840 ),\t\tvec3( 0.35458, 0.90834, 0.13383 ),\n\t\tvec3( 0.04823, 0.01566, 0.83777 )\n\t);\n\tconst mat3 ACESOutputMat = mat3(\n\t\tvec3( 1.60475, -0.10208, -0.00327 ),\t\tvec3( -0.53108, 1.10813, -0.07276 ),\n\t\tvec3( -0.07367, -0.00605, 1.07602 )\n\t);\n\tcolor *= toneMappingExposure / 0.6;\n\tcolor = ACESInputMat * color;\n\tcolor = RRTAndODTFit( color );\n\tcolor = ACESOutputMat * color;\n\treturn saturate( color );\n}\nvec3 CustomToneMapping( vec3 color ) { return color; }",transmission_fragment:"#ifdef USE_TRANSMISSION\n\tfloat transmissionAlpha = 1.0;\n\tfloat transmissionFactor = transmission;\n\tfloat thicknessFactor = thickness;\n\t#ifdef USE_TRANSMISSIONMAP\n\t\ttransmissionFactor *= texture2D( transmissionMap, vUv ).r;\n\t#endif\n\t#ifdef USE_THICKNESSMAP\n\t\tthicknessFactor *= texture2D( thicknessMap, vUv ).g;\n\t#endif\n\tvec3 pos = vWorldPosition;\n\tvec3 v = normalize( cameraPosition - pos );\n\tvec3 n = inverseTransformDirection( normal, viewMatrix );\n\tvec4 transmission = getIBLVolumeRefraction(\n\t\tn, v, roughnessFactor, material.diffuseColor, material.specularColor, material.specularF90,\n\t\tpos, modelMatrix, viewMatrix, projectionMatrix, ior, thicknessFactor,\n\t\tattenuationColor, attenuationDistance );\n\ttotalDiffuse = mix( totalDiffuse, transmission.rgb, transmissionFactor );\n\ttransmissionAlpha = mix( transmissionAlpha, transmission.a, transmissionFactor );\n#endif",transmission_pars_fragment:"#ifdef USE_TRANSMISSION\n\tuniform float transmission;\n\tuniform float thickness;\n\tuniform float attenuationDistance;\n\tuniform vec3 attenuationColor;\n\t#ifdef USE_TRANSMISSIONMAP\n\t\tuniform sampler2D transmissionMap;\n\t#endif\n\t#ifdef USE_THICKNESSMAP\n\t\tuniform sampler2D thicknessMap;\n\t#endif\n\tuniform vec2 transmissionSamplerSize;\n\tuniform sampler2D transmissionSamplerMap;\n\tuniform mat4 modelMatrix;\n\tuniform mat4 projectionMatrix;\n\tvarying vec3 vWorldPosition;\n\tvec3 getVolumeTransmissionRay( vec3 n, vec3 v, float thickness, float ior, mat4 modelMatrix ) {\n\t\tvec3 refractionVector = refract( - v, normalize( n ), 1.0 / ior );\n\t\tvec3 modelScale;\n\t\tmodelScale.x = length( vec3( modelMatrix[ 0 ].xyz ) );\n\t\tmodelScale.y = length( vec3( modelMatrix[ 1 ].xyz ) );\n\t\tmodelScale.z = length( vec3( modelMatrix[ 2 ].xyz ) );\n\t\treturn normalize( refractionVector ) * thickness * modelScale;\n\t}\n\tfloat applyIorToRoughness( float roughness, float ior ) {\n\t\treturn roughness * clamp( ior * 2.0 - 2.0, 0.0, 1.0 );\n\t}\n\tvec4 getTransmissionSample( vec2 fragCoord, float roughness, float ior ) {\n\t\tfloat framebufferLod = log2( transmissionSamplerSize.x ) * applyIorToRoughness( roughness, ior );\n\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\treturn texture2DLodEXT( transmissionSamplerMap, fragCoord.xy, framebufferLod );\n\t\t#else\n\t\t\treturn texture2D( transmissionSamplerMap, fragCoord.xy, framebufferLod );\n\t\t#endif\n\t}\n\tvec3 applyVolumeAttenuation( vec3 radiance, float transmissionDistance, vec3 attenuationColor, float attenuationDistance ) {\n\t\tif ( attenuationDistance == 0.0 ) {\n\t\t\treturn radiance;\n\t\t} else {\n\t\t\tvec3 attenuationCoefficient = -log( attenuationColor ) / attenuationDistance;\n\t\t\tvec3 transmittance = exp( - attenuationCoefficient * transmissionDistance );\t\t\treturn transmittance * radiance;\n\t\t}\n\t}\n\tvec4 getIBLVolumeRefraction( vec3 n, vec3 v, float roughness, vec3 diffuseColor, vec3 specularColor, float specularF90,\n\t\tvec3 position, mat4 modelMatrix, mat4 viewMatrix, mat4 projMatrix, float ior, float thickness,\n\t\tvec3 attenuationColor, float attenuationDistance ) {\n\t\tvec3 transmissionRay = getVolumeTransmissionRay( n, v, thickness, ior, modelMatrix );\n\t\tvec3 refractedRayExit = position + transmissionRay;\n\t\tvec4 ndcPos = projMatrix * viewMatrix * vec4( refractedRayExit, 1.0 );\n\t\tvec2 refractionCoords = ndcPos.xy / ndcPos.w;\n\t\trefractionCoords += 1.0;\n\t\trefractionCoords /= 2.0;\n\t\tvec4 transmittedLight = getTransmissionSample( refractionCoords, roughness, ior );\n\t\tvec3 attenuatedColor = applyVolumeAttenuation( transmittedLight.rgb, length( transmissionRay ), attenuationColor, attenuationDistance );\n\t\tvec3 F = EnvironmentBRDF( n, v, specularColor, specularF90, roughness );\n\t\treturn vec4( ( 1.0 - F ) * attenuatedColor * diffuseColor, transmittedLight.a );\n\t}\n#endif",uv_pars_fragment:"#if ( defined( USE_UV ) && ! defined( UVS_VERTEX_ONLY ) )\n\tvarying vec2 vUv;\n#endif",uv_pars_vertex:"#ifdef USE_UV\n\t#ifdef UVS_VERTEX_ONLY\n\t\tvec2 vUv;\n\t#else\n\t\tvarying vec2 vUv;\n\t#endif\n\tuniform mat3 uvTransform;\n#endif",uv_vertex:"#ifdef USE_UV\n\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\n#endif",uv2_pars_fragment:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvarying vec2 vUv2;\n#endif",uv2_pars_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tattribute vec2 uv2;\n\tvarying vec2 vUv2;\n\tuniform mat3 uv2Transform;\n#endif",uv2_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvUv2 = ( uv2Transform * vec3( uv2, 1 ) ).xy;\n#endif",worldpos_vertex:"#if defined( USE_ENVMAP ) || defined( DISTANCE ) || defined ( USE_SHADOWMAP ) || defined ( USE_TRANSMISSION )\n\tvec4 worldPosition = vec4( transformed, 1.0 );\n\t#ifdef USE_INSTANCING\n\t\tworldPosition = instanceMatrix * worldPosition;\n\t#endif\n\tworldPosition = modelMatrix * worldPosition;\n#endif",background_vert:"varying vec2 vUv;\nuniform mat3 uvTransform;\nvoid main() {\n\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\n\tgl_Position = vec4( position.xy, 1.0, 1.0 );\n}",background_frag:"uniform sampler2D t2D;\nvarying vec2 vUv;\nvoid main() {\n\tvec4 texColor = texture2D( t2D, vUv );\n\tgl_FragColor = mapTexelToLinear( texColor );\n\t#include \n\t#include \n}",cube_vert:"varying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvWorldDirection = transformDirection( position, modelMatrix );\n\t#include \n\t#include \n\tgl_Position.z = gl_Position.w;\n}",cube_frag:"#include \nuniform float opacity;\nvarying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvec3 vReflect = vWorldDirection;\n\t#include \n\tgl_FragColor = envColor;\n\tgl_FragColor.a *= opacity;\n\t#include \n\t#include \n}",depth_vert:"#include \n#include \n#include \n#include \n#include \n#include \n#include \nvarying vec2 vHighPrecisionZW;\nvoid main() {\n\t#include \n\t#include \n\t#ifdef USE_DISPLACEMENTMAP\n\t\t#include \n\t\t#include \n\t\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvHighPrecisionZW = gl_Position.zw;\n}",depth_frag:"#if DEPTH_PACKING == 3200\n\tuniform float opacity;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvarying vec2 vHighPrecisionZW;\nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( 1.0 );\n\t#if DEPTH_PACKING == 3200\n\t\tdiffuseColor.a = opacity;\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\tfloat fragCoordZ = 0.5 * vHighPrecisionZW[0] / vHighPrecisionZW[1] + 0.5;\n\t#if DEPTH_PACKING == 3200\n\t\tgl_FragColor = vec4( vec3( 1.0 - fragCoordZ ), opacity );\n\t#elif DEPTH_PACKING == 3201\n\t\tgl_FragColor = packDepthToRGBA( fragCoordZ );\n\t#endif\n}",distanceRGBA_vert:"#define DISTANCE\nvarying vec3 vWorldPosition;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#ifdef USE_DISPLACEMENTMAP\n\t\t#include \n\t\t#include \n\t\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvWorldPosition = worldPosition.xyz;\n}",distanceRGBA_frag:"#define DISTANCE\nuniform vec3 referencePosition;\nuniform float nearDistance;\nuniform float farDistance;\nvarying vec3 vWorldPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main () {\n\t#include \n\tvec4 diffuseColor = vec4( 1.0 );\n\t#include \n\t#include \n\t#include \n\tfloat dist = length( vWorldPosition - referencePosition );\n\tdist = ( dist - nearDistance ) / ( farDistance - nearDistance );\n\tdist = saturate( dist );\n\tgl_FragColor = packDepthToRGBA( dist );\n}",equirect_vert:"varying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvWorldDirection = transformDirection( position, modelMatrix );\n\t#include \n\t#include \n}",equirect_frag:"uniform sampler2D tEquirect;\nvarying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvec3 direction = normalize( vWorldDirection );\n\tvec2 sampleUV = equirectUv( direction );\n\tvec4 texColor = texture2D( tEquirect, sampleUV );\n\tgl_FragColor = mapTexelToLinear( texColor );\n\t#include \n\t#include \n}",linedashed_vert:"uniform float scale;\nattribute float lineDistance;\nvarying float vLineDistance;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\tvLineDistance = scale * lineDistance;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",linedashed_frag:"uniform vec3 diffuse;\nuniform float opacity;\nuniform float dashSize;\nuniform float totalSize;\nvarying float vLineDistance;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tif ( mod( vLineDistance, totalSize ) > dashSize ) {\n\t\tdiscard;\n\t}\n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshbasic_vert:"#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#if defined ( USE_ENVMAP ) || defined ( USE_SKINNING )\n\t\t#include \n\t\t#include \n\t\t#include \n\t\t#include \n\t\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshbasic_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\t#ifdef USE_LIGHTMAP\n\t\tvec4 lightMapTexel= texture2D( lightMap, vUv2 );\n\t\treflectedLight.indirectDiffuse += lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\n\t#else\n\t\treflectedLight.indirectDiffuse += vec3( 1.0 );\n\t#endif\n\t#include \n\treflectedLight.indirectDiffuse *= diffuseColor.rgb;\n\tvec3 outgoingLight = reflectedLight.indirectDiffuse;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshlambert_vert:"#define LAMBERT\nvarying vec3 vLightFront;\nvarying vec3 vIndirectFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n\tvarying vec3 vIndirectBack;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshlambert_frag:"uniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float opacity;\nvarying vec3 vLightFront;\nvarying vec3 vIndirectFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n\tvarying vec3 vIndirectBack;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#ifdef DOUBLE_SIDED\n\t\treflectedLight.indirectDiffuse += ( gl_FrontFacing ) ? vIndirectFront : vIndirectBack;\n\t#else\n\t\treflectedLight.indirectDiffuse += vIndirectFront;\n\t#endif\n\t#include \n\treflectedLight.indirectDiffuse *= BRDF_Lambert( diffuseColor.rgb );\n\t#ifdef DOUBLE_SIDED\n\t\treflectedLight.directDiffuse = ( gl_FrontFacing ) ? vLightFront : vLightBack;\n\t#else\n\t\treflectedLight.directDiffuse = vLightFront;\n\t#endif\n\treflectedLight.directDiffuse *= BRDF_Lambert( diffuseColor.rgb ) * getShadowMask();\n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshmatcap_vert:"#define MATCAP\nvarying vec3 vViewPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n}",meshmatcap_frag:"#define MATCAP\nuniform vec3 diffuse;\nuniform float opacity;\nuniform sampler2D matcap;\nvarying vec3 vViewPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 viewDir = normalize( vViewPosition );\n\tvec3 x = normalize( vec3( viewDir.z, 0.0, - viewDir.x ) );\n\tvec3 y = cross( viewDir, x );\n\tvec2 uv = vec2( dot( x, normal ), dot( y, normal ) ) * 0.495 + 0.5;\n\t#ifdef USE_MATCAP\n\t\tvec4 matcapColor = texture2D( matcap, uv );\n\t\tmatcapColor = matcapTexelToLinear( matcapColor );\n\t#else\n\t\tvec4 matcapColor = vec4( 1.0 );\n\t#endif\n\tvec3 outgoingLight = diffuseColor.rgb * matcapColor.rgb;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshnormal_vert:"#define NORMAL\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\n\tvViewPosition = - mvPosition.xyz;\n#endif\n}",meshnormal_frag:"#define NORMAL\nuniform float opacity;\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\tgl_FragColor = vec4( packNormalToRGB( normal ), opacity );\n}",meshphong_vert:"#define PHONG\nvarying vec3 vViewPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n\t#include \n}",meshphong_frag:"#define PHONG\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform vec3 specular;\nuniform float shininess;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshphysical_vert:"#define STANDARD\nvarying vec3 vViewPosition;\n#ifdef USE_TRANSMISSION\n\tvarying vec3 vWorldPosition;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n#ifdef USE_TRANSMISSION\n\tvWorldPosition = worldPosition.xyz;\n#endif\n}",meshphysical_frag:"#define STANDARD\n#ifdef PHYSICAL\n\t#define IOR\n\t#define SPECULAR\n#endif\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float roughness;\nuniform float metalness;\nuniform float opacity;\n#ifdef IOR\n\tuniform float ior;\n#endif\n#ifdef SPECULAR\n\tuniform float specularIntensity;\n\tuniform vec3 specularColor;\n\t#ifdef USE_SPECULARINTENSITYMAP\n\t\tuniform sampler2D specularIntensityMap;\n\t#endif\n\t#ifdef USE_SPECULARCOLORMAP\n\t\tuniform sampler2D specularColorMap;\n\t#endif\n#endif\n#ifdef USE_CLEARCOAT\n\tuniform float clearcoat;\n\tuniform float clearcoatRoughness;\n#endif\n#ifdef USE_SHEEN\n\tuniform vec3 sheenColor;\n\tuniform float sheenRoughness;\n\t#ifdef USE_SHEENCOLORMAP\n\t\tuniform sampler2D sheenColorMap;\n\t#endif\n\t#ifdef USE_SHEENROUGHNESSMAP\n\t\tuniform sampler2D sheenRoughnessMap;\n\t#endif\n#endif\nvarying vec3 vViewPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 totalDiffuse = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse;\n\tvec3 totalSpecular = reflectedLight.directSpecular + reflectedLight.indirectSpecular;\n\t#include \n\tvec3 outgoingLight = totalDiffuse + totalSpecular + totalEmissiveRadiance;\n\t#ifdef USE_CLEARCOAT\n\t\tfloat dotNVcc = saturate( dot( geometry.clearcoatNormal, geometry.viewDir ) );\n\t\tvec3 Fcc = F_Schlick( material.clearcoatF0, material.clearcoatF90, dotNVcc );\n\t\toutgoingLight = outgoingLight * ( 1.0 - material.clearcoat * Fcc ) + clearcoatSpecular * material.clearcoat;\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshtoon_vert:"#define TOON\nvarying vec3 vViewPosition;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n}",meshtoon_frag:"#define TOON\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",points_vert:"uniform float size;\nuniform float scale;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\tgl_PointSize = size;\n\t#ifdef USE_SIZEATTENUATION\n\t\tbool isPerspective = isPerspectiveMatrix( projectionMatrix );\n\t\tif ( isPerspective ) gl_PointSize *= ( scale / - mvPosition.z );\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n}",points_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",shadow_vert:"#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",shadow_frag:"uniform vec3 color;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\tgl_FragColor = vec4( color, opacity * ( 1.0 - getShadowMask() ) );\n\t#include \n\t#include \n\t#include \n}",sprite_vert:"uniform float rotation;\nuniform vec2 center;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 mvPosition = modelViewMatrix * vec4( 0.0, 0.0, 0.0, 1.0 );\n\tvec2 scale;\n\tscale.x = length( vec3( modelMatrix[ 0 ].x, modelMatrix[ 0 ].y, modelMatrix[ 0 ].z ) );\n\tscale.y = length( vec3( modelMatrix[ 1 ].x, modelMatrix[ 1 ].y, modelMatrix[ 1 ].z ) );\n\t#ifndef USE_SIZEATTENUATION\n\t\tbool isPerspective = isPerspectiveMatrix( projectionMatrix );\n\t\tif ( isPerspective ) scale *= - mvPosition.z;\n\t#endif\n\tvec2 alignedPosition = ( position.xy - ( center - vec2( 0.5 ) ) ) * scale;\n\tvec2 rotatedPosition;\n\trotatedPosition.x = cos( rotation ) * alignedPosition.x - sin( rotation ) * alignedPosition.y;\n\trotatedPosition.y = sin( rotation ) * alignedPosition.x + cos( rotation ) * alignedPosition.y;\n\tmvPosition.xy += rotatedPosition;\n\tgl_Position = projectionMatrix * mvPosition;\n\t#include \n\t#include \n\t#include \n}",sprite_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\t#include \n\t#include \n\t#include \n\t#include \n}"},Ct={common:{diffuse:{value:new Rt(16777215)},opacity:{value:1},map:{value:null},uvTransform:{value:new js},uv2Transform:{value:new js},alphaMap:{value:null},alphaTest:{value:0}},specularmap:{specularMap:{value:null}},envmap:{envMap:{value:null},flipEnvMap:{value:-1},reflectivity:{value:1},ior:{value:1.5},refractionRatio:{value:.98}},aomap:{aoMap:{value:null},aoMapIntensity:{value:1}},lightmap:{lightMap:{value:null},lightMapIntensity:{value:1}},emissivemap:{emissiveMap:{value:null}},bumpmap:{bumpMap:{value:null},bumpScale:{value:1}},normalmap:{normalMap:{value:null},normalScale:{value:new tt(1,1)}},displacementmap:{displacementMap:{value:null},displacementScale:{value:1},displacementBias:{value:0}},roughnessmap:{roughnessMap:{value:null}},metalnessmap:{metalnessMap:{value:null}},gradientmap:{gradientMap:{value:null}},fog:{fogDensity:{value:25e-5},fogNear:{value:1},fogFar:{value:2e3},fogColor:{value:new Rt(16777215)}},lights:{ambientLightColor:{value:[]},lightProbe:{value:[]},directionalLights:{value:[],properties:{direction:{},color:{}}},directionalLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{}}},directionalShadowMap:{value:[]},directionalShadowMatrix:{value:[]},spotLights:{value:[],properties:{color:{},position:{},direction:{},distance:{},coneCos:{},penumbraCos:{},decay:{}}},spotLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{}}},spotShadowMap:{value:[]},spotShadowMatrix:{value:[]},pointLights:{value:[],properties:{color:{},position:{},decay:{},distance:{}}},pointLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{},shadowCameraNear:{},shadowCameraFar:{}}},pointShadowMap:{value:[]},pointShadowMatrix:{value:[]},hemisphereLights:{value:[],properties:{direction:{},skyColor:{},groundColor:{}}},rectAreaLights:{value:[],properties:{color:{},position:{},width:{},height:{}}},ltc_1:{value:null},ltc_2:{value:null}},points:{diffuse:{value:new Rt(16777215)},opacity:{value:1},size:{value:1},scale:{value:1},map:{value:null},alphaMap:{value:null},alphaTest:{value:0},uvTransform:{value:new js}},sprite:{diffuse:{value:new Rt(16777215)},opacity:{value:1},center:{value:new tt(.5,.5)},rotation:{value:0},map:{value:null},alphaMap:{value:null},alphaTest:{value:0},uvTransform:{value:new js}}},ed={basic:{uniforms:jo([Ct.common,Ct.specularmap,Ct.envmap,Ct.aomap,Ct.lightmap,Ct.fog]),vertexShader:pi.meshbasic_vert,fragmentShader:pi.meshbasic_frag},lambert:{uniforms:jo([Ct.common,Ct.specularmap,Ct.envmap,Ct.aomap,Ct.lightmap,Ct.emissivemap,Ct.fog,Ct.lights,{emissive:{value:new Rt(0)}}]),vertexShader:pi.meshlambert_vert,fragmentShader:pi.meshlambert_frag},phong:{uniforms:jo([Ct.common,Ct.specularmap,Ct.envmap,Ct.aomap,Ct.lightmap,Ct.emissivemap,Ct.bumpmap,Ct.normalmap,Ct.displacementmap,Ct.fog,Ct.lights,{emissive:{value:new Rt(0)},specular:{value:new Rt(1118481)},shininess:{value:30}}]),vertexShader:pi.meshphong_vert,fragmentShader:pi.meshphong_frag},standard:{uniforms:jo([Ct.common,Ct.envmap,Ct.aomap,Ct.lightmap,Ct.emissivemap,Ct.bumpmap,Ct.normalmap,Ct.displacementmap,Ct.roughnessmap,Ct.metalnessmap,Ct.fog,Ct.lights,{emissive:{value:new Rt(0)},roughness:{value:1},metalness:{value:0},envMapIntensity:{value:1}}]),vertexShader:pi.meshphysical_vert,fragmentShader:pi.meshphysical_frag},toon:{uniforms:jo([Ct.common,Ct.aomap,Ct.lightmap,Ct.emissivemap,Ct.bumpmap,Ct.normalmap,Ct.displacementmap,Ct.gradientmap,Ct.fog,Ct.lights,{emissive:{value:new Rt(0)}}]),vertexShader:pi.meshtoon_vert,fragmentShader:pi.meshtoon_frag},matcap:{uniforms:jo([Ct.common,Ct.bumpmap,Ct.normalmap,Ct.displacementmap,Ct.fog,{matcap:{value:null}}]),vertexShader:pi.meshmatcap_vert,fragmentShader:pi.meshmatcap_frag},points:{uniforms:jo([Ct.points,Ct.fog]),vertexShader:pi.points_vert,fragmentShader:pi.points_frag},dashed:{uniforms:jo([Ct.common,Ct.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:pi.linedashed_vert,fragmentShader:pi.linedashed_frag},depth:{uniforms:jo([Ct.common,Ct.displacementmap]),vertexShader:pi.depth_vert,fragmentShader:pi.depth_frag},normal:{uniforms:jo([Ct.common,Ct.bumpmap,Ct.normalmap,Ct.displacementmap,{opacity:{value:1}}]),vertexShader:pi.meshnormal_vert,fragmentShader:pi.meshnormal_frag},sprite:{uniforms:jo([Ct.sprite,Ct.fog]),vertexShader:pi.sprite_vert,fragmentShader:pi.sprite_frag},background:{uniforms:{uvTransform:{value:new js},t2D:{value:null}},vertexShader:pi.background_vert,fragmentShader:pi.background_frag},cube:{uniforms:jo([Ct.envmap,{opacity:{value:1}}]),vertexShader:pi.cube_vert,fragmentShader:pi.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:pi.equirect_vert,fragmentShader:pi.equirect_frag},distanceRGBA:{uniforms:jo([Ct.common,Ct.displacementmap,{referencePosition:{value:new ne},nearDistance:{value:1},farDistance:{value:1e3}}]),vertexShader:pi.distanceRGBA_vert,fragmentShader:pi.distanceRGBA_frag},shadow:{uniforms:jo([Ct.lights,Ct.fog,{color:{value:new Rt(0)},opacity:{value:1}}]),vertexShader:pi.shadow_vert,fragmentShader:pi.shadow_frag}};function xae(n,e,t,i,r){const s=new Rt(0);let a,c,o=0,u=null,p=0,g=null;function y(x,T){t.buffers.color.setClear(x.r,x.g,x.b,T,r)}return{getClearColor:function(){return s},setClearColor:function(x,T=1){s.set(x),o=T,y(s,o)},getClearAlpha:function(){return o},setClearAlpha:function(x){o=x,y(s,o)},render:function v(x,T){let N=!1,k=!0===T.isScene?T.background:null;k&&k.isTexture&&(k=e.get(k));const A=n.xr,H=A.getSession&&A.getSession();H&&"additive"===H.environmentBlendMode&&(k=null),null===k?y(s,o):k&&k.isColor&&(y(k,1),N=!0),(n.autoClear||N)&&n.clear(n.autoClearColor,n.autoClearDepth,n.autoClearStencil),k&&(k.isCubeTexture||k.mapping===ky)?(void 0===c&&(c=new vr(new tu(1,1,1),new wh({name:"BackgroundCubeMaterial",uniforms:a0(ed.cube.uniforms),vertexShader:ed.cube.vertexShader,fragmentShader:ed.cube.fragmentShader,side:Ds,depthTest:!1,depthWrite:!1,fog:!1})),c.geometry.deleteAttribute("normal"),c.geometry.deleteAttribute("uv"),c.onBeforeRender=function(G,X,se){this.matrixWorld.copyPosition(se.matrixWorld)},Object.defineProperty(c.material,"envMap",{get:function(){return this.uniforms.envMap.value}}),i.update(c)),c.material.uniforms.envMap.value=k,c.material.uniforms.flipEnvMap.value=k.isCubeTexture&&!1===k.isRenderTargetTexture?-1:1,(u!==k||p!==k.version||g!==n.toneMapping)&&(c.material.needsUpdate=!0,u=k,p=k.version,g=n.toneMapping),x.unshift(c,c.geometry,c.material,0,0,null)):k&&k.isTexture&&(void 0===a&&(a=new vr(new Uy(2,2),new wh({name:"BackgroundMaterial",uniforms:a0(ed.background.uniforms),vertexShader:ed.background.vertexShader,fragmentShader:ed.background.fragmentShader,side:Og,depthTest:!1,depthWrite:!1,fog:!1})),a.geometry.deleteAttribute("normal"),Object.defineProperty(a.material,"map",{get:function(){return this.uniforms.t2D.value}}),i.update(a)),a.material.uniforms.t2D.value=k,!0===k.matrixAutoUpdate&&k.updateMatrix(),a.material.uniforms.uvTransform.value.copy(k.matrix),(u!==k||p!==k.version||g!==n.toneMapping)&&(a.material.needsUpdate=!0,u=k,p=k.version,g=n.toneMapping),x.unshift(a,a.geometry,a.material,0,0,null))}}}function wae(n,e,t,i){const r=n.getParameter(34921),s=i.isWebGL2?null:e.get("OES_vertex_array_object"),o=i.isWebGL2||null!==s,a={},c=T(null);let u=c;function v(Pe){return i.isWebGL2?n.bindVertexArray(Pe):s.bindVertexArrayOES(Pe)}function y(Pe){return i.isWebGL2?n.deleteVertexArray(Pe):s.deleteVertexArrayOES(Pe)}function T(Pe){const Oe=[],Ve=[],ye=[];for(let Me=0;Me=0){let vt=Me[ze];if(void 0===vt&&("instanceMatrix"===ze&&Pe.instanceMatrix&&(vt=Pe.instanceMatrix),"instanceColor"===ze&&Pe.instanceColor&&(vt=Pe.instanceColor)),void 0!==vt){const yt=vt.normalized,gt=vt.itemSize,mi=t.get(vt);if(void 0===mi)continue;const ct=mi.buffer,Qt=mi.type,sn=mi.bytesPerElement;if(vt.isInterleavedBufferAttribute){const It=vt.data,on=It.stride,gi=vt.offset;if(It&&It.isInstancedInterleavedBuffer){for(let Xe=0;Xe0&&n.getShaderPrecisionFormat(35632,36338).precision>0)return"highp";K="mediump"}return"mediump"===K&&n.getShaderPrecisionFormat(35633,36337).precision>0&&n.getShaderPrecisionFormat(35632,36337).precision>0?"mediump":"lowp"}const o=typeof WebGL2RenderingContext<"u"&&n instanceof WebGL2RenderingContext||typeof WebGL2ComputeRenderingContext<"u"&&n instanceof WebGL2ComputeRenderingContext;let a=void 0!==t.precision?t.precision:"highp";const c=s(a);c!==a&&(console.warn("THREE.WebGLRenderer:",a,"not supported, using",c,"instead."),a=c);const u=o||e.has("WEBGL_draw_buffers"),p=!0===t.logarithmicDepthBuffer,g=n.getParameter(34930),v=n.getParameter(35660),y=n.getParameter(3379),x=n.getParameter(34076),T=n.getParameter(34921),N=n.getParameter(36347),k=n.getParameter(36348),A=n.getParameter(36349),H=v>0,G=o||e.has("OES_texture_float");return{isWebGL2:o,drawBuffers:u,getMaxAnisotropy:function r(){if(void 0!==i)return i;if(!0===e.has("EXT_texture_filter_anisotropic")){const K=e.get("EXT_texture_filter_anisotropic");i=n.getParameter(K.MAX_TEXTURE_MAX_ANISOTROPY_EXT)}else i=0;return i},getMaxPrecision:s,precision:a,logarithmicDepthBuffer:p,maxTextures:g,maxVertexTextures:v,maxTextureSize:y,maxCubemapSize:x,maxAttributes:T,maxVertexUniforms:N,maxVaryings:k,maxFragmentUniforms:A,vertexTextures:H,floatFragmentTextures:G,floatVertexTextures:H&&G,maxSamples:o?n.getParameter(36183):0}}function Mae(n){const e=this;let t=null,i=0,r=!1,s=!1;const o=new nu,a=new js,c={value:null,needsUpdate:!1};function u(){c.value!==t&&(c.value=t,c.needsUpdate=i>0),e.numPlanes=i,e.numIntersection=0}function p(g,v,y,x){const T=null!==g?g.length:0;let N=null;if(0!==T){if(N=c.value,!0!==x||null===N){const k=y+4*T,A=v.matrixWorldInverse;a.getNormalMatrix(A),(null===N||N.length0){const u=n.getRenderTarget(),p=new rI(c.height/2);return p.fromEquirectangularTexture(n,o),e.set(o,p),n.setRenderTarget(u),o.addEventListener("dispose",r),t(p.texture,o.mapping)}return null}}}return o},dispose:function s(){e=new WeakMap}}}ed.physical={uniforms:jo([ed.standard.uniforms,{clearcoat:{value:0},clearcoatMap:{value:null},clearcoatRoughness:{value:0},clearcoatRoughnessMap:{value:null},clearcoatNormalScale:{value:new tt(1,1)},clearcoatNormalMap:{value:null},sheen:{value:0},sheenColor:{value:new Rt(0)},sheenColorMap:{value:null},sheenRoughness:{value:0},sheenRoughnessMap:{value:null},transmission:{value:0},transmissionMap:{value:null},transmissionSamplerSize:{value:new tt},transmissionSamplerMap:{value:null},thickness:{value:0},thicknessMap:{value:null},attenuationDistance:{value:0},attenuationColor:{value:new Rt(0)},specularIntensity:{value:0},specularIntensityMap:{value:null},specularColor:{value:new Rt(1,1,1)},specularColorMap:{value:null}}]),vertexShader:pi.meshphysical_vert,fragmentShader:pi.meshphysical_frag};class S2 extends b2{constructor(e=-1,t=1,i=1,r=-1,s=.1,o=2e3){super(),this.type="OrthographicCamera",this.zoom=1,this.view=null,this.left=e,this.right=t,this.top=i,this.bottom=r,this.near=s,this.far=o,this.updateProjectionMatrix()}copy(e,t){return super.copy(e,t),this.left=e.left,this.right=e.right,this.top=e.top,this.bottom=e.bottom,this.near=e.near,this.far=e.far,this.zoom=e.zoom,this.view=null===e.view?null:Object.assign({},e.view),this}setViewOffset(e,t,i,r,s,o){null===this.view&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=e,this.view.fullHeight=t,this.view.offsetX=i,this.view.offsetY=r,this.view.width=s,this.view.height=o,this.updateProjectionMatrix()}clearViewOffset(){null!==this.view&&(this.view.enabled=!1),this.updateProjectionMatrix()}updateProjectionMatrix(){const e=(this.right-this.left)/(2*this.zoom),t=(this.top-this.bottom)/(2*this.zoom),i=(this.right+this.left)/2,r=(this.top+this.bottom)/2;let s=i-e,o=i+e,a=r+t,c=r-t;if(null!==this.view&&this.view.enabled){const u=(this.right-this.left)/this.view.fullWidth/this.zoom,p=(this.top-this.bottom)/this.view.fullHeight/this.zoom;s+=u*this.view.offsetX,o=s+u*this.view.width,a-=p*this.view.offsetY,c=a-p*this.view.height}this.projectionMatrix.makeOrthographic(s,o,a,c,this.near,this.far),this.projectionMatrixInverse.copy(this.projectionMatrix).invert()}toJSON(e){const t=super.toJSON(e);return t.object.zoom=this.zoom,t.object.left=this.left,t.object.right=this.right,t.object.top=this.top,t.object.bottom=this.bottom,t.object.near=this.near,t.object.far=this.far,null!==this.view&&(t.object.view=Object.assign({},this.view)),t}}S2.prototype.isOrthographicCamera=!0;class zy extends wh{constructor(e){super(e),this.type="RawShaderMaterial"}}zy.prototype.isRawShaderMaterial=!0;const u0=4,Sh=8,td=Math.pow(2,Sh),kB=[.125,.215,.35,.446,.526,.582],IB=Sh-u0+1+kB.length,cp={[Ma]:0,[e2]:1,[Tk]:2,[cB]:3,[lB]:4,[dB]:5,[Dk]:6},oI=new S2,{_lodPlanes:Gy,_sizeLods:FB,_sigmas:E2}=Aae(),RB=new Rt;let aI=null;const lp=(1+Math.sqrt(5))/2,f0=1/lp,PB=[new ne(1,1,1),new ne(-1,1,1),new ne(1,1,-1),new ne(-1,1,-1),new ne(0,lp,f0),new ne(0,lp,-f0),new ne(f0,0,lp),new ne(-f0,0,lp),new ne(lp,f0,0),new ne(-lp,f0,0)];class Dae{constructor(e){this._renderer=e,this._pingPongRenderTarget=null,this._blurMaterial=function kae(n){const e=new Float32Array(n),t=new ne(0,1,0);return new zy({name:"SphericalGaussianBlur",defines:{n},uniforms:{envMap:{value:null},samples:{value:1},weights:{value:e},latitudinal:{value:!1},dTheta:{value:0},mipInt:{value:0},poleAxis:{value:t},inputEncoding:{value:cp[Ma]},outputEncoding:{value:cp[Ma]}},vertexShader:"\n\n\t\tprecision mediump float;\n\t\tprecision mediump int;\n\n\t\tattribute vec3 position;\n\t\tattribute vec2 uv;\n\t\tattribute float faceIndex;\n\n\t\tvarying vec3 vOutputDirection;\n\n\t\t// RH coordinate system; PMREM face-indexing convention\n\t\tvec3 getDirection( vec2 uv, float face ) {\n\n\t\t\tuv = 2.0 * uv - 1.0;\n\n\t\t\tvec3 direction = vec3( uv, 1.0 );\n\n\t\t\tif ( face == 0.0 ) {\n\n\t\t\t\tdirection = direction.zyx; // ( 1, v, u ) pos x\n\n\t\t\t} else if ( face == 1.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xz *= -1.0; // ( -u, 1, -v ) pos y\n\n\t\t\t} else if ( face == 2.0 ) {\n\n\t\t\t\tdirection.x *= -1.0; // ( -u, v, 1 ) pos z\n\n\t\t\t} else if ( face == 3.0 ) {\n\n\t\t\t\tdirection = direction.zyx;\n\t\t\t\tdirection.xz *= -1.0; // ( -1, v, -u ) neg x\n\n\t\t\t} else if ( face == 4.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xy *= -1.0; // ( -u, -1, v ) neg y\n\n\t\t\t} else if ( face == 5.0 ) {\n\n\t\t\t\tdirection.z *= -1.0; // ( u, v, -1 ) neg z\n\n\t\t\t}\n\n\t\t\treturn direction;\n\n\t\t}\n\n\t\tvoid main() {\n\n\t\t\tvOutputDirection = getDirection( uv, faceIndex );\n\t\t\tgl_Position = vec4( position, 1.0 );\n\n\t\t}\n\t",fragmentShader:"\n\n\t\t\tprecision mediump float;\n\t\t\tprecision mediump int;\n\n\t\t\tvarying vec3 vOutputDirection;\n\n\t\t\tuniform sampler2D envMap;\n\t\t\tuniform int samples;\n\t\t\tuniform float weights[ n ];\n\t\t\tuniform bool latitudinal;\n\t\t\tuniform float dTheta;\n\t\t\tuniform float mipInt;\n\t\t\tuniform vec3 poleAxis;\n\n\t\t\t\n\n\t\tuniform int inputEncoding;\n\t\tuniform int outputEncoding;\n\n\t\t#include \n\n\t\tvec4 inputTexelToLinear( vec4 value ) {\n\n\t\t\tif ( inputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( inputEncoding == 1 ) {\n\n\t\t\t\treturn sRGBToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 2 ) {\n\n\t\t\t\treturn RGBEToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 3 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 7.0 );\n\n\t\t\t} else if ( inputEncoding == 4 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 16.0 );\n\n\t\t\t} else if ( inputEncoding == 5 ) {\n\n\t\t\t\treturn RGBDToLinear( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn GammaToLinear( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 linearToOutputTexel( vec4 value ) {\n\n\t\t\tif ( outputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( outputEncoding == 1 ) {\n\n\t\t\t\treturn LinearTosRGB( value );\n\n\t\t\t} else if ( outputEncoding == 2 ) {\n\n\t\t\t\treturn LinearToRGBE( value );\n\n\t\t\t} else if ( outputEncoding == 3 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 7.0 );\n\n\t\t\t} else if ( outputEncoding == 4 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 16.0 );\n\n\t\t\t} else if ( outputEncoding == 5 ) {\n\n\t\t\t\treturn LinearToRGBD( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn LinearToGamma( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 envMapTexelToLinear( vec4 color ) {\n\n\t\t\treturn inputTexelToLinear( color );\n\n\t\t}\n\t\n\n\t\t\t#define ENVMAP_TYPE_CUBE_UV\n\t\t\t#include \n\n\t\t\tvec3 getSample( float theta, vec3 axis ) {\n\n\t\t\t\tfloat cosTheta = cos( theta );\n\t\t\t\t// Rodrigues' axis-angle rotation\n\t\t\t\tvec3 sampleDirection = vOutputDirection * cosTheta\n\t\t\t\t\t+ cross( axis, vOutputDirection ) * sin( theta )\n\t\t\t\t\t+ axis * dot( axis, vOutputDirection ) * ( 1.0 - cosTheta );\n\n\t\t\t\treturn bilinearCubeUV( envMap, sampleDirection, mipInt );\n\n\t\t\t}\n\n\t\t\tvoid main() {\n\n\t\t\t\tvec3 axis = latitudinal ? poleAxis : cross( poleAxis, vOutputDirection );\n\n\t\t\t\tif ( all( equal( axis, vec3( 0.0 ) ) ) ) {\n\n\t\t\t\t\taxis = vec3( vOutputDirection.z, 0.0, - vOutputDirection.x );\n\n\t\t\t\t}\n\n\t\t\t\taxis = normalize( axis );\n\n\t\t\t\tgl_FragColor = vec4( 0.0, 0.0, 0.0, 1.0 );\n\t\t\t\tgl_FragColor.rgb += weights[ 0 ] * getSample( 0.0, axis );\n\n\t\t\t\tfor ( int i = 1; i < n; i++ ) {\n\n\t\t\t\t\tif ( i >= samples ) {\n\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t}\n\n\t\t\t\t\tfloat theta = dTheta * float( i );\n\t\t\t\t\tgl_FragColor.rgb += weights[ i ] * getSample( -1.0 * theta, axis );\n\t\t\t\t\tgl_FragColor.rgb += weights[ i ] * getSample( theta, axis );\n\n\t\t\t\t}\n\n\t\t\t\tgl_FragColor = linearToOutputTexel( gl_FragColor );\n\n\t\t\t}\n\t\t",blending:hh,depthTest:!1,depthWrite:!1})}(20),this._equirectShader=null,this._cubemapShader=null,this._compileMaterial(this._blurMaterial)}fromScene(e,t=0,i=.1,r=100){aI=this._renderer.getRenderTarget();const s=this._allocateTargets();return this._sceneToCubeUV(e,i,r,s),t>0&&this._blur(s,0,0,t),this._applyPMREM(s),this._cleanup(s),s}fromEquirectangular(e){return this._fromTexture(e)}fromCubemap(e){return this._fromTexture(e)}compileCubemapShader(){null===this._cubemapShader&&(this._cubemapShader=NB(),this._compileMaterial(this._cubemapShader))}compileEquirectangularShader(){null===this._equirectShader&&(this._equirectShader=LB(),this._compileMaterial(this._equirectShader))}dispose(){this._blurMaterial.dispose(),null!==this._cubemapShader&&this._cubemapShader.dispose(),null!==this._equirectShader&&this._equirectShader.dispose();for(let e=0;e2?td:0,td,td),p.setRenderTarget(r),N&&p.render(T,a),p.render(e,a)}T.geometry.dispose(),T.material.dispose(),p.toneMapping=y,p.outputEncoding=v,p.autoClear=g,e.background=k}_setEncoding(e,t){e.value=cp[t.encoding]}_textureToCubeUV(e,t){const i=this._renderer,r=e.mapping===Bg||e.mapping===Vg;r?null==this._cubemapShader&&(this._cubemapShader=NB()):null==this._equirectShader&&(this._equirectShader=LB());const s=r?this._cubemapShader:this._equirectShader,o=new vr(Gy[0],s),a=s.uniforms;a.envMap.value=e,r||a.texelSize.value.set(1/e.image.width,1/e.image.height),this._setEncoding(a.inputEncoding,e),this._setEncoding(a.outputEncoding,t.texture),M2(t,0,0,3*td,2*td),i.setRenderTarget(t),i.render(o,oI)}_applyPMREM(e){const t=this._renderer,i=t.autoClear;t.autoClear=!1;for(let r=1;r20&&console.warn(`sigmaRadians, ${s}, is too large and will clip, as it requested ${N} samples when the maximum is set to 20`);const k=[];let A=0;for(let se=0;se<20;++se){const K=se/T,he=Math.exp(-K*K/2);k.push(he),0==se?A+=he:seSh-u0?r-Sh+u0:0),3*H,2*H),c.setRenderTarget(t),c.render(g,oI)}}function Tae(n){return void 0!==n&&n.type===fh&&(n.encoding===Ma||n.encoding===e2||n.encoding===Dk)}function Aae(){const n=[],e=[],t=[];let i=Sh;for(let r=0;rSh-u0?o=kB[r-Sh+u0-1]:0==r&&(o=0),t.push(o);const a=1/(s-1),c=-a/2,u=1+a/2,p=[c,c,u,c,u,u,c,c,u,u,c,u],g=6,v=6,y=3,x=2,T=1,N=new Float32Array(y*v*g),k=new Float32Array(x*v*g),A=new Float32Array(T*v*g);for(let G=0;G2?0:-1;N.set([X,se,0,X+2/3,se,0,X+2/3,se+1,0,X,se,0,X+2/3,se+1,0,X,se+1,0],y*v*G),k.set(p,x*v*G),A.set([G,G,G,G,G,G],T*v*G)}const H=new gn;H.setAttribute("position",new zi(N,y)),H.setAttribute("uv",new zi(k,x)),H.setAttribute("faceIndex",new zi(A,T)),n.push(H),i>u0&&i--}return{_lodPlanes:n,_sizeLods:e,_sigmas:t}}function OB(n){const e=new Bc(3*td,3*td,n);return e.texture.mapping=ky,e.texture.name="PMREM.cubeUv",e.scissorTest=!0,e}function M2(n,e,t,i,r){n.viewport.set(e,t,i,r),n.scissor.set(e,t,i,r)}function LB(){const n=new tt(1,1);return new zy({name:"EquirectangularToCubeUV",uniforms:{envMap:{value:null},texelSize:{value:n},inputEncoding:{value:cp[Ma]},outputEncoding:{value:cp[Ma]}},vertexShader:"\n\n\t\tprecision mediump float;\n\t\tprecision mediump int;\n\n\t\tattribute vec3 position;\n\t\tattribute vec2 uv;\n\t\tattribute float faceIndex;\n\n\t\tvarying vec3 vOutputDirection;\n\n\t\t// RH coordinate system; PMREM face-indexing convention\n\t\tvec3 getDirection( vec2 uv, float face ) {\n\n\t\t\tuv = 2.0 * uv - 1.0;\n\n\t\t\tvec3 direction = vec3( uv, 1.0 );\n\n\t\t\tif ( face == 0.0 ) {\n\n\t\t\t\tdirection = direction.zyx; // ( 1, v, u ) pos x\n\n\t\t\t} else if ( face == 1.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xz *= -1.0; // ( -u, 1, -v ) pos y\n\n\t\t\t} else if ( face == 2.0 ) {\n\n\t\t\t\tdirection.x *= -1.0; // ( -u, v, 1 ) pos z\n\n\t\t\t} else if ( face == 3.0 ) {\n\n\t\t\t\tdirection = direction.zyx;\n\t\t\t\tdirection.xz *= -1.0; // ( -1, v, -u ) neg x\n\n\t\t\t} else if ( face == 4.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xy *= -1.0; // ( -u, -1, v ) neg y\n\n\t\t\t} else if ( face == 5.0 ) {\n\n\t\t\t\tdirection.z *= -1.0; // ( u, v, -1 ) neg z\n\n\t\t\t}\n\n\t\t\treturn direction;\n\n\t\t}\n\n\t\tvoid main() {\n\n\t\t\tvOutputDirection = getDirection( uv, faceIndex );\n\t\t\tgl_Position = vec4( position, 1.0 );\n\n\t\t}\n\t",fragmentShader:"\n\n\t\t\tprecision mediump float;\n\t\t\tprecision mediump int;\n\n\t\t\tvarying vec3 vOutputDirection;\n\n\t\t\tuniform sampler2D envMap;\n\t\t\tuniform vec2 texelSize;\n\n\t\t\t\n\n\t\tuniform int inputEncoding;\n\t\tuniform int outputEncoding;\n\n\t\t#include \n\n\t\tvec4 inputTexelToLinear( vec4 value ) {\n\n\t\t\tif ( inputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( inputEncoding == 1 ) {\n\n\t\t\t\treturn sRGBToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 2 ) {\n\n\t\t\t\treturn RGBEToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 3 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 7.0 );\n\n\t\t\t} else if ( inputEncoding == 4 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 16.0 );\n\n\t\t\t} else if ( inputEncoding == 5 ) {\n\n\t\t\t\treturn RGBDToLinear( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn GammaToLinear( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 linearToOutputTexel( vec4 value ) {\n\n\t\t\tif ( outputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( outputEncoding == 1 ) {\n\n\t\t\t\treturn LinearTosRGB( value );\n\n\t\t\t} else if ( outputEncoding == 2 ) {\n\n\t\t\t\treturn LinearToRGBE( value );\n\n\t\t\t} else if ( outputEncoding == 3 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 7.0 );\n\n\t\t\t} else if ( outputEncoding == 4 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 16.0 );\n\n\t\t\t} else if ( outputEncoding == 5 ) {\n\n\t\t\t\treturn LinearToRGBD( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn LinearToGamma( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 envMapTexelToLinear( vec4 color ) {\n\n\t\t\treturn inputTexelToLinear( color );\n\n\t\t}\n\t\n\n\t\t\t#include \n\n\t\t\tvoid main() {\n\n\t\t\t\tgl_FragColor = vec4( 0.0, 0.0, 0.0, 1.0 );\n\n\t\t\t\tvec3 outputDirection = normalize( vOutputDirection );\n\t\t\t\tvec2 uv = equirectUv( outputDirection );\n\n\t\t\t\tvec2 f = fract( uv / texelSize - 0.5 );\n\t\t\t\tuv -= f * texelSize;\n\t\t\t\tvec3 tl = envMapTexelToLinear( texture2D ( envMap, uv ) ).rgb;\n\t\t\t\tuv.x += texelSize.x;\n\t\t\t\tvec3 tr = envMapTexelToLinear( texture2D ( envMap, uv ) ).rgb;\n\t\t\t\tuv.y += texelSize.y;\n\t\t\t\tvec3 br = envMapTexelToLinear( texture2D ( envMap, uv ) ).rgb;\n\t\t\t\tuv.x -= texelSize.x;\n\t\t\t\tvec3 bl = envMapTexelToLinear( texture2D ( envMap, uv ) ).rgb;\n\n\t\t\t\tvec3 tm = mix( tl, tr, f.x );\n\t\t\t\tvec3 bm = mix( bl, br, f.x );\n\t\t\t\tgl_FragColor.rgb = mix( tm, bm, f.y );\n\n\t\t\t\tgl_FragColor = linearToOutputTexel( gl_FragColor );\n\n\t\t\t}\n\t\t",blending:hh,depthTest:!1,depthWrite:!1})}function NB(){return new zy({name:"CubemapToCubeUV",uniforms:{envMap:{value:null},inputEncoding:{value:cp[Ma]},outputEncoding:{value:cp[Ma]}},vertexShader:"\n\n\t\tprecision mediump float;\n\t\tprecision mediump int;\n\n\t\tattribute vec3 position;\n\t\tattribute vec2 uv;\n\t\tattribute float faceIndex;\n\n\t\tvarying vec3 vOutputDirection;\n\n\t\t// RH coordinate system; PMREM face-indexing convention\n\t\tvec3 getDirection( vec2 uv, float face ) {\n\n\t\t\tuv = 2.0 * uv - 1.0;\n\n\t\t\tvec3 direction = vec3( uv, 1.0 );\n\n\t\t\tif ( face == 0.0 ) {\n\n\t\t\t\tdirection = direction.zyx; // ( 1, v, u ) pos x\n\n\t\t\t} else if ( face == 1.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xz *= -1.0; // ( -u, 1, -v ) pos y\n\n\t\t\t} else if ( face == 2.0 ) {\n\n\t\t\t\tdirection.x *= -1.0; // ( -u, v, 1 ) pos z\n\n\t\t\t} else if ( face == 3.0 ) {\n\n\t\t\t\tdirection = direction.zyx;\n\t\t\t\tdirection.xz *= -1.0; // ( -1, v, -u ) neg x\n\n\t\t\t} else if ( face == 4.0 ) {\n\n\t\t\t\tdirection = direction.xzy;\n\t\t\t\tdirection.xy *= -1.0; // ( -u, -1, v ) neg y\n\n\t\t\t} else if ( face == 5.0 ) {\n\n\t\t\t\tdirection.z *= -1.0; // ( u, v, -1 ) neg z\n\n\t\t\t}\n\n\t\t\treturn direction;\n\n\t\t}\n\n\t\tvoid main() {\n\n\t\t\tvOutputDirection = getDirection( uv, faceIndex );\n\t\t\tgl_Position = vec4( position, 1.0 );\n\n\t\t}\n\t",fragmentShader:"\n\n\t\t\tprecision mediump float;\n\t\t\tprecision mediump int;\n\n\t\t\tvarying vec3 vOutputDirection;\n\n\t\t\tuniform samplerCube envMap;\n\n\t\t\t\n\n\t\tuniform int inputEncoding;\n\t\tuniform int outputEncoding;\n\n\t\t#include \n\n\t\tvec4 inputTexelToLinear( vec4 value ) {\n\n\t\t\tif ( inputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( inputEncoding == 1 ) {\n\n\t\t\t\treturn sRGBToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 2 ) {\n\n\t\t\t\treturn RGBEToLinear( value );\n\n\t\t\t} else if ( inputEncoding == 3 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 7.0 );\n\n\t\t\t} else if ( inputEncoding == 4 ) {\n\n\t\t\t\treturn RGBMToLinear( value, 16.0 );\n\n\t\t\t} else if ( inputEncoding == 5 ) {\n\n\t\t\t\treturn RGBDToLinear( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn GammaToLinear( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 linearToOutputTexel( vec4 value ) {\n\n\t\t\tif ( outputEncoding == 0 ) {\n\n\t\t\t\treturn value;\n\n\t\t\t} else if ( outputEncoding == 1 ) {\n\n\t\t\t\treturn LinearTosRGB( value );\n\n\t\t\t} else if ( outputEncoding == 2 ) {\n\n\t\t\t\treturn LinearToRGBE( value );\n\n\t\t\t} else if ( outputEncoding == 3 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 7.0 );\n\n\t\t\t} else if ( outputEncoding == 4 ) {\n\n\t\t\t\treturn LinearToRGBM( value, 16.0 );\n\n\t\t\t} else if ( outputEncoding == 5 ) {\n\n\t\t\t\treturn LinearToRGBD( value, 256.0 );\n\n\t\t\t} else {\n\n\t\t\t\treturn LinearToGamma( value, 2.2 );\n\n\t\t\t}\n\n\t\t}\n\n\t\tvec4 envMapTexelToLinear( vec4 color ) {\n\n\t\t\treturn inputTexelToLinear( color );\n\n\t\t}\n\t\n\n\t\t\tvoid main() {\n\n\t\t\t\tgl_FragColor = vec4( 0.0, 0.0, 0.0, 1.0 );\n\t\t\t\tgl_FragColor.rgb = envMapTexelToLinear( textureCube( envMap, vec3( - vOutputDirection.x, vOutputDirection.yz ) ) ).rgb;\n\t\t\t\tgl_FragColor = linearToOutputTexel( gl_FragColor );\n\n\t\t\t}\n\t\t",blending:hh,depthTest:!1,depthWrite:!1})}function Iae(n){let e=new WeakMap,t=null;function s(a){const c=a.target;c.removeEventListener("dispose",s);const u=e.get(c);void 0!==u&&(e.delete(c),u.dispose())}return{get:function i(a){if(a&&a.isTexture&&!1===a.isRenderTargetTexture){const c=a.mapping,u=c===WS||c===$S,p=c===Bg||c===Vg;if(u||p){if(e.has(a))return e.get(a).texture;{const g=a.image;if(u&&g&&g.height>0||p&&g&&function r(a){let c=0;for(let p=0;p<6;p++)void 0!==a[p]&&c++;return 6===c}(g)){const v=n.getRenderTarget();null===t&&(t=new Dae(n));const y=u?t.fromEquirectangular(a):t.fromCubemap(a);return e.set(a,y),n.setRenderTarget(v),a.addEventListener("dispose",s),y.texture}return null}}}return a},dispose:function o(){e=new WeakMap,null!==t&&(t.dispose(),t=null)}}}function Fae(n){const e={};function t(i){if(void 0!==e[i])return e[i];let r;switch(i){case"WEBGL_depth_texture":r=n.getExtension("WEBGL_depth_texture")||n.getExtension("MOZ_WEBGL_depth_texture")||n.getExtension("WEBKIT_WEBGL_depth_texture");break;case"EXT_texture_filter_anisotropic":r=n.getExtension("EXT_texture_filter_anisotropic")||n.getExtension("MOZ_EXT_texture_filter_anisotropic")||n.getExtension("WEBKIT_EXT_texture_filter_anisotropic");break;case"WEBGL_compressed_texture_s3tc":r=n.getExtension("WEBGL_compressed_texture_s3tc")||n.getExtension("MOZ_WEBGL_compressed_texture_s3tc")||n.getExtension("WEBKIT_WEBGL_compressed_texture_s3tc");break;case"WEBGL_compressed_texture_pvrtc":r=n.getExtension("WEBGL_compressed_texture_pvrtc")||n.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc");break;default:r=n.getExtension(i)}return e[i]=r,r}return{has:function(i){return null!==t(i)},init:function(i){i.isWebGL2?t("EXT_color_buffer_float"):(t("WEBGL_depth_texture"),t("OES_texture_float"),t("OES_texture_half_float"),t("OES_texture_half_float_linear"),t("OES_standard_derivatives"),t("OES_element_index_uint"),t("OES_vertex_array_object"),t("ANGLE_instanced_arrays")),t("OES_texture_float_linear"),t("EXT_color_buffer_half_float"),t("WEBGL_multisampled_render_to_texture")},get:function(i){const r=t(i);return null===r&&console.warn("THREE.WebGLRenderer: "+i+" extension not supported."),r}}}function Rae(n,e,t,i){const r={},s=new WeakMap;function o(g){const v=g.target;null!==v.index&&e.remove(v.index);for(const x in v.attributes)e.remove(v.attributes[x]);v.removeEventListener("dispose",o),delete r[v.id];const y=s.get(v);y&&(e.remove(y),s.delete(v)),i.releaseStatesOfGeometry(v),!0===v.isInstancedBufferGeometry&&delete v._maxInstanceCount,t.memory.geometries--}function u(g){const v=[],y=g.index,x=g.attributes.position;let T=0;if(null!==y){const A=y.array;T=y.version;for(let H=0,G=A.length;H65535?Xk:Yk)(v,1);N.version=T;const k=s.get(g);k&&e.remove(k),s.set(g,N)}return{get:function a(g,v){return!0===r[v.id]||(v.addEventListener("dispose",o),r[v.id]=!0,t.memory.geometries++),v},update:function c(g){const v=g.attributes;for(const x in v)e.update(v[x],34962);const y=g.morphAttributes;for(const x in y){const T=y[x];for(let N=0,k=T.length;Ne.maxTextureSize&&(he=Math.ceil(K/e.maxTextureSize),K=e.maxTextureSize);const De=new Float32Array(K*he*4*x),Te=new dI(De,K,he,x);Te.format=zo,Te.type=Yd;const ge=4*se;for(let Qe=0;Qe0)return n;const r=e*t;let s=jB[r];if(void 0===s&&(s=new Float32Array(r),jB[r]=s),0!==e){i.toArray(s,0);for(let o=1,a=0;o!==e;++o)a+=t,n[o].toArray(s,a)}return s}function ua(n,e){if(n.length!==e.length)return!1;for(let t=0,i=n.length;t/gm;function hI(n){return n.replace(Oce,Lce)}function Lce(n,e){const t=pi[e];if(void 0===t)throw new Error("Can not resolve #include <"+e+">");return hI(t)}const Nce=/#pragma unroll_loop[\s]+?for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g,Bce=/#pragma unroll_loop_start\s+for\s*\(\s*int\s+i\s*=\s*(\d+)\s*;\s*i\s*<\s*(\d+)\s*;\s*i\s*\+\+\s*\)\s*{([\s\S]+?)}\s+#pragma unroll_loop_end/g;function i6(n){return n.replace(Bce,r6).replace(Nce,Vce)}function Vce(n,e,t,i){return console.warn("WebGLProgram: #pragma unroll_loop shader syntax is deprecated. Please use #pragma unroll_loop_start syntax instead."),r6(0,e,t,i)}function r6(n,e,t,i){let r="";for(let s=parseInt(e);s0?n.gammaFactor:1,y=t.isWebGL2?"":function Fce(n){return[n.extensionDerivatives||n.envMapCubeUV||n.bumpMap||n.tangentSpaceNormalMap||n.clearcoatNormalMap||n.flatShading||"physical"===n.shaderID?"#extension GL_OES_standard_derivatives : enable":"",(n.extensionFragDepth||n.logarithmicDepthBuffer)&&n.rendererExtensionFragDepth?"#extension GL_EXT_frag_depth : enable":"",n.extensionDrawBuffers&&n.rendererExtensionDrawBuffers?"#extension GL_EXT_draw_buffers : require":"",(n.extensionShaderTextureLOD||n.envMap||n.transmission)&&n.rendererExtensionShaderTextureLod?"#extension GL_EXT_shader_texture_lod : enable":""].filter(jy).join("\n")}(t),x=function Rce(n){const e=[];for(const t in n){const i=n[t];!1!==i&&e.push("#define "+t+" "+i)}return e.join("\n")}(s),T=r.createProgram();let N,k,A=t.glslVersion?"#version "+t.glslVersion+"\n":"";t.isRawShaderMaterial?(N=[x].filter(jy).join("\n"),N.length>0&&(N+="\n"),k=[y,x].filter(jy).join("\n"),k.length>0&&(k+="\n")):(N=[s6(t),"#define SHADER_NAME "+t.shaderName,x,t.instancing?"#define USE_INSTANCING":"",t.instancingColor?"#define USE_INSTANCING_COLOR":"",t.supportsVertexTextures?"#define VERTEX_TEXTURES":"","#define GAMMA_FACTOR "+v,"#define MAX_BONES "+t.maxBones,t.useFog&&t.fog?"#define USE_FOG":"",t.useFog&&t.fogExp2?"#define FOG_EXP2":"",t.map?"#define USE_MAP":"",t.envMap?"#define USE_ENVMAP":"",t.envMap?"#define "+p:"",t.lightMap?"#define USE_LIGHTMAP":"",t.aoMap?"#define USE_AOMAP":"",t.emissiveMap?"#define USE_EMISSIVEMAP":"",t.bumpMap?"#define USE_BUMPMAP":"",t.normalMap?"#define USE_NORMALMAP":"",t.normalMap&&t.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",t.normalMap&&t.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",t.clearcoatMap?"#define USE_CLEARCOATMAP":"",t.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",t.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",t.displacementMap&&t.supportsVertexTextures?"#define USE_DISPLACEMENTMAP":"",t.specularMap?"#define USE_SPECULARMAP":"",t.specularIntensityMap?"#define USE_SPECULARINTENSITYMAP":"",t.specularColorMap?"#define USE_SPECULARCOLORMAP":"",t.roughnessMap?"#define USE_ROUGHNESSMAP":"",t.metalnessMap?"#define USE_METALNESSMAP":"",t.alphaMap?"#define USE_ALPHAMAP":"",t.transmission?"#define USE_TRANSMISSION":"",t.transmissionMap?"#define USE_TRANSMISSIONMAP":"",t.thicknessMap?"#define USE_THICKNESSMAP":"",t.sheenColorMap?"#define USE_SHEENCOLORMAP":"",t.sheenRoughnessMap?"#define USE_SHEENROUGHNESSMAP":"",t.vertexTangents?"#define USE_TANGENT":"",t.vertexColors?"#define USE_COLOR":"",t.vertexAlphas?"#define USE_COLOR_ALPHA":"",t.vertexUvs?"#define USE_UV":"",t.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",t.flatShading?"#define FLAT_SHADED":"",t.skinning?"#define USE_SKINNING":"",t.useVertexTexture?"#define BONE_TEXTURE":"",t.morphTargets?"#define USE_MORPHTARGETS":"",t.morphNormals&&!1===t.flatShading?"#define USE_MORPHNORMALS":"",t.morphTargets&&t.isWebGL2?"#define MORPHTARGETS_TEXTURE":"",t.morphTargets&&t.isWebGL2?"#define MORPHTARGETS_COUNT "+t.morphTargetsCount:"",t.doubleSided?"#define DOUBLE_SIDED":"",t.flipSided?"#define FLIP_SIDED":"",t.shadowMapEnabled?"#define USE_SHADOWMAP":"",t.shadowMapEnabled?"#define "+c:"",t.sizeAttenuation?"#define USE_SIZEATTENUATION":"",t.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",t.logarithmicDepthBuffer&&t.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"","uniform mat4 modelMatrix;","uniform mat4 modelViewMatrix;","uniform mat4 projectionMatrix;","uniform mat4 viewMatrix;","uniform mat3 normalMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;","#ifdef USE_INSTANCING","\tattribute mat4 instanceMatrix;","#endif","#ifdef USE_INSTANCING_COLOR","\tattribute vec3 instanceColor;","#endif","attribute vec3 position;","attribute vec3 normal;","attribute vec2 uv;","#ifdef USE_TANGENT","\tattribute vec4 tangent;","#endif","#if defined( USE_COLOR_ALPHA )","\tattribute vec4 color;","#elif defined( USE_COLOR )","\tattribute vec3 color;","#endif","#if ( defined( USE_MORPHTARGETS ) && ! defined( MORPHTARGETS_TEXTURE ) )","\tattribute vec3 morphTarget0;","\tattribute vec3 morphTarget1;","\tattribute vec3 morphTarget2;","\tattribute vec3 morphTarget3;","\t#ifdef USE_MORPHNORMALS","\t\tattribute vec3 morphNormal0;","\t\tattribute vec3 morphNormal1;","\t\tattribute vec3 morphNormal2;","\t\tattribute vec3 morphNormal3;","\t#else","\t\tattribute vec3 morphTarget4;","\t\tattribute vec3 morphTarget5;","\t\tattribute vec3 morphTarget6;","\t\tattribute vec3 morphTarget7;","\t#endif","#endif","#ifdef USE_SKINNING","\tattribute vec4 skinIndex;","\tattribute vec4 skinWeight;","#endif","\n"].filter(jy).join("\n"),k=[y,s6(t),"#define SHADER_NAME "+t.shaderName,x,"#define GAMMA_FACTOR "+v,t.useFog&&t.fog?"#define USE_FOG":"",t.useFog&&t.fogExp2?"#define FOG_EXP2":"",t.map?"#define USE_MAP":"",t.matcap?"#define USE_MATCAP":"",t.envMap?"#define USE_ENVMAP":"",t.envMap?"#define "+u:"",t.envMap?"#define "+p:"",t.envMap?"#define "+g:"",t.lightMap?"#define USE_LIGHTMAP":"",t.aoMap?"#define USE_AOMAP":"",t.emissiveMap?"#define USE_EMISSIVEMAP":"",t.bumpMap?"#define USE_BUMPMAP":"",t.normalMap?"#define USE_NORMALMAP":"",t.normalMap&&t.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",t.normalMap&&t.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",t.clearcoat?"#define USE_CLEARCOAT":"",t.clearcoatMap?"#define USE_CLEARCOATMAP":"",t.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",t.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",t.specularMap?"#define USE_SPECULARMAP":"",t.specularIntensityMap?"#define USE_SPECULARINTENSITYMAP":"",t.specularColorMap?"#define USE_SPECULARCOLORMAP":"",t.roughnessMap?"#define USE_ROUGHNESSMAP":"",t.metalnessMap?"#define USE_METALNESSMAP":"",t.alphaMap?"#define USE_ALPHAMAP":"",t.alphaTest?"#define USE_ALPHATEST":"",t.sheen?"#define USE_SHEEN":"",t.sheenColorMap?"#define USE_SHEENCOLORMAP":"",t.sheenRoughnessMap?"#define USE_SHEENROUGHNESSMAP":"",t.transmission?"#define USE_TRANSMISSION":"",t.transmissionMap?"#define USE_TRANSMISSIONMAP":"",t.thicknessMap?"#define USE_THICKNESSMAP":"",t.vertexTangents?"#define USE_TANGENT":"",t.vertexColors||t.instancingColor?"#define USE_COLOR":"",t.vertexAlphas?"#define USE_COLOR_ALPHA":"",t.vertexUvs?"#define USE_UV":"",t.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",t.gradientMap?"#define USE_GRADIENTMAP":"",t.flatShading?"#define FLAT_SHADED":"",t.doubleSided?"#define DOUBLE_SIDED":"",t.flipSided?"#define FLIP_SIDED":"",t.shadowMapEnabled?"#define USE_SHADOWMAP":"",t.shadowMapEnabled?"#define "+c:"",t.premultipliedAlpha?"#define PREMULTIPLIED_ALPHA":"",t.physicallyCorrectLights?"#define PHYSICALLY_CORRECT_LIGHTS":"",t.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",t.logarithmicDepthBuffer&&t.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"",(t.extensionShaderTextureLOD||t.envMap)&&t.rendererExtensionShaderTextureLod?"#define TEXTURE_LOD_EXT":"","uniform mat4 viewMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;",t.toneMapping!==Qf?"#define TONE_MAPPING":"",t.toneMapping!==Qf?pi.tonemapping_pars_fragment:"",t.toneMapping!==Qf?Ice("toneMapping",t.toneMapping):"",t.dithering?"#define DITHERING":"",t.format===ep?"#define OPAQUE":"",pi.encodings_pars_fragment,t.map?dp("mapTexelToLinear",t.mapEncoding):"",t.matcap?dp("matcapTexelToLinear",t.matcapEncoding):"",t.envMap?dp("envMapTexelToLinear",t.envMapEncoding):"",t.emissiveMap?dp("emissiveMapTexelToLinear",t.emissiveMapEncoding):"",t.specularColorMap?dp("specularColorMapTexelToLinear",t.specularColorMapEncoding):"",t.sheenColorMap?dp("sheenColorMapTexelToLinear",t.sheenColorMapEncoding):"",t.lightMap?dp("lightMapTexelToLinear",t.lightMapEncoding):"",kce("linearToOutputTexel",t.outputEncoding),t.depthPacking?"#define DEPTH_PACKING "+t.depthPacking:"","\n"].filter(jy).join("\n")),o=hI(o),o=t6(o,t),o=n6(o,t),a=hI(a),a=t6(a,t),a=n6(a,t),o=i6(o),a=i6(a),t.isWebGL2&&!0!==t.isRawShaderMaterial&&(A="#version 300 es\n",N=["precision mediump sampler2DArray;","#define attribute in","#define varying out","#define texture2D texture"].join("\n")+"\n"+N,k=["#define varying in",t.glslVersion===uB?"":"out highp vec4 pc_fragColor;",t.glslVersion===uB?"":"#define gl_FragColor pc_fragColor","#define gl_FragDepthEXT gl_FragDepth","#define texture2D texture","#define textureCube texture","#define texture2DProj textureProj","#define texture2DLodEXT textureLod","#define texture2DProjLodEXT textureProjLod","#define textureCubeLodEXT textureLod","#define texture2DGradEXT textureGrad","#define texture2DProjGradEXT textureProjGrad","#define textureCubeGradEXT textureGrad"].join("\n")+"\n"+k);const G=A+k+a,X=JB(r,35633,A+N+o),se=JB(r,35632,G);if(r.attachShader(T,X),r.attachShader(T,se),void 0!==t.index0AttributeName?r.bindAttribLocation(T,0,t.index0AttributeName):!0===t.morphTargets&&r.bindAttribLocation(T,0,"position"),r.linkProgram(T),n.debug.checkShaderErrors){const De=r.getProgramInfoLog(T).trim(),Te=r.getShaderInfoLog(X).trim(),ge=r.getShaderInfoLog(se).trim();let Qe=!0,Pe=!0;if(!1===r.getProgramParameter(T,35714)){Qe=!1;const Oe=e6(r,X,"vertex"),Ve=e6(r,se,"fragment");console.error("THREE.WebGLProgram: Shader Error "+r.getError()+" - VALIDATE_STATUS "+r.getProgramParameter(T,35715)+"\n\nProgram Info Log: "+De+"\n"+Oe+"\n"+Ve)}else""!==De?console.warn("THREE.WebGLProgram: Program Info Log:",De):(""===Te||""===ge)&&(Pe=!1);Pe&&(this.diagnostics={runnable:Qe,programLog:De,vertexShader:{log:Te,prefix:N},fragmentShader:{log:ge,prefix:k}})}let K,he;return r.deleteShader(X),r.deleteShader(se),this.getUniforms=function(){return void 0===K&&(K=new Eh(r,T)),K},this.getAttributes=function(){return void 0===he&&(he=function Pce(n,e){const t={},i=n.getProgramParameter(e,35721);for(let r=0;r0,Ke=K.clearcoat>0;return{isWebGL2:c,shaderID:Ve,shaderName:K.type,vertexShader:Me,fragmentShader:je,defines:K.defines,isRawShaderMaterial:!0===K.isRawShaderMaterial,glslVersion:K.glslVersion,precision:y,instancing:!0===ge.isInstancedMesh,instancingColor:!0===ge.isInstancedMesh&&null!==ge.instanceColor,supportsVertexTextures:v,outputEncoding:null!==lt?k(lt.texture):n.outputEncoding,map:!!K.map,mapEncoding:k(K.map),matcap:!!K.matcap,matcapEncoding:k(K.matcap),envMap:!!Oe,envMapMode:Oe&&Oe.mapping,envMapEncoding:k(Oe),envMapCubeUV:!!Oe&&(Oe.mapping===ky||Oe.mapping===qS),lightMap:!!K.lightMap,lightMapEncoding:k(K.lightMap),aoMap:!!K.aoMap,emissiveMap:!!K.emissiveMap,emissiveMapEncoding:k(K.emissiveMap),bumpMap:!!K.bumpMap,normalMap:!!K.normalMap,objectSpaceNormalMap:K.normalMapType===Hre,tangentSpaceNormalMap:K.normalMapType===$g,clearcoat:Ke,clearcoatMap:Ke&&!!K.clearcoatMap,clearcoatRoughnessMap:Ke&&!!K.clearcoatRoughnessMap,clearcoatNormalMap:Ke&&!!K.clearcoatNormalMap,displacementMap:!!K.displacementMap,roughnessMap:!!K.roughnessMap,metalnessMap:!!K.metalnessMap,specularMap:!!K.specularMap,specularIntensityMap:!!K.specularIntensityMap,specularColorMap:!!K.specularColorMap,specularColorMapEncoding:k(K.specularColorMap),alphaMap:!!K.alphaMap,alphaTest:ze,gradientMap:!!K.gradientMap,sheen:K.sheen>0,sheenColorMap:!!K.sheenColorMap,sheenColorMapEncoding:k(K.sheenColorMap),sheenRoughnessMap:!!K.sheenRoughnessMap,transmission:K.transmission>0,transmissionMap:!!K.transmissionMap,thicknessMap:!!K.thicknessMap,combine:K.combine,vertexTangents:!!K.normalMap&&!!ge.geometry&&!!ge.geometry.attributes.tangent,vertexColors:K.vertexColors,vertexAlphas:!0===K.vertexColors&&!!ge.geometry&&!!ge.geometry.attributes.color&&4===ge.geometry.attributes.color.itemSize,vertexUvs:!!K.map||!!K.bumpMap||!!K.normalMap||!!K.specularMap||!!K.alphaMap||!!K.emissiveMap||!!K.roughnessMap||!!K.metalnessMap||!!K.clearcoatMap||!!K.clearcoatRoughnessMap||!!K.clearcoatNormalMap||!!K.displacementMap||!!K.transmissionMap||!!K.thicknessMap||!!K.specularIntensityMap||!!K.specularColorMap||!!K.sheenColorMap||K.sheenRoughnessMap,uvsVertexOnly:!(K.map||K.bumpMap||K.normalMap||K.specularMap||K.alphaMap||K.emissiveMap||K.roughnessMap||K.metalnessMap||K.clearcoatNormalMap||K.transmission>0||K.transmissionMap||K.thicknessMap||K.specularIntensityMap||K.specularColorMap||K.sheen>0||K.sheenColorMap||K.sheenRoughnessMap||!K.displacementMap),fog:!!Qe,useFog:K.fog,fogExp2:Qe&&Qe.isFogExp2,flatShading:!!K.flatShading,sizeAttenuation:K.sizeAttenuation,logarithmicDepthBuffer:u,skinning:!0===ge.isSkinnedMesh&&ye>0,maxBones:ye,useVertexTexture:p,morphTargets:!!ge.geometry&&!!ge.geometry.morphAttributes.position,morphNormals:!!ge.geometry&&!!ge.geometry.morphAttributes.normal,morphTargetsCount:ge.geometry&&ge.geometry.morphAttributes.position?ge.geometry.morphAttributes.position.length:0,numDirLights:he.directional.length,numPointLights:he.point.length,numSpotLights:he.spot.length,numRectAreaLights:he.rectArea.length,numHemiLights:he.hemi.length,numDirLightShadows:he.directionalShadowMap.length,numPointLightShadows:he.pointShadowMap.length,numSpotLightShadows:he.spotShadowMap.length,numClippingPlanes:o.numPlanes,numClipIntersection:o.numIntersection,format:K.format,dithering:K.dithering,shadowMapEnabled:n.shadowMap.enabled&&De.length>0,shadowMapType:n.shadowMap.type,toneMapping:K.toneMapped?n.toneMapping:Qf,physicallyCorrectLights:n.physicallyCorrectLights,premultipliedAlpha:K.premultipliedAlpha,doubleSided:K.side===Lg,flipSided:K.side===Ds,depthPacking:void 0!==K.depthPacking&&K.depthPacking,index0AttributeName:K.index0AttributeName,extensionDerivatives:K.extensions&&K.extensions.derivatives,extensionFragDepth:K.extensions&&K.extensions.fragDepth,extensionDrawBuffers:K.extensions&&K.extensions.drawBuffers,extensionShaderTextureLOD:K.extensions&&K.extensions.shaderTextureLOD,rendererExtensionFragDepth:c||i.has("EXT_frag_depth"),rendererExtensionDrawBuffers:c||i.has("WEBGL_draw_buffers"),rendererExtensionShaderTextureLod:c||i.has("EXT_shader_texture_lod"),customProgramCacheKey:K.customProgramCacheKey()}},getProgramCacheKey:function H(K){const he=[];if(K.shaderID?he.push(K.shaderID):(he.push(mB(K.fragmentShader)),he.push(mB(K.vertexShader))),void 0!==K.defines)for(const De in K.defines)he.push(De),he.push(K.defines[De]);if(!1===K.isRawShaderMaterial){for(let De=0;De0?r.push(H):!0===T.transparent?s.push(H):i.push(H)},unshift:function p(y,x,T,N,k,A){const H=c(y,x,T,N,k,A);T.transmission>0?r.unshift(H):!0===T.transparent?s.unshift(H):i.unshift(H)},finish:function v(){for(let y=t,x=e.length;y1&&i.sort(y||qce),r.length>1&&r.sort(x||o6),s.length>1&&s.sort(x||o6)}}}function Kce(n){let e=new WeakMap;return{get:function t(r,s){let o;return!1===e.has(r)?(o=new a6(n),e.set(r,[o])):s>=e.get(r).length?(o=new a6(n),e.get(r).push(o)):o=e.get(r)[s],o},dispose:function i(){e=new WeakMap}}}function Yce(){const n={};return{get:function(e){if(void 0!==n[e.id])return n[e.id];let t;switch(e.type){case"DirectionalLight":t={direction:new ne,color:new Rt};break;case"SpotLight":t={position:new ne,direction:new ne,color:new Rt,distance:0,coneCos:0,penumbraCos:0,decay:0};break;case"PointLight":t={position:new ne,color:new Rt,distance:0,decay:0};break;case"HemisphereLight":t={direction:new ne,skyColor:new Rt,groundColor:new Rt};break;case"RectAreaLight":t={color:new Rt,position:new ne,halfWidth:new ne,halfHeight:new ne}}return n[e.id]=t,t}}}let Zce=0;function Jce(n,e){return(e.castShadow?1:0)-(n.castShadow?1:0)}function Qce(n,e){const t=new Yce,i=function Xce(){const n={};return{get:function(e){if(void 0!==n[e.id])return n[e.id];let t;switch(e.type){case"DirectionalLight":case"SpotLight":t={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new tt};break;case"PointLight":t={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new tt,shadowCameraNear:1,shadowCameraFar:1e3}}return n[e.id]=t,t}}}(),r={version:0,hash:{directionalLength:-1,pointLength:-1,spotLength:-1,rectAreaLength:-1,hemiLength:-1,numDirectionalShadows:-1,numPointShadows:-1,numSpotShadows:-1},ambient:[0,0,0],probe:[],directional:[],directionalShadow:[],directionalShadowMap:[],directionalShadowMatrix:[],spot:[],spotShadow:[],spotShadowMap:[],spotShadowMatrix:[],rectArea:[],rectAreaLTC1:null,rectAreaLTC2:null,point:[],pointShadow:[],pointShadowMap:[],pointShadowMatrix:[],hemi:[]};for(let p=0;p<9;p++)r.probe.push(new ne);const s=new ne,o=new Gt,a=new Gt;return{setup:function c(p,g){let v=0,y=0,x=0;for(let De=0;De<9;De++)r.probe[De].set(0,0,0);let T=0,N=0,k=0,A=0,H=0,G=0,X=0,se=0;p.sort(Jce);const K=!0!==g?Math.PI:1;for(let De=0,Te=p.length;De0&&(e.isWebGL2||!0===n.has("OES_texture_float_linear")?(r.rectAreaLTC1=Ct.LTC_FLOAT_1,r.rectAreaLTC2=Ct.LTC_FLOAT_2):!0===n.has("OES_texture_half_float_linear")?(r.rectAreaLTC1=Ct.LTC_HALF_1,r.rectAreaLTC2=Ct.LTC_HALF_2):console.error("THREE.WebGLRenderer: Unable to use RectAreaLight. Missing WebGL extensions.")),r.ambient[0]=v,r.ambient[1]=y,r.ambient[2]=x;const he=r.hash;(he.directionalLength!==T||he.pointLength!==N||he.spotLength!==k||he.rectAreaLength!==A||he.hemiLength!==H||he.numDirectionalShadows!==G||he.numPointShadows!==X||he.numSpotShadows!==se)&&(r.directional.length=T,r.spot.length=k,r.rectArea.length=A,r.point.length=N,r.hemi.length=H,r.directionalShadow.length=G,r.directionalShadowMap.length=G,r.pointShadow.length=X,r.pointShadowMap.length=X,r.spotShadow.length=se,r.spotShadowMap.length=se,r.directionalShadowMatrix.length=G,r.pointShadowMatrix.length=X,r.spotShadowMatrix.length=se,he.directionalLength=T,he.pointLength=N,he.spotLength=k,he.rectAreaLength=A,he.hemiLength=H,he.numDirectionalShadows=G,he.numPointShadows=X,he.numSpotShadows=se,r.version=Zce++)},setupView:function u(p,g){let v=0,y=0,x=0,T=0,N=0;const k=g.matrixWorldInverse;for(let A=0,H=p.length;A=t.get(s).length?(a=new c6(n,e),t.get(s).push(a)):a=t.get(s)[o],a},dispose:function r(){t=new WeakMap}}}class fI extends Co{constructor(e){super(),this.type="MeshDepthMaterial",this.depthPacking=3200,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.setValues(e)}copy(e){return super.copy(e),this.depthPacking=e.depthPacking,this.map=e.map,this.alphaMap=e.alphaMap,this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this}}fI.prototype.isMeshDepthMaterial=!0;class pI extends Co{constructor(e){super(),this.type="MeshDistanceMaterial",this.referencePosition=new ne,this.nearDistance=1,this.farDistance=1e3,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.fog=!1,this.setValues(e)}copy(e){return super.copy(e),this.referencePosition.copy(e.referencePosition),this.nearDistance=e.nearDistance,this.farDistance=e.farDistance,this.map=e.map,this.alphaMap=e.alphaMap,this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this}}pI.prototype.isMeshDistanceMaterial=!0;const tle="void main() {\n\tgl_Position = vec4( position, 1.0 );\n}",nle="uniform sampler2D shadow_pass;\nuniform vec2 resolution;\nuniform float radius;\n#include \nvoid main() {\n\tconst float samples = float( VSM_SAMPLES );\n\tfloat mean = 0.0;\n\tfloat squared_mean = 0.0;\n\tfloat uvStride = samples <= 1.0 ? 0.0 : 2.0 / ( samples - 1.0 );\n\tfloat uvStart = samples <= 1.0 ? 0.0 : - 1.0;\n\tfor ( float i = 0.0; i < samples; i ++ ) {\n\t\tfloat uvOffset = uvStart + i * uvStride;\n\t\t#ifdef HORIZONTAL_PASS\n\t\t\tvec2 distribution = unpackRGBATo2Half( texture2D( shadow_pass, ( gl_FragCoord.xy + vec2( uvOffset, 0.0 ) * radius ) / resolution ) );\n\t\t\tmean += distribution.x;\n\t\t\tsquared_mean += distribution.y * distribution.y + distribution.x * distribution.x;\n\t\t#else\n\t\t\tfloat depth = unpackRGBAToDepth( texture2D( shadow_pass, ( gl_FragCoord.xy + vec2( 0.0, uvOffset ) * radius ) / resolution ) );\n\t\t\tmean += depth;\n\t\t\tsquared_mean += depth * depth;\n\t\t#endif\n\t}\n\tmean = mean / samples;\n\tsquared_mean = squared_mean / samples;\n\tfloat std_dev = sqrt( squared_mean - mean * mean );\n\tgl_FragColor = pack2HalfToRGBA( vec2( mean, std_dev ) );\n}";function l6(n,e,t){let i=new w2;const r=new tt,s=new tt,o=new tr,a=new fI({depthPacking:Vre}),c=new pI,u={},p=t.maxTextureSize,g={0:Ds,1:Og,2:Lg},v=new wh({defines:{VSM_SAMPLES:8},uniforms:{shadow_pass:{value:null},resolution:{value:new tt},radius:{value:4}},vertexShader:tle,fragmentShader:nle}),y=v.clone();y.defines.HORIZONTAL_PASS=1;const x=new gn;x.setAttribute("position",new zi(new Float32Array([-1,-1,.5,3,-1,.5,-1,3,.5]),3));const T=new vr(x,v),N=this;function k(G,X){const se=e.update(T);v.defines.VSM_SAMPLES!==G.blurSamples&&(v.defines.VSM_SAMPLES=G.blurSamples,y.defines.VSM_SAMPLES=G.blurSamples,v.needsUpdate=!0,y.needsUpdate=!0),v.uniforms.shadow_pass.value=G.map.texture,v.uniforms.resolution.value=G.mapSize,v.uniforms.radius.value=G.radius,n.setRenderTarget(G.mapPass),n.clear(),n.renderBufferDirect(X,null,se,v,T,null),y.uniforms.shadow_pass.value=G.mapPass.texture,y.uniforms.resolution.value=G.mapSize,y.uniforms.radius.value=G.radius,n.setRenderTarget(G.map),n.clear(),n.renderBufferDirect(X,null,se,y,T,null)}function A(G,X,se,K,he,De,Te){let ge=null;const Qe=!0===K.isPointLight?G.customDistanceMaterial:G.customDepthMaterial;if(ge=void 0!==Qe?Qe:!0===K.isPointLight?c:a,n.localClippingEnabled&&!0===se.clipShadows&&0!==se.clippingPlanes.length||se.displacementMap&&0!==se.displacementScale||se.alphaMap&&se.alphaTest>0){const Pe=ge.uuid,Oe=se.uuid;let Ve=u[Pe];void 0===Ve&&(Ve={},u[Pe]=Ve);let ye=Ve[Oe];void 0===ye&&(ye=ge.clone(),Ve[Oe]=ye),ge=ye}return ge.visible=se.visible,ge.wireframe=se.wireframe,ge.side=Te===Ty?null!==se.shadowSide?se.shadowSide:se.side:null!==se.shadowSide?se.shadowSide:g[se.side],ge.alphaMap=se.alphaMap,ge.alphaTest=se.alphaTest,ge.clipShadows=se.clipShadows,ge.clippingPlanes=se.clippingPlanes,ge.clipIntersection=se.clipIntersection,ge.displacementMap=se.displacementMap,ge.displacementScale=se.displacementScale,ge.displacementBias=se.displacementBias,ge.wireframeLinewidth=se.wireframeLinewidth,ge.linewidth=se.linewidth,!0===K.isPointLight&&!0===ge.isMeshDistanceMaterial&&(ge.referencePosition.setFromMatrixPosition(K.matrixWorld),ge.nearDistance=he,ge.farDistance=De),ge}function H(G,X,se,K,he){if(!1===G.visible)return;if(G.layers.test(X.layers)&&(G.isMesh||G.isLine||G.isPoints)&&(G.castShadow||G.receiveShadow&&he===Ty)&&(!G.frustumCulled||i.intersectsObject(G))){G.modelViewMatrix.multiplyMatrices(se.matrixWorldInverse,G.matrixWorld);const ge=e.update(G),Qe=G.material;if(Array.isArray(Qe)){const Pe=ge.groups;for(let Oe=0,Ve=Pe.length;Oep||r.y>p)&&(r.x>p&&(s.x=Math.floor(p/Ve.x),r.x=s.x*Ve.x,Oe.mapSize.x=s.x),r.y>p&&(s.y=Math.floor(p/Ve.y),r.y=s.y*Ve.y,Oe.mapSize.y=s.y)),null===Oe.map&&!Oe.isPointLightShadow&&this.type===Ty){const Me={minFilter:no,magFilter:no,format:zo};Oe.map=new Bc(r.x,r.y,Me),Oe.map.texture.name=Pe.name+".shadowMap",Oe.mapPass=new Bc(r.x,r.y,Me),Oe.camera.updateProjectionMatrix()}null===Oe.map&&(Oe.map=new Bc(r.x,r.y,{minFilter:Gs,magFilter:Gs,format:zo}),Oe.map.texture.name=Pe.name+".shadowMap",Oe.camera.updateProjectionMatrix()),n.setRenderTarget(Oe.map),n.clear();const ye=Oe.getViewportCount();for(let Me=0;Me=1):-1!==Oe.indexOf("OpenGL ES")&&(Pe=parseFloat(/^OpenGL ES (\d)/.exec(Oe)[1]),Qe=Pe>=2);let Ve=null,ye={};const Me=n.getParameter(3088),je=n.getParameter(2978),lt=(new tr).fromArray(Me),ze=(new tr).fromArray(je);function Ke(Ce,St,at){const kt=new Uint8Array(4),Et=n.createTexture();n.bindTexture(Ce,Et),n.texParameteri(Ce,10241,9728),n.texParameteri(Ce,10240,9728);for(let zt=0;ztst||fe.height>st)&&(Kt=st/Math.max(fe.width,fe.height)),Kt<1||!0===ae){if(typeof HTMLImageElement<"u"&&fe instanceof HTMLImageElement||typeof HTMLCanvasElement<"u"&&fe instanceof HTMLCanvasElement||typeof ImageBitmap<"u"&&fe instanceof ImageBitmap){const Wt=ae?fB:Math.floor,Ce=Wt(Kt*fe.width),St=Wt(Kt*fe.height);void 0===T&&(T=k(Ce,St));const at=ot?k(Ce,St):T;return at.width=Ce,at.height=St,at.getContext("2d").drawImage(fe,0,0,Ce,St),console.warn("THREE.WebGLRenderer: Texture has been resized from ("+fe.width+"x"+fe.height+") to ("+Ce+"x"+St+")."),at}return"data"in fe&&console.warn("THREE.WebGLRenderer: Image in DataTexture is too big ("+fe.width+"x"+fe.height+")."),fe}return fe}function H(fe){return Ik(fe.width)&&Ik(fe.height)}function X(fe,ae){return fe.generateMipmaps&&ae&&fe.minFilter!==Gs&&fe.minFilter!==no}function se(fe){n.generateMipmap(fe)}function K(fe,ae,ot){if(!1===a)return ae;if(null!==fe){if(void 0!==n[fe])return n[fe];console.warn("THREE.WebGLRenderer: Attempt to use non-existing WebGL internal format '"+fe+"'")}let st=ae;return 6403===ae&&(5126===ot&&(st=33326),5131===ot&&(st=33325),5121===ot&&(st=33321)),6407===ae&&(5126===ot&&(st=34837),5131===ot&&(st=34843),5121===ot&&(st=32849)),6408===ae&&(5126===ot&&(st=34836),5131===ot&&(st=34842),5121===ot&&(st=32856)),(33325===st||33326===st||34842===st||34836===st)&&e.get("EXT_color_buffer_float"),st}function De(fe){return fe===Gs||fe===Sk||fe===Ek?9728:9729}function Te(fe){const ae=fe.target;ae.removeEventListener("dispose",Te),function Qe(fe){const ae=i.get(fe);void 0!==ae.__webglInit&&(n.deleteTexture(ae.__webglTexture),i.remove(fe))}(ae),ae.isVideoTexture&&x.delete(ae),o.memory.textures--}function ge(fe){const ae=fe.target;ae.removeEventListener("dispose",ge),function Pe(fe){const ae=fe.texture,ot=i.get(fe),st=i.get(ae);if(fe){if(void 0!==st.__webglTexture&&(n.deleteTexture(st.__webglTexture),o.memory.textures--),fe.depthTexture&&fe.depthTexture.dispose(),fe.isWebGLCubeRenderTarget)for(let Kt=0;Kt<6;Kt++)n.deleteFramebuffer(ot.__webglFramebuffer[Kt]),ot.__webglDepthbuffer&&n.deleteRenderbuffer(ot.__webglDepthbuffer[Kt]);else n.deleteFramebuffer(ot.__webglFramebuffer),ot.__webglDepthbuffer&&n.deleteRenderbuffer(ot.__webglDepthbuffer),ot.__webglMultisampledFramebuffer&&n.deleteFramebuffer(ot.__webglMultisampledFramebuffer),ot.__webglColorRenderbuffer&&n.deleteRenderbuffer(ot.__webglColorRenderbuffer),ot.__webglDepthRenderbuffer&&n.deleteRenderbuffer(ot.__webglDepthRenderbuffer);if(fe.isWebGLMultipleRenderTargets)for(let Kt=0,Wt=ae.length;Kt0&&ot.__version!==fe.version){const st=fe.image;if(void 0===st)console.warn("THREE.WebGLRenderer: Texture marked for update but image is undefined");else{if(!1!==st.complete)return void mi(ot,fe,ae);console.warn("THREE.WebGLRenderer: Texture marked for update but image is incomplete")}}t.activeTexture(33984+ae),t.bindTexture(3553,ot.__webglTexture)}function ze(fe,ae){const ot=i.get(fe);fe.version>0&&ot.__version!==fe.version?function ct(fe,ae,ot){if(6!==ae.image.length)return;gt(fe,ae),t.activeTexture(33984+ot),t.bindTexture(34067,fe.__webglTexture),n.pixelStorei(37440,ae.flipY),n.pixelStorei(37441,ae.premultiplyAlpha),n.pixelStorei(3317,ae.unpackAlignment),n.pixelStorei(37443,0);const st=ae&&(ae.isCompressedTexture||ae.image[0].isCompressedTexture),Kt=ae.image[0]&&ae.image[0].isDataTexture,Wt=[];for(let Yt=0;Yt<6;Yt++)Wt[Yt]=st||Kt?Kt?ae.image[Yt].image:ae.image[Yt]:A(ae.image[Yt],!1,!0,u);const St=H(Wt[0])||a,at=s.convert(ae.format),kt=s.convert(ae.type),Et=K(ae.internalFormat,at,kt);let zt;if(yt(34067,ae,St),st)for(let Yt=0;Yt<6;Yt++){zt=Wt[Yt].mipmaps;for(let ni=0;ni1||i.get(ae).__currentAnisotropy)&&(n.texParameterf(fe,st.TEXTURE_MAX_ANISOTROPY_EXT,Math.min(ae.anisotropy,r.getMaxAnisotropy())),i.get(ae).__currentAnisotropy=ae.anisotropy)}}function gt(fe,ae){void 0===fe.__webglInit&&(fe.__webglInit=!0,ae.addEventListener("dispose",Te),fe.__webglTexture=n.createTexture(),o.memory.textures++)}function mi(fe,ae,ot){let st=3553;ae.isDataTexture2DArray&&(st=35866),ae.isDataTexture3D&&(st=32879),gt(fe,ae),t.activeTexture(33984+ot),t.bindTexture(st,fe.__webglTexture),n.pixelStorei(37440,ae.flipY),n.pixelStorei(37441,ae.premultiplyAlpha),n.pixelStorei(3317,ae.unpackAlignment),n.pixelStorei(37443,0);const Kt=function G(fe){return!a&&(fe.wrapS!==Uo||fe.wrapT!==Uo||fe.minFilter!==Gs&&fe.minFilter!==no)}(ae)&&!1===H(ae.image),Wt=A(ae.image,Kt,!1,p),Ce=H(Wt)||a,St=s.convert(ae.format);let Et,at=s.convert(ae.type),kt=K(ae.internalFormat,St,at);yt(st,ae,Ce);const zt=ae.mipmaps;if(ae.isDepthTexture)kt=6402,a?kt=ae.type===Yd?36012:ae.type===XS?33190:ae.type===zg?35056:33189:ae.type===Yd&&console.error("WebGLRenderer: Floating point depth texture requires WebGL2."),ae.format===tp&&6402===kt&&ae.type!==Iy&&ae.type!==XS&&(console.warn("THREE.WebGLRenderer: Use UnsignedShortType or UnsignedIntType for DepthFormat DepthTexture."),ae.type=Iy,at=s.convert(ae.type)),ae.format===Gg&&6402===kt&&(kt=34041,ae.type!==zg&&(console.warn("THREE.WebGLRenderer: Use UnsignedInt248Type for DepthStencilFormat DepthTexture."),ae.type=zg,at=s.convert(ae.type))),t.texImage2D(3553,0,kt,Wt.width,Wt.height,0,St,at,null);else if(ae.isDataTexture)if(zt.length>0&&Ce){for(let Yt=0,ni=zt.length;Yt0?fe.mipmaps.length:1}(ae,Wt,Ce),ni=a&&!0!==ae.isVideoTexture,fs=void 0===fe.__version;if(zt.length>0&&Ce){ni&&fs&&t.texStorage2D(3553,Yt,kt,zt[0].width,zt[0].height);for(let Gi=0,bl=zt.length;Gi=c&&console.warn("THREE.WebGLTextures: Trying to use "+fe+" texture units while this GPU supports only "+c),Oe+=1,fe},this.resetTextureUnits=function Ve(){Oe=0},this.setTexture2D=Me,this.setTexture2DArray=function je(fe,ae){const ot=i.get(fe);fe.version>0&&ot.__version!==fe.version?mi(ot,fe,ae):(t.activeTexture(33984+ae),t.bindTexture(35866,ot.__webglTexture))},this.setTexture3D=function lt(fe,ae){const ot=i.get(fe);fe.version>0&&ot.__version!==fe.version?mi(ot,fe,ae):(t.activeTexture(33984+ae),t.bindTexture(32879,ot.__webglTexture))},this.setTextureCube=ze,this.rebindTextures=function gi(fe,ae,ot){const st=i.get(fe);void 0!==ae&&Qt(st.__webglFramebuffer,fe,fe.texture,36064,3553),void 0!==ot&&on(fe)},this.setupRenderTarget=function Xe(fe){const ae=fe.texture,ot=i.get(fe),st=i.get(ae);fe.addEventListener("dispose",ge),!0!==fe.isWebGLMultipleRenderTargets&&(void 0===st.__webglTexture&&(st.__webglTexture=n.createTexture()),st.__version=ae.version,o.memory.textures++);const Kt=!0===fe.isWebGLCubeRenderTarget,Wt=!0===fe.isWebGLMultipleRenderTargets,Ce=ae.isDataTexture3D||ae.isDataTexture2DArray,St=H(fe)||a;if(a&&ae.format===ep&&(ae.type===Yd||ae.type===Ug)&&(ae.format=zo,console.warn("THREE.WebGLRenderer: Rendering to textures with RGB format is not supported. Using RGBA format instead.")),Kt){ot.__webglFramebuffer=[];for(let at=0;at<6;at++)ot.__webglFramebuffer[at]=n.createFramebuffer()}else if(ot.__webglFramebuffer=n.createFramebuffer(),Wt)if(r.drawBuffers){const at=fe.texture;for(let kt=0,Et=at.length;kty+x?(u.inputState.pinching=!1,this.dispatchEvent({type:"pinchend",handedness:e.handedness,target:this})):!u.inputState.pinching&&v<=y-x&&(u.inputState.pinching=!0,this.dispatchEvent({type:"pinchstart",handedness:e.handedness,target:this}))}else null!==c&&e.gripSpace&&(s=t.getPose(e.gripSpace,i),null!==s&&(c.matrix.fromArray(s.transform.matrix),c.matrix.decompose(c.position,c.rotation,c.scale),s.linearVelocity?(c.hasLinearVelocity=!0,c.linearVelocity.copy(s.linearVelocity)):c.hasLinearVelocity=!1,s.angularVelocity?(c.hasAngularVelocity=!0,c.angularVelocity.copy(s.angularVelocity)):c.hasAngularVelocity=!1));return null!==a&&(a.visible=null!==r),null!==c&&(c.visible=null!==s),null!==u&&(u.visible=null!==o),this}}class gI extends io{constructor(e,t,i,r,s,o,a,c,u,p){if((p=void 0!==p?p:tp)!==tp&&p!==Gg)throw new Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");void 0===i&&p===tp&&(i=Iy),void 0===i&&p===Gg&&(i=zg),super(null,r,s,o,a,c,p,i,u),this.image={width:e,height:t},this.magFilter=void 0!==a?a:Gs,this.minFilter=void 0!==c?c:Gs,this.flipY=!1,this.generateMipmaps=!1}}gI.prototype.isDepthTexture=!0;class ale extends np{constructor(e,t){super();const i=this;let r=null,s=1,o=null,a="local-floor";const c=e.extensions.has("WEBGL_multisampled_render_to_texture");let u=null,p=null,g=null,v=null,y=!1,x=null;const T=t.getContextAttributes();let N=null,k=null;const A=[],H=new Map,G=new Do;G.layers.enable(1),G.viewport=new tr;const X=new Do;X.layers.enable(2),X.viewport=new tr;const se=[G,X],K=new d6;K.layers.enable(1),K.layers.enable(2);let he=null,De=null;function Te(ze){const Ke=H.get(ze.inputSource);Ke&&Ke.dispatchEvent({type:ze.type,data:ze.inputSource})}function ge(){H.forEach(function(ze,Ke){ze.disconnect(Ke)}),H.clear(),he=null,De=null,e.setRenderTarget(N),v=null,g=null,p=null,r=null,k=null,lt.stop(),i.isPresenting=!1,i.dispatchEvent({type:"sessionend"})}function Qe(ze){const Ke=r.inputSources;for(let vt=0;vt0&&(k.alphaTest.value=A.alphaTest);const H=n.get(A).envMap;let G,X;H&&(k.envMap.value=H,k.flipEnvMap.value=H.isCubeTexture&&!1===H.isRenderTargetTexture?-1:1,k.reflectivity.value=A.reflectivity,k.ior.value=A.ior,k.refractionRatio.value=A.refractionRatio),A.lightMap&&(k.lightMap.value=A.lightMap,k.lightMapIntensity.value=A.lightMapIntensity),A.aoMap&&(k.aoMap.value=A.aoMap,k.aoMapIntensity.value=A.aoMapIntensity),A.map?G=A.map:A.specularMap?G=A.specularMap:A.displacementMap?G=A.displacementMap:A.normalMap?G=A.normalMap:A.bumpMap?G=A.bumpMap:A.roughnessMap?G=A.roughnessMap:A.metalnessMap?G=A.metalnessMap:A.alphaMap?G=A.alphaMap:A.emissiveMap?G=A.emissiveMap:A.clearcoatMap?G=A.clearcoatMap:A.clearcoatNormalMap?G=A.clearcoatNormalMap:A.clearcoatRoughnessMap?G=A.clearcoatRoughnessMap:A.specularIntensityMap?G=A.specularIntensityMap:A.specularColorMap?G=A.specularColorMap:A.transmissionMap?G=A.transmissionMap:A.thicknessMap?G=A.thicknessMap:A.sheenColorMap?G=A.sheenColorMap:A.sheenRoughnessMap&&(G=A.sheenRoughnessMap),void 0!==G&&(G.isWebGLRenderTarget&&(G=G.texture),!0===G.matrixAutoUpdate&&G.updateMatrix(),k.uvTransform.value.copy(G.matrix)),A.aoMap?X=A.aoMap:A.lightMap&&(X=A.lightMap),void 0!==X&&(X.isWebGLRenderTarget&&(X=X.texture),!0===X.matrixAutoUpdate&&X.updateMatrix(),k.uv2Transform.value.copy(X.matrix))}function g(k,A){k.roughness.value=A.roughness,k.metalness.value=A.metalness,A.roughnessMap&&(k.roughnessMap.value=A.roughnessMap),A.metalnessMap&&(k.metalnessMap.value=A.metalnessMap),A.emissiveMap&&(k.emissiveMap.value=A.emissiveMap),A.bumpMap&&(k.bumpMap.value=A.bumpMap,k.bumpScale.value=A.bumpScale,A.side===Ds&&(k.bumpScale.value*=-1)),A.normalMap&&(k.normalMap.value=A.normalMap,k.normalScale.value.copy(A.normalScale),A.side===Ds&&k.normalScale.value.negate()),A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias),n.get(A).envMap&&(k.envMapIntensity.value=A.envMapIntensity)}return{refreshFogUniforms:function e(k,A){k.fogColor.value.copy(A.color),A.isFog?(k.fogNear.value=A.near,k.fogFar.value=A.far):A.isFogExp2&&(k.fogDensity.value=A.density)},refreshMaterialUniforms:function t(k,A,H,G,X){A.isMeshBasicMaterial?i(k,A):A.isMeshLambertMaterial?(i(k,A),function c(k,A){A.emissiveMap&&(k.emissiveMap.value=A.emissiveMap)}(k,A)):A.isMeshToonMaterial?(i(k,A),function p(k,A){A.gradientMap&&(k.gradientMap.value=A.gradientMap),A.emissiveMap&&(k.emissiveMap.value=A.emissiveMap),A.bumpMap&&(k.bumpMap.value=A.bumpMap,k.bumpScale.value=A.bumpScale,A.side===Ds&&(k.bumpScale.value*=-1)),A.normalMap&&(k.normalMap.value=A.normalMap,k.normalScale.value.copy(A.normalScale),A.side===Ds&&k.normalScale.value.negate()),A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias)}(k,A)):A.isMeshPhongMaterial?(i(k,A),function u(k,A){k.specular.value.copy(A.specular),k.shininess.value=Math.max(A.shininess,1e-4),A.emissiveMap&&(k.emissiveMap.value=A.emissiveMap),A.bumpMap&&(k.bumpMap.value=A.bumpMap,k.bumpScale.value=A.bumpScale,A.side===Ds&&(k.bumpScale.value*=-1)),A.normalMap&&(k.normalMap.value=A.normalMap,k.normalScale.value.copy(A.normalScale),A.side===Ds&&k.normalScale.value.negate()),A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias)}(k,A)):A.isMeshStandardMaterial?(i(k,A),A.isMeshPhysicalMaterial?function v(k,A,H){g(k,A),k.ior.value=A.ior,A.sheen>0&&(k.sheenColor.value.copy(A.sheenColor).multiplyScalar(A.sheen),k.sheenRoughness.value=A.sheenRoughness,A.sheenColorMap&&(k.sheenColorMap.value=A.sheenColorMap),A.sheenRoughnessMap&&(k.sheenRoughnessMap.value=A.sheenRoughnessMap)),A.clearcoat>0&&(k.clearcoat.value=A.clearcoat,k.clearcoatRoughness.value=A.clearcoatRoughness,A.clearcoatMap&&(k.clearcoatMap.value=A.clearcoatMap),A.clearcoatRoughnessMap&&(k.clearcoatRoughnessMap.value=A.clearcoatRoughnessMap),A.clearcoatNormalMap&&(k.clearcoatNormalScale.value.copy(A.clearcoatNormalScale),k.clearcoatNormalMap.value=A.clearcoatNormalMap,A.side===Ds&&k.clearcoatNormalScale.value.negate())),A.transmission>0&&(k.transmission.value=A.transmission,k.transmissionSamplerMap.value=H.texture,k.transmissionSamplerSize.value.set(H.width,H.height),A.transmissionMap&&(k.transmissionMap.value=A.transmissionMap),k.thickness.value=A.thickness,A.thicknessMap&&(k.thicknessMap.value=A.thicknessMap),k.attenuationDistance.value=A.attenuationDistance,k.attenuationColor.value.copy(A.attenuationColor)),k.specularIntensity.value=A.specularIntensity,k.specularColor.value.copy(A.specularColor),A.specularIntensityMap&&(k.specularIntensityMap.value=A.specularIntensityMap),A.specularColorMap&&(k.specularColorMap.value=A.specularColorMap)}(k,A,X):g(k,A)):A.isMeshMatcapMaterial?(i(k,A),function y(k,A){A.matcap&&(k.matcap.value=A.matcap),A.bumpMap&&(k.bumpMap.value=A.bumpMap,k.bumpScale.value=A.bumpScale,A.side===Ds&&(k.bumpScale.value*=-1)),A.normalMap&&(k.normalMap.value=A.normalMap,k.normalScale.value.copy(A.normalScale),A.side===Ds&&k.normalScale.value.negate()),A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias)}(k,A)):A.isMeshDepthMaterial?(i(k,A),function x(k,A){A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias)}(k,A)):A.isMeshDistanceMaterial?(i(k,A),function T(k,A){A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias),k.referencePosition.value.copy(A.referencePosition),k.nearDistance.value=A.nearDistance,k.farDistance.value=A.farDistance}(k,A)):A.isMeshNormalMaterial?(i(k,A),function N(k,A){A.bumpMap&&(k.bumpMap.value=A.bumpMap,k.bumpScale.value=A.bumpScale,A.side===Ds&&(k.bumpScale.value*=-1)),A.normalMap&&(k.normalMap.value=A.normalMap,k.normalScale.value.copy(A.normalScale),A.side===Ds&&k.normalScale.value.negate()),A.displacementMap&&(k.displacementMap.value=A.displacementMap,k.displacementScale.value=A.displacementScale,k.displacementBias.value=A.displacementBias)}(k,A)):A.isLineBasicMaterial?(function r(k,A){k.diffuse.value.copy(A.color),k.opacity.value=A.opacity}(k,A),A.isLineDashedMaterial&&function s(k,A){k.dashSize.value=A.dashSize,k.totalSize.value=A.dashSize+A.gapSize,k.scale.value=A.scale}(k,A)):A.isPointsMaterial?function o(k,A,H,G){let X;k.diffuse.value.copy(A.color),k.opacity.value=A.opacity,k.size.value=A.size*H,k.scale.value=.5*G,A.map&&(k.map.value=A.map),A.alphaMap&&(k.alphaMap.value=A.alphaMap),A.alphaTest>0&&(k.alphaTest.value=A.alphaTest),A.map?X=A.map:A.alphaMap&&(X=A.alphaMap),void 0!==X&&(!0===X.matrixAutoUpdate&&X.updateMatrix(),k.uvTransform.value.copy(X.matrix))}(k,A,H,G):A.isSpriteMaterial?function a(k,A){let H;k.diffuse.value.copy(A.color),k.opacity.value=A.opacity,k.rotation.value=A.rotation,A.map&&(k.map.value=A.map),A.alphaMap&&(k.alphaMap.value=A.alphaMap),A.alphaTest>0&&(k.alphaTest.value=A.alphaTest),A.map?H=A.map:A.alphaMap&&(H=A.alphaMap),void 0!==H&&(!0===H.matrixAutoUpdate&&H.updateMatrix(),k.uvTransform.value.copy(H.matrix))}(k,A):A.isShadowMaterial?(k.color.value.copy(A.color),k.opacity.value=A.opacity):A.isShaderMaterial&&(A.uniformsNeedUpdate=!1)}}}function nr(n={}){const e=void 0!==n.canvas?n.canvas:function lle(){const n=n2("canvas");return n.style.display="block",n}(),t=void 0!==n.context?n.context:null,i=void 0!==n.alpha&&n.alpha,r=void 0===n.depth||n.depth,s=void 0===n.stencil||n.stencil,o=void 0!==n.antialias&&n.antialias,a=void 0===n.premultipliedAlpha||n.premultipliedAlpha,c=void 0!==n.preserveDrawingBuffer&&n.preserveDrawingBuffer,u=void 0!==n.powerPreference?n.powerPreference:"default",p=void 0!==n.failIfMajorPerformanceCaveat&&n.failIfMajorPerformanceCaveat;let g=null,v=null;const y=[],x=[];this.domElement=e,this.debug={checkShaderErrors:!0},this.autoClear=!0,this.autoClearColor=!0,this.autoClearDepth=!0,this.autoClearStencil=!0,this.sortObjects=!0,this.clippingPlanes=[],this.localClippingEnabled=!1,this.gammaFactor=2,this.outputEncoding=Ma,this.physicallyCorrectLights=!1,this.toneMapping=Qf,this.toneMappingExposure=1;const T=this;let N=!1,k=0,A=0,H=null,G=-1,X=null;const se=new tr,K=new tr;let he=null,De=e.width,Te=e.height,ge=1,Qe=null,Pe=null;const Oe=new tr(0,0,De,Te),Ve=new tr(0,0,De,Te);let ye=!1;const Me=[],je=new w2;let lt=!1,ze=!1,Ke=null;const vt=new Gt,yt=new ne,gt={background:null,fog:null,environment:null,overrideMaterial:null,isScene:!0};function mi(){return null===H?ge:1}let sn,It,on,gi,Xe,ht,bt,Vt,At,Wn,$n,xi,xr,fe,ae,ot,st,Kt,Wt,Ce,St,at,kt,ct=t;function Qt(oe,Re){for(let We=0;We0&&function Cue(oe,Re,We){null===Ke&&(Ke=new(!0===o&&!0===It.isWebGL2?Rk:Bc)(1024,1024,{generateMipmaps:!0,type:null!==at.convert(Ug)?Ug:fh,minFilter:Hg,magFilter:Gs,wrapS:Uo,wrapT:Uo,useRenderToTexture:sn.has("WEBGL_multisampled_render_to_texture")}));const Be=T.getRenderTarget();T.setRenderTarget(Ke),T.clear();const et=T.toneMapping;T.toneMapping=Qf,bE(oe,Re,We),T.toneMapping=et,ht.updateMultisampleRenderTarget(Ke),ht.updateRenderTargetMipmap(Ke),T.setRenderTarget(Be)}(et,Re,We),Be&&on.viewport(se.copy(Be)),et.length>0&&bE(et,Re,We),Bn.length>0&&bE(Bn,Re,We),xn.length>0&&bE(xn,Re,We)}function bE(oe,Re,We){const Be=!0===Re.isScene?Re.overrideMaterial:null;for(let et=0,Bn=oe.length;et0?x[x.length-1]:null,y.pop(),g=y.length>0?y[y.length-1]:null}}else console.error("THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.")},this.getActiveCubeFace=function(){return k},this.getActiveMipmapLevel=function(){return A},this.getRenderTarget=function(){return H},this.setRenderTargetTextures=function(oe,Re,We){Xe.get(oe.texture).__webglTexture=Re,Xe.get(oe.depthTexture).__webglTexture=We;const Be=Xe.get(oe);Be.__hasExternalTextures=!0,Be.__hasExternalTextures&&(Be.__autoAllocateDepthBuffer=void 0===We,Be.__autoAllocateDepthBuffer||oe.useRenderToTexture&&(console.warn("render-to-texture extension was disabled because an external texture was provided"),oe.useRenderToTexture=!1,oe.useRenderbuffer=!0))},this.setRenderTargetFramebuffer=function(oe,Re){const We=Xe.get(oe);We.__webglFramebuffer=Re,We.__useDefaultFramebuffer=void 0===Re},this.setRenderTarget=function(oe,Re=0,We=0){H=oe,k=Re,A=We;let Be=!0;if(oe){const Vn=Xe.get(oe);void 0!==Vn.__useDefaultFramebuffer?(on.bindFramebuffer(36160,null),Be=!1):void 0===Vn.__webglFramebuffer?ht.setupRenderTarget(oe):Vn.__hasExternalTextures&&ht.rebindTextures(oe,Xe.get(oe.texture).__webglTexture,Xe.get(oe.depthTexture).__webglTexture)}let et=null,Bn=!1,xn=!1;if(oe){const Vn=oe.texture;(Vn.isDataTexture3D||Vn.isDataTexture2DArray)&&(xn=!0);const Li=Xe.get(oe).__webglFramebuffer;oe.isWebGLCubeRenderTarget?(et=Li[Re],Bn=!0):et=oe.useRenderbuffer?Xe.get(oe).__webglMultisampledFramebuffer:Li,se.copy(oe.viewport),K.copy(oe.scissor),he=oe.scissorTest}else se.copy(Oe).multiplyScalar(ge).floor(),K.copy(Ve).multiplyScalar(ge).floor(),he=ye;if(on.bindFramebuffer(36160,et)&&It.drawBuffers&&Be){let Vn=!1;if(oe)if(oe.isWebGLMultipleRenderTargets){const Li=oe.texture;if(Me.length!==Li.length||36064!==Me[0]){for(let li=0,Ai=Li.length;li=0&&Re<=oe.width-Be&&We>=0&&We<=oe.height-et&&ct.readPixels(Re,We,Be,et,at.convert(Li),at.convert(li),Bn):console.error("THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete.")}finally{const Vn=null!==H?Xe.get(H).__webglFramebuffer:null;on.bindFramebuffer(36160,Vn)}}},this.copyFramebufferToTexture=function(oe,Re,We=0){const Be=Math.pow(2,-We),et=Math.floor(Re.image.width*Be),Bn=Math.floor(Re.image.height*Be);let xn=at.convert(Re.format);It.isWebGL2&&(6407===xn&&(xn=32849),6408===xn&&(xn=32856)),ht.setTexture2D(Re,0),ct.copyTexImage2D(3553,We,xn,oe.x,oe.y,et,Bn,0),on.unbindTexture()},this.copyTextureToTexture=function(oe,Re,We,Be=0){const et=Re.image.width,Bn=Re.image.height,xn=at.convert(We.format),ci=at.convert(We.type);ht.setTexture2D(We,0),ct.pixelStorei(37440,We.flipY),ct.pixelStorei(37441,We.premultiplyAlpha),ct.pixelStorei(3317,We.unpackAlignment),Re.isDataTexture?ct.texSubImage2D(3553,Be,oe.x,oe.y,et,Bn,xn,ci,Re.image.data):Re.isCompressedTexture?ct.compressedTexSubImage2D(3553,Be,oe.x,oe.y,Re.mipmaps[0].width,Re.mipmaps[0].height,xn,Re.mipmaps[0].data):ct.texSubImage2D(3553,Be,oe.x,oe.y,xn,ci,Re.image),0===Be&&We.generateMipmaps&&ct.generateMipmap(3553),on.unbindTexture()},this.copyTextureToTexture3D=function(oe,Re,We,Be,et=0){if(T.isWebGL1Renderer)return void console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: can only be used with WebGL2.");const Bn=oe.max.x-oe.min.x+1,xn=oe.max.y-oe.min.y+1,ci=oe.max.z-oe.min.z+1,Vn=at.convert(Be.format),Li=at.convert(Be.type);let li;if(Be.isDataTexture3D)ht.setTexture3D(Be,0),li=32879;else{if(!Be.isDataTexture2DArray)return void console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: only supports THREE.DataTexture3D and THREE.DataTexture2DArray.");ht.setTexture2DArray(Be,0),li=35866}ct.pixelStorei(37440,Be.flipY),ct.pixelStorei(37441,Be.premultiplyAlpha),ct.pixelStorei(3317,Be.unpackAlignment);const Ai=ct.getParameter(3314),Wr=ct.getParameter(32878),bp=ct.getParameter(3316),ji=ct.getParameter(3315),db=ct.getParameter(32877),wr=We.isCompressedTexture?We.mipmaps[0]:We.image;ct.pixelStorei(3314,wr.width),ct.pixelStorei(32878,wr.height),ct.pixelStorei(3316,oe.min.x),ct.pixelStorei(3315,oe.min.y),ct.pixelStorei(32877,oe.min.z),We.isDataTexture||We.isDataTexture3D?ct.texSubImage3D(li,et,Re.x,Re.y,Re.z,Bn,xn,ci,Vn,Li,wr.data):We.isCompressedTexture?(console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: untested support for compressed srcTexture."),ct.compressedTexSubImage3D(li,et,Re.x,Re.y,Re.z,Bn,xn,ci,Vn,wr.data)):ct.texSubImage3D(li,et,Re.x,Re.y,Re.z,Bn,xn,ci,Vn,Li,wr),ct.pixelStorei(3314,Ai),ct.pixelStorei(32878,Wr),ct.pixelStorei(3316,bp),ct.pixelStorei(3315,ji),ct.pixelStorei(32877,db),0===et&&Be.generateMipmaps&&ct.generateMipmap(li),on.unbindTexture()},this.initTexture=function(oe){ht.setTexture2D(oe,0),on.unbindTexture()},this.resetState=function(){k=0,A=0,H=null,on.reset(),kt.reset()},typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}nr.prototype.isWebGLRenderer=!0,class dle extends nr{}.prototype.isWebGL1Renderer=!0;class D2{constructor(e,t=25e-5){this.name="",this.color=new Rt(e),this.density=t}clone(){return new D2(this.color,this.density)}toJSON(){return{type:"FogExp2",color:this.color.getHex(),density:this.density}}}D2.prototype.isFogExp2=!0;class T2{constructor(e,t=1,i=1e3){this.name="",this.color=new Rt(e),this.near=t,this.far=i}clone(){return new T2(this.color,this.near,this.far)}toJSON(){return{type:"Fog",color:this.color.getHex(),near:this.near,far:this.far}}}T2.prototype.isFog=!0;class A2 extends qi{constructor(){super(),this.type="Scene",this.background=null,this.environment=null,this.fog=null,this.overrideMaterial=null,this.autoUpdate=!0,typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}copy(e,t){return super.copy(e,t),null!==e.background&&(this.background=e.background.clone()),null!==e.environment&&(this.environment=e.environment.clone()),null!==e.fog&&(this.fog=e.fog.clone()),null!==e.overrideMaterial&&(this.overrideMaterial=e.overrideMaterial.clone()),this.autoUpdate=e.autoUpdate,this.matrixAutoUpdate=e.matrixAutoUpdate,this}toJSON(e){const t=super.toJSON(e);return null!==this.fog&&(t.object.fog=this.fog.toJSON()),t}}A2.prototype.isScene=!0;class g0{constructor(e,t){this.array=e,this.stride=t,this.count=void 0!==e?e.length/t:0,this.usage=Fy,this.updateRange={offset:0,count:-1},this.version=0,this.uuid=rc()}onUploadCallback(){}set needsUpdate(e){!0===e&&this.version++}setUsage(e){return this.usage=e,this}copy(e){return this.array=new e.array.constructor(e.array),this.count=e.count,this.stride=e.stride,this.usage=e.usage,this}copyAt(e,t,i){e*=this.stride,i*=t.stride;for(let r=0,s=this.stride;re.far||t.push({distance:c,point:Wy.clone(),uv:Ts.getUV(Wy,k2,qy,I2,h6,vI,f6,new tt),face:null,object:this})}copy(e){return super.copy(e),void 0!==e.center&&this.center.copy(e.center),this.material=e.material,this}}).prototype.isSprite=!0;const m6=new ne,g6=new tr,_6=new tr,hle=new ne,v6=new Gt;class bI extends vr{constructor(e,t){super(e,t),this.type="SkinnedMesh",this.bindMode="attached",this.bindMatrix=new Gt,this.bindMatrixInverse=new Gt}copy(e){return super.copy(e),this.bindMode=e.bindMode,this.bindMatrix.copy(e.bindMatrix),this.bindMatrixInverse.copy(e.bindMatrixInverse),this.skeleton=e.skeleton,this}bind(e,t){this.skeleton=e,void 0===t&&(this.updateMatrixWorld(!0),this.skeleton.calculateInverses(),t=this.matrixWorld),this.bindMatrix.copy(t),this.bindMatrixInverse.copy(t).invert()}pose(){this.skeleton.pose()}normalizeSkinWeights(){const e=new tr,t=this.geometry.attributes.skinWeight;for(let i=0,r=t.count;ic)continue;v.applyMatrix4(this.matrixWorld);const he=e.ray.origin.distanceTo(v);hee.far||t.push({distance:he,point:g.clone().applyMatrix4(this.matrixWorld),index:H,face:null,faceIndex:null,object:this})}else for(let H=Math.max(0,o.start),G=Math.min(N.count,o.start+o.count)-1;Hc)continue;v.applyMatrix4(this.matrixWorld);const se=e.ray.origin.distanceTo(v);see.far||t.push({distance:se,point:g.clone().applyMatrix4(this.matrixWorld),index:H,face:null,faceIndex:null,object:this})}}else i.isGeometry&&console.error("THREE.Line.raycast() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}updateMorphTargets(){const e=this.geometry;if(e.isBufferGeometry){const t=e.morphAttributes,i=Object.keys(t);if(i.length>0){const r=t[i[0]];if(void 0!==r){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Line.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}}}hp.prototype.isLine=!0;const C6=new ne,D6=new ne;class Mh extends hp{constructor(e,t){super(e,t),this.type="LineSegments"}computeLineDistances(){const e=this.geometry;if(e.isBufferGeometry)if(null===e.index){const t=e.attributes.position,i=[];for(let r=0,s=t.count;rr.far)return;s.push({distance:u,distanceToRay:Math.sqrt(a),point:c,index:e,face:null,object:o})}}(class B2 extends qi{constructor(e=new gn,t=new S0){super(),this.type="Points",this.geometry=e,this.material=t,this.updateMorphTargets()}copy(e){return super.copy(e),this.material=e.material,this.geometry=e.geometry,this}raycast(e,t){const i=this.geometry,r=this.matrixWorld,s=e.params.Points.threshold,o=i.drawRange;if(null===i.boundingSphere&&i.computeBoundingSphere(),L2.copy(i.boundingSphere),L2.applyMatrix4(r),L2.radius+=s,!1===e.ray.intersectsSphere(L2))return;A6.copy(r).invert(),EI.copy(e.ray).applyMatrix4(A6);const a=s/((this.scale.x+this.scale.y+this.scale.z)/3),c=a*a;if(i.isBufferGeometry){const u=i.index,g=i.attributes.position;if(null!==u)for(let x=Math.max(0,o.start),T=Math.min(u.count,o.start+o.count);x0){const r=t[i[0]];if(void 0!==r){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Points.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}}}).prototype.isPoints=!0,class ple extends io{constructor(e,t,i,r,s,o,a,c,u){super(e,t,i,r,s,o,a,c,u),this.format=void 0!==a?a:ep,this.minFilter=void 0!==o?o:no,this.magFilter=void 0!==s?s:no,this.generateMipmaps=!1;const p=this;"requestVideoFrameCallback"in e&&e.requestVideoFrameCallback(function g(){p.needsUpdate=!0,e.requestVideoFrameCallback(g)})}clone(){return new this.constructor(this.image).copy(this)}update(){const e=this.image;"requestVideoFrameCallback"in e==0&&e.readyState>=e.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}}.prototype.isVideoTexture=!0;(class I6 extends io{constructor(e,t,i,r,s,o,a,c,u,p,g,v){super(null,o,a,c,u,p,r,s,g,v),this.image={width:t,height:i},this.mipmaps=e,this.flipY=!1,this.generateMipmaps=!1}}).prototype.isCompressedTexture=!0,class mle extends io{constructor(e,t,i,r,s,o,a,c,u){super(e,t,i,r,s,o,a,c,u),this.needsUpdate=!0}}.prototype.isCanvasTexture=!0,new ne,new ne,new ne,new Ts;class Uc{constructor(){this.type="Curve",this.arcLengthDivisions=200}getPoint(){return console.warn("THREE.Curve: .getPoint() not implemented."),null}getPointAt(e,t){const i=this.getUtoTmapping(e);return this.getPoint(i,t)}getPoints(e=5){const t=[];for(let i=0;i<=e;i++)t.push(this.getPoint(i/e));return t}getSpacedPoints(e=5){const t=[];for(let i=0;i<=e;i++)t.push(this.getPointAt(i/e));return t}getLength(){const e=this.getLengths();return e[e.length-1]}getLengths(e=this.arcLengthDivisions){if(this.cacheArcLengths&&this.cacheArcLengths.length===e+1&&!this.needsUpdate)return this.cacheArcLengths;this.needsUpdate=!1;const t=[];let i,r=this.getPoint(0),s=0;t.push(0);for(let o=1;o<=e;o++)i=this.getPoint(o/e),s+=i.distanceTo(r),t.push(s),r=i;return this.cacheArcLengths=t,t}updateArcLengths(){this.needsUpdate=!0,this.getLengths()}getUtoTmapping(e,t){const i=this.getLengths();let r=0;const s=i.length;let o;o=t||e*i[s-1];let u,a=0,c=s-1;for(;a<=c;)if(r=Math.floor(a+(c-a)/2),u=i[r]-o,u<0)a=r+1;else{if(!(u>0)){c=r;break}c=r-1}if(r=c,i[r]===o)return r/(s-1);const p=i[r];return(r+(o-p)/(i[r+1]-p))/(s-1)}getTangent(e,t){let r=e-1e-4,s=e+1e-4;r<0&&(r=0),s>1&&(s=1);const o=this.getPoint(r),a=this.getPoint(s),c=t||(o.isVector2?new tt:new ne);return c.copy(a).sub(o).normalize(),c}getTangentAt(e,t){const i=this.getUtoTmapping(e);return this.getTangent(i,t)}computeFrenetFrames(e,t){const i=new ne,r=[],s=[],o=[],a=new ne,c=new Gt;for(let y=0;y<=e;y++)r[y]=this.getTangentAt(y/e,new ne);s[0]=new ne,o[0]=new ne;let u=Number.MAX_VALUE;const p=Math.abs(r[0].x),g=Math.abs(r[0].y),v=Math.abs(r[0].z);p<=u&&(u=p,i.set(1,0,0)),g<=u&&(u=g,i.set(0,1,0)),v<=u&&i.set(0,0,1),a.crossVectors(r[0],i).normalize(),s[0].crossVectors(r[0],a),o[0].crossVectors(r[0],s[0]);for(let y=1;y<=e;y++){if(s[y]=s[y-1].clone(),o[y]=o[y-1].clone(),a.crossVectors(r[y-1],r[y]),a.length()>Number.EPSILON){a.normalize();const x=Math.acos(Mo(r[y-1].dot(r[y]),-1,1));s[y].applyMatrix4(c.makeRotationAxis(a,x))}o[y].crossVectors(r[y],s[y])}if(!0===t){let y=Math.acos(Mo(s[0].dot(s[e]),-1,1));y/=e,r[0].dot(a.crossVectors(s[0],s[e]))>0&&(y=-y);for(let x=1;x<=e;x++)s[x].applyMatrix4(c.makeRotationAxis(r[x],y*x)),o[x].crossVectors(r[x],s[x])}return{tangents:r,normals:s,binormals:o}}clone(){return(new this.constructor).copy(this)}copy(e){return this.arcLengthDivisions=e.arcLengthDivisions,this}toJSON(){const e={metadata:{version:4.5,type:"Curve",generator:"Curve.toJSON"}};return e.arcLengthDivisions=this.arcLengthDivisions,e.type=this.type,e}fromJSON(e){return this.arcLengthDivisions=e.arcLengthDivisions,this}}class W2 extends Uc{constructor(e=0,t=0,i=1,r=1,s=0,o=2*Math.PI,a=!1,c=0){super(),this.type="EllipseCurve",this.aX=e,this.aY=t,this.xRadius=i,this.yRadius=r,this.aStartAngle=s,this.aEndAngle=o,this.aClockwise=a,this.aRotation=c}getPoint(e,t){const i=t||new tt,r=2*Math.PI;let s=this.aEndAngle-this.aStartAngle;const o=Math.abs(s)r;)s-=r;s0?0:(Math.floor(Math.abs(a)/s)+1)*s:0===c&&a===s-1&&(a=s-2,c=1),this.closed||a>0?u=r[(a-1)%s]:($2.subVectors(r[0],r[1]).add(r[0]),u=$2);const g=r[a%s],v=r[(a+1)%s];if(this.closed||a+2r.length-2?r.length-1:o+1],g=r[o>r.length-3?r.length-1:o+2];return i.set(O6(a,c.x,u.x,p.x,g.x),O6(a,c.y,u.y,p.y,g.y)),i}copy(e){super.copy(e),this.points=[];for(let t=0,i=e.points.length;t=i){const o=r[s]-i,a=this.curves[s],c=a.getLength();return a.getPointAt(0===c?0:1-o/c,t)}s++}return null}getLength(){const e=this.getCurveLengths();return e[e.length-1]}updateArcLengths(){this.needsUpdate=!0,this.cacheLengths=null,this.getCurveLengths()}getCurveLengths(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;const e=[];let t=0;for(let i=0,r=this.curves.length;i1&&!t[t.length-1].equals(t[0])&&t.push(t[0]),t}copy(e){super.copy(e),this.curves=[];for(let t=0,i=e.curves.length;t0){const g=u.getPoint(0);g.equals(this.currentPoint)||this.lineTo(g.x,g.y)}this.curves.push(u);const p=u.getPoint(1);return this.currentPoint.copy(p),this}copy(e){return super.copy(e),this.currentPoint.copy(e.currentPoint),this}toJSON(){const e=super.toJSON();return e.currentPoint=this.currentPoint.toArray(),e}fromJSON(e){return super.fromJSON(e),this.currentPoint.fromArray(e.currentPoint),this}}class iu extends K2{constructor(e){super(e),this.uuid=rc(),this.type="Shape",this.holes=[]}getPointsHoles(e){const t=[];for(let i=0,r=this.holes.length;i0)for(s=e;s=e;s-=i)o=H6(s,n[s],n[s+1],o);return o&&Y2(o,o.next)&&(Qy(o),o=o.next),o}function Dh(n,e){if(!n)return n;e||(e=n);let i,t=n;do{if(i=!1,t.steiner||!Y2(t,t.next)&&0!==Lr(t.prev,t,t.next))t=t.next;else{if(Qy(t),t=e=t.prev,t===t.next)break;i=!0}}while(i||t!==e);return e}function Zy(n,e,t,i,r,s,o){if(!n)return;!o&&s&&function Ole(n,e,t,i){let r=n;do{null===r.z&&(r.z=OI(r.x,r.y,e,t,i)),r.prevZ=r.prev,r.nextZ=r.next,r=r.next}while(r!==n);r.prevZ.nextZ=null,r.prevZ=null,function Lle(n){let e,t,i,r,s,o,a,c,u=1;do{for(t=n,n=null,s=null,o=0;t;){for(o++,i=t,a=0,e=0;e0||c>0&&i;)0!==a&&(0===c||!i||t.z<=i.z)?(r=t,t=t.nextZ,a--):(r=i,i=i.nextZ,c--),s?s.nextZ=r:n=r,r.prevZ=s,s=r;t=i}s.nextZ=null,u*=2}while(o>1)}(r)}(n,i,r,s);let c,u,a=n;for(;n.prev!==n.next;)if(c=n.prev,u=n.next,s?Dle(n,i,r,s):Cle(n))e.push(c.i/t),e.push(n.i/t),e.push(u.i/t),Qy(n),n=u.next,a=u.next;else if((n=u)===a){o?1===o?Zy(n=Tle(Dh(n),e,t),e,t,i,r,s,2):2===o&&Ale(n,e,t,i,r,s):Zy(Dh(n),e,t,i,r,s,1);break}}function Cle(n){const e=n.prev,t=n,i=n.next;if(Lr(e,t,i)>=0)return!1;let r=n.next.next;for(;r!==n.prev;){if(M0(e.x,e.y,t.x,t.y,i.x,i.y,r.x,r.y)&&Lr(r.prev,r,r.next)>=0)return!1;r=r.next}return!0}function Dle(n,e,t,i){const r=n.prev,s=n,o=n.next;if(Lr(r,s,o)>=0)return!1;const u=r.x>s.x?r.x>o.x?r.x:o.x:s.x>o.x?s.x:o.x,p=r.y>s.y?r.y>o.y?r.y:o.y:s.y>o.y?s.y:o.y,g=OI(r.x=g&&x&&x.z<=v;){if(y!==n.prev&&y!==n.next&&M0(r.x,r.y,s.x,s.y,o.x,o.y,y.x,y.y)&&Lr(y.prev,y,y.next)>=0||(y=y.prevZ,x!==n.prev&&x!==n.next&&M0(r.x,r.y,s.x,s.y,o.x,o.y,x.x,x.y)&&Lr(x.prev,x,x.next)>=0))return!1;x=x.nextZ}for(;y&&y.z>=g;){if(y!==n.prev&&y!==n.next&&M0(r.x,r.y,s.x,s.y,o.x,o.y,y.x,y.y)&&Lr(y.prev,y,y.next)>=0)return!1;y=y.prevZ}for(;x&&x.z<=v;){if(x!==n.prev&&x!==n.next&&M0(r.x,r.y,s.x,s.y,o.x,o.y,x.x,x.y)&&Lr(x.prev,x,x.next)>=0)return!1;x=x.nextZ}return!0}function Tle(n,e,t){let i=n;do{const r=i.prev,s=i.next.next;!Y2(r,s)&&B6(r,i,i.next,s)&&Jy(r,s)&&Jy(s,r)&&(e.push(r.i/t),e.push(i.i/t),e.push(s.i/t),Qy(i),Qy(i.next),i=n=s),i=i.next}while(i!==n);return Dh(i)}function Ale(n,e,t,i,r,s){let o=n;do{let a=o.next.next;for(;a!==o.prev;){if(o.i!==a.i&&Ble(o,a)){let c=V6(o,a);return o=Dh(o,o.next),c=Dh(c,c.next),Zy(o,e,t,i,r,s),void Zy(c,e,t,i,r,s)}a=a.next}o=o.next}while(o!==n)}function Ile(n,e){return n.x-e.x}function Fle(n,e){if(e=function Rle(n,e){let t=e;const i=n.x,r=n.y;let o,s=-1/0;do{if(r<=t.y&&r>=t.next.y&&t.next.y!==t.y){const v=t.x+(r-t.y)*(t.next.x-t.x)/(t.next.y-t.y);if(v<=i&&v>s){if(s=v,v===i){if(r===t.y)return t;if(r===t.next.y)return t.next}o=t.x=t.x&&t.x>=c&&i!==t.x&&M0(ro.x||t.x===o.x&&Ple(o,t)))&&(o=t,p=g)),t=t.next}while(t!==a);return o}(n,e),e){const t=V6(e,n);Dh(e,e.next),Dh(t,t.next)}}function Ple(n,e){return Lr(n.prev,n,e.prev)<0&&Lr(e.next,n,n.next)<0}function OI(n,e,t,i,r){return(n=1431655765&((n=858993459&((n=252645135&((n=16711935&((n=32767*(n-t)*r)|n<<8))|n<<4))|n<<2))|n<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-i)*r)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function Nle(n){let e=n,t=n;do{(e.x=0&&(n-o)*(i-a)-(t-o)*(e-a)>=0&&(t-o)*(s-a)-(r-o)*(i-a)>=0}function Ble(n,e){return n.next.i!==e.i&&n.prev.i!==e.i&&!function Vle(n,e){let t=n;do{if(t.i!==n.i&&t.next.i!==n.i&&t.i!==e.i&&t.next.i!==e.i&&B6(t,t.next,n,e))return!0;t=t.next}while(t!==n);return!1}(n,e)&&(Jy(n,e)&&Jy(e,n)&&function Hle(n,e){let t=n,i=!1;const r=(n.x+e.x)/2,s=(n.y+e.y)/2;do{t.y>s!=t.next.y>s&&t.next.y!==t.y&&r<(t.next.x-t.x)*(s-t.y)/(t.next.y-t.y)+t.x&&(i=!i),t=t.next}while(t!==n);return i}(n,e)&&(Lr(n.prev,n,e.prev)||Lr(n,e.prev,e))||Y2(n,e)&&Lr(n.prev,n,n.next)>0&&Lr(e.prev,e,e.next)>0)}function Lr(n,e,t){return(e.y-n.y)*(t.x-e.x)-(e.x-n.x)*(t.y-e.y)}function Y2(n,e){return n.x===e.x&&n.y===e.y}function B6(n,e,t,i){const r=Z2(Lr(n,e,t)),s=Z2(Lr(n,e,i)),o=Z2(Lr(t,i,n)),a=Z2(Lr(t,i,e));return!!(r!==s&&o!==a||0===r&&X2(n,t,e)||0===s&&X2(n,i,e)||0===o&&X2(t,n,i)||0===a&&X2(t,e,i))}function X2(n,e,t){return e.x<=Math.max(n.x,t.x)&&e.x>=Math.min(n.x,t.x)&&e.y<=Math.max(n.y,t.y)&&e.y>=Math.min(n.y,t.y)}function Z2(n){return n>0?1:n<0?-1:0}function Jy(n,e){return Lr(n.prev,n,n.next)<0?Lr(n,e,n.next)>=0&&Lr(n,n.prev,e)>=0:Lr(n,e,n.prev)<0||Lr(n,n.next,e)<0}function V6(n,e){const t=new LI(n.i,n.x,n.y),i=new LI(e.i,e.x,e.y),r=n.next,s=e.prev;return n.next=e,e.prev=n,t.next=r,r.prev=t,i.next=t,t.prev=i,s.next=i,i.prev=s,i}function H6(n,e,t,i){const r=new LI(n,e,t);return i?(r.next=i.next,r.prev=i,i.next.prev=r,i.next=r):(r.prev=r,r.next=r),r}function Qy(n){n.next.prev=n.prev,n.prev.next=n.next,n.prevZ&&(n.prevZ.nextZ=n.nextZ),n.nextZ&&(n.nextZ.prevZ=n.prevZ)}function LI(n,e,t){this.i=n,this.x=e,this.y=t,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}class ru{static area(e){const t=e.length;let i=0;for(let r=t-1,s=0;s80*t){a=u=n[0],c=p=n[1];for(let x=t;xu&&(u=g),v>p&&(p=v);y=Math.max(u-a,p-c),y=0!==y?1/y:0}return Zy(s,o,t,a,c,y),o}(i,r);for(let c=0;c2&&n[e-1].equals(n[0])&&n.pop()}function z6(n,e){for(let t=0;tNumber.EPSILON){const st=Math.sqrt(ae),Kt=Math.sqrt(xr*xr+fe*fe),Wt=ht.x-xi/st,Ce=ht.y+$n/st,kt=((bt.x-fe/Kt-Wt)*fe-(bt.y+xr/Kt-Ce)*xr)/($n*fe-xi*xr);Vt=Wt+$n*kt-Xe.x,At=Ce+xi*kt-Xe.y;const Et=Vt*Vt+At*At;if(Et<=2)return new tt(Vt,At);Wn=Math.sqrt(Et/2)}else{let st=!1;$n>Number.EPSILON?xr>Number.EPSILON&&(st=!0):$n<-Number.EPSILON?xr<-Number.EPSILON&&(st=!0):Math.sign(xi)===Math.sign(fe)&&(st=!0),st?(Vt=-xi,At=$n,Wn=Math.sqrt(ae)):(Vt=$n,At=xi,Wn=Math.sqrt(ae/2))}return new tt(Vt/Wn,At/Wn)}const lt=[];for(let Xe=0,ht=Oe.length,bt=ht-1,Vt=Xe+1;Xe=0;Xe--){const ht=Xe/N,bt=y*Math.cos(ht*Math.PI/2),Vt=x*Math.sin(ht*Math.PI/2)+T;for(let At=0,Wn=Oe.length;At=0;){const Vt=bt;let At=bt-1;At<0&&(At=Xe.length-1);for(let Wn=0,$n=p+2*N;Wn<$n;Wn++){const xi=ye*Wn,xr=ye*(Wn+1);It(ht+Vt+xi,ht+At+xi,ht+At+xr,ht+Vt+xr)}}}function Qt(Xe,ht,bt){c.push(Xe),c.push(ht),c.push(bt)}function sn(Xe,ht,bt){on(Xe),on(ht),on(bt);const Vt=r.length/3,At=A.generateTopUV(i,r,Vt-3,Vt-2,Vt-1);gi(At[0]),gi(At[1]),gi(At[2])}function It(Xe,ht,bt,Vt){on(Xe),on(ht),on(Vt),on(ht),on(bt),on(Vt);const At=r.length/3,Wn=A.generateSideWallUV(i,r,At-6,At-3,At-2,At-1);gi(Wn[0]),gi(Wn[1]),gi(Wn[3]),gi(Wn[1]),gi(Wn[2]),gi(Wn[3])}function on(Xe){r.push(c[3*Xe+0]),r.push(c[3*Xe+1]),r.push(c[3*Xe+2])}function gi(Xe){s.push(Xe.x),s.push(Xe.y)}(function gt(){const Xe=r.length/3;if(v){let ht=0,bt=ye*ht;for(let Vt=0;Vt0!=e>0&&this.version++,this._sheen=e}get clearcoat(){return this._clearcoat}set clearcoat(e){this._clearcoat>0!=e>0&&this.version++,this._clearcoat=e}get transmission(){return this._transmission}set transmission(e){this._transmission>0!=e>0&&this.version++,this._transmission=e}copy(e){return super.copy(e),this.defines={STANDARD:"",PHYSICAL:""},this.clearcoat=e.clearcoat,this.clearcoatMap=e.clearcoatMap,this.clearcoatRoughness=e.clearcoatRoughness,this.clearcoatRoughnessMap=e.clearcoatRoughnessMap,this.clearcoatNormalMap=e.clearcoatNormalMap,this.clearcoatNormalScale.copy(e.clearcoatNormalScale),this.ior=e.ior,this.sheen=e.sheen,this.sheenColor.copy(e.sheenColor),this.sheenColorMap=e.sheenColorMap,this.sheenRoughness=e.sheenRoughness,this.sheenRoughnessMap=e.sheenRoughnessMap,this.transmission=e.transmission,this.transmissionMap=e.transmissionMap,this.thickness=e.thickness,this.thicknessMap=e.thicknessMap,this.attenuationDistance=e.attenuationDistance,this.attenuationColor.copy(e.attenuationColor),this.specularIntensity=e.specularIntensity,this.specularIntensityMap=e.specularIntensityMap,this.specularColor.copy(e.specularColor),this.specularColorMap=e.specularColorMap,this}}).prototype.isMeshPhysicalMaterial=!0;(class K6 extends Co{constructor(e){super(),this.type="MeshPhongMaterial",this.color=new Rt(16777215),this.specular=new Rt(1118481),this.shininess=30,this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new Rt(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=$g,this.normalScale=new tt(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=jS,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.specular.copy(e.specular),this.shininess=e.shininess,this.map=e.map,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.specularMap=e.specularMap,this.alphaMap=e.alphaMap,this.envMap=e.envMap,this.combine=e.combine,this.reflectivity=e.reflectivity,this.refractionRatio=e.refractionRatio,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this.flatShading=e.flatShading,this}}).prototype.isMeshPhongMaterial=!0;(class Y6 extends Co{constructor(e){super(),this.defines={TOON:""},this.type="MeshToonMaterial",this.color=new Rt(16777215),this.map=null,this.gradientMap=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new Rt(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=$g,this.normalScale=new tt(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.map=e.map,this.gradientMap=e.gradientMap,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.alphaMap=e.alphaMap,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this}}).prototype.isMeshToonMaterial=!0;(class X6 extends Co{constructor(e){super(),this.type="MeshNormalMaterial",this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=$g,this.normalScale=new tt(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.flatShading=e.flatShading,this}}).prototype.isMeshNormalMaterial=!0;(class Z6 extends Co{constructor(e){super(),this.type="MeshLambertMaterial",this.color=new Rt(16777215),this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new Rt(0),this.emissiveIntensity=1,this.emissiveMap=null,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=jS,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.map=e.map,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.specularMap=e.specularMap,this.alphaMap=e.alphaMap,this.envMap=e.envMap,this.combine=e.combine,this.reflectivity=e.reflectivity,this.refractionRatio=e.refractionRatio,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this}}).prototype.isMeshLambertMaterial=!0;(class J6 extends Co{constructor(e){super(),this.defines={MATCAP:""},this.type="MeshMatcapMaterial",this.color=new Rt(16777215),this.matcap=null,this.map=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=$g,this.normalScale=new tt(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.defines={MATCAP:""},this.color.copy(e.color),this.matcap=e.matcap,this.map=e.map,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.alphaMap=e.alphaMap,this.flatShading=e.flatShading,this}}).prototype.isMeshMatcapMaterial=!0;(class Q6 extends To{constructor(e){super(),this.type="LineDashedMaterial",this.scale=1,this.dashSize=3,this.gapSize=1,this.setValues(e)}copy(e){return super.copy(e),this.scale=e.scale,this.dashSize=e.dashSize,this.gapSize=e.gapSize,this}}).prototype.isLineDashedMaterial=!0;const Ar={arraySlice:function(n,e,t){return Ar.isTypedArray(n)?new n.constructor(n.subarray(e,void 0!==t?t:n.length)):n.slice(e,t)},convertArray:function(n,e,t){return!n||!t&&n.constructor===e?n:"number"==typeof e.BYTES_PER_ELEMENT?new e(n):Array.prototype.slice.call(n)},isTypedArray:function(n){return ArrayBuffer.isView(n)&&!(n instanceof DataView)},getKeyframeOrder:function(n){const t=n.length,i=new Array(t);for(let r=0;r!==t;++r)i[r]=r;return i.sort(function e(r,s){return n[r]-n[s]}),i},sortedArray:function(n,e,t){const i=n.length,r=new n.constructor(i);for(let s=0,o=0;o!==i;++s){const a=t[s]*e;for(let c=0;c!==e;++c)r[o++]=n[a+c]}return r},flattenJSON:function(n,e,t,i){let r=1,s=n[0];for(;void 0!==s&&void 0===s[i];)s=n[r++];if(void 0===s)return;let o=s[i];if(void 0!==o)if(Array.isArray(o))do{o=s[i],void 0!==o&&(e.push(s.time),t.push.apply(t,o)),s=n[r++]}while(void 0!==s);else if(void 0!==o.toArray)do{o=s[i],void 0!==o&&(e.push(s.time),o.toArray(t,t.length)),s=n[r++]}while(void 0!==s);else do{o=s[i],void 0!==o&&(e.push(s.time),t.push(o)),s=n[r++]}while(void 0!==s)},subclip:function(n,e,t,i,r=30){const s=n.clone();s.name=e;const o=[];for(let c=0;c=i)){g.push(u.times[y]);for(let T=0;Ts.tracks[c].times[0]&&(a=s.tracks[c].times[0]);for(let c=0;c=a.times[x]){const k=x*g+p;T=Ar.arraySlice(a.values,k,k+g-p)}else{const k=a.createInterpolant(),A=p,H=g-p;k.evaluate(s),T=Ar.arraySlice(k.resultBuffer,A,H)}"quaternion"===c&&(new Go).fromArray(T).normalize().conjugate().toArray(T);const N=u.times.length;for(let k=0;k=s)break e;{const a=t[1];e=s)break t}o=i,i=0}}for(;i>>1;et;)--o;if(++o,0!==s||o!==r){s>=o&&(o=Math.max(o,1),s=o-1);const a=this.getValueSize();this.times=Ar.arraySlice(i,s,o),this.values=Ar.arraySlice(this.values,s*a,o*a)}return this}validate(){let e=!0;const t=this.getValueSize();t-Math.floor(t)!=0&&(console.error("THREE.KeyframeTrack: Invalid value size in track.",this),e=!1);const i=this.times,r=this.values,s=i.length;0===s&&(console.error("THREE.KeyframeTrack: Track is empty.",this),e=!1);let o=null;for(let a=0;a!==s;a++){const c=i[a];if("number"==typeof c&&isNaN(c)){console.error("THREE.KeyframeTrack: Time is not a valid number.",this,a,c),e=!1;break}if(null!==o&&o>c){console.error("THREE.KeyframeTrack: Out of order keys.",this,a,c,o),e=!1;break}o=c}if(void 0!==r&&Ar.isTypedArray(r))for(let a=0,c=r.length;a!==c;++a){const u=r[a];if(isNaN(u)){console.error("THREE.KeyframeTrack: Value is not a valid number.",this,a,u),e=!1;break}}return e}optimize(){const e=Ar.arraySlice(this.times),t=Ar.arraySlice(this.values),i=this.getValueSize(),r=2302===this.getInterpolation(),s=e.length-1;let o=1;for(let a=1;a0){e[o]=e[s];for(let a=s*i,c=o*i,u=0;u!==i;++u)t[c+u]=t[a+u];++o}return o!==e.length?(this.times=Ar.arraySlice(e,0,o),this.values=Ar.arraySlice(t,0,o*i)):(this.times=e,this.values=t),this}clone(){const e=Ar.arraySlice(this.times,0),t=Ar.arraySlice(this.values,0),r=new(0,this.constructor)(this.name,e,t);return r.createInterpolant=this.createInterpolant,r}}nd.prototype.TimeBufferType=Float32Array,nd.prototype.ValueBufferType=Float32Array,nd.prototype.DefaultInterpolation=2301;class C0 extends nd{}C0.prototype.ValueTypeName="bool",C0.prototype.ValueBufferType=Array,C0.prototype.DefaultInterpolation=2300,C0.prototype.InterpolantFactoryMethodLinear=void 0,C0.prototype.InterpolantFactoryMethodSmooth=void 0;class tV extends nd{}tV.prototype.ValueTypeName="color";class oE extends nd{}oE.prototype.ValueTypeName="number";class Kle extends Th{constructor(e,t,i,r){super(e,t,i,r)}interpolate_(e,t,i,r){const s=this.resultBuffer,o=this.sampleValues,a=this.valueSize,c=(i-t)/(r-t);let u=e*a;for(let p=u+a;u!==p;u+=4)Go.slerpFlat(s,0,o,u-a,o,u,c);return s}}class ib extends nd{InterpolantFactoryMethodLinear(e){return new Kle(this.times,this.values,this.getValueSize(),e)}}ib.prototype.ValueTypeName="quaternion",ib.prototype.DefaultInterpolation=2301,ib.prototype.InterpolantFactoryMethodSmooth=void 0;class D0 extends nd{}D0.prototype.ValueTypeName="string",D0.prototype.ValueBufferType=Array,D0.prototype.DefaultInterpolation=2300,D0.prototype.InterpolantFactoryMethodLinear=void 0,D0.prototype.InterpolantFactoryMethodSmooth=void 0;class aE extends nd{}aE.prototype.ValueTypeName="vector";class cE{constructor(e,t=-1,i,r=2500){this.name=e,this.tracks=i,this.duration=t,this.blendMode=r,this.uuid=rc(),this.duration<0&&this.resetDuration()}static parse(e){const t=[],i=e.tracks,r=1/(e.fps||1);for(let o=0,a=i.length;o!==a;++o)t.push(Xle(i[o]).scale(r));const s=new this(e.name,e.duration,t,e.blendMode);return s.uuid=e.uuid,s}static toJSON(e){const t=[],i=e.tracks,r={name:e.name,duration:e.duration,tracks:t,uuid:e.uuid,blendMode:e.blendMode};for(let s=0,o=i.length;s!==o;++s)t.push(nd.toJSON(i[s]));return r}static CreateFromMorphTargetSequence(e,t,i,r){const s=t.length,o=[];for(let a=0;a1){const g=p[1];let v=r[g];v||(r[g]=v=[]),v.push(u)}}const o=[];for(const a in r)o.push(this.CreateFromMorphTargetSequence(a,r[a],t,i));return o}static parseAnimation(e,t){if(!e)return console.error("THREE.AnimationClip: No animation in JSONLoader data."),null;const i=function(g,v,y,x,T){if(0!==y.length){const N=[],k=[];Ar.flattenJSON(y,N,k,x),0!==N.length&&T.push(new g(v,N,k))}},r=[],s=e.name||"default",o=e.fps||30,a=e.blendMode;let c=e.length||-1;const u=e.hierarchy||[];for(let g=0;g{t&&t(s),this.manager.itemEnd(e)},0),s;if(void 0!==au[e])return void au[e].push({onLoad:t,onProgress:i,onError:r});au[e]=[],au[e].push({onLoad:t,onProgress:i,onError:r});const o=new Request(e,{headers:new Headers(this.requestHeader),credentials:this.withCredentials?"include":"same-origin"});fetch(o).then(a=>{if(200===a.status||0===a.status){0===a.status&&console.warn("THREE.FileLoader: HTTP Status 0 received.");const c=au[e],u=a.body.getReader(),p=a.headers.get("Content-Length"),g=p?parseInt(p):0,v=0!==g;let y=0;return new ReadableStream({start(x){!function T(){u.read().then(({done:N,value:k})=>{if(N)x.close();else{y+=k.byteLength;const A=new ProgressEvent("progress",{lengthComputable:v,loaded:y,total:g});for(let H=0,G=c.length;H{const c=new Response(a);switch(this.responseType){case"arraybuffer":return c.arrayBuffer();case"blob":return c.blob();case"document":return c.text().then(u=>(new DOMParser).parseFromString(u,this.mimeType));case"json":return c.json();default:return c.text()}}).then(a=>{T0.add(e,a);const c=au[e];delete au[e];for(let u=0,p=c.length;u{const c=au[e];delete au[e];for(let u=0,p=c.length;u"u"&&console.warn("THREE.ImageBitmapLoader: createImageBitmap() not supported."),typeof fetch>"u"&&console.warn("THREE.ImageBitmapLoader: fetch() not supported."),this.options={premultiplyAlpha:"none"}}setOptions(e){return this.options=e,this}load(e,t,i,r){void 0===e&&(e=""),void 0!==this.path&&(e=this.path+e),e=this.manager.resolveURL(e);const s=this,o=T0.get(e);if(void 0!==o)return s.manager.itemStart(e),setTimeout(function(){t&&t(o),s.manager.itemEnd(e)},0),o;const a={};a.credentials="anonymous"===this.crossOrigin?"same-origin":"include",a.headers=this.requestHeader,fetch(e,a).then(function(c){return c.blob()}).then(function(c){return createImageBitmap(c,Object.assign(s.options,{colorSpaceConversion:"none"}))}).then(function(c){T0.add(e,c),t&&t(c),s.manager.itemEnd(e)}).catch(function(c){r&&r(c),s.manager.itemError(e),s.manager.itemEnd(e)}),s.manager.itemStart(e)}}.prototype.isImageBitmapLoader=!0;class sde extends ou{constructor(e){super(e)}load(e,t,i,r){const s=this,o=new id(this.manager);o.setResponseType("arraybuffer"),o.setPath(this.path),o.setRequestHeader(this.requestHeader),o.setWithCredentials(this.withCredentials),o.load(e,function(a){try{const c=a.slice(0);(void 0===uE&&(uE=new(window.AudioContext||window.webkitAudioContext)),uE).decodeAudioData(c,function(p){t(p)})}catch(c){r?r(c):console.error(c),s.manager.itemError(e)}},i,r)}}(class ode extends dE{constructor(e,t,i=1){super(void 0,i);const r=(new Rt).set(e),s=(new Rt).set(t),o=new ne(r.r,r.g,r.b),a=new ne(s.r,s.g,s.b),c=Math.sqrt(Math.PI),u=c*Math.sqrt(.75);this.sh.coefficients[0].copy(o).add(a).multiplyScalar(c),this.sh.coefficients[1].copy(o).sub(a).multiplyScalar(u)}}).prototype.isHemisphereLightProbe=!0,class ade extends dE{constructor(e,t=1){super(void 0,t);const i=(new Rt).set(e);this.sh.coefficients[0].set(i.r,i.g,i.b).multiplyScalar(2*Math.sqrt(Math.PI))}}.prototype.isAmbientLightProbe=!0;class fde{constructor(e,t,i){let r,s,o;switch(this.binding=e,this.valueSize=i,t){case"quaternion":r=this._slerp,s=this._slerpAdditive,o=this._setAdditiveIdentityQuaternion,this.buffer=new Float64Array(6*i),this._workIndex=5;break;case"string":case"bool":r=this._select,s=this._select,o=this._setAdditiveIdentityOther,this.buffer=new Array(5*i);break;default:r=this._lerp,s=this._lerpAdditive,o=this._setAdditiveIdentityNumeric,this.buffer=new Float64Array(5*i)}this._mixBufferRegion=r,this._mixBufferRegionAdditive=s,this._setIdentity=o,this._origIndex=3,this._addIndex=4,this.cumulativeWeight=0,this.cumulativeWeightAdditive=0,this.useCount=0,this.referenceCount=0}accumulate(e,t){const i=this.buffer,r=this.valueSize,s=e*r+r;let o=this.cumulativeWeight;if(0===o){for(let a=0;a!==r;++a)i[s+a]=i[a];o=t}else o+=t,this._mixBufferRegion(i,s,0,t/o,r);this.cumulativeWeight=o}accumulateAdditive(e){const t=this.buffer,i=this.valueSize,r=i*this._addIndex;0===this.cumulativeWeightAdditive&&this._setIdentity(),this._mixBufferRegionAdditive(t,r,0,e,i),this.cumulativeWeightAdditive+=e}apply(e){const t=this.valueSize,i=this.buffer,r=e*t+t,s=this.cumulativeWeight,o=this.cumulativeWeightAdditive,a=this.binding;this.cumulativeWeight=0,this.cumulativeWeightAdditive=0,s<1&&this._mixBufferRegion(i,r,t*this._origIndex,1-s,t),o>0&&this._mixBufferRegionAdditive(i,r,this._addIndex*t,1,t);for(let c=t,u=t+t;c!==u;++c)if(i[c]!==i[c+t]){a.setValue(i,r);break}}saveOriginalState(){const t=this.buffer,i=this.valueSize,r=i*this._origIndex;this.binding.getValue(t,r);for(let s=i,o=r;s!==o;++s)t[s]=t[r+s%i];this._setIdentity(),this.cumulativeWeight=0,this.cumulativeWeightAdditive=0}restoreOriginalState(){this.binding.setValue(this.buffer,3*this.valueSize)}_setAdditiveIdentityNumeric(){const e=this._addIndex*this.valueSize,t=e+this.valueSize;for(let i=e;i=.5)for(let o=0;o!==s;++o)e[t+o]=e[i+o]}_slerp(e,t,i,r){Go.slerpFlat(e,t,e,t,e,i,r)}_slerpAdditive(e,t,i,r,s){const o=this._workIndex*s;Go.multiplyQuaternionsFlat(e,o,e,t,e,i),Go.slerpFlat(e,t,e,t,e,o,r)}_lerp(e,t,i,r,s){const o=1-r;for(let a=0;a!==s;++a){const c=t+a;e[c]=e[c]*o+e[i+a]*r}}_lerpAdditive(e,t,i,r,s){for(let o=0;o!==s;++o){const a=t+o;e[a]=e[a]+e[i+o]*r}}}const HI="\\[\\]\\.:\\/",pde=new RegExp("["+HI+"]","g"),UI="[^"+HI+"]",mde="[^"+HI.replace("\\.","")+"]",gde=/((?:WC+[\/:])*)/.source.replace("WC",UI),_de=/(WCOD+)?/.source.replace("WCOD",mde),vde=/(?:\.(WC+)(?:\[(.+)\])?)?/.source.replace("WC",UI),yde=/\.(WC+)(?:\[(.+)\])?/.source.replace("WC",UI),bde=new RegExp("^"+gde+_de+vde+yde+"$"),xde=["material","materials","bones"];class wde{constructor(e,t,i){const r=i||yr.parseTrackName(t);this._targetGroup=e,this._bindings=e.subscribe_(t,r)}getValue(e,t){this.bind();const r=this._bindings[this._targetGroup.nCachedObjects_];void 0!==r&&r.getValue(e,t)}setValue(e,t){const i=this._bindings;for(let r=this._targetGroup.nCachedObjects_,s=i.length;r!==s;++r)i[r].setValue(e,t)}bind(){const e=this._bindings;for(let t=this._targetGroup.nCachedObjects_,i=e.length;t!==i;++t)e[t].bind()}unbind(){const e=this._bindings;for(let t=this._targetGroup.nCachedObjects_,i=e.length;t!==i;++t)e[t].unbind()}}let yr=(()=>{class n{constructor(t,i,r){this.path=i,this.parsedPath=r||n.parseTrackName(i),this.node=n.findNode(t,this.parsedPath.nodeName)||t,this.rootNode=t,this.getValue=this._getValue_unbound,this.setValue=this._setValue_unbound}static create(t,i,r){return t&&t.isAnimationObjectGroup?new n.Composite(t,i,r):new n(t,i,r)}static sanitizeNodeName(t){return t.replace(/\s/g,"_").replace(pde,"")}static parseTrackName(t){const i=bde.exec(t);if(!i)throw new Error("PropertyBinding: Cannot parse trackName: "+t);const r={nodeName:i[2],objectName:i[3],objectIndex:i[4],propertyName:i[5],propertyIndex:i[6]},s=r.nodeName&&r.nodeName.lastIndexOf(".");if(void 0!==s&&-1!==s){const o=r.nodeName.substring(s+1);-1!==xde.indexOf(o)&&(r.nodeName=r.nodeName.substring(0,s),r.objectName=o)}if(null===r.propertyName||0===r.propertyName.length)throw new Error("PropertyBinding: can not parse propertyName from trackName: "+t);return r}static findNode(t,i){if(!i||""===i||"."===i||-1===i||i===t.name||i===t.uuid)return t;if(t.skeleton){const r=t.skeleton.getBoneByName(i);if(void 0!==r)return r}if(t.children){const r=function(o){for(let a=0;a0){const c=this._interpolants,u=this._propertyBindings;if(2501===this.blendMode)for(let p=0,g=c.length;p!==g;++p)c[p].evaluate(o),u[p].accumulateAdditive(a);else for(let p=0,g=c.length;p!==g;++p)c[p].evaluate(o),u[p].accumulate(r,a)}}_updateWeight(e){let t=0;if(this.enabled){t=this.weight;const i=this._weightInterpolant;if(null!==i){const r=i.evaluate(e)[0];t*=r,e>i.parameterPositions[1]&&(this.stopFading(),0===r&&(this.enabled=!1))}}return this._effectiveWeight=t,t}_updateTimeScale(e){let t=0;if(!this.paused){t=this.timeScale;const i=this._timeScaleInterpolant;null!==i&&(t*=i.evaluate(e)[0],e>i.parameterPositions[1]&&(this.stopWarping(),0===t?this.paused=!0:this.timeScale=t))}return this._effectiveTimeScale=t,t}_updateTime(e){const t=this._clip.duration,i=this.loop;let r=this.time+e,s=this._loopCount;const o=2202===i;if(0===e)return-1===s?r:o&&1==(1&s)?t-r:r;if(2200===i){-1===s&&(this._loopCount=0,this._setEndings(!0,!0,!1));e:{if(r>=t)r=t;else{if(!(r<0)){this.time=r;break e}r=0}this.clampWhenFinished?this.paused=!0:this.enabled=!1,this.time=r,this._mixer.dispatchEvent({type:"finished",action:this,direction:e<0?-1:1})}}else{if(-1===s&&(e>=0?(s=0,this._setEndings(!0,0===this.repetitions,o)):this._setEndings(0===this.repetitions,!0,o)),r>=t||r<0){const a=Math.floor(r/t);r-=t*a,s+=Math.abs(a);const c=this.repetitions-s;if(c<=0)this.clampWhenFinished?this.paused=!0:this.enabled=!1,r=e>0?t:0,this.time=r,this._mixer.dispatchEvent({type:"finished",action:this,direction:e>0?1:-1});else{if(1===c){const u=e<0;this._setEndings(u,!u,o)}else this._setEndings(!1,!1,o);this._loopCount=s,this.time=r,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:a})}}else this.time=r;if(o&&1==(1&s))return t-r}return r}_setEndings(e,t,i){const r=this._interpolantSettings;i?(r.endingStart=Wg,r.endingEnd=Wg):(r.endingStart=e?this.zeroSlopeAtStart?Wg:jg:2402,r.endingEnd=t?this.zeroSlopeAtEnd?Wg:jg:2402)}_scheduleFading(e,t,i){const r=this._mixer,s=r.time;let o=this._weightInterpolant;null===o&&(o=r._lendControlInterpolant(),this._weightInterpolant=o);const a=o.parameterPositions,c=o.sampleValues;return a[0]=s,c[0]=t,a[1]=s+e,c[1]=i,this}}(class Mde extends np{constructor(e){super(),this._root=e,this._initMemoryManager(),this._accuIndex=0,this.time=0,this.timeScale=1}_bindAction(e,t){const i=e._localRoot||this._root,r=e._clip.tracks,s=r.length,o=e._propertyBindings,a=e._interpolants,c=i.uuid,u=this._bindingsByRootAndName;let p=u[c];void 0===p&&(p={},u[c]=p);for(let g=0;g!==s;++g){const v=r[g],y=v.name;let x=p[y];if(void 0!==x)o[g]=x;else{if(x=o[g],void 0!==x){null===x._cacheIndex&&(++x.referenceCount,this._addInactiveBinding(x,c,y));continue}x=new fde(yr.create(i,y,t&&t._propertyBindings[g].binding.parsedPath),v.ValueTypeName,v.getValueSize()),++x.referenceCount,this._addInactiveBinding(x,c,y),o[g]=x}a[g].resultBuffer=x.buffer}}_activateAction(e){if(!this._isActiveAction(e)){if(null===e._cacheIndex){const i=(e._localRoot||this._root).uuid,r=e._clip.uuid,s=this._actionsByClip[r];this._bindAction(e,s&&s.knownActions[0]),this._addInactiveAction(e,r,i)}const t=e._propertyBindings;for(let i=0,r=t.length;i!==r;++i){const s=t[i];0==s.useCount++&&(this._lendBinding(s),s.saveOriginalState())}this._lendAction(e)}}_deactivateAction(e){if(this._isActiveAction(e)){const t=e._propertyBindings;for(let i=0,r=t.length;i!==r;++i){const s=t[i];0==--s.useCount&&(s.restoreOriginalState(),this._takeBackBinding(s))}this._takeBackAction(e)}}_initMemoryManager(){this._actions=[],this._nActiveActions=0,this._actionsByClip={},this._bindings=[],this._nActiveBindings=0,this._bindingsByRootAndName={},this._controlInterpolants=[],this._nActiveControlInterpolants=0;const e=this;this.stats={actions:{get total(){return e._actions.length},get inUse(){return e._nActiveActions}},bindings:{get total(){return e._bindings.length},get inUse(){return e._nActiveBindings}},controlInterpolants:{get total(){return e._controlInterpolants.length},get inUse(){return e._nActiveControlInterpolants}}}}_isActiveAction(e){const t=e._cacheIndex;return null!==t&&t=0;--i)e[i].stop();return this}update(e){const t=this._actions,i=this._nActiveActions,r=this.time+=e*=this.timeScale,s=Math.sign(e),o=this._accuIndex^=1;for(let u=0;u!==i;++u)t[u]._update(r,e,s,o);const a=this._bindings,c=this._nActiveBindings;for(let u=0;u!==c;++u)a[u].apply(o);return this}setTime(e){this.time=0;for(let t=0;tthis.max.x||e.ythis.max.y)}containsBox(e){return this.min.x<=e.min.x&&e.max.x<=this.max.x&&this.min.y<=e.min.y&&e.max.y<=this.max.y}getParameter(e,t){return t.set((e.x-this.min.x)/(this.max.x-this.min.x),(e.y-this.min.y)/(this.max.y-this.min.y))}intersectsBox(e){return!(e.max.xthis.max.x||e.max.ythis.max.y)}clampPoint(e,t){return t.copy(e).clamp(this.min,this.max)}distanceToPoint(e){return DV.copy(e).clamp(this.min,this.max).sub(e).length()}intersect(e){return this.min.max(e.min),this.max.min(e.max),this}union(e){return this.min.min(e.min),this.max.max(e.max),this}translate(e){return this.min.add(e),this.max.add(e),this}equals(e){return e.min.equals(this.min)&&e.max.equals(this.max)}}sb.prototype.isBox2=!0;const Ah=new ne,fE=new Gt,jI=new Gt;function kV(n){const e=[];n&&n.isBone&&e.push(n);for(let t=0;tNumber.EPSILON){if(ge<0&&(he=H[K],Te=-Te,De=H[se],ge=-ge),A.yDe.y)continue;if(A.y===he.y){if(A.x===he.x)return!0}else{const Qe=ge*(A.x-he.x)-Te*(A.y-he.y);if(0===Qe)return!0;if(Qe<0)continue;X=!X}}else{if(A.y!==he.y)continue;if(De.x<=A.x&&A.x<=he.x||he.x<=A.x&&A.x<=De.x)return!0}}return X}const s=ru.isClockWise,o=this.subPaths;if(0===o.length)return[];if(!0===t)return i(o);let a,c,u;const p=[];if(1===o.length)return c=o[0],u=new iu,u.curves=c.curves,p.push(u),p;let g=!s(o[0].getPoints());g=e?!g:g;const v=[],y=[];let N,k,x=[],T=0;y[T]=void 0,x[T]=[];for(let A=0,H=o.length;A1){let A=!1;const H=[];for(let G=0,X=y.length;G0&&(A||(x=v))}for(let A=0,H=y.length;A0){this.source.connect(this.filters[0]);for(let e=1,t=this.filters.length;e0){this.source.disconnect(this.filters[0]);for(let e=1,t=this.filters.length;et.clone()),e}invert(){for(let t=0;t{class n{constructor(t,i){this.normal=t,this.w=i,this.normal=t,this.w=i}clone(){return new n(this.normal.clone(),this.w)}flip(){this.normal.negate(),this.w=-this.w}splitPolygon(t,i,r,s,o){let g=0;const v=[];for(let y=0;yn.EPSILON?1:0;g|=T,v.push(T)}switch(g){case 0:(this.normal.dot(t.plane.normal)>0?i:r).push(t);break;case 1:s.push(t);break;case 2:o.push(t);break;case 3:{const y=[],x=[];for(let T=0;T=3&&s.push(new A0(y,t.shared)),x.length>=3&&o.push(new A0(x,t.shared));break}}}static fromPoints(t,i,r){const s=(new Ca).copy(i).sub(t).cross((new Ca).copy(r).sub(t)).normalize();return new n(s.clone(),s.dot(t))}}return n.EPSILON=1e-5,n})();class A0{constructor(e,t){this.vertices=e,this.shared=t,this.plane=Nde.fromPoints(e[0].pos,e[1].pos,e[2].pos)}clone(){return new A0(this.vertices.map(e=>e.clone()),this.shared)}flip(){this.vertices.reverse().map(e=>e.flip()),this.plane.flip()}}class vE{constructor(e,t,i,r){this.pos=(new Ca).copy(e),this.normal=(new Ca).copy(t),this.uv=(new Ca).copy(i),this.uv.z=0,r&&(this.color=(new Ca).copy(r))}clone(){return new vE(this.pos,this.normal,this.uv,this.color)}flip(){this.normal.negate()}interpolate(e,t){return new vE(this.pos.clone().lerp(e.pos,t),this.normal.clone().lerp(e.normal,t),this.uv.clone().lerp(e.uv,t),this.color&&e.color&&this.color.clone().lerp(e.color,t))}}class br{constructor(){this.polygons=new Array}static fromPolygons(e){const t=new br;return t.polygons=e,t}static fromGeometry(e,t){let i=[];const r=e.attributes.position,s=e.attributes.normal,o=e.attributes.uv,a=e.attributes.color,c=e.groups;let u;if(e.index)u=e.index.array;else{u=new Array(r.array.length/r.itemSize|0);for(let g=0;g0)for(const T of c)u[g]>=T.start&&u[g]!isNaN(g.plane.normal.x)))}static toGeometry(e,t){let i=0;const r=e.polygons;for(const y of r)i+=y.vertices.length-2;const s=new gn,o=new $I(3*i*3),a=new $I(3*i*3),c=new Lde(2*i*3);let u;const p=[],g=[];for(const y of r){const x=y.vertices,T=x.length;void 0!==y.shared&&(p[y.shared]||(p[y.shared]=[])),T&&void 0!==x[0].color&&(u||(u=new $I(3*i*3)));for(let N=3;N<=T;N++)(void 0===y.shared?g:p[y.shared]).push(o.top/3,o.top/3+1,o.top/3+2),o.write(x[0].pos),o.write(x[N-2].pos),o.write(x[N-1].pos),a.write(x[0].normal),a.write(x[N-2].normal),a.write(x[N-1].normal),c&&(c.write(x[0].uv),c.write(x[N-2].uv),c.write(x[N-1].uv)),u&&(u.write(x[0].color),u.write(x[N-2].color),u.write(x[N-1].color))}s.setAttribute("position",new zi(o.array,3)),s.setAttribute("normal",new zi(a.array,3)),c&&s.setAttribute("uv",new zi(c.array,2)),u&&s.setAttribute("color",new zi(u.array,3));for(let y=0;yt.clone()).filter(t=>Number.isFinite(t.plane.w)),e}toPolygons(){return this.polygons}union(e){const t=new sd(this.clone().polygons),i=new sd(e.clone().polygons);return t.clipTo(i),i.clipTo(t),i.invert(),i.clipTo(t),i.invert(),t.build(i.allPolygons()),br.fromPolygons(t.allPolygons())}subtract(e){const t=new sd(this.clone().polygons),i=new sd(e.clone().polygons);return t.invert(),t.clipTo(i),i.clipTo(t),i.invert(),i.clipTo(t),i.invert(),t.build(i.allPolygons()),t.invert(),br.fromPolygons(t.allPolygons())}intersect(e){const t=new sd(this.clone().polygons),i=new sd(e.clone().polygons);return t.invert(),i.clipTo(t),i.invert(),t.clipTo(i),i.clipTo(t),t.build(i.allPolygons()),t.invert(),br.fromPolygons(t.allPolygons())}inverse(){const e=this.clone();for(const t of e.polygons)t.flip();return e}toMesh(e,t){return br.toMesh(this,e,t)}toGeometry(e){return br.toGeometry(this,e)}}class Bde{parse(e,t={}){const i=void 0!==t.binary&&t.binary,r=[];let s=0;e.traverse(function(k){if(k.isMesh){const A=k.geometry;if(!0!==A.isBufferGeometry)throw new Error("THREE.STLExporter: Geometry is not of type THREE.BufferGeometry.");const H=A.index,G=A.getAttribute("position");s+=null!==H?H.count/3:G.count/3,r.push({object3d:k,geometry:A})}});let o,a=80;if(!0===i){const A=new ArrayBuffer(2*s+3*s*4*4+80+4);o=new DataView(A),o.setUint32(a,s,!0),a+=4}else o="",o+="solid exported\n";const c=new ne,u=new ne,p=new ne,g=new ne,v=new ne,y=new ne;for(let k=0,A=r.length;k0?"active":"inactive",i.poi?Ti(4,13,yv(5,16,t.date,"y-M-d","GMT"),"icon"):""))("ngStyle",qu(55,qde,"hsl("+(120*(100-Ti(6,20,t.activities,i.calendarFilter)/864)/50-120)+", "+(Ti(7,23,t.activities,i.calendarFilter)>0?"100%":"0%")+", "+(Ti(8,26,t.activities,i.calendarFilter)>0?Ti(9,29,t.activities,i.calendarFilter)/864>50?100-vn(10,32,t.activities)/864+"%":"50%":"90%")+")"))("matTooltip",yv(11,34,t.date,"shortDate","GMT")+Ti(12,38,yv(13,41,t.date,"y-M-d","GMT"),"text")+": "+i.Math.floor(Ti(14,45,t.activities,i.calendarFilter)/86400*24)+"h "+i.Math.floor(Ti(15,48,t.activities,i.calendarFilter)%3600/60)+"m")}}function Yde(n,e){if(1&n){const t=Df();ke(0,"button",21),Gn("click",function(){R(t);const r=Jt().$implicit,s=Jt();return V(s.three(r,s.displayName,s.seasons.length))}),ft(1,"loadingReduce"),it(2,"Download STL"),Ne()}if(2&n){const t=Jt().$implicit;$e("disabled",vn(1,2,Jt().loadingArray))("id","download"+t.number)}}const Xde=function(n){return{width:n}};function Zde(n,e){if(1&n&&(ke(0,"div",14)(1,"div",15),it(2),Ne(),mt(3,Wde,3,3,"div",16),ke(4,"div",17),ft(5,"loadingReduce"),mt(6,Kde,16,57,"div",18),Ne(),mt(7,Yde,3,4,"button",19),Ne()),2&n){const t=e.$implicit,i=Jt();$e("ngStyle",qu(8,Xde,i.Math.ceil(t.days.length/7)+"em")),Le(2),Hi(t.name),Le(1),$e("ngIf",i.seasonTimes),Le(1),$e("ngClass",vn(5,6,i.loadingArray)?"loading":""),Le(2),$e("ngForOf",t.days),Le(1),$e("ngIf",i.downloadButtons)}}function Jde(n,e){1&n&&(ke(0,"mat-icon",22),it(1,"refresh"),Ne())}function Qde(n,e){1&n&&(ke(0,"mat-icon",37),it(1," trending_up "),Ne())}function eue(n,e){1&n&&(ke(0,"mat-icon",38),it(1," trending_flat "),Ne())}function tue(n,e){1&n&&(ke(0,"mat-icon",39),it(1," trending_down "),Ne())}function nue(n,e){1&n&&(ke(0,"mat-icon",37),it(1," trending_up "),Ne())}function iue(n,e){1&n&&(ke(0,"mat-icon",38),it(1," trending_flat "),Ne())}function rue(n,e){1&n&&(ke(0,"mat-icon",39),it(1," trending_down "),Ne())}function sue(n,e){if(1&n&&(ke(0,"div",24),mt(1,nue,2,0,"mat-icon",25),mt(2,iue,2,0,"mat-icon",26),mt(3,rue,2,0,"mat-icon",27),ke(4,"div",28)(5,"div",29)(6,"div",30),it(7),ft(8,"async"),ft(9,"manifest"),Ne(),qt(10,"img",41),ft(11,"async"),ft(12,"manifest"),ft(13,"async"),ft(14,"manifest"),Ne(),ke(15,"div",31)(16,"div",32)(17,"div",33),it(18),Ne(),ke(19,"div",34),it(20,"13 week avg"),Ne()(),ke(21,"div",35)(22,"div",33),it(23),Ne(),ke(24,"div",34),it(25,"52 week avg"),Ne()()()()()),2&n){const t=Jt().$implicit,i=Jt(2);Le(1),$e("ngIf",t.quarter>t.year),Le(1),$e("ngIf",t.quarter===t.year),Le(1),$e("ngIf",t.quarter60?i.Math.floor(t.quarter/60)+"h"+t.quarter%60:t.quarter,"m/week"),Le(5),xs("",t.year>60?i.Math.floor(t.year/60)+"h"+t.year%60:t.year,"m/week")}}function oue(n,e){if(1&n&&(av(0),mt(1,sue,26,23,"div",40),cv()),2&n){const t=e.$implicit;Le(1),$e("ngIf",t.quarter>0||t.year>0)}}function aue(n,e){if(1&n&&(ke(0,"div",23)(1,"div",24),mt(2,Qde,2,0,"mat-icon",25),ft(3,"loadingReduce"),mt(4,eue,2,0,"mat-icon",26),ft(5,"loadingReduce"),mt(6,tue,2,0,"mat-icon",27),ft(7,"loadingReduce"),ke(8,"div",28)(9,"div",29)(10,"div",30),it(11,"All Activities"),Ne()(),ke(12,"div",31)(13,"div",32)(14,"div",33),it(15),Ne(),ke(16,"div",34),it(17,"13 week avg"),Ne()(),ke(18,"div",35)(19,"div",33),it(20),Ne(),ke(21,"div",34),it(22,"52 week avg"),Ne()()()()(),mt(23,oue,2,1,"ng-container",36),Ne()),2&n){const t=Jt();Le(2),$e("ngIf",!vn(3,6,t.loadingArray)&&t.getOverallTrend().quarter>t.getOverallTrend().year),Le(2),$e("ngIf",!vn(5,8,t.loadingArray)&&t.getOverallTrend().quarter===t.getOverallTrend().year),Le(2),$e("ngIf",!vn(7,10,t.loadingArray)&&t.getOverallTrend().quarter60?t.Math.floor(t.getOverallTrend().quarter/60)+"h"+t.getOverallTrend().quarter%60:t.getOverallTrend().quarter,"m/week"),Le(5),xs("",t.getOverallTrend().year>60?t.Math.floor(t.getOverallTrend().year/60)+"h"+t.getOverallTrend().year%60:t.getOverallTrend().year,"m/week"),Le(3),$e("ngForOf",t.getModeTrends())}}class ob{constructor(e,t,i,r,s,o){this.dialog=t,this.manifestService=i,this.bungieQueue=r,this.bungieAuth=s,this.zone=o,this.membershipDataForCurrentUser$=new er(void 0),this.accountResponse$=new er([]),this.displayName="",this.downloadLink="",this.downloadButtons=!0,this.seasonTimes=!0,this.poi=!0,this.Math=Math,this.locale=e}addDay(e){this.days[e.getUTCFullYear()]||(this.days[e.getUTCFullYear()]={}),this.days[e.getUTCFullYear()][e.getUTCMonth()+1]||(this.days[e.getUTCFullYear()][e.getUTCMonth()+1]={}),this.days[e.getUTCFullYear()][e.getUTCMonth()+1][e.getUTCDate()]||(this.days[e.getUTCFullYear()][e.getUTCMonth()+1][e.getUTCDate()]={date:new Date(e),activities:[]}),this.seasons.some(t=>{if(e>=t.startDate)return t.days.push(this.days[e.getUTCFullYear()][e.getUTCMonth()+1][e.getUTCDate()]),!0}),this.flatDays.push(this.days[e.getUTCFullYear()][e.getUTCMonth()+1][e.getUTCDate()].activities)}ngOnInit(){this.loadingArray=[],this.calendarFilter="0",this.subs=[],this.activities=[],this.days={},this.flatDays=[],this.oneQuarterAgo=new Date((new Date).setDate((new Date).getDate()-91)),this.oneYearAgo=new Date((new Date).setDate((new Date).getDate()-364)),this.modeTrends={},this.overallTrend={quarter:[],year:[]},this.seasons=[{number:23,name:"Season of the Wish",days:[],startDate:new Date("2023-11-28")},{number:22,name:"Season of the Witch",days:[],startDate:new Date("2023-08-22")},{number:21,name:"Season of the Deep",days:[],startDate:new Date("2023-05-23")},{number:20,name:"Season of Defiance",days:[],startDate:new Date("2023-02-28")},{number:19,name:"Season of the Seraph",days:[],startDate:new Date("2022-12-06")},{number:18,name:"Season of Plunder",days:[],startDate:new Date("2022-08-23")},{number:17,name:"Season of the Haunted",days:[],startDate:new Date("2022-05-24")},{number:16,name:"Season of the Risen",days:[],startDate:new Date("2022-02-22")},{number:15,name:"Season of the Lost",days:[],startDate:new Date("2021-08-24")},{number:14,name:"Season of the Splicer",days:[],startDate:new Date("2021-05-11")},{number:13,name:"Season of the Chosen",days:[],startDate:new Date("2021-02-09")},{number:12,name:"Season of the Hunt",days:[],startDate:new Date("2020-11-10")},{number:11,name:"Season of Arrivals",days:[],startDate:new Date("2020-06-09")},{number:10,name:"Season of the Worthy",days:[],startDate:new Date("2020-03-10")},{number:9,name:"Season of Dawn",days:[],startDate:new Date("2019-12-10")},{number:8,name:"Season of Undying",days:[],startDate:new Date("2019-10-01")},{number:7,name:"Season of Opulence",days:[],startDate:new Date("2019-06-04")},{number:6,name:"Season of the Drifter",days:[],startDate:new Date("2019-03-05")},{number:5,name:"Season of the Forge",days:[],startDate:new Date("2018-12-04")},{number:4,name:"Season of the Outlaw",days:[],startDate:new Date("2018-09-04")},{number:3,name:"Warmind",days:[],startDate:new Date("2018-05-08")},{number:2,name:"Curse of Osiris",days:[],startDate:new Date("2017-12-05")},{number:1,name:"The Red War",days:[],startDate:new Date("2017-09-05")}],this.flatDaysBS=new er([]),this.manifestService.state$.subscribe(s=>{s.loaded&&(this.modeOptions=Object.keys(this.manifestService.defs.ActivityMode.dbTable).map(o=>this.manifestService.defs.ActivityMode.dbTable[o].modeType).sort())}),this.errorStatus="",this.errorMessage="";const e=new Date("2017-09-05T00:00:00Z"),t=new Date;for(;e<=t;)this.addDay(e),e.setDate(e.getDate()+1);this.seasons.reverse(),this.seasons.forEach((s,o)=>{s.startDateString=DD(s.startDate,"shortDate",this.locale||"en-US"),this.seasons[o+1]&&(s.endDateString=DD(this.seasons[o+1].startDate,"shortDate",this.locale||"en-US"))}),this.flatDaysBS.next(this.flatDays),this.yearKeys=Object.keys(this.days),this.monthKeys={},this.monthOffsets={2017:{9:0}};let i=0,r=28;this.dayKeys={},this.yearKeys.forEach(s=>{this.monthKeys[s]=Object.keys(this.days[s]),this.monthOffsets[s]||(this.monthOffsets[s]={}),this.dayKeys[s]={},this.monthKeys[s].forEach(o=>{this.monthOffsets[s][o]||(this.monthOffsets[s][o]=(r+i)%7,r=Object.keys(this.days[s][o]).length,i=this.monthOffsets[s][o]),this.dayKeys[s][o]=Object.keys(this.days[s][o])})}),this.subs.push(this.bungieAuth.hasValidAccessToken$.pipe(Rc(),Dr(s=>{s&&this.bungieQueue.addToQueue("getProfile",V8,c=>{this.membershipDataForCurrentUser$.next(c)})})).subscribe()),this.subs.push(this.membershipDataForCurrentUser$.pipe(Rc(),wo(s=>ig(s?.Response?.destinyMemberships.map(o=>{const a={loading:!0};this.loadingArray.push(a);const c=new er(void 0),{membershipId:u,membershipType:p}=o;return this.bungieQueue.addToQueue("getProfile",N8,x=>{x&&1===x.ErrorCode&&x?.Response?.characters?.length>0?ig(x?.Response?.characters.map(T=>{const N={loading:!0};this.loadingArray.push(N);const k=new er(void 0),{characterId:A}=T,H=T.merged?.allTime?.secondsPlayed?.basic?.value;return this.bungieQueue.addToQueue("getProfile",L8,K=>{if(1===K.ErrorCode){const he=K;he.Response.character=K.Response.character??{data:{characterId:A,membershipId:u,membershipType:p,minutesPlayedTotal:H?this.Math.floor(H/60):0}},k.next(he)}N.loading=!1,k.complete()},{characterId:A,destinyMembershipId:u,membershipType:p,components:[200]}),k})??Fc).pipe(Gr(1)).subscribe(T=>{c.next(T),a.loading=!1,c.complete()}):(a.loading=!1,c.complete())},{destinyMembershipId:u,membershipType:p,groups:[1]}),c})??Fc)),_t(s=>this.accountResponse$.next(s))).subscribe()),this.membershipDataForCurrentUser$.pipe(Rc(),_t(s=>{this.displayName=s?.Response?.bungieNetUser?.displayName})).subscribe(),this.characters$=this.accountResponse$.pipe(Rc(),_t(s=>{const o=[];for(const a of s)if(a)for(const c of a)try{o.push(c.Response.character.data)}catch{}return o})),this.minutesPlayedTotal=this.characters$.pipe(_t(s=>{let o=0;return s.forEach(a=>{o+=+a.minutesPlayedTotal}),o})),this.subs.push(this.characters$.pipe(Rc()).subscribe(s=>{this.activities=[],s.forEach(o=>{const a={destinyMembershipId:o.membershipId,membershipType:o.membershipType,characterId:o.characterId,mode:0,count:250};this.addHistorySub({...a,page:0}),this.addHistorySub({...a,page:1}),this.addHistorySub({...a,page:2})})}))}addHistorySub(e){const t={loading:!0};this.loadingArray.push(t);const{page:i}=e,r=new er(void 0);this.bungieQueue.addToQueue("getActivityHistory",B8,a=>{r.next(a)},e),this.subs.push(r.subscribe(a=>{1!==a?.ErrorCode&&a?.ErrorStatus&&(this.errorStatus=a.ErrorStatus,this.errorMessage=a.Message),a?.Response.activities&&a?.Response.activities.length&&(this.addHistorySub({...e,page:i+3}),a.Response.activities.forEach(c=>{c.characterId=e.characterId;const p=(new Date(c.period).getTime()-612e5)/1e3+c.values.startSeconds.basic.value,g=p+c.values.timePlayedSeconds.basic.value;c.startDate=new Date(1e3*p),c.endDate=new Date(1e3*g),this.activities.push(c);try{this.days[c.startDate.getUTCFullYear()][c.startDate.getUTCMonth()+1][c.startDate.getUTCDate()].activities.push(c),c.endDate>this.oneYearAgo&&(c.activityDetails.modes.forEach(v=>{this.modeTrends[v]||(this.modeTrends[v]={quarter:[],year:[]}),this.modeTrends[v].year.push(c),c.endDate>this.oneQuarterAgo&&this.modeTrends[v].quarter.push(c)}),this.overallTrend.year.push(c),c.endDate>this.oneQuarterAgo&&this.overallTrend.quarter.push(c))}catch{}this.flatDaysBS.next(this.flatDays)})),a&&(t.loading=!1,this.flatDaysBS.next(this.flatDays))}))}ngOnDestroy(){this.subs.forEach(e=>e.unsubscribe())}seasonActivities(e){return e.reduce((t,i)=>t.concat(i.activities),[])}three(e,t,i){this.zone.runOutsideAngular(r=>{let s,o,a,c,u,p,g,v,y;for(let N=1;N<=i;N++)s=document.getElementById("download"+N),s.setAttribute("disabled","true");s=document.getElementById("download"+e.number),s.innerHTML="Generating...";const x=2.5;!function T(){const N=new A2,k=2.5,A=Math.sqrt(7.25-5*Math.cos(Math.PI/2)),H=Math.acos((A*A+k*k-1)/(2*A*k));u=Math.ceil(e.days.length/7+2)*x,p=k*x,g=9*x,o=new tu(u,p,g);const G=new sE;a=new vr(o,G);const X=a.geometry.getAttribute("position");X.setXYZ(2,X.getX(2)+x,X.getY(2),X.getZ(2)+x),X.setXYZ(3,X.getX(3)+x,X.getY(3),X.getZ(3)-x),X.setXYZ(6,X.getX(6)-x,X.getY(6),X.getZ(6)-x),X.setXYZ(7,X.getX(7)-x,X.getY(7),X.getZ(7)+x),X.setXYZ(12,X.getX(12)-x,X.getY(12),X.getZ(12)+x),X.setXYZ(13,X.getX(13)+x,X.getY(13),X.getZ(13)+x),X.setXYZ(14,X.getX(14)-x,X.getY(14),X.getZ(14)-x),X.setXYZ(15,X.getX(15)+x,X.getY(15),X.getZ(15)-x),X.setXYZ(18,X.getX(18)-x,X.getY(18),X.getZ(18)+x),X.setXYZ(19,X.getX(19)+x,X.getY(19),X.getZ(19)+x),X.setXYZ(22,X.getX(22)+x,X.getY(22),X.getZ(22)-x),X.setXYZ(23,X.getX(23)-x,X.getY(23),X.getZ(23)-x),u=(Math.ceil(e.days.length/7+2)/2-1.5)*x,p=-p/2,g=7.5,a.position.set(u,p,g),a.updateMatrix();for(let K=0;KQe+Pe.values.timePlayedSeconds.basic.value,0)/86400*24;u=2.5,p=ge*x,g=2.5,o=new tu(u,p,g),c=new vr(o,G),u=(Math.floor(he/7)-52*Math.floor(he/364))*x,p=ge/2*x,g=(he%7+7*Math.floor(he/364))*x,c.position.set(u,p,g),c.updateMatrix(),a=br.union(a,c)}}(new Vde).load("assets/fonts/helvetiker_bold.typeface.json",function(K){v=2.5,y=.625,o=new yE(e.name,{font:K,size:v,height:y}),o.computeBoundingBox(),u=((Math.ceil(e.days.length/7)-o.boundingBox.max.x/x)/2-.5)*x,p=-4.375,g=20.5,c=new vr(o,G),c.position.set(u,p,g),c.rotateX(-H),c.updateMatrix(),a=br.union(a,c),c.geometry.dispose(),o=new yE(t,{font:K,size:v,height:y}),c=new vr(o,G),o.computeBoundingBox(),u=((Math.ceil(e.days.length/7)-o.boundingBox.max.x/x)/2-.5+o.boundingBox.max.x/x)*x,p=-4.375,g=-5.5,c.position.set(u,p,g),c.rotateX(H),c.rotateY(Math.PI),c.updateMatrix(),a=br.union(a,c),e.startDateString&&(o=new yE(e.startDateString,{font:K,size:v,height:y}),c=new vr(o,G),o.computeBoundingBox(),u=-5.5,p=-4.375,g=((7-o.boundingBox.max.x/x)/2-.5)*x,c.position.set(u,p,g),c.rotateZ(-H),c.rotateY(-Math.PI/2),c.updateMatrix(),a=br.union(a,c)),e.endDateString&&(o=new yE(e.endDateString,{font:K,size:v,height:y,curveSegments:12,bevelEnabled:!0,bevelThickness:0,bevelSize:0,bevelOffset:0,bevelSegments:0}),c=new vr(o,G),o.computeBoundingBox(),u=(Math.ceil(e.days.length/7)+1.2)*x,p=-4.375,g=((7-o.boundingBox.max.x/x)/2-.5+o.boundingBox.max.x/x)*x,c.position.set(u,p,g),c.rotateZ(H),c.rotateY(Math.PI/2),c.updateMatrix(),a=br.union(a,c)),a.geometry.rotateX(Math.PI/2),a.updateMatrix(),N.add(a);const he=new Bde,De=document.createElement("a");De.style.display="none",document.body.appendChild(De);const Te=he.parse(N);De.href=URL.createObjectURL(new Blob([Te],{type:"text/plain"})),De.download=`${e.name}.stl`,De.click(),N.remove(a),a.geometry.dispose(),s.innerHTML="Download STL";for(let ge=1;ge<=i;ge++)s=document.getElementById("download"+ge),s.removeAttribute("disabled")})}()})}getModeTrends(){return Object.keys(this.modeTrends).map(e=>({mode:Number(e),quarter:Math.round(this.modeTrends[Number(e)].quarter.reduce((t,i)=>t+(i.endDate-i.startDate),0)/13),year:Math.round(this.modeTrends[Number(e)].year.reduce((t,i)=>t+(i.endDate-i.startDate),0)/52)})).sort((e,t)=>t.year-e.year).sort((e,t)=>t.quarter-e.quarter).map(e=>({...e,quarter:Math.round(e.quarter/6e4),year:Math.round(e.year/6e4)}))}getOverallTrend(){return{quarter:Math.round(this.overallTrend.quarter.reduce((e,t)=>e+(t.endDate-t.startDate),0)/13/6e4),year:Math.round(this.overallTrend.year.reduce((e,t)=>e+(t.endDate-t.startDate),0)/52/6e4)}}}function cue(n,e){if(1&n&&(ke(0,"mat-card",1),it(1),Ne()),2&n){const t=e.$implicit;Le(1),xs(" ",t.AlertHtml,"\n")}}ob.\u0275fac=function(e){return new(e||ob)(ie(Ac),ie(Zw),ie(uh),ie(Jf),ie(qd),ie(Xt))},ob.\u0275cmp=Ln({type:ob,selectors:[["app-guardian-3d"]],decls:59,vars:40,consts:[["appearance","outlined","class","errorStatus",4,"ngIf"],[1,"mat-body-2"],[1,"mat-subtitle-2"],["aria-label","Search for Guardian","class","spinner",4,"ngIf"],[3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[1,"calYear"],["class","calMonth",3,"ngStyle",4,"ngFor","ngForOf"],[1,"trends-header"],["class","trending_loading",4,"ngIf"],["class","trends",4,"ngIf"],["appearance","outlined",1,"errorStatus"],["aria-label","Search for Guardian",1,"spinner"],[3,"value"],[1,"calMonth",3,"ngStyle"],[1,"monthLabel","mat-caption"],["class","monthLabel mat-caption",4,"ngIf"],[1,"dayWrapper",3,"ngClass"],["class","calDay",3,"ngClass","ngStyle","matTooltip",4,"ngFor","ngForOf"],["mat-button","","class","downloadButtons",3,"disabled","id","click",4,"ngIf"],[1,"calDay",3,"ngClass","ngStyle","matTooltip"],["mat-button","",1,"downloadButtons",3,"disabled","id","click"],[1,"trending_loading"],[1,"trends"],[1,"trend"],["class","trend-up",4,"ngIf"],["class","trend-flat",4,"ngIf"],["class","trend-down",4,"ngIf"],[1,"trend-main"],[1,"trend-header"],[1,"trend-name"],[1,"trend-values"],[1,"trend-quarter"],[1,"trend-value"],[1,"trend-time"],[1,"trend-year"],[4,"ngFor","ngForOf"],[1,"trend-up"],[1,"trend-flat"],[1,"trend-down"],["class","trend",4,"ngIf"],[1,"trend-icon",3,"src","alt"]],template:function(e,t){1&e&&(mt(0,zde,5,2,"mat-card",0),ke(1,"div",1),it(2," Name: "),ke(3,"span",2),it(4),Ne(),qt(5,"br"),it(6," Total Time in Destiny 2: "),ke(7,"span",2),it(8),ft(9,"hoursPlayed"),ft(10,"async"),Ne(),it(11," = "),ke(12,"span",2),it(13),ft(14,"parseMinutesPlayed"),ft(15,"async"),Ne(),qt(16,"br"),it(17," Total Time in Activities: "),ke(18,"span",2),it(19),ft(20,"activitiesTotalHours"),Ne(),it(21," = "),ke(22,"span",2),it(23),ft(24,"activitiesTotalTime"),Ne(),qt(25,"br"),it(26," Destiny 2 Activity Count: "),ke(27,"span",2),it(28),Ne(),mt(29,Gde,2,0,"mat-icon",3),ft(30,"loadingReduce"),qt(31,"br"),it(32),ft(33,"currentStreak"),qt(34,"br"),it(35),ft(36,"longestStreaks"),qt(37,"br"),it(38," STL Download Buttons: "),ke(39,"mat-checkbox",4),Gn("ngModelChange",function(r){return t.downloadButtons=r}),Ne(),qt(40,"br"),it(41," Points of Interest: "),ke(42,"mat-checkbox",4),Gn("ngModelChange",function(r){return t.poi=r}),Ne(),qt(43,"br"),it(44," Seasonal Times: "),ke(45,"mat-checkbox",4),Gn("ngModelChange",function(r){return t.seasonTimes=r}),Ne(),qt(46,"br"),it(47," Filter Heatmap: "),ke(48,"mat-form-field")(49,"mat-select",4),Gn("ngModelChange",function(r){return t.calendarFilter=r}),mt(50,jde,4,7,"mat-option",5),Ne()()(),ke(51,"div",6),mt(52,Zde,8,10,"div",7),Ne(),ke(53,"h3",8),it(54,"Trends"),Ne(),mt(55,Jde,2,0,"mat-icon",9),ft(56,"loadingReduce"),mt(57,aue,24,12,"div",10),ft(58,"loadingReduce")),2&e&&($e("ngIf",t.errorStatus),Le(4),Hi(t.displayName),Le(4),Hi(vn(9,18,vn(10,20,t.minutesPlayedTotal))),Le(5),Hi(vn(14,22,vn(15,24,t.minutesPlayedTotal))),Le(6),Hi(vn(20,26,t.activities)),Le(4),Hi(vn(24,28,t.activities)),Le(5),Hi(t.activities.length),Le(1),$e("ngIf",vn(30,30,t.loadingArray)),Le(3),xs(" Current Streak: ",vn(33,32,t.flatDays),""),Le(3),xs(" Longest Streaks: ",vn(36,34,t.flatDays),""),Le(4),$e("ngModel",t.downloadButtons),Le(3),$e("ngModel",t.poi),Le(3),$e("ngModel",t.seasonTimes),Le(4),$e("ngModel",t.calendarFilter),Le(1),$e("ngForOf",t.modeOptions),Le(2),$e("ngForOf",t.seasons),Le(3),$e("ngIf",vn(56,36,t.loadingArray)),Le(2),$e("ngIf",!vn(58,38,t.loadingArray)))},dependencies:[eg,tg,Yu,nw,cN,bN,nS,rA,_4,b4,BT,Uw,GT,zT,aT,Ew,Rf,k3,Yf,Xf,Tg,Ag,kg,Ig,Zf,Fg,Rg,Pg],styles:['.calYear[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;margin-top:1em}.calMonth[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin-right:.5em;margin-bottom:.5em}.dayWrapper[_ngcontent-%COMP%]{display:flex;flex-direction:column;height:7em;flex-wrap:wrap}.calDay[_ngcontent-%COMP%]{display:block;width:1em;height:1em;box-sizing:border-box;cursor:pointer;transition:transform .2s;background-position:center;background-size:16px}.calDay[_ngcontent-%COMP%]:hover.icon{transform:scale(1.5);z-index:999;box-shadow:0 0 8px 3px #696969;opacity:1}.calDay[_ngcontent-%COMP%]:before{content:" ";top:0;left:0;width:100%;height:100%;filter:invert(1);display:block;-webkit-mask-size:contain;mask-size:contain}.calDay.red-war[_ngcontent-%COMP%]:before{-webkit-mask-image:url(red-war.3eff2acca21c93ca.png);mask-image:url(red-war.3eff2acca21c93ca.png);background-color:inherit}.calDay.curse-of-osiris[_ngcontent-%COMP%]:before{-webkit-mask-image:url(curse-of-osiris.6c410487c8c1193b.png);mask-image:url(curse-of-osiris.6c410487c8c1193b.png);background-color:inherit}.calDay.dawning[_ngcontent-%COMP%]:before{-webkit-mask-image:url(dawning.645be67ef31d090a.png);mask-image:url(dawning.645be67ef31d090a.png);background-color:inherit}.calDay.crimson-days[_ngcontent-%COMP%]:before{-webkit-mask-image:url(crimson-days.aa88f4d939be6b4f.png);mask-image:url(crimson-days.aa88f4d939be6b4f.png);background-color:inherit}.calDay.warmind[_ngcontent-%COMP%]:before{-webkit-mask-image:url(warmind.af5f3877c551d0a9.png);mask-image:url(warmind.af5f3877c551d0a9.png);background-color:inherit}.calDay.moments-of-triumph[_ngcontent-%COMP%]:before{-webkit-mask-image:url(moments-of-triumph.3dd2b9684009007a.png);mask-image:url(moments-of-triumph.3dd2b9684009007a.png);background-color:inherit}.calDay.solstice[_ngcontent-%COMP%]:before{-webkit-mask-image:url(solstice.cb7917ad27da3310.png);mask-image:url(solstice.cb7917ad27da3310.png);background-color:inherit}.calDay.forsaken[_ngcontent-%COMP%]:before{-webkit-mask-image:url(forsaken.f61a352f91528263.png);mask-image:url(forsaken.f61a352f91528263.png);background-color:inherit}.calDay.festival-of-the-lost[_ngcontent-%COMP%]:before{-webkit-mask-image:url(festival-of-the-lost.656fb66ff23db261.png);mask-image:url(festival-of-the-lost.656fb66ff23db261.png);background-color:inherit}.calDay.season-of-the-forge[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-forge.a88ddb98b2a97a0e.png);mask-image:url(season-of-the-forge.a88ddb98b2a97a0e.png);background-color:inherit}.calDay.season-of-the-drifter[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-drifter.1867ff7e8c88eda5.png);mask-image:url(season-of-the-drifter.1867ff7e8c88eda5.png);background-color:inherit}.calDay.revelry[_ngcontent-%COMP%]:before{-webkit-mask-image:url(revelry.4a84f0f680e2599d.png);mask-image:url(revelry.4a84f0f680e2599d.png);background-color:inherit}.calDay.season-of-opulence[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-opulence.3b878d66365d9cc6.png);mask-image:url(season-of-opulence.3b878d66365d9cc6.png);background-color:inherit}.calDay.shadowkeep[_ngcontent-%COMP%]:before{-webkit-mask-image:url(shadowkeep.2412f7e9615345e8.png);mask-image:url(shadowkeep.2412f7e9615345e8.png);background-color:inherit}.calDay.season-of-the-undying[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-undying.a0948d4e1e5532ab.png);mask-image:url(season-of-the-undying.a0948d4e1e5532ab.png);background-color:inherit}.calDay.season-of-dawn[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-dawn.152fa5fa97203b11.png);mask-image:url(season-of-dawn.152fa5fa97203b11.png);background-color:inherit}.calDay.season-of-the-worthy[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-worthy.97fe2af14ad98313.png);mask-image:url(season-of-the-worthy.97fe2af14ad98313.png);background-color:inherit}.calDay.guardian-games[_ngcontent-%COMP%]:before{-webkit-mask-image:url(guardian-games.1458a297ee32ae52.png);mask-image:url(guardian-games.1458a297ee32ae52.png);background-color:inherit}.calDay.season-of-arrivals[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-arrivals.649a4db068c154bf.png);mask-image:url(season-of-arrivals.649a4db068c154bf.png);background-color:inherit}.calDay.beyond-light[_ngcontent-%COMP%]:before{-webkit-mask-image:url(beyond-light.8fb053c5e78ee3c1.png);mask-image:url(beyond-light.8fb053c5e78ee3c1.png);background-color:inherit}.calDay.season-of-the-hunt[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-hunt.23c0a09811c2dd46.png);mask-image:url(season-of-the-hunt.23c0a09811c2dd46.png);background-color:inherit}.calDay.season-of-the-chosen[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-chosen.9d73f0c6a48c8b28.png);mask-image:url(season-of-the-chosen.9d73f0c6a48c8b28.png);background-color:inherit}.calDay.season-of-the-splicer[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-splicer.5cff32b822f61b20.png);mask-image:url(season-of-the-splicer.5cff32b822f61b20.png);background-color:inherit}.calDay.season-of-the-lost[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-lost.10a416eb34d1915e.png);mask-image:url(season-of-the-lost.10a416eb34d1915e.png);background-color:inherit}.calDay.thirtieth-anniversary[_ngcontent-%COMP%]:before{-webkit-mask-image:url(thirtieth-anniversary.3aa725ceedf9157d.png);mask-image:url(thirtieth-anniversary.3aa725ceedf9157d.png);background-color:inherit}.calDay.witch-queen[_ngcontent-%COMP%]:before{-webkit-mask-image:url(witch-queen.4fdd67baed2eb636.png);mask-image:url(witch-queen.4fdd67baed2eb636.png);background-color:inherit}.calDay.season-of-the-haunted[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-haunted.d4556f3df7022cf7.png);mask-image:url(season-of-the-haunted.d4556f3df7022cf7.png);background-color:inherit}.calDay.iron-banner[_ngcontent-%COMP%]:before{-webkit-mask-image:url(iron-banner.0cccf5ef6d1f8153.png);mask-image:url(iron-banner.0cccf5ef6d1f8153.png);background-color:inherit}.calDay.solstice2022[_ngcontent-%COMP%]:before{-webkit-mask-image:url(solstice2022.4129b7a862b1dd62.png);mask-image:url(solstice2022.4129b7a862b1dd62.png);background-color:inherit}.calDay.raid[_ngcontent-%COMP%]:before{-webkit-mask-image:url(raid.c24a762febb5d48f.png);mask-image:url(raid.c24a762febb5d48f.png);background-color:inherit}.calDay.season-of-plunder[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-plunder.a82a4f350d3ff629.png);mask-image:url(season-of-plunder.a82a4f350d3ff629.png);background-color:inherit}.calDay.dungeon[_ngcontent-%COMP%]:before{-webkit-mask-image:url(dungeon.1e3bb371bcf5c37b.png);mask-image:url(dungeon.1e3bb371bcf5c37b.png);background-color:inherit}.calDay.season-of-the-seraph[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-seraph.30ab5d205a09f6c4.png);mask-image:url(season-of-the-seraph.30ab5d205a09f6c4.png);background-color:inherit}.calDay.lightfall[_ngcontent-%COMP%]:before{-webkit-mask-image:url(lightfall.cbc105e4dbc42ae7.png);mask-image:url(lightfall.cbc105e4dbc42ae7.png);background-color:inherit}.calDay.season-of-the-deep[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-deep.c79c733175700d33.png);mask-image:url(season-of-the-deep.c79c733175700d33.png);background-color:inherit}.calDay.exotic-quest[_ngcontent-%COMP%]:before{-webkit-mask-image:url(exotic-quest.bb278fc19eb3104c.png);mask-image:url(exotic-quest.bb278fc19eb3104c.png);background-color:inherit}.calDay.season-of-the-witch[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-witch.7978d2dee322e4cf.png);mask-image:url(season-of-the-witch.7978d2dee322e4cf.png);background-color:inherit}.calDay.season-of-the-wish[_ngcontent-%COMP%]:before{-webkit-mask-image:url(season-of-the-wish.97577548fcd7897c.png);mask-image:url(season-of-the-wish.97577548fcd7897c.png);background-color:inherit}@media (prefers-reduced-motion){.calDay[_ngcontent-%COMP%]{transition:none}.calDay[_ngcontent-%COMP%]:hover{transform:none;box-shadow:none;background-image:none}}.loading[_ngcontent-%COMP%] > .calDay[_ngcontent-%COMP%]{cursor:progress}.yearLabel[_ngcontent-%COMP%]{display:flex;align-items:center}.yearLabel[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{display:block;transform:rotate(-90deg)}.monthSpacer[_ngcontent-%COMP%]{width:1em}.monthLabel[_ngcontent-%COMP%]{font-size:.75em;min-width:13em;text-align:center}.downloadButtons[_ngcontent-%COMP%]{font-size:.75em;min-width:12em}.release[_ngcontent-%COMP%]:before{width:100%;height:100%}.raid[_ngcontent-%COMP%]:before, .event[_ngcontent-%COMP%]:before{width:100%;height:100%}@media (prefers-color-scheme: dark){.inactive[_ngcontent-%COMP%]{opacity:.15}}.spinner[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_spin 3s infinite linear;height:1em;width:1em;display:inline-block;line-height:1em;font-size:.75em}@keyframes _ngcontent-%COMP%_spin{0%{-webkit-transform:rotate(0deg)}to{-webkit-transform:rotate(360deg)}}@keyframes _ngcontent-%COMP%_spinX{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.errorStatus[_ngcontent-%COMP%]{margin-bottom:.5em}.trends-header[_ngcontent-%COMP%]{font-family:Roboto,Helvetica Neue,sans-serif}.trending_loading[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_spin 3s infinite linear}.trends[_ngcontent-%COMP%]{font-family:Roboto,Helvetica Neue,sans-serif;display:flex;flex-wrap:wrap;gap:1em}.trends[_ngcontent-%COMP%] .trend-up[_ngcontent-%COMP%]{color:green}.trends[_ngcontent-%COMP%] .trend-down[_ngcontent-%COMP%]{color:red}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.75em;min-width:17em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-header[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{height:1em}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-time[_ngcontent-%COMP%]{font-size:.75em;opacity:.6}.trends[_ngcontent-%COMP%] .trend[_ngcontent-%COMP%] .trend-values[_ngcontent-%COMP%]{display:flex;gap:.75em}']});class ab{constructor(e){this.http=e}ngOnInit(){this.bungieStatus=new er([]),this.bungieSub=this.http.get("https://www.bungie.net/Platform/GlobalAlerts/").pipe(da(e=>Pc(e.error||"Server error"))).subscribe(e=>{try{this.bungieStatus.next(e.Response)}catch{}})}}function lue(n,e){1&n&&qt(0,"app-guardian")}function due(n,e){1&n&&qt(0,"app-guardian-3d")}ab.\u0275fac=function(e){return new(e||ab)(ie(Ju))},ab.\u0275cmp=Ln({type:ab,selectors:[["app-bungie-status"]],decls:2,vars:3,consts:[["appearance","outlined",4,"ngFor","ngForOf"],["appearance","outlined"]],template:function(e,t){1&e&&(mt(0,cue,2,1,"mat-card",0),ft(1,"async")),2&e&&$e("ngForOf",vn(1,1,t.bungieStatus))},dependencies:[tg,Uw,Rf]});class cb{calendarChange(e){this.calendar=e}constructor(e){this.bungieAuth=e}}cb.\u0275fac=function(e){return new(e||cb)(ie(qd))},cb.\u0275cmp=Ln({type:cb,selectors:[["app-root"]],decls:8,vars:7,consts:[[1,"appWrapper"],[1,"bungieStatus"],[1,"nav",3,"calendar","calendarChange"],[4,"ngIf"]],template:function(e,t){1&e&&(qt(0,"destiny-webring"),ke(1,"div",0),qt(2,"app-bungie-status",1),ke(3,"app-nav",2),Gn("calendarChange",function(r){return t.calendarChange(r)}),Ne(),mt(4,lue,1,0,"app-guardian",3),ft(5,"async"),mt(6,due,1,0,"app-guardian-3d",3),ft(7,"async"),Ne()),2&e&&(Le(3),$e("calendar",t.calendar),Le(1),$e("ngIf",vn(5,3,"gregorian"===t.calendar&&t.bungieAuth.hasValidAccessToken$)),Le(2),$e("ngIf",vn(7,5,"bungie"===t.calendar&&t.bungieAuth.hasValidAccessToken$)))},dependencies:[Yu,Dg,Sy,Dy,ob,ab,Rf],styles:[".appWrapper[_ngcontent-%COMP%]{display:flex;flex-direction:column;position:absolute;min-height:100%;top:0;left:.5em}.bungieStatus[_ngcontent-%COMP%], .nav[_ngcontent-%COMP%]{margin-top:.5em}.content[_ngcontent-%COMP%]{flex-grow:1}.footer[_ngcontent-%COMP%]{margin-bottom:.5em}"]});class lb{constructor(){}ngOnInit(){}}lb.\u0275fac=function(e){return new(e||lb)},lb.\u0275cmp=Ln({type:lb,selectors:[["app-front-page"]],decls:2,vars:0,consts:[[1,"mat-body-2"]],template:function(e,t){1&e&&(ke(0,"p",0),it(1,"Welcome back, Guardian."),Ne())}});const uue=[{path:"",component:lb},{path:"**",redirectTo:"",pathMatch:"full"}];class k0{}k0.\u0275fac=function(e){return new(e||k0)},k0.\u0275mod=Mt({type:k0}),k0.\u0275inj=On({imports:[C8.forRoot(uue,{}),C8]});const vp=void 0,fue=["en",[["a","p"],["AM","PM"],vp],[["AM","PM"],vp,vp],[["S","M","T","W","T","F","S"],["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],["Su","Mo","Tu","We","Th","Fr","Sa"]],vp,[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],["January","February","March","April","May","June","July","August","September","October","November","December"]],vp,[["B","A"],["BC","AD"],["Before Christ","Anno Domini"]],0,[6,0],["M/d/yy","MMM d, y","MMMM d, y","EEEE, MMMM d, y"],["h:mm a","h:mm:ss a","h:mm:ss a z","h:mm:ss a zzzz"],["{1}, {0}",vp,"{1} 'at' {0}",vp],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"USD","$","US Dollar",{},"ltr",function hue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length;return 1===t&&0===i?1:5}],us=void 0,BV=["fr",[["AM","PM"],us,us],us,[["D","L","M","M","J","V","S"],["dim.","lun.","mar.","mer.","jeu.","ven.","sam."],["dimanche","lundi","mardi","mercredi","jeudi","vendredi","samedi"],["di","lu","ma","me","je","ve","sa"]],us,[["J","F","M","A","M","J","J","A","S","O","N","D"],["janv.","f\xe9vr.","mars","avr.","mai","juin","juil.","ao\xfbt","sept.","oct.","nov.","d\xe9c."],["janvier","f\xe9vrier","mars","avril","mai","juin","juillet","ao\xfbt","septembre","octobre","novembre","d\xe9cembre"]],us,[["av. J.-C.","ap. J.-C."],us,["avant J\xe9sus-Christ","apr\xe8s J\xe9sus-Christ"]],1,[6,0],["dd/MM/y","d MMM y","d MMMM y","EEEE d MMMM y"],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1} {0}","{1}, {0}","{1} '\xe0' {0}",us],[",","\u202f",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0\xa0%","#,##0.00\xa0\xa4","#E0"],"EUR","\u20ac","euro",{ARS:["$AR","$"],AUD:["$AU","$"],BEF:["FB"],BMD:["$BM","$"],BND:["$BN","$"],BYN:[us,"\u0440."],BZD:["$BZ","$"],CAD:["$CA","$"],CLP:["$CL","$"],CNY:[us,"\xa5"],COP:["$CO","$"],CYP:["\xa3CY"],EGP:[us,"\xa3E"],FJD:["$FJ","$"],FKP:["\xa3FK","\xa3"],FRF:["F"],GBP:["\xa3GB","\xa3"],GIP:["\xa3GI","\xa3"],HKD:[us,"$"],IEP:["\xa3IE"],ILP:["\xa3IL"],ITL:["\u20a4IT"],JPY:[us,"\xa5"],KMF:[us,"FC"],LBP:["\xa3LB","\xa3L"],MTP:["\xa3MT"],MXN:["$MX","$"],NAD:["$NA","$"],NIO:[us,"$C"],NZD:["$NZ","$"],PHP:[us,"\u20b1"],RHD:["$RH"],RON:[us,"L"],RWF:[us,"FR"],SBD:["$SB","$"],SGD:["$SG","$"],SRD:["$SR","$"],TOP:[us,"$T"],TTD:["$TT","$"],TWD:[us,"NT$"],USD:["$US","$"],UYU:["$UY","$"],WST:["$WS"],XCD:[us,"$"],XPF:["FCFP"],ZMW:[us,"Kw"]},"ltr",function pue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length,r=parseInt(n.toString().replace(/^[^e]*(e([-+]?\d+))?/,"$2"))||0;return 0===t||1===t?1:0===r&&0!==t&&t%1e6==0&&0===i||!(r>=0&&r<=5)?4:5}],lr=void 0,VV=["es",[["a.\xa0m.","p.\xa0m."],lr,lr],lr,[["D","L","M","X","J","V","S"],["dom","lun","mar","mi\xe9","jue","vie","s\xe1b"],["domingo","lunes","martes","mi\xe9rcoles","jueves","viernes","s\xe1bado"],["DO","LU","MA","MI","JU","VI","SA"]],lr,[["E","F","M","A","M","J","J","A","S","O","N","D"],["ene","feb","mar","abr","may","jun","jul","ago","sept","oct","nov","dic"],["enero","febrero","marzo","abril","mayo","junio","julio","agosto","septiembre","octubre","noviembre","diciembre"]],lr,[["a. C.","d. C."],lr,["antes de Cristo","despu\xe9s de Cristo"]],1,[6,0],["d/M/yy","d MMM y","d 'de' MMMM 'de' y","EEEE, d 'de' MMMM 'de' y"],["H:mm","H:mm:ss","H:mm:ss z","H:mm:ss (zzzz)"],["{1}, {0}",lr,lr,lr],[",",".",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0\xa0%","#,##0.00\xa0\xa4","#E0"],"EUR","\u20ac","euro",{AUD:[lr,"$"],BRL:[lr,"R$"],BYN:[lr,"\u0440."],CAD:[lr,"$"],CNY:[lr,"\xa5"],EGP:[],ESP:["\u20a7"],GBP:[lr,"\xa3"],HKD:[lr,"$"],ILS:[lr,"\u20aa"],INR:[lr,"\u20b9"],JPY:[lr,"\xa5"],KRW:[lr,"\u20a9"],MXN:[lr,"$"],NZD:[lr,"$"],PHP:[lr,"\u20b1"],RON:[lr,"L"],THB:["\u0e3f"],TWD:[lr,"NT$"],USD:["US$","$"],XAF:[],XCD:[lr,"$"],XOF:[]},"ltr",function mue(n){const e=n,t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length,r=parseInt(n.toString().replace(/^[^e]*(e([-+]?\d+))?/,"$2"))||0;return 1===e?1:0===r&&0!==t&&t%1e6==0&&0===i||!(r>=0&&r<=5)?4:5}],ac=void 0,_ue=["pt",[["AM","PM"],ac,ac],ac,[["D","S","T","Q","Q","S","S"],["dom.","seg.","ter.","qua.","qui.","sex.","s\xe1b."],["domingo","segunda-feira","ter\xe7a-feira","quarta-feira","quinta-feira","sexta-feira","s\xe1bado"],["dom.","seg.","ter.","qua.","qui.","sex.","s\xe1b."]],ac,[["J","F","M","A","M","J","J","A","S","O","N","D"],["jan.","fev.","mar.","abr.","mai.","jun.","jul.","ago.","set.","out.","nov.","dez."],["janeiro","fevereiro","mar\xe7o","abril","maio","junho","julho","agosto","setembro","outubro","novembro","dezembro"]],ac,[["a.C.","d.C."],ac,["antes de Cristo","depois de Cristo"]],0,[6,0],["dd/MM/y","d 'de' MMM 'de' y","d 'de' MMMM 'de' y","EEEE, d 'de' MMMM 'de' y"],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1} {0}",ac,ac,ac],[",",".",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4\xa0#,##0.00","#E0"],"BRL","R$","Real brasileiro",{AUD:["AU$","$"],BYN:[ac,"\u0440."],JPY:["JP\xa5","\xa5"],PHP:[ac,"\u20b1"],PTE:["Esc."],RON:[ac,"L"],SYP:[ac,"S\xa3"],THB:["\u0e3f"],TWD:["NT$"],USD:["US$","$"]},"ltr",function gue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length,r=parseInt(n.toString().replace(/^[^e]*(e([-+]?\d+))?/,"$2"))||0;return t===Math.floor(t)&&t>=0&&t<=1?1:0===r&&0!==t&&t%1e6==0&&0===i||!(r>=0&&r<=5)?4:5}],Da=void 0,HV=["zh",[["\u4e0a\u5348","\u4e0b\u5348"],Da,Da],Da,[["\u65e5","\u4e00","\u4e8c","\u4e09","\u56db","\u4e94","\u516d"],["\u5468\u65e5","\u5468\u4e00","\u5468\u4e8c","\u5468\u4e09","\u5468\u56db","\u5468\u4e94","\u5468\u516d"],["\u661f\u671f\u65e5","\u661f\u671f\u4e00","\u661f\u671f\u4e8c","\u661f\u671f\u4e09","\u661f\u671f\u56db","\u661f\u671f\u4e94","\u661f\u671f\u516d"],["\u5468\u65e5","\u5468\u4e00","\u5468\u4e8c","\u5468\u4e09","\u5468\u56db","\u5468\u4e94","\u5468\u516d"]],Da,[["1","2","3","4","5","6","7","8","9","10","11","12"],["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],["\u4e00\u6708","\u4e8c\u6708","\u4e09\u6708","\u56db\u6708","\u4e94\u6708","\u516d\u6708","\u4e03\u6708","\u516b\u6708","\u4e5d\u6708","\u5341\u6708","\u5341\u4e00\u6708","\u5341\u4e8c\u6708"]],Da,[["\u516c\u5143\u524d","\u516c\u5143"],Da,Da],0,[6,0],["y/M/d","y\u5e74M\u6708d\u65e5",Da,"y\u5e74M\u6708d\u65e5EEEE"],["HH:mm","HH:mm:ss","z HH:mm:ss","zzzz HH:mm:ss"],["{1} {0}",Da,Da,Da],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"CNY","\xa5","\u4eba\u6c11\u5e01",{AUD:["AU$","$"],BYN:[Da,"\u0440."],CNY:["\xa5"],ILR:["ILS"],JPY:["JP\xa5","\xa5"],KRW:["\uffe6","\u20a9"],PHP:[Da,"\u20b1"],RUR:[Da,"\u0440."],TWD:["NT$"],USD:["US$","$"],XXX:[]},"ltr",function vue(n){return 5}],so=void 0,UV=["de",[["AM","PM"],so,so],so,[["S","M","D","M","D","F","S"],["So.","Mo.","Di.","Mi.","Do.","Fr.","Sa."],["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],["So.","Mo.","Di.","Mi.","Do.","Fr.","Sa."]],[["S","M","D","M","D","F","S"],["So","Mo","Di","Mi","Do","Fr","Sa"],["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],["So.","Mo.","Di.","Mi.","Do.","Fr.","Sa."]],[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan.","Feb.","M\xe4rz","Apr.","Mai","Juni","Juli","Aug.","Sept.","Okt.","Nov.","Dez."],["Januar","Februar","M\xe4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]],[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","M\xe4r","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"],["Januar","Februar","M\xe4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]],[["v. Chr.","n. Chr."],so,so],1,[6,0],["dd.MM.yy","dd.MM.y","d. MMMM y","EEEE, d. MMMM y"],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1}, {0}",so,"{1} 'um' {0}",so],[",",".",";","%","+","-","E","\xb7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0\xa0%","#,##0.00\xa0\xa4","#E0"],"EUR","\u20ac","Euro",{ATS:["\xf6S"],AUD:["AU$","$"],BGM:["BGK"],BGO:["BGJ"],BYN:[so,"\u0440."],CUC:[so,"Cub$"],DEM:["DM"],FKP:[so,"Fl\xa3"],GHS:[so,"\u20b5"],GNF:[so,"F.G."],KMF:[so,"FC"],PHP:[so,"\u20b1"],RON:[so,"L"],RUR:[so,"\u0440."],RWF:[so,"F.Rw"],SYP:[],THB:["\u0e3f"],TWD:["NT$"],XXX:[],ZMW:[so,"K"]},"ltr",function yue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length;return 1===t&&0===i?1:5}],ha=void 0,zV=["ja",[["\u5348\u524d","\u5348\u5f8c"],ha,ha],ha,[["\u65e5","\u6708","\u706b","\u6c34","\u6728","\u91d1","\u571f"],ha,["\u65e5\u66dc\u65e5","\u6708\u66dc\u65e5","\u706b\u66dc\u65e5","\u6c34\u66dc\u65e5","\u6728\u66dc\u65e5","\u91d1\u66dc\u65e5","\u571f\u66dc\u65e5"],["\u65e5","\u6708","\u706b","\u6c34","\u6728","\u91d1","\u571f"]],ha,[["1","2","3","4","5","6","7","8","9","10","11","12"],["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],ha],ha,[["BC","AD"],["\u7d00\u5143\u524d","\u897f\u66a6"],ha],0,[6,0],["y/MM/dd",ha,"y\u5e74M\u6708d\u65e5","y\u5e74M\u6708d\u65e5EEEE"],["H:mm","H:mm:ss","H:mm:ss z","H\u6642mm\u5206ss\u79d2 zzzz"],["{1} {0}",ha,ha,ha],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"JPY","\uffe5","\u65e5\u672c\u5186",{BYN:[ha,"\u0440."],CNY:["\u5143","\uffe5"],JPY:["\uffe5"],PHP:[ha,"\u20b1"],RON:[ha,"\u30ec\u30a4"],XXX:[]},"ltr",function bue(n){return 5}],Ta=void 0,GV=["ko",[["AM","PM"],Ta,["\uc624\uc804","\uc624\ud6c4"]],Ta,[["\uc77c","\uc6d4","\ud654","\uc218","\ubaa9","\uae08","\ud1a0"],Ta,["\uc77c\uc694\uc77c","\uc6d4\uc694\uc77c","\ud654\uc694\uc77c","\uc218\uc694\uc77c","\ubaa9\uc694\uc77c","\uae08\uc694\uc77c","\ud1a0\uc694\uc77c"],["\uc77c","\uc6d4","\ud654","\uc218","\ubaa9","\uae08","\ud1a0"]],Ta,[["1\uc6d4","2\uc6d4","3\uc6d4","4\uc6d4","5\uc6d4","6\uc6d4","7\uc6d4","8\uc6d4","9\uc6d4","10\uc6d4","11\uc6d4","12\uc6d4"],Ta,Ta],Ta,[["BC","AD"],Ta,["\uae30\uc6d0\uc804","\uc11c\uae30"]],0,[6,0],["yy. M. d.","y. M. d.","y\ub144 M\uc6d4 d\uc77c","y\ub144 M\uc6d4 d\uc77c EEEE"],["a h:mm","a h:mm:ss","a h\uc2dc m\ubd84 s\ucd08 z","a h\uc2dc m\ubd84 s\ucd08 zzzz"],["{1} {0}",Ta,Ta,Ta],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"KRW","\u20a9","\ub300\ud55c\ubbfc\uad6d \uc6d0",{AUD:["AU$","$"],BYN:[Ta,"\u0440."],JPY:["JP\xa5","\xa5"],PHP:[Ta,"\u20b1"],RON:[Ta,"L"],TWD:["NT$"],USD:["US$","$"]},"ltr",function xue(n){return 5}],oo=void 0,jV=["it",[["m.","p."],["AM","PM"],oo],oo,[["D","L","M","M","G","V","S"],["dom","lun","mar","mer","gio","ven","sab"],["domenica","luned\xec","marted\xec","mercoled\xec","gioved\xec","venerd\xec","sabato"],["dom","lun","mar","mer","gio","ven","sab"]],oo,[["G","F","M","A","M","G","L","A","S","O","N","D"],["gen","feb","mar","apr","mag","giu","lug","ago","set","ott","nov","dic"],["gennaio","febbraio","marzo","aprile","maggio","giugno","luglio","agosto","settembre","ottobre","novembre","dicembre"]],oo,[["aC","dC"],["a.C.","d.C."],["avanti Cristo","dopo Cristo"]],1,[6,0],["dd/MM/yy","d MMM y","d MMMM y","EEEE d MMMM y"],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1}, {0}",oo,"{1} {0}",oo],[",",".",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","#,##0.00\xa0\xa4","#E0"],"EUR","\u20ac","euro",{BRL:[oo,"R$"],BYN:[oo,"Br"],EGP:[oo,"\xa3E"],HKD:[oo,"$"],INR:[oo,"\u20b9"],JPY:[oo,"\xa5"],KRW:[oo,"\u20a9"],MXN:[oo,"$"],NOK:[oo,"NKr"],THB:["\u0e3f"],TWD:[oo,"NT$"],USD:[oo,"$"],VND:[oo,"\u20ab"]},"ltr",function wue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length,r=parseInt(n.toString().replace(/^[^e]*(e([-+]?\d+))?/,"$2"))||0;return 1===t&&0===i?1:0===r&&0!==t&&t%1e6==0&&0===i||!(r>=0&&r<=5)?4:5}],yl=void 0,WV=["ru",[["AM","PM"],yl,yl],yl,[["\u0412","\u041f","\u0412","\u0421","\u0427","\u041f","\u0421"],["\u0432\u0441","\u043f\u043d","\u0432\u0442","\u0441\u0440","\u0447\u0442","\u043f\u0442","\u0441\u0431"],["\u0432\u043e\u0441\u043a\u0440\u0435\u0441\u0435\u043d\u044c\u0435","\u043f\u043e\u043d\u0435\u0434\u0435\u043b\u044c\u043d\u0438\u043a","\u0432\u0442\u043e\u0440\u043d\u0438\u043a","\u0441\u0440\u0435\u0434\u0430","\u0447\u0435\u0442\u0432\u0435\u0440\u0433","\u043f\u044f\u0442\u043d\u0438\u0446\u0430","\u0441\u0443\u0431\u0431\u043e\u0442\u0430"],["\u0432\u0441","\u043f\u043d","\u0432\u0442","\u0441\u0440","\u0447\u0442","\u043f\u0442","\u0441\u0431"]],yl,[["\u042f","\u0424","\u041c","\u0410","\u041c","\u0418","\u0418","\u0410","\u0421","\u041e","\u041d","\u0414"],["\u044f\u043d\u0432.","\u0444\u0435\u0432\u0440.","\u043c\u0430\u0440.","\u0430\u043f\u0440.","\u043c\u0430\u044f","\u0438\u044e\u043d.","\u0438\u044e\u043b.","\u0430\u0432\u0433.","\u0441\u0435\u043d\u0442.","\u043e\u043a\u0442.","\u043d\u043e\u044f\u0431.","\u0434\u0435\u043a."],["\u044f\u043d\u0432\u0430\u0440\u044f","\u0444\u0435\u0432\u0440\u0430\u043b\u044f","\u043c\u0430\u0440\u0442\u0430","\u0430\u043f\u0440\u0435\u043b\u044f","\u043c\u0430\u044f","\u0438\u044e\u043d\u044f","\u0438\u044e\u043b\u044f","\u0430\u0432\u0433\u0443\u0441\u0442\u0430","\u0441\u0435\u043d\u0442\u044f\u0431\u0440\u044f","\u043e\u043a\u0442\u044f\u0431\u0440\u044f","\u043d\u043e\u044f\u0431\u0440\u044f","\u0434\u0435\u043a\u0430\u0431\u0440\u044f"]],[["\u042f","\u0424","\u041c","\u0410","\u041c","\u0418","\u0418","\u0410","\u0421","\u041e","\u041d","\u0414"],["\u044f\u043d\u0432.","\u0444\u0435\u0432\u0440.","\u043c\u0430\u0440\u0442","\u0430\u043f\u0440.","\u043c\u0430\u0439","\u0438\u044e\u043d\u044c","\u0438\u044e\u043b\u044c","\u0430\u0432\u0433.","\u0441\u0435\u043d\u0442.","\u043e\u043a\u0442.","\u043d\u043e\u044f\u0431.","\u0434\u0435\u043a."],["\u044f\u043d\u0432\u0430\u0440\u044c","\u0444\u0435\u0432\u0440\u0430\u043b\u044c","\u043c\u0430\u0440\u0442","\u0430\u043f\u0440\u0435\u043b\u044c","\u043c\u0430\u0439","\u0438\u044e\u043d\u044c","\u0438\u044e\u043b\u044c","\u0430\u0432\u0433\u0443\u0441\u0442","\u0441\u0435\u043d\u0442\u044f\u0431\u0440\u044c","\u043e\u043a\u0442\u044f\u0431\u0440\u044c","\u043d\u043e\u044f\u0431\u0440\u044c","\u0434\u0435\u043a\u0430\u0431\u0440\u044c"]],[["\u0434\u043e \u043d.\u044d.","\u043d.\u044d."],["\u0434\u043e \u043d. \u044d.","\u043d. \u044d."],["\u0434\u043e \u0420\u043e\u0436\u0434\u0435\u0441\u0442\u0432\u0430 \u0425\u0440\u0438\u0441\u0442\u043e\u0432\u0430","\u043e\u0442 \u0420\u043e\u0436\u0434\u0435\u0441\u0442\u0432\u0430 \u0425\u0440\u0438\u0441\u0442\u043e\u0432\u0430"]],1,[6,0],["dd.MM.y","d MMM y '\u0433'.","d MMMM y '\u0433'.","EEEE, d MMMM y '\u0433'."],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1}, {0}",yl,yl,yl],[",","\xa0",";","%","+","-","E","\xd7","\u2030","\u221e","\u043d\u0435\xa0\u0447\u0438\u0441\u043b\u043e",":"],["#,##0.###","#,##0\xa0%","#,##0.00\xa0\xa4","#E0"],"RUB","\u20bd","\u0440\u043e\u0441\u0441\u0438\u0439\u0441\u043a\u0438\u0439 \u0440\u0443\u0431\u043b\u044c",{BYN:[yl,"\u0440."],GEL:[yl,"\u10da"],PHP:[yl,"\u20b1"],RON:[yl,"L"],RUB:["\u20bd"],RUR:["\u0440."],THB:["\u0e3f"],TMT:["\u0422\u041c\u0422"],TWD:["NT$"],UAH:["\u20b4"],XXX:["XXXX"]},"ltr",function Sue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length;return 0===i&&t%10==1&&t%100!=11?1:0===i&&t%10===Math.floor(t%10)&&t%10>=2&&t%10<=4&&!(t%100>=12&&t%100<=14)?3:0===i&&t%10==0||0===i&&t%10===Math.floor(t%10)&&t%10>=5&&t%10<=9||0===i&&t%100===Math.floor(t%100)&&t%100>=11&&t%100<=14?4:5}],hs=void 0,$V=["pl",[["a","p"],["AM","PM"],hs],hs,[["n","p","w","\u015b","c","p","s"],["niedz.","pon.","wt.","\u015br.","czw.","pt.","sob."],["niedziela","poniedzia\u0142ek","wtorek","\u015broda","czwartek","pi\u0105tek","sobota"],["nie","pon","wto","\u015bro","czw","pi\u0105","sob"]],[["N","P","W","\u015a","C","P","S"],["niedz.","pon.","wt.","\u015br.","czw.","pt.","sob."],["niedziela","poniedzia\u0142ek","wtorek","\u015broda","czwartek","pi\u0105tek","sobota"],["nie","pon","wto","\u015bro","czw","pi\u0105","sob"]],[["s","l","m","k","m","c","l","s","w","p","l","g"],["sty","lut","mar","kwi","maj","cze","lip","sie","wrz","pa\u017a","lis","gru"],["stycznia","lutego","marca","kwietnia","maja","czerwca","lipca","sierpnia","wrze\u015bnia","pa\u017adziernika","listopada","grudnia"]],[["S","L","M","K","M","C","L","S","W","P","L","G"],["sty","lut","mar","kwi","maj","cze","lip","sie","wrz","pa\u017a","lis","gru"],["stycze\u0144","luty","marzec","kwiecie\u0144","maj","czerwiec","lipiec","sierpie\u0144","wrzesie\u0144","pa\u017adziernik","listopad","grudzie\u0144"]],[["p.n.e.","n.e."],hs,["przed nasz\u0105 er\u0105","naszej ery"]],1,[6,0],["d.MM.y","d MMM y","d MMMM y","EEEE, d MMMM y"],["HH:mm","HH:mm:ss","HH:mm:ss z","HH:mm:ss zzzz"],["{1}, {0}",hs,"{1} {0}",hs],[",","\xa0",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","#,##0.00\xa0\xa4","#E0"],"PLN","z\u0142","z\u0142oty polski",{AUD:[hs,"$"],CAD:[hs,"$"],CNY:[hs,"\xa5"],GBP:[hs,"\xa3"],HKD:[hs,"$"],ILS:[hs,"\u20aa"],INR:[hs,"\u20b9"],JPY:[hs,"\xa5"],KRW:[hs,"\u20a9"],MXN:[hs,"$"],NZD:[hs,"$"],PHP:[hs,"\u20b1"],PLN:["z\u0142"],RON:[hs,"lej"],TWD:[hs,"NT$"],USD:[hs,"$"],VND:[hs,"\u20ab"]},"ltr",function Eue(n){const t=Math.floor(Math.abs(n)),i=n.toString().replace(/^[^.]*\.?/,"").length;return 1===t&&0===i?1:0===i&&t%10===Math.floor(t%10)&&t%10>=2&&t%10<=4&&!(t%100>=12&&t%100<=14)?3:0===i&&1!==t&&t%10===Math.floor(t%10)&&t%10>=0&&t%10<=1||0===i&&t%10===Math.floor(t%10)&&t%10>=5&&t%10<=9||0===i&&t%100===Math.floor(t%100)&&t%100>=12&&t%100<=14?4:5}];let As="en";Es(fue),navigator.languages.some(n=>{switch(n.toLowerCase()){case"pt-br":return Es(_ue),As=n,!0;case"zh-cht":case"zh-chs":return Es(HV),As=n,!0;case"fr":return Es(BV),As=n,!0;case"es":return Es(VV),As=n,!0;case"de":return Es(UV),As=n,!0;case"it":return Es(jV),As=n,!0;case"ja":return Es(zV),As="ja",!0;case"ru":return Es(WV),As=n,!0;case"pl":return Es($V),As=n,!0;case"ko":return Es(GV),As=n,!0}switch(n.toLowerCase().split("-")[0]){case"fr":return Es(BV),As=n,!0;case"es":return Es(VV),As=n,!0;case"de":return Es(UV),As=n,!0;case"it":return Es(jV),As=n,!0;case"ja":return Es(zV),As="ja",!0;case"ru":return Es(WV),As=n,!0;case"pl":return Es($V),As=n,!0;case"ko":return Es(GV),As=n,!0}});class I0{}I0.\u0275fac=function(e){return new(e||I0)},I0.\u0275mod=Mt({type:I0,bootstrap:[cb]}),I0.\u0275inj=On({providers:[{provide:Ac,useValue:As}],imports:[nO,BJ,uN,yq,Iq,s4,VX,cY,EX,Yq,wW,yj,k0,gg,Dg]}),HG().bootstrapModule(I0).catch(n=>console.log(n))},8410:function(Aa,ka){!function(dt){"use strict";var qr="function"==typeof WeakSet,le=Object.keys;function pt(Pt,$t){Pt&&"object"==typeof Pt&&$t.add(Pt)}function ps(Pt,$t,Qn,In){for(var Fn,fn=Pt.length,sr=0;sr{var l,f,_,b,E,M,D,F,P,U,I,h,qr={userAgent:!1},le={},pt=pt||(l=Math,_=(f={}).lib={},b=_.Base=function(){function C(){}return{extend:function(B){C.prototype=this;var R=new C;return B&&R.mixIn(B),R.hasOwnProperty("init")||(R.init=function(){R.$super.init.apply(this,arguments)}),R.init.prototype=R,R.$super=this,R},create:function(){var B=this.extend();return B.init.apply(B,arguments),B},init:function(){},mixIn:function(B){for(var R in B)B.hasOwnProperty(R)&&(this[R]=B[R]);B.hasOwnProperty("toString")&&(this.toString=B.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),E=_.WordArray=b.extend({init:function(C,B){C=this.words=C||[],this.sigBytes=null!=B?B:4*C.length},toString:function(C){return(C||D).stringify(this)},concat:function(C){var B=this.words,R=C.words,V=this.sigBytes,L=C.sigBytes;if(this.clamp(),V%4)for(var $=0;$>>2]|=(R[$>>>2]>>>24-$%4*8&255)<<24-(V+$)%4*8;else for($=0;$>>2]=R[$>>>2];return this.sigBytes+=L,this},clamp:function(){var C=this.words,B=this.sigBytes;C[B>>>2]&=4294967295<<32-B%4*8,C.length=l.ceil(B/4)},clone:function(){var C=b.clone.call(this);return C.words=this.words.slice(0),C},random:function(C){for(var B=[],R=0;R>>2]>>>24-L%4*8&255;V.push(($>>>4).toString(16)),V.push((15&$).toString(16))}return V.join("")},parse:function(C){for(var B=C.length,R=[],V=0;V>>3]|=parseInt(C.substr(V,2),16)<<24-V%8*4;return new E.init(R,B/2)}},F=M.Latin1={stringify:function(C){for(var B=C.words,R=C.sigBytes,V=[],L=0;L>>2]>>>24-L%4*8&255));return V.join("")},parse:function(C){for(var B=C.length,R=[],V=0;V>>2]|=(255&C.charCodeAt(V))<<24-V%4*8;return new E.init(R,B)}},P=M.Utf8={stringify:function(C){try{return decodeURIComponent(escape(F.stringify(C)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(C){return F.parse(unescape(encodeURIComponent(C)))}},U=_.BufferedBlockAlgorithm=b.extend({reset:function(){this._data=new E.init,this._nDataBytes=0},_append:function(C){"string"==typeof C&&(C=P.parse(C)),this._data.concat(C),this._nDataBytes+=C.sigBytes},_process:function(C){var B=this._data,R=B.words,V=B.sigBytes,L=this.blockSize,J=V/(4*L),Q=(J=C?l.ceil(J):l.max((0|J)-this._minBufferSize,0))*L,te=l.min(4*Q,V);if(Q){for(var Se=0;Se>>2]}},h.BlockCipher=D.extend({cfg:D.cfg.extend({mode:z,padding:P}),reset:function(){D.reset.call(this);var R=(V=this.cfg).iv,V=V.mode;if(this._xformMode==this._ENC_XFORM_MODE)var L=V.createEncryptor;else L=V.createDecryptor,this._minBufferSize=1;this._mode=L.call(V,this,R&&R.words)},_doProcessBlock:function(R,V){this._mode.processBlock(R,V)},_doFinalize:function(){var R=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){R.pad(this._data,this.blockSize);var V=this._process(!0)}else V=this._process(!0),R.unpad(V);return V},blockSize:4});var U=h.CipherParams=f.extend({init:function(R){this.mixIn(R)},toString:function(R){return(R||this.formatter).stringify(this)}}),I=(z=(C.format={}).OpenSSL={stringify:function(R){var V=R.ciphertext;return((R=R.salt)?_.create([1398893684,1701076831]).concat(R).concat(V):V).toString(E)},parse:function(R){var V=(R=E.parse(R)).words;if(1398893684==V[0]&&1701076831==V[1]){var L=_.create(V.slice(2,4));V.splice(0,4),R.sigBytes-=16}return U.create({ciphertext:R,salt:L})}},h.SerializableCipher=f.extend({cfg:f.extend({format:z}),encrypt:function(R,V,L,$){$=this.cfg.extend($);var J=R.createEncryptor(L,$);return V=J.finalize(V),U.create({ciphertext:V,key:L,iv:(J=J.cfg).iv,algorithm:R,mode:J.mode,padding:J.padding,blockSize:R.blockSize,formatter:$.format})},decrypt:function(R,V,L,$){return $=this.cfg.extend($),V=this._parse(V,$.format),R.createDecryptor(L,$).finalize(V.ciphertext)},_parse:function(R,V){return"string"==typeof R?V.parse(R,this):R}})),C=(C.kdf={}).OpenSSL={execute:function(R,V,L,$){return $||($=_.random(8)),R=M.create({keySize:V+L}).compute(R,$),L=_.create(R.words.slice(V),4*L),R.sigBytes=4*V,U.create({key:R,iv:L,salt:$})}},B=h.PasswordBasedCipher=I.extend({cfg:I.cfg.extend({kdf:C}),encrypt:function(R,V,L,$){return L=($=this.cfg.extend($)).kdf.execute(L,R.keySize,R.ivSize),$.iv=L.iv,(R=I.encrypt.call(this,R,V,L.key,$)).mixIn(L),R},decrypt:function(R,V,L,$){return $=this.cfg.extend($),V=this._parse(V,$.format),L=$.kdf.execute(L,R.keySize,R.ivSize,V.salt),$.iv=L.iv,I.decrypt.call(this,R,V,L.key,$)}})}(),function(){for(var l=pt,h=l.lib.BlockCipher,Se=l.algo,f=[],_=[],b=[],E=[],M=[],D=[],F=[],P=[],U=[],z=[],I=[],C=0;256>C;C++)I[C]=128>C?C<<1:C<<1^283;var B=0,R=0;for(C=0;256>C;C++){var V;f[B]=V=(V=R^R<<1^R<<2^R<<3^R<<4)>>>8^255&V^99,_[V]=B;var L=I[B],$=I[L],J=I[$],Q=257*I[V]^16843008*V;b[B]=Q<<24|Q>>>8,E[B]=Q<<16|Q>>>16,M[B]=Q<<8|Q>>>24,D[B]=Q,F[V]=(Q=16843009*J^65537*$^257*L^16843008*B)<<24|Q>>>8,P[V]=Q<<16|Q>>>16,U[V]=Q<<8|Q>>>24,z[V]=Q,B?(B=L^I[I[I[J^L]]],R^=I[I[R]]):B=R=1}var te=[0,1,2,4,8,16,32,64,128,27,54];Se=Se.AES=h.extend({_doReset:function(){for(var Ae=(q=this._key).words,j=q.sigBytes/4,q=4*((this._nRounds=j+6)+1),ee=this._keySchedule=[],re=0;re>>24]<<24|f[ue>>>16&255]<<16|f[ue>>>8&255]<<8|f[255&ue]):(ue=f[(ue=ue<<8|ue>>>24)>>>24]<<24|f[ue>>>16&255]<<16|f[ue>>>8&255]<<8|f[255&ue],ue^=te[re/j|0]<<24),ee[re]=ee[re-j]^ue}for(Ae=this._invKeySchedule=[],j=0;jj||4>=re?ue:F[f[ue>>>24]]^P[f[ue>>>16&255]]^U[f[ue>>>8&255]]^z[f[255&ue]]},encryptBlock:function(Ae,j){this._doCryptBlock(Ae,j,this._keySchedule,b,E,M,D,f)},decryptBlock:function(Ae,j){var q=Ae[j+1];Ae[j+1]=Ae[j+3],Ae[j+3]=q,this._doCryptBlock(Ae,j,this._invKeySchedule,F,P,U,z,_),q=Ae[j+1],Ae[j+1]=Ae[j+3],Ae[j+3]=q},_doCryptBlock:function(Ae,j,q,ee,re,ue,be,ce){for(var pe=this._nRounds,Y=Ae[j]^q[0],ui=Ae[j+1]^q[1],oi=Ae[j+2]^q[2],Rn=Ae[j+3]^q[3],ve=4,Ie=1;Ie>>24]^re[ui>>>16&255]^ue[oi>>>8&255]^be[255&Rn]^q[ve++],Nt=ee[ui>>>24]^re[oi>>>16&255]^ue[Rn>>>8&255]^be[255&Y]^q[ve++],Lt=ee[oi>>>24]^re[Rn>>>16&255]^ue[Y>>>8&255]^be[255&ui]^q[ve++];Rn=ee[Rn>>>24]^re[Y>>>16&255]^ue[ui>>>8&255]^be[255&oi]^q[ve++],Y=Bt,ui=Nt,oi=Lt}Bt=(ce[Y>>>24]<<24|ce[ui>>>16&255]<<16|ce[oi>>>8&255]<<8|ce[255&Rn])^q[ve++],Nt=(ce[ui>>>24]<<24|ce[oi>>>16&255]<<16|ce[Rn>>>8&255]<<8|ce[255&Y])^q[ve++],Lt=(ce[oi>>>24]<<24|ce[Rn>>>16&255]<<16|ce[Y>>>8&255]<<8|ce[255&ui])^q[ve++],Rn=(ce[Rn>>>24]<<24|ce[Y>>>16&255]<<16|ce[ui>>>8&255]<<8|ce[255&oi])^q[ve++],Ae[j]=Bt,Ae[j+1]=Nt,Ae[j+2]=Lt,Ae[j+3]=Rn},keySize:8}),l.AES=h._createHelper(Se)}(),function(){function l(I,C){var B=(this._lBlock>>>I^this._rBlock)&C;this._rBlock^=B,this._lBlock^=B<>>I^this._lBlock)&C;this._lBlock^=B,this._rBlock^=B<B;B++){var R=M[B]-1;C[B]=I[R>>>5]>>>31-R%32&1}for(I=this._subKeys=[],R=0;16>R;R++){var V=I[R]=[],L=F[R];for(B=0;24>B;B++)V[B/6|0]|=C[(D[B]-1+L)%28]<<31-B%6,V[4+(B/6|0)]|=C[28+(D[B+24]-1+L)%28]<<31-B%6;for(V[0]=V[0]<<1|V[0]>>>31,B=1;7>B;B++)V[B]>>>=4*(B-1)+3;V[7]=V[7]<<5|V[7]>>>27}for(C=this._invSubKeys=[],B=0;16>B;B++)C[B]=I[15-B]},encryptBlock:function(I,C){this._doCryptBlock(I,C,this._subKeys)},decryptBlock:function(I,C){this._doCryptBlock(I,C,this._invSubKeys)},_doCryptBlock:function(I,C,B){this._lBlock=I[C],this._rBlock=I[C+1],l.call(this,4,252645135),l.call(this,16,65535),h.call(this,2,858993459),h.call(this,8,16711935),l.call(this,1,1431655765);for(var R=0;16>R;R++){for(var V=B[R],L=this._lBlock,$=this._rBlock,J=0,Q=0;8>Q;Q++)J|=P[Q][(($^V[Q])&U[Q])>>>0];this._lBlock=$,this._rBlock=L^J}B=this._lBlock,this._lBlock=this._rBlock,this._rBlock=B,l.call(this,1,1431655765),h.call(this,8,16711935),h.call(this,2,858993459),l.call(this,16,65535),l.call(this,4,252645135),I[C]=this._lBlock,I[C+1]=this._rBlock},keySize:2,ivSize:2,blockSize:2});f.DES=b._createHelper(z),E=E.TripleDES=b.extend({_doReset:function(){var I=this._key.words;this._des1=z.createEncryptor(_.create(I.slice(0,2))),this._des2=z.createEncryptor(_.create(I.slice(2,4))),this._des3=z.createEncryptor(_.create(I.slice(4,6)))},encryptBlock:function(I,C){this._des1.encryptBlock(I,C),this._des2.decryptBlock(I,C),this._des3.encryptBlock(I,C)},decryptBlock:function(I,C){this._des3.decryptBlock(I,C),this._des2.encryptBlock(I,C),this._des1.decryptBlock(I,C)},keySize:6,ivSize:2,blockSize:2}),f.TripleDES=b._createHelper(E)}(),h=pt.lib.WordArray,pt.enc.Base64={stringify:function(f){var _=f.words,b=f.sigBytes,E=this._map;f.clamp(),f=[];for(var M=0;M>>2]>>>24-M%4*8&255)<<16|(_[M+1>>>2]>>>24-(M+1)%4*8&255)<<8|_[M+2>>>2]>>>24-(M+2)%4*8&255,F=0;4>F&&M+.75*F>>6*(3-F)&63));if(_=E.charAt(64))for(;f.length%4;)f.push(_);return f.join("")},parse:function(f){var _=f.length,b=this._map;(E=b.charAt(64))&&-1!=(E=f.indexOf(E))&&(_=E);for(var E=[],M=0,D=0;D<_;D++)if(D%4){var F=b.indexOf(f.charAt(D-1))<>>6-D%4*2;E[M>>>2]|=(F|P)<<24-M%4*8,M++}return h.create(E,M)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},function(l){function h(z,I,C,B,R,V,L){return((z=z+(I&C|~I&B)+R+L)<>>32-V)+I}function f(z,I,C,B,R,V,L){return((z=z+(I&B|C&~B)+R+L)<>>32-V)+I}function _(z,I,C,B,R,V,L){return((z=z+(I^C^B)+R+L)<>>32-V)+I}function b(z,I,C,B,R,V,L){return((z=z+(C^(I|~B))+R+L)<>>32-V)+I}for(var E=pt,M=(F=E.lib).WordArray,D=F.Hasher,F=E.algo,P=[],U=0;64>U;U++)P[U]=4294967296*l.abs(l.sin(U+1))|0;F=F.MD5=D.extend({_doReset:function(){this._hash=new M.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(z,I){for(var C=0;16>C;C++)z[B=I+C]=16711935&((R=z[B])<<8|R>>>24)|4278255360&(R<<24|R>>>8);var B,R=z[I+1],V=z[I+2],L=z[I+3],$=z[I+4],J=z[I+5],Q=z[I+6],te=z[I+7],Se=z[I+8],Ae=z[I+9],j=z[I+10],q=z[I+11],ee=z[I+12],re=z[I+13],ue=z[I+14],be=z[I+15],ce=h(ce=(C=this._hash.words)[0],Ie=C[1],ve=C[2],pe=C[3],B=z[I+0],7,P[0]),pe=h(pe,ce,Ie,ve,R,12,P[1]),ve=h(ve,pe,ce,Ie,V,17,P[2]),Ie=h(Ie,ve,pe,ce,L,22,P[3]);ce=h(ce,Ie,ve,pe,$,7,P[4]),pe=h(pe,ce,Ie,ve,J,12,P[5]),ve=h(ve,pe,ce,Ie,Q,17,P[6]),Ie=h(Ie,ve,pe,ce,te,22,P[7]),ce=h(ce,Ie,ve,pe,Se,7,P[8]),pe=h(pe,ce,Ie,ve,Ae,12,P[9]),ve=h(ve,pe,ce,Ie,j,17,P[10]),Ie=h(Ie,ve,pe,ce,q,22,P[11]),ce=h(ce,Ie,ve,pe,ee,7,P[12]),pe=h(pe,ce,Ie,ve,re,12,P[13]),ve=h(ve,pe,ce,Ie,ue,17,P[14]),ce=f(ce,Ie=h(Ie,ve,pe,ce,be,22,P[15]),ve,pe,R,5,P[16]),pe=f(pe,ce,Ie,ve,Q,9,P[17]),ve=f(ve,pe,ce,Ie,q,14,P[18]),Ie=f(Ie,ve,pe,ce,B,20,P[19]),ce=f(ce,Ie,ve,pe,J,5,P[20]),pe=f(pe,ce,Ie,ve,j,9,P[21]),ve=f(ve,pe,ce,Ie,be,14,P[22]),Ie=f(Ie,ve,pe,ce,$,20,P[23]),ce=f(ce,Ie,ve,pe,Ae,5,P[24]),pe=f(pe,ce,Ie,ve,ue,9,P[25]),ve=f(ve,pe,ce,Ie,L,14,P[26]),Ie=f(Ie,ve,pe,ce,Se,20,P[27]),ce=f(ce,Ie,ve,pe,re,5,P[28]),pe=f(pe,ce,Ie,ve,V,9,P[29]),ve=f(ve,pe,ce,Ie,te,14,P[30]),ce=_(ce,Ie=f(Ie,ve,pe,ce,ee,20,P[31]),ve,pe,J,4,P[32]),pe=_(pe,ce,Ie,ve,Se,11,P[33]),ve=_(ve,pe,ce,Ie,q,16,P[34]),Ie=_(Ie,ve,pe,ce,ue,23,P[35]),ce=_(ce,Ie,ve,pe,R,4,P[36]),pe=_(pe,ce,Ie,ve,$,11,P[37]),ve=_(ve,pe,ce,Ie,te,16,P[38]),Ie=_(Ie,ve,pe,ce,j,23,P[39]),ce=_(ce,Ie,ve,pe,re,4,P[40]),pe=_(pe,ce,Ie,ve,B,11,P[41]),ve=_(ve,pe,ce,Ie,L,16,P[42]),Ie=_(Ie,ve,pe,ce,Q,23,P[43]),ce=_(ce,Ie,ve,pe,Ae,4,P[44]),pe=_(pe,ce,Ie,ve,ee,11,P[45]),ve=_(ve,pe,ce,Ie,be,16,P[46]),ce=b(ce,Ie=_(Ie,ve,pe,ce,V,23,P[47]),ve,pe,B,6,P[48]),pe=b(pe,ce,Ie,ve,te,10,P[49]),ve=b(ve,pe,ce,Ie,ue,15,P[50]),Ie=b(Ie,ve,pe,ce,J,21,P[51]),ce=b(ce,Ie,ve,pe,ee,6,P[52]),pe=b(pe,ce,Ie,ve,L,10,P[53]),ve=b(ve,pe,ce,Ie,j,15,P[54]),Ie=b(Ie,ve,pe,ce,R,21,P[55]),ce=b(ce,Ie,ve,pe,Se,6,P[56]),pe=b(pe,ce,Ie,ve,be,10,P[57]),ve=b(ve,pe,ce,Ie,Q,15,P[58]),Ie=b(Ie,ve,pe,ce,re,21,P[59]),ce=b(ce,Ie,ve,pe,$,6,P[60]),pe=b(pe,ce,Ie,ve,q,10,P[61]),ve=b(ve,pe,ce,Ie,V,15,P[62]),Ie=b(Ie,ve,pe,ce,Ae,21,P[63]),C[0]=C[0]+ce|0,C[1]=C[1]+Ie|0,C[2]=C[2]+ve|0,C[3]=C[3]+pe|0},_doFinalize:function(){var z=this._data,I=z.words,C=8*this._nDataBytes,B=8*z.sigBytes;I[B>>>5]|=128<<24-B%32;var R=l.floor(C/4294967296);for(I[15+(B+64>>>9<<4)]=16711935&(R<<8|R>>>24)|4278255360&(R<<24|R>>>8),I[14+(B+64>>>9<<4)]=16711935&(C<<8|C>>>24)|4278255360&(C<<24|C>>>8),z.sigBytes=4*(I.length+1),this._process(),I=(z=this._hash).words,C=0;4>C;C++)I[C]=16711935&((B=I[C])<<8|B>>>24)|4278255360&(B<<24|B>>>8);return z},clone:function(){var z=D.clone.call(this);return z._hash=this._hash.clone(),z}}),E.MD5=D._createHelper(F),E.HmacMD5=D._createHmacHelper(F)}(Math),function(){var l=pt,h=(b=l.lib).WordArray,f=b.Hasher,_=[],b=l.algo.SHA1=f.extend({_doReset:function(){this._hash=new h.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(E,M){for(var D=this._hash.words,F=D[0],P=D[1],U=D[2],z=D[3],I=D[4],C=0;80>C;C++){if(16>C)_[C]=0|E[M+C];else{var B=_[C-3]^_[C-8]^_[C-14]^_[C-16];_[C]=B<<1|B>>>31}B=(F<<5|F>>>27)+I+_[C],B=20>C?B+(1518500249+(P&U|~P&z)):40>C?B+(1859775393+(P^U^z)):60>C?B+((P&U|P&z|U&z)-1894007588):B+((P^U^z)-899497514),I=z,z=U,U=P<<30|P>>>2,P=F,F=B}D[0]=D[0]+F|0,D[1]=D[1]+P|0,D[2]=D[2]+U|0,D[3]=D[3]+z|0,D[4]=D[4]+I|0},_doFinalize:function(){var E=this._data,M=E.words,D=8*this._nDataBytes,F=8*E.sigBytes;return M[F>>>5]|=128<<24-F%32,M[14+(F+64>>>9<<4)]=Math.floor(D/4294967296),M[15+(F+64>>>9<<4)]=D,E.sigBytes=4*M.length,this._process(),this._hash},clone:function(){var E=f.clone.call(this);return E._hash=this._hash.clone(),E}});l.SHA1=f._createHelper(b),l.HmacSHA1=f._createHmacHelper(b)}(),function(l){for(var h=pt,f=(C=h.lib).WordArray,_=C.Hasher,C=h.algo,b=[],E=[],M=function(R){return 4294967296*(R-(0|R))|0},D=2,F=0;64>F;){var P;e:{for(var U=l.sqrt(P=D),z=2;z<=U;z++)if(!(P%z)){P=!1;break e}P=!0}P&&(8>F&&(b[F]=M(l.pow(D,.5))),E[F]=M(l.pow(D,1/3)),F++),D++}var I=[];C=C.SHA256=_.extend({_doReset:function(){this._hash=new f.init(b.slice(0))},_doProcessBlock:function(B,R){for(var V=this._hash.words,L=V[0],$=V[1],J=V[2],Q=V[3],te=V[4],Se=V[5],Ae=V[6],j=V[7],q=0;64>q;q++){if(16>q)I[q]=0|B[R+q];else{var ee=I[q-15],re=I[q-2];I[q]=((ee<<25|ee>>>7)^(ee<<14|ee>>>18)^ee>>>3)+I[q-7]+((re<<15|re>>>17)^(re<<13|re>>>19)^re>>>10)+I[q-16]}ee=j+((te<<26|te>>>6)^(te<<21|te>>>11)^(te<<7|te>>>25))+(te&Se^~te&Ae)+E[q]+I[q],re=((L<<30|L>>>2)^(L<<19|L>>>13)^(L<<10|L>>>22))+(L&$^L&J^$&J),j=Ae,Ae=Se,Se=te,te=Q+ee|0,Q=J,J=$,$=L,L=ee+re|0}V[0]=V[0]+L|0,V[1]=V[1]+$|0,V[2]=V[2]+J|0,V[3]=V[3]+Q|0,V[4]=V[4]+te|0,V[5]=V[5]+Se|0,V[6]=V[6]+Ae|0,V[7]=V[7]+j|0},_doFinalize:function(){var B=this._data,R=B.words,V=8*this._nDataBytes,L=8*B.sigBytes;return R[L>>>5]|=128<<24-L%32,R[14+(L+64>>>9<<4)]=l.floor(V/4294967296),R[15+(L+64>>>9<<4)]=V,B.sigBytes=4*R.length,this._process(),this._hash},clone:function(){var B=_.clone.call(this);return B._hash=this._hash.clone(),B}}),h.SHA256=_._createHelper(C),h.HmacSHA256=_._createHmacHelper(C)}(Math),function(){var l=pt,h=l.lib.WordArray,f=(_=l.algo).SHA256,_=_.SHA224=f.extend({_doReset:function(){this._hash=new h.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var b=f._doFinalize.call(this);return b.sigBytes-=4,b}});l.SHA224=f._createHelper(_),l.HmacSHA224=f._createHmacHelper(_)}(),function(){function l(){return _.create.apply(_,arguments)}for(var h=pt,f=h.lib.Hasher,_=(E=h.x64).Word,b=E.WordArray,E=h.algo,M=[l(1116352408,3609767458),l(1899447441,602891725),l(3049323471,3964484399),l(3921009573,2173295548),l(961987163,4081628472),l(1508970993,3053834265),l(2453635748,2937671579),l(2870763221,3664609560),l(3624381080,2734883394),l(310598401,1164996542),l(607225278,1323610764),l(1426881987,3590304994),l(1925078388,4068182383),l(2162078206,991336113),l(2614888103,633803317),l(3248222580,3479774868),l(3835390401,2666613458),l(4022224774,944711139),l(264347078,2341262773),l(604807628,2007800933),l(770255983,1495990901),l(1249150122,1856431235),l(1555081692,3175218132),l(1996064986,2198950837),l(2554220882,3999719339),l(2821834349,766784016),l(2952996808,2566594879),l(3210313671,3203337956),l(3336571891,1034457026),l(3584528711,2466948901),l(113926993,3758326383),l(338241895,168717936),l(666307205,1188179964),l(773529912,1546045734),l(1294757372,1522805485),l(1396182291,2643833823),l(1695183700,2343527390),l(1986661051,1014477480),l(2177026350,1206759142),l(2456956037,344077627),l(2730485921,1290863460),l(2820302411,3158454273),l(3259730800,3505952657),l(3345764771,106217008),l(3516065817,3606008344),l(3600352804,1432725776),l(4094571909,1467031594),l(275423344,851169720),l(430227734,3100823752),l(506948616,1363258195),l(659060556,3750685593),l(883997877,3785050280),l(958139571,3318307427),l(1322822218,3812723403),l(1537002063,2003034995),l(1747873779,3602036899),l(1955562222,1575990012),l(2024104815,1125592928),l(2227730452,2716904306),l(2361852424,442776044),l(2428436474,593698344),l(2756734187,3733110249),l(3204031479,2999351573),l(3329325298,3815920427),l(3391569614,3928383900),l(3515267271,566280711),l(3940187606,3454069534),l(4118630271,4000239992),l(116418474,1914138554),l(174292421,2731055270),l(289380356,3203993006),l(460393269,320620315),l(685471733,587496836),l(852142971,1086792851),l(1017036298,365543100),l(1126000580,2618297676),l(1288033470,3409855158),l(1501505948,4234509866),l(1607167915,987167468),l(1816402316,1246189591)],D=[],F=0;80>F;F++)D[F]=l();E=E.SHA512=f.extend({_doReset:function(){this._hash=new b.init([new _.init(1779033703,4089235720),new _.init(3144134277,2227873595),new _.init(1013904242,4271175723),new _.init(2773480762,1595750129),new _.init(1359893119,2917565137),new _.init(2600822924,725511199),new _.init(528734635,4215389547),new _.init(1541459225,327033209)])},_doProcessBlock:function(P,U){for(var $,z=($=this._hash.words)[0],I=$[1],C=$[2],B=$[3],R=$[4],V=$[5],L=$[6],J=z.high,Q=z.low,te=I.high,Se=I.low,Ae=C.high,j=C.low,q=B.high,ee=B.low,re=R.high,ue=R.low,be=V.high,ce=V.low,pe=L.high,ve=L.low,Ie=($=$[7]).high,Bt=$.low,Nt=J,Lt=Q,Rn=te,Y=Se,ui=Ae,oi=j,Fi=q,ln=ee,es=re,vs=ue,Ls=be,Kn=ce,Mr=pe,Qi=ve,ii=Ie,gr=Bt,an=0;80>an;an++){var bc=D[an];if(16>an)var $i=bc.high=0|P[U+2*an],vi=bc.low=0|P[U+2*an+1];else{$i=((vi=($i=D[an-15]).high)>>>1|(_a=$i.low)<<31)^(vi>>>8|_a<<24)^vi>>>7;var _a=(_a>>>1|vi<<31)^(_a>>>8|vi<<24)^(_a>>>7|vi<<25),qc=((vi=(qc=D[an-2]).high)>>>19|(Bi=qc.low)<<13)^(vi<<3|Bi>>>29)^vi>>>6,Bi=(Bi>>>19|vi<<13)^(Bi<<3|vi>>>29)^(Bi>>>6|vi<<26);bc.high=$i=($i=($i=$i+(xd=(vi=D[an-7]).high)+((vi=_a+vi.low)>>>0<_a>>>0?1:0))+qc+((vi+=Bi)>>>0>>0?1:0))+(Po=(Xo=D[an-16]).high)+((vi+=Xo=Xo.low)>>>0>>0?1:0),bc.low=vi}var xd=es&Ls^~es&Mr,Xo=vs&Kn^~vs&Qi,W0=(bc=Nt&Rn^Nt&ui^Rn&ui,Lt&Y^Lt&oi^Y&oi),Ro=(Bi=M[an]).high,wd=Bi.low,Po=ii+((es>>>14|vs<<18)^(es>>>18|vs<<14)^(es<<23|vs>>>9))+((Bi=gr+((vs>>>14|es<<18)^(vs>>>18|es<<14)^(vs<<23|es>>>9)))>>>0>>0?1:0);ii=Mr,gr=Qi,Mr=Ls,Qi=Kn,Ls=es,Kn=vs,es=Fi+(Po=(Po=(Po=Po+xd+((Bi+=Xo)>>>0>>0?1:0))+Ro+((Bi+=wd)>>>0>>0?1:0))+$i+((Bi+=vi)>>>0>>0?1:0))+((vs=ln+Bi|0)>>>0>>0?1:0)|0,Fi=ui,ln=oi,ui=Rn,oi=Y,Rn=Nt,Y=Lt,Nt=Po+(bc=(_a=(Nt>>>28|Lt<<4)^(Nt<<30|Lt>>>2)^(Nt<<25|Lt>>>7))+bc+((vi=(qc=(Lt>>>28|Nt<<4)^(Lt<<30|Nt>>>2)^(Lt<<25|Nt>>>7))+W0)>>>0>>0?1:0))+((Lt=Bi+vi|0)>>>0>>0?1:0)|0}Q=z.low=Q+Lt,z.high=J+Nt+(Q>>>0>>0?1:0),Se=I.low=Se+Y,I.high=te+Rn+(Se>>>0>>0?1:0),j=C.low=j+oi,C.high=Ae+ui+(j>>>0>>0?1:0),ee=B.low=ee+ln,B.high=q+Fi+(ee>>>0>>0?1:0),ue=R.low=ue+vs,R.high=re+es+(ue>>>0>>0?1:0),ce=V.low=ce+Kn,V.high=be+Ls+(ce>>>0>>0?1:0),ve=L.low=ve+Qi,L.high=pe+Mr+(ve>>>0>>0?1:0),Bt=$.low=Bt+gr,$.high=Ie+ii+(Bt>>>0>>0?1:0)},_doFinalize:function(){var P=this._data,U=P.words,z=8*this._nDataBytes,I=8*P.sigBytes;return U[I>>>5]|=128<<24-I%32,U[30+(I+128>>>10<<5)]=Math.floor(z/4294967296),U[31+(I+128>>>10<<5)]=z,P.sigBytes=4*U.length,this._process(),this._hash.toX32()},clone:function(){var P=f.clone.call(this);return P._hash=this._hash.clone(),P},blockSize:32}),h.SHA512=f._createHelper(E),h.HmacSHA512=f._createHmacHelper(E)}(),function(){var l=pt,h=(b=l.x64).Word,f=b.WordArray,_=(b=l.algo).SHA512,b=b.SHA384=_.extend({_doReset:function(){this._hash=new f.init([new h.init(3418070365,3238371032),new h.init(1654270250,914150663),new h.init(2438529370,812702999),new h.init(355462360,4144912697),new h.init(1731405415,4290775857),new h.init(2394180231,1750603025),new h.init(3675008525,1694076839),new h.init(1203062813,3204075428)])},_doFinalize:function(){var E=_._doFinalize.call(this);return E.sigBytes-=16,E}});l.SHA384=_._createHelper(b),l.HmacSHA384=_._createHmacHelper(b)}(),function(){var l=pt,h=(P=l.lib).WordArray,f=P.Hasher,P=l.algo,_=h.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),b=h.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),E=h.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),M=h.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),D=h.create([0,1518500249,1859775393,2400959708,2840853838]),F=h.create([1352829926,1548603684,1836072691,2053994217,0]);P=P.RIPEMD160=f.extend({_doReset:function(){this._hash=h.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(U,z){for(var I=0;16>I;I++)U[C=z+I]=16711935&((B=U[C])<<8|B>>>24)|4278255360&(B<<24|B>>>8);var C,Q,te,Se,Ae,j,q,ee,re,ue,be,ce,B=D.words,R=F.words,V=_.words,L=b.words,$=E.words,J=M.words;for(q=Q=(C=this._hash.words)[0],ee=te=C[1],re=Se=C[2],ue=Ae=C[3],be=j=C[4],I=0;80>I;I+=1)ce=Q+U[z+V[I]]|0,ce=16>I?ce+((te^Se^Ae)+B[0]):32>I?ce+((te&Se|~te&Ae)+B[1]):48>I?ce+(((te|~Se)^Ae)+B[2]):64>I?ce+((te&Ae|Se&~Ae)+B[3]):ce+((te^(Se|~Ae))+B[4]),ce=(ce=(ce|=0)<<$[I]|ce>>>32-$[I])+j|0,Q=j,j=Ae,Ae=Se<<10|Se>>>22,Se=te,te=ce,ce=q+U[z+L[I]]|0,ce=16>I?ce+((ee^(re|~ue))+R[0]):32>I?ce+((ee&ue|re&~ue)+R[1]):48>I?ce+(((ee|~re)^ue)+R[2]):64>I?ce+((ee&re|~ee&ue)+R[3]):ce+((ee^re^ue)+R[4]),ce=(ce=(ce|=0)<>>32-J[I])+be|0,q=be,be=ue,ue=re<<10|re>>>22,re=ee,ee=ce;ce=C[1]+Se+ue|0,C[1]=C[2]+Ae+be|0,C[2]=C[3]+j+q|0,C[3]=C[4]+Q+ee|0,C[4]=C[0]+te+re|0,C[0]=ce},_doFinalize:function(){var U=this._data,z=U.words,I=8*this._nDataBytes,C=8*U.sigBytes;for(z[C>>>5]|=128<<24-C%32,z[14+(C+64>>>9<<4)]=16711935&(I<<8|I>>>24)|4278255360&(I<<24|I>>>8),U.sigBytes=4*(z.length+1),this._process(),z=(U=this._hash).words,I=0;5>I;I++)z[I]=16711935&((C=z[I])<<8|C>>>24)|4278255360&(C<<24|C>>>8);return U},clone:function(){var U=f.clone.call(this);return U._hash=this._hash.clone(),U}}),l.RIPEMD160=f._createHelper(P),l.HmacRIPEMD160=f._createHmacHelper(P)}(Math),function(){var h=pt.enc.Utf8;pt.algo.HMAC=pt.lib.Base.extend({init:function(f,_){f=this._hasher=new f.init,"string"==typeof _&&(_=h.parse(_));var b=f.blockSize,E=4*b;_.sigBytes>E&&(_=f.finalize(_)),_.clamp();for(var M=this._oKey=_.clone(),D=this._iKey=_.clone(),F=M.words,P=D.words,U=0;U>6)+ps.charAt(63&f);if(h+1==l.length?(f=parseInt(l.substring(h,h+1),16),_+=ps.charAt(f<<2)):h+2==l.length&&(f=parseInt(l.substring(h,h+2),16),_+=ps.charAt(f>>2)+ps.charAt((3&f)<<4)),Ia)for(;(3&_.length)>0;)_+=Ia;return _}function ao(l){var f,b,E,h="",_=0;for(f=0;f>2),b=3&E,_=1):1==_?(h+=un(b<<2|E>>4),b=15&E,_=2):2==_?(h+=un(b),h+=un(E>>2),b=3&E,_=3):(h+=un(b<<2|E>>4),h+=un(15&E),_=0));return 1==_&&(h+=un(b<<2)),h}function _e(l,h,f){null!=l&&("number"==typeof l?this.fromNumber(l,h,f):this.fromString(l,null==h&&"string"!=typeof l?256:h))}function An(){return new _e(null)}"Microsoft Internet Explorer"==qr.appName?(_e.prototype.am=function ks(l,h,f,_,b,E){for(var M=32767&h,D=h>>15;--E>=0;){var F=32767&this[l],P=this[l++]>>15,U=D*F+P*M;b=((F=M*F+((32767&U)<<15)+f[_]+(1073741823&b))>>>30)+(U>>>15)+D*P+(b>>>30),f[_++]=1073741823&F}return b},Kr=30):"Netscape"!=qr.appName?(_e.prototype.am=function di(l,h,f,_,b,E){for(;--E>=0;){var M=h*this[l++]+f[_]+b;b=Math.floor(M/67108864),f[_++]=67108863&M}return b},Kr=26):(_e.prototype.am=function Fa(l,h,f,_,b,E){for(var M=16383&h,D=h>>14;--E>=0;){var F=16383&this[l],P=this[l++]>>14,U=D*F+P*M;b=((F=M*F+((16383&U)<<14)+f[_]+b)>>28)+(U>>14)+D*P,f[_++]=268435455&F}return b},Kr=28),_e.prototype.DB=Kr,_e.prototype.DM=(1<>>16)&&(l=f,h+=16),0!=(f=l>>8)&&(l=f,h+=8),0!=(f=l>>4)&&(l=f,h+=4),0!=(f=l>>2)&&(l=f,h+=2),0!=(f=l>>1)&&(l=f,h+=1),h}function _t(l){this.m=l}function Gc(l){this.m=l,this.mp=l.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<>=16,h+=16),255&l||(l>>=8,h+=8),15&l||(l>>=4,h+=4),3&l||(l>>=2,h+=2),1&l||++h,h}function wn(l){for(var h=0;0!=l;)l&=l-1,++h;return h}function fc(){}function O0(l){return l}function Je(l){this.r2=An(),this.q3=An(),_e.ONE.dlShiftTo(2*l.t,this.r2),this.mu=this.r2.divide(l),this.m=l}_t.prototype.convert=function uu(l){return l.s<0||l.compareTo(this.m)>=0?l.mod(this.m):l},_t.prototype.revert=function zc(l){return l},_t.prototype.reduce=function hu(l){l.divRemTo(this.m,null,l)},_t.prototype.mulTo=function Ep(l,h,f){l.multiplyTo(h,f),this.reduce(f)},_t.prototype.sqrTo=function lo(l,h){l.squareTo(h),this.reduce(h)},Gc.prototype.convert=function Oa(l){var h=An();return l.abs().dlShiftTo(this.m.t,h),h.divRemTo(this.m,null,h),l.s<0&&h.compareTo(_e.ZERO)>0&&this.m.subTo(h,h),h},Gc.prototype.revert=function Mp(l){var h=An();return l.copyTo(h),this.reduce(h),h},Gc.prototype.reduce=function dr(l){for(;l.t<=this.mt2;)l[l.t++]=0;for(var h=0;h>15)*this.mpl&this.um)<<15)&l.DM;for(l[f=h+this.m.t]+=this.m.am(0,_,l,h,0,this.m.t);l[f]>=l.DV;)l[f]-=l.DV,l[++f]++}l.clamp(),l.drShiftTo(this.m.t,l),l.compareTo(this.m)>=0&&l.subTo(this.m,l)},Gc.prototype.mulTo=function qo(l,h,f){l.multiplyTo(h,f),this.reduce(f)},Gc.prototype.sqrTo=function ur(l,h){l.squareTo(h),this.reduce(h)},_e.prototype.copyTo=function lu(l){for(var h=this.t-1;h>=0;--h)l[h]=this[h];l.t=this.t,l.s=this.s},_e.prototype.fromInt=function Pa(l){this.t=1,this.s=l<0?-1:0,l>0?this[0]=l:l<-1?this[0]=l+this.DV:this.t=0},_e.prototype.fromString=function du(l,h){var f;if(16==h)f=4;else if(8==h)f=3;else if(256==h)f=8;else if(2==h)f=1;else if(32==h)f=5;else{if(4!=h)return void this.fromRadix(l,h);f=2}this.t=0,this.s=0;for(var _=l.length,b=!1,E=0;--_>=0;){var M=8==f?255&l[_]:Ra(l,_);M<0?"-"==l.charAt(_)&&(b=!0):(b=!1,0==E?this[this.t++]=M:E+f>this.DB?(this[this.t-1]|=(M&(1<>this.DB-E):this[this.t-1]|=M<=this.DB&&(E-=this.DB))}8==f&&128&l[0]&&(this.s=-1,E>0&&(this[this.t-1]|=(1<0&&this[this.t-1]==l;)--this.t},_e.prototype.dlShiftTo=function fn(l,h){var f;for(f=this.t-1;f>=0;--f)h[f+l]=this[f];for(f=l-1;f>=0;--f)h[f]=0;h.t=this.t+l,h.s=this.s},_e.prototype.drShiftTo=function Fn(l,h){for(var f=l;f=0;--D)h[D+E+1]=this[D]>>_|M,M=(this[D]&b)<=0;--D)h[D]=0;h[E]=M,h.t=this.t+E+1,h.s=this.s,h.clamp()},_e.prototype.rShiftTo=function Wi(l,h){h.s=this.s;var f=Math.floor(l/this.DB);if(f>=this.t)h.t=0;else{var _=l%this.DB,b=this.DB-_,E=(1<<_)-1;h[0]=this[f]>>_;for(var M=f+1;M>_;_>0&&(h[this.t-f-1]|=(this.s&E)<>=this.DB;if(l.t>=this.DB;_+=this.s}else{for(_+=this.s;f>=this.DB;_-=l.s}h.s=_<0?-1:0,_<-1?h[f++]=this.DV+_:_>0&&(h[f++]=_),h.t=f,h.clamp()},_e.prototype.multiplyTo=function co(l,h){var f=this.abs(),_=l.abs(),b=f.t;for(h.t=b+_.t;--b>=0;)h[b]=0;for(b=0;b<_.t;++b)h[b+f.t]=f.am(0,_[b],h,b,0,f.t);h.s=0,h.clamp(),this.s!=l.s&&_e.ZERO.subTo(h,h)},_e.prototype.squareTo=function dc(l){for(var h=this.abs(),f=l.t=2*h.t;--f>=0;)l[f]=0;for(f=0;f=h.DV&&(l[f+h.t]-=h.DV,l[f+h.t+1]=1)}l.t>0&&(l[l.t-1]+=h.am(f,h[f],l,2*f,0,1)),l.s=0,l.clamp()},_e.prototype.divRemTo=function $o(l,h,f){var _=l.abs();if(!(_.t<=0)){var b=this.abs();if(b.t<_.t)return h?.fromInt(0),void(null!=f&&this.copyTo(f));null==f&&(f=An());var E=An(),M=this.s,D=l.s,F=this.DB-Qn(_[_.t-1]);F>0?(_.lShiftTo(F,E),b.lShiftTo(F,f)):(_.copyTo(E),b.copyTo(f));var P=E.t,U=E[P-1];if(0!=U){var z=U*(1<1?E[P-2]>>this.F2:0),I=this.FV/z,C=(1<=0&&(f[f.t++]=1,f.subTo(L,f)),_e.ONE.dlShiftTo(P,L),L.subTo(E,E);E.t=0;){var $=f[--R]==U?this.DM:Math.floor(f[R]*I+(f[R-1]+B)*C);if((f[R]+=E.am(0,$,f,V,0,P))<$)for(E.dlShiftTo(V,L),f.subTo(L,f);f[R]<--$;)f.subTo(L,f)}null!=h&&(f.drShiftTo(P,h),M!=D&&_e.ZERO.subTo(h,h)),f.t=P,f.clamp(),F>0&&f.rShiftTo(F,f),M<0&&_e.ZERO.subTo(f,f)}}},_e.prototype.invDigit=function ad(){if(this.t<1)return 0;var l=this[0];if(!(1&l))return 0;var h=3&l;return(h=(h=(h=(h=h*(2-(15&l)*h)&15)*(2-(255&l)*h)&255)*(2-((65535&l)*h&65535))&65535)*(2-l*h%this.DV)%this.DV)>0?this.DV-h:-h},_e.prototype.isEven=function cd(){return 0==(this.t>0?1&this[0]:this.s)},_e.prototype.exp=function Ih(l,h){if(l>4294967295||l<1)return _e.ONE;var f=An(),_=An(),b=h.convert(this),E=Qn(l)-1;for(b.copyTo(f);--E>=0;)if(h.sqrTo(f,_),(l&1<0)h.mulTo(_,b,f);else{var M=f;f=_,_=M}return h.revert(f)},_e.prototype.toString=function od(l){if(this.s<0)return"-"+this.negate().toString(l);var h;if(16==l)h=4;else if(8==l)h=3;else if(2==l)h=1;else if(32==l)h=5;else{if(4!=l)return this.toRadix(l);h=2}var _,f=(1<0)for(D>D)>0&&(b=!0,E=un(_));M>=0;)D>(D+=this.DB-h)):(_=this[M]>>(D-=h)&f,D<=0&&(D+=this.DB,--M)),_>0&&(b=!0),b&&(E+=un(_));return b?E:"0"},_e.prototype.negate=function cc(){var l=An();return _e.ZERO.subTo(this,l),l},_e.prototype.abs=function Pt(){return this.s<0?this.negate():this},_e.prototype.compareTo=function $t(l){var h=this.s-l.s;if(0!=h)return h;var f=this.t;if(0!=(h=f-l.t))return this.s<0?-h:h;for(;--f>=0;)if(0!=(h=this[f]-l[f]))return h;return 0},_e.prototype.bitLength=function In(){return this.t<=0?0:this.DB*(this.t-1)+Qn(this[this.t-1]^this.s&this.DM)},_e.prototype.mod=function Fs(l){var h=An();return this.abs().divRemTo(l,null,h),this.s<0&&h.compareTo(_e.ZERO)>0&&l.subTo(h,h),h},_e.prototype.modPowInt=function Ml(l,h){var f;return f=l<256||h.isEven()?new _t(h):new Gc(h),this.exp(l,f)},_e.ZERO=Ws(0),_e.ONE=Ws(1),fc.prototype.convert=O0,fc.prototype.revert=O0,fc.prototype.mulTo=function Rs(l,h,f){l.multiplyTo(h,f)},fc.prototype.sqrTo=function Ci(l,h){l.squareTo(h)},Je.prototype.convert=function N0(l){if(l.s<0||l.t>2*this.m.t)return l.mod(this.m);if(l.compareTo(this.m)<0)return l;var h=An();return l.copyTo(h),this.reduce(h),h},Je.prototype.revert=function On(l){return l},Je.prototype.reduce=function _u(l){for(l.drShiftTo(this.m.t-1,this.r2),l.t>this.m.t+1&&(l.t=this.m.t+1,l.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);l.compareTo(this.r2)<0;)l.dAddOffset(1,this.m.t+1);for(l.subTo(this.r2,l);l.compareTo(this.m)>=0;)l.subTo(this.m,l)},Je.prototype.mulTo=function kp(l,h,f){l.multiplyTo(h,f),this.reduce(f)},Je.prototype.sqrTo=function B0(l,h){l.squareTo(h),this.reduce(h)};var Xr=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],zh=(1<<26)/Xr[Xr.length-1];function dd(){this.i=0,this.j=0,this.S=new Array}_e.prototype.chunkSize=function Fh(l){return Math.floor(Math.LN2*this.DB/Math.log(l))},_e.prototype.toRadix=function Rh(l){if(null==l&&(l=10),0==this.signum()||l<2||l>36)return"0";var h=this.chunkSize(l),f=Math.pow(l,h),_=Ws(f),b=An(),E=An(),M="";for(this.divRemTo(_,b,E);b.signum()>0;)M=(f+E.intValue()).toString(l).substr(1)+M,b.divRemTo(_,b,E);return E.intValue().toString(l)+M},_e.prototype.fromRadix=function Ph(l,h){this.fromInt(0),null==h&&(h=10);for(var f=this.chunkSize(h),_=Math.pow(h,f),b=!1,E=0,M=0,D=0;D=f&&(this.dMultiply(_),this.dAddOffset(M,0),E=0,M=0))}E>0&&(this.dMultiply(Math.pow(h,E)),this.dAddOffset(M,0)),b&&_e.ZERO.subTo(this,this)},_e.prototype.fromNumber=function Cp(l,h,f){if("number"==typeof h)if(l<2)this.fromInt(1);else for(this.fromNumber(l,f),this.testBit(l-1)||this.bitwiseTo(_e.ONE.shiftLeft(l-1),ki,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(h);)this.dAddOffset(2,0),this.bitLength()>l&&this.subTo(_e.ONE.shiftLeft(l-1),this);else{var _=new Array,b=7&l;_.length=1+(l>>3),h.nextBytes(_),b>0?_[0]&=(1<>=this.DB;if(l.t>=this.DB;_+=this.s}else{for(_+=this.s;f>=this.DB;_+=l.s}h.s=_<0?-1:0,_>0?h[f++]=_:_<-1&&(h[f++]=this.DV+_),h.t=f,h.clamp()},_e.prototype.dMultiply=function P0(l){this[this.t]=this.am(0,l-1,this,0,0,this.t),++this.t,this.clamp()},_e.prototype.dAddOffset=function bb(l,h){if(0!=l){for(;this.t<=h;)this[this.t++]=0;for(this[h]+=l;this[h]>=this.DV;)this[h]-=this.DV,++h>=this.t&&(this[this.t++]=0),++this[h]}},_e.prototype.multiplyLowerTo=function wb(l,h,f){var b,_=Math.min(this.t+l.t,h);for(f.s=0,f.t=_;_>0;)f[--_]=0;for(b=f.t-this.t;_=0;)f[_]=0;for(_=Math.max(h-this.t,0);_0)if(0==h)f=this[0]%l;else for(var _=this.t-1;_>=0;--_)f=(h*f+this[_])%l;return f},_e.prototype.millerRabin=function tn(l){var h=this.subtract(_e.ONE),f=h.getLowestSetBit();if(f<=0)return!1;var _=h.shiftRight(f);(l=l+1>>1)>Xr.length&&(l=Xr.length);for(var b=An(),E=0;E>24},_e.prototype.shortValue=function Cl(){return 0==this.t?this.s:this[0]<<16>>16},_e.prototype.signum=function ld(){return this.s<0?-1:this.t<=0||1==this.t&&this[0]<=0?0:1},_e.prototype.toByteArray=function Oh(){var l=this.t,h=new Array;h[0]=this.s;var _,f=this.DB-l*this.DB%8,b=0;if(l-- >0)for(f>f)!=(this.s&this.DM)>>f&&(h[b++]=_|this.s<=0;)f<8?(_=(this[l]&(1<>(f+=this.DB-8)):(_=this[l]>>(f-=8)&255,f<=0&&(f+=this.DB,--l)),128&_&&(_|=-256),0==b&&(128&this.s)!=(128&_)&&++b,(b>0||_!=this.s)&&(h[b++]=_);return h},_e.prototype.equals=function Lh(l){return 0==this.compareTo(l)},_e.prototype.min=function Nh(l){return this.compareTo(l)<0?this:l},_e.prototype.max=function Bh(l){return this.compareTo(l)>0?this:l},_e.prototype.and=function Vh(l){var h=An();return this.bitwiseTo(l,Vi,h),h},_e.prototype.or=function fu(l){var h=An();return this.bitwiseTo(l,ki,h),h},_e.prototype.xor=function Mi(l){var h=An();return this.bitwiseTo(l,Tp,h),h},_e.prototype.andNot=function Hh(l){var h=An();return this.bitwiseTo(l,en,h),h},_e.prototype.not=function pu(){for(var l=An(),h=0;h=this.t?0!=this.s:0!=(this[h]&1<1){var U=An();for(E.sqrTo(M[1],U);D<=P;)M[D]=An(),E.mulTo(U,M[D-2],M[D]),D+=2}var I,R,z=l.t-1,C=!0,B=An();for(f=Qn(l[z])-1;z>=0;){for(f>=F?I=l[z]>>f-F&P:(I=(l[z]&(1<0&&(I|=l[z-1]>>this.DB+f-F)),D=_;!(1&I);)I>>=1,--D;if((f-=D)<0&&(f+=this.DB,--z),C)M[I].copyTo(b),C=!1;else{for(;D>1;)E.sqrTo(b,B),E.sqrTo(B,b),D-=2;D>0?E.sqrTo(b,B):(R=b,b=B,B=R),E.mulTo(B,M[I],b)}for(;z>=0&&!(l[z]&1<=0?(f.subTo(_,f),h&&b.subTo(M,b),E.subTo(D,E)):(_.subTo(f,_),h&&M.subTo(b,M),D.subTo(E,D))}return 0!=_.compareTo(_e.ONE)?_e.ZERO:D.compareTo(l)>=0?D.subtract(l):D.signum()<0?(D.addTo(l,D),D.signum()<0?D.add(l):D):D},_e.prototype.pow=function xb(l){return this.exp(l,new fc)},_e.prototype.gcd=function Fp(l){var h=this.s<0?this.negate():this.clone(),f=l.s<0?l.negate():l.clone();if(h.compareTo(f)<0){var _=h;h=f,f=_}var b=h.getLowestSetBit(),E=f.getLowestSetBit();if(E<0)return h;for(b0&&(h.rShiftTo(E,h),f.rShiftTo(E,f));h.signum()>0;)(b=h.getLowestSetBit())>0&&h.rShiftTo(b,h),(b=f.getLowestSetBit())>0&&f.rShiftTo(b,f),h.compareTo(f)>=0?(h.subTo(f,h),h.rShiftTo(1,h)):(f.subTo(h,f),f.rShiftTo(1,f));return E>0&&f.lShiftTo(E,f),f},_e.prototype.isProbablePrime=function vu(l){var h,f=this.abs();if(1==f.t&&f[0]<=Xr[Xr.length-1]){for(h=0;h>8&255,$s[kr++]^=l>>16&255,$s[kr++]^=l>>24&255,kr>=Pp&&(kr-=Pp)}((new Date).getTime())}if(null==$s){var qs;if($s=new Array,kr=0,void 0!==le&&(void 0!==le.crypto||void 0!==le.msCrypto)){var hd=le.crypto||le.msCrypto;if(hd.getRandomValues){var Gh=new Uint8Array(32);for(hd.getRandomValues(Gh),qs=0;qs<32;++qs)$s[kr++]=Gh[qs]}else if("Netscape"==qr.appName&&qr.appVersion<"5"){var jh=le.crypto.random(32);for(qs=0;qs>>8,$s[kr++]=255&qs;kr=0,pc()}function Op(){if(null==Ii){for(pc(),(Ii=function yu(){return new dd}()).init($s),kr=0;kr<$s.length;++kr)$s[kr]=0;kr=0}return Ii.next()}function Ao(){}function hr(l,h){return new _e(l,h)}function hn(l,h,f){for(var _="",b=0;_.length>24,(16711680&b)>>16,(65280&b)>>8,255&b]))),b+=1;return _}function Ut(){this.n=null,this.e=0,this.d=null,this.p=null,this.q=null,this.dmp1=null,this.dmq1=null,this.coeff=null}function ko(l,h,f){for(var _="",b=0;_.length>24,(16711680&b)>>16,(65280&b)>>8,255&b])),b+=1;return _}function fr(l,h){this.x=h,this.q=l}function Mt(l,h,f,_){this.curve=l,this.x=h,this.y=f,this.z=null==_?_e.ONE:_,this.zinv=null}function Nr(l,h,f){this.q=l,this.a=this.fromBigInteger(h),this.b=this.fromBigInteger(f),this.infinity=new Mt(this,null,null)}Ao.prototype.nextBytes=function Wh(l){var h;for(h=0;h0&&h.length>0))throw"Invalid RSA public key";this.n=hr(l,16),this.e=parseInt(h,16)}},Ut.prototype.encrypt=function H0(l){var h=function Lp(l,h){if(h=0&&h>0;){var b=l.charCodeAt(_--);b<128?f[--h]=b:b>127&&b<2048?(f[--h]=63&b|128,f[--h]=b>>6|192):(f[--h]=63&b|128,f[--h]=b>>6&63|128,f[--h]=b>>12|224)}f[--h]=0;for(var E=new Ao,M=new Array;h>2;){for(M[0]=0;0==M[0];)E.nextBytes(M);f[--h]=M[0]}return f[--h]=2,f[--h]=0,new _e(f)}(l,this.n.bitLength()+7>>3);if(null==h)return null;var f=this.doPublic(h);if(null==f)return null;var _=f.toString(16);return 1&_.length?"0"+_:_},Ut.prototype.encryptOAEP=function U0(l,h,f){var _=function bu(l,h,f,_){var b=w.crypto.MessageDigest,E=w.crypto.Util,M=null;if(f||(f="sha1"),"string"==typeof f&&(M=b.getCanonicalAlgName(f),_=b.getHashLength(M),f=function(R){return Vr(E.hashHex(_s(R),M))}),l.length+2*_+2>h)throw"Message too long for RSA";var F,D="";for(F=0;F>3,h,f);if(null==_)return null;var b=this.doPublic(_);if(null==b)return null;var E=b.toString(16);return 1&E.length?"0"+E:E},Ut.prototype.type="RSA",Ut.prototype.doPrivate=function Si(l){if(null==this.p||null==this.q)return l.modPow(this.d,this.n);for(var h=l.mod(this.p).modPow(this.dmp1,this.p),f=l.mod(this.q).modPow(this.dmq1,this.q);h.compareTo(f)<0;)h=h.add(this.p);return h.subtract(f).multiply(this.coeff).mod(this.p).multiply(this.q).add(f)},Ut.prototype.setPrivate=function Ki(l,h,f){if(this.isPrivate=!0,"string"!=typeof l)this.n=l,this.e=h,this.d=f;else{if(!(null!=l&&null!=h&&l.length>0&&h.length>0))throw"Invalid RSA private key";this.n=hr(l,16),this.e=parseInt(h,16),this.d=hr(f,16)}},Ut.prototype.setPrivateEx=function Ko(l,h,f,_,b,E,M,D){if(this.isPrivate=!0,this.isPublic=!1,null==l)throw"RSASetPrivateEx N == null";if(null==h)throw"RSASetPrivateEx E == null";if(0==l.length)throw"RSASetPrivateEx N.length == 0";if(0==h.length)throw"RSASetPrivateEx E.length == 0";if(!(null!=l&&null!=h&&l.length>0&&h.length>0))throw"Invalid RSA private key in RSASetPrivateEx";this.n=hr(l,16),this.e=parseInt(h,16),this.d=hr(f,16),this.p=hr(_,16),this.q=hr(b,16),this.dmp1=hr(E,16),this.dmq1=hr(M,16),this.coeff=hr(D,16)},Ut.prototype.generate=function Na(l,h){var f=new Ao,_=l>>1;this.e=parseInt(h,16);for(var b=new _e(h,16),E=l/2-100,M=_e.ONE.shiftLeft(E);;){for(;this.p=new _e(l-_,1,f),0!=this.p.subtract(_e.ONE).gcd(b).compareTo(_e.ONE)||!this.p.isProbablePrime(10););for(;this.q=new _e(_,1,f),0!=this.q.subtract(_e.ONE).gcd(b).compareTo(_e.ONE)||!this.q.isProbablePrime(10););if(this.p.compareTo(this.q)<=0){var D=this.p;this.p=this.q,this.q=D}var F=this.q.subtract(this.p).abs();if(!(F.bitLength()=f.length)return null;for(var b="";++_191&&E<224?(b+=String.fromCharCode((31&E)<<6|63&f[_+1]),++_):(b+=String.fromCharCode((15&E)<<12|(63&f[_+1])<<6|63&f[_+2]),_+=2)}return b}(f,this.n.bitLength()+7>>3)},Ut.prototype.decryptOAEP=function $h(l,h,f){if(l.length!=Math.ceil(this.n.bitLength()/4))throw new Error("wrong ctext length");var _=hr(l,16),b=this.doPrivate(_);return null==b?null:function Xi(l,h,f,_){var b=w.crypto.MessageDigest,E=w.crypto.Util,M=null;for(f||(f="sha1"),"string"==typeof f&&(M=b.getCanonicalAlgName(f),_=b.getHashLength(M),f=function(V){return Vr(E.hashHex(_s(V),M))}),l=l.toByteArray(),z=0;z>3,h,f)},fr.prototype.equals=function qh(l){return l==this||this.q.equals(l.q)&&this.x.equals(l.x)},fr.prototype.toBigInteger=function Ba(){return this.x},fr.prototype.negate=function pr(){return new fr(this.q,this.x.negate().mod(this.q))},fr.prototype.add=function Np(l){return new fr(this.q,this.x.add(l.toBigInteger()).mod(this.q))},fr.prototype.subtract=function Ln(l){return new fr(this.q,this.x.subtract(l.toBigInteger()).mod(this.q))},fr.prototype.multiply=function Bp(l){return new fr(this.q,this.x.multiply(l.toBigInteger()).mod(this.q))},fr.prototype.square=function wu(){return new fr(this.q,this.x.square().mod(this.q))},fr.prototype.divide=function fo(l){return new fr(this.q,this.x.multiply(l.toBigInteger().modInverse(this.q)).mod(this.q))},fr.prototype.sqrt=function(){return new fr(this.q,this.x.sqrt().mod(this.q))},Mt.prototype.getX=function Vp(){return null==this.zinv&&(this.zinv=this.z.modInverse(this.curve.q)),this.curve.fromBigInteger(this.x.toBigInteger().multiply(this.zinv).mod(this.curve.q))},Mt.prototype.getY=function Kh(){return null==this.zinv&&(this.zinv=this.z.modInverse(this.curve.q)),this.curve.fromBigInteger(this.y.toBigInteger().multiply(this.zinv).mod(this.curve.q))},Mt.prototype.equals=function ut(l){return l==this||(this.isInfinity()?l.isInfinity():l.isInfinity()?this.isInfinity():!!l.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(l.z)).mod(this.curve.q).equals(_e.ZERO)&&l.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(l.z)).mod(this.curve.q).equals(_e.ZERO))},Mt.prototype.isInfinity=function Yi(){return null==this.x&&null==this.y||this.z.equals(_e.ZERO)&&!this.y.toBigInteger().equals(_e.ZERO)},Mt.prototype.negate=function Ei(){return new Mt(this.curve,this.x,this.y.negate(),this.z)},Mt.prototype.add=function Ni(l){if(this.isInfinity())return l;if(l.isInfinity())return this;var h=l.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(l.z)).mod(this.curve.q),f=l.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(l.z)).mod(this.curve.q);if(_e.ZERO.equals(f))return _e.ZERO.equals(h)?this.twice():this.curve.getInfinity();var _=new _e("3"),b=this.x.toBigInteger(),E=this.y.toBigInteger(),F=(l.x.toBigInteger(),l.y.toBigInteger(),f.square()),P=F.multiply(f),U=b.multiply(F),z=h.square().multiply(this.z),I=z.subtract(U.shiftLeft(1)).multiply(l.z).subtract(P).multiply(f).mod(this.curve.q),C=U.multiply(_).multiply(h).subtract(E.multiply(P)).subtract(z.multiply(h)).multiply(l.z).add(h.multiply(P)).mod(this.curve.q),B=P.multiply(this.z).multiply(l.z).mod(this.curve.q);return new Mt(this.curve,this.curve.fromBigInteger(I),this.curve.fromBigInteger(C),B)},Mt.prototype.twice=function Ps(){if(this.isInfinity())return this;if(0==this.y.toBigInteger().signum())return this.curve.getInfinity();var l=new _e("3"),h=this.x.toBigInteger(),f=this.y.toBigInteger(),_=f.multiply(this.z),b=_.multiply(f).mod(this.curve.q),E=this.curve.a.toBigInteger(),M=h.square().multiply(l);_e.ZERO.equals(E)||(M=M.add(this.z.square().multiply(E)));var D=(M=M.mod(this.curve.q)).square().subtract(h.shiftLeft(3).multiply(b)).shiftLeft(1).multiply(_).mod(this.curve.q),F=M.multiply(l).multiply(h).subtract(b.shiftLeft(1)).shiftLeft(2).multiply(b).subtract(M.square().multiply(M)).mod(this.curve.q),P=_.square().multiply(_).shiftLeft(3).mod(this.curve.q);return new Mt(this.curve,this.curve.fromBigInteger(D),this.curve.fromBigInteger(F),P)},Mt.prototype.multiply=function Zr(l){if(this.isInfinity())return this;if(0==l.signum())return this.curve.getInfinity();var P,h=l,f=h.multiply(new _e("3")),_=this.negate(),b=this,E=this.curve.q.subtract(l),M=E.multiply(new _e("3")),D=new Mt(this.curve,this.x,this.y),F=D.negate();for(P=f.bitLength()-2;P>0;--P){b=b.twice();var U=f.testBit(P);U!=h.testBit(P)&&(b=b.add(U?this:_))}for(P=M.bitLength()-2;P>0;--P){D=D.twice();var I=M.testBit(P);I!=E.testBit(P)&&(D=D.add(I?D:F))}return b},Mt.prototype.multiplyTwo=function po(l,h,f){var _;_=l.bitLength()>f.bitLength()?l.bitLength()-1:f.bitLength()-1;for(var b=this.curve.getInfinity(),E=this.add(h);_>=0;)b=b.twice(),l.testBit(_)?b=f.testBit(_)?b.add(E):b.add(this):f.testBit(_)&&(b=b.add(h)),--_;return b},Nr.prototype.getQ=function xt(){return this.q},Nr.prototype.getA=function Sn(){return this.a},Nr.prototype.getB=function Zi(){return this.b},Nr.prototype.equals=function si(l){return l==this||this.q.equals(l.q)&&this.a.equals(l.a)&&this.b.equals(l.b)},Nr.prototype.getInfinity=function Ks(){return this.infinity},Nr.prototype.fromBigInteger=function Br(l){return new fr(this.q,l)},Nr.prototype.decodePointHex=function Al(l){switch(parseInt(l.substr(0,2),16)){case 0:return this.infinity;case 2:case 3:var h=l.substr(0,2),_=(l.substr(2),this.fromBigInteger(new _e(P,16))),b=this.getA(),E=this.getB(),D=_.square().add(b).multiply(_).add(E).sqrt();return"03"==h&&(D=D.negate()),new Mt(this,_,D);case 4:case 6:case 7:var F=(l.length-2)/2,P=l.substr(2,F),U=l.substr(F+2,F);return new Mt(this,this.fromBigInteger(new _e(P,16)),this.fromBigInteger(new _e(U,16)));default:return null}},fr.prototype.getByteLength=function(){return Math.floor((this.toBigInteger().bitLength()+7)/8)},Mt.prototype.getEncoded=function(l){var h=function(E,M){var D=E.toByteArrayUnsigned();if(MD.length;)D.unshift(0);return D},f=this.getX().toBigInteger(),_=this.getY().toBigInteger(),b=h(f,32);return l?_.isEven()?b.unshift(2):b.unshift(3):(b.unshift(4),b=b.concat(h(_,32))),b},Mt.decodeFrom=function(l,h){var _=h.length-1,b=h.slice(1,1+_/2),E=h.slice(1+_/2,1+_);b.unshift(0),E.unshift(0);var M=new _e(b),D=new _e(E);return new Mt(l,l.fromBigInteger(M),l.fromBigInteger(D))},Mt.decodeFromHex=function(l,h){h.substr(0,2);var _=h.length-2,b=h.substr(2,_/2),E=h.substr(2+_/2,_/2),M=new _e(b,16),D=new _e(E,16);return new Mt(l,l.fromBigInteger(M),l.fromBigInteger(D))},Mt.prototype.add2D=function(l){if(this.isInfinity())return l;if(l.isInfinity())return this;if(this.x.equals(l.x))return this.y.equals(l.y)?this.twice():this.curve.getInfinity();var h=l.x.subtract(this.x),_=l.y.subtract(this.y).divide(h),b=_.square().subtract(this.x).subtract(l.x),E=_.multiply(this.x.subtract(b)).subtract(this.y);return new Mt(this.curve,b,E)},Mt.prototype.twice2D=function(){if(this.isInfinity())return this;if(0==this.y.toBigInteger().signum())return this.curve.getInfinity();var l=this.curve.fromBigInteger(_e.valueOf(2)),h=this.curve.fromBigInteger(_e.valueOf(3)),f=this.x.square().multiply(h).add(this.curve.a).divide(this.y.multiply(l)),_=f.square().subtract(this.x.multiply(l)),b=f.multiply(this.x.subtract(_)).subtract(this.y);return new Mt(this.curve,_,b)},Mt.prototype.multiply2D=function(l){if(this.isInfinity())return this;if(0==l.signum())return this.curve.getInfinity();var E,h=l,f=h.multiply(new _e("3")),_=this.negate(),b=this;for(E=f.bitLength()-2;E>0;--E){b=b.twice();var M=f.testBit(E);M!=h.testBit(E)&&(b=b.add2D(M?this:_))}return b},Mt.prototype.isOnCurve=function(){var l=this.getX().toBigInteger(),h=this.getY().toBigInteger(),f=this.curve.getA().toBigInteger(),_=this.curve.getB().toBigInteger(),b=this.curve.getQ(),E=h.multiply(h).mod(b),M=l.multiply(l).multiply(l).add(f.multiply(l)).add(_).mod(b);return E.equals(M)},Mt.prototype.toString=function(){return"("+this.getX().toBigInteger().toString()+","+this.getY().toBigInteger().toString()+")"},Mt.prototype.validate=function(){var l=this.curve.getQ();if(this.isInfinity())throw new Error("Point is at infinity.");var h=this.getX().toBigInteger(),f=this.getY().toBigInteger();if(h.compareTo(_e.ONE)<0||h.compareTo(l.subtract(_e.ONE))>0)throw new Error("x coordinate out of bounds");if(f.compareTo(_e.ONE)<0||f.compareTo(l.subtract(_e.ONE))>0)throw new Error("y coordinate out of bounds");if(!this.isOnCurve())throw new Error("Point is not on the curve.");if(this.multiply(l).isInfinity())throw new Error("Point is not a scalar multiple of G.");return!0};var Ji=function(){var _=new RegExp('(?:false|true|null|[\\{\\}\\[\\]]|(?:-?\\b(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?(?:[eE][+-]?[0-9]+)?\\b)|(?:"(?:[^\\0-\\x08\\x0a-\\x1f"\\\\]|\\\\(?:["/\\\\bfnrt]|u[0-9A-Fa-f]{4}))*"))',"g"),b=new RegExp("\\\\(?:([^u])|u(.{4}))","g"),E={'"':'"',"/":"/","\\":"\\",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"};function M(z,I,C){return I?E[I]:String.fromCharCode(parseInt(C,16))}var D=new String(""),U=Object.hasOwnProperty;return function(z,I){var B,C=z.match(_),R=C[0],V=!1;"{"===R?B={}:"["===R?B=[]:(B=[],V=!0);for(var L,$=[B],J=1-V,Q=C.length;J=0;)delete q[ee[be]]}return I.call(Ae,j,q)};B=Se({"":B},"")}return B}}();(typeof w>"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),w.asn1.ASN1Util=new function(){this.integerToByteHex=function(l){var h=l.toString(16);return h.length%2==1&&(h="0"+h),h},this.bigIntToMinTwosComplementsHex=function(l){var h=l.toString(16);if("-"!=h.substr(0,1))h.length%2==1?h="0"+h:h.match(/^[0-7]/)||(h="00"+h);else{var _=h.substr(1).length;_%2==1?_+=1:h.match(/^[0-7]/)||(_+=2);for(var b="",E=0;E<_;E++)b+="f";h=new _e(b,16).xor(l).add(_e.ONE).toString(16).replace(/^-/,"")}return h},this.getPEMStringFromHex=function(l,h){return Fr(l,h)},this.newObject=function(l){var f=w.asn1,_=f.ASN1Object,b=f.DERBoolean,E=f.DERInteger,M=f.DERBitString,D=f.DEROctetString,F=f.DERNull,P=f.DERObjectIdentifier,U=f.DEREnumerated,z=f.DERUTF8String,I=f.DERNumericString,C=f.DERPrintableString,B=f.DERTeletexString,R=f.DERIA5String,V=f.DERUTCTime,L=f.DERGeneralizedTime,$=f.DERVisibleString,J=f.DERBMPString,Q=f.DERSequence,te=f.DERSet,Se=f.DERTaggedObject,Ae=f.ASN1Util.newObject;if(l instanceof f.ASN1Object)return l;var j=Object.keys(l);if(1!=j.length)throw new Error("key of param shall be only one.");var q=j[0];if(-1==":asn1:bool:int:bitstr:octstr:null:oid:enum:utf8str:numstr:prnstr:telstr:ia5str:utctime:gentime:visstr:bmpstr:seq:set:tag:".indexOf(":"+q+":"))throw new Error("undefined key: "+q);if("bool"==q)return new b(l[q]);if("int"==q)return new E(l[q]);if("bitstr"==q)return new M(l[q]);if("octstr"==q)return new D(l[q]);if("null"==q)return new F(l[q]);if("oid"==q)return new P(l[q]);if("enum"==q)return new U(l[q]);if("utf8str"==q)return new z(l[q]);if("numstr"==q)return new I(l[q]);if("prnstr"==q)return new C(l[q]);if("telstr"==q)return new B(l[q]);if("ia5str"==q)return new R(l[q]);if("utctime"==q)return new V(l[q]);if("gentime"==q)return new L(l[q]);if("visstr"==q)return new $(l[q]);if("bmpstr"==q)return new J(l[q]);if("asn1"==q)return new _(l[q]);if("seq"==q){for(var ee=l[q],re=[],ue=0;ue"u"||null==this.hV)throw new Error("this.hV is null or undefined");if(this.hV.length%2==1)throw new Error("value hex must be even length: n="+"".length+",v="+this.hV);var M=this.hV.length/2,D=M.toString(16);if(D.length%2==1&&(D="0"+D),M<128)return D;var F=D.length/2;if(F>15)throw new Error("ASN.1 length too long to represent by 8x: n = "+M.toString(16));return(128+F).toString(16)+D},this.tohex=function(){return(null==this.hTLV||this.isModified)&&(this.hV=this.getFreshValueHex(),this.hL=this.getLengthHexFromValue(),this.hTLV=this.hT+this.hL+this.hV,this.isModified=!1),this.hTLV},this.getEncodedHex=function(){return this.tohex()},this.getValueHex=function(){return this.tohex(),this.hV},this.getFreshValueHex=function(){return""},this.setByParam=function(M){this.params=M},null!=l&&null!=l.tlv&&(this.hTLV=l.tlv,this.isModified=!1)},w.asn1.DERAbstractString=function(l){w.asn1.DERAbstractString.superclass.constructor.call(this),this.getString=function(){return this.s},this.setString=function(_){this.hTLV=null,this.isModified=!0,this.s=_,this.hV=Io(this.s).toLowerCase()},this.setStringHex=function(_){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=_},this.getFreshValueHex=function(){return this.hV},typeof l<"u"&&("string"==typeof l?this.setString(l):typeof l.str<"u"?this.setString(l.str):typeof l.hex<"u"&&this.setStringHex(l.hex))},He(w.asn1.DERAbstractString,w.asn1.ASN1Object),w.asn1.DERAbstractTime=function(l){w.asn1.DERAbstractTime.superclass.constructor.call(this),this.localDateToUTC=function(_){var b=_.getTime()+6e4*_.getTimezoneOffset();return new Date(b)},this.formatDate=function(_,b,E){var M=this.zeroPadding,D=this.localDateToUTC(_),F=String(D.getFullYear());"utc"==b&&(F=F.substr(2,2));var B=F+M(String(D.getMonth()+1),2)+M(String(D.getDate()),2)+M(String(D.getHours()),2)+M(String(D.getMinutes()),2)+M(String(D.getSeconds()),2);if(!0===E){var R=D.getMilliseconds();if(0!=R){var V=M(String(R),3);B=B+"."+(V=V.replace(/[0]+$/,""))}}return B+"Z"},this.zeroPadding=function(_,b){return _.length>=b?_:new Array(b-_.length+1).join("0")+_},this.setByParam=function(_){this.hV=null,this.hTLV=null,this.params=_},this.getString=function(){},this.setString=function(_){this.hTLV=null,this.isModified=!0,null==this.params&&(this.params={}),this.params.str=_},this.setByDate=function(_){this.hTLV=null,this.isModified=!0,null==this.params&&(this.params={}),this.params.date=_},this.setByDateValue=function(_,b,E,M,D,F){var P=new Date(Date.UTC(_,b-1,E,M,D,F,0));this.setByDate(P)},this.getFreshValueHex=function(){return this.hV}},He(w.asn1.DERAbstractTime,w.asn1.ASN1Object),w.asn1.DERAbstractStructured=function(l){w.asn1.DERAbstractString.superclass.constructor.call(this),this.setByASN1ObjectArray=function(f){this.hTLV=null,this.isModified=!0,this.asn1Array=f},this.appendASN1Object=function(f){this.hTLV=null,this.isModified=!0,this.asn1Array.push(f)},this.asn1Array=new Array,typeof l<"u"&&typeof l.array<"u"&&(this.asn1Array=l.array)},He(w.asn1.DERAbstractStructured,w.asn1.ASN1Object),w.asn1.DERBoolean=function(l){w.asn1.DERBoolean.superclass.constructor.call(this),this.hT="01",this.hTLV=0==l?"010100":"0101ff"},He(w.asn1.DERBoolean,w.asn1.ASN1Object),w.asn1.DERInteger=function(l){w.asn1.DERInteger.superclass.constructor.call(this),this.hT="02",this.setByBigInteger=function(h){this.hTLV=null,this.isModified=!0,this.hV=w.asn1.ASN1Util.bigIntToMinTwosComplementsHex(h)},this.setByInteger=function(h){var f=new _e(String(h),10);this.setByBigInteger(f)},this.setValueHex=function(h){this.hV=h},this.getFreshValueHex=function(){return this.hV},typeof l<"u"&&(typeof l.bigint<"u"?this.setByBigInteger(l.bigint):typeof l.int<"u"?this.setByInteger(l.int):"number"==typeof l?this.setByInteger(l):typeof l.hex<"u"&&this.setValueHex(l.hex))},He(w.asn1.DERInteger,w.asn1.ASN1Object),w.asn1.DERBitString=function(l){if(void 0!==l&&typeof l.obj<"u"){var h=w.asn1.ASN1Util.newObject(l.obj);l.hex="00"+h.tohex()}w.asn1.DERBitString.superclass.constructor.call(this),this.hT="03",this.setHexValueIncludingUnusedBits=function(f){this.hTLV=null,this.isModified=!0,this.hV=f},this.setUnusedBitsAndHexValue=function(f,_){if(f<0||7>6).toString(16)+F.toString(16))}F=128|(15&E)<<2|(192&M)>>6;var P=128|63&M;return ei((224|(240&E)>>4).toString(16)+F.toString(16)+P.toString(16))});return _.join("")}function Fe(l){for(var h=encodeURIComponent(l),f="",_=0;_"7"?"00"+l:l}function vc(l){if(!qn(l))return null;try{var h=[],f=l.substr(0,2),_=parseInt(f,16);h[0]=new String(Math.floor(_/40)),h[1]=new String(_%40);for(var b=l.substr(2),E=[],M=0;M0&&(P=P+"."+D.join(".")),P}catch{return null}}rt.getLblen=function(l,h){if("8"!=l.substr(h+2,1))return 1;var f=parseInt(l.substr(h+3,1));return 0==f?-1:0=E)break}return _},rt.getNthChildIdx=function(l,h,f){return rt.getChildIdx(l,h)[f]},rt.getIdxbyList=function(l,h,f,_){var E,M,b=rt;return 0==f.length?void 0!==_&&l.substr(h,2)!==_?-1:h:(E=f.shift())>=(M=b.getChildIdx(l,h)).length?-1:b.getIdxbyList(l,M[E],f,_)},rt.getIdxbyListEx=function(l,h,f,_){var E,M,b=rt;if(0==f.length)return void 0!==_&&l.substr(h,2)!==_?-1:h;E=f.shift(),M=b.getChildIdx(l,h);for(var D=0,F=0;F=l.length?null:b.getTLV(l,E)},rt.getTLVbyListEx=function(l,h,f,_){var b=rt,E=b.getIdxbyListEx(l,h,f,_);return-1==E?null:b.getTLV(l,E)},rt.getVbyList=function(l,h,f,_,b){var M,D,E=rt;return-1==(M=E.getIdxbyList(l,h,f,_))||M>=l.length?null:(D=E.getV(l,M),!0===b&&(D=D.substr(2)),D)},rt.getVbyListEx=function(l,h,f,_,b){var M,F,E=rt;return-1==(M=E.getIdxbyListEx(l,h,f,_))?null:(F=E.getV(l,M),"03"==l.substr(M,2)&&!1!==b&&(F=F.substr(2)),F)},rt.getInt=function(l,h,f){null==f&&(f=-1);try{var _=l.substr(h,2);if("02"!=_&&"03"!=_)return f;var b=rt.getV(l,h);return"02"==_?parseInt(b,16):function Wc(l){if(l.length%2!=0||null==(l=l.toLowerCase()).match(/^[0-9a-f]+$/))return-1;try{var h=l.substr(0,2);if("00"==h)return parseInt(l.substr(2),16);var f=parseInt(h,16);if(f>7)return-1;var _=l.substr(2),b=parseInt(_,16).toString(2);"0"==b&&(b="00000000"),b=b.slice(0,0-f);var E=parseInt(b,2);return NaN==E?-1:E}catch{return-1}}(b)}catch{return f}},rt.getOID=function(l,h,f){null==f&&(f=null);try{return"06"!=l.substr(h,2)?f:vc(rt.getV(l,h))}catch{return f}},rt.getOIDName=function(l,h,f){null==f&&(f=null);try{var _=rt.getOID(l,h,f);if(_==f)return f;var b=w.asn1.x509.OID.oid2name(_);return""==b?_:b}catch{return f}},rt.getString=function(l,h,f){null==f&&(f=null);try{return Vr(rt.getV(l,h))}catch{return f}},rt.hextooidstr=function(l){var h=function(z,I){return z.length>=I?z:new Array(I-z.length+1).join("0")+z},f=[],_=l.substr(0,2),b=parseInt(_,16);f[0]=new String(Math.floor(b/40)),f[1]=new String(b%40);for(var E=l.substr(2),M=[],D=0;D0&&(U=U+"."+F.join(".")),U},rt.dump=function(l,h,f,_){var b=rt,E=b.getV,M=b.dump,D=b.getChildIdx,F=l;l instanceof w.asn1.ASN1Object&&(F=l.tohex());var P=function(Ae,j){return Ae.length<=2*j?Ae:Ae.substr(0,j)+"..(total "+Ae.length/2+"bytes).."+Ae.substr(Ae.length-j,j)};void 0===h&&(h={ommit_long_octet:32}),void 0===f&&(f=0),void 0===_&&(_="");var te,U=h.ommit_long_octet;if("01"==(te=F.substr(f,2)))return"00"==(z=E(F,f))?_+"BOOLEAN FALSE\n":_+"BOOLEAN TRUE\n";if("02"==te)return _+"INTEGER "+P(z=E(F,f),U)+"\n";if("03"==te){var z=E(F,f);return b.isASN1HEX(z.substr(2))?(I=_+"BITSTRING, encapsulates\n")+M(z.substr(2),h,0,_+" "):_+"BITSTRING "+P(z,U)+"\n"}if("04"==te)return z=E(F,f),b.isASN1HEX(z)?(I=_+"OCTETSTRING, encapsulates\n")+M(z,h,0,_+" "):_+"OCTETSTRING "+P(z,U)+"\n";if("05"==te)return _+"NULL\n";if("06"==te){var C=E(F,f),B=w.asn1.ASN1Util.oidHexToInt(C),R=w.asn1.x509.OID.oid2name(B),V=B.replace(/\./g," ");return""!=R?_+"ObjectIdentifier "+R+" ("+V+")\n":_+"ObjectIdentifier ("+V+")\n"}if("0a"==te)return _+"ENUMERATED "+parseInt(E(F,f))+"\n";if("0c"==te)return _+"UTF8String '"+ei(E(F,f))+"'\n";if("13"==te)return _+"PrintableString '"+ei(E(F,f))+"'\n";if("14"==te)return _+"TeletexString '"+ei(E(F,f))+"'\n";if("16"==te)return _+"IA5String '"+ei(E(F,f))+"'\n";if("17"==te)return _+"UTCTime "+ei(E(F,f))+"\n";if("18"==te)return _+"GeneralizedTime "+ei(E(F,f))+"\n";if("1a"==te)return _+"VisualString '"+ei(E(F,f))+"'\n";if("1e"==te)return _+"BMPString '"+Ge(E(F,f))+"'\n";if("30"==te){if("3000"==F.substr(f,4))return _+"SEQUENCE {}\n";I=_+"SEQUENCE\n";var $=h;if((2==(L=D(F,f)).length||3==L.length)&&"06"==F.substr(L[0],2)&&"04"==F.substr(L[L.length-1],2)){R=b.oidname(E(F,L[0]));var J=JSON.parse(JSON.stringify(h));J.x509ExtName=R,$=J}for(var Q=0;Q4?{enum:{hex:L}}:{enum:parseInt(L,16)};if("30"==R||"31"==R)return V[C[R]]=function(q){for(var ee=[],re=M(q,0),ue=0;ue31))&&128==(192&f)&&(31&f)==_}catch{return!1}},rt.isASN1HEX=function(l){var h=rt;if(l.length%2==1)return!1;var f=h.getVblen(l,0),_=l.substr(0,2),b=h.getL(l,0);return l.length-_.length-b.length==2*f},rt.checkStrictDER=function(l,h,f,_,b){var E=rt;if(void 0===f){if("string"!=typeof l)throw new Error("not hex string");if(l=l.toLowerCase(),!w.lang.String.isHex(l))throw new Error("not hex string");f=l.length,b=(_=l.length/2)<128?1:Math.ceil(_.toString(16))+1}if(E.getL(l,h).length>2*b)throw new Error("L of TLV too long: idx="+h);var D=E.getVblen(l,h);if(D>_)throw new Error("value of L too long than hex: idx="+h);var F=E.getTLV(l,h),P=F.length-2-E.getL(l,h).length;if(P!==2*D)throw new Error("V string length and L's value not the same:"+P+"/"+2*D);if(0===h&&l.length!=F.length)throw new Error("total length and TLV length unmatch:"+l.length+"!="+F.length);var U=l.substr(h,2);if("02"===U){var z=E.getVidx(l,h);if("00"==l.substr(z,2)&&l.charCodeAt(z+2)<56)throw new Error("not least zeros for DER INTEGER")}if(32&parseInt(U,16)){for(var I=E.getVblen(l,h),C=0,B=E.getChildIdx(l,h),R=0;R"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),(typeof w.asn1.x509>"u"||!w.asn1.x509)&&(w.asn1.x509={}),w.asn1.x509.Certificate=function(l){w.asn1.x509.Certificate.superclass.constructor.call(this);var f=w.asn1,_=f.DERBitString,b=f.DERSequence,E=f.x509,M=E.TBSCertificate,D=E.AlgorithmIdentifier;this.params=void 0,this.setByParam=function(F){this.params=F},this.sign=function(){var F=this.params,P=F.sigalg;null!=F.sigalg.name&&(P=F.sigalg.name);var U=F.tbsobj.tohex(),z=new w.crypto.Signature({alg:P});z.init(F.cakey),z.updateHex(U),F.sighex=z.sign()},this.getPEM=function(){return Fr(this.tohex(),"CERTIFICATE")},this.tohex=function(){var F=this.params;if((null==F.tbsobj||null==F.tbsobj)&&(F.tbsobj=new M(F)),null==F.sighex&&null!=F.cakey&&this.sign(),null==F.sighex)throw new Error("sighex or cakey parameter not defined");var P=[];return P.push(F.tbsobj),P.push(new D({name:F.sigalg})),P.push(new _({hex:"00"+F.sighex})),new b({array:P}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&(this.params=l)},He(w.asn1.x509.Certificate,w.asn1.ASN1Object),w.asn1.x509.TBSCertificate=function(l){w.asn1.x509.TBSCertificate.superclass.constructor.call(this);var f=w.asn1,_=f.x509,b=f.DERTaggedObject,E=f.DERInteger,M=f.DERSequence,D=_.AlgorithmIdentifier,F=_.Time,P=_.X500Name,U=_.Extensions,z=_.SubjectPublicKeyInfo;this.params=null,this.setByParam=function(I){this.params=I},this.tohex=function(){var I=[],C=this.params;if(null!=C.version||1!=C.version){var B=2;null!=C.version&&(B=C.version-1);var R=new b({obj:new E({int:B})});I.push(R)}return I.push(new E(C.serial)),I.push(new D({name:C.sigalg})),I.push(new P(C.issuer)),I.push(new M({array:[new F(C.notbefore),new F(C.notafter)]})),I.push(new P(C.subject)),I.push(new z(Zt.getKey(C.sbjpubkey))),void 0!==C.ext&&C.ext.length>0&&I.push(new b({tag:"a3",obj:new U(C.ext)})),new w.asn1.DERSequence({array:I}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.x509.TBSCertificate,w.asn1.ASN1Object),w.asn1.x509.Extensions=function(l){w.asn1.x509.Extensions.superclass.constructor.call(this);var f=w.asn1,_=f.DERSequence,b=f.x509;this.aParam=[],this.setByParam=function(E){this.aParam=E},this.tohex=function(){for(var E=[],M=0;M-1&&D.push(new _({int:this.pathLen}));var F=new b({array:D});return this.asn1ExtnValue=F,this.asn1ExtnValue.tohex()},this.oid="2.5.29.19",this.cA=!1,this.pathLen=-1,void 0!==l&&(void 0!==l.cA&&(this.cA=l.cA),void 0!==l.pathLen&&(this.pathLen=l.pathLen))},He(w.asn1.x509.BasicConstraints,w.asn1.x509.Extension),w.asn1.x509.CRLDistributionPoints=function(l){w.asn1.x509.CRLDistributionPoints.superclass.constructor.call(this,l);var f=w.asn1,_=f.x509;this.getExtnValueHex=function(){return this.asn1ExtnValue.tohex()},this.setByDPArray=function(b){for(var E=[],M=0;M0&&E.push(new f({array:M}))}return new f({array:E}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&(this.params=l)},He(w.asn1.x509.PolicyInformation,w.asn1.ASN1Object),w.asn1.x509.PolicyQualifierInfo=function(l){w.asn1.x509.PolicyQualifierInfo.superclass.constructor.call(this,l);var h=w.asn1,f=h.DERSequence,_=h.DERIA5String,b=h.DERObjectIdentifier,E=h.x509.UserNotice;this.params=null,this.tohex=function(){return void 0!==this.params.cps?new f({array:[new b({oid:"1.3.6.1.5.5.7.2.1"}),new _({str:this.params.cps})]}).tohex():null!=this.params.unotice?new f({array:[new b({oid:"1.3.6.1.5.5.7.2.2"}),new E(this.params.unotice)]}).tohex():void 0},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&(this.params=l)},He(w.asn1.x509.PolicyQualifierInfo,w.asn1.ASN1Object),w.asn1.x509.UserNotice=function(l){w.asn1.x509.UserNotice.superclass.constructor.call(this,l);var h=w.asn1.DERSequence,_=w.asn1.x509.DisplayText,b=w.asn1.x509.NoticeReference;this.params=null,this.tohex=function(){var E=[];return void 0!==this.params.noticeref&&E.push(new b(this.params.noticeref)),void 0!==this.params.exptext&&E.push(new _(this.params.exptext)),new h({array:E}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&(this.params=l)},He(w.asn1.x509.UserNotice,w.asn1.ASN1Object),w.asn1.x509.NoticeReference=function(l){w.asn1.x509.NoticeReference.superclass.constructor.call(this,l);var h=w.asn1.DERSequence,f=w.asn1.DERInteger,_=w.asn1.x509.DisplayText;this.params=null,this.tohex=function(){var b=[];if(void 0!==this.params.org&&b.push(new _(this.params.org)),void 0!==this.params.noticenum){for(var E=[],M=this.params.noticenum,D=0;D0)for(var M=0;M0;b++){var E=h.shift();if(!0===f){var D=(_.pop()+","+E).replace(/\\,/g,",");_.push(D),f=!1}else _.push(E);"\\"===E.substr(-1,1)&&(f=!0)}return _=_.map(function(F){return F.replace("/","\\/")}),_.reverse(),"/"+_.join("/")},w.asn1.x509.X500Name.ldapToOneline=function(l){return w.asn1.x509.X500Name.ldapToCompat(l)},w.asn1.x509.RDN=function(l){w.asn1.x509.RDN.superclass.constructor.call(this),this.asn1Array=[],this.paramArray=[],this.sRule="utf8";var h=w.asn1.x509.AttributeTypeAndValue;this.setByParam=function(f){void 0!==f.rule&&(this.sRule=f.rule),void 0!==f.str&&this.addByMultiValuedString(f.str),void 0!==f.array&&(this.paramArray=f.array)},this.addByString=function(f){this.asn1Array.push(new w.asn1.x509.AttributeTypeAndValue({str:f,rule:this.sRule}))},this.addByMultiValuedString=function(f){for(var _=w.asn1.x509.RDN.parseString(f),b=0;b<_.length;b++)this.addByString(_[b])},this.tohex=function(){if(0==this.asn1Array.length&&this.paramArray.length>0)for(var f=0;f0;b++){var E=h.shift();if(!0===f){var D=(_.pop()+"+"+E).replace(/\\\+/g,"+");_.push(D),f=!1}else _.push(E);"\\"===E.substr(-1,1)&&(f=!0)}var F=!1,P=[];for(b=0;_.length>0;b++){if(E=_.shift(),!0===F){var U=P.pop();E.match(/"$/)?(D=(U+"+"+E).replace(/^([^=]+)="(.*)"$/,"$1=$2"),P.push(D),F=!1):P.push(U+"+"+E)}else P.push(E);E.match(/^[^=]+="/)&&(F=!0)}return P},w.asn1.x509.AttributeTypeAndValue=function(l){w.asn1.x509.AttributeTypeAndValue.superclass.constructor.call(this),this.sRule="utf8",this.sType=null,this.sValue=null,this.dsType=null;var f=w.asn1,_=f.DERSequence,b=f.DERUTF8String,E=f.DERPrintableString,M=f.DERTeletexString,D=f.DERIA5String,F=f.DERVisibleString,P=f.DERBMPString,U=w.lang.String.isMail,z=w.lang.String.isPrintable;this.setByParam=function(I){if(void 0!==I.rule&&(this.sRule=I.rule),void 0!==I.ds&&(this.dsType=I.ds),void 0===I.value&&void 0!==I.str){var B=I.str.match(/^([^=]+)=(.+)$/);if(!B)throw new Error("malformed attrTypeAndValueStr: "+attrTypeAndValueStr);this.sType=B[1],this.sValue=B[2]}else this.sType=I.type,this.sValue=I.value},this.setByString=function(I,C){void 0!==C&&(this.sRule=C);var B=I.match(/^([^=]+)=(.+)$/);if(!B)throw new Error("malformed attrTypeAndValueStr: "+attrTypeAndValueStr);this.setByAttrTypeAndValueStr(B[1],B[2])},this._getDsType=function(){var I=this.sType,C=this.sValue,B=this.sRule;return"prn"===B?"CN"==I&&U(C)?"ia5":z(C)?"prn":"utf8":"utf8"===B?"CN"==I&&U(C)?"ia5":"C"==I?"prn":"utf8":"utf8"},this.setByAttrTypeAndValueStr=function(I,C,B){void 0!==B&&(this.sRule=B),this.sType=I,this.sValue=C},this.getValueObj=function(I,C){if("utf8"==I)return new b({str:C});if("prn"==I)return new E({str:C});if("tel"==I)return new M({str:C});if("ia5"==I)return new D({str:C});if("vis"==I)return new F({str:C});if("bmp"==I)return new P({str:C});throw new Error("unsupported directory string type: type="+I+" value="+C)},this.tohex=function(){null==this.dsType&&(this.dsType=this._getDsType());var I=w.asn1.x509.OID.atype2obj(this.sType),C=this.getValueObj(this.dsType,this.sValue),B=new _({array:[I,C]});return this.TLV=B.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.x509.AttributeTypeAndValue,w.asn1.ASN1Object),w.asn1.x509.SubjectPublicKeyInfo=function(l){w.asn1.x509.SubjectPublicKeyInfo.superclass.constructor.call(this);var b=w.asn1,E=b.DERInteger,M=b.DERBitString,D=b.DERObjectIdentifier,F=b.DERSequence,P=b.ASN1Util.newObject,z=b.x509.AlgorithmIdentifier;this.getASN1Object=function(){if(null==this.asn1AlgId||null==this.asn1SubjPKey)throw"algId and/or subjPubKey not set";return new F({array:[this.asn1AlgId,this.asn1SubjPKey]})},this.tohex=function(){var R=this.getASN1Object();return this.hTLV=R.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},this.setPubKey=function(R){try{if(R instanceof Ut){var L=P({seq:[{int:{bigint:R.n}},{int:{int:R.e}}]}).tohex();this.asn1AlgId=new z({name:"rsaEncryption"}),this.asn1SubjPKey=new M({hex:"00"+L})}}catch{}try{if(R instanceof w.crypto.ECDSA){var $=new D({name:R.curveName});this.asn1AlgId=new z({name:"ecPublicKey",asn1params:$}),this.asn1SubjPKey=new M({hex:"00"+R.pubKeyHex})}}catch{}try{if(R instanceof w.crypto.DSA){$=new P({seq:[{int:{bigint:R.p}},{int:{bigint:R.q}},{int:{bigint:R.g}}]}),this.asn1AlgId=new z({name:"dsa",asn1params:$});var J=new E({bigint:R.y});this.asn1SubjPKey=new M({hex:"00"+J.tohex()})}}catch{}},void 0!==l&&this.setPubKey(l)},He(w.asn1.x509.SubjectPublicKeyInfo,w.asn1.ASN1Object),w.asn1.x509.Time=function(l){w.asn1.x509.Time.superclass.constructor.call(this);var b=w.asn1,E=b.DERUTCTime,M=b.DERGeneralizedTime;this.params=null,this.type=null,this.setTimeParams=function(D){this.timeParams=D},this.setByParam=function(D){this.params=D},this.getType=function(D){return D.match(/^[0-9]{12}Z$/)?"utc":D.match(/^[0-9]{14}Z$/)?"gen":D.match(/^[0-9]{12}\.[0-9]+Z$/)?"utc":D.match(/^[0-9]{14}\.[0-9]+Z$/)?"gen":null},this.tohex=function(){var D=this.params,F=null;if("string"==typeof D&&(D={str:D}),null!=D&&D.str&&(null==D.type||null==D.type)&&(D.type=this.getType(D.str)),null!=D&&D.str?("utc"==D.type&&(F=new E(D.str)),"gen"==D.type&&(F=new M(D.str))):F="gen"==this.type?new M:new E,null==F)throw new Error("wrong setting for Time");return this.TLV=F.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},w.asn1.x509.Time_bak=function(l){w.asn1.x509.Time_bak.superclass.constructor.call(this);var b=w.asn1,E=b.DERUTCTime,M=b.DERGeneralizedTime;this.setTimeParams=function(D){this.timeParams=D},this.tohex=function(){var D=null;return D=null!=this.timeParams?"utc"==this.type?new E(this.timeParams):new M(this.timeParams):"utc"==this.type?new E:new M,this.TLV=D.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},this.type="utc",void 0!==l&&(void 0!==l.type?this.type=l.type:void 0!==l.str&&(l.str.match(/^[0-9]{12}Z$/)&&(this.type="utc"),l.str.match(/^[0-9]{14}Z$/)&&(this.type="gen")),this.timeParams=l)},He(w.asn1.x509.Time,w.asn1.ASN1Object),w.asn1.x509.AlgorithmIdentifier=function(l){w.asn1.x509.AlgorithmIdentifier.superclass.constructor.call(this),this.nameAlg=null,this.asn1Alg=null,this.asn1Params=null,this.paramEmpty=!1;var f=w.asn1,_=f.x509.AlgorithmIdentifier.PSSNAME2ASN1TLV;if(this.tohex=function(){if(null===this.nameAlg&&null===this.asn1Alg)throw new Error("algorithm not specified");if(null!==this.nameAlg){var E=null;for(var M in _)M===this.nameAlg&&(E=_[M]);if(null!==E)return this.hTLV=E,this.hTLV}null!==this.nameAlg&&null===this.asn1Alg&&(this.asn1Alg=f.x509.OID.name2obj(this.nameAlg));var D=[this.asn1Alg];null!==this.asn1Params&&D.push(this.asn1Params);var F=new f.DERSequence({array:D});return this.hTLV=F.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&(void 0!==l.name&&(this.nameAlg=l.name),void 0!==l.asn1params&&(this.asn1Params=l.asn1params),void 0!==l.paramempty&&(this.paramEmpty=l.paramempty)),null===this.asn1Params&&!1===this.paramEmpty&&null!==this.nameAlg){void 0!==this.nameAlg.name&&(this.nameAlg=this.nameAlg.name);var b=this.nameAlg.toLowerCase();"withdsa"!==b.substr(-7,7)&&"withecdsa"!==b.substr(-9,9)&&(this.asn1Params=new f.DERNull)}},He(w.asn1.x509.AlgorithmIdentifier,w.asn1.ASN1Object),w.asn1.x509.AlgorithmIdentifier.PSSNAME2ASN1TLV={SHAwithRSAandMGF1:"300d06092a864886f70d01010a3000",SHA256withRSAandMGF1:"303d06092a864886f70d01010a3030a00d300b0609608648016503040201a11a301806092a864886f70d010108300b0609608648016503040201a203020120",SHA384withRSAandMGF1:"303d06092a864886f70d01010a3030a00d300b0609608648016503040202a11a301806092a864886f70d010108300b0609608648016503040202a203020130",SHA512withRSAandMGF1:"303d06092a864886f70d01010a3030a00d300b0609608648016503040203a11a301806092a864886f70d010108300b0609608648016503040203a203020140"},w.asn1.x509.GeneralName=function(l){w.asn1.x509.GeneralName.superclass.constructor.call(this);var _=w.asn1,b=_.x509,E=b.X500Name,M=b.OtherName,D=_.DERIA5String,P=_.DEROctetString,U=_.DERTaggedObject,z=_.ASN1Object,I=Error;this.params=null,this.setByParam=function(C){this.params=C},this.tohex=function(){var B,R,C=this.params,V=!1;if(void 0!==C.other)B="a0",R=new M(C.other);else if(void 0!==C.rfc822)B="81",R=new D({str:C.rfc822});else if(void 0!==C.dns)B="82",R=new D({str:C.dns});else if(void 0!==C.dn)B="a4",V=!0,R="string"==typeof C.dn?new E({str:C.dn}):C.dn instanceof w.asn1.x509.X500Name?C.dn:new E(C.dn);else if(void 0!==C.ldapdn)B="a4",V=!0,R=new E({ldapstr:C.ldapdn});else if(void 0!==C.certissuer||void 0!==C.certsubj){B="a4",V=!0;var L,$,J=null;if(void 0!==C.certsubj?(L=!1,$=C.certsubj):(L=!0,$=C.certissuer),$.match(/^[0-9A-Fa-f]+$/),-1!=$.indexOf("-----BEGIN ")&&(J=ir($)),null==J)throw new Error("certsubj/certissuer not cert");var te,Q=new rn;Q.hex=J,te=L?Q.getIssuerHex():Q.getSubjectHex(),(R=new z).hTLV=te}else if(void 0!==C.uri)B="86",R=new D({str:C.uri});else{if(void 0===C.ip)throw new I("improper params");B="87";var Se,Ae=C.ip;try{if(Ae.match(/^[0-9a-f]+$/)){var j=Ae.length;if(8!=j&&16!=j&&32!=j&&64!=j)throw"err";Se=Ae}else Se=md(Ae)}catch(ee){throw new I("malformed IP address: "+C.ip+":"+ee.message)}R=new P({hex:Se})}return new U({tag:B,explicit:V,obj:R}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.x509.GeneralName,w.asn1.ASN1Object),w.asn1.x509.GeneralNames=function(l){w.asn1.x509.GeneralNames.superclass.constructor.call(this);var _=w.asn1;this.setByParamArray=function(b){for(var E=0;E"u")throw"Name of ObjectIdentifier not defined: "+h;var _=new l({oid:this.name2oidList[h]});return this.objCache[h]=_,_},this.atype2obj=function(h){if(void 0!==this.objCache[h])return this.objCache[h];var f;if(h.match(/^\d+\.\d+\.[0-9.]+$/))f=h;else if(void 0!==this.atype2oidList[h])f=this.atype2oidList[h];else{if(void 0===this.name2oidList[h])throw new Error("AttributeType name undefined: "+h);f=this.name2oidList[h]}var _=new l({oid:f});return this.objCache[h]=_,_},this.registerOIDs=function(h){if(this.checkOIDs(h))for(var f in h)this.name2oidList[f]=h[f]},this.checkOIDs=function(h){try{var f=Object.keys(h);return 0!=f.length&&(f.map(function(_,b,E){if(!this[_].match(/^[0-2]\.[0-9.]+$/))throw new Error("value is not OID")},h),!0)}catch{return!1}}},w.asn1.x509.OID.oid2name=function(l){var h=w.asn1.x509.OID.name2oidList;for(var f in h)if(h[f]==l)return f;return""},w.asn1.x509.OID.oid2atype=function(l){var h=w.asn1.x509.OID.atype2oidList;for(var f in h)if(h[f]==l)return f;return l},w.asn1.x509.OID.name2oid=function(l){if(l.match(/^[0-9.]+$/))return l;var h=w.asn1.x509.OID.name2oidList;return void 0===h[l]?"":h[l]},w.asn1.x509.X509Util={},w.asn1.x509.X509Util.newCertPEM=function(l){return new(0,w.asn1.x509.Certificate)(l).getPEM()},(typeof w>"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),(typeof w.asn1.cms>"u"||!w.asn1.cms)&&(w.asn1.cms={}),w.asn1.cms.Attribute=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.DERSet,M=_.DERObjectIdentifier;this.params=null,this.typeOid=null,this.setByParam=function(D){this.params=D},this.getValueArray=function(){throw new h("not yet implemented abstract")},this.tohex=function(){var D=new M({oid:this.typeOid}),F=new E({array:this.getValueArray()});return new b({array:[D,F]}).tohex()},this.getEncodedHex=function(){return this.tohex()}},He(w.asn1.cms.Attribute,w.asn1.ASN1Object),w.asn1.cms.ContentType=function(l){var f=w.asn1;f.cms.ContentType.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.3",this.getValueArray=function(){return[new f.DERObjectIdentifier(this.params.type)]},null!=l&&this.setByParam(l)},He(w.asn1.cms.ContentType,w.asn1.cms.Attribute),w.asn1.cms.MessageDigest=function(l){var f=w.asn1,_=f.DEROctetString;f.cms.MessageDigest.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.4",this.getValueArray=function(){return[new _(this.params)]},null!=l&&this.setByParam(l)},He(w.asn1.cms.MessageDigest,w.asn1.cms.Attribute),w.asn1.cms.SigningTime=function(l){var f=w.asn1;f.cms.SigningTime.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.5",this.getValueArray=function(){return[new f.x509.Time(this.params)]},null!=l&&this.setByParam(l)},He(w.asn1.cms.SigningTime,w.asn1.cms.Attribute),w.asn1.cms.SigningCertificate=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.cms,M=E.ESSCertID;E.SigningCertificate.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.12",this.getValueArray=function(){if(null==this.params||null==this.params||null==this.params.array)throw new h("parameter 'array' not specified");for(var F=this.params.array,P=[],U=0;U0){for(var B=E(I.valhex,C[0]),R=z(B,0),V=[],L=0;L1){var Q=E(I.valhex,C[1]);I.polhex=Q}delete I.valhex},this.setSignaturePolicyIdentifier=function(I){var C=z(I.valhex,0);if(C.length>0){var B=_.getOID(I.valhex,C[0]);I.oid=B}if(C.length>1){var R=new h,V=z(I.valhex,C[1]),L=E(I.valhex,V[0]),$=R.getAlgorithmIdentifierName(L);I.alg=$;var J=b(I.valhex,V[1]);I.hash=J}delete I.valhex},this.setSigningCertificateV2=function(I){var C=z(I.valhex,0);if(C.length>0){for(var B=E(I.valhex,C[0]),R=z(B,0),V=[],L=0;L1){var Q=E(I.valhex,C[1]);I.polhex=Q}delete I.valhex},this.getESSCertID=function(I){var C={},B=z(I,0);if(B.length>0){var R=b(I,B[0]);C.hash=R}if(B.length>1){var V=E(I,B[1]),L=this.getIssuerSerial(V);null!=L.serial&&(C.serial=L.serial),null!=L.issuer&&(C.issuer=L.issuer)}return C},this.getESSCertIDv2=function(I){var C={},B=z(I,0);if(B.length<1||3R+1){var $=E(I,B[R+1]),J=this.getIssuerSerial($);C.issuer=J.issuer,C.serial=J.serial}return C},this.getIssuerSerial=function(I){var C={},B=z(I,0),R=E(I,B[0]),V=f.getGeneralNames(R);C.issuer=V[0].dn;var $=b(I,B[1]);return C.serial={hex:$},C},this.getCertificateSet=function(I){for(var C=z(I,0),B=[],R=0;R"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),(typeof w.asn1.tsp>"u"||!w.asn1.tsp)&&(w.asn1.tsp={}),w.asn1.tsp.TimeStampToken=function(l){var _=w.asn1.tsp;_.TimeStampToken.superclass.constructor.call(this),this.params=null,this.getEncodedHexPrepare=function(){var b=new _.TSTInfo(this.params.econtent.content);this.params.econtent.content.hex=b.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.TimeStampToken,w.asn1.cms.SignedData),w.asn1.tsp.TSTInfo=function(l){Error;var _=w.asn1,b=_.DERSequence,E=_.DERInteger,M=_.DERBoolean,D=_.DERGeneralizedTime,F=_.DERObjectIdentifier,P=_.DERTaggedObject,U=_.tsp,z=U.MessageImprint,I=U.Accuracy,B=_.x509.GeneralName;if(U.TSTInfo.superclass.constructor.call(this),this.dVersion=new E({int:1}),this.dPolicy=null,this.dMessageImprint=null,this.dSerial=null,this.dGenTime=null,this.dAccuracy=null,this.dOrdering=null,this.dNonce=null,this.dTsa=null,this.tohex=function(){var R=[this.dVersion];if(null==this.dPolicy)throw new Error("policy shall be specified.");if(R.push(this.dPolicy),null==this.dMessageImprint)throw new Error("messageImprint shall be specified.");if(R.push(this.dMessageImprint),null==this.dSerial)throw new Error("serialNumber shall be specified.");if(R.push(this.dSerial),null==this.dGenTime)throw new Error("genTime shall be specified.");R.push(this.dGenTime),null!=this.dAccuracy&&R.push(this.dAccuracy),null!=this.dOrdering&&R.push(this.dOrdering),null!=this.dNonce&&R.push(this.dNonce),null!=this.dTsa&&R.push(this.dTsa);var V=new b({array:R});return this.hTLV=V.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==l){if("string"==typeof l.policy){if(!l.policy.match(/^[0-9.]+$/))throw"policy shall be oid like 0.1.4.134";this.dPolicy=new F({oid:l.policy})}void 0!==l.messageImprint&&(this.dMessageImprint=new z(l.messageImprint)),void 0!==l.serial&&(this.dSerial=new E(l.serial)),void 0!==l.genTime&&(this.dGenTime=new D(l.genTime)),void 0!==l.accuracy&&(this.dAccuracy=new I(l.accuracy)),void 0!==l.ordering&&1==l.ordering&&(this.dOrdering=new M),void 0!==l.nonce&&(this.dNonce=new E(l.nonce)),void 0!==l.tsa&&(this.dTsa=new P({tag:"a0",explicit:!0,obj:new B({dn:l.tsa})}))}},He(w.asn1.tsp.TSTInfo,w.asn1.ASN1Object),w.asn1.tsp.Accuracy=function(l){var f=w.asn1,_=f.ASN1Util.newObject;f.tsp.Accuracy.superclass.constructor.call(this),this.params=null,this.tohex=function(){var b=this.params,E=[];return null!=b.seconds&&"number"==typeof b.seconds&&E.push({int:b.seconds}),null!=b.millis&&"number"==typeof b.millis&&E.push({tag:{tagi:"80",obj:{int:b.millis}}}),null!=b.micros&&"number"==typeof b.micros&&E.push({tag:{tagi:"81",obj:{int:b.micros}}}),_({seq:E}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.Accuracy,w.asn1.ASN1Object),w.asn1.tsp.MessageImprint=function(l){var f=w.asn1,_=f.DERSequence,b=f.DEROctetString,M=f.x509.AlgorithmIdentifier;f.tsp.MessageImprint.superclass.constructor.call(this),this.params=null,this.tohex=function(){var D=this.params,F=new M({name:D.alg}),P=new b({hex:D.hash});return new _({array:[F,P]}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.tsp.MessageImprint,w.asn1.ASN1Object),w.asn1.tsp.TimeStampReq=function(l){var f=w.asn1,_=f.DERSequence,b=f.DERInteger,E=f.DERBoolean,D=f.DERObjectIdentifier,F=f.tsp,P=F.MessageImprint;F.TimeStampReq.superclass.constructor.call(this),this.params=null,this.tohex=function(){var U=this.params,z=[];return z.push(new b({int:1})),z.push(U.messageImprint instanceof w.asn1.ASN1Object?U.messageImprint:new P(U.messageImprint)),null!=U.policy&&z.push(new D(U.policy)),null!=U.nonce&&z.push(new b(U.nonce)),1==U.certreq&&z.push(new E),new _({array:z}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.TimeStampReq,w.asn1.ASN1Object),w.asn1.tsp.TimeStampResp=function(l){var f=w.asn1,_=f.DERSequence,E=f.tsp,M=E.PKIStatusInfo;E.TimeStampResp.superclass.constructor.call(this),this.params=null,this.tohex=function(){var D=this.params,F=[];if(null!=D.econtent||null!=D.tst)if(F.push(new M(null!=D.statusinfo?D.statusinfo:"granted")),null!=D.econtent)F.push(new E.TimeStampToken(D).getContentInfo());else{if(!(D.tst instanceof f.ASN1Object))throw new Error("improper member tst value");F.push(D.tst)}else{if(null==D.statusinfo)throw new Error("parameter for token nor statusinfo not specified");F.push(new M(D.statusinfo))}return new _({array:F}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.TimeStampResp,w.asn1.ASN1Object),w.asn1.tsp.PKIStatusInfo=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.tsp,M=E.PKIStatus,D=E.PKIFreeText,F=E.PKIFailureInfo;E.PKIStatusInfo.superclass.constructor.call(this),this.params=null,this.tohex=function(){var P=this.params,U=[];if("string"==typeof P)U.push(new M(P));else{if(null==P.status)throw new h("property 'status' unspecified");U.push(new M(P.status)),null!=P.statusstr&&U.push(new D(P.statusstr)),null!=P.failinfo&&U.push(new F(P.failinfo))}return new b({array:U}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.PKIStatusInfo,w.asn1.ASN1Object),w.asn1.tsp.PKIStatus=function(l){var h=Error,_=w.asn1,b=_.DERInteger;_.tsp.PKIStatus.superclass.constructor.call(this);var M={granted:0,grantedWithMods:1,rejection:2,waiting:3,revocationWarning:4,revocationNotification:5};this.params=null,this.tohex=function(){var P,D=this.params;if("string"==typeof D)try{P=M[D]}catch{throw new h("undefined name: "+D)}else{if("number"!=typeof D)throw new h("unsupported params");P=D}return new b({int:P}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.PKIStatus,w.asn1.ASN1Object),w.asn1.tsp.PKIFreeText=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.DERUTF8String;_.tsp.PKIFreeText.superclass.constructor.call(this),this.params=null,this.tohex=function(){var D=this.params;if(!D instanceof Array)throw new h("wrong params: not array");for(var F=[],P=0;P=0;I--)z+=U[I];return z}if("string"==typeof F&&null!=D[F])return vd([F],D);if("object"==typeof F&&null!=F.length)return vd(F,D);throw new h("wrong params")},this.tohex=function(){var P=this.getBinValue();return new b({bin:P}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.tsp.PKIFailureInfo,w.asn1.ASN1Object),w.asn1.tsp.AbstractTSAAdapter=function(l){this.getTSTHex=function(h,f){throw"not implemented yet"}},w.asn1.tsp.SimpleTSAAdapter=function(l){var _=w.asn1.tsp,b=w.crypto.Util.hashHex;_.SimpleTSAAdapter.superclass.constructor.call(this),this.params=null,this.serial=0,this.getTSTHex=function(E,M){var D=b(E,M);this.params.econtent.content.messageImprint={alg:M,hash:D},this.params.econtent.content.serial={int:this.serial++};var F=Math.floor(1e9*Math.random());return this.params.econtent.content.nonce={int:F},new _.TimeStampToken(this.params).getContentInfoEncodedHex()},void 0!==l&&(this.params=l)},He(w.asn1.tsp.SimpleTSAAdapter,w.asn1.tsp.AbstractTSAAdapter),w.asn1.tsp.FixedTSAAdapter=function(l){var _=w.asn1.tsp,b=w.crypto.Util.hashHex;_.FixedTSAAdapter.superclass.constructor.call(this),this.params=null,this.getTSTHex=function(E,M){var D=b(E,M);return this.params.econtent.content.messageImprint={alg:M,hash:D},new _.TimeStampToken(this.params).getContentInfoEncodedHex()},void 0!==l&&(this.params=l)},He(w.asn1.tsp.FixedTSAAdapter,w.asn1.tsp.AbstractTSAAdapter),w.asn1.tsp.TSPUtil=new function(){},w.asn1.tsp.TSPUtil.newTimeStampToken=function(l){return new w.asn1.tsp.TimeStampToken(l)},w.asn1.tsp.TSPUtil.parseTimeStampReq=function(l){return(new w.asn1.tsp.TSPParser).getTimeStampReq(l)},w.asn1.tsp.TSPUtil.parseMessageImprint=function(l){return(new w.asn1.tsp.TSPParser).getMessageImprint(l)},w.asn1.tsp.TSPParser=function(){Error;var f=new rn,_=rt,b=_.getV,E=_.getTLV,M=_.getIdxbyList,F=_.getChildIdx,P=["granted","grantedWithMods","rejection","waiting","revocationWarning","revocationNotification"],U={0:"badAlg",2:"badRequest",5:"badDataFormat",14:"timeNotAvailable",15:"unacceptedPolicy",16:"unacceptedExtension",17:"addInfoNotAvailable",25:"systemFailure"};this.getResponse=function(z){var I=F(z,0);if(1==I.length)return this.getPKIStatusInfo(E(z,I[0]));if(I.length>1){var C=this.getPKIStatusInfo(E(z,I[0])),B=E(z,I[1]),R=this.getToken(B);return R.statusinfo=C,R}},this.getToken=function(z){var C=(new w.asn1.cms.CMSParser).getCMSSignedData(z);return this.setTSTInfo(C),C},this.setTSTInfo=function(z){var I=z.econtent;if("tstinfo"==I.type){var B=this.getTSTInfo(I.content.hex);I.content=B}},this.getTSTInfo=function(z){var I={},C=F(z,0),B=b(z,C[1]);I.policy=vc(B);var R=E(z,C[2]);I.messageImprint=this.getMessageImprint(R);var V=b(z,C[3]);I.serial={hex:V};var L=b(z,C[4]);I.genTime={str:ei(L)};var $=0;if(C.length>5&&"30"==z.substr(C[5],2)){var J=E(z,C[5]);I.accuracy=this.getAccuracy(J),$++}if(C.length>5+$&&"01"==z.substr(C[5+$],2)&&("ff"==b(z,C[5+$])&&(I.ordering=!0),$++),C.length>5+$&&"02"==z.substr(C[5+$],2)){var te=b(z,C[5+$]);I.nonce={hex:te},$++}if(C.length>5+$&&"a0"==z.substr(C[5+$],2)){var Se=E(z,C[5+$]);Se="30"+Se.substr(2),pGeneralNames=f.getGeneralNames(Se);var Ae=pGeneralNames[0].dn;I.tsa=Ae,$++}if(C.length>5+$&&"a1"==z.substr(C[5+$],2)){var j=E(z,C[5+$]);j="30"+j.substr(2);var q=f.getExtParamArray(j);I.ext=q,$++}return I},this.getAccuracy=function(z){for(var I={},C=F(z,0),B=0;B1&&"30"==z.substr(C[1],2)){var L=E(z,C[1]);I.statusstr=this.getPKIFreeText(L),B++}if(C.length>B&&"03"==z.substr(C[1+B],2)){var $=E(z,C[1+B]);I.failinfo=this.getPKIFailureInfo($)}return I},this.getPKIFreeText=function(z){for(var I=[],C=F(z,0),B=0;B"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),(typeof w.asn1.cades>"u"||!w.asn1.cades)&&(w.asn1.cades={}),w.asn1.cades.SignaturePolicyIdentifier=function(l){var _=w.asn1.cades,b=_.SignaturePolicyId;_.SignaturePolicyIdentifier.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.15",this.params=null,this.getValueArray=function(){return[new b(this.params)]},this.setByParam=function(E){this.params=E},null!=l&&this.setByParam(l)},He(w.asn1.cades.SignaturePolicyIdentifier,w.asn1.cms.Attribute),w.asn1.cades.SignaturePolicyId=function(l){var f=w.asn1,_=f.DERSequence,b=f.DERObjectIdentifier,D=f.cades,P=D.OtherHashAlgAndValue;D.SignaturePolicyId.superclass.constructor.call(this),this.params=null,this.tohex=function(){var U=this.params,z=[];return z.push(new b(U.oid)),z.push(new P(U)),new _({array:z}).tohex()},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(U){this.params=U},null!=l&&this.setByParam(l)},He(w.asn1.cades.SignaturePolicyId,w.asn1.ASN1Object),w.asn1.cades.OtherHashAlgAndValue=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.DEROctetString,D=_.x509.AlgorithmIdentifier;_.cades.OtherHashAlgAndValue.superclass.constructor.call(this),this.params=null,this.tohex=function(){var U=this.params;if(null==U.alg)throw new h("property 'alg' not specified");if(null==U.hash&&null==U.cert)throw new h("property 'hash' nor 'cert' not specified");var z=null;if(null!=U.hash)z=U.hash;else if(null!=U.cert){if("string"!=typeof U.cert)throw new h("cert not string");var I=U.cert;-1!=U.cert.indexOf("-----BEGIN")&&(I=ir(U.cert)),z=w.crypto.Util.hashHex(I,U.alg)}var C=[];return C.push(new D({name:U.alg})),C.push(new E({hex:z})),new b({array:C}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.cades.OtherHashAlgAndValue,w.asn1.ASN1Object),w.asn1.cades.OtherHashValue=function(l){w.asn1.cades.OtherHashValue.superclass.constructor.call(this);var h=Error,E=w.asn1.DEROctetString;this.params=null,this.tohex=function(){var D=this.params;if(null==D.hash&&null==D.cert)throw new h("hash or cert not specified");var F=null;if(null!=D.hash)F=D.hash;else if(null!=D.cert){if("string"!=typeof D.cert)throw new h("cert not string");var P=D.cert;-1!=D.cert.indexOf("-----BEGIN")&&(P=ir(D.cert)),F=w.crypto.Util.hashHex(P,"sha1")}return new E({hex:F}).tohex()},this.getEncodedHex=function(){return this.tohex()},null!=l&&this.setByParam(l)},He(w.asn1.cades.OtherHashValue,w.asn1.ASN1Object),w.asn1.cades.SignatureTimeStamp=function(l){var h=Error,_=w.lang.String.isHex,b=w.asn1,E=b.ASN1Object;b.cades.SignatureTimeStamp.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.14",this.params=null,this.getValueArray=function(){var F=this.params;if(null!=F.tst){if(_(F.tst))return(P=new E).hTLV=F.tst,[P];if(F.tst instanceof E)return[F.tst];throw new h("params.tst has wrong value")}if(null!=F.res){var P,U=F.res;if(U instanceof E&&(U=U.tohex()),"string"!=typeof U||!_(U))throw new h("params.res has wrong value");return rt.getTLVbyList(U,0,[1]),(P=new E).hTLV=F.tst,[P]}},null!=l&&this.setByParam(l)},He(w.asn1.cades.SignatureTimeStamp,w.asn1.cms.Attribute),w.asn1.cades.CompleteCertificateRefs=function(l){var h=Error,_=w.asn1,b=_.DERSequence,E=_.cades,M=E.OtherCertID,D=w.lang.String.isHex;E.CompleteCertificateRefs.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.21",this.params=null,this.getValueArray=function(){for(var F=this.params,P=[],U=0;U"u"||!w.asn1.csr)&&(w.asn1.csr={}),w.asn1.csr.CertificationRequest=function(l){var f=w.asn1,_=f.DERBitString,b=f.DERSequence,E=f.csr,D=E.CertificationRequestInfo;E.CertificationRequest.superclass.constructor.call(this),this.setByParam=function(F){this.params=F},this.sign=function(){var F=new D(this.params).tohex(),P=new w.crypto.Signature({alg:this.params.sigalg});P.init(this.params.sbjprvkey),P.updateHex(F);var U=P.sign();this.params.sighex=U},this.getPEM=function(){return Fr(this.tohex(),"CERTIFICATE REQUEST")},this.tohex=function(){var F=this.params,P=new w.asn1.csr.CertificationRequestInfo(this.params),U=new w.asn1.x509.AlgorithmIdentifier({name:F.sigalg});if(null==F.sighex&&null!=F.sbjprvkey&&this.sign(),null==F.sighex)throw new Error("sighex or sbjprvkey parameter not defined");var z=new _({hex:"00"+F.sighex});return new b({array:[P,U,z]}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.csr.CertificationRequest,w.asn1.ASN1Object),w.asn1.csr.CertificationRequestInfo=function(l){var f=w.asn1,b=f.DERSequence,E=f.DERInteger,M=f.DERUTF8String,D=f.DERTaggedObject,F=f.ASN1Util.newObject,U=f.x509,z=U.X500Name,I=U.Extensions,C=U.SubjectPublicKeyInfo;f.csr.CertificationRequestInfo.superclass.constructor.call(this),this.params=null,this.setByParam=function(V){null!=V&&(this.params=V)},this.tohex=function(){var V=this.params,L=[];if(L.push(new E({int:0})),L.push(new z(V.subject)),L.push(new C(Zt.getKey(V.sbjpubkey))),null!=V.attrs){var $=function R(V){for(var L=Error,$=w.asn1.x509.Extensions,J=[],Q=0;Q"u"||!w)&&(w={}),(typeof w.asn1>"u"||!w.asn1)&&(w.asn1={}),(typeof w.asn1.ocsp>"u"||!w.asn1.ocsp)&&(w.asn1.ocsp={}),w.asn1.ocsp.DEFAULT_HASH="sha1",w.asn1.ocsp.OCSPResponse=function(l){w.asn1.ocsp.OCSPResponse.superclass.constructor.call(this);var f=w.asn1.ASN1Util.newObject,_=w.asn1.ocsp.ResponseBytes,b=["successful","malformedRequest","internalError","tryLater","_not_used_","sigRequired","unauthorized"];this.params=null,this._getStatusCode=function(){var E=this.params.resstatus;return"number"==typeof E?E:"string"!=typeof E?-1:b.indexOf(E)},this.setByParam=function(E){this.params=E},this.tohex=function(){var E=this.params,M=this._getStatusCode();if(-1==M)throw new Error("responseStatus not supported: "+E.resstatus);if(0!=M)return f({seq:[{enum:{int:M}}]}).tohex();var D=new _(E);return f({seq:[{enum:{int:0}},{tag:{tag:"a0",explicit:!0,obj:D}}]}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.ocsp.OCSPResponse,w.asn1.ASN1Object),w.asn1.ocsp.ResponseBytes=function(l){w.asn1.ocsp.ResponseBytes.superclass.constructor.call(this);var h=w.asn1,f=h.DERSequence,_=h.DERObjectIdentifier,b=h.DEROctetString,E=h.ocsp.BasicOCSPResponse;this.params=null,this.setByParam=function(M){this.params=M},this.tohex=function(){var M=this.params;if("ocspBasic"!=M.restype)throw new Error("not supported responseType: "+M.restype);var D=new E(M),F=[];return F.push(new _({name:"ocspBasic"})),F.push(new b({hex:D.tohex()})),new f({array:F}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==l&&this.setByParam(l)},He(w.asn1.ocsp.ResponseBytes,w.asn1.ASN1Object),w.asn1.ocsp.BasicOCSPResponse=function(l){w.asn1.ocsp.BasicOCSPResponse.superclass.constructor.call(this);var h=Error,f=w.asn1,_=f.ASN1Object,b=f.DERSequence,M=f.DERTaggedObject,D=f.DERBitString,P=f.x509.AlgorithmIdentifier,U=f.ocsp;_SingleResponseList=U.SingleResponseList,_ResponseData=U.ResponseData,this.params=null,this.setByParam=function(I){this.params=I},this.sign=function(){var I=this.params,C=I.tbsresp.tohex(),B=new w.crypto.Signature({alg:I.sigalg});B.init(I.reskey),B.updateHex(C),I.sighex=B.sign()},this.tohex=function(){var I=this.params;null==I.tbsresp&&(I.tbsresp=new _ResponseData(I)),null==I.sighex&&null!=I.reskey&&this.sign();var C=[];if(C.push(I.tbsresp),C.push(new P({name:I.sigalg})),C.push(new D({hex:"00"+I.sighex})),null!=I.certs&&null!=I.certs.length){for(var B=[],R=0;R"u"||!w)&&(w={}),(typeof w.lang>"u"||!w.lang)&&(w.lang={}),w.lang.String=function(){},"function"==typeof Buffer?(Il=function(l){return Qr(Buffer.from(l,"utf8").toString("base64"))},mo=function(l){return Buffer.from(ma(l),"base64").toString("utf8")}):(Il=function(l){return Er(_o(Fe(l)))},mo=function(l){return decodeURIComponent(Xh(nn(l)))}),w.lang.String.isInteger=function(l){return!!l.match(/^[0-9]+$/)||!!l.match(/^-[0-9]+$/)},w.lang.String.isHex=function(l){return qn(l)},w.lang.String.isBase64=function(l){return!(!(l=l.replace(/\s+/g,"")).match(/^[0-9A-Za-z+\/]+={0,3}$/)||l.length%4!=0)},w.lang.String.isBase64URL=function(l){return!l.match(/[+/=]/)&&(l=ma(l),w.lang.String.isBase64(l))},w.lang.String.isIntegerArray=function(l){return!!(l=l.replace(/\s+/g,"")).match(/^\[[0-9,]+\]$/)},w.lang.String.isPrintable=function(l){return null!==l.match(/^[0-9A-Za-z '()+,-./:=?]*$/)},w.lang.String.isIA5=function(l){return null!==l.match(/^[\x20-\x21\x23-\x7f]*$/)},w.lang.String.isMail=function(l){return null!==l.match(/^[A-Za-z0-9]{1}[A-Za-z0-9_.-]*@{1}[A-Za-z0-9_.-]{1,}\.[A-Za-z0-9]{1,}$/)};var gd=function(l,h,f){return null==f&&(f="0"),l.length>=h?l:new Array(h-l.length+1).join(f)+l};function vd(l,h){for(var f=0,_=0;_=0;_--)E+=b[_];return E}function He(l,h){var f=function(){};f.prototype=h.prototype,l.prototype=new f,l.prototype.constructor=l,l.superclass=h.prototype,h.prototype.constructor==Object.prototype.constructor&&(h.prototype.constructor=h)}(typeof w>"u"||!w)&&(w={}),(typeof w.crypto>"u"||!w.crypto)&&(w.crypto={}),w.crypto.Util=new function(){this.DIGESTINFOHEAD={sha1:"3021300906052b0e03021a05000414",sha224:"302d300d06096086480165030402040500041c",sha256:"3031300d060960864801650304020105000420",sha384:"3041300d060960864801650304020205000430",sha512:"3051300d060960864801650304020305000440",md2:"3020300c06082a864886f70d020205000410",md5:"3020300c06082a864886f70d020505000410",ripemd160:"3021300906052b2403020105000414"},this.DEFAULTPROVIDER={md5:"cryptojs",sha1:"cryptojs",sha224:"cryptojs",sha256:"cryptojs",sha384:"cryptojs",sha512:"cryptojs",ripemd160:"cryptojs",hmacmd5:"cryptojs",hmacsha1:"cryptojs",hmacsha224:"cryptojs",hmacsha256:"cryptojs",hmacsha384:"cryptojs",hmacsha512:"cryptojs",hmacripemd160:"cryptojs",MD5withRSA:"cryptojs/jsrsa",SHA1withRSA:"cryptojs/jsrsa",SHA224withRSA:"cryptojs/jsrsa",SHA256withRSA:"cryptojs/jsrsa",SHA384withRSA:"cryptojs/jsrsa",SHA512withRSA:"cryptojs/jsrsa",RIPEMD160withRSA:"cryptojs/jsrsa",MD5withECDSA:"cryptojs/jsrsa",SHA1withECDSA:"cryptojs/jsrsa",SHA224withECDSA:"cryptojs/jsrsa",SHA256withECDSA:"cryptojs/jsrsa",SHA384withECDSA:"cryptojs/jsrsa",SHA512withECDSA:"cryptojs/jsrsa",RIPEMD160withECDSA:"cryptojs/jsrsa",SHA1withDSA:"cryptojs/jsrsa",SHA224withDSA:"cryptojs/jsrsa",SHA256withDSA:"cryptojs/jsrsa",MD5withRSAandMGF1:"cryptojs/jsrsa",SHAwithRSAandMGF1:"cryptojs/jsrsa",SHA1withRSAandMGF1:"cryptojs/jsrsa",SHA224withRSAandMGF1:"cryptojs/jsrsa",SHA256withRSAandMGF1:"cryptojs/jsrsa",SHA384withRSAandMGF1:"cryptojs/jsrsa",SHA512withRSAandMGF1:"cryptojs/jsrsa",RIPEMD160withRSAandMGF1:"cryptojs/jsrsa"},this.CRYPTOJSMESSAGEDIGESTNAME={md5:pt.algo.MD5,sha1:pt.algo.SHA1,sha224:pt.algo.SHA224,sha256:pt.algo.SHA256,sha384:pt.algo.SHA384,sha512:pt.algo.SHA512,ripemd160:pt.algo.RIPEMD160},this.getDigestInfoHex=function(l,h){if(typeof this.DIGESTINFOHEAD[h]>"u")throw"alg not supported in Util.DIGESTINFOHEAD: "+h;return this.DIGESTINFOHEAD[h]+l},this.getPaddedDigestInfoHex=function(l,h,f){var _=this.getDigestInfoHex(l,h),b=f/4;if(_.length+22>b)throw"key is too short for SigAlg: keylen="+f+","+h;for(var E="0001",M="00"+_,D="",F=b-E.length-M.length,P=0;P"u"||!w)&&(w={}),(typeof w.crypto>"u"||!w.crypto)&&(w.crypto={}),w.crypto.ECDSA=function(l){var E=Error,M=_e,D=Mt,F=w.crypto.ECDSA,P=w.crypto.ECParameterDB,U=F.getName,I=rt.getVbyListEx,C=rt.isASN1HEX,B=new Ao;this.type="EC",this.isPrivate=!1,this.isPublic=!1,this.getBigRandom=function(L){return new M(L.bitLength(),B).mod(L.subtract(M.ONE)).add(M.ONE)},this.setNamedCurve=function(L){this.ecparams=P.getByName(L),this.prvKeyHex=null,this.pubKeyHex=null,this.curveName=L},this.setPrivateKeyHex=function(L){this.isPrivate=!0,this.prvKeyHex=L},this.setPublicKeyHex=function(L){this.isPublic=!0,this.pubKeyHex=L},this.getPublicKeyXYHex=function(){var L=this.pubKeyHex;if("04"!==L.substr(0,2))throw"this method supports uncompressed format(04) only";var $=this.ecparams.keycharlen;if(L.length!==2+2*$)throw"malformed public key hex length";var J={};return J.x=L.substr(2,$),J.y=L.substr(2+$),J},this.getShortNISTPCurveName=function(){var L=this.curveName;return"secp256r1"===L||"NIST P-256"===L||"P-256"===L||"prime256v1"===L?"P-256":"secp384r1"===L||"NIST P-384"===L||"P-384"===L?"P-384":"secp521r1"===L||"NIST P-521"===L||"P-521"===L?"P-521":null},this.generateKeyPairHex=function(){var $=this.getBigRandom(this.ecparams.n),J=this.ecparams.keycharlen,Q=("0000000000"+$.toString(16)).slice(-J);return this.setPrivateKeyHex(Q),{ecprvhex:Q,ecpubhex:this.generatePublicKeyHex()}},this.generatePublicKeyHex=function(){var L=new M(this.prvKeyHex,16),$=this.ecparams.G.multiply(L),J=$.getX().toBigInteger(),Q=$.getY().toBigInteger(),te=this.ecparams.keycharlen,j="04"+("0000000000"+J.toString(16)).slice(-te)+("0000000000"+Q.toString(16)).slice(-te);return this.setPublicKeyHex(j),j},this.signWithMessageHash=function(L){return this.signHex(L,this.prvKeyHex)},this.signHex=function(L,$){var J=new M($,16),Q=this.ecparams.n,te=new M(L.substring(0,this.ecparams.keycharlen),16);do{var Se=this.getBigRandom(Q),q=this.ecparams.G.multiply(Se).getX().toBigInteger().mod(Q)}while(q.compareTo(M.ZERO)<=0);var ee=Se.modInverse(Q).multiply(te.add(J.multiply(q))).mod(Q);return F.biRSSigToASN1Sig(q,ee)},this.sign=function(L,$){var J=$,Q=this.ecparams.n,te=M.fromByteArrayUnsigned(L);do{var Se=this.getBigRandom(Q),q=this.ecparams.G.multiply(Se).getX().toBigInteger().mod(Q)}while(q.compareTo(_e.ZERO)<=0);var ee=Se.modInverse(Q).multiply(te.add(J.multiply(q))).mod(Q);return this.serializeSig(q,ee)},this.verifyWithMessageHash=function(L,$){return this.verifyHex(L,$,this.pubKeyHex)},this.verifyHex=function(L,$,J){try{var Q,te,Se=F.parseSigHex($);Q=Se.r,te=Se.s;var Ae=D.decodeFromHex(this.ecparams.curve,J),j=new M(L.substring(0,this.ecparams.keycharlen),16);return this.verifyRaw(j,Q,te,Ae)}catch{return!1}},this.verify=function(L,$,J){var Q,te,Ae;if(Bitcoin.Util.isArray($)){var Se=this.parseSig($);Q=Se.r,te=Se.s}else{if("object"!=typeof $||!$.r||!$.s)throw"Invalid value for signature";Q=$.r,te=$.s}if(J instanceof Mt)Ae=J;else{if(!Bitcoin.Util.isArray(J))throw"Invalid format for pubkey value, must be byte array or ECPointFp";Ae=D.decodeFrom(this.ecparams.curve,J)}var j=M.fromByteArrayUnsigned(L);return this.verifyRaw(j,Q,te,Ae)},this.verifyRaw=function(L,$,J,Q){var te=this.ecparams.n,Se=this.ecparams.G;if($.compareTo(M.ONE)<0||$.compareTo(te)>=0||J.compareTo(M.ONE)<0||J.compareTo(te)>=0)return!1;var Ae=J.modInverse(te),j=L.multiply(Ae).mod(te),q=$.multiply(Ae).mod(te);return Se.multiply(j).add(Q.multiply(q)).getX().toBigInteger().mod(te).equals($)},this.serializeSig=function(L,$){var J=L.toByteArraySigned(),Q=$.toByteArraySigned(),te=[];return te.push(2),te.push(J.length),(te=te.concat(J)).push(2),te.push(Q.length),(te=te.concat(Q)).unshift(te.length),te.unshift(48),te},this.parseSig=function(L){var $;if(48!=L[0])throw new Error("Signature not a valid DERSequence");if(2!=L[$=2])throw new Error("First element in signature must be a DERInteger");var J=L.slice($+2,$+2+L[$+1]);if(2!=L[$+=2+L[$+1]])throw new Error("Second element in signature must be a DERInteger");var Q=L.slice($+2,$+2+L[$+1]);return $+=2+L[$+1],{r:M.fromByteArrayUnsigned(J),s:M.fromByteArrayUnsigned(Q)}},this.parseSigCompact=function(L){if(65!==L.length)throw"Signature has the wrong length";var $=L[0]-27;if($<0||$>7)throw"Invalid signature type";var J=this.ecparams.n;return{r:M.fromByteArrayUnsigned(L.slice(1,33)).mod(J),s:M.fromByteArrayUnsigned(L.slice(33,65)).mod(J),i:$}},this.readPKCS5PrvKeyHex=function(L){if(!1===C(L))throw new Error("not ASN.1 hex string");var $,J,Q;try{$=I(L,0,["[0]",0],"06"),J=I(L,0,[1],"04");try{Q=I(L,0,["[1]",0],"03")}catch{}}catch{throw new Error("malformed PKCS#1/5 plain ECC private key")}if(this.curveName=U($),void 0===this.curveName)throw"unsupported curve name";this.setNamedCurve(this.curveName),this.setPublicKeyHex(Q),this.setPrivateKeyHex(J),this.isPublic=!1},this.readPKCS8PrvKeyHex=function(L){if(!1===C(L))throw new E("not ASN.1 hex string");var J,Q,te;try{I(L,0,[1,0],"06"),J=I(L,0,[1,1],"06"),Q=I(L,0,[2,0,1],"04");try{te=I(L,0,[2,0,"[1]",0],"03")}catch{}}catch{throw new E("malformed PKCS#8 plain ECC private key")}if(this.curveName=U(J),void 0===this.curveName)throw new E("unsupported curve name");this.setNamedCurve(this.curveName),this.setPublicKeyHex(te),this.setPrivateKeyHex(Q),this.isPublic=!1},this.readPKCS8PubKeyHex=function(L){if(!1===C(L))throw new E("not ASN.1 hex string");var J,Q;try{I(L,0,[0,0],"06"),J=I(L,0,[0,1],"06"),Q=I(L,0,[1],"03")}catch{throw new E("malformed PKCS#8 ECC public key")}if(this.curveName=U(J),null===this.curveName)throw new E("unsupported curve name");this.setNamedCurve(this.curveName),this.setPublicKeyHex(Q)},this.readCertPubKeyHex=function(L,$){if(!1===C(L))throw new E("not ASN.1 hex string");var J,Q;try{J=I(L,0,[0,5,0,1],"06"),Q=I(L,0,[0,5,1],"03")}catch{throw new E("malformed X.509 certificate ECC public key")}if(this.curveName=U(J),null===this.curveName)throw new E("unsupported curve name");this.setNamedCurve(this.curveName),this.setPublicKeyHex(Q)},void 0!==l&&void 0!==l.curve&&(this.curveName=l.curve),void 0===this.curveName&&(this.curveName="secp256r1"),this.setNamedCurve(this.curveName),void 0!==l&&(void 0!==l.prv&&this.setPrivateKeyHex(l.prv),void 0!==l.pub&&this.setPublicKeyHex(l.pub))},w.crypto.ECDSA.parseSigHex=function(l){var h=w.crypto.ECDSA.parseSigHexInHexRS(l);return{r:new _e(h.r,16),s:new _e(h.s,16)}},w.crypto.ECDSA.parseSigHexInHexRS=function(l){var f=rt.getChildIdx,_=rt.getV;if(rt.checkStrictDER(l,0),"30"!=l.substr(0,2))throw new Error("signature is not a ASN.1 sequence");var b=f(l,0);if(2!=b.length)throw new Error("signature shall have two elements");var E=b[0],M=b[1];if("02"!=l.substr(E,2))throw new Error("1st item not ASN.1 integer");if("02"!=l.substr(M,2))throw new Error("2nd item not ASN.1 integer");return{r:_(l,E),s:_(l,M)}},w.crypto.ECDSA.asn1SigToConcatSig=function(l){var h=w.crypto.ECDSA.parseSigHexInHexRS(l),f=h.r,_=h.s;if(f.length>=130&&f.length<=134){if(f.length%2!=0)throw Error("unknown ECDSA sig r length error");if(_.length%2!=0)throw Error("unknown ECDSA sig s length error");"00"==f.substr(0,2)&&(f=f.substr(2)),"00"==_.substr(0,2)&&(_=_.substr(2));var b=Math.max(f.length,_.length);return(f=("000000"+f).slice(-b))+("000000"+_).slice(-b)}if("00"==f.substr(0,2)&&f.length%32==2&&(f=f.substr(2)),"00"==_.substr(0,2)&&_.length%32==2&&(_=_.substr(2)),f.length%32==30&&(f="00"+f),_.length%32==30&&(_="00"+_),f.length%32!=0)throw Error("unknown ECDSA sig r length error");if(_.length%32!=0)throw Error("unknown ECDSA sig s length error");return f+_},w.crypto.ECDSA.concatSigToASN1Sig=function(l){if(l.length%4!=0)throw Error("unknown ECDSA concatinated r-s sig length error");var h=l.substr(0,l.length/2),f=l.substr(l.length/2);return w.crypto.ECDSA.hexRSSigToASN1Sig(h,f)},w.crypto.ECDSA.hexRSSigToASN1Sig=function(l,h){var f=new _e(l,16),_=new _e(h,16);return w.crypto.ECDSA.biRSSigToASN1Sig(f,_)},w.crypto.ECDSA.biRSSigToASN1Sig=function(l,h){var f=w.asn1,_=new f.DERInteger({bigint:l}),b=new f.DERInteger({bigint:h});return new f.DERSequence({array:[_,b]}).tohex()},w.crypto.ECDSA.getName=function(l){return"2b8104001f"===l?"secp192k1":"2a8648ce3d030107"===l?"secp256r1":"2b8104000a"===l?"secp256k1":"2b81040021"===l?"secp224r1":"2b81040022"===l?"secp384r1":"2b81040023"===l?"secp521r1":-1!=="|secp256r1|NIST P-256|P-256|prime256v1|".indexOf(l)?"secp256r1":-1!=="|secp256k1|".indexOf(l)?"secp256k1":-1!=="|secp224r1|NIST P-224|P-224|".indexOf(l)?"secp224r1":-1!=="|secp384r1|NIST P-384|P-384|".indexOf(l)?"secp384r1":-1!=="|secp521r1|NIST P-521|P-521|".indexOf(l)?"secp521r1":null},(typeof w>"u"||!w)&&(w={}),(typeof w.crypto>"u"||!w.crypto)&&(w.crypto={}),w.crypto.ECParameterDB=new function(){var l={},h={};function f(_){return new _e(_,16)}this.getByName=function(_){var b=_;if(typeof h[b]<"u"&&(b=h[_]),typeof l[b]<"u")return l[b];throw"unregistered EC curve name: "+b},this.regist=function(_,b,E,M,D,F,P,U,z,I,C,B){l[_]={};var R=f(E),V=f(M),L=f(D),$=f(F),J=f(P),Q=new Nr(R,V,L),te=Q.decodePointHex("04"+U+z);l[_].name=_,l[_].keylen=b,l[_].keycharlen=2*Math.ceil(b/8),l[_].curve=Q,l[_].G=te,l[_].n=$,l[_].h=J,l[_].oid=C,l[_].info=B;for(var Se=0;Se"u"||!w)&&(w={}),(typeof w.crypto>"u"||!w.crypto)&&(w.crypto={}),w.crypto.DSA=function(){var f=rt.getVbyListEx,_=rt.isASN1HEX,b=_e;this.p=null,this.q=null,this.g=null,this.y=null,this.x=null,this.type="DSA",this.isPrivate=!1,this.isPublic=!1,this.setPrivate=function(E,M,D,F,P){this.isPrivate=!0,this.p=E,this.q=M,this.g=D,this.y=F,this.x=P},this.setPrivateHex=function(E,M,D,F,P){var U,z,I,C,B;U=new _e(E,16),z=new _e(M,16),I=new _e(D,16),C="string"==typeof F&&F.length>1?new _e(F,16):null,B=new _e(P,16),this.setPrivate(U,z,I,C,B)},this.setPublic=function(E,M,D,F){this.isPublic=!0,this.p=E,this.q=M,this.g=D,this.y=F,this.x=null},this.setPublicHex=function(E,M,D,F){var P,U,z,I;P=new _e(E,16),U=new _e(M,16),z=new _e(D,16),I=new _e(F,16),this.setPublic(P,U,z,I)},this.signWithMessageHash=function(E){var M=this.p,D=this.q,F=this.g,U=this.x,z=w.crypto.Util.getRandomBigIntegerMinToMax(_e.ONE.add(_e.ONE),D.subtract(_e.ONE)),C=new _e(E.substr(0,D.bitLength()/4),16),B=F.modPow(z,M).mod(D),R=z.modInverse(D).multiply(C.add(U.multiply(B))).mod(D);return w.asn1.ASN1Util.jsonToASN1HEX({seq:[{int:{bigint:B}},{int:{bigint:R}}]})},this.verifyWithMessageHash=function(E,M){var D=this.p,F=this.q,P=this.g,U=this.y,z=this.parseASN1Signature(M),I=z[0],C=z[1],R=new _e(E.substr(0,F.bitLength()/4),16);if(_e.ZERO.compareTo(I)>0||I.compareTo(F)>0||_e.ZERO.compareTo(C)>=0||C.compareTo(F)>0)throw"invalid DSA signature";var V=C.modInverse(F),L=R.multiply(V).mod(F),$=I.multiply(V).mod(F);return 0==P.modPow(L,D).multiply(U.modPow($,D)).mod(D).mod(F).compareTo(I)},this.parseASN1Signature=function(E){try{return[new b(f(E,0,[0],"02"),16),new b(f(E,0,[1],"02"),16)]}catch{throw new Error("malformed ASN.1 DSA signature")}},this.readPKCS5PrvKeyHex=function(E){var M,D,F,P,U;if(!1===_(E))throw new Error("not ASN.1 hex string");try{M=f(E,0,[1],"02"),D=f(E,0,[2],"02"),F=f(E,0,[3],"02"),P=f(E,0,[4],"02"),U=f(E,0,[5],"02")}catch{throw new Error("malformed PKCS#1/5 plain DSA private key")}this.setPrivateHex(M,D,F,P,U)},this.readPKCS8PrvKeyHex=function(E){var M,D,F,P;if(!1===_(E))throw new Error("not ASN.1 hex string");try{M=f(E,0,[1,1,0],"02"),D=f(E,0,[1,1,1],"02"),F=f(E,0,[1,1,2],"02"),P=f(E,0,[2,0],"02")}catch{throw new Error("malformed PKCS#8 plain DSA private key")}this.setPrivateHex(M,D,F,null,P)},this.readPKCS8PubKeyHex=function(E){var M,D,F,P;if(!1===_(E))throw new Error("not ASN.1 hex string");try{M=f(E,0,[0,1,0],"02"),D=f(E,0,[0,1,1],"02"),F=f(E,0,[0,1,2],"02"),P=f(E,0,[1,0],"02")}catch{throw new Error("malformed PKCS#8 DSA public key")}this.setPublicHex(M,D,F,P)},this.readCertPubKeyHex=function(E,M){var D,F,P,U;if(!1===_(E))throw new Error("not ASN.1 hex string");try{D=f(E,0,[0,5,0,1,0],"02"),F=f(E,0,[0,5,0,1,1],"02"),P=f(E,0,[0,5,0,1,2],"02"),U=f(E,0,[0,5,1,0],"02")}catch{throw new Error("malformed X.509 certificate DSA public key")}this.setPublicHex(D,F,P,U)}};var Zt=function(){var l=function(R,V,L){return _(pt.AES,R,V,L)},_=function(R,V,L,$){var J=pt.enc.Hex.parse(V),Q=pt.enc.Hex.parse(L),te=pt.enc.Hex.parse($),Se={};Se.key=Q,Se.iv=te,Se.ciphertext=J;var Ae=R.decrypt(Se,Q,{iv:te});return pt.enc.Hex.stringify(Ae)},b=function(R,V,L){return D(pt.AES,R,V,L)},D=function(R,V,L,$){var J=pt.enc.Hex.parse(V),Q=pt.enc.Hex.parse(L),te=pt.enc.Hex.parse($),Se=R.encrypt(J,Q,{iv:te}),Ae=pt.enc.Hex.parse(Se.toString());return pt.enc.Base64.stringify(Ae)},F={"AES-256-CBC":{proc:l,eproc:b,keylen:32,ivlen:16},"AES-192-CBC":{proc:l,eproc:b,keylen:24,ivlen:16},"AES-128-CBC":{proc:l,eproc:b,keylen:16,ivlen:16},"DES-EDE3-CBC":{proc:function(R,V,L){return _(pt.TripleDES,R,V,L)},eproc:function(R,V,L){return D(pt.TripleDES,R,V,L)},keylen:24,ivlen:8},"DES-CBC":{proc:function(R,V,L){return _(pt.DES,R,V,L)},eproc:function(R,V,L){return D(pt.DES,R,V,L)},keylen:8,ivlen:8}},z=function(R){var V={},L=R.match(new RegExp("DEK-Info: ([^,]+),([0-9A-Fa-f]+)","m"));L&&(V.cipher=L[1],V.ivsalt=L[2]);var $=R.match(new RegExp("-----BEGIN ([A-Z]+) PRIVATE KEY-----"));$&&(V.type=$[1]);var J=-1,Q=0;-1!=R.indexOf("\r\n\r\n")&&(J=R.indexOf("\r\n\r\n"),Q=2),-1!=R.indexOf("\n\n")&&(J=R.indexOf("\n\n"),Q=1);var te=R.indexOf("-----END");if(-1!=J&&-1!=te){var Se=R.substring(J+2*Q,te-Q);Se=Se.replace(/\s+/g,""),V.data=Se}return V},I=function(R,V,L){for(var $=L.substring(0,16),J=pt.enc.Hex.parse($),Q=pt.enc.Utf8.parse(V),te=F[R].keylen+F[R].ivlen,Se="",Ae=null;;){var j=pt.algo.MD5.create();if(null!=Ae&&j.update(Ae),j.update(Q),j.update(J),Ae=j.finalize(),(Se+=pt.enc.Hex.stringify(Ae)).length>=2*te)break}var q={};return q.keyhex=Se.substr(0,2*F[R].keylen),q.ivhex=Se.substr(2*F[R].keylen,2*F[R].ivlen),q},C=function(R,V,L,$){var J=pt.enc.Base64.parse(R),Q=pt.enc.Hex.stringify(J);return(0,F[V].proc)(Q,L,$)};return{version:"1.0.0",parsePKCS5PEM:function(R){return z(R)},getKeyAndUnusedIvByPasscodeAndIvsalt:function(R,V,L){return I(R,V,L)},decryptKeyB64:function(R,V,L,$){return C(R,V,L,$)},getDecryptedKeyHex:function(R,V){var L=z(R),J=L.cipher,Q=L.ivsalt,te=L.data,Se=I(J,V,Q);return C(te,J,Se.keyhex,Q)},getEncryptedPKCS5PEMFromPrvKeyHex:function(R,V,L,$,J){var ee="";if((typeof $>"u"||null==$)&&($="AES-256-CBC"),typeof F[$]>"u")throw new Error("KEYUTIL unsupported algorithm: "+$);if(typeof J>"u"||null==J){var te=function(R){var V=pt.lib.WordArray.random(R);return pt.enc.Hex.stringify(V)}(F[$].ivlen);J=te.toUpperCase()}var j=function(R,V,L,$){return(0,F[V].eproc)(R,L,$)}(V,$,I($,L,J).keyhex,J);return ee="-----BEGIN "+R+" PRIVATE KEY-----\r\n",ee+="Proc-Type: 4,ENCRYPTED\r\n",ee+="DEK-Info: "+$+","+J+"\r\n",ee+="\r\n",(ee+=j.replace(/(.{64})/g,"$1\r\n"))+"\r\n-----END "+R+" PRIVATE KEY-----\r\n"},parseHexOfEncryptedPKCS8:function(R){var L=rt.getChildIdx,$=rt.getV,J={},Q=L(R,0);if(2!=Q.length)throw new Error("malformed format: SEQUENCE(0).items != 2: "+Q.length);J.ciphertext=$(R,Q[1]);var te=L(R,Q[0]);if(2!=te.length)throw new Error("malformed format: SEQUENCE(0.0).items != 2: "+te.length);if("2a864886f70d01050d"!=$(R,te[0]))throw new Error("this only supports pkcs5PBES2");var Se=L(R,te[1]);if(2!=te.length)throw new Error("malformed format: SEQUENCE(0.0.1).items != 2: "+Se.length);var Ae=L(R,Se[1]);if(2!=Ae.length)throw new Error("malformed format: SEQUENCE(0.0.1.1).items != 2: "+Ae.length);if("2a864886f70d0307"!=$(R,Ae[0]))throw"this only supports TripleDES";J.encryptionSchemeAlg="TripleDES",J.encryptionSchemeIV=$(R,Ae[1]);var j=L(R,Se[0]);if(2!=j.length)throw new Error("malformed format: SEQUENCE(0.0.1.0).items != 2: "+j.length);if("2a864886f70d01050c"!=$(R,j[0]))throw new Error("this only supports pkcs5PBKDF2");var q=L(R,j[1]);if(q.length<2)throw new Error("malformed format: SEQUENCE(0.0.1.0.1).items < 2: "+q.length);J.pbkdf2Salt=$(R,q[0]);var ee=$(R,q[1]);try{J.pbkdf2Iter=parseInt(ee,16)}catch{throw new Error("malformed format pbkdf2Iter: "+ee)}return J},getPBKDF2KeyHexFromParam:function(R,V){var L=pt.enc.Hex.parse(R.pbkdf2Salt),J=pt.PBKDF2(V,L,{keySize:6,iterations:R.pbkdf2Iter});return pt.enc.Hex.stringify(J)},_getPlainPKCS8HexFromEncryptedPKCS8PEM:function(R,V){var L=ir(R,"ENCRYPTED PRIVATE KEY"),$=this.parseHexOfEncryptedPKCS8(L),J=Zt.getPBKDF2KeyHexFromParam($,V),Q={};Q.ciphertext=pt.enc.Hex.parse($.ciphertext);var te=pt.enc.Hex.parse(J),Se=pt.enc.Hex.parse($.encryptionSchemeIV),Ae=pt.TripleDES.decrypt(Q,te,{iv:Se});return pt.enc.Hex.stringify(Ae)},getKeyFromEncryptedPKCS8PEM:function(R,V){var L=this._getPlainPKCS8HexFromEncryptedPKCS8PEM(R,V);return this.getKeyFromPlainPrivatePKCS8Hex(L)},parsePlainPrivatePKCS8Hex:function(R){var V=rt,L=V.getChildIdx,$=V.getV,J={algparam:null};if("30"!=R.substr(0,2))throw new Error("malformed plain PKCS8 private key(code:001)");var Q=L(R,0);if(Q.length<3)throw new Error("malformed plain PKCS8 private key(code:002)");if("30"!=R.substr(Q[1],2))throw new Error("malformed PKCS8 private key(code:003)");var te=L(R,Q[1]);if(2!=te.length)throw new Error("malformed PKCS8 private key(code:004)");if("06"!=R.substr(te[0],2))throw new Error("malformed PKCS8 private key(code:005)");if(J.algoid=$(R,te[0]),"06"==R.substr(te[1],2)&&(J.algparam=$(R,te[1])),"04"!=R.substr(Q[2],2))throw new Error("malformed PKCS8 private key(code:006)");return J.keyidx=V.getVidx(R,Q[2]),J},getKeyFromPlainPrivatePKCS8PEM:function(R){var V=ir(R,"PRIVATE KEY");return this.getKeyFromPlainPrivatePKCS8Hex(V)},getKeyFromPlainPrivatePKCS8Hex:function(R){var L,V=this.parsePlainPrivatePKCS8Hex(R);if("2a864886f70d010101"==V.algoid)L=new Ut;else if("2a8648ce380401"==V.algoid)L=new w.crypto.DSA;else{if("2a8648ce3d0201"!=V.algoid)throw new Error("unsupported private key algorithm");L=new w.crypto.ECDSA}return L.readPKCS8PrvKeyHex(R),L},_getKeyFromPublicPKCS8Hex:function(R){var V,L=rt.getVbyList(R,0,[0,0],"06");if("2a864886f70d010101"===L)V=new Ut;else if("2a8648ce380401"===L)V=new w.crypto.DSA;else{if("2a8648ce3d0201"!==L)throw new Error("unsupported PKCS#8 public key hex");V=new w.crypto.ECDSA}return V.readPKCS8PubKeyHex(R),V},parsePublicRawRSAKeyHex:function(R){var L=rt.getChildIdx,$=rt.getV,J={};if("30"!=R.substr(0,2))throw new Error("malformed RSA key(code:001)");var Q=L(R,0);if(2!=Q.length)throw new Error("malformed RSA key(code:002)");if("02"!=R.substr(Q[0],2))throw new Error("malformed RSA key(code:003)");if(J.n=$(R,Q[0]),"02"!=R.substr(Q[1],2))throw new Error("malformed RSA key(code:004)");return J.e=$(R,Q[1]),J},parsePublicPKCS8Hex:function(R){var V=rt,L=V.getChildIdx,$=V.getV,J={algparam:null},Q=L(R,0);if(2!=Q.length)throw new Error("outer DERSequence shall have 2 elements: "+Q.length);var te=Q[0];if("30"!=R.substr(te,2))throw new Error("malformed PKCS8 public key(code:001)");var Se=L(R,te);if(2!=Se.length)throw new Error("malformed PKCS8 public key(code:002)");if("06"!=R.substr(Se[0],2))throw new Error("malformed PKCS8 public key(code:003)");if(J.algoid=$(R,Se[0]),"06"==R.substr(Se[1],2)?J.algparam=$(R,Se[1]):"30"==R.substr(Se[1],2)&&(J.algparam={},J.algparam.p=V.getVbyList(R,Se[1],[0],"02"),J.algparam.q=V.getVbyList(R,Se[1],[1],"02"),J.algparam.g=V.getVbyList(R,Se[1],[2],"02")),"03"!=R.substr(Q[1],2))throw new Error("malformed PKCS8 public key(code:004)");return J.key=$(R,Q[1]).substr(2),J}}}();function Xs(l,h){for(var f="",_=h/4-l.length,b=0;b<_;b++)f+="0";return f+l}function yd(l,h,f){for(var _="",b=0;_.length>24,(16711680&b)>>16,(65280&b)>>8,255&b])))),b+=1;return _}function Os(l){for(var h in w.crypto.Util.DIGESTINFOHEAD){var f=w.crypto.Util.DIGESTINFOHEAD[h],_=f.length;if(l.substring(0,_)==f)return[h,l.substring(_)]}return[]}function rn(l){var J,h=rt,f=h.getChildIdx,_=h.getV,E=h.parse,M=h.getTLV,D=h.getVbyList,F=h.getVbyListEx,P=h.getTLVbyList,U=h.getTLVbyListEx,z=h.getIdxbyList,I=h.getIdxbyListEx,C=h.getVidx,B=h.getInt,R=h.oidname,V=h.hextooidstr,$=ir,Q=Error;try{J=w.asn1.x509.AlgorithmIdentifier.PSSNAME2ASN1TLV}catch{}this.HEX2STAG={"0c":"utf8",13:"prn",16:"ia5","1a":"vis","1e":"bmp"},this.hex=null,this.version=0,this.foffset=0,this.aExtInfo=null,this.getVersion=function(){if(null===this.hex||0!==this.version)return this.version;var j=P(this.hex,0,[0,0]);if("a0"==j.substr(0,2)){var q=P(j,0,[0]),ee=B(q,0);if(ee<0||21){var be=M(j,ue[1]),ce=this.getGeneralName(be);null!=ce.uri&&(re.uri=ce.uri)}if(ue.length>2){var pe=M(j,ue[2]);"0101ff"==pe&&(re.reqauth=!0),"010100"==pe&&(re.reqauth=!1)}return re};var te=function(j){var q={};try{var re=w.asn1.x509.OID.name2oid(j.seq[0].oid);q.type=w.asn1.x509.OID.oid2atype(re);var ue=j.seq[1];if(null!=ue.utf8str)q.ds="utf8",q.value=ue.utf8str.str;else if(null!=ue.numstr)q.ds="num",q.value=ue.numstr.str;else if(null!=ue.telstr)q.ds="tel",q.value=ue.telstr.str;else if(null!=ue.prnstr)q.ds="prn",q.value=ue.prnstr.str;else if(null!=ue.ia5str)q.ds="ia5",q.value=ue.ia5str.str;else if(null!=ue.visstr)q.ds="vis",q.value=ue.visstr.str;else{if(null==ue.bmpstr)throw"error";q.ds="bmp",q.value=ue.bmpstr.str}return q}catch{throw new Erorr("improper ASN.1 parsed AttrTypeAndValue")}},Se=function(j){try{return j.set.map(function(q){return te(q)})}catch(q){throw new Error("improper ASN.1 parsed RDN: "+q)}};this.getX500NameRule=function(j){for(var ce=null,pe=[],ve=0;ve0&&(q.ext=this.getExtParamArray()),q.sighex=this.getSignatureValueHex(),1==j.tbshex&&(q.tbshex=P(this.hex,0,[0])),1==j.nodnarray&&(delete q.issuer.array,delete q.subject.array),q},this.getExtParamArray=function(j){null==j&&-1!=I(this.hex,0,[0,"[3]"])&&(j=U(this.hex,0,[0,"[3]",0],"30"));for(var ee=[],re=f(j,0),ue=0;ue2&&"04"===Q.substr(te[1],2)))throw new Error("unsupported PKCS#1/5 hexadecimal key");(C=new F).readPKCS5PrvKeyHex(Q)}return C}if("pkcs8prv"===f)return I.getKeyFromPlainPrivatePKCS8Hex(l);if("pkcs8pub"===f)return I._getKeyFromPublicPKCS8Hex(l);if("x509pub"===f)return rn.getPublicKeyFromCertHex(l);if(-1!=l.indexOf("-END CERTIFICATE-",0)||-1!=l.indexOf("-END X509 CERTIFICATE-",0)||-1!=l.indexOf("-END TRUSTED CERTIFICATE-",0))return rn.getPublicKeyFromCertPEM(l);if(-1!=l.indexOf("-END PUBLIC KEY-")){var Se=ir(l,"PUBLIC KEY");return I._getKeyFromPublicPKCS8Hex(Se)}if(-1!=l.indexOf("-END RSA PRIVATE KEY-")&&-1==l.indexOf("4,ENCRYPTED")){var Ae=z(l,"RSA PRIVATE KEY");return I.getKey(Ae,null,"pkcs5prv")}if(-1!=l.indexOf("-END DSA PRIVATE KEY-")&&-1==l.indexOf("4,ENCRYPTED")){var q=M(j=z(l,"DSA PRIVATE KEY"),0,[1],"02"),ee=M(j,0,[2],"02"),re=M(j,0,[3],"02"),ue=M(j,0,[4],"02"),be=M(j,0,[5],"02");return(C=new P).setPrivate(new _e(q,16),new _e(ee,16),new _e(re,16),new _e(ue,16),new _e(be,16)),C}if(-1!=l.indexOf("-END EC PRIVATE KEY-")&&-1==l.indexOf("4,ENCRYPTED"))return Ae=z(l,"EC PRIVATE KEY"),I.getKey(Ae,null,"pkcs5prv");if(-1!=l.indexOf("-END PRIVATE KEY-"))return I.getKeyFromPlainPrivatePKCS8PEM(l);if(-1!=l.indexOf("-END RSA PRIVATE KEY-")&&-1!=l.indexOf("4,ENCRYPTED")){var ce=I.getDecryptedKeyHex(l,h),pe=new Ut;return pe.readPKCS5PrvKeyHex(ce),pe}if(-1!=l.indexOf("-END EC PRIVATE KEY-")&&-1!=l.indexOf("4,ENCRYPTED")){var B,C=M(j=I.getDecryptedKeyHex(l,h),0,[1],"04"),ve=M(j,0,[2,0],"06"),Ie=M(j,0,[3,0],"03").substr(2);if(void 0===w.crypto.OID.oidhex2name[ve])throw new Error("undefined OID(hex) in KJUR.crypto.OID: "+ve);return(B=new F({curve:w.crypto.OID.oidhex2name[ve]})).setPublicKeyHex(Ie),B.setPrivateKeyHex(C),B.isPublic=!1,B}if(-1!=l.indexOf("-END DSA PRIVATE KEY-")&&-1!=l.indexOf("4,ENCRYPTED"))return q=M(j=I.getDecryptedKeyHex(l,h),0,[1],"02"),ee=M(j,0,[2],"02"),re=M(j,0,[3],"02"),ue=M(j,0,[4],"02"),be=M(j,0,[5],"02"),(C=new P).setPrivate(new _e(q,16),new _e(ee,16),new _e(re,16),new _e(ue,16),new _e(be,16)),C;if(-1!=l.indexOf("-END ENCRYPTED PRIVATE KEY-"))return I.getKeyFromEncryptedPKCS8PEM(l,h);throw new Error("not supported argument")},Zt.generateKeypair=function(l,h){if("RSA"==l){var f=h;(_=new Ut).generate(f,"10001"),_.isPrivate=!0,_.isPublic=!0;var b=new Ut,E=_.n.toString(16),M=_.e.toString(16);return b.setPublic(E,M),b.isPrivate=!1,b.isPublic=!0,(D={}).prvKeyObj=_,D.pubKeyObj=b,D}if("EC"==l){var _,D,F=h,U=new w.crypto.ECDSA({curve:F}).generateKeyPairHex();return(_=new w.crypto.ECDSA({curve:F})).setPublicKeyHex(U.ecpubhex),_.setPrivateKeyHex(U.ecprvhex),_.isPrivate=!0,_.isPublic=!1,(b=new w.crypto.ECDSA({curve:F})).setPublicKeyHex(U.ecpubhex),b.isPrivate=!1,b.isPublic=!0,(D={}).prvKeyObj=_,D.pubKeyObj=b,D}throw new Error("unknown algorithm: "+l)},Zt.getPEM=function(l,h,f,_,b,E){var D=w.asn1,F=D.DERObjectIdentifier,P=D.DERInteger,U=D.ASN1Util.newObject,C=w.crypto,B=C.DSA,R=C.ECDSA,V=Ut;function L(ve){return U({seq:[{int:0},{int:{bigint:ve.n}},{int:ve.e},{int:{bigint:ve.d}},{int:{bigint:ve.p}},{int:{bigint:ve.q}},{int:{bigint:ve.dmp1}},{int:{bigint:ve.dmq1}},{int:{bigint:ve.coeff}}]})}function $(ve){return U({seq:[{int:1},{octstr:{hex:ve.prvKeyHex}},{tag:["a0",!0,{oid:{name:ve.curveName}}]},{tag:["a1",!0,{bitstr:{hex:"00"+ve.pubKeyHex}}]}]})}function J(ve){return U({seq:[{int:0},{int:{bigint:ve.p}},{int:{bigint:ve.q}},{int:{bigint:ve.g}},{int:{bigint:ve.y}},{int:{bigint:ve.x}}]})}if((void 0!==V&&l instanceof V||void 0!==B&&l instanceof B||void 0!==R&&l instanceof R)&&1==l.isPublic&&(void 0===h||"PKCS8PUB"==h))return Fr(te=new(0,D.x509.SubjectPublicKeyInfo)(l).tohex(),"PUBLIC KEY");if("PKCS1PRV"==h&&void 0!==V&&l instanceof V&&(void 0===f||null==f)&&1==l.isPrivate)return Fr(te=L(l).tohex(),"RSA PRIVATE KEY");if("PKCS1PRV"==h&&void 0!==R&&l instanceof R&&(void 0===f||null==f)&&1==l.isPrivate){var Ae=new F({name:l.curveName}).tohex(),q=$(l).tohex(),ee="";return(ee+=Fr(Ae,"EC PARAMETERS"))+Fr(q,"EC PRIVATE KEY")}if("PKCS1PRV"==h&&void 0!==B&&l instanceof B&&(void 0===f||null==f)&&1==l.isPrivate)return Fr(te=J(l).tohex(),"DSA PRIVATE KEY");if("PKCS5PRV"==h&&void 0!==V&&l instanceof V&&void 0!==f&&null!=f&&1==l.isPrivate){var te=L(l).tohex();return void 0===_&&(_="DES-EDE3-CBC"),this.getEncryptedPKCS5PEMFromPrvKeyHex("RSA",te,f,_,E)}if("PKCS5PRV"==h&&void 0!==R&&l instanceof R&&void 0!==f&&null!=f&&1==l.isPrivate)return te=$(l).tohex(),void 0===_&&(_="DES-EDE3-CBC"),this.getEncryptedPKCS5PEMFromPrvKeyHex("EC",te,f,_,E);if("PKCS5PRV"==h&&void 0!==B&&l instanceof B&&void 0!==f&&null!=f&&1==l.isPrivate)return te=J(l).tohex(),void 0===_&&(_="DES-EDE3-CBC"),this.getEncryptedPKCS5PEMFromPrvKeyHex("DSA",te,f,_,E);var re=function(ve,Ie){var Bt=ue(ve,Ie);return new U({seq:[{seq:[{oid:{name:"pkcs5PBES2"}},{seq:[{seq:[{oid:{name:"pkcs5PBKDF2"}},{seq:[{octstr:{hex:Bt.pbkdf2Salt}},{int:Bt.pbkdf2Iter}]}]},{seq:[{oid:{name:"des-EDE3-CBC"}},{octstr:{hex:Bt.encryptionSchemeIV}}]}]}]},{octstr:{hex:Bt.ciphertext}}]}).tohex()},ue=function(ve,Ie){var Nt=pt.lib.WordArray.random(8),Rn=pt.lib.WordArray.random(8),Y=pt.PBKDF2(Ie,Nt,{keySize:6,iterations:100}),ui=pt.enc.Hex.parse(ve),oi=pt.TripleDES.encrypt(ui,Y,{iv:Rn})+"",Fi={};return Fi.ciphertext=oi,Fi.pbkdf2Salt=pt.enc.Hex.stringify(Nt),Fi.pbkdf2Iter=100,Fi.encryptionSchemeAlg="DES-EDE3-CBC",Fi.encryptionSchemeIV=pt.enc.Hex.stringify(Rn),Fi};if("PKCS8PRV"==h&&null!=V&&l instanceof V&&1==l.isPrivate){var ce=L(l).tohex();return te=U({seq:[{int:0},{seq:[{oid:{name:"rsaEncryption"}},{null:!0}]},{octstr:{hex:ce}}]}).tohex(),void 0===f||null==f?Fr(te,"PRIVATE KEY"):Fr(q=re(te,f),"ENCRYPTED PRIVATE KEY")}if("PKCS8PRV"==h&&void 0!==R&&l instanceof R&&1==l.isPrivate){var pe={seq:[{int:1},{octstr:{hex:l.prvKeyHex}}]};return"string"==typeof l.pubKeyHex&&pe.seq.push({tag:["a1",!0,{bitstr:{hex:"00"+l.pubKeyHex}}]}),ce=new U(pe).tohex(),te=U({seq:[{int:0},{seq:[{oid:{name:"ecPublicKey"}},{oid:{name:l.curveName}}]},{octstr:{hex:ce}}]}).tohex(),void 0===f||null==f?Fr(te,"PRIVATE KEY"):Fr(q=re(te,f),"ENCRYPTED PRIVATE KEY")}if("PKCS8PRV"==h&&void 0!==B&&l instanceof B&&1==l.isPrivate)return ce=new P({bigint:l.x}).tohex(),te=U({seq:[{int:0},{seq:[{oid:{name:"dsa"}},{seq:[{int:{bigint:l.p}},{int:{bigint:l.q}},{int:{bigint:l.g}}]}]},{octstr:{hex:ce}}]}).tohex(),void 0===f||null==f?Fr(te,"PRIVATE KEY"):Fr(q=re(te,f),"ENCRYPTED PRIVATE KEY");throw new Error("unsupported object nor format")},Zt.getKeyFromCSRPEM=function(l){var h=ir(l,"CERTIFICATE REQUEST");return Zt.getKeyFromCSRHex(h)},Zt.getKeyFromCSRHex=function(l){var h=Zt.parseCSRHex(l);return Zt.getKey(h.p8pubkeyhex,null,"pkcs8pub")},Zt.parseCSRHex=function(l){var f=rt.getChildIdx,_=rt.getTLV,b={},E=l;if("30"!=E.substr(0,2))throw new Error("malformed CSR(code:001)");var M=f(E,0);if(M.length<1)throw new Error("malformed CSR(code:002)");if("30"!=E.substr(M[0],2))throw new Error("malformed CSR(code:003)");var D=f(E,M[0]);if(D.length<3)throw new Error("malformed CSR(code:004)");return b.p8pubkeyhex=_(E,D[2]),b},Zt.getKeyID=function(l){var h=Zt,f=rt;"string"==typeof l&&-1!=l.indexOf("BEGIN ")&&(l=h.getKey(l));var _=ir(h.getPEM(l)),b=f.getIdxbyList(_,0,[1]),E=f.getV(_,b).substring(2);return w.crypto.Util.hashHex(E,"sha1")},Zt.getJWK=function(l,h,f,_,b){var E,D,M={},F=w.crypto.Util.hashHex;if("string"==typeof l)E=Zt.getKey(l),-1!=l.indexOf("CERTIFICATE")&&(D=ir(l));else{if("object"!=typeof l)throw new Error("unsupported keyinfo type");l instanceof rn?(E=l.getPublicKey(),D=l.hex):E=l}if(E instanceof Ut&&E.isPrivate)M.kty="RSA",M.n=Er(E.n.toString(16)),M.e=Er(E.e.toString(16)),M.d=Er(E.d.toString(16)),M.p=Er(E.p.toString(16)),M.q=Er(E.q.toString(16)),M.dp=Er(E.dmp1.toString(16)),M.dq=Er(E.dmq1.toString(16)),M.qi=Er(E.coeff.toString(16));else if(E instanceof Ut&&E.isPublic)M.kty="RSA",M.n=Er(E.n.toString(16)),M.e=Er(E.e.toString(16));else if(E instanceof w.crypto.ECDSA&&E.isPrivate){if("P-256"!==(P=E.getShortNISTPCurveName())&&"P-384"!==P&&"P-521"!==P)throw new Error("unsupported curve name for JWT: "+P);var U=E.getPublicKeyXYHex();M.kty="EC",M.crv=P,M.x=Er(U.x),M.y=Er(U.y),M.d=Er(E.prvKeyHex)}else if(E instanceof w.crypto.ECDSA&&E.isPublic){var P;if("P-256"!==(P=E.getShortNISTPCurveName())&&"P-384"!==P&&"P-521"!==P)throw new Error("unsupported curve name for JWT: "+P);U=E.getPublicKeyXYHex(),M.kty="EC",M.crv=P,M.x=Er(U.x),M.y=Er(U.y)}if(null==M.kty)throw new Error("unsupported keyinfo");return!E.isPrivate&&1!=h&&(M.kid=w.jws.JWS.getJWKthumbprint(M)),null!=D&&1!=f&&(M.x5c=[_i(D)]),null!=D&&1!=_&&(M.x5t=Qr(_i(F(D,"sha1")))),null!=D&&1!=b&&(M["x5t#S256"]=Qr(_i(F(D,"sha256")))),M},Zt.getJWKFromKey=function(l){return Zt.getJWK(l,!0,!0,!0,!0)},Ut.getPosArrayOfChildrenFromHex=function(l){return rt.getChildIdx(l,0)},Ut.getHexValueArrayOfChildrenFromHex=function(l){var I,f=rt.getV,_=f(l,(I=Ut.getPosArrayOfChildrenFromHex(l))[0]),b=f(l,I[1]),E=f(l,I[2]),M=f(l,I[3]),D=f(l,I[4]),F=f(l,I[5]),P=f(l,I[6]),U=f(l,I[7]),z=f(l,I[8]);return(I=new Array).push(_,b,E,M,D,F,P,U,z),I},Ut.prototype.readPrivateKeyFromPEMString=function(l){var h=ir(l),f=Ut.getHexValueArrayOfChildrenFromHex(h);this.setPrivateEx(f[1],f[2],f[3],f[4],f[5],f[6],f[7],f[8])},Ut.prototype.readPKCS5PrvKeyHex=function(l){var h=Ut.getHexValueArrayOfChildrenFromHex(l);this.setPrivateEx(h[1],h[2],h[3],h[4],h[5],h[6],h[7],h[8])},Ut.prototype.readPKCS8PrvKeyHex=function(l){var h,f,_,b,E,M,D,F,U=rt.getVbyListEx;if(!1===rt.isASN1HEX(l))throw new Error("not ASN.1 hex string");try{h=U(l,0,[2,0,1],"02"),f=U(l,0,[2,0,2],"02"),_=U(l,0,[2,0,3],"02"),b=U(l,0,[2,0,4],"02"),E=U(l,0,[2,0,5],"02"),M=U(l,0,[2,0,6],"02"),D=U(l,0,[2,0,7],"02"),F=U(l,0,[2,0,8],"02")}catch{throw new Error("malformed PKCS#8 plain RSA private key")}this.setPrivateEx(h,f,_,b,E,M,D,F)},Ut.prototype.readPKCS5PubKeyHex=function(l){var h=rt,f=h.getV;if(!1===h.isASN1HEX(l))throw new Error("keyHex is not ASN.1 hex string");var _=h.getChildIdx(l,0);if(2!==_.length||"02"!==l.substr(_[0],2)||"02"!==l.substr(_[1],2))throw new Error("wrong hex for PKCS#5 public key");var b=f(l,_[0]),E=f(l,_[1]);this.setPublic(b,E)},Ut.prototype.readPKCS8PubKeyHex=function(l){var h=rt;if(!1===h.isASN1HEX(l))throw new Error("not ASN.1 hex string");if("06092a864886f70d010101"!==h.getTLVbyListEx(l,0,[0,0]))throw new Error("not PKCS8 RSA public key");var f=h.getTLVbyListEx(l,0,[1,0]);this.readPKCS5PubKeyHex(f)},Ut.prototype.readCertPubKeyHex=function(l,h){var f,_;(f=new rn).readCertHex(l),_=f.getPublicKeyHex(),this.readPKCS8PubKeyHex(_)},Ut.prototype.sign=function(l,h){var _=function(b){return w.crypto.Util.hashString(b,h)}(l);return this.signWithMessageHash(_,h)},Ut.prototype.signWithMessageHash=function(l,h){var _=hr(w.crypto.Util.getPaddedDigestInfoHex(l,h,this.n.bitLength()),16);return Xs(this.doPrivate(_).toString(16),this.n.bitLength())},Ut.prototype.signPSS=function(l,h,f){var b=function(E){return w.crypto.Util.hashHex(E,h)}(_s(l));return void 0===f&&(f=-1),this.signWithMessageHashPSS(b,h,f)},Ut.prototype.signWithMessageHashPSS=function(l,h,f){var D,_=Vr(l),b=_.length,E=this.n.bitLength()-1,M=Math.ceil(E/8),F=function(V){return w.crypto.Util.hashHex(V,h)};if(-1===f||void 0===f)f=b;else if(-2===f)f=M-b-2;else if(f<-2)throw new Error("invalid salt length");if(M0&&(P=new Array(f),(new Ao).nextBytes(P),P=String.fromCharCode.apply(String,P));var U=Vr(F(_s("\0\0\0\0\0\0\0\0"+_+P))),z=[];for(D=0;D>8*M-E&255),D=0;D_)return!1;var E=this.doPublic(f).toString(16);if(E.length+3!=_/4)return!1;var D=Os(E.replace(/^1f+00/,""));if(0==D.length)return!1;var F=D[0],P=D[1],z=function(I){return w.crypto.Util.hashString(I,F)}(l);return P==z},Ut.prototype.verifyWithMessageHash=function(l,h){if(h.length!=Math.ceil(this.n.bitLength()/4))return!1;var f=hr(h,16);if(f.bitLength()>this.n.bitLength())return 0;var E=Os(this.doPublic(f).toString(16).replace(/^1f+00/,""));return 0!=E.length&&E[1]==l},Ut.prototype.verifyPSS=function(l,h,f,_){var E=function(M){return w.crypto.Util.hashHex(M,f)}(_s(l));return void 0===_&&(_=-1),this.verifyWithMessageHashPSS(E,h,f,_)},Ut.prototype.verifyWithMessageHashPSS=function(l,h,f,_){if(h.length!=Math.ceil(this.n.bitLength()/4))return!1;var U,b=new _e(h,16),E=function($){return w.crypto.Util.hashHex($,f)},M=Vr(l),D=M.length,F=this.n.bitLength()-1,P=Math.ceil(F/8);if(-1===_||void 0===_)_=D;else if(-2===_)_=P-D-2;else if(_<-2)throw new Error("invalid salt length");if(P>8*P-F&255;if(I.charCodeAt(0)&B)throw new Error("bits beyond keysize not zero");var R=yd(C,I.length,E),V=[];for(U=0;U"u"||!w)&&(w={}),(typeof w.jws>"u"||!w.jws)&&(w.jws={}),w.jws.JWS=function(){var f=w.jws.JWS.isSafeJSONString;this.parseJWS=function(_,b){if(void 0===this.parsedJWS||!b&&void 0===this.parsedJWS.sigvalH){var E=_.match(/^([^.]+)\.([^.]+)\.([^.]+)$/);if(null==E)throw"JWS signature is not a form of 'Head.Payload.SigValue'.";var M=E[1],D=E[2],F=E[3],P=M+"."+D;if(this.parsedJWS={},this.parsedJWS.headB64U=M,this.parsedJWS.payloadB64U=D,this.parsedJWS.sigvalB64U=F,this.parsedJWS.si=P,!b){var U=nn(F),z=hr(U,16);this.parsedJWS.sigvalH=U,this.parsedJWS.sigvalBI=z}var I=mo(M),C=mo(D);if(this.parsedJWS.headS=I,this.parsedJWS.payloadS=C,!f(I,this.parsedJWS,"headP"))throw"malformed JSON string for JWS Head: "+I}}},w.jws.JWS.sign=function(l,h,f,_,b){var R,V,L,D=w.jws.JWS,F=D.readSafeJSONString,P=D.isSafeJSONString,U=w.crypto,I=U.Mac,C=U.Signature,B=JSON;if("string"!=typeof h&&"object"!=typeof h)throw"spHeader must be JSON string or object: "+h;if("object"==typeof h&&(R=B.stringify(V=h)),"string"==typeof h){if(!P(R=h))throw"JWS Head is not safe JSON string: "+R;V=F(R)}if(L=f,"object"==typeof f&&(L=B.stringify(f)),(""==l||null==l)&&void 0!==V.alg&&(l=V.alg),""!=l&&null!=l&&void 0===V.alg&&(V.alg=l,R=B.stringify(V)),l!==V.alg)throw"alg and sHeader.alg doesn't match: "+l+"!="+V.alg;var $=null;if(void 0===D.jwsalg2sigalg[l])throw"unsupported alg name: "+l;$=D.jwsalg2sigalg[l];var te=Il(R)+"."+Il(L),Se="";if("Hmac"==$.substr(0,4)){if(void 0===_)throw"mac key shall be specified for HS* alg";var Ae=new I({alg:$,prov:"cryptojs",pass:_});Ae.updateString(te),Se=Ae.doFinal()}else if(-1!=$.indexOf("withECDSA")){(j=new C({alg:$})).init(_,b),j.updateString(te);var q=j.sign();Se=w.crypto.ECDSA.asn1SigToConcatSig(q)}else if("none"!=$){var j;(j=new C({alg:$})).init(_,b),j.updateString(te),Se=j.sign()}return te+"."+Er(Se)},w.jws.JWS.verify=function(l,h,f){var z,E=w.jws.JWS,M=E.readSafeJSONString,D=w.crypto,F=D.ECDSA,P=D.Mac,U=D.Signature;if(z=Ut,!mr(l))return!1;var I=l.split(".");if(3!==I.length)return!1;var J,R=I[0]+"."+I[1],V=nn(I[2]),L=M(mo(I[0])),$=null;if(void 0===L.alg)throw"algorithm not specified in header";if(J=($=L.alg).substr(0,2),null!=f&&"[object Array]"===Object.prototype.toString.call(f)&&f.length>0&&-1==(":"+f.join(":")+":").indexOf(":"+$+":"))throw"algorithm '"+$+"' not accepted in the list";if("none"!=$&&null===h)throw"key shall be specified to verify.";if("string"==typeof h&&-1!=h.indexOf("-----BEGIN ")&&(h=Zt.getKey(h)),!("RS"!=J&&"PS"!=J||h instanceof z))throw"key shall be a RSAKey obj for RS* and PS* algs";if("ES"==J&&!(h instanceof F))throw"key shall be a ECDSA obj for ES* algs";var te=null;if(void 0===E.jwsalg2sigalg[L.alg])throw"unsupported alg name: "+$;if("none"==(te=E.jwsalg2sigalg[$]))throw"not supported";if("Hmac"==te.substr(0,4)){if(void 0===h)throw"hexadecimal key shall be specified for HMAC";var Ae=new P({alg:te,pass:h});return Ae.updateString(R),V==Ae.doFinal()}if(-1!=te.indexOf("withECDSA")){var q,j=null;try{j=F.concatSigToASN1Sig(V)}catch{return!1}return(q=new U({alg:te})).init(h),q.updateString(R),q.verify(j)}return(q=new U({alg:te})).init(h),q.updateString(R),q.verify(V)},w.jws.JWS.parse=function(l){var b,E,h=l.split("."),f={};if(2!=h.length&&3!=h.length)throw"malformed sJWS: wrong number of '.' splitted elements";return b=h[1],3==h.length&&(E=h[2]),f.headerObj=w.jws.JWS.readSafeJSONString(mo(h[0])),f.payloadObj=w.jws.JWS.readSafeJSONString(mo(b)),f.headerPP=JSON.stringify(f.headerObj,null," "),f.payloadPP=null==f.payloadObj?mo(b):JSON.stringify(f.payloadObj,null," "),void 0!==E&&(f.sigHex=nn(E)),f},w.jws.JWS.verifyJWT=function(l,h,f){var b=w.jws,E=b.JWS,M=E.readSafeJSONString,D=E.inArray,F=E.includedArray;if(!mr(l))return!1;var P=l.split(".");if(3!=P.length)return!1;var U=P[0],z=P[1],B=(nn(P[2]),M(mo(U))),R=M(mo(z));if(void 0===B.alg)return!1;if(void 0===f.alg)throw"acceptField.alg shall be specified";if(!D(B.alg,f.alg)||void 0!==R.iss&&"object"==typeof f.iss&&!D(R.iss,f.iss)||void 0!==R.sub&&"object"==typeof f.sub&&!D(R.sub,f.sub))return!1;if(void 0!==R.aud&&"object"==typeof f.aud)if("string"==typeof R.aud){if(!D(R.aud,f.aud))return!1}else if("object"==typeof R.aud&&!F(R.aud,f.aud))return!1;var V=b.IntDate.getNow();return void 0!==f.verifyAt&&"number"==typeof f.verifyAt&&(V=f.verifyAt),(void 0===f.gracePeriod||"number"!=typeof f.gracePeriod)&&(f.gracePeriod=0),!(void 0!==R.exp&&"number"==typeof R.exp&&R.exp+f.gracePeriod"u"||!w)&&(w={}),(typeof w.jws>"u"||!w.jws)&&(w.jws={}),w.jws.JWSJS=function(){var f=w.jws.JWS,_=f.readSafeJSONString;this.aHeader=[],this.sPayload="",this.aSignature=[],this.init=function(){this.aHeader=[],this.sPayload=void 0,this.aSignature=[]},this.initWithJWS=function(b){this.init();var E=b.split(".");if(3!=E.length)throw"malformed input JWS";this.aHeader.push(E[0]),this.sPayload=E[1],this.aSignature.push(E[2])},this.addSignature=function(b,E,M,D){if(null==this.sPayload)throw"there's no JSON-JS signature to add.";var F=this.aHeader.length;if(this.aHeader.length!=this.aSignature.length)throw"aHeader.length != aSignature.length";try{var U=w.jws.JWS.sign(b,E,this.sPayload,M,D).split(".");this.aHeader.push(U[0]),this.aSignature.push(U[2])}catch(C){throw this.aHeader.length>F&&this.aHeader.pop(),this.aSignature.length>F&&this.aSignature.pop(),"addSignature failed: "+C}},this.verifyAll=function(b){if(this.aHeader.length!==b.length||this.aSignature.length!==b.length)return!1;for(var E=0;E0))throw"malformed header";if(this.aHeader=b.headers,"string"!=typeof b.payload)throw"malformed signatures";if(this.sPayload=b.payload,!(b.signatures.length>0))throw"malformed signatures";this.aSignature=b.signatures}catch(M){throw"malformed JWS-JS JSON object: "+M}},this.getJSON=function(){return{headers:this.aHeader,payload:this.sPayload,signatures:this.aSignature}},this.isEmpty=function(){return 0==this.aHeader.length?1:0}},ka.KZ=Zt,ka.fs=w},7489:function(Aa,ka,dt){var qr;Aa=dt.nmd(Aa),function(){var le,ps=200,_i="Expected a function",ao="__lodash_hash_undefined__",Kr="__lodash_placeholder__",Tn=1,Sl=2,_e=4,An=1,di=2,ks=1,Fa=2,El=4,ms=8,Is=16,Yr=32,Sr=64,un=128,Ra=256,lu=512,du=800,cn=16,$t=1/0,Qn=9007199254740991,In=17976931348623157e292,fn=NaN,Fn=4294967295,sr=Fn-1,Wi=Fn>>>1,lc=[["ary",un],["bind",ks],["bindKey",Fa],["curry",ms],["curryRight",Is],["flip",lu],["partial",Yr],["partialRight",Sr],["rearg",Ra]],co="[object Arguments]",dc="[object Array]",$o="[object AsyncFunction]",Fs="[object Boolean]",_t="[object Date]",uu="[object DOMException]",zc="[object Error]",hu="[object Function]",Ep="[object GeneratorFunction]",lo="[object Map]",ad="[object Number]",Gc="[object Null]",Oa="[object Object]",Mp="[object Promise]",dr="[object Proxy]",ur="[object RegExp]",qo="[object Set]",cd="[object String]",Ih="[object Symbol]",Ml="[object Undefined]",uc="[object WeakMap]",hc="[object ArrayBuffer]",Cl="[object DataView]",Fh="[object Float32Array]",ld="[object Float64Array]",Rh="[object Int8Array]",Ph="[object Int16Array]",Cp="[object Int32Array]",Oh="[object Uint8Array]",Lh="[object Uint8ClampedArray]",Nh="[object Uint16Array]",Bh="[object Uint32Array]",Dp=/\b__p \+= '';/g,Vi=/\b(__p \+=) '' \+/g,Vh=/(__e\(.*?\)|\b__t\)) \+\n'';/g,ki=/&(?:amp|lt|gt|quot|#39);/g,fu=/[&<>"']/g,Tp=RegExp(ki.source),Mi=RegExp(fu.source),en=/<%-([\s\S]+?)%>/g,Hh=/<%([\s\S]+?)%>/g,pu=/<%=([\s\S]+?)%>/g,hb=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,mu=/^\w*$/,Ue=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Dl=/[\\^$.*+?()[\]{}|]/g,wn=RegExp(Dl.source),wi=/^\s+|\s+$/g,Ap=/^\s+/,fb=/\s+$/,F0=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,gu=/\{\n\/\* \[wrapped with (.+)\] \*/,uo=/,? & /,pb=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,R0=/\\(\\)?/g,mb=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,La=/\w*$/,gb=/^[-+]0x[0-9a-f]+$/i,_b=/^0b[01]+$/i,vb=/^\[object .+?Constructor\]$/,yb=/^0o[0-7]+$/i,P0=/^(?:0|[1-9]\d*)$/,bb=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,fc=/($^)/,O0=/['\n\r\u2028\u2029\\]/g,Rs="\\ud800-\\udfff",L0="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Je="\\u2700-\\u27bf",N0="a-z\\xdf-\\xf6\\xf8-\\xff",Ip="A-Z\\xc0-\\xd6\\xd8-\\xde",Fp="\\ufe0e\\ufe0f",Uh="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Xr="["+Rs+"]",zh="["+Uh+"]",vu="["+L0+"]",tn="\\d+",dd="["+Je+"]",Rp="["+N0+"]",ho="[^"+Rs+Uh+tn+Je+N0+Ip+"]",yu="\\ud83c[\\udffb-\\udfff]",Ii="[^"+Rs+"]",$s="(?:\\ud83c[\\udde6-\\uddff]){2}",kr="[\\ud800-\\udbff][\\udc00-\\udfff]",ud="["+Ip+"]",qs="(?:"+Rp+"|"+ho+")",hd="(?:"+ud+"|"+ho+")",Gh="(?:['\u2019](?:d|ll|m|re|s|t|ve))?",jh="(?:['\u2019](?:D|LL|M|RE|S|T|VE))?",Op="(?:"+vu+"|"+yu+")?",Wh="["+Fp+"]?",xe=Wh+Op+"(?:\\u200d(?:"+[Ii,$s,kr].join("|")+")"+Wh+Op+")*",Lp="(?:"+[dd,$s,kr].join("|")+")"+xe,hn="(?:"+[Ii+vu+"?",vu,$s,kr,Xr].join("|")+")",bu=RegExp("['\u2019]","g"),Ut=RegExp(vu,"g"),jc=RegExp(yu+"(?="+yu+")|"+hn+xe,"g"),V0=RegExp([ud+"?"+Rp+"+"+Gh+"(?="+[zh,ud,"$"].join("|")+")",hd+"+"+jh+"(?="+[zh,ud+qs,"$"].join("|")+")",ud+"?"+qs+"+"+Gh,ud+"+"+jh,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",tn,Lp].join("|"),"g"),H0=RegExp("[\\u200d"+Rs+L0+Fp+"]"),U0=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,mc=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],ko=-1,Xi={};Xi[Fh]=Xi[ld]=Xi[Rh]=Xi[Ph]=Xi[Cp]=Xi[Oh]=Xi[Lh]=Xi[Nh]=Xi[Bh]=!0,Xi[co]=Xi[dc]=Xi[hc]=Xi[Fs]=Xi[Cl]=Xi[_t]=Xi[zc]=Xi[hu]=Xi[lo]=Xi[ad]=Xi[Oa]=Xi[ur]=Xi[qo]=Xi[cd]=Xi[uc]=!1;var Ki={};Ki[co]=Ki[dc]=Ki[hc]=Ki[Cl]=Ki[Fs]=Ki[_t]=Ki[Fh]=Ki[ld]=Ki[Rh]=Ki[Ph]=Ki[Cp]=Ki[lo]=Ki[ad]=Ki[Oa]=Ki[ur]=Ki[qo]=Ki[cd]=Ki[Ih]=Ki[Oh]=Ki[Lh]=Ki[Nh]=Ki[Bh]=!0,Ki[zc]=Ki[hu]=Ki[uc]=!1;var xu={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},$h=parseFloat,fr=parseInt,qh="object"==typeof global&&global&&global.Object===Object&&global,Ba="object"==typeof self&&self&&self.Object===Object&&self,pr=qh||Ba||Function("return this")(),Np=ka&&!ka.nodeType&&ka,Ln=Np&&Aa&&!Aa.nodeType&&Aa,Bp=Ln&&Ln.exports===Np,wu=Bp&&qh.process,fo=function(){try{return Ln&&Ln.require&&Ln.require("util").types||wu&&wu.binding&&wu.binding("util")}catch{}}(),Mt=fo&&fo.isArrayBuffer,Vp=fo&&fo.isDate,Kh=fo&&fo.isMap,ut=fo&&fo.isRegExp,Yi=fo&&fo.isSet,Ei=fo&&fo.isTypedArray;function Ni(we,Ge,Fe){switch(Fe.length){case 0:return we.call(Ge);case 1:return we.call(Ge,Fe[0]);case 2:return we.call(Ge,Fe[0],Fe[1]);case 3:return we.call(Ge,Fe[0],Fe[1],Fe[2])}return we.apply(Ge,Fe)}function Ps(we,Ge,Fe,Ft){for(var kn=-1,qn=null==we?0:we.length;++kn-1}function Zi(we,Ge,Fe){for(var Ft=-1,kn=null==we?0:we.length;++Ft-1;);return Fe}function gs(we,Ge){for(var Fe=we.length;Fe--&&pa(Ge,we[Fe],0)>-1;);return Fe}var go=Qr({\u00c0:"A",\u00c1:"A",\u00c2:"A",\u00c3:"A",\u00c4:"A",\u00c5:"A",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u00e3:"a",\u00e4:"a",\u00e5:"a",\u00c7:"C",\u00e7:"c",\u00d0:"D",\u00f0:"d",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u00cb:"E",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u00eb:"e",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u00cf:"I",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u00ef:"i",\u00d1:"N",\u00f1:"n",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u00d5:"O",\u00d6:"O",\u00d8:"O",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u00f5:"o",\u00f6:"o",\u00f8:"o",\u00d9:"U",\u00da:"U",\u00db:"U",\u00dc:"U",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u00fc:"u",\u00dd:"Y",\u00fd:"y",\u00ff:"y",\u00c6:"Ae",\u00e6:"ae",\u00de:"Th",\u00fe:"th",\u00df:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u010e:"D",\u0110:"D",\u010f:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011a:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011b:"e",\u011c:"G",\u011e:"G",\u0120:"G",\u0122:"G",\u011d:"g",\u011f:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012a:"I",\u012c:"I",\u012e:"I",\u0130:"I",\u0129:"i",\u012b:"i",\u012d:"i",\u012f:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013b:"L",\u013d:"L",\u013f:"L",\u0141:"L",\u013a:"l",\u013c:"l",\u013e:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014a:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014b:"n",\u014c:"O",\u014e:"O",\u0150:"O",\u014d:"o",\u014f:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015a:"S",\u015c:"S",\u015e:"S",\u0160:"S",\u015b:"s",\u015d:"s",\u015f:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016a:"U",\u016c:"U",\u016e:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016b:"u",\u016d:"u",\u016f:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017b:"Z",\u017d:"Z",\u017a:"z",\u017c:"z",\u017e:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017f:"s"}),Yo=Qr({"&":"&","<":"<",">":">",'"':""","'":"'"});function Vr(we){return"\\"+xu[we]}function ga(we){return H0.test(we)}function Fr(we){var Ge=-1,Fe=Array(we.size);return we.forEach(function(Ft,kn){Fe[++Ge]=[kn,Ft]}),Fe}function ir(we,Ge){return function(Fe){return we(Ge(Fe))}}function _c(we,Ge){for(var Fe=-1,Ft=we.length,kn=0,qn=[];++Fe",""":'"',"'":"'"}),md=function we(Ge){var d,Fe=(Ge=null==Ge?pr:md.defaults(pr.Object(),Ge,md.pick(pr,mc))).Array,Ft=Ge.Date,kn=Ge.Error,qn=Ge.Function,mr=Ge.Math,Cn=Ge.Object,Su=Ge.RegExp,j0=Ge.String,vo=Ge.TypeError,vc=Fe.prototype,Wc=Cn.prototype,$c=Ge["__core-js_shared__"],_d=qn.prototype.toString,Nn=Wc.hasOwnProperty,vd=0,He=(d=/[^.]+$/.exec($c&&$c.keys&&$c.keys.IE_PROTO||""))?"Symbol(src)_1."+d:"",Zt=Wc.toString,Mb=_d.call(Cn),Jh=pr._,Xs=Su("^"+_d.call(Nn).replace(Dl,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),yd=Bp?Ge.Buffer:le,Ha=Ge.Symbol,yc=Ge.Uint8Array,Os=yd?yd.allocUnsafe:le,rn=ir(Cn.getPrototypeOf,Cn),bd=Cn.create,l=Wc.propertyIsEnumerable,h=vc.splice,f=Ha?Ha.isConcatSpreadable:le,_=Ha?Ha.iterator:le,b=Ha?Ha.toStringTag:le,E=function(){try{var d=Bl(Cn,"defineProperty");return d({},"",{}),d}catch{}}(),M=Ge.clearTimeout!==pr.clearTimeout&&Ge.clearTimeout,D=Ft&&Ft.now!==pr.Date.now&&Ft.now,F=Ge.setTimeout!==pr.setTimeout&&Ge.setTimeout,P=mr.ceil,U=mr.floor,z=Cn.getOwnPropertySymbols,I=yd?yd.isBuffer:le,C=Ge.isFinite,B=vc.join,R=ir(Cn.keys,Cn),V=mr.max,L=mr.min,$=Ft.now,J=Ge.parseInt,Q=mr.random,te=vc.reverse,Se=Bl(Ge,"DataView"),Ae=Bl(Ge,"Map"),j=Bl(Ge,"Promise"),q=Bl(Ge,"Set"),ee=Bl(Ge,"WeakMap"),re=Bl(Cn,"create"),ue=ee&&new ee,be={},ce=Hl(Se),pe=Hl(Ae),ve=Hl(j),Ie=Hl(q),Bt=Hl(ee),Nt=Ha?Ha.prototype:le,Lt=Nt?Nt.valueOf:le,Rn=Nt?Nt.toString:le;function Y(d){if(Cr(d)&&!yn(d)&&!(d instanceof ln)){if(d instanceof Fi)return d;if(Nn.call(d,"__wrapped__"))return nM(d)}return new Fi(d)}var ui=function(){function d(){}return function(m){if(!_r(m))return{};if(bd)return bd(m);d.prototype=m;var S=new d;return d.prototype=le,S}}();function oi(){}function Fi(d,m){this.__wrapped__=d,this.__actions__=[],this.__chain__=!!m,this.__index__=0,this.__values__=le}function ln(d){this.__wrapped__=d,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Fn,this.__views__=[]}function Kn(d){var m=-1,S=null==d?0:d.length;for(this.clear();++m=m?d:m)),d}function Zo(d,m,S,O,W,Z){var de,me=m&Tn,Ee=m&Sl,qe=m&_e;if(S&&(de=W?S(d,O,W,Z):S(d)),de!==le)return de;if(!_r(d))return d;var Ye=yn(d);if(Ye){if(de=function YE(d){var m=d.length,S=new d.constructor(m);return m&&"string"==typeof d[0]&&Nn.call(d,"index")&&(S.index=d.index,S.input=d.input),S}(d),!me)return Bs(d,de)}else{var nt=Vs(d),wt=nt==hu||nt==Ep;if(zl(d))return Cd(d,me);if(nt==Oa||nt==co||wt&&!W){if(de=Ee||wt?{}:sm(d),!me)return Ee?function qb(d,m){return $a(d,Jb(d),m)}(d,function $p(d,m){return d&&$a(m,ns(m),d)}(de,d)):function BE(d,m){return $a(d,rm(d),m)}(d,Tb(de,d))}else{if(!Ki[nt])return W?d:{};de=function h_(d,m,S){var O=d.constructor;switch(m){case hc:return Dd(d);case Fs:case _t:return new O(+d);case Cl:return function OE(d,m){var S=m?Dd(d.buffer):d.buffer;return new d.constructor(S,d.byteOffset,d.byteLength)}(d,S);case Fh:case ld:case Rh:case Ph:case Cp:case Oh:case Lh:case Nh:case Bh:return jb(d,S);case lo:return new O;case ad:case cd:return new O(d);case ur:return function tF(d){var m=new d.constructor(d.source,La.exec(d));return m.lastIndex=d.lastIndex,m}(d);case qo:return new O;case Ih:return function Gb(d){return Lt?Cn(Lt.call(d)):{}}(d)}}(d,nt,me)}}Z||(Z=new xc);var Ht=Z.get(d);if(Ht)return Ht;Z.set(d,de),B_(d)?d.forEach(function(dn){de.add(Zo(dn,m,S,dn,d,Z))}):Od(d)&&d.forEach(function(dn,ri){de.set(ri,Zo(dn,m,S,ri,d,Z))});var zn=Ye?le:(qe?Ee?Qs:u_:Ee?ns:bs)(d);return Zr(zn||d,function(dn,ri){zn&&(dn=d[ri=dn]),Eu(de,ri,Zo(dn,m,S,ri,d,Z))}),de}function kb(d,m,S){var O=S.length;if(null==d)return!O;for(d=Cn(d);O--;){var W=S[O],de=d[W];if(de===le&&!(W in d)||!(0,m[W])(de))return!1}return!0}function za(d,m,S){if("function"!=typeof d)throw new vo(_i);return Ad(function(){d.apply(le,S)},m)}function tf(d,m,S,O){var W=-1,Z=Sn,de=!0,me=d.length,Ee=[],qe=m.length;if(!me)return Ee;S&&(m=si(m,Ys(S))),O?(Z=Zi,de=!1):m.length>=ps&&(Z=Io,de=!1,m=new va(m));e:for(;++W-1},$i.prototype.set=function qc(d,m){var S=this.__data__,O=ef(S,d);return O<0?(++this.size,S.push([d,m])):S[O][1]=m,this},Ro.prototype.clear=function wd(){this.size=0,this.__data__={hash:new Kn,map:new(Ae||$i),string:new Kn}},Ro.prototype.delete=function Bi(d){var m=Nl(this,d).delete(d);return this.size-=m?1:0,m},Ro.prototype.get=function Po(d){return Nl(this,d).get(d)},Ro.prototype.has=function vi(d){return Nl(this,d).has(d)},Ro.prototype.set=function bc(d,m){var S=Nl(this,d),O=S.size;return S.set(d,m),this.size+=S.size==O?0:1,this},va.prototype.add=va.prototype.push=function Qh(d){return this.__data__.set(d,ao),this},va.prototype.has=function wE(d){return this.__data__.has(d)},xc.prototype.clear=function $0(){this.__data__=new $i,this.size=0},xc.prototype.delete=function KI(d){var m=this.__data__,S=m.delete(d);return this.size=m.size,S},xc.prototype.get=function SE(d){return this.__data__.get(d)},xc.prototype.has=function EE(d){return this.__data__.has(d)},xc.prototype.set=function YI(d,m){var S=this.__data__;if(S instanceof $i){var O=S.__data__;if(!Ae||O.length0&&S(me)?m>1?ys(me,m-1,S,O,W):Ks(W,me):O||(W[W.length]=me)}return W}var Kp=Kb(),K0=Kb(!0);function ja(d,m){return d&&Kp(d,m,bs)}function Y0(d,m){return d&&K0(d,m,bs)}function Ed(d,m){return xt(m,function(S){return nl(d[S])})}function Jo(d,m){for(var S=0,O=(m=Wa(m,d)).length;null!=d&&Sm}function Tu(d,m){return null!=d&&Nn.call(d,m)}function CE(d,m){return null!=d&&m in Cn(d)}function nf(d,m,S){for(var O=S?Zi:Sn,W=d[0].length,Z=d.length,de=Z,me=Fe(Z),Ee=1/0,qe=[];de--;){var Ye=d[de];de&&m&&(Ye=si(Ye,Ys(m))),Ee=L(Ye.length,Ee),me[de]=!S&&(m||W>=120&&Ye.length>=120)?new va(de&&Ye):le}Ye=d[0];var nt=-1,wt=me[0];e:for(;++nt=me?Ee:Ee*("desc"==S[O]?-1:1)}return d.index-m.index}(Z,de,S)})}function Nb(d,m,S){for(var O=-1,W=m.length,Z={};++O-1;)me!==d&&h.call(me,Ee,1),h.call(d,Ee,1);return d}function J0(d,m){for(var S=d?m.length:0,O=S-1;S--;){var W=m[S];if(S==O||W!==Z){var Z=W;Jc(W)?h.call(d,W,1):Ou(d,W)}}return d}function Ru(d,m){return d+U(Q()*(m-d+1))}function Q0(d,m){var S="";if(!d||m<1||m>Qn)return S;do{m%2&&(S+=d),(m=U(m/2))&&(d+=d)}while(m);return S}function ti(d,m){return g_(nx(d,m,Lo),d+"")}function RE(d){return jp(ju(d))}function QI(d,m){var S=ju(d);return gf(S,Cu(m,0,S.length))}function Ns(d,m,S,O){if(!_r(d))return d;for(var W=-1,Z=(m=Wa(m,d)).length,de=Z-1,me=d;null!=me&&++WW?0:W+m),(S=S>W?W:S)<0&&(S+=W),W=m>S?0:S-m>>>0,m>>>=0;for(var Z=Fe(W);++O>>1,de=d[Z];null!==de&&!ia(de)&&(S?de<=m:de=ps){var qe=m?null:jE(d);if(qe)return Yh(qe);de=!1,W=Io,Ee=new va}else Ee=m?[]:me;e:for(;++O=O?d:Qo(d,m,S)}var zb=M||function(d){return pr.clearTimeout(d)};function Cd(d,m){if(m)return d.slice();var S=d.length,O=Os?Os(S):new d.constructor(S);return d.copy(O),O}function Dd(d){var m=new d.constructor(d.byteLength);return new yc(m).set(new yc(d)),m}function jb(d,m){var S=m?Dd(d.buffer):d.buffer;return new d.constructor(S,d.byteOffset,d.length)}function LE(d,m){if(d!==m){var S=d!==le,O=null===d,W=d==d,Z=ia(d),de=m!==le,me=null===m,Ee=m==m,qe=ia(m);if(!me&&!qe&&!Z&&d>m||Z&&de&&Ee&&!me&&!qe||O&&de&&Ee||!S&&Ee||!W)return 1;if(!O&&!Z&&!qe&&d1?S[W-1]:le,de=W>2?S[2]:le;for(Z=d.length>3&&"function"==typeof Z?(W--,Z):le,de&&yo(S[0],S[1],de)&&(Z=W<3?le:Z,W=1),m=Cn(m);++O-1?W[Z?m[de]:de]:le}}function zE(d){return Zc(function(m){var S=m.length,O=S,W=Fi.prototype.thru;for(d&&m.reverse();O--;){var Z=m[O];if("function"!=typeof Z)throw new vo(_i);if(W&&!de&&"wrapper"==hf(Z))var de=new Fi([],!0)}for(O=de?O:S;++O1&&yi.reverse(),Ye&&Eeme))return!1;var qe=Z.get(d),Ye=Z.get(m);if(qe&&Ye)return qe==m&&Ye==d;var nt=-1,wt=!0,Ht=S&di?new va:le;for(Z.set(d,m),Z.set(m,d);++nt-1&&d%1==0&&d1?"& ":"")+m[O],m=m.join(S>2?", ":" "),d.replace(F0,"{\n/* [wrapped with "+m+"] */\n")}(O,function tM(d,m){return Zr(lc,function(S){var O="_."+S[0];m&S[1]&&!Sn(d,O)&&d.push(O)}),d.sort()}(function Qb(d){var m=d.match(gu);return m?m[1].split(uo):[]}(O),S)))}function __(d){var m=0,S=0;return function(){var O=$(),W=cn-(O-S);if(S=O,W>0){if(++m>=du)return arguments[0]}else m=0;return d.apply(le,arguments)}}function gf(d,m){var S=-1,O=d.length,W=O-1;for(m=m===le?O:m;++S1?d[m-1]:le;return S="function"==typeof S?(d.pop(),S):le,_f(d,S)});function _m(d){var m=Y(d);return m.__chain__=!0,m}function E_(d,m){return m(d)}var oF=Zc(function(d){var m=d.length,S=m?d[0]:0,O=this.__wrapped__,W=function(Z){return Mu(Z,d)};return!(m>1||this.__actions__.length)&&O instanceof ln&&Jc(S)?((O=O.slice(S,+S+(m?1:0))).__actions__.push({func:E_,args:[W],thisArg:le}),new Fi(O,this.__chain__).thru(function(Z){return m&&!Z.length&&Z.push(le),Z})):this.thru(W)}),Ex=n_(function(d,m,S){Nn.call(d,S)?++d[S]:Ua(d,S,1)}),Ri=UE(um),AM=UE(hm);function Cx(d,m){return(yn(d)?Zr:Ga)(d,Ot(m,3))}function Dx(d,m){return(yn(d)?po:qp)(d,Ot(m,3))}var IM=n_(function(d,m,S){Nn.call(d,S)?d[S].push(m):Ua(d,S,[m])}),Tx=ti(function(d,m,S){var O=-1,W="function"==typeof m,Z=Oo(d)?Fe(d.length):[];return Ga(d,function(de){Z[++O]=W?Ni(m,de,S):Au(de,m,S)}),Z}),aF=n_(function(d,m,S){Ua(d,S,m)});function C_(d,m){return(yn(d)?si:IE)(d,Ot(m,3))}var ym=n_(function(d,m,S){d[S?0:1].push(m)},function(){return[[],[]]}),cF=ti(function(d,m){if(null==d)return[];var S=m.length;return S>1&&yo(d,m[0],m[1])?m=[]:S>2&&yo(m[0],m[1],m[2])&&(m=[m[0]]),Xp(d,ys(m,1),[])}),Hu=D||function(){return pr.Date.now()};function bm(d,m,S){return m=S?le:m,Xc(d,un,le,le,le,le,m=d&&null==m?d.length:m)}function T_(d,m){var S;if("function"!=typeof m)throw new vo(_i);return d=Un(d),function(){return--d>0&&(S=m.apply(this,arguments)),d<=1&&(m=le),S}}var xm=ti(function(d,m,S){var O=ks;if(S.length){var W=_c(S,Ll(xm));O|=Yr}return Xc(d,O,m,S,W)}),Ul=ti(function(d,m,S){var O=ks|Fa;if(S.length){var W=_c(S,Ll(Ul));O|=Yr}return Xc(m,O,d,S,W)});function bf(d,m,S){var O,W,Z,de,me,Ee,qe=0,Ye=!1,nt=!1,wt=!0;if("function"!=typeof d)throw new vo(_i);function Ht(Pr){var Ya=O,Xa=W;return O=W=le,qe=Pr,de=d.apply(Xa,Ya)}function dn(Pr){var Ya=Pr-Ee;return Ee===le||Ya>=m||Ya<0||nt&&Pr-qe>=Z}function ri(){var Pr=Hu();if(dn(Pr))return yi(Pr);me=Ad(ri,function zn(Pr){var D1=m-(Pr-Ee);return nt?L(D1,Z-(Pr-qe)):D1}(Pr))}function yi(Pr){return me=le,wt&&O?Ht(Pr):(O=W=le,de)}function to(){var Pr=Hu(),Ya=dn(Pr);if(O=arguments,W=this,Ee=Pr,Ya){if(me===le)return function pn(Pr){return qe=Pr,me=Ad(ri,m),Ye?Ht(Pr):de}(Ee);if(nt)return zb(me),me=Ad(ri,m),Ht(Ee)}return me===le&&(me=Ad(ri,m)),de}return m=wa(m)||0,_r(S)&&(Ye=!!S.leading,Z=(nt="maxWait"in S)?V(wa(S.maxWait)||0,m):Z,wt="trailing"in S?!!S.trailing:wt),to.cancel=function No(){me!==le&&zb(me),qe=0,O=Ee=W=me=le},to.flush=function Bo(){return me===le?de:yi(Hu())},to}var OM=ti(function(d,m){return za(d,1,m)}),A_=ti(function(d,m,S){return za(d,wa(m)||0,S)});function na(d,m){if("function"!=typeof d||null!=m&&"function"!=typeof m)throw new vo(_i);var S=function(){var O=arguments,W=m?m.apply(this,O):O[0],Z=S.cache;if(Z.has(W))return Z.get(W);var de=d.apply(this,O);return S.cache=Z.set(W,de)||Z,de};return S.cache=new(na.Cache||Ro),S}function xf(d){if("function"!=typeof d)throw new vo(_i);return function(){var m=arguments;switch(m.length){case 0:return!d.call(this);case 1:return!d.call(this,m[0]);case 2:return!d.call(this,m[0],m[1]);case 3:return!d.call(this,m[0],m[1],m[2])}return!d.apply(this,m)}}na.Cache=Ro;var LM=Ub(function(d,m){var S=(m=1==m.length&&yn(m[0])?si(m[0],Ys(Ot())):si(ys(m,1),Ys(Ot()))).length;return ti(function(O){for(var W=-1,Z=L(O.length,S);++W=m}),Rd=Kc(function(){return arguments}())?Kc:function(d){return Cr(d)&&Nn.call(d,"callee")&&!l.call(d,"callee")},yn=Fe.isArray,el=Mt?Ys(Mt):function ku(d){return Cr(d)&&Zs(d)==hc};function Oo(d){return null!=d&&Em(d.length)&&!nl(d)}function Rr(d){return Cr(d)&&Oo(d)}var zl=I||Sf,P_=Vp?Ys(Vp):function Iu(d){return Cr(d)&&Zs(d)==_t};function N_(d){if(!Cr(d))return!1;var m=Zs(d);return m==zc||m==uu||"string"==typeof d.message&&"string"==typeof d.name&&!Gu(d)}function nl(d){if(!_r(d))return!1;var m=Zs(d);return m==hu||m==Ep||m==$o||m==dr}function Bx(d){return"number"==typeof d&&d==Un(d)}function Em(d){return"number"==typeof d&&d>-1&&d%1==0&&d<=Qn}function _r(d){var m=typeof d;return null!=d&&("object"==m||"function"==m)}function Cr(d){return null!=d&&"object"==typeof d}var Od=Kh?Ys(Kh):function X0(d){return Cr(d)&&Vs(d)==lo};function qM(d){return"number"==typeof d||Cr(d)&&Zs(d)==ad}function Gu(d){if(!Cr(d)||Zs(d)!=Oa)return!1;var m=rn(d);if(null===m)return!0;var S=Nn.call(m,"constructor")&&m.constructor;return"function"==typeof S&&S instanceof S&&_d.call(S)==Mb}var Mm=ut?Ys(ut):function AE(d){return Cr(d)&&Zs(d)==ur},B_=Yi?Ys(Yi):function Ze(d){return Cr(d)&&Vs(d)==qo};function Cm(d){return"string"==typeof d||!yn(d)&&Cr(d)&&Zs(d)==cd}function ia(d){return"symbol"==typeof d||Cr(d)&&Zs(d)==Ih}var eo=Ei?Ys(Ei):function XI(d){return Cr(d)&&Em(d.length)&&!!Xi[Zs(d)]},ZM=df(Lb),JM=df(function(d,m){return d<=m});function Ux(d){if(!d)return[];if(Oo(d))return Cm(d)?_o(d):Bs(d);if(_&&d[_])return function Hp(we){for(var Ge,Fe=[];!(Ge=we.next()).done;)Fe.push(Ge.value);return Fe}(d[_]());var m=Vs(d);return(m==lo?Fr:m==qo?Yh:ju)(d)}function Mc(d){return d?(d=wa(d))===$t||d===-$t?(d<0?-1:1)*In:d==d?d:0:0===d?d:0}function Un(d){var m=Mc(d),S=m%1;return m==m?S?m-S:m:0}function zx(d){return d?Cu(Un(d),0,Fn):0}function wa(d){if("number"==typeof d)return d;if(ia(d))return fn;if(_r(d)){var m="function"==typeof d.valueOf?d.valueOf():d;d=_r(m)?m+"":m}if("string"!=typeof d)return 0===d?d:+d;d=d.replace(wi,"");var S=_b.test(d);return S||yb.test(d)?fr(d.slice(2),S?2:8):gb.test(d)?fn:+d}function Dn(d){return $a(d,ns(d))}function Pi(d){return null==d?"":ea(d)}var Gx=Td(function(d,m){if(Nu(m)||Oo(m))$a(m,bs(m),d);else for(var S in m)Nn.call(m,S)&&Eu(d,S,m[S])}),jx=Td(function(d,m){$a(m,ns(m),d)}),Dm=Td(function(d,m,S,O){$a(m,ns(m),d,O)}),Wx=Td(function(d,m,S,O){$a(m,bs(m),d,O)}),QM=Zc(Mu),eC=ti(function(d,m){d=Cn(d);var S=-1,O=m.length,W=O>2?m[2]:le;for(W&&yo(m[0],m[1],W)&&(O=1);++S1),Z}),$a(d,Qs(d),S),O&&(S=Zo(S,Tn|Sl|_e,WE));for(var W=m.length;W--;)Ou(S,m[W]);return S}),aC=Zc(function(d,m){return null==d?{}:function rf(d,m){return Nb(d,m,function(S,O){return Xx(d,O)})}(d,m)});function t1(d,m){if(null==d)return{};var S=si(Qs(d),function(O){return[O]});return m=Ot(m),Nb(d,S,function(O,W){return m(O,W[0])})}var r1=Yb(bs),U_=Yb(ns);function ju(d){return null==d?[]:Fl(d,bs(d))}var o1=cf(function(d,m,S){return m=m.toLowerCase(),d+(S?a1(m):m)});function a1(d){return Im(Pi(d).toLowerCase())}function c1(d){return(d=Pi(d))&&d.replace(bb,go).replace(Ut,"")}var wf=cf(function(d,m,S){return d+(S?"-":"")+m.toLowerCase()}),W_=cf(function(d,m,S){return d+(S?" ":"")+m.toLowerCase()}),km=em("toLowerCase"),uC=cf(function(d,m,S){return d+(S?"_":"")+m.toLowerCase()}),u1=cf(function(d,m,S){return d+(S?" ":"")+Im(m)}),X_=cf(function(d,m,S){return d+(S?" ":"")+m.toUpperCase()}),Im=em("toUpperCase");function m1(d,m,S){return d=Pi(d),(m=S?le:m)===le?function Fo(we){return U0.test(we)}(d)?function Zh(we){return we.match(V0)||[]}(d):function Hn(we){return we.match(pb)||[]}(d):d.match(m)||[]}var g1=ti(function(d,m){try{return Ni(d,le,m)}catch(S){return N_(S)?S:new kn(S)}}),_C=Zc(function(d,m){return Zr(m,function(S){S=qa(S),Ua(d,S,xm(d[S],d))}),d});function Z_(d){return function(){return d}}var yC=zE(),bC=zE(!0);function Lo(d){return d}function Q_(d){return kE("function"==typeof d?d:Zo(d,Tn))}var ev=ti(function(d,m){return function(S){return Au(S,d,m)}}),wC=ti(function(d,m){return function(S){return Au(d,S,m)}});function tv(d,m,S){var O=bs(m),W=Ed(m,O);null==S&&(!_r(m)||!W.length&&O.length)&&(S=m,m=d,d=this,W=Ed(m,bs(m)));var Z=!(_r(S)&&"chain"in S&&!S.chain),de=nl(d);return Zr(W,function(me){var Ee=m[me];d[me]=Ee,de&&(d.prototype[me]=function(){var qe=this.__chain__;if(Z||qe){var Ye=d(this.__wrapped__);return(Ye.__actions__=Bs(this.__actions__)).push({func:Ee,args:arguments,thisArg:d}),Ye.__chain__=qe,Ye}return Ee.apply(d,Ks([this.value()],arguments))})}),d}function nv(){}var EC=o_(si),iv=o_(Nr),MC=o_(Ji);function y1(d){return pf(d)?gc(qa(d)):function ya(d){return function(m){return Jo(m,d)}}(d)}var rv=c_(),Rm=c_(!0);function b1(){return[]}function Sf(){return!1}var rl=s_(function(d,m){return d+m},0),Pm=Js("ceil"),Om=s_(function(d,m){return d/m},1),Ef=Js("floor"),AC=s_(function(d,m){return d*m},1),yF=Js("round"),kC=s_(function(d,m){return d-m},0);return Y.after=function PM(d,m){if("function"!=typeof m)throw new vo(_i);return d=Un(d),function(){if(--d<1)return m.apply(this,arguments)}},Y.ary=bm,Y.assign=Gx,Y.assignIn=jx,Y.assignInWith=Dm,Y.assignWith=Wx,Y.at=QM,Y.before=T_,Y.bind=xm,Y.bindAll=_C,Y.bindKey=Ul,Y.castArray=function Lx(){if(!arguments.length)return[];var d=arguments[0];return yn(d)?d:[d]},Y.chain=_m,Y.chunk=function cm(d,m,S){m=(S?yo(d,m,S):m===le)?1:V(Un(m),0);var O=null==d?0:d.length;if(!O||m<1)return[];for(var W=0,Z=0,de=Fe(P(O/m));WW?0:W+S),(O=O===le||O>W?W:Un(O))<0&&(O+=W),O=S>O?0:zx(O);S>>0)?(d=Pi(d))&&("string"==typeof m||null!=m&&!Mm(m))&&!(m=ea(m))&&ga(d)?Ol(_o(d),0,S):d.split(m,S):[]},Y.spread=function BM(d,m){if("function"!=typeof d)throw new vo(_i);return m=null==m?0:V(Un(m),0),ti(function(S){var O=S[m],W=Ol(S,0,m);return O&&Ks(W,O),Ni(d,this,W)})},Y.tail=function Ec(d){var m=null==d?0:d.length;return m?Qo(d,1,m):[]},Y.take=function mM(d,m,S){return d&&d.length?Qo(d,0,(m=S||m===le?1:Un(m))<0?0:m):[]},Y.takeRight=function gM(d,m,S){var O=null==d?0:d.length;return O?Qo(d,(m=O-(m=S||m===le?1:Un(m)))<0?0:m,O):[]},Y.takeRightWhile=function _M(d,m){return d&&d.length?ba(d,Ot(m,3),!1,!0):[]},Y.takeWhile=function vM(d,m){return d&&d.length?ba(d,Ot(m,3)):[]},Y.tap=function S_(d,m){return m(d),d},Y.throttle=function VM(d,m,S){var O=!0,W=!0;if("function"!=typeof d)throw new vo(_i);return _r(S)&&(O="leading"in S?!!S.leading:O,W="trailing"in S?!!S.trailing:W),bf(d,m,{leading:O,maxWait:m,trailing:W})},Y.thru=E_,Y.toArray=Ux,Y.toPairs=r1,Y.toPairsIn=U_,Y.toPath=function E1(d){return yn(d)?si(d,qa):ia(d)?[d]:Bs(Vl(Pi(d)))},Y.toPlainObject=Dn,Y.transform=function s1(d,m,S){var O=yn(d),W=O||zl(d)||eo(d);if(m=Ot(m,4),null==S){var Z=d&&d.constructor;S=W?O?new Z:[]:_r(d)&&nl(Z)?ui(rn(d)):{}}return(W?Zr:ja)(d,function(de,me,Ee){return m(S,de,me,Ee)}),S},Y.unary=function R_(d){return bm(d,1)},Y.union=yM,Y.unionBy=bM,Y.unionWith=vx,Y.uniq=function xM(d){return d&&d.length?Sc(d):[]},Y.uniqBy=function wM(d,m){return d&&d.length?Sc(d,Ot(m,2)):[]},Y.uniqWith=function SM(d,m){return m="function"==typeof m?m:le,d&&d.length?Sc(d,le,m):[]},Y.unset=function z_(d,m){return null==d||Ou(d,m)},Y.unzip=w_,Y.unzipWith=_f,Y.update=function mF(d,m,S){return null==d?d:af(d,m,Md(S))},Y.updateWith=function G_(d,m,S,O){return O="function"==typeof O?O:le,null==d?d:af(d,m,Md(S),O)},Y.values=ju,Y.valuesIn=function gF(d){return null==d?[]:Fl(d,ns(d))},Y.without=Qc,Y.words=m1,Y.wrap=function HM(d,m){return I_(Md(m),d)},Y.xor=vf,Y.xorBy=yx,Y.xorWith=bx,Y.zip=xx,Y.zipObject=function iF(d,m){return Hb(d||[],m||[],Eu)},Y.zipObjectDeep=function rF(d,m){return Hb(d||[],m||[],Ns)},Y.zipWith=sF,Y.entries=r1,Y.entriesIn=U_,Y.extend=jx,Y.extendWith=Dm,tv(Y,Y),Y.add=rl,Y.attempt=g1,Y.camelCase=o1,Y.capitalize=a1,Y.ceil=Pm,Y.clamp=function ie(d,m,S){return S===le&&(S=m,m=le),S!==le&&(S=(S=wa(S))==S?S:0),m!==le&&(m=(m=wa(m))==m?m:0),Cu(wa(d),m,S)},Y.clone=function UM(d){return Zo(d,_e)},Y.cloneDeep=function lF(d){return Zo(d,Tn|_e)},Y.cloneDeepWith=function zM(d,m){return Zo(d,Tn|_e,m="function"==typeof m?m:le)},Y.cloneWith=function Nx(d,m){return Zo(d,_e,m="function"==typeof m?m:le)},Y.conformsTo=function Fd(d,m){return null==m||kb(d,m,bs(m))},Y.deburr=c1,Y.defaultTo=function J_(d,m){return null==d||d!=d?m:d},Y.divide=Om,Y.endsWith=function Am(d,m,S){d=Pi(d),m=ea(m);var O=d.length,W=S=S===le?O:Cu(Un(S),0,O);return(S-=m.length)>=0&&d.slice(S,W)==m},Y.eq=Ka,Y.escape=function Wu(d){return(d=Pi(d))&&Mi.test(d)?d.replace(fu,Yo):d},Y.escapeRegExp=function j_(d){return(d=Pi(d))&&wn.test(d)?d.replace(Dl,"\\$&"):d},Y.every=function M_(d,m,S){var O=yn(d)?Nr:Ib;return S&&yo(d,m,S)&&(m=le),O(d,Ot(m,3))},Y.find=Ri,Y.findIndex=um,Y.findKey=function hF(d,m){return fd(d,Ot(m,3),ja)},Y.findLast=AM,Y.findLastIndex=hm,Y.findLastKey=function qx(d,m){return fd(d,Ot(m,3),Y0)},Y.floor=Ef,Y.forEach=Cx,Y.forEachRight=Dx,Y.forIn=function Kx(d,m){return null==d?d:Kp(d,Ot(m,3),ns)},Y.forInRight=function ts(d,m){return null==d?d:K0(d,Ot(m,3),ns)},Y.forOwn=function nC(d,m){return d&&ja(d,Ot(m,3))},Y.forOwnRight=function V_(d,m){return d&&Y0(d,Ot(m,3))},Y.get=Yx,Y.gt=zu,Y.gte=_n,Y.has=function fF(d,m){return null!=d&&ex(d,m,Tu)},Y.hasIn=Xx,Y.head=hx,Y.identity=Lo,Y.includes=function FM(d,m,S,O){d=Oo(d)?d:ju(d),S=S&&!O?Un(S):0;var W=d.length;return S<0&&(S=V(W+S,0)),Cm(d)?S<=W&&d.indexOf(m,S)>-1:!!W&&pa(d,m,S)>-1},Y.indexOf=function oM(d,m,S){var O=null==d?0:d.length;if(!O)return-1;var W=null==S?0:Un(S);return W<0&&(W=V(O+W,0)),pa(d,m,W)},Y.inRange=function Gl(d,m,S){return m=Mc(m),S===le?(S=m,m=0):S=Mc(S),function or(d,m,S){return d>=L(m,S)&&d=-Qn&&d<=Qn},Y.isSet=B_,Y.isString=Cm,Y.isSymbol=ia,Y.isTypedArray=eo,Y.isUndefined=function YM(d){return d===le},Y.isWeakMap=function Hx(d){return Cr(d)&&Vs(d)==uc},Y.isWeakSet=function XM(d){return Cr(d)&&"[object WeakSet]"==Zs(d)},Y.join=function Vu(d,m){return null==d?"":B.call(d,m)},Y.kebabCase=wf,Y.last=xa,Y.lastIndexOf=function aM(d,m,S){var O=null==d?0:d.length;if(!O)return-1;var W=O;return S!==le&&(W=(W=Un(S))<0?V(O+W,0):L(W,O-1)),m==m?function Eb(we,Ge,Fe){for(var Ft=Fe+1;Ft--;)if(we[Ft]===Ge)return Ft;return Ft}(d,m,W):Va(d,Jr,W,!0)},Y.lowerCase=W_,Y.lowerFirst=km,Y.lt=ZM,Y.lte=JM,Y.max=function CC(d){return d&&d.length?Du(d,Lo,Yp):le},Y.maxBy=function M1(d,m){return d&&d.length?Du(d,Ot(m,2),Yp):le},Y.mean=function C1(d){return kl(d,Lo)},Y.meanBy=function DC(d,m){return kl(d,Ot(m,2))},Y.min=function TC(d){return d&&d.length?Du(d,Lo,Lb):le},Y.minBy=function Mf(d,m){return d&&d.length?Du(d,Ot(m,2),Lb):le},Y.stubArray=b1,Y.stubFalse=Sf,Y.stubObject=function vF(){return{}},Y.stubString=function x1(){return""},Y.stubTrue=function w1(){return!0},Y.multiply=AC,Y.nth=function nF(d,m){return d&&d.length?Hr(d,Un(m)):le},Y.noConflict=function v1(){return pr._===this&&(pr._=Jh),this},Y.noop=nv,Y.now=Hu,Y.pad=function l1(d,m,S){d=Pi(d);var O=(m=Un(m))?pd(d):0;if(!m||O>=m)return d;var W=(m-O)/2;return lf(U(W),S)+d+lf(P(W),S)},Y.padEnd=function $_(d,m,S){d=Pi(d);var O=(m=Un(m))?pd(d):0;return m&&Om){var O=d;d=m,m=O}if(S||d%1||m%1){var W=Q();return L(d+W*(m-d+$h("1e-"+((W+"").length-1))),m)}return Ru(d,m)},Y.reduce=function Ax(d,m,S){var O=yn(d)?Br:ma,W=arguments.length<3;return O(d,Ot(m,4),S,W,Ga)},Y.reduceRight=function kx(d,m,S){var O=yn(d)?Al:ma,W=arguments.length<3;return O(d,Ot(m,4),S,W,qp)},Y.repeat=function d1(d,m,S){return m=(S?yo(d,m,S):m===le)?1:Un(m),Q0(Pi(d),m)},Y.replace=function Y_(){var d=arguments,m=Pi(d[0]);return d.length<3?m:m.replace(d[1],d[2])},Y.result=function cC(d,m,S){var O=-1,W=(m=Wa(m,d)).length;for(W||(W=1,d=le);++OQn)return[];var S=Fn,O=L(d,Fn);m=Ot(m),d-=Fn;for(var W=Il(O,m);++S=Z)return d;var me=S-pd(O);if(me<1)return O;var Ee=de?Ol(de,0,me).join(""):d.slice(0,me);if(W===le)return Ee+O;if(de&&(me+=Ee.length-me),Mm(W)){if(d.slice(me).search(W)){var qe,Ye=Ee;for(W.global||(W=Su(W.source,Pi(La.exec(W))+"g")),W.lastIndex=0;qe=W.exec(Ye);)var nt=qe.index;Ee=Ee.slice(0,nt===le?me:nt)}}else if(d.indexOf(ea(W),me)!=me){var wt=Ee.lastIndexOf(W);wt>-1&&(Ee=Ee.slice(0,wt))}return Ee+O},Y.unescape=function _F(d){return(d=Pi(d))&&Tp.test(d)?d.replace(ki,Xh):d},Y.uniqueId=function sv(d){var m=++vd;return Pi(d)+m},Y.upperCase=X_,Y.upperFirst=Im,Y.each=Cx,Y.eachRight=Dx,Y.first=hx,tv(Y,function(){var d={};return ja(Y,function(m,S){Nn.call(Y.prototype,S)||(d[S]=m)}),d}(),{chain:!1}),Y.VERSION="4.17.19",Zr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(d){Y[d].placeholder=Y}),Zr(["drop","take"],function(d,m){ln.prototype[d]=function(S){S=S===le?1:V(Un(S),0);var O=this.__filtered__&&!m?new ln(this):this.clone();return O.__filtered__?O.__takeCount__=L(S,O.__takeCount__):O.__views__.push({size:L(S,Fn),type:d+(O.__dir__<0?"Right":"")}),O},ln.prototype[d+"Right"]=function(S){return this.reverse()[d](S).reverse()}}),Zr(["filter","map","takeWhile"],function(d,m){var S=m+1,O=1==S||3==S;ln.prototype[d]=function(W){var Z=this.clone();return Z.__iteratees__.push({iteratee:Ot(W,3),type:S}),Z.__filtered__=Z.__filtered__||O,Z}}),Zr(["head","last"],function(d,m){var S="take"+(m?"Right":"");ln.prototype[d]=function(){return this[S](1).value()[0]}}),Zr(["initial","tail"],function(d,m){var S="drop"+(m?"":"Right");ln.prototype[d]=function(){return this.__filtered__?new ln(this):this[S](1)}}),ln.prototype.compact=function(){return this.filter(Lo)},ln.prototype.find=function(d){return this.filter(d).head()},ln.prototype.findLast=function(d){return this.reverse().find(d)},ln.prototype.invokeMap=ti(function(d,m){return"function"==typeof d?new ln(this):this.map(function(S){return Au(S,d,m)})}),ln.prototype.reject=function(d){return this.filter(xf(Ot(d)))},ln.prototype.slice=function(d,m){d=Un(d);var S=this;return S.__filtered__&&(d>0||m<0)?new ln(S):(d<0?S=S.takeRight(-d):d&&(S=S.drop(d)),m!==le&&(S=(m=Un(m))<0?S.dropRight(-m):S.take(m-d)),S)},ln.prototype.takeRightWhile=function(d){return this.reverse().takeWhile(d).reverse()},ln.prototype.toArray=function(){return this.take(Fn)},ja(ln.prototype,function(d,m){var S=/^(?:filter|find|map|reject)|While$/.test(m),O=/^(?:head|last)$/.test(m),W=Y[O?"take"+("last"==m?"Right":""):m],Z=O||/^find/.test(m);W&&(Y.prototype[m]=function(){var de=this.__wrapped__,me=O?[1]:arguments,Ee=de instanceof ln,qe=me[0],Ye=Ee||yn(de),nt=function(ri){var yi=W.apply(Y,Ks([ri],me));return O&&wt?yi[0]:yi};Ye&&S&&"function"==typeof qe&&1!=qe.length&&(Ee=Ye=!1);var wt=this.__chain__,pn=Z&&!wt,zn=Ee&&!this.__actions__.length;if(!Z&&Ye){de=zn?de:new ln(this);var dn=d.apply(de,me);return dn.__actions__.push({func:E_,args:[nt],thisArg:le}),new Fi(dn,wt)}return pn&&zn?d.apply(this,me):(dn=this.thru(nt),pn?O?dn.value()[0]:dn.value():dn)})}),Zr(["pop","push","shift","sort","splice","unshift"],function(d){var m=vc[d],S=/^(?:push|sort|unshift)$/.test(d)?"tap":"thru",O=/^(?:pop|shift)$/.test(d);Y.prototype[d]=function(){var W=arguments;if(O&&!this.__chain__){var Z=this.value();return m.apply(yn(Z)?Z:[],W)}return this[S](function(de){return m.apply(yn(de)?de:[],W)})}}),ja(ln.prototype,function(d,m){var S=Y[m];if(S){var O=S.name+"";Nn.call(be,O)||(be[O]=[]),be[O].push({name:m,func:S})}}),be[r_(le,Fa).name]=[{name:"wrapper",func:le}],ln.prototype.clone=function es(){var d=new ln(this.__wrapped__);return d.__actions__=Bs(this.__actions__),d.__dir__=this.__dir__,d.__filtered__=this.__filtered__,d.__iteratees__=Bs(this.__iteratees__),d.__takeCount__=this.__takeCount__,d.__views__=Bs(this.__views__),d},ln.prototype.reverse=function vs(){if(this.__filtered__){var d=new ln(this);d.__dir__=-1,d.__filtered__=!0}else(d=this.clone()).__dir__*=-1;return d},ln.prototype.value=function Ls(){var d=this.__wrapped__.value(),m=this.__dir__,S=yn(d),O=m<0,W=S?d.length:0,Z=function KE(d,m,S){for(var O=-1,W=S.length;++O=this.__values__.length;return{done:d,value:d?le:this.__values__[this.__index__++]}},Y.prototype.plant=function DM(d){for(var m,S=this;S instanceof oi;){var O=nM(S);O.__index__=0,O.__values__=le,m?W.__wrapped__=O:m=O;var W=O;S=S.__wrapped__}return W.__wrapped__=d,m},Y.prototype.reverse=function Sx(){var d=this.__wrapped__;if(d instanceof ln){var m=d;return this.__actions__.length&&(m=new ln(this)),(m=m.reverse()).__actions__.push({func:E_,args:[gm],thisArg:le}),new Fi(m,this.__chain__)}return this.thru(gm)},Y.prototype.toJSON=Y.prototype.valueOf=Y.prototype.value=function vm(){return t_(this.__wrapped__,this.__actions__)},Y.prototype.first=Y.prototype.head,_&&(Y.prototype[_]=function CM(){return this}),Y}();pr._=md,(qr=function(){return md}.call(ka,dt,ka,Aa))!==le&&(Aa.exports=qr)}.call(this)}},Aa=>{Aa(Aa.s=1658)}]); \ No newline at end of file