guito 0.6.1 → 0.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,6 @@
1
+ var mv=Object.defineProperty,vv=Object.defineProperties;var yv=Object.getOwnPropertyDescriptors;var Od=Object.getOwnPropertySymbols;var _v=Object.prototype.hasOwnProperty,bv=Object.prototype.propertyIsEnumerable;var Pd=(t,e,n)=>e in t?mv(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,K=(t,e)=>{for(var n in e||={})_v.call(e,n)&&Pd(t,n,e[n]);if(Od)for(var n of Od(e))bv.call(e,n)&&Pd(t,n,e[n]);return t},le=(t,e)=>vv(t,yv(e));var sr=(t,e,n)=>new Promise((r,o)=>{var i=c=>{try{a(n.next(c))}catch(l){o(l)}},s=c=>{try{a(n.throw(c))}catch(l){o(l)}},a=c=>c.done?r(c.value):Promise.resolve(c.value).then(i,s);a((n=n.apply(t,e)).next())});var Za;function fi(){return Za}function xt(t){let e=Za;return Za=t,e}var Fd=Symbol("NotFound");function ar(t){return t===Fd||t?.name==="\u0275NotFound"}var Le=null,pi=!1,Ya=1,Cv=null,Re=Symbol("SIGNAL");function L(t){let e=Le;return Le=t,e}function vi(){return Le}var pn={version:0,lastCleanEpoch:0,dirty:!1,producers:void 0,producersTail:void 0,consumers:void 0,consumersTail:void 0,recomputing:!1,consumerAllowSignalWrites:!1,consumerIsAlwaysLive:!1,kind:"unknown",producerMustRecompute:()=>!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{}};function hn(t){if(pi)throw new Error("");if(Le===null)return;Le.consumerOnSignalRead(t);let e=Le.producersTail;if(e!==void 0&&e.producer===t)return;let n,r=Le.recomputing;if(r&&(n=e!==void 0?e.nextProducer:Le.producers,n!==void 0&&n.producer===t)){Le.producersTail=n,n.lastReadVersion=t.version;return}let o=t.consumersTail;if(o!==void 0&&o.consumer===Le&&(!r||Ev(o,Le)))return;let i=cr(Le),s={producer:t,consumer:Le,nextProducer:n,prevConsumer:o,lastReadVersion:t.version,nextConsumer:void 0};Le.producersTail=s,e!==void 0?e.nextProducer=s:Le.producers=s,i&&Bd(t,s)}function Ld(){Ya++}function yi(t){if(!(cr(t)&&!t.dirty)&&!(!t.dirty&&t.lastCleanEpoch===Ya)){if(!t.producerMustRecompute(t)&&!mn(t)){mi(t);return}t.producerRecomputeValue(t),mi(t)}}function Qa(t){if(t.consumers===void 0)return;let e=pi;pi=!0;try{for(let n=t.consumers;n!==void 0;n=n.nextConsumer){let r=n.consumer;r.dirty||Dv(r)}}finally{pi=e}}function Ka(){return Le?.consumerAllowSignalWrites!==!1}function Dv(t){t.dirty=!0,Qa(t),t.consumerMarkedDirty?.(t)}function mi(t){t.dirty=!1,t.lastCleanEpoch=Ya}function Gt(t){return t&&jd(t),L(t)}function jd(t){t.producersTail=void 0,t.recomputing=!0}function gn(t,e){L(e),t&&Vd(t)}function Vd(t){t.recomputing=!1;let e=t.producersTail,n=e!==void 0?e.nextProducer:t.producers;if(n!==void 0){if(cr(t))do n=Xa(n);while(n!==void 0);e!==void 0?e.nextProducer=void 0:t.producers=void 0}}function mn(t){for(let e=t.producers;e!==void 0;e=e.nextProducer){let n=e.producer,r=e.lastReadVersion;if(r!==n.version||(yi(n),r!==n.version))return!0}return!1}function qt(t){if(cr(t)){let e=t.producers;for(;e!==void 0;)e=Xa(e)}t.producers=void 0,t.producersTail=void 0,t.consumers=void 0,t.consumersTail=void 0}function Bd(t,e){let n=t.consumersTail,r=cr(t);if(n!==void 0?(e.nextConsumer=n.nextConsumer,n.nextConsumer=e):(e.nextConsumer=void 0,t.consumers=e),e.prevConsumer=n,t.consumersTail=e,!r)for(let o=t.producers;o!==void 0;o=o.nextProducer)Bd(o.producer,o)}function Xa(t){let e=t.producer,n=t.nextProducer,r=t.nextConsumer,o=t.prevConsumer;if(t.nextConsumer=void 0,t.prevConsumer=void 0,r!==void 0?r.prevConsumer=o:e.consumersTail=o,o!==void 0)o.nextConsumer=r;else if(e.consumers=r,!cr(e)){let i=e.producers;for(;i!==void 0;)i=Xa(i)}return n}function cr(t){return t.consumerIsAlwaysLive||t.consumers!==void 0}function _i(t){Cv?.(t)}function Ev(t,e){let n=e.producersTail;if(n!==void 0){let r=e.producers;do{if(r===t)return!0;if(r===n)break;r=r.nextProducer}while(r!==void 0)}return!1}function bi(t,e){return Object.is(t,e)}function Zr(t,e){let n=Object.create(wv);n.computation=t,e!==void 0&&(n.equal=e);let r=()=>{if(yi(n),hn(n),n.value===qr)throw n.error;return n.value};return r[Re]=n,_i(n),r}var hi=Symbol("UNSET"),gi=Symbol("COMPUTING"),qr=Symbol("ERRORED"),wv=le(K({},pn),{value:hi,dirty:!0,error:null,equal:bi,kind:"computed",producerMustRecompute(t){return t.value===hi||t.value===gi},producerRecomputeValue(t){if(t.value===gi)throw new Error("");let e=t.value;t.value=gi;let n=Gt(t),r,o=!1;try{r=t.computation(),L(null),o=e!==hi&&e!==qr&&r!==qr&&t.equal(e,r)}catch(i){r=qr,t.error=i}finally{gn(t,n)}if(o){t.value=e;return}t.value=r,t.version++}});function xv(){throw new Error}var Hd=xv;function $d(t){Hd(t)}function Ja(t){Hd=t}var Iv=null;function ec(t,e){let n=Object.create(Yr);n.value=t,e!==void 0&&(n.equal=e);let r=()=>Ud(n);return r[Re]=n,_i(n),[r,s=>lr(n,s),s=>tc(n,s)]}function Ud(t){return hn(t),t.value}function lr(t,e){Ka()||$d(t),t.equal(t.value,e)||(t.value=e,Mv(t))}function tc(t,e){Ka()||$d(t),lr(t,e(t.value))}var Yr=le(K({},pn),{equal:bi,value:void 0,kind:"signal"});function Mv(t){t.version++,Ld(),Qa(t),Iv?.(t)}function W(t){return typeof t=="function"}function ur(t){let n=t(r=>{Error.call(r),r.stack=new Error().stack});return n.prototype=Object.create(Error.prototype),n.prototype.constructor=n,n}var Ci=ur(t=>function(n){t(this),this.message=n?`${n.length} errors occurred during unsubscription:
2
+ ${n.map((r,o)=>`${o+1}) ${r.toString()}`).join(`
3
+ `)}`:"",this.name="UnsubscriptionError",this.errors=n});function vn(t,e){if(t){let n=t.indexOf(e);0<=n&&t.splice(n,1)}}var me=class t{constructor(e){this.initialTeardown=e,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let e;if(!this.closed){this.closed=!0;let{_parentage:n}=this;if(n)if(this._parentage=null,Array.isArray(n))for(let i of n)i.remove(this);else n.remove(this);let{initialTeardown:r}=this;if(W(r))try{r()}catch(i){e=i instanceof Ci?i.errors:[i]}let{_finalizers:o}=this;if(o){this._finalizers=null;for(let i of o)try{zd(i)}catch(s){e=e??[],s instanceof Ci?e=[...e,...s.errors]:e.push(s)}}if(e)throw new Ci(e)}}add(e){var n;if(e&&e!==this)if(this.closed)zd(e);else{if(e instanceof t){if(e.closed||e._hasParent(this))return;e._addParent(this)}(this._finalizers=(n=this._finalizers)!==null&&n!==void 0?n:[]).push(e)}}_hasParent(e){let{_parentage:n}=this;return n===e||Array.isArray(n)&&n.includes(e)}_addParent(e){let{_parentage:n}=this;this._parentage=Array.isArray(n)?(n.push(e),n):n?[n,e]:e}_removeParent(e){let{_parentage:n}=this;n===e?this._parentage=null:Array.isArray(n)&&vn(n,e)}remove(e){let{_finalizers:n}=this;n&&vn(n,e),e instanceof t&&e._removeParent(this)}};me.EMPTY=(()=>{let t=new me;return t.closed=!0,t})();var nc=me.EMPTY;function Di(t){return t instanceof me||t&&"closed"in t&&W(t.remove)&&W(t.add)&&W(t.unsubscribe)}function zd(t){W(t)?t():t.unsubscribe()}var ut={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1};var dr={setTimeout(t,e,...n){let{delegate:r}=dr;return r?.setTimeout?r.setTimeout(t,e,...n):setTimeout(t,e,...n)},clearTimeout(t){let{delegate:e}=dr;return(e?.clearTimeout||clearTimeout)(t)},delegate:void 0};function Ei(t){dr.setTimeout(()=>{let{onUnhandledError:e}=ut;if(e)e(t);else throw t})}function Qr(){}var Wd=rc("C",void 0,void 0);function Gd(t){return rc("E",void 0,t)}function qd(t){return rc("N",t,void 0)}function rc(t,e,n){return{kind:t,value:e,error:n}}var yn=null;function fr(t){if(ut.useDeprecatedSynchronousErrorHandling){let e=!yn;if(e&&(yn={errorThrown:!1,error:null}),t(),e){let{errorThrown:n,error:r}=yn;if(yn=null,n)throw r}}else t()}function Zd(t){ut.useDeprecatedSynchronousErrorHandling&&yn&&(yn.errorThrown=!0,yn.error=t)}var _n=class extends me{constructor(e){super(),this.isStopped=!1,e?(this.destination=e,Di(e)&&e.add(this)):this.destination=Nv}static create(e,n,r){return new dt(e,n,r)}next(e){this.isStopped?ic(qd(e),this):this._next(e)}error(e){this.isStopped?ic(Gd(e),this):(this.isStopped=!0,this._error(e))}complete(){this.isStopped?ic(Wd,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(e){this.destination.next(e)}_error(e){try{this.destination.error(e)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}},Tv=Function.prototype.bind;function oc(t,e){return Tv.call(t,e)}var sc=class{constructor(e){this.partialObserver=e}next(e){let{partialObserver:n}=this;if(n.next)try{n.next(e)}catch(r){wi(r)}}error(e){let{partialObserver:n}=this;if(n.error)try{n.error(e)}catch(r){wi(r)}else wi(e)}complete(){let{partialObserver:e}=this;if(e.complete)try{e.complete()}catch(n){wi(n)}}},dt=class extends _n{constructor(e,n,r){super();let o;if(W(e)||!e)o={next:e??void 0,error:n??void 0,complete:r??void 0};else{let i;this&&ut.useDeprecatedNextContext?(i=Object.create(e),i.unsubscribe=()=>this.unsubscribe(),o={next:e.next&&oc(e.next,i),error:e.error&&oc(e.error,i),complete:e.complete&&oc(e.complete,i)}):o=e}this.destination=new sc(o)}};function wi(t){ut.useDeprecatedSynchronousErrorHandling?Zd(t):Ei(t)}function Sv(t){throw t}function ic(t,e){let{onStoppedNotification:n}=ut;n&&dr.setTimeout(()=>n(t,e))}var Nv={closed:!0,next:Qr,error:Sv,complete:Qr};var pr=typeof Symbol=="function"&&Symbol.observable||"@@observable";function hr(t){return t}function Yd(t){return t.length===0?hr:t.length===1?t[0]:function(n){return t.reduce((r,o)=>o(r),n)}}var z=(()=>{class t{constructor(n){n&&(this._subscribe=n)}lift(n){let r=new t;return r.source=this,r.operator=n,r}subscribe(n,r,o){let i=kv(n)?n:new dt(n,r,o);return fr(()=>{let{operator:s,source:a}=this;i.add(s?s.call(i,a):a?this._subscribe(i):this._trySubscribe(i))}),i}_trySubscribe(n){try{return this._subscribe(n)}catch(r){n.error(r)}}forEach(n,r){return r=Qd(r),new r((o,i)=>{let s=new dt({next:a=>{try{n(a)}catch(c){i(c),s.unsubscribe()}},error:i,complete:o});this.subscribe(s)})}_subscribe(n){var r;return(r=this.source)===null||r===void 0?void 0:r.subscribe(n)}[pr](){return this}pipe(...n){return Yd(n)(this)}toPromise(n){return n=Qd(n),new n((r,o)=>{let i;this.subscribe(s=>i=s,s=>o(s),()=>r(i))})}}return t.create=e=>new t(e),t})();function Qd(t){var e;return(e=t??ut.Promise)!==null&&e!==void 0?e:Promise}function Rv(t){return t&&W(t.next)&&W(t.error)&&W(t.complete)}function kv(t){return t&&t instanceof _n||Rv(t)&&Di(t)}function ac(t){return W(t?.lift)}function J(t){return e=>{if(ac(e))return e.lift(function(n){try{return t(n,this)}catch(r){this.error(r)}});throw new TypeError("Unable to lift unknown Observable type")}}function ee(t,e,n,r,o){return new cc(t,e,n,r,o)}var cc=class extends _n{constructor(e,n,r,o,i,s){super(e),this.onFinalize=i,this.shouldUnsubscribe=s,this._next=n?function(a){try{n(a)}catch(c){e.error(c)}}:super._next,this._error=o?function(a){try{o(a)}catch(c){e.error(c)}finally{this.unsubscribe()}}:super._error,this._complete=r?function(){try{r()}catch(a){e.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var e;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){let{closed:n}=this;super.unsubscribe(),!n&&((e=this.onFinalize)===null||e===void 0||e.call(this))}}};function Kd(){return J((t,e)=>{let n=null;t._refCount++;let r=ee(e,void 0,void 0,void 0,()=>{if(!t||t._refCount<=0||0<--t._refCount){n=null;return}let o=t._connection,i=n;n=null,o&&(!i||o===i)&&o.unsubscribe(),e.unsubscribe()});t.subscribe(r),r.closed||(n=t.connect())})}var Kr=class extends z{constructor(e,n){super(),this.source=e,this.subjectFactory=n,this._subject=null,this._refCount=0,this._connection=null,ac(e)&&(this.lift=e.lift)}_subscribe(e){return this.getSubject().subscribe(e)}getSubject(){let e=this._subject;return(!e||e.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;let{_connection:e}=this;this._subject=this._connection=null,e?.unsubscribe()}connect(){let e=this._connection;if(!e){e=this._connection=new me;let n=this.getSubject();e.add(this.source.subscribe(ee(n,void 0,()=>{this._teardown(),n.complete()},r=>{this._teardown(),n.error(r)},()=>this._teardown()))),e.closed&&(this._connection=null,e=me.EMPTY)}return e}refCount(){return Kd()(this)}};var gr={schedule(t){let e=requestAnimationFrame,n=cancelAnimationFrame,{delegate:r}=gr;r&&(e=r.requestAnimationFrame,n=r.cancelAnimationFrame);let o=e(i=>{n=void 0,t(i)});return new me(()=>n?.(o))},requestAnimationFrame(...t){let{delegate:e}=gr;return(e?.requestAnimationFrame||requestAnimationFrame)(...t)},cancelAnimationFrame(...t){let{delegate:e}=gr;return(e?.cancelAnimationFrame||cancelAnimationFrame)(...t)},delegate:void 0};var Xd=ur(t=>function(){t(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});var ye=(()=>{class t extends z{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(n){let r=new xi(this,this);return r.operator=n,r}_throwIfClosed(){if(this.closed)throw new Xd}next(n){fr(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(let r of this.currentObservers)r.next(n)}})}error(n){fr(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=n;let{observers:r}=this;for(;r.length;)r.shift().error(n)}})}complete(){fr(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;let{observers:n}=this;for(;n.length;)n.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var n;return((n=this.observers)===null||n===void 0?void 0:n.length)>0}_trySubscribe(n){return this._throwIfClosed(),super._trySubscribe(n)}_subscribe(n){return this._throwIfClosed(),this._checkFinalizedStatuses(n),this._innerSubscribe(n)}_innerSubscribe(n){let{hasError:r,isStopped:o,observers:i}=this;return r||o?nc:(this.currentObservers=null,i.push(n),new me(()=>{this.currentObservers=null,vn(i,n)}))}_checkFinalizedStatuses(n){let{hasError:r,thrownError:o,isStopped:i}=this;r?n.error(o):i&&n.complete()}asObservable(){let n=new z;return n.source=this,n}}return t.create=(e,n)=>new xi(e,n),t})(),xi=class extends ye{constructor(e,n){super(),this.destination=e,this.source=n}next(e){var n,r;(r=(n=this.destination)===null||n===void 0?void 0:n.next)===null||r===void 0||r.call(n,e)}error(e){var n,r;(r=(n=this.destination)===null||n===void 0?void 0:n.error)===null||r===void 0||r.call(n,e)}complete(){var e,n;(n=(e=this.destination)===null||e===void 0?void 0:e.complete)===null||n===void 0||n.call(e)}_subscribe(e){var n,r;return(r=(n=this.source)===null||n===void 0?void 0:n.subscribe(e))!==null&&r!==void 0?r:nc}};var Xr=class extends ye{constructor(e){super(),this._value=e}get value(){return this.getValue()}_subscribe(e){let n=super._subscribe(e);return!n.closed&&e.next(this._value),n}getValue(){let{hasError:e,thrownError:n,_value:r}=this;if(e)throw n;return this._throwIfClosed(),r}next(e){super.next(this._value=e)}};var Jr={now(){return(Jr.delegate||Date).now()},delegate:void 0};var bn=class extends ye{constructor(e=1/0,n=1/0,r=Jr){super(),this._bufferSize=e,this._windowTime=n,this._timestampProvider=r,this._buffer=[],this._infiniteTimeWindow=!0,this._infiniteTimeWindow=n===1/0,this._bufferSize=Math.max(1,e),this._windowTime=Math.max(1,n)}next(e){let{isStopped:n,_buffer:r,_infiniteTimeWindow:o,_timestampProvider:i,_windowTime:s}=this;n||(r.push(e),!o&&r.push(i.now()+s)),this._trimBuffer(),super.next(e)}_subscribe(e){this._throwIfClosed(),this._trimBuffer();let n=this._innerSubscribe(e),{_infiniteTimeWindow:r,_buffer:o}=this,i=o.slice();for(let s=0;s<i.length&&!e.closed;s+=r?1:2)e.next(i[s]);return this._checkFinalizedStatuses(e),n}_trimBuffer(){let{_bufferSize:e,_timestampProvider:n,_buffer:r,_infiniteTimeWindow:o}=this,i=(o?1:2)*e;if(e<1/0&&i<r.length&&r.splice(0,r.length-i),!o){let s=n.now(),a=0;for(let c=1;c<r.length&&r[c]<=s;c+=2)a=c;a&&r.splice(0,a+1)}}};var Ii=class extends me{constructor(e,n){super()}schedule(e,n=0){return this}};var eo={setInterval(t,e,...n){let{delegate:r}=eo;return r?.setInterval?r.setInterval(t,e,...n):setInterval(t,e,...n)},clearInterval(t){let{delegate:e}=eo;return(e?.clearInterval||clearInterval)(t)},delegate:void 0};var Zt=class extends Ii{constructor(e,n){super(e,n),this.scheduler=e,this.work=n,this.pending=!1}schedule(e,n=0){var r;if(this.closed)return this;this.state=e;let o=this.id,i=this.scheduler;return o!=null&&(this.id=this.recycleAsyncId(i,o,n)),this.pending=!0,this.delay=n,this.id=(r=this.id)!==null&&r!==void 0?r:this.requestAsyncId(i,this.id,n),this}requestAsyncId(e,n,r=0){return eo.setInterval(e.flush.bind(e,this),r)}recycleAsyncId(e,n,r=0){if(r!=null&&this.delay===r&&this.pending===!1)return n;n!=null&&eo.clearInterval(n)}execute(e,n){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;let r=this._execute(e,n);if(r)return r;this.pending===!1&&this.id!=null&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(e,n){let r=!1,o;try{this.work(e)}catch(i){r=!0,o=i||new Error("Scheduled action threw falsy error")}if(r)return this.unsubscribe(),o}unsubscribe(){if(!this.closed){let{id:e,scheduler:n}=this,{actions:r}=n;this.work=this.state=this.scheduler=null,this.pending=!1,vn(r,this),e!=null&&(this.id=this.recycleAsyncId(n,e,null)),this.delay=null,super.unsubscribe()}}};var Av=1,lc,uc={};function Jd(t){return t in uc?(delete uc[t],!0):!1}var ef={setImmediate(t){let e=Av++;return uc[e]=!0,lc||(lc=Promise.resolve()),lc.then(()=>Jd(e)&&t()),e},clearImmediate(t){Jd(t)}};var{setImmediate:Ov,clearImmediate:Pv}=ef,to={setImmediate(...t){let{delegate:e}=to;return(e?.setImmediate||Ov)(...t)},clearImmediate(t){let{delegate:e}=to;return(e?.clearImmediate||Pv)(t)},delegate:void 0};var Mi=class extends Zt{constructor(e,n){super(e,n),this.scheduler=e,this.work=n}requestAsyncId(e,n,r=0){return r!==null&&r>0?super.requestAsyncId(e,n,r):(e.actions.push(this),e._scheduled||(e._scheduled=to.setImmediate(e.flush.bind(e,void 0))))}recycleAsyncId(e,n,r=0){var o;if(r!=null?r>0:this.delay>0)return super.recycleAsyncId(e,n,r);let{actions:i}=e;n!=null&&((o=i[i.length-1])===null||o===void 0?void 0:o.id)!==n&&(to.clearImmediate(n),e._scheduled===n&&(e._scheduled=void 0))}};var mr=class t{constructor(e,n=t.now){this.schedulerActionCtor=e,this.now=n}schedule(e,n=0,r){return new this.schedulerActionCtor(this,e).schedule(r,n)}};mr.now=Jr.now;var Yt=class extends mr{constructor(e,n=mr.now){super(e,n),this.actions=[],this._active=!1}flush(e){let{actions:n}=this;if(this._active){n.push(e);return}let r;this._active=!0;do if(r=e.execute(e.state,e.delay))break;while(e=n.shift());if(this._active=!1,r){for(;e=n.shift();)e.unsubscribe();throw r}}};var Ti=class extends Yt{flush(e){this._active=!0;let n=this._scheduled;this._scheduled=void 0;let{actions:r}=this,o;e=e||r.shift();do if(o=e.execute(e.state,e.delay))break;while((e=r[0])&&e.id===n&&r.shift());if(this._active=!1,o){for(;(e=r[0])&&e.id===n&&r.shift();)e.unsubscribe();throw o}}};var dc=new Ti(Mi);var no=new Yt(Zt),tf=no;var Si=class extends Zt{constructor(e,n){super(e,n),this.scheduler=e,this.work=n}requestAsyncId(e,n,r=0){return r!==null&&r>0?super.requestAsyncId(e,n,r):(e.actions.push(this),e._scheduled||(e._scheduled=gr.requestAnimationFrame(()=>e.flush(void 0))))}recycleAsyncId(e,n,r=0){var o;if(r!=null?r>0:this.delay>0)return super.recycleAsyncId(e,n,r);let{actions:i}=e;n!=null&&n===e._scheduled&&((o=i[i.length-1])===null||o===void 0?void 0:o.id)!==n&&(gr.cancelAnimationFrame(n),e._scheduled=void 0)}};var Ni=class extends Yt{flush(e){this._active=!0;let n;e?n=e.id:(n=this._scheduled,this._scheduled=void 0);let{actions:r}=this,o;e=e||r.shift();do if(o=e.execute(e.state,e.delay))break;while((e=r[0])&&e.id===n&&r.shift());if(this._active=!1,o){for(;(e=r[0])&&e.id===n&&r.shift();)e.unsubscribe();throw o}}};var fc=new Ni(Si);function Ri(t){return t&&W(t.schedule)}function nf(t){return t[t.length-1]}function rf(t){return W(nf(t))?t.pop():void 0}function vr(t){return Ri(nf(t))?t.pop():void 0}function sf(t,e,n,r){function o(i){return i instanceof n?i:new n(function(s){s(i)})}return new(n||(n=Promise))(function(i,s){function a(u){try{l(r.next(u))}catch(f){s(f)}}function c(u){try{l(r.throw(u))}catch(f){s(f)}}function l(u){u.done?i(u.value):o(u.value).then(a,c)}l((r=r.apply(t,e||[])).next())})}function of(t){var e=typeof Symbol=="function"&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function Cn(t){return this instanceof Cn?(this.v=t,this):new Cn(t)}function af(t,e,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=n.apply(t,e||[]),o,i=[];return o=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",s),o[Symbol.asyncIterator]=function(){return this},o;function s(p){return function(E){return Promise.resolve(E).then(p,f)}}function a(p,E){r[p]&&(o[p]=function(N){return new Promise(function(k,S){i.push([p,N,k,S])>1||c(p,N)})},E&&(o[p]=E(o[p])))}function c(p,E){try{l(r[p](E))}catch(N){m(i[0][3],N)}}function l(p){p.value instanceof Cn?Promise.resolve(p.value.v).then(u,f):m(i[0][2],p)}function u(p){c("next",p)}function f(p){c("throw",p)}function m(p,E){p(E),i.shift(),i.length&&c(i[0][0],i[0][1])}}function cf(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e=t[Symbol.asyncIterator],n;return e?e.call(t):(t=typeof of=="function"?of(t):t[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(i){n[i]=t[i]&&function(s){return new Promise(function(a,c){s=t[i](s),o(a,c,s.done,s.value)})}}function o(i,s,a,c){Promise.resolve(c).then(function(l){i({value:l,done:a})},s)}}var ki=t=>t&&typeof t.length=="number"&&typeof t!="function";function Ai(t){return W(t?.then)}function Oi(t){return W(t[pr])}function Pi(t){return Symbol.asyncIterator&&W(t?.[Symbol.asyncIterator])}function Fi(t){return new TypeError(`You provided ${t!==null&&typeof t=="object"?"an invalid object":`'${t}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}function Fv(){return typeof Symbol!="function"||!Symbol.iterator?"@@iterator":Symbol.iterator}var Li=Fv();function ji(t){return W(t?.[Li])}function Vi(t){return af(this,arguments,function*(){let n=t.getReader();try{for(;;){let{value:r,done:o}=yield Cn(n.read());if(o)return yield Cn(void 0);yield yield Cn(r)}}finally{n.releaseLock()}})}function Bi(t){return W(t?.getReader)}function he(t){if(t instanceof z)return t;if(t!=null){if(Oi(t))return Lv(t);if(ki(t))return jv(t);if(Ai(t))return Vv(t);if(Pi(t))return lf(t);if(ji(t))return Bv(t);if(Bi(t))return Hv(t)}throw Fi(t)}function Lv(t){return new z(e=>{let n=t[pr]();if(W(n.subscribe))return n.subscribe(e);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}function jv(t){return new z(e=>{for(let n=0;n<t.length&&!e.closed;n++)e.next(t[n]);e.complete()})}function Vv(t){return new z(e=>{t.then(n=>{e.closed||(e.next(n),e.complete())},n=>e.error(n)).then(null,Ei)})}function Bv(t){return new z(e=>{for(let n of t)if(e.next(n),e.closed)return;e.complete()})}function lf(t){return new z(e=>{$v(t,e).catch(n=>e.error(n))})}function Hv(t){return lf(Vi(t))}function $v(t,e){var n,r,o,i;return sf(this,void 0,void 0,function*(){try{for(n=cf(t);r=yield n.next(),!r.done;){let s=r.value;if(e.next(s),e.closed)return}}catch(s){o={error:s}}finally{try{r&&!r.done&&(i=n.return)&&(yield i.call(n))}finally{if(o)throw o.error}}e.complete()})}function et(t,e,n,r=0,o=!1){let i=e.schedule(function(){n(),o?t.add(this.schedule(null,r)):this.unsubscribe()},r);if(t.add(i),!o)return i}function Hi(t,e=0){return J((n,r)=>{n.subscribe(ee(r,o=>et(r,t,()=>r.next(o),e),()=>et(r,t,()=>r.complete(),e),o=>et(r,t,()=>r.error(o),e)))})}function $i(t,e=0){return J((n,r)=>{r.add(t.schedule(()=>n.subscribe(r),e))})}function uf(t,e){return he(t).pipe($i(e),Hi(e))}function df(t,e){return he(t).pipe($i(e),Hi(e))}function ff(t,e){return new z(n=>{let r=0;return e.schedule(function(){r===t.length?n.complete():(n.next(t[r++]),n.closed||this.schedule())})})}function pf(t,e){return new z(n=>{let r;return et(n,e,()=>{r=t[Li](),et(n,e,()=>{let o,i;try{({value:o,done:i}=r.next())}catch(s){n.error(s);return}i?n.complete():n.next(o)},0,!0)}),()=>W(r?.return)&&r.return()})}function Ui(t,e){if(!t)throw new Error("Iterable cannot be null");return new z(n=>{et(n,e,()=>{let r=t[Symbol.asyncIterator]();et(n,e,()=>{r.next().then(o=>{o.done?n.complete():n.next(o.value)})},0,!0)})})}function hf(t,e){return Ui(Vi(t),e)}function gf(t,e){if(t!=null){if(Oi(t))return uf(t,e);if(ki(t))return ff(t,e);if(Ai(t))return df(t,e);if(Pi(t))return Ui(t,e);if(ji(t))return pf(t,e);if(Bi(t))return hf(t,e)}throw Fi(t)}function zi(t,e){return e?gf(t,e):he(t)}function Se(...t){let e=vr(t);return zi(t,e)}function pc(t,e){let n=W(t)?t:()=>t,r=o=>o.error(n());return new z(e?o=>e.schedule(r,0,o):r)}function ro(t){return!!t&&(t instanceof z||W(t.lift)&&W(t.subscribe))}var mf=ur(t=>function(){t(this),this.name="EmptyError",this.message="no elements in sequence"});function Wi(t,e){let n=typeof e=="object";return new Promise((r,o)=>{let i=new dt({next:s=>{r(s),i.unsubscribe()},error:o,complete:()=>{n?r(e.defaultValue):o(new mf)}});t.subscribe(i)})}function vf(t){return t instanceof Date&&!isNaN(t)}function je(t,e){return J((n,r)=>{let o=0;n.subscribe(ee(r,i=>{r.next(t.call(e,i,o++))}))})}var{isArray:Uv}=Array;function zv(t,e){return Uv(e)?t(...e):t(e)}function yf(t){return je(e=>zv(t,e))}var{isArray:Wv}=Array,{getPrototypeOf:Gv,prototype:qv,keys:Zv}=Object;function _f(t){if(t.length===1){let e=t[0];if(Wv(e))return{args:e,keys:null};if(Yv(e)){let n=Zv(e);return{args:n.map(r=>e[r]),keys:n}}}return{args:t,keys:null}}function Yv(t){return t&&typeof t=="object"&&Gv(t)===qv}function bf(t,e){return t.reduce((n,r,o)=>(n[r]=e[o],n),{})}function Cf(t,e,n,r,o,i,s,a){let c=[],l=0,u=0,f=!1,m=()=>{f&&!c.length&&!l&&e.complete()},p=N=>l<r?E(N):c.push(N),E=N=>{i&&e.next(N),l++;let k=!1;he(n(N,u++)).subscribe(ee(e,S=>{o?.(S),i?p(S):e.next(S)},()=>{k=!0},void 0,()=>{if(k)try{for(l--;c.length&&l<r;){let S=c.shift();s?et(e,s,()=>E(S)):E(S)}m()}catch(S){e.error(S)}}))};return t.subscribe(ee(e,p,()=>{f=!0,m()})),()=>{a?.()}}function yr(t,e,n=1/0){return W(e)?yr((r,o)=>je((i,s)=>e(r,i,o,s))(he(t(r,o))),n):(typeof e=="number"&&(n=e),J((r,o)=>Cf(r,o,t,n)))}function Df(t=1/0){return yr(hr,t)}function Ef(){return Df(1)}function hc(...t){return Ef()(zi(t,vr(t)))}function gc(t){return new z(e=>{he(t()).subscribe(e)})}function mc(...t){let e=rf(t),{args:n,keys:r}=_f(t),o=new z(i=>{let{length:s}=n;if(!s){i.complete();return}let a=new Array(s),c=s,l=s;for(let u=0;u<s;u++){let f=!1;he(n[u]).subscribe(ee(i,m=>{f||(f=!0,l--),a[u]=m},()=>c--,void 0,()=>{(!c||!f)&&(l||i.next(r?bf(r,a):a),i.complete())}))}});return e?o.pipe(yf(e)):o}function wf(t=0,e,n=tf){let r=-1;return e!=null&&(Ri(e)?n=e:r=e),new z(o=>{let i=vf(t)?+t-n.now():t;i<0&&(i=0);let s=0;return n.schedule(function(){o.closed||(o.next(s++),0<=r?this.schedule(void 0,r):o.complete())},i)})}function oo(t,e){return J((n,r)=>{let o=0;n.subscribe(ee(r,i=>t.call(e,i,o++)&&r.next(i)))})}function xf(t){return J((e,n)=>{let r=!1,o=null,i=null,s=!1,a=()=>{if(i?.unsubscribe(),i=null,r){r=!1;let l=o;o=null,n.next(l)}s&&n.complete()},c=()=>{i=null,s&&n.complete()};e.subscribe(ee(n,l=>{r=!0,o=l,i||he(t(l)).subscribe(i=ee(n,a,c))},()=>{s=!0,(!r||!i||i.closed)&&n.complete()}))})}function io(t,e=no){return xf(()=>wf(t,e))}function It(t){return J((e,n)=>{let r=null,o=!1,i;r=e.subscribe(ee(n,void 0,void 0,s=>{i=he(t(s,It(t)(e))),r?(r.unsubscribe(),r=null,i.subscribe(n)):o=!0})),o&&(r.unsubscribe(),r=null,i.subscribe(n))})}function vc(t,e){return W(e)?yr(t,e,1):yr(t,1)}function yc(t,e=no){return J((n,r)=>{let o=null,i=null,s=null,a=()=>{if(o){o.unsubscribe(),o=null;let l=i;i=null,r.next(l)}};function c(){let l=s+t,u=e.now();if(u<l){o=this.schedule(void 0,l-u),r.add(o);return}a()}n.subscribe(ee(r,l=>{i=l,s=e.now(),o||(o=e.schedule(c,t),r.add(o))},()=>{a(),r.complete()},void 0,()=>{i=o=null}))})}function so(t,e=hr){return t=t??Qv,J((n,r)=>{let o,i=!0;n.subscribe(ee(r,s=>{let a=e(s);(i||!t(o,a))&&(i=!1,o=a,r.next(s))}))})}function Qv(t,e){return t===e}function _r(t){return J((e,n)=>{try{e.subscribe(n)}finally{n.add(t)}})}function _c(){return J((t,e)=>{let n,r=!1;t.subscribe(ee(e,o=>{let i=n;n=o,r&&e.next([i,o]),r=!0}))})}function If(t={}){let{connector:e=()=>new ye,resetOnError:n=!0,resetOnComplete:r=!0,resetOnRefCountZero:o=!0}=t;return i=>{let s,a,c,l=0,u=!1,f=!1,m=()=>{a?.unsubscribe(),a=void 0},p=()=>{m(),s=c=void 0,u=f=!1},E=()=>{let N=s;p(),N?.unsubscribe()};return J((N,k)=>{l++,!f&&!u&&m();let S=c=c??e();k.add(()=>{l--,l===0&&!f&&!u&&(a=bc(E,o))}),S.subscribe(k),!s&&l>0&&(s=new dt({next:ve=>S.next(ve),error:ve=>{f=!0,m(),a=bc(p,n,ve),S.error(ve)},complete:()=>{u=!0,m(),a=bc(p,r),S.complete()}}),he(N).subscribe(s))})(i)}}function bc(t,e,...n){if(e===!0){t();return}if(e===!1)return;let r=new dt({next:()=>{r.unsubscribe(),t()}});return he(e(...n)).subscribe(r)}function br(t,e,n){let r,o=!1;return t&&typeof t=="object"?{bufferSize:r=1/0,windowTime:e=1/0,refCount:o=!1,scheduler:n}=t:r=t??1/0,If({connector:()=>new bn(r,e,n),resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:o})}function Gi(...t){let e=vr(t);return J((n,r)=>{(e?hc(t,n,e):hc(t,n)).subscribe(r)})}function ft(t,e){return J((n,r)=>{let o=null,i=0,s=!1,a=()=>s&&!o&&r.complete();n.subscribe(ee(r,c=>{o?.unsubscribe();let l=0,u=i++;he(t(c,u)).subscribe(o=ee(r,f=>r.next(e?e(c,f,u,l++):f),()=>{o=null,a()}))},()=>{s=!0,a()}))})}function Dn(t){return J((e,n)=>{he(t).subscribe(ee(n,()=>n.complete(),Qr)),!n.closed&&e.subscribe(n)})}function Mf(t){let e=L(null);try{return t()}finally{L(e)}}var Tf=le(K({},pn),{consumerIsAlwaysLive:!0,consumerAllowSignalWrites:!0,dirty:!0,kind:"effect"});function Sf(t){if(t.dirty=!1,t.version>0&&!mn(t))return;t.version++;let e=Gt(t);try{t.cleanup(),t.fn()}finally{gn(t,e)}}var Qi="https://angular.dev/best-practices/security#preventing-cross-site-scripting-xss",R=class extends Error{code;constructor(e,n){super(Tn(e,n)),this.code=e}};function Kv(t){return`NG0${Math.abs(t)}`}function Tn(t,e){return`${Kv(t)}${e?": "+e:""}`}var Sn=globalThis;function ne(t){for(let e in t)if(t[e]===ne)return e;throw Error("")}function kf(t,e){for(let n in e)e.hasOwnProperty(n)&&!t.hasOwnProperty(n)&&(t[n]=e[n])}function Qt(t){if(typeof t=="string")return t;if(Array.isArray(t))return`[${t.map(Qt).join(", ")}]`;if(t==null)return""+t;let e=t.overriddenName||t.name;if(e)return`${e}`;let n=t.toString();if(n==null)return""+n;let r=n.indexOf(`
4
+ `);return r>=0?n.slice(0,r):n}function Ki(t,e){return t?e?`${t} ${e}`:t:e||""}var Xv=ne({__forward_ref__:ne});function Dr(t){return t.__forward_ref__=Dr,t.toString=function(){return Qt(this())},t}function Ve(t){return Af(t)?t():t}function Af(t){return typeof t=="function"&&t.hasOwnProperty(Xv)&&t.__forward_ref__===Dr}function B(t){return{token:t.token,providedIn:t.providedIn||null,factory:t.factory,value:void 0}}function Xi(t){return Jv(t,Ji)}function Jv(t,e){return t.hasOwnProperty(e)&&t[e]||null}function ey(t){let e=t?.[Ji]??null;return e||null}function Dc(t){return t&&t.hasOwnProperty(Zi)?t[Zi]:null}var Ji=ne({\u0275prov:ne}),Zi=ne({\u0275inj:ne}),P=class{_desc;ngMetadataName="InjectionToken";\u0275prov;constructor(e,n){this._desc=e,this.\u0275prov=void 0,typeof n=="number"?this.__NG_ELEMENT_ID__=n:n!==void 0&&(this.\u0275prov=B({token:this,providedIn:n.providedIn||"root",factory:n.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}};function Ac(t){return t&&!!t.\u0275providers}var Oc=ne({\u0275cmp:ne}),Pc=ne({\u0275dir:ne}),Fc=ne({\u0275pipe:ne});var Ec=ne({\u0275fac:ne}),Nn=ne({__NG_ELEMENT_ID__:ne}),Nf=ne({__NG_ENV_ID__:ne});function Rn(t){return typeof t=="string"?t:t==null?"":String(t)}function Of(t){return typeof t=="function"?t.name||t.toString():typeof t=="object"&&t!=null&&typeof t.type=="function"?t.type.name||t.type.toString():Rn(t)}var Pf=ne({ngErrorCode:ne}),ty=ne({ngErrorMessage:ne}),ny=ne({ngTokenPath:ne});function Lc(t,e){return Ff("",-200,e)}function es(t,e){throw new R(-201,!1)}function Ff(t,e,n){let r=new R(e,t);return r[Pf]=e,r[ty]=t,n&&(r[ny]=n),r}function ry(t){return t[Pf]}var wc;function Lf(){return wc}function $e(t){let e=wc;return wc=t,e}function jc(t,e,n){let r=Xi(t);if(r&&r.providedIn=="root")return r.value===void 0?r.value=r.factory():r.value;if(n&8)return null;if(e!==void 0)return e;es(t,"Injector")}var oy={},En=oy,xc="__NG_DI_FLAG__",Ic=class{injector;constructor(e){this.injector=e}retrieve(e,n){let r=wn(n)||0;try{return this.injector.get(e,r&8?null:En,r)}catch(o){if(ar(o))return o;throw o}}};function iy(t,e=0){let n=fi();if(n===void 0)throw new R(-203,!1);if(n===null)return jc(t,void 0,e);{let r=sy(e),o=n.retrieve(t,r);if(ar(o)){if(r.optional)return null;throw o}return o}}function Q(t,e=0){return(Lf()||iy)(Ve(t),e)}function _(t,e){return Q(t,wn(e))}function wn(t){return typeof t>"u"||typeof t=="number"?t:0|(t.optional&&8)|(t.host&&1)|(t.self&&2)|(t.skipSelf&&4)}function sy(t){return{optional:!!(t&8),host:!!(t&1),self:!!(t&2),skipSelf:!!(t&4)}}function Mc(t){let e=[];for(let n=0;n<t.length;n++){let r=Ve(t[n]);if(Array.isArray(r)){if(r.length===0)throw new R(900,!1);let o,i=0;for(let s=0;s<r.length;s++){let a=r[s],c=ay(a);typeof c=="number"?c===-1?o=a.token:i|=c:o=a}e.push(Q(o,i))}else e.push(Q(r))}return e}function Vc(t,e){return t[xc]=e,t.prototype[xc]=e,t}function ay(t){return t[xc]}function xn(t,e){let n=t.hasOwnProperty(Ec);return n?t[Ec]:null}function jf(t,e,n){if(t.length!==e.length)return!1;for(let r=0;r<t.length;r++){let o=t[r],i=e[r];if(n&&(o=n(o),i=n(i)),i!==o)return!1}return!0}function Vf(t){return t.flat(Number.POSITIVE_INFINITY)}function ts(t,e){t.forEach(n=>Array.isArray(n)?ts(n,e):e(n))}function Bc(t,e,n){e>=t.length?t.push(n):t.splice(e,0,n)}function uo(t,e){return e>=t.length-1?t.pop():t.splice(e,1)[0]}function Bf(t,e){let n=[];for(let r=0;r<t;r++)n.push(e);return n}function Hf(t,e,n,r){let o=t.length;if(o==e)t.push(n,r);else if(o===1)t.push(r,t[0]),t[0]=n;else{for(o--,t.push(t[o-1],t[o]);o>e;){let i=o-2;t[o]=t[i],o--}t[e]=n,t[e+1]=r}}function ns(t,e,n){let r=Er(t,e);return r>=0?t[r|1]=n:(r=~r,Hf(t,r,e,n)),r}function rs(t,e){let n=Er(t,e);if(n>=0)return t[n|1]}function Er(t,e){return cy(t,e,1)}function cy(t,e,n){let r=0,o=t.length>>n;for(;o!==r;){let i=r+(o-r>>1),s=t[i<<n];if(e===s)return i<<n;s>e?o=i:r=i+1}return~(o<<n)}var Xt={},tt=[],kn=new P(""),Hc=new P("",-1),$c=new P(""),co=class{get(e,n=En){if(n===En){let o=Ff("",-201);throw o.name="\u0275NotFound",o}return n}};function An(t){return t[Oc]||null}function Uc(t){return t[Pc]||null}function $f(t){return t[Fc]||null}function fo(t){return{\u0275providers:t}}function Uf(...t){return{\u0275providers:zc(!0,t),\u0275fromNgModule:!0}}function zc(t,...e){let n=[],r=new Set,o,i=s=>{n.push(s)};return ts(e,s=>{let a=s;Yi(a,i,[],r)&&(o||=[],o.push(a))}),o!==void 0&&zf(o,i),n}function zf(t,e){for(let n=0;n<t.length;n++){let{ngModule:r,providers:o}=t[n];Wc(o,i=>{e(i,r)})}}function Yi(t,e,n,r){if(t=Ve(t),!t)return!1;let o=null,i=Dc(t),s=!i&&An(t);if(!i&&!s){let c=t.ngModule;if(i=Dc(c),i)o=c;else return!1}else{if(s&&!s.standalone)return!1;o=t}let a=r.has(o);if(s){if(a)return!1;if(r.add(o),s.dependencies){let c=typeof s.dependencies=="function"?s.dependencies():s.dependencies;for(let l of c)Yi(l,e,n,r)}}else if(i){if(i.imports!=null&&!a){r.add(o);let l;ts(i.imports,u=>{Yi(u,e,n,r)&&(l||=[],l.push(u))}),l!==void 0&&zf(l,e)}if(!a){let l=xn(o)||(()=>new o);e({provide:o,useFactory:l,deps:tt},o),e({provide:$c,useValue:o,multi:!0},o),e({provide:kn,useValue:()=>Q(o),multi:!0},o)}let c=i.providers;if(c!=null&&!a){let l=t;Wc(c,u=>{e(u,l)})}}else return!1;return o!==t&&t.providers!==void 0}function Wc(t,e){for(let n of t)Ac(n)&&(n=n.\u0275providers),Array.isArray(n)?Wc(n,e):e(n)}var ly=ne({provide:String,useValue:ne});function Wf(t){return t!==null&&typeof t=="object"&&ly in t}function uy(t){return!!(t&&t.useExisting)}function dy(t){return!!(t&&t.useFactory)}function In(t){return typeof t=="function"}function Gf(t){return!!t.useClass}var po=new P(""),qi={},Rf={},Cc;function ho(){return Cc===void 0&&(Cc=new co),Cc}var Ge=class{},Mn=class extends Ge{parent;source;scopes;records=new Map;_ngOnDestroyHooks=new Set;_onDestroyHooks=[];get destroyed(){return this._destroyed}_destroyed=!1;injectorDefTypes;constructor(e,n,r,o){super(),this.parent=n,this.source=r,this.scopes=o,Sc(e,s=>this.processProvider(s)),this.records.set(Hc,Cr(void 0,this)),o.has("environment")&&this.records.set(Ge,Cr(void 0,this));let i=this.records.get(po);i!=null&&typeof i.value=="string"&&this.scopes.add(i.value),this.injectorDefTypes=new Set(this.get($c,tt,{self:!0}))}retrieve(e,n){let r=wn(n)||0;try{return this.get(e,En,r)}catch(o){if(ar(o))return o;throw o}}destroy(){ao(this),this._destroyed=!0;let e=L(null);try{for(let r of this._ngOnDestroyHooks)r.ngOnDestroy();let n=this._onDestroyHooks;this._onDestroyHooks=[];for(let r of n)r()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),L(e)}}onDestroy(e){return ao(this),this._onDestroyHooks.push(e),()=>this.removeOnDestroy(e)}runInContext(e){ao(this);let n=xt(this),r=$e(void 0),o;try{return e()}finally{xt(n),$e(r)}}get(e,n=En,r){if(ao(this),e.hasOwnProperty(Nf))return e[Nf](this);let o=wn(r),i,s=xt(this),a=$e(void 0);try{if(!(o&4)){let l=this.records.get(e);if(l===void 0){let u=my(e)&&Xi(e);u&&this.injectableDefInScope(u)?l=Cr(Tc(e),qi):l=null,this.records.set(e,l)}if(l!=null)return this.hydrate(e,l,o)}let c=o&2?ho():this.parent;return n=o&8&&n===En?null:n,c.get(e,n)}catch(c){let l=ry(c);throw l===-200||l===-201?new R(l,null):c}finally{$e(a),xt(s)}}resolveInjectorInitializers(){let e=L(null),n=xt(this),r=$e(void 0),o;try{let i=this.get(kn,tt,{self:!0});for(let s of i)s()}finally{xt(n),$e(r),L(e)}}toString(){let e=[],n=this.records;for(let r of n.keys())e.push(Qt(r));return`R3Injector[${e.join(", ")}]`}processProvider(e){e=Ve(e);let n=In(e)?e:Ve(e&&e.provide),r=py(e);if(!In(e)&&e.multi===!0){let o=this.records.get(n);o||(o=Cr(void 0,qi,!0),o.factory=()=>Mc(o.multi),this.records.set(n,o)),n=e,o.multi.push(e)}this.records.set(n,r)}hydrate(e,n,r){let o=L(null);try{if(n.value===Rf)throw Lc(Qt(e));return n.value===qi&&(n.value=Rf,n.value=n.factory(void 0,r)),typeof n.value=="object"&&n.value&&gy(n.value)&&this._ngOnDestroyHooks.add(n.value),n.value}finally{L(o)}}injectableDefInScope(e){if(!e.providedIn)return!1;let n=Ve(e.providedIn);return typeof n=="string"?n==="any"||this.scopes.has(n):this.injectorDefTypes.has(n)}removeOnDestroy(e){let n=this._onDestroyHooks.indexOf(e);n!==-1&&this._onDestroyHooks.splice(n,1)}};function Tc(t){let e=Xi(t),n=e!==null?e.factory:xn(t);if(n!==null)return n;if(t instanceof P)throw new R(204,!1);if(t instanceof Function)return fy(t);throw new R(204,!1)}function fy(t){if(t.length>0)throw new R(204,!1);let n=ey(t);return n!==null?()=>n.factory(t):()=>new t}function py(t){if(Wf(t))return Cr(void 0,t.useValue);{let e=Gc(t);return Cr(e,qi)}}function Gc(t,e,n){let r;if(In(t)){let o=Ve(t);return xn(o)||Tc(o)}else if(Wf(t))r=()=>Ve(t.useValue);else if(dy(t))r=()=>t.useFactory(...Mc(t.deps||[]));else if(uy(t))r=(o,i)=>Q(Ve(t.useExisting),i!==void 0&&i&8?8:void 0);else{let o=Ve(t&&(t.useClass||t.provide));if(hy(t))r=()=>new o(...Mc(t.deps));else return xn(o)||Tc(o)}return r}function ao(t){if(t.destroyed)throw new R(205,!1)}function Cr(t,e,n=!1){return{factory:t,value:e,multi:n?[]:void 0}}function hy(t){return!!t.deps}function gy(t){return t!==null&&typeof t=="object"&&typeof t.ngOnDestroy=="function"}function my(t){return typeof t=="function"||typeof t=="object"&&t.ngMetadataName==="InjectionToken"}function Sc(t,e){for(let n of t)Array.isArray(n)?Sc(n,e):n&&Ac(n)?Sc(n.\u0275providers,e):e(n)}function wr(t,e){let n;t instanceof Mn?(ao(t),n=t):n=new Ic(t);let r,o=xt(n),i=$e(void 0);try{return e()}finally{xt(o),$e(i)}}function qf(){return Lf()!==void 0||fi()!=null}var pt=0,F=1,j=2,Ne=3,rt=4,ze=5,On=6,xr=7,Ee=8,Vt=9,Mt=10,ge=11,Ir=12,qc=13,Pn=14,We=15,Jt=16,Fn=17,Tt=18,go=19,Zc=20,jt=21,os=22,Bt=23,Xe=24,Ln=25,jn=26,_e=27,Zf=1,Yc=6,en=7,mo=8,Vn=9,De=10;function St(t){return Array.isArray(t)&&typeof t[Zf]=="object"}function ht(t){return Array.isArray(t)&&t[Zf]===!0}function Qc(t){return(t.flags&4)!==0}function tn(t){return t.componentOffset>-1}function vo(t){return(t.flags&1)===1}function Nt(t){return!!t.template}function Mr(t){return(t[j]&512)!==0}function Bn(t){return(t[j]&256)===256}var is=(function(t){return t[t.NONE=0]="NONE",t[t.HTML=1]="HTML",t[t.STYLE=2]="STYLE",t[t.SCRIPT=3]="SCRIPT",t[t.URL=4]="URL",t[t.RESOURCE_URL=5]="RESOURCE_URL",t[t.ATTRIBUTE_NO_BINDING=6]="ATTRIBUTE_NO_BINDING",t})(is||{});var Kc="svg",Yf="math";function ot(t){for(;Array.isArray(t);)t=t[pt];return t}function Xc(t,e){return ot(e[t])}function gt(t,e){return ot(e[t.index])}function yo(t,e){return t.data[e]}function Jc(t,e){return t[e]}function el(t,e,n,r){n>=t.data.length&&(t.data[n]=null,t.blueprint[n]=null),e[n]=r}function it(t,e){let n=e[t];return St(n)?n:n[pt]}function Qf(t){return(t[j]&4)===4}function ss(t){return(t[j]&128)===128}function Kf(t){return ht(t[Ne])}function st(t,e){return e==null?null:t[e]}function tl(t){t[Fn]=0}function nl(t){t[j]&1024||(t[j]|=1024,ss(t)&&nn(t))}function Xf(t,e){for(;t>0;)e=e[Pn],t--;return e}function _o(t){return!!(t[j]&9216||t[Xe]?.dirty)}function as(t){t[Mt].changeDetectionScheduler?.notify(8),t[j]&64&&(t[j]|=1024),_o(t)&&nn(t)}function nn(t){t[Mt].changeDetectionScheduler?.notify(0);let e=Kt(t);for(;e!==null&&!(e[j]&8192||(e[j]|=8192,!ss(e)));)e=Kt(e)}function rl(t,e){if(Bn(t))throw new R(911,!1);t[jt]===null&&(t[jt]=[]),t[jt].push(e)}function Jf(t,e){if(t[jt]===null)return;let n=t[jt].indexOf(e);n!==-1&&t[jt].splice(n,1)}function Kt(t){let e=t[Ne];return ht(e)?e[Ne]:e}function ol(t){return t[xr]??=[]}function il(t){return t.cleanup??=[]}function ep(t,e,n,r){let o=ol(e);o.push(n),t.firstCreatePass&&il(t).push(r,o.length-1)}var G={lFrame:dp(null),bindingsEnabled:!0,skipHydrationRootTNode:null};var Nc=!1;function tp(){return G.lFrame.elementDepthCount}function np(){G.lFrame.elementDepthCount++}function sl(){G.lFrame.elementDepthCount--}function al(){return G.bindingsEnabled}function cl(){return G.skipHydrationRootTNode!==null}function ll(t){return G.skipHydrationRootTNode===t}function ul(){G.skipHydrationRootTNode=null}function H(){return G.lFrame.lView}function we(){return G.lFrame.tView}function C(t){return G.lFrame.contextLView=t,t[Ee]}function D(t){return G.lFrame.contextLView=null,t}function Be(){let t=dl();for(;t!==null&&t.type===64;)t=t.parent;return t}function dl(){return G.lFrame.currentTNode}function rp(){let t=G.lFrame,e=t.currentTNode;return t.isParent?e:e.parent}function Tr(t,e){let n=G.lFrame;n.currentTNode=t,n.isParent=e}function fl(){return G.lFrame.isParent}function pl(){G.lFrame.isParent=!1}function hl(){return Nc}function Sr(t){let e=Nc;return Nc=t,e}function gl(){let t=G.lFrame,e=t.bindingRootIndex;return e===-1&&(e=t.bindingRootIndex=t.tView.bindingStartIndex),e}function op(){return G.lFrame.bindingIndex}function ip(t){return G.lFrame.bindingIndex=t}function Hn(){return G.lFrame.bindingIndex++}function cs(t){let e=G.lFrame,n=e.bindingIndex;return e.bindingIndex=e.bindingIndex+t,n}function sp(){return G.lFrame.inI18n}function ap(t,e){let n=G.lFrame;n.bindingIndex=n.bindingRootIndex=t,ls(e)}function cp(){return G.lFrame.currentDirectiveIndex}function ls(t){G.lFrame.currentDirectiveIndex=t}function lp(t){let e=G.lFrame.currentDirectiveIndex;return e===-1?null:t[e]}function us(){return G.lFrame.currentQueryIndex}function bo(t){G.lFrame.currentQueryIndex=t}function vy(t){let e=t[F];return e.type===2?e.declTNode:e.type===1?t[ze]:null}function ml(t,e,n){if(n&4){let o=e,i=t;for(;o=o.parent,o===null&&!(n&1);)if(o=vy(i),o===null||(i=i[Pn],o.type&10))break;if(o===null)return!1;e=o,t=i}let r=G.lFrame=up();return r.currentTNode=e,r.lView=t,!0}function ds(t){let e=up(),n=t[F];G.lFrame=e,e.currentTNode=n.firstChild,e.lView=t,e.tView=n,e.contextLView=t,e.bindingIndex=n.bindingStartIndex,e.inI18n=!1}function up(){let t=G.lFrame,e=t===null?null:t.child;return e===null?dp(t):e}function dp(t){let 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:t,child:null,inI18n:!1};return t!==null&&(t.child=e),e}function fp(){let t=G.lFrame;return G.lFrame=t.parent,t.currentTNode=null,t.lView=null,t}var vl=fp;function fs(){let t=fp();t.isParent=!0,t.tView=null,t.selectedIndex=-1,t.contextLView=null,t.elementDepthCount=0,t.currentDirectiveIndex=-1,t.currentNamespace=null,t.bindingRootIndex=-1,t.bindingIndex=-1,t.currentQueryIndex=0}function pp(t){return(G.lFrame.contextLView=Xf(t,G.lFrame.contextLView))[Ee]}function Rt(){return G.lFrame.selectedIndex}function rn(t){G.lFrame.selectedIndex=t}function ps(){let t=G.lFrame;return yo(t.tView,t.selectedIndex)}function X(){G.lFrame.currentNamespace=Kc}function xe(){yy()}function yy(){G.lFrame.currentNamespace=null}function yl(){return G.lFrame.currentNamespace}var hp=!0;function hs(){return hp}function gs(t){hp=t}function Rc(t,e=null,n=null,r){let o=gp(t,e,n,r);return o.resolveInjectorInitializers(),o}function gp(t,e=null,n=null,r,o=new Set){let i=[n||tt,Uf(t)];return r=r||(typeof t=="object"?void 0:Qt(t)),new Mn(i,e||ho(),r||null,o)}var Ue=class t{static THROW_IF_NOT_FOUND=En;static NULL=new co;static create(e,n){if(Array.isArray(e))return Rc({name:""},n,e,"");{let r=e.name??"";return Rc({name:r},e.parent,e.providers,r)}}static \u0275prov=B({token:t,providedIn:"any",factory:()=>Q(Hc)});static __NG_ELEMENT_ID__=-1},Ae=new P(""),Oe=(()=>{class t{static __NG_ELEMENT_ID__=_y;static __NG_ENV_ID__=n=>n}return t})(),lo=class extends Oe{_lView;constructor(e){super(),this._lView=e}get destroyed(){return Bn(this._lView)}onDestroy(e){let n=this._lView;return rl(n,e),()=>Jf(n,e)}};function _y(){return new lo(H())}var Ke=class{_console=console;handleError(e){this._console.error("ERROR",e)}},mt=new P("",{providedIn:"root",factory:()=>{let t=_(Ge),e;return n=>{t.destroyed&&!e?setTimeout(()=>{throw n}):(e??=t.get(Ke),e.handleError(n))}}}),mp={provide:kn,useValue:()=>{_(Ke)},multi:!0};function b(t,e){let[n,r,o]=ec(t,e?.equal),i=n,s=i[Re];return i.set=r,i.update=o,i.asReadonly=_l.bind(i),i}function _l(){let t=this[Re];if(t.readonlyFn===void 0){let e=()=>this();e[Re]=t,t.readonlyFn=e}return t.readonlyFn}var $n=(()=>{class t{view;node;constructor(n,r){this.view=n,this.node=r}static __NG_ELEMENT_ID__=by}return t})();function by(){return new $n(H(),Be())}var nt=class{},Co=new P("",{providedIn:"root",factory:()=>!1});var bl=new P(""),Cl=new P(""),on=(()=>{class t{taskId=0;pendingTasks=new Set;destroyed=!1;pendingTask=new Xr(!1);get hasPendingTasks(){return this.destroyed?!1:this.pendingTask.value}get hasPendingTasksObservable(){return this.destroyed?new z(n=>{n.next(!1),n.complete()}):this.pendingTask}add(){!this.hasPendingTasks&&!this.destroyed&&this.pendingTask.next(!0);let n=this.taskId++;return this.pendingTasks.add(n),n}has(n){return this.pendingTasks.has(n)}remove(n){this.pendingTasks.delete(n),this.pendingTasks.size===0&&this.hasPendingTasks&&this.pendingTask.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this.hasPendingTasks&&this.pendingTask.next(!1),this.destroyed=!0,this.pendingTask.unsubscribe()}static \u0275prov=B({token:t,providedIn:"root",factory:()=>new t})}return t})(),Nr=(()=>{class t{internalPendingTasks=_(on);scheduler=_(nt);errorHandler=_(mt);add(){let n=this.internalPendingTasks.add();return()=>{this.internalPendingTasks.has(n)&&(this.scheduler.notify(11),this.internalPendingTasks.remove(n))}}run(n){let r=this.add();n().catch(this.errorHandler).finally(r)}static \u0275prov=B({token:t,providedIn:"root",factory:()=>new t})}return t})();function Un(...t){}var Do=(()=>{class t{static \u0275prov=B({token:t,providedIn:"root",factory:()=>new kc})}return t})(),kc=class{dirtyEffectCount=0;queues=new Map;add(e){this.enqueue(e),this.schedule(e)}schedule(e){e.dirty&&this.dirtyEffectCount++}remove(e){let n=e.zone,r=this.queues.get(n);r.has(e)&&(r.delete(e),e.dirty&&this.dirtyEffectCount--)}enqueue(e){let n=e.zone;this.queues.has(n)||this.queues.set(n,new Set);let r=this.queues.get(n);r.has(e)||r.add(e)}flush(){for(;this.dirtyEffectCount>0;){let e=!1;for(let[n,r]of this.queues)n===null?e||=this.flushQueue(r):e||=n.run(()=>this.flushQueue(r));e||(this.dirtyEffectCount=0)}}flushQueue(e){let n=!1;for(let r of e)r.dirty&&(this.dirtyEffectCount--,n=!0,r.run());return n}};function Bs(t){return{toString:t}.toString()}var ms="__parameters__";function Sy(t){return function(...n){if(t){let r=t(...n);for(let o in r)this[o]=r[o]}}}function Wp(t,e,n){return Bs(()=>{let r=Sy(e);function o(...i){if(this instanceof o)return r.apply(this,i),this;let s=new o(...i);return a.annotation=s,a;function a(c,l,u){let f=c.hasOwnProperty(ms)?c[ms]:Object.defineProperty(c,ms,{value:[]})[ms];for(;f.length<=u;)f.push(null);return(f[u]=f[u]||[]).push(s),c}}return o.prototype.ngMetadataName=t,o.annotationCls=o,o})}var uu=Vc(Wp("Inject",t=>({token:t})),-1),du=Vc(Wp("Optional"),8);function Ny(t){return typeof t=="function"}var ws=class{previousValue;currentValue;firstChange;constructor(e,n,r){this.previousValue=e,this.currentValue=n,this.firstChange=r}isFirstChange(){return this.firstChange}};function Gp(t,e,n,r){e!==null?e.applyValueToInputSignal(e,r):t[n]=r}var Hs=(()=>{let t=()=>qp;return t.ngInherit=!0,t})();function qp(t){return t.type.prototype.ngOnChanges&&(t.setInput=ky),Ry}function Ry(){let t=Yp(this),e=t?.current;if(e){let n=t.previous;if(n===Xt)t.previous=e;else for(let r in e)n[r]=e[r];t.current=null,this.ngOnChanges(e)}}function ky(t,e,n,r,o){let i=this.declaredInputs[r],s=Yp(t)||Ay(t,{previous:Xt,current:null}),a=s.current||(s.current={}),c=s.previous,l=c[i];a[i]=new ws(l&&l.currentValue,n,c===Xt),Gp(t,e,o,n)}var Zp="__ngSimpleChanges__";function Yp(t){return t[Zp]||null}function Ay(t,e){return t[Zp]=e}var vp=[];var te=function(t,e=null,n){for(let r=0;r<vp.length;r++){let o=vp[r];o(t,e,n)}};function Oy(t,e,n){let{ngOnChanges:r,ngOnInit:o,ngDoCheck:i}=e.type.prototype;if(r){let s=qp(e);(n.preOrderHooks??=[]).push(t,s),(n.preOrderCheckHooks??=[]).push(t,s)}o&&(n.preOrderHooks??=[]).push(0-t,o),i&&((n.preOrderHooks??=[]).push(t,i),(n.preOrderCheckHooks??=[]).push(t,i))}function Qp(t,e){for(let n=e.directiveStart,r=e.directiveEnd;n<r;n++){let i=t.data[n].type.prototype,{ngAfterContentInit:s,ngAfterContentChecked:a,ngAfterViewInit:c,ngAfterViewChecked:l,ngOnDestroy:u}=i;s&&(t.contentHooks??=[]).push(-n,s),a&&((t.contentHooks??=[]).push(n,a),(t.contentCheckHooks??=[]).push(n,a)),c&&(t.viewHooks??=[]).push(-n,c),l&&((t.viewHooks??=[]).push(n,l),(t.viewCheckHooks??=[]).push(n,l)),u!=null&&(t.destroyHooks??=[]).push(n,u)}}function _s(t,e,n){Kp(t,e,3,n)}function bs(t,e,n,r){(t[j]&3)===n&&Kp(t,e,n,r)}function Dl(t,e){let n=t[j];(n&3)===e&&(n&=16383,n+=1,t[j]=n)}function Kp(t,e,n,r){let o=r!==void 0?t[Fn]&65535:0,i=r??-1,s=e.length-1,a=0;for(let c=o;c<s;c++)if(typeof e[c+1]=="number"){if(a=e[c],r!=null&&a>=r)break}else e[c]<0&&(t[Fn]+=65536),(a<i||i==-1)&&(Py(t,n,e,c),t[Fn]=(t[Fn]&4294901760)+c+2),c++}function yp(t,e){te(4,t,e);let n=L(null);try{e.call(t)}finally{L(n),te(5,t,e)}}function Py(t,e,n,r){let o=n[r]<0,i=n[r+1],s=o?-n[r]:n[r],a=t[s];o?t[j]>>14<t[Fn]>>16&&(t[j]&3)===e&&(t[j]+=16384,yp(a,i)):yp(a,i)}var kr=-1,Wn=class{factory;name;injectImpl;resolving=!1;canSeeViewProviders;multi;componentProviders;index;providerFactory;constructor(e,n,r,o){this.factory=e,this.name=o,this.canSeeViewProviders=n,this.injectImpl=r}};function Fy(t){return(t.flags&8)!==0}function Ly(t){return(t.flags&16)!==0}function jy(t,e,n){let r=0;for(;r<n.length;){let o=n[r];if(typeof o=="number"){if(o!==0)break;r++;let i=n[r++],s=n[r++],a=n[r++];t.setAttribute(e,s,a,i)}else{let i=o,s=n[++r];By(i)?t.setProperty(e,i,s):t.setAttribute(e,i,s),r++}}return r}function Vy(t){return t===3||t===4||t===6}function By(t){return t.charCodeAt(0)===64}function Ar(t,e){if(!(e===null||e.length===0))if(t===null||t.length===0)t=e.slice();else{let n=-1;for(let r=0;r<e.length;r++){let o=e[r];typeof o=="number"?n=o:n===0||(n===-1||n===2?_p(t,n,o,null,e[++r]):_p(t,n,o,null,null))}}return t}function _p(t,e,n,r,o){let i=0,s=t.length;if(e===-1)s=-1;else for(;i<t.length;){let a=t[i++];if(typeof a=="number"){if(a===e){s=-1;break}else if(a>e){s=i-1;break}}}for(;i<t.length;){let a=t[i];if(typeof a=="number")break;if(a===n){o!==null&&(t[i+1]=o);return}i++,o!==null&&i++}s!==-1&&(t.splice(s,0,e),i=s+1),t.splice(i++,0,n),o!==null&&t.splice(i++,0,o)}function Xp(t){return t!==kr}function xs(t){return t&32767}function Hy(t){return t>>16}function Is(t,e){let n=Hy(t),r=e;for(;n>0;)r=r[Pn],n--;return r}var Al=!0;function Ms(t){let e=Al;return Al=t,e}var $y=256,Jp=$y-1,eh=5,Uy=0,kt={};function zy(t,e,n){let r;typeof n=="string"?r=n.charCodeAt(0)||0:n.hasOwnProperty(Nn)&&(r=n[Nn]),r==null&&(r=n[Nn]=Uy++);let o=r&Jp,i=1<<o;e.data[t+(o>>eh)]|=i}function Ts(t,e){let n=th(t,e);if(n!==-1)return n;let r=e[F];r.firstCreatePass&&(t.injectorIndex=e.length,El(r.data,t),El(e,null),El(r.blueprint,null));let o=fu(t,e),i=t.injectorIndex;if(Xp(o)){let s=xs(o),a=Is(o,e),c=a[F].data;for(let l=0;l<8;l++)e[i+l]=a[s+l]|c[s+l]}return e[i+8]=o,i}function El(t,e){t.push(0,0,0,0,0,0,0,0,e)}function th(t,e){return t.injectorIndex===-1||t.parent&&t.parent.injectorIndex===t.injectorIndex||e[t.injectorIndex+8]===null?-1:t.injectorIndex}function fu(t,e){if(t.parent&&t.parent.injectorIndex!==-1)return t.parent.injectorIndex;let n=0,r=null,o=e;for(;o!==null;){if(r=sh(o),r===null)return kr;if(n++,o=o[Pn],r.injectorIndex!==-1)return r.injectorIndex|n<<16}return kr}function Ol(t,e,n){zy(t,e,n)}function nh(t,e,n){if(n&8||t!==void 0)return t;es(e,"NodeInjector")}function rh(t,e,n,r){if(n&8&&r===void 0&&(r=null),(n&3)===0){let o=t[Vt],i=$e(void 0);try{return o?o.get(e,r,n&8):jc(e,r,n&8)}finally{$e(i)}}return nh(r,e,n)}function oh(t,e,n,r=0,o){if(t!==null){if(e[j]&2048&&!(r&2)){let s=Zy(t,e,n,r,kt);if(s!==kt)return s}let i=ih(t,e,n,r,kt);if(i!==kt)return i}return rh(e,n,r,o)}function ih(t,e,n,r,o){let i=Gy(n);if(typeof i=="function"){if(!ml(e,t,r))return r&1?nh(o,n,r):rh(e,n,r,o);try{let s;if(s=i(r),s==null&&!(r&8))es(n);else return s}finally{vl()}}else if(typeof i=="number"){let s=null,a=th(t,e),c=kr,l=r&1?e[We][ze]:null;for((a===-1||r&4)&&(c=a===-1?fu(t,e):e[a+8],c===kr||!Cp(r,!1)?a=-1:(s=e[F],a=xs(c),e=Is(c,e)));a!==-1;){let u=e[F];if(bp(i,a,u.data)){let f=Wy(a,e,n,s,r,l);if(f!==kt)return f}c=e[a+8],c!==kr&&Cp(r,e[F].data[a+8]===l)&&bp(i,a,e)?(s=u,a=xs(c),e=Is(c,e)):a=-1}}return o}function Wy(t,e,n,r,o,i){let s=e[F],a=s.data[t+8],c=r==null?tn(a)&&Al:r!=s&&(a.type&3)!==0,l=o&1&&i===a,u=Cs(a,s,n,c,l);return u!==null?xo(e,s,u,a,o):kt}function Cs(t,e,n,r,o){let i=t.providerIndexes,s=e.data,a=i&1048575,c=t.directiveStart,l=t.directiveEnd,u=i>>20,f=r?a:a+u,m=o?a+u:l;for(let p=f;p<m;p++){let E=s[p];if(p<c&&n===E||p>=c&&E.type===n)return p}if(o){let p=s[c];if(p&&Nt(p)&&p.type===n)return c}return null}function xo(t,e,n,r,o){let i=t[n],s=e.data;if(i instanceof Wn){let a=i;if(a.resolving){let p=Of(s[n]);throw Lc(p)}let c=Ms(a.canSeeViewProviders);a.resolving=!0;let l=s[n].type||s[n],u,f=a.injectImpl?$e(a.injectImpl):null,m=ml(t,r,0);try{i=t[n]=a.factory(void 0,o,s,t,r),e.firstCreatePass&&n>=r.directiveStart&&Oy(n,s[n],e)}finally{f!==null&&$e(f),Ms(c),a.resolving=!1,vl()}}return i}function Gy(t){if(typeof t=="string")return t.charCodeAt(0)||0;let e=t.hasOwnProperty(Nn)?t[Nn]:void 0;return typeof e=="number"?e>=0?e&Jp:qy:e}function bp(t,e,n){let r=1<<t;return!!(n[e+(t>>eh)]&r)}function Cp(t,e){return!(t&2)&&!(t&1&&e)}var zn=class{_tNode;_lView;constructor(e,n){this._tNode=e,this._lView=n}get(e,n,r){return oh(this._tNode,this._lView,e,wn(r),n)}};function qy(){return new zn(Be(),H())}function Zy(t,e,n,r,o){let i=t,s=e;for(;i!==null&&s!==null&&s[j]&2048&&!Mr(s);){let a=ih(i,s,n,r|2,kt);if(a!==kt)return a;let c=i.parent;if(!c){let l=s[Zc];if(l){let u=l.get(n,kt,r);if(u!==kt)return u}c=sh(s),s=s[Pn]}i=c}return o}function sh(t){let e=t[F],n=e.type;return n===2?e.declTNode:n===1?t[ze]:null}function Yy(){return Lr(Be(),H())}function Lr(t,e){return new Ct(gt(t,e))}var Ct=(()=>{class t{nativeElement;constructor(n){this.nativeElement=n}static __NG_ELEMENT_ID__=Yy}return t})();function ah(t){return t instanceof Ct?t.nativeElement:t}function Qy(){return this._results[Symbol.iterator]()}var Ss=class{_emitDistinctChangesOnly;dirty=!0;_onDirty=void 0;_results=[];_changesDetected=!1;_changes=void 0;length=0;first=void 0;last=void 0;get changes(){return this._changes??=new ye}constructor(e=!1){this._emitDistinctChangesOnly=e}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,n){return this._results.reduce(e,n)}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,n){this.dirty=!1;let r=Vf(e);(this._changesDetected=!jf(this._results,r,n))&&(this._results=r,this.length=r.length,this.last=r[this.length-1],this.first=r[0])}notifyOnChanges(){this._changes!==void 0&&(this._changesDetected||!this._emitDistinctChangesOnly)&&this._changes.next(this)}onDirty(e){this._onDirty=e}setDirty(){this.dirty=!0,this._onDirty?.()}destroy(){this._changes!==void 0&&(this._changes.complete(),this._changes.unsubscribe())}[Symbol.iterator]=Qy};function ch(t){return(t.flags&128)===128}var pu=(function(t){return t[t.OnPush=0]="OnPush",t[t.Default=1]="Default",t})(pu||{}),lh=new Map,Ky=0;function Xy(){return Ky++}function Jy(t){lh.set(t[go],t)}function Pl(t){lh.delete(t[go])}var Dp="__ngContext__";function Or(t,e){St(e)?(t[Dp]=e[go],Jy(e)):t[Dp]=e}function uh(t){return fh(t[Ir])}function dh(t){return fh(t[rt])}function fh(t){for(;t!==null&&!ht(t);)t=t[rt];return t}var Fl;function hu(t){Fl=t}function ph(){if(Fl!==void 0)return Fl;if(typeof document<"u")return document;throw new R(210,!1)}var $s=new P("",{providedIn:"root",factory:()=>e_}),e_="ng",Us=new P(""),Zn=new P("",{providedIn:"platform",factory:()=>"unknown"});var zs=new P("",{providedIn:"root",factory:()=>ph().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});var t_="h",n_="b";var hh="r";var gh="di";var mh=!1,vh=new P("",{providedIn:"root",factory:()=>mh});var r_=(t,e,n,r)=>{};function o_(t,e,n,r){r_(t,e,n,r)}function Ws(t){return(t.flags&32)===32}var i_=()=>null;function yh(t,e,n=!1){return i_(t,e,n)}function _h(t,e){let n=t.contentQueries;if(n!==null){let r=L(null);try{for(let o=0;o<n.length;o+=2){let i=n[o],s=n[o+1];if(s!==-1){let a=t.data[s];bo(i),a.contentQueries(2,e[s],s)}}}finally{L(r)}}}function Ll(t,e,n){bo(0);let r=L(null);try{e(t,n)}finally{L(r)}}function bh(t,e,n){if(Qc(e)){let r=L(null);try{let o=e.directiveStart,i=e.directiveEnd;for(let s=o;s<i;s++){let a=t.data[s];if(a.contentQueries){let c=n[s];a.contentQueries(1,c,s)}}}finally{L(r)}}}var Ht=(function(t){return t[t.Emulated=0]="Emulated",t[t.None=2]="None",t[t.ShadowDom=3]="ShadowDom",t})(Ht||{});var Ns=class{changingThisBreaksApplicationSecurity;constructor(e){this.changingThisBreaksApplicationSecurity=e}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${Qi})`}};function Gs(t){return t instanceof Ns?t.changingThisBreaksApplicationSecurity:t}function Ch(t,e){let n=Dh(t);if(n!=null&&n!==e){if(n==="ResourceURL"&&e==="URL")return!0;throw new Error(`Required a safe ${e}, got a ${n} (see ${Qi})`)}return n===e}function Dh(t){return t instanceof Ns&&t.getTypeName()||null}var s_=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\/?#]*(?:[\/?#]|$))/i;function Eh(t){return t=String(t),t.match(s_)?t:"unsafe:"+t}function a_(t,e){return t.createText(e)}function c_(t,e,n){t.setValue(e,n)}function wh(t,e,n){return t.createElement(e,n)}function Rs(t,e,n,r,o){t.insertBefore(e,n,r,o)}function xh(t,e,n){t.appendChild(e,n)}function Ep(t,e,n,r,o){r!==null?Rs(t,e,n,r,o):xh(t,e,n)}function Ih(t,e,n,r){t.removeChild(null,e,n,r)}function l_(t,e,n){t.setAttribute(e,"style",n)}function u_(t,e,n){n===""?t.removeAttribute(e,"class"):t.setAttribute(e,"class",n)}function Mh(t,e,n){let{mergedAttrs:r,classes:o,styles:i}=n;r!==null&&jy(t,e,r),o!==null&&u_(t,e,o),i!==null&&l_(t,e,i)}function Po(t){let e=d_();return e?e.sanitize(is.URL,t)||"":Ch(t,"URL")?Gs(t):Eh(Rn(t))}function d_(){let t=H();return t&&t[Mt].sanitizer}function gu(t){return t.ownerDocument.defaultView}function qe(t){return t.ownerDocument}function f_(t,e,n){let r=t.length;for(;;){let o=t.indexOf(e,n);if(o===-1)return o;if(o===0||t.charCodeAt(o-1)<=32){let i=e.length;if(o+i===r||t.charCodeAt(o+i)<=32)return o}n=o+1}}var Th="ng-template";function p_(t,e,n,r){let o=0;if(r){for(;o<e.length&&typeof e[o]=="string";o+=2)if(e[o]==="class"&&f_(e[o+1].toLowerCase(),n,0)!==-1)return!0}else if(mu(t))return!1;if(o=e.indexOf(1,o),o>-1){let i;for(;++o<e.length&&typeof(i=e[o])=="string";)if(i.toLowerCase()===n)return!0}return!1}function mu(t){return t.type===4&&t.value!==Th}function h_(t,e,n){let r=t.type===4&&!n?Th:t.value;return e===r}function g_(t,e,n){let r=4,o=t.attrs,i=o!==null?y_(o):0,s=!1;for(let a=0;a<e.length;a++){let c=e[a];if(typeof c=="number"){if(!s&&!vt(r)&&!vt(c))return!1;if(s&&vt(c))continue;s=!1,r=c|r&1;continue}if(!s)if(r&4){if(r=2|r&1,c!==""&&!h_(t,c,n)||c===""&&e.length===1){if(vt(r))return!1;s=!0}}else if(r&8){if(o===null||!p_(t,o,c,n)){if(vt(r))return!1;s=!0}}else{let l=e[++a],u=m_(c,o,mu(t),n);if(u===-1){if(vt(r))return!1;s=!0;continue}if(l!==""){let f;if(u>i?f="":f=o[u+1].toLowerCase(),r&2&&l!==f){if(vt(r))return!1;s=!0}}}}return vt(r)||s}function vt(t){return(t&1)===0}function m_(t,e,n,r){if(e===null)return-1;let o=0;if(r||!n){let i=!1;for(;o<e.length;){let s=e[o];if(s===t)return o;if(s===3||s===6)i=!0;else if(s===1||s===2){let a=e[++o];for(;typeof a=="string";)a=e[++o];continue}else{if(s===4)break;if(s===0){o+=4;continue}}o+=i?1:2}return-1}else return __(e,t)}function Sh(t,e,n=!1){for(let r=0;r<e.length;r++)if(g_(t,e[r],n))return!0;return!1}function v_(t){let e=t.attrs;if(e!=null){let n=e.indexOf(5);if((n&1)===0)return e[n+1]}return null}function y_(t){for(let e=0;e<t.length;e++){let n=t[e];if(Vy(n))return e}return t.length}function __(t,e){let n=t.indexOf(4);if(n>-1)for(n++;n<t.length;){let r=t[n];if(typeof r=="number")return-1;if(r===e)return n;n++}return-1}function b_(t,e){e:for(let n=0;n<e.length;n++){let r=e[n];if(t.length===r.length){for(let o=0;o<t.length;o++)if(t[o]!==r[o])continue e;return!0}}return!1}function wp(t,e){return t?":not("+e.trim()+")":e}function C_(t){let e=t[0],n=1,r=2,o="",i=!1;for(;n<t.length;){let s=t[n];if(typeof s=="string")if(r&2){let a=t[++n];o+="["+s+(a.length>0?'="'+a+'"':"")+"]"}else r&8?o+="."+s:r&4&&(o+=" "+s);else o!==""&&!vt(s)&&(e+=wp(i,o),o=""),r=s,i=i||!vt(r);n++}return o!==""&&(e+=wp(i,o)),e}function D_(t){return t.map(C_).join(",")}function E_(t){let e=[],n=[],r=1,o=2;for(;r<t.length;){let i=t[r];if(typeof i=="string")o===2?i!==""&&e.push(i,t[++r]):o===8&&n.push(i);else{if(!vt(o))break;o=i}r++}return n.length&&e.push(1,...n),e}var Ze={};function vu(t,e,n,r,o,i,s,a,c,l,u){let f=_e+r,m=f+o,p=w_(f,m),E=typeof l=="function"?l():l;return p[F]={type:t,blueprint:p,template:n,queries:null,viewQuery:a,declTNode:e,data:p.slice().fill(null,f),bindingStartIndex:f,expandoStartIndex:m,hostBindingOpCodes:null,firstCreatePass:!0,firstUpdatePass:!0,staticViewQueries:!1,staticContentQueries:!1,preOrderHooks:null,preOrderCheckHooks:null,contentHooks:null,contentCheckHooks:null,viewHooks:null,viewCheckHooks:null,destroyHooks:null,cleanup:null,contentQueries:null,components:null,directiveRegistry:typeof i=="function"?i():i,pipeRegistry:typeof s=="function"?s():s,firstChild:null,schemas:c,consts:E,incompleteFirstPass:!1,ssrId:u}}function w_(t,e){let n=[];for(let r=0;r<e;r++)n.push(r<t?null:Ze);return n}function x_(t){let e=t.tView;return e===null||e.incompleteFirstPass?t.tView=vu(1,null,t.template,t.decls,t.vars,t.directiveDefs,t.pipeDefs,t.viewQuery,t.schemas,t.consts,t.id):e}function yu(t,e,n,r,o,i,s,a,c,l,u){let f=e.blueprint.slice();return f[pt]=o,f[j]=r|4|128|8|64|1024,(l!==null||t&&t[j]&2048)&&(f[j]|=2048),tl(f),f[Ne]=f[Pn]=t,f[Ee]=n,f[Mt]=s||t&&t[Mt],f[ge]=a||t&&t[ge],f[Vt]=c||t&&t[Vt]||null,f[ze]=i,f[go]=Xy(),f[On]=u,f[Zc]=l,f[We]=e.type==2?t[We]:f,f}function I_(t,e,n){let r=gt(e,t),o=x_(n),i=t[Mt].rendererFactory,s=_u(t,yu(t,o,null,Nh(n),r,e,null,i.createRenderer(r,n),null,null,null));return t[e.index]=s}function Nh(t){let e=16;return t.signals?e=4096:t.onPush&&(e=64),e}function Rh(t,e,n,r){if(n===0)return-1;let o=e.length;for(let i=0;i<n;i++)e.push(r),t.blueprint.push(r),t.data.push(null);return o}function _u(t,e){return t[Ir]?t[qc][rt]=e:t[Ir]=e,t[qc]=e,e}function d(t=1){kh(we(),H(),Rt()+t,!1)}function kh(t,e,n,r){if(!r)if((e[j]&3)===3){let i=t.preOrderCheckHooks;i!==null&&_s(e,i,n)}else{let i=t.preOrderHooks;i!==null&&bs(e,i,0,n)}rn(n)}var qs=(function(t){return t[t.None=0]="None",t[t.SignalBased=1]="SignalBased",t[t.HasDecoratorInputTransform=2]="HasDecoratorInputTransform",t})(qs||{});function jl(t,e,n,r){let o=L(null);try{let[i,s,a]=t.inputs[n],c=null;(s&qs.SignalBased)!==0&&(c=e[i][Re]),c!==null&&c.transformFn!==void 0?r=c.transformFn(r):a!==null&&(r=a.call(e,r)),t.setInput!==null?t.setInput(e,c,r,n,i):Gp(e,c,i,r)}finally{L(o)}}var At=(function(t){return t[t.Important=1]="Important",t[t.DashCase=2]="DashCase",t})(At||{}),M_;function bu(t,e){return M_(t,e)}var Gn=new Set,Zs=(function(t){return t[t.CHANGE_DETECTION=0]="CHANGE_DETECTION",t[t.AFTER_NEXT_RENDER=1]="AFTER_NEXT_RENDER",t})(Zs||{}),cn=new P(""),xp=new Set;function ln(t){xp.has(t)||(xp.add(t),performance?.mark?.("mark_feature_usage",{detail:{feature:t}}))}var Ah=!1,Vl=class extends ye{__isAsync;destroyRef=void 0;pendingTasks=void 0;constructor(e=!1){super(),this.__isAsync=e,qf()&&(this.destroyRef=_(Oe,{optional:!0})??void 0,this.pendingTasks=_(on,{optional:!0})??void 0)}emit(e){let n=L(null);try{super.next(e)}finally{L(n)}}subscribe(e,n,r){let o=e,i=n||(()=>null),s=r;if(e&&typeof e=="object"){let c=e;o=c.next?.bind(c),i=c.error?.bind(c),s=c.complete?.bind(c)}this.__isAsync&&(i=this.wrapInTimeout(i),o&&(o=this.wrapInTimeout(o)),s&&(s=this.wrapInTimeout(s)));let a=super.subscribe({next:o,error:i,complete:s});return e instanceof me&&e.add(a),a}wrapInTimeout(e){return n=>{let r=this.pendingTasks?.add();setTimeout(()=>{try{e(n)}finally{r!==void 0&&this.pendingTasks?.remove(r)}})}}},_t=Vl;function Oh(t){let e,n;function r(){t=Un;try{n!==void 0&&typeof cancelAnimationFrame=="function"&&cancelAnimationFrame(n),e!==void 0&&clearTimeout(e)}catch{}}return e=setTimeout(()=>{t(),r()}),typeof requestAnimationFrame=="function"&&(n=requestAnimationFrame(()=>{t(),r()})),()=>r()}function Ip(t){return queueMicrotask(()=>t()),()=>{t=Un}}var Cu="isAngularZone",ks=Cu+"_ID",T_=0,ie=class t{hasPendingMacrotasks=!1;hasPendingMicrotasks=!1;isStable=!0;onUnstable=new _t(!1);onMicrotaskEmpty=new _t(!1);onStable=new _t(!1);onError=new _t(!1);constructor(e){let{enableLongStackTrace:n=!1,shouldCoalesceEventChangeDetection:r=!1,shouldCoalesceRunChangeDetection:o=!1,scheduleInRootZone:i=Ah}=e;if(typeof Zone>"u")throw new R(908,!1);Zone.assertZonePatched();let s=this;s._nesting=0,s._outer=s._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(s._inner=s._inner.fork(new Zone.TaskTrackingZoneSpec)),n&&Zone.longStackTraceZoneSpec&&(s._inner=s._inner.fork(Zone.longStackTraceZoneSpec)),s.shouldCoalesceEventChangeDetection=!o&&r,s.shouldCoalesceRunChangeDetection=o,s.callbackScheduled=!1,s.scheduleInRootZone=i,R_(s)}static isInAngularZone(){return typeof Zone<"u"&&Zone.current.get(Cu)===!0}static assertInAngularZone(){if(!t.isInAngularZone())throw new R(909,!1)}static assertNotInAngularZone(){if(t.isInAngularZone())throw new R(909,!1)}run(e,n,r){return this._inner.run(e,n,r)}runTask(e,n,r,o){let i=this._inner,s=i.scheduleEventTask("NgZoneEvent: "+o,e,S_,Un,Un);try{return i.runTask(s,n,r)}finally{i.cancelTask(s)}}runGuarded(e,n,r){return this._inner.runGuarded(e,n,r)}runOutsideAngular(e){return this._outer.run(e)}},S_={};function Du(t){if(t._nesting==0&&!t.hasPendingMicrotasks&&!t.isStable)try{t._nesting++,t.onMicrotaskEmpty.emit(null)}finally{if(t._nesting--,!t.hasPendingMicrotasks)try{t.runOutsideAngular(()=>t.onStable.emit(null))}finally{t.isStable=!0}}}function N_(t){if(t.isCheckStableRunning||t.callbackScheduled)return;t.callbackScheduled=!0;function e(){Oh(()=>{t.callbackScheduled=!1,Bl(t),t.isCheckStableRunning=!0,Du(t),t.isCheckStableRunning=!1})}t.scheduleInRootZone?Zone.root.run(()=>{e()}):t._outer.run(()=>{e()}),Bl(t)}function R_(t){let e=()=>{N_(t)},n=T_++;t._inner=t._inner.fork({name:"angular",properties:{[Cu]:!0,[ks]:n,[ks+n]:!0},onInvokeTask:(r,o,i,s,a,c)=>{if(k_(c))return r.invokeTask(i,s,a,c);try{return Mp(t),r.invokeTask(i,s,a,c)}finally{(t.shouldCoalesceEventChangeDetection&&s.type==="eventTask"||t.shouldCoalesceRunChangeDetection)&&e(),Tp(t)}},onInvoke:(r,o,i,s,a,c,l)=>{try{return Mp(t),r.invoke(i,s,a,c,l)}finally{t.shouldCoalesceRunChangeDetection&&!t.callbackScheduled&&!A_(c)&&e(),Tp(t)}},onHasTask:(r,o,i,s)=>{r.hasTask(i,s),o===i&&(s.change=="microTask"?(t._hasPendingMicrotasks=s.microTask,Bl(t),Du(t)):s.change=="macroTask"&&(t.hasPendingMacrotasks=s.macroTask))},onHandleError:(r,o,i,s)=>(r.handleError(i,s),t.runOutsideAngular(()=>t.onError.emit(s)),!1)})}function Bl(t){t._hasPendingMicrotasks||(t.shouldCoalesceEventChangeDetection||t.shouldCoalesceRunChangeDetection)&&t.callbackScheduled===!0?t.hasPendingMicrotasks=!0:t.hasPendingMicrotasks=!1}function Mp(t){t._nesting++,t.isStable&&(t.isStable=!1,t.onUnstable.emit(null))}function Tp(t){t._nesting--,Du(t)}var As=class{hasPendingMicrotasks=!1;hasPendingMacrotasks=!1;isStable=!0;onUnstable=new _t;onMicrotaskEmpty=new _t;onStable=new _t;onError=new _t;run(e,n,r){return e.apply(n,r)}runGuarded(e,n,r){return e.apply(n,r)}runOutsideAngular(e){return e()}runTask(e,n,r,o){return e.apply(n,r)}};function k_(t){return Ph(t,"__ignore_ng_zone__")}function A_(t){return Ph(t,"__scheduler_tick__")}function Ph(t,e){return!Array.isArray(t)||t.length!==1?!1:t[0]?.data?.[e]===!0}var Ys=(()=>{class t{impl=null;execute(){this.impl?.execute()}static \u0275prov=B({token:t,providedIn:"root",factory:()=>new t})}return t})(),Eu=[0,1,2,3],wu=(()=>{class t{ngZone=_(ie);scheduler=_(nt);errorHandler=_(Ke,{optional:!0});sequences=new Set;deferredRegistrations=new Set;executing=!1;constructor(){_(cn,{optional:!0})}execute(){let n=this.sequences.size>0;n&&te(16),this.executing=!0;for(let r of Eu)for(let o of this.sequences)if(!(o.erroredOrDestroyed||!o.hooks[r]))try{o.pipelinedValue=this.ngZone.runOutsideAngular(()=>this.maybeTrace(()=>{let i=o.hooks[r];return i(o.pipelinedValue)},o.snapshot))}catch(i){o.erroredOrDestroyed=!0,this.errorHandler?.handleError(i)}this.executing=!1;for(let r of this.sequences)r.afterRun(),r.once&&(this.sequences.delete(r),r.destroy());for(let r of this.deferredRegistrations)this.sequences.add(r);this.deferredRegistrations.size>0&&this.scheduler.notify(7),this.deferredRegistrations.clear(),n&&te(17)}register(n){let{view:r}=n;r!==void 0?((r[Ln]??=[]).push(n),nn(r),r[j]|=8192):this.executing?this.deferredRegistrations.add(n):this.addSequence(n)}addSequence(n){this.sequences.add(n),this.scheduler.notify(7)}unregister(n){this.executing&&this.sequences.has(n)?(n.erroredOrDestroyed=!0,n.pipelinedValue=void 0,n.once=!0):(this.sequences.delete(n),this.deferredRegistrations.delete(n))}maybeTrace(n,r){return r?r.run(Zs.AFTER_NEXT_RENDER,n):n()}static \u0275prov=B({token:t,providedIn:"root",factory:()=>new t})}return t})(),Io=class{impl;hooks;view;once;snapshot;erroredOrDestroyed=!1;pipelinedValue=void 0;unregisterOnDestroy;constructor(e,n,r,o,i,s=null){this.impl=e,this.hooks=n,this.view=r,this.once=o,this.snapshot=s,this.unregisterOnDestroy=i?.onDestroy(()=>this.destroy())}afterRun(){this.erroredOrDestroyed=!1,this.pipelinedValue=void 0,this.snapshot?.dispose(),this.snapshot=null}destroy(){this.impl.unregister(this),this.unregisterOnDestroy?.();let e=this.view?.[Ln];e&&(this.view[Ln]=e.filter(n=>n!==this))}};function xu(t,e){let n=e?.injector??_(Ue);return ln("NgAfterNextRender"),P_(t,n,e,!0)}function O_(t){return t instanceof Function?[void 0,void 0,t,void 0]:[t.earlyRead,t.write,t.mixedReadWrite,t.read]}function P_(t,e,n,r){let o=e.get(Ys);o.impl??=e.get(wu);let i=e.get(cn,null,{optional:!0}),s=n?.manualCleanup!==!0?e.get(Oe):null,a=e.get($n,null,{optional:!0}),c=new Io(o.impl,O_(t),a?.view,r,s,i?.snapshot(null));return o.impl.register(c),c}var Fh=new P("",{providedIn:"root",factory:()=>({queue:new Set,isScheduled:!1,scheduler:null})});function Lh(t,e,n){let r=t.get(Fh);if(Array.isArray(e))for(let o of e)r.queue.add(o),n?.detachedLeaveAnimationFns?.push(o);else r.queue.add(e),n?.detachedLeaveAnimationFns?.push(e);r.scheduler&&r.scheduler(t)}function F_(t,e){let n=t.get(Fh);if(e.detachedLeaveAnimationFns){for(let r of e.detachedLeaveAnimationFns)n.queue.delete(r);e.detachedLeaveAnimationFns=void 0}}function L_(t,e){for(let[n,r]of e)Lh(t,r.animateFns)}function Sp(t,e,n,r){let o=t?.[jn]?.enter;e!==null&&o&&o.has(n.index)&&L_(r,o)}function Rr(t,e,n,r,o,i,s,a){if(o!=null){let c,l=!1;ht(o)?c=o:St(o)&&(l=!0,o=o[pt]);let u=ot(o);t===0&&r!==null?(Sp(a,r,i,n),s==null?xh(e,r,u):Rs(e,r,u,s||null,!0)):t===1&&r!==null?(Sp(a,r,i,n),Rs(e,r,u,s||null,!0)):t===2?Np(a,i,n,f=>{Ih(e,u,l,f)}):t===3&&Np(a,i,n,()=>{e.destroyNode(u)}),c!=null&&Z_(e,t,n,c,i,r,s)}}function j_(t,e){jh(t,e),e[pt]=null,e[ze]=null}function V_(t,e,n,r,o,i){r[pt]=o,r[ze]=e,Ks(t,r,n,1,o,i)}function jh(t,e){e[Mt].changeDetectionScheduler?.notify(9),Ks(t,e,e[ge],2,null,null)}function B_(t){let e=t[Ir];if(!e)return wl(t[F],t);for(;e;){let n=null;if(St(e))n=e[Ir];else{let r=e[De];r&&(n=r)}if(!n){for(;e&&!e[rt]&&e!==t;)St(e)&&wl(e[F],e),e=e[Ne];e===null&&(e=t),St(e)&&wl(e[F],e),n=e&&e[rt]}e=n}}function Iu(t,e){let n=t[Vn],r=n.indexOf(e);n.splice(r,1)}function Qs(t,e){if(Bn(e))return;let n=e[ge];n.destroyNode&&Ks(t,e,n,3,null,null),B_(e)}function wl(t,e){if(Bn(e))return;let n=L(null);try{e[j]&=-129,e[j]|=256,e[Xe]&&qt(e[Xe]),U_(t,e),$_(t,e),e[F].type===1&&e[ge].destroy();let r=e[Jt];if(r!==null&&ht(e[Ne])){r!==e[Ne]&&Iu(r,e);let o=e[Tt];o!==null&&o.detachView(t)}Pl(e)}finally{L(n)}}function Np(t,e,n,r){let o=t?.[jn];if(o==null||o.leave==null||!o.leave.has(e.index))return r(!1);t&&Gn.add(t),Lh(n,()=>{if(o.leave&&o.leave.has(e.index)){let s=o.leave.get(e.index),a=[];if(s){for(let c=0;c<s.animateFns.length;c++){let l=s.animateFns[c],{promise:u}=l();a.push(u)}o.detachedLeaveAnimationFns=void 0}o.running=Promise.allSettled(a),H_(t,r)}else t&&Gn.delete(t),r(!1)},o)}function H_(t,e){let n=t[jn]?.running;if(n){n.then(()=>{t[jn].running=void 0,Gn.delete(t),e(!0)});return}e(!1)}function $_(t,e){let n=t.cleanup,r=e[xr];if(n!==null)for(let s=0;s<n.length-1;s+=2)if(typeof n[s]=="string"){let a=n[s+3];a>=0?r[a]():r[-a].unsubscribe(),s+=2}else{let a=r[n[s+1]];n[s].call(a)}r!==null&&(e[xr]=null);let o=e[jt];if(o!==null){e[jt]=null;for(let s=0;s<o.length;s++){let a=o[s];a()}}let i=e[Bt];if(i!==null){e[Bt]=null;for(let s of i)s.destroy()}}function U_(t,e){let n;if(t!=null&&(n=t.destroyHooks)!=null)for(let r=0;r<n.length;r+=2){let o=e[n[r]];if(!(o instanceof Wn)){let i=n[r+1];if(Array.isArray(i))for(let s=0;s<i.length;s+=2){let a=o[i[s]],c=i[s+1];te(4,a,c);try{c.call(a)}finally{te(5,a,c)}}else{te(4,o,i);try{i.call(o)}finally{te(5,o,i)}}}}}function Vh(t,e,n){return z_(t,e.parent,n)}function z_(t,e,n){let r=e;for(;r!==null&&r.type&168;)e=r,r=e.parent;if(r===null)return n[pt];if(tn(r)){let{encapsulation:o}=t.data[r.directiveStart+r.componentOffset];if(o===Ht.None||o===Ht.Emulated)return null}return gt(r,n)}function Bh(t,e,n){return G_(t,e,n)}function W_(t,e,n){return t.type&40?gt(t,n):null}var G_=W_,Rp;function Mu(t,e,n,r){let o=Vh(t,r,e),i=e[ge],s=r.parent||e[ze],a=Bh(s,r,e);if(o!=null)if(Array.isArray(n))for(let c=0;c<n.length;c++)Ep(i,o,n[c],a,!1);else Ep(i,o,n,a,!1);Rp!==void 0&&Rp(i,r,e,n,o)}function Eo(t,e){if(e!==null){let n=e.type;if(n&3)return gt(e,t);if(n&4)return Hl(-1,t[e.index]);if(n&8){let r=e.child;if(r!==null)return Eo(t,r);{let o=t[e.index];return ht(o)?Hl(-1,o):ot(o)}}else{if(n&128)return Eo(t,e.next);if(n&32)return bu(e,t)()||ot(t[e.index]);{let r=Hh(t,e);if(r!==null){if(Array.isArray(r))return r[0];let o=Kt(t[We]);return Eo(o,r)}else return Eo(t,e.next)}}}return null}function Hh(t,e){if(e!==null){let r=t[We][ze],o=e.projection;return r.projection[o]}return null}function Hl(t,e){let n=De+t+1;if(n<e.length){let r=e[n],o=r[F].firstChild;if(o!==null)return Eo(r,o)}return e[en]}function Tu(t,e,n,r,o,i,s){for(;n!=null;){let a=r[Vt];if(n.type===128){n=n.next;continue}let c=r[n.index],l=n.type;if(s&&e===0&&(c&&Or(ot(c),r),n.flags|=2),!Ws(n))if(l&8)Tu(t,e,n.child,r,o,i,!1),Rr(e,t,a,o,c,n,i,r);else if(l&32){let u=bu(n,r),f;for(;f=u();)Rr(e,t,a,o,f,n,i,r);Rr(e,t,a,o,c,n,i,r)}else l&16?$h(t,e,r,n,o,i):Rr(e,t,a,o,c,n,i,r);n=s?n.projectionNext:n.next}}function Ks(t,e,n,r,o,i){Tu(n,r,t.firstChild,e,o,i,!1)}function q_(t,e,n){let r=e[ge],o=Vh(t,n,e),i=n.parent||e[ze],s=Bh(i,n,e);$h(r,0,e,n,o,s)}function $h(t,e,n,r,o,i){let s=n[We],c=s[ze].projection[r.projection];if(Array.isArray(c))for(let l=0;l<c.length;l++){let u=c[l];Rr(e,t,n[Vt],o,u,r,i,n)}else{let l=c,u=s[Ne];ch(r)&&(l.flags|=128),Tu(t,e,l,u,o,i,!0)}}function Z_(t,e,n,r,o,i,s){let a=r[en],c=ot(r);a!==c&&Rr(e,t,n,i,a,o,s);for(let l=De;l<r.length;l++){let u=r[l];Ks(u[F],u,t,e,i,a)}}function Y_(t,e,n,r,o){if(e)o?t.addClass(n,r):t.removeClass(n,r);else{let i=r.indexOf("-")===-1?void 0:At.DashCase;o==null?t.removeStyle(n,r,i):(typeof o=="string"&&o.endsWith("!important")&&(o=o.slice(0,-10),i|=At.Important),t.setStyle(n,r,o,i))}}function Uh(t,e,n,r,o){let i=Rt(),s=r&2;try{rn(-1),s&&e.length>_e&&kh(t,e,_e,!1),te(s?2:0,o,n),n(r,o)}finally{rn(i),te(s?3:1,o,n)}}function Su(t,e,n){n0(t,e,n),(n.flags&64)===64&&r0(t,e,n)}function Xs(t,e,n=gt){let r=e.localNames;if(r!==null){let o=e.index+1;for(let i=0;i<r.length;i+=2){let s=r[i+1],a=s===-1?n(e,t):t[s];t[o++]=a}}}function Q_(t,e,n,r){let i=r.get(vh,mh)||n===Ht.ShadowDom,s=t.selectRootElement(e,i);return K_(s),s}function K_(t){X_(t)}var X_=()=>null;function J_(t){return t==="class"?"className":t==="for"?"htmlFor":t==="formaction"?"formAction":t==="innerHtml"?"innerHTML":t==="readonly"?"readOnly":t==="tabindex"?"tabIndex":t}function e0(t,e,n,r,o,i){let s=e[F];if(Nu(t,s,e,n,r)){tn(t)&&t0(e,t.index);return}t.type&3&&(n=J_(n)),zh(t,e,n,r,o,i)}function zh(t,e,n,r,o,i){if(t.type&3){let s=gt(t,e);r=i!=null?i(r,t.value||"",n):r,o.setProperty(s,n,r)}else t.type&12}function t0(t,e){let n=it(e,t);n[j]&16||(n[j]|=64)}function n0(t,e,n){let r=n.directiveStart,o=n.directiveEnd;tn(n)&&I_(e,n,t.data[r+n.componentOffset]),t.firstCreatePass||Ts(n,e);let i=n.initialInputs;for(let s=r;s<o;s++){let a=t.data[s],c=xo(e,t,s,n);if(Or(c,e),i!==null&&a0(e,s-r,c,a,n,i),Nt(a)){let l=it(n.index,e);l[Ee]=xo(e,t,s,n)}}}function r0(t,e,n){let r=n.directiveStart,o=n.directiveEnd,i=n.index,s=cp();try{rn(i);for(let a=r;a<o;a++){let c=t.data[a],l=e[a];ls(a),(c.hostBindings!==null||c.hostVars!==0||c.hostAttrs!==null)&&o0(c,l)}}finally{rn(-1),ls(s)}}function o0(t,e){t.hostBindings!==null&&t.hostBindings(1,e)}function Wh(t,e){let n=t.directiveRegistry,r=null;if(n)for(let o=0;o<n.length;o++){let i=n[o];Sh(e,i.selectors,!1)&&(r??=[],Nt(i)?r.unshift(i):r.push(i))}return r}function i0(t,e,n,r,o,i){let s=gt(t,e);s0(e[ge],s,i,t.value,n,r,o)}function s0(t,e,n,r,o,i,s){if(i==null)t.removeAttribute(e,o,n);else{let a=s==null?Rn(i):s(i,r||"",o);t.setAttribute(e,o,a,n)}}function a0(t,e,n,r,o,i){let s=i[e];if(s!==null)for(let a=0;a<s.length;a+=2){let c=s[a],l=s[a+1];jl(r,n,c,l)}}function Gh(t,e,n,r,o){let i=_e+n,s=e[F],a=o(s,e,t,r,n);e[i]=a,Tr(t,!0);let c=t.type===2;return c?(Mh(e[ge],a,t),(tp()===0||vo(t))&&Or(a,e),np()):Or(a,e),hs()&&(!c||!Ws(t))&&Mu(s,e,a,t),t}function qh(t){let e=t;return fl()?pl():(e=e.parent,Tr(e,!1)),e}function c0(t,e){let n=t[Vt];if(!n)return;let r;try{r=n.get(mt,null)}catch{r=null}r?.(e)}function Nu(t,e,n,r,o){let i=t.inputs?.[r],s=t.hostDirectiveInputs?.[r],a=!1;if(s)for(let c=0;c<s.length;c+=2){let l=s[c],u=s[c+1],f=e.data[l];jl(f,n[l],u,o),a=!0}if(i)for(let c of i){let l=n[c],u=e.data[c];jl(u,l,r,o),a=!0}return a}function l0(t,e){let n=it(e,t),r=n[F];u0(r,n);let o=n[pt];o!==null&&n[On]===null&&(n[On]=yh(o,n[Vt])),te(18),Ru(r,n,n[Ee]),te(19,n[Ee])}function u0(t,e){for(let n=e.length;n<t.blueprint.length;n++)e.push(t.blueprint[n])}function Ru(t,e,n){ds(e);try{let r=t.viewQuery;r!==null&&Ll(1,r,n);let o=t.template;o!==null&&Uh(t,e,o,1,n),t.firstCreatePass&&(t.firstCreatePass=!1),e[Tt]?.finishViewCreation(t),t.staticContentQueries&&_h(t,e),t.staticViewQueries&&Ll(2,t.viewQuery,n);let i=t.components;i!==null&&d0(e,i)}catch(r){throw t.firstCreatePass&&(t.incompleteFirstPass=!0,t.firstCreatePass=!1),r}finally{e[j]&=-5,fs()}}function d0(t,e){for(let n=0;n<e.length;n++)l0(t,e[n])}function Fo(t,e,n,r){let o=L(null);try{let i=e.tView,a=t[j]&4096?4096:16,c=yu(t,i,n,a,null,e,null,null,r?.injector??null,r?.embeddedViewInjector??null,r?.dehydratedView??null),l=t[e.index];c[Jt]=l;let u=t[Tt];return u!==null&&(c[Tt]=u.createEmbeddedView(i)),Ru(i,c,n),c}finally{L(o)}}function Pr(t,e){return!e||e.firstChild===null||ch(t)}function Mo(t,e,n,r,o=!1){for(;n!==null;){if(n.type===128){n=o?n.projectionNext:n.next;continue}let i=e[n.index];i!==null&&r.push(ot(i)),ht(i)&&Zh(i,r);let s=n.type;if(s&8)Mo(t,e,n.child,r);else if(s&32){let a=bu(n,e),c;for(;c=a();)r.push(c)}else if(s&16){let a=Hh(e,n);if(Array.isArray(a))r.push(...a);else{let c=Kt(e[We]);Mo(c[F],c,a,r,!0)}}n=o?n.projectionNext:n.next}return r}function Zh(t,e){for(let n=De;n<t.length;n++){let r=t[n],o=r[F].firstChild;o!==null&&Mo(r[F],r,o,e)}t[en]!==t[pt]&&e.push(t[en])}function Yh(t){if(t[Ln]!==null){for(let e of t[Ln])e.impl.addSequence(e);t[Ln].length=0}}var Qh=[];function f0(t){return t[Xe]??p0(t)}function p0(t){let e=Qh.pop()??Object.create(g0);return e.lView=t,e}function h0(t){t.lView[Xe]!==t&&(t.lView=null,Qh.push(t))}var g0=le(K({},pn),{consumerIsAlwaysLive:!0,kind:"template",consumerMarkedDirty:t=>{nn(t.lView)},consumerOnSignalRead(){this.lView[Xe]=this}});function m0(t){let e=t[Xe]??Object.create(v0);return e.lView=t,e}var v0=le(K({},pn),{consumerIsAlwaysLive:!0,kind:"template",consumerMarkedDirty:t=>{let e=Kt(t.lView);for(;e&&!Kh(e[F]);)e=Kt(e);e&&nl(e)},consumerOnSignalRead(){this.lView[Xe]=this}});function Kh(t){return t.type!==2}function Xh(t){if(t[Bt]===null)return;let e=!0;for(;e;){let n=!1;for(let r of t[Bt])r.dirty&&(n=!0,r.zone===null||Zone.current===r.zone?r.run():r.zone.run(()=>r.run()));e=n&&!!(t[j]&8192)}}var y0=100;function Jh(t,e=0){let r=t[Mt].rendererFactory,o=!1;o||r.begin?.();try{_0(t,e)}finally{o||r.end?.()}}function _0(t,e){let n=hl();try{Sr(!0),$l(t,e);let r=0;for(;_o(t);){if(r===y0)throw new R(103,!1);r++,$l(t,1)}}finally{Sr(n)}}function b0(t,e,n,r){if(Bn(e))return;let o=e[j],i=!1,s=!1;ds(e);let a=!0,c=null,l=null;i||(Kh(t)?(l=f0(e),c=Gt(l)):vi()===null?(a=!1,l=m0(e),c=Gt(l)):e[Xe]&&(qt(e[Xe]),e[Xe]=null));try{tl(e),ip(t.bindingStartIndex),n!==null&&Uh(t,e,n,2,r);let u=(o&3)===3;if(!i)if(u){let p=t.preOrderCheckHooks;p!==null&&_s(e,p,null)}else{let p=t.preOrderHooks;p!==null&&bs(e,p,0,null),Dl(e,0)}if(s||C0(e),Xh(e),eg(e,0),t.contentQueries!==null&&_h(t,e),!i)if(u){let p=t.contentCheckHooks;p!==null&&_s(e,p)}else{let p=t.contentHooks;p!==null&&bs(e,p,1),Dl(e,1)}E0(t,e);let f=t.components;f!==null&&ng(e,f,0);let m=t.viewQuery;if(m!==null&&Ll(2,m,r),!i)if(u){let p=t.viewCheckHooks;p!==null&&_s(e,p)}else{let p=t.viewHooks;p!==null&&bs(e,p,2),Dl(e,2)}if(t.firstUpdatePass===!0&&(t.firstUpdatePass=!1),e[os]){for(let p of e[os])p();e[os]=null}i||(Yh(e),e[j]&=-73)}catch(u){throw i||nn(e),u}finally{l!==null&&(gn(l,c),a&&h0(l)),fs()}}function eg(t,e){for(let n=uh(t);n!==null;n=dh(n))for(let r=De;r<n.length;r++){let o=n[r];tg(o,e)}}function C0(t){for(let e=uh(t);e!==null;e=dh(e)){if(!(e[j]&2))continue;let n=e[Vn];for(let r=0;r<n.length;r++){let o=n[r];nl(o)}}}function D0(t,e,n){te(18);let r=it(e,t);tg(r,n),te(19,r[Ee])}function tg(t,e){ss(t)&&$l(t,e)}function $l(t,e){let r=t[F],o=t[j],i=t[Xe],s=!!(e===0&&o&16);if(s||=!!(o&64&&e===0),s||=!!(o&1024),s||=!!(i?.dirty&&mn(i)),s||=!1,i&&(i.dirty=!1),t[j]&=-9217,s)b0(r,t,r.template,t[Ee]);else if(o&8192){let a=L(null);try{Xh(t),eg(t,1);let c=r.components;c!==null&&ng(t,c,1),Yh(t)}finally{L(a)}}}function ng(t,e,n){for(let r=0;r<e.length;r++)D0(t,e[r],n)}function E0(t,e){let n=t.hostBindingOpCodes;if(n!==null)try{for(let r=0;r<n.length;r++){let o=n[r];if(o<0)rn(~o);else{let i=o,s=n[++r],a=n[++r];ap(s,i);let c=e[i];te(24,c),a(2,c),te(25,c)}}}finally{rn(-1)}}function ku(t,e){let n=hl()?64:1088;for(t[Mt].changeDetectionScheduler?.notify(e);t;){t[j]|=n;let r=Kt(t);if(Mr(t)&&!r)return t;t=r}return null}function rg(t,e,n,r){return[t,!0,0,e,null,r,null,n,null,null]}function og(t,e){let n=De+e;if(n<t.length)return t[n]}function Lo(t,e,n,r=!0){let o=e[F];if(w0(o,e,t,n),r){let s=Hl(n,t),a=e[ge],c=a.parentNode(t[en]);c!==null&&V_(o,t[ze],a,e,c,s)}let i=e[On];i!==null&&i.firstChild!==null&&(i.firstChild=null)}function ig(t,e){let n=To(t,e);return n!==void 0&&Qs(n[F],n),n}function To(t,e){if(t.length<=De)return;let n=De+e,r=t[n];if(r){let o=r[Jt];o!==null&&o!==t&&Iu(o,r),e>0&&(t[n-1][rt]=r[rt]);let i=uo(t,De+e);j_(r[F],r);let s=i[Tt];s!==null&&s.detachView(i[F]),r[Ne]=null,r[rt]=null,r[j]&=-129}return r}function w0(t,e,n,r){let o=De+r,i=n.length;r>0&&(n[o-1][rt]=e),r<i-De?(e[rt]=n[o],Bc(n,De+r,e)):(n.push(e),e[rt]=null),e[Ne]=n;let s=e[Jt];s!==null&&n!==s&&sg(s,e);let a=e[Tt];a!==null&&a.insertView(t),as(e),e[j]|=128}function sg(t,e){let n=t[Vn],r=e[Ne];if(St(r))t[j]|=2;else{let o=r[Ne][We];e[We]!==o&&(t[j]|=2)}n===null?t[Vn]=[e]:n.push(e)}var sn=class{_lView;_cdRefInjectingView;_appRef=null;_attachedToViewContainer=!1;exhaustive;get rootNodes(){let e=this._lView,n=e[F];return Mo(n,e,n.firstChild,[])}constructor(e,n){this._lView=e,this._cdRefInjectingView=n}get context(){return this._lView[Ee]}set context(e){this._lView[Ee]=e}get destroyed(){return Bn(this._lView)}destroy(){if(this._appRef)this._appRef.detachView(this);else if(this._attachedToViewContainer){let e=this._lView[Ne];if(ht(e)){let n=e[mo],r=n?n.indexOf(this):-1;r>-1&&(To(e,r),uo(n,r))}this._attachedToViewContainer=!1}Qs(this._lView[F],this._lView)}onDestroy(e){rl(this._lView,e)}markForCheck(){ku(this._cdRefInjectingView||this._lView,4)}detach(){this._lView[j]&=-129}reattach(){as(this._lView),this._lView[j]|=128}detectChanges(){this._lView[j]|=1024,Jh(this._lView)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new R(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null;let e=Mr(this._lView),n=this._lView[Jt];n!==null&&!e&&Iu(n,this._lView),jh(this._lView[F],this._lView)}attachToAppRef(e){if(this._attachedToViewContainer)throw new R(902,!1);this._appRef=e;let n=Mr(this._lView),r=this._lView[Jt];r!==null&&!n&&sg(r,this._lView),as(this._lView)}};var an=(()=>{class t{_declarationLView;_declarationTContainer;elementRef;static __NG_ELEMENT_ID__=x0;constructor(n,r,o){this._declarationLView=n,this._declarationTContainer=r,this.elementRef=o}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(n,r){return this.createEmbeddedViewImpl(n,r)}createEmbeddedViewImpl(n,r,o){let i=Fo(this._declarationLView,this._declarationTContainer,n,{embeddedViewInjector:r,dehydratedView:o});return new sn(i)}}return t})();function x0(){return Au(Be(),H())}function Au(t,e){return t.type&4?new an(e,t,Lr(t,e)):null}function jr(t,e,n,r,o){let i=t.data[e];if(i===null)i=I0(t,e,n,r,o),sp()&&(i.flags|=32);else if(i.type&64){i.type=n,i.value=r,i.attrs=o;let s=rp();i.injectorIndex=s===null?-1:s.injectorIndex}return Tr(i,!0),i}function I0(t,e,n,r,o){let i=dl(),s=fl(),a=s?i:i&&i.parent,c=t.data[e]=T0(t,a,n,e,r,o);return M0(t,c,i,s),c}function M0(t,e,n,r){t.firstChild===null&&(t.firstChild=e),n!==null&&(r?n.child==null&&e.parent!==null&&(n.child=e):n.next===null&&(n.next=e,e.prev=n))}function T0(t,e,n,r,o,i){let s=e?e.injectorIndex:-1,a=0;return cl()&&(a|=128),{type:n,index:r,insertBeforeIndex:null,injectorIndex:s,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:o,namespace:yl(),attrs:i,mergedAttrs:null,localNames:null,initialInputs:null,inputs:null,hostDirectiveInputs:null,outputs:null,hostDirectiveOutputs:null,directiveToIndex:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:e,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}var pk=new RegExp(`^(\\d+)*(${n_}|${t_})*(.*)`);function S0(t){let e=t[Yc]??[],r=t[Ne][ge],o=[];for(let i of e)i.data[gh]!==void 0?o.push(i):N0(i,r);t[Yc]=o}function N0(t,e){let n=0,r=t.firstChild;if(r){let o=t.data[hh];for(;n<o;){let i=r.nextSibling;Ih(e,r,!1),r=i,n++}}}var R0=()=>null,k0=()=>null;function Os(t,e){return R0(t,e)}function ag(t,e,n){return k0(t,e,n)}var cg=class{},Js=class{},Ul=class{resolveComponentFactory(e){throw new R(917,!1)}},ea=class{static NULL=new Ul},Ot=class{},ta=(()=>{class t{destroyNode=null;static __NG_ELEMENT_ID__=()=>A0()}return t})();function A0(){let t=H(),e=Be(),n=it(e.index,t);return(St(n)?n:t)[ge]}var lg=(()=>{class t{static \u0275prov=B({token:t,providedIn:"root",factory:()=>null})}return t})();var Ds={},zl=class{injector;parentInjector;constructor(e,n){this.injector=e,this.parentInjector=n}get(e,n,r){let o=this.injector.get(e,Ds,r);return o!==Ds||n===Ds?o:this.parentInjector.get(e,n,r)}};function Ps(t,e,n){let r=n?t.styles:null,o=n?t.classes:null,i=0;if(e!==null)for(let s=0;s<e.length;s++){let a=e[s];if(typeof a=="number")i=a;else if(i==1)o=Ki(o,a);else if(i==2){let c=a,l=e[++s];r=Ki(r,c+": "+l+";")}}n?t.styles=r:t.stylesWithoutHost=r,n?t.classes=o:t.classesWithoutHost=o}function Pt(t,e=0){let n=H();if(n===null)return Q(t,e);let r=Be();return oh(r,n,Ve(t),e)}function ug(t,e,n,r,o){let i=r===null?null:{"":-1},s=o(t,n);if(s!==null){let a=s,c=null,l=null;for(let u of s)if(u.resolveHostDirectives!==null){[a,c,l]=u.resolveHostDirectives(s);break}F0(t,e,n,a,i,c,l)}i!==null&&r!==null&&O0(n,r,i)}function O0(t,e,n){let r=t.localNames=[];for(let o=0;o<e.length;o+=2){let i=n[e[o+1]];if(i==null)throw new R(-301,!1);r.push(e[o],i)}}function P0(t,e,n){e.componentOffset=n,(t.components??=[]).push(e.index)}function F0(t,e,n,r,o,i,s){let a=r.length,c=!1;for(let m=0;m<a;m++){let p=r[m];!c&&Nt(p)&&(c=!0,P0(t,n,m)),Ol(Ts(n,e),t,p.type)}$0(n,t.data.length,a);for(let m=0;m<a;m++){let p=r[m];p.providersResolver&&p.providersResolver(p)}let l=!1,u=!1,f=Rh(t,e,a,null);a>0&&(n.directiveToIndex=new Map);for(let m=0;m<a;m++){let p=r[m];if(n.mergedAttrs=Ar(n.mergedAttrs,p.hostAttrs),j0(t,n,e,f,p),H0(f,p,o),s!==null&&s.has(p)){let[N,k]=s.get(p);n.directiveToIndex.set(p.type,[f,N+n.directiveStart,k+n.directiveStart])}else(i===null||!i.has(p))&&n.directiveToIndex.set(p.type,f);p.contentQueries!==null&&(n.flags|=4),(p.hostBindings!==null||p.hostAttrs!==null||p.hostVars!==0)&&(n.flags|=64);let E=p.type.prototype;!l&&(E.ngOnChanges||E.ngOnInit||E.ngDoCheck)&&((t.preOrderHooks??=[]).push(n.index),l=!0),!u&&(E.ngOnChanges||E.ngDoCheck)&&((t.preOrderCheckHooks??=[]).push(n.index),u=!0),f++}L0(t,n,i)}function L0(t,e,n){for(let r=e.directiveStart;r<e.directiveEnd;r++){let o=t.data[r];if(n===null||!n.has(o))kp(0,e,o,r),kp(1,e,o,r),Op(e,r,!1);else{let i=n.get(o);Ap(0,e,i,r),Ap(1,e,i,r),Op(e,r,!0)}}}function kp(t,e,n,r){let o=t===0?n.inputs:n.outputs;for(let i in o)if(o.hasOwnProperty(i)){let s;t===0?s=e.inputs??={}:s=e.outputs??={},s[i]??=[],s[i].push(r),dg(e,i)}}function Ap(t,e,n,r){let o=t===0?n.inputs:n.outputs;for(let i in o)if(o.hasOwnProperty(i)){let s=o[i],a;t===0?a=e.hostDirectiveInputs??={}:a=e.hostDirectiveOutputs??={},a[s]??=[],a[s].push(r,i),dg(e,s)}}function dg(t,e){e==="class"?t.flags|=8:e==="style"&&(t.flags|=16)}function Op(t,e,n){let{attrs:r,inputs:o,hostDirectiveInputs:i}=t;if(r===null||!n&&o===null||n&&i===null||mu(t)){t.initialInputs??=[],t.initialInputs.push(null);return}let s=null,a=0;for(;a<r.length;){let c=r[a];if(c===0){a+=4;continue}else if(c===5){a+=2;continue}else if(typeof c=="number")break;if(!n&&o.hasOwnProperty(c)){let l=o[c];for(let u of l)if(u===e){s??=[],s.push(c,r[a+1]);break}}else if(n&&i.hasOwnProperty(c)){let l=i[c];for(let u=0;u<l.length;u+=2)if(l[u]===e){s??=[],s.push(l[u+1],r[a+1]);break}}a+=2}t.initialInputs??=[],t.initialInputs.push(s)}function j0(t,e,n,r,o){t.data[r]=o;let i=o.factory||(o.factory=xn(o.type,!0)),s=new Wn(i,Nt(o),Pt,null);t.blueprint[r]=s,n[r]=s,V0(t,e,r,Rh(t,n,o.hostVars,Ze),o)}function V0(t,e,n,r,o){let i=o.hostBindings;if(i){let s=t.hostBindingOpCodes;s===null&&(s=t.hostBindingOpCodes=[]);let a=~e.index;B0(s)!=a&&s.push(a),s.push(n,r,i)}}function B0(t){let e=t.length;for(;e>0;){let n=t[--e];if(typeof n=="number"&&n<0)return n}return 0}function H0(t,e,n){if(n){if(e.exportAs)for(let r=0;r<e.exportAs.length;r++)n[e.exportAs[r]]=t;Nt(e)&&(n[""]=t)}}function $0(t,e,n){t.flags|=1,t.directiveStart=e,t.directiveEnd=e+n,t.providerIndexes=e}function fg(t,e,n,r,o,i,s,a){let c=e[F],l=c.consts,u=st(l,s),f=jr(c,t,n,r,u);return i&&ug(c,e,f,st(l,a),o),f.mergedAttrs=Ar(f.mergedAttrs,f.attrs),f.attrs!==null&&Ps(f,f.attrs,!1),f.mergedAttrs!==null&&Ps(f,f.mergedAttrs,!0),c.queries!==null&&c.queries.elementStart(c,f),f}function pg(t,e){Qp(t,e),Qc(e)&&t.queries.elementEnd(e)}function U0(t,e,n,r,o,i){let s=e.consts,a=st(s,o),c=jr(e,t,n,r,a);if(c.mergedAttrs=Ar(c.mergedAttrs,c.attrs),i!=null){let l=st(s,i);c.localNames=[];for(let u=0;u<l.length;u+=2)c.localNames.push(l[u],-1)}return c.attrs!==null&&Ps(c,c.attrs,!1),c.mergedAttrs!==null&&Ps(c,c.mergedAttrs,!0),e.queries!==null&&e.queries.elementStart(e,c),c}function Ou(t){return gg(t)?Array.isArray(t)||!(t instanceof Map)&&Symbol.iterator in t:!1}function hg(t,e){if(Array.isArray(t))for(let n=0;n<t.length;n++)e(t[n]);else{let n=t[Symbol.iterator](),r;for(;!(r=n.next()).done;)e(r.value)}}function gg(t){return t!==null&&(typeof t=="function"||typeof t=="object")}function mg(t,e,n){return t[e]=n}function bt(t,e,n){if(n===Ze)return!1;let r=t[e];return Object.is(r,n)?!1:(t[e]=n,!0)}function vg(t,e,n,r){let o=bt(t,e,n);return bt(t,e+1,r)||o}function Es(t,e,n){return function r(o){let i=tn(t)?it(t.index,e):e;ku(i,5);let s=e[Ee],a=Pp(e,s,n,o),c=r.__ngNextListenerFn__;for(;c;)a=Pp(e,s,c,o)&&a,c=c.__ngNextListenerFn__;return a}}function Pp(t,e,n,r){let o=L(null);try{return te(6,e,n),n(r)!==!1}catch(i){return c0(t,i),!1}finally{te(7,e,n),L(o)}}function yg(t,e,n,r,o,i,s,a){let c=vo(t),l=!1,u=null;if(!r&&c&&(u=W0(e,n,i,t.index)),u!==null){let f=u.__ngLastListenerFn__||u;f.__ngNextListenerFn__=s,u.__ngLastListenerFn__=s,l=!0}else{let f=gt(t,n),m=r?r(f):f;o_(n,m,i,a);let p=o.listen(m,i,a);if(!z0(i)){let E=r?N=>r(ot(N[t.index])):t.index;_g(E,e,n,i,a,p,!1)}}return l}function z0(t){return t.startsWith("animation")||t.startsWith("transition")}function W0(t,e,n,r){let o=t.cleanup;if(o!=null)for(let i=0;i<o.length-1;i+=2){let s=o[i];if(s===n&&o[i+1]===r){let a=e[xr],c=o[i+2];return a&&a.length>c?a[c]:null}typeof s=="string"&&(i+=2)}return null}function _g(t,e,n,r,o,i,s){let a=e.firstCreatePass?il(e):null,c=ol(n),l=c.length;c.push(o,i),a&&a.push(r,t,l,(l+1)*(s?-1:1))}function Fp(t,e,n,r,o,i){let s=e[n],a=e[F],l=a.data[n].outputs[r],f=s[l].subscribe(i);_g(t.index,a,e,o,i,f,!0)}var Wl=Symbol("BINDING");var Gl=class extends ea{ngModule;constructor(e){super(),this.ngModule=e}resolveComponentFactory(e){let n=An(e);return new So(n,this.ngModule)}};function G0(t){return Object.keys(t).map(e=>{let[n,r,o]=t[e],i={propName:n,templateName:e,isSignal:(r&qs.SignalBased)!==0};return o&&(i.transform=o),i})}function q0(t){return Object.keys(t).map(e=>({propName:t[e],templateName:e}))}function Z0(t,e,n){let r=e instanceof Ge?e:e?.injector;return r&&t.getStandaloneInjector!==null&&(r=t.getStandaloneInjector(r)||r),r?new zl(n,r):n}function Y0(t){let e=t.get(Ot,null);if(e===null)throw new R(407,!1);let n=t.get(lg,null),r=t.get(nt,null);return{rendererFactory:e,sanitizer:n,changeDetectionScheduler:r,ngReflect:!1}}function Q0(t,e){let n=bg(t);return wh(e,n,n==="svg"?Kc:n==="math"?Yf:null)}function K0(t){if(t?.toLowerCase()==="script")throw new R(905,!1)}function bg(t){return(t.selectors[0][0]||"div").toLowerCase()}var So=class extends Js{componentDef;ngModule;selector;componentType;ngContentSelectors;isBoundToModule;cachedInputs=null;cachedOutputs=null;get inputs(){return this.cachedInputs??=G0(this.componentDef.inputs),this.cachedInputs}get outputs(){return this.cachedOutputs??=q0(this.componentDef.outputs),this.cachedOutputs}constructor(e,n){super(),this.componentDef=e,this.ngModule=n,this.componentType=e.type,this.selector=D_(e.selectors),this.ngContentSelectors=e.ngContentSelectors??[],this.isBoundToModule=!!n}create(e,n,r,o,i,s){te(22);let a=L(null);try{let c=this.componentDef,l=X0(r,c,s,i),u=Z0(c,o||this.ngModule,e),f=Y0(u),m=f.rendererFactory.createRenderer(null,c),p=r?Q_(m,r,c.encapsulation,u):Q0(c,m);K0(p?.tagName);let E=s?.some(Lp)||i?.some(S=>typeof S!="function"&&S.bindings.some(Lp)),N=yu(null,l,null,512|Nh(c),null,null,f,m,u,null,yh(p,u,!0));N[_e]=p,ds(N);let k=null;try{let S=fg(_e,N,2,"#host",()=>l.directiveRegistry,!0,0);Mh(m,p,S),Or(p,N),Su(l,N,S),bh(l,S,N),pg(l,S),n!==void 0&&eb(S,this.ngContentSelectors,n),k=it(S.index,N),N[Ee]=k[Ee],Ru(l,N,null)}catch(S){throw k!==null&&Pl(k),Pl(N),S}finally{te(23),fs()}return new Fs(this.componentType,N,!!E)}finally{L(a)}}};function X0(t,e,n,r){let o=t?["ng-version","20.3.29"]:E_(e.selectors[0]),i=null,s=null,a=0;if(n)for(let u of n)a+=u[Wl].requiredVars,u.create&&(u.targetIdx=0,(i??=[]).push(u)),u.update&&(u.targetIdx=0,(s??=[]).push(u));if(r)for(let u=0;u<r.length;u++){let f=r[u];if(typeof f!="function")for(let m of f.bindings){a+=m[Wl].requiredVars;let p=u+1;m.create&&(m.targetIdx=p,(i??=[]).push(m)),m.update&&(m.targetIdx=p,(s??=[]).push(m))}}let c=[e];if(r)for(let u of r){let f=typeof u=="function"?u:u.type,m=Uc(f);c.push(m)}return vu(0,null,J0(i,s),1,a,c,null,null,null,[o],null)}function J0(t,e){return!t&&!e?null:n=>{if(n&1&&t)for(let r of t)r.create();if(n&2&&e)for(let r of e)r.update()}}function Lp(t){let e=t[Wl].kind;return e==="input"||e==="twoWay"}var Fs=class extends cg{_rootLView;_hasInputBindings;instance;hostView;changeDetectorRef;componentType;location;previousInputValues=null;_tNode;constructor(e,n,r){super(),this._rootLView=n,this._hasInputBindings=r,this._tNode=yo(n[F],_e),this.location=Lr(this._tNode,n),this.instance=it(this._tNode.index,n)[Ee],this.hostView=this.changeDetectorRef=new sn(n,void 0),this.componentType=e}setInput(e,n){this._hasInputBindings;let r=this._tNode;if(this.previousInputValues??=new Map,this.previousInputValues.has(e)&&Object.is(this.previousInputValues.get(e),n))return;let o=this._rootLView,i=Nu(r,o[F],o,e,n);this.previousInputValues.set(e,n);let s=it(r.index,o);ku(s,1)}get injector(){return new zn(this._tNode,this._rootLView)}destroy(){this.hostView.destroy()}onDestroy(e){this.hostView.onDestroy(e)}};function eb(t,e,n){let r=t.projection=[];for(let o=0;o<e.length;o++){let i=n[o];r.push(i!=null&&i.length?Array.from(i):null)}}var Yn=(()=>{class t{static __NG_ELEMENT_ID__=tb}return t})();function tb(){let t=Be();return Dg(t,H())}var nb=Yn,Cg=class extends nb{_lContainer;_hostTNode;_hostLView;constructor(e,n,r){super(),this._lContainer=e,this._hostTNode=n,this._hostLView=r}get element(){return Lr(this._hostTNode,this._hostLView)}get injector(){return new zn(this._hostTNode,this._hostLView)}get parentInjector(){let e=fu(this._hostTNode,this._hostLView);if(Xp(e)){let n=Is(e,this._hostLView),r=xs(e),o=n[F].data[r+8];return new zn(o,n)}else return new zn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(e){let n=jp(this._lContainer);return n!==null&&n[e]||null}get length(){return this._lContainer.length-De}createEmbeddedView(e,n,r){let o,i;typeof r=="number"?o=r:r!=null&&(o=r.index,i=r.injector);let s=Os(this._lContainer,e.ssrId),a=e.createEmbeddedViewImpl(n||{},i,s);return this.insertImpl(a,o,Pr(this._hostTNode,s)),a}createComponent(e,n,r,o,i,s,a){let c=e&&!Ny(e),l;if(c)l=n;else{let k=n||{};l=k.index,r=k.injector,o=k.projectableNodes,i=k.environmentInjector||k.ngModuleRef,s=k.directives,a=k.bindings}let u=c?e:new So(An(e)),f=r||this.parentInjector;if(!i&&u.ngModule==null){let S=(c?f:this.parentInjector).get(Ge,null);S&&(i=S)}let m=An(u.componentType??{}),p=Os(this._lContainer,m?.id??null),E=p?.firstChild??null,N=u.create(f,o,E,i,s,a);return this.insertImpl(N.hostView,l,Pr(this._hostTNode,p)),N}insert(e,n){return this.insertImpl(e,n,!0)}insertImpl(e,n,r){let o=e._lView;if(Kf(o)){let a=this.indexOf(e);if(a!==-1)this.detach(a);else{let c=o[Ne],l=new Cg(c,c[ze],c[Ne]);l.detach(l.indexOf(e))}}let i=this._adjustIndex(n),s=this._lContainer;return Lo(s,o,i,r),e.attachToViewContainerRef(),Bc(xl(s),i,e),e}move(e,n){return this.insert(e,n)}indexOf(e){let n=jp(this._lContainer);return n!==null?n.indexOf(e):-1}remove(e){let n=this._adjustIndex(e,-1),r=To(this._lContainer,n);r&&(uo(xl(this._lContainer),n),Qs(r[F],r))}detach(e){let n=this._adjustIndex(e,-1),r=To(this._lContainer,n);return r&&uo(xl(this._lContainer),n)!=null?new sn(r):null}_adjustIndex(e,n=0){return e??this.length+n}};function jp(t){return t[mo]}function xl(t){return t[mo]||(t[mo]=[])}function Dg(t,e){let n,r=e[t.index];return ht(r)?n=r:(n=rg(r,e,null,t),e[t.index]=n,_u(e,n)),ob(n,e,t,r),new Cg(n,t,e)}function rb(t,e){let n=t[ge],r=n.createComment(""),o=gt(e,t),i=n.parentNode(o);return Rs(n,i,r,n.nextSibling(o),!1),r}var ob=ab,ib=()=>!1;function sb(t,e,n){return ib(t,e,n)}function ab(t,e,n,r){if(t[en])return;let o;n.type&8?o=ot(r):o=rb(e,n),t[en]=o}var ql=class t{queryList;matches=null;constructor(e){this.queryList=e}clone(){return new t(this.queryList)}setDirty(){this.queryList.setDirty()}},Zl=class t{queries;constructor(e=[]){this.queries=e}createEmbeddedView(e){let n=e.queries;if(n!==null){let r=e.contentQueries!==null?e.contentQueries[0]:n.length,o=[];for(let i=0;i<r;i++){let s=n.getByIndex(i),a=this.queries[s.indexInDeclarationView];o.push(a.clone())}return new t(o)}return null}insertView(e){this.dirtyQueriesWithMatches(e)}detachView(e){this.dirtyQueriesWithMatches(e)}finishViewCreation(e){this.dirtyQueriesWithMatches(e)}dirtyQueriesWithMatches(e){for(let n=0;n<this.queries.length;n++)Fu(e,n).matches!==null&&this.queries[n].setDirty()}},Yl=class{flags;read;predicate;constructor(e,n,r=null){this.flags=n,this.read=r,typeof e=="string"?this.predicate=pb(e):this.predicate=e}},Ql=class t{queries;constructor(e=[]){this.queries=e}elementStart(e,n){for(let r=0;r<this.queries.length;r++)this.queries[r].elementStart(e,n)}elementEnd(e){for(let n=0;n<this.queries.length;n++)this.queries[n].elementEnd(e)}embeddedTView(e){let n=null;for(let r=0;r<this.length;r++){let o=n!==null?n.length:0,i=this.getByIndex(r).embeddedTView(e,o);i&&(i.indexInDeclarationView=r,n!==null?n.push(i):n=[i])}return n!==null?new t(n):null}template(e,n){for(let r=0;r<this.queries.length;r++)this.queries[r].template(e,n)}getByIndex(e){return this.queries[e]}get length(){return this.queries.length}track(e){this.queries.push(e)}},Kl=class t{metadata;matches=null;indexInDeclarationView=-1;crossesNgTemplate=!1;_declarationNodeIndex;_appliesToNextNode=!0;constructor(e,n=-1){this.metadata=e,this._declarationNodeIndex=n}elementStart(e,n){this.isApplyingToNode(n)&&this.matchTNode(e,n)}elementEnd(e){this._declarationNodeIndex===e.index&&(this._appliesToNextNode=!1)}template(e,n){this.elementStart(e,n)}embeddedTView(e,n){return this.isApplyingToNode(e)?(this.crossesNgTemplate=!0,this.addMatch(-e.index,n),new t(this.metadata)):null}isApplyingToNode(e){if(this._appliesToNextNode&&(this.metadata.flags&1)!==1){let n=this._declarationNodeIndex,r=e.parent;for(;r!==null&&r.type&8&&r.index!==n;)r=r.parent;return n===(r!==null?r.index:-1)}return this._appliesToNextNode}matchTNode(e,n){let r=this.metadata.predicate;if(Array.isArray(r))for(let o=0;o<r.length;o++){let i=r[o];this.matchTNodeWithReadOption(e,n,cb(n,i)),this.matchTNodeWithReadOption(e,n,Cs(n,e,i,!1,!1))}else r===an?n.type&4&&this.matchTNodeWithReadOption(e,n,-1):this.matchTNodeWithReadOption(e,n,Cs(n,e,r,!1,!1))}matchTNodeWithReadOption(e,n,r){if(r!==null){let o=this.metadata.read;if(o!==null)if(o===Ct||o===Yn||o===an&&n.type&4)this.addMatch(n.index,-2);else{let i=Cs(n,e,o,!1,!1);i!==null&&this.addMatch(n.index,i)}else this.addMatch(n.index,r)}}addMatch(e,n){this.matches===null?this.matches=[e,n]:this.matches.push(e,n)}};function cb(t,e){let n=t.localNames;if(n!==null){for(let r=0;r<n.length;r+=2)if(n[r]===e)return n[r+1]}return null}function lb(t,e){return t.type&11?Lr(t,e):t.type&4?Au(t,e):null}function ub(t,e,n,r){return n===-1?lb(e,t):n===-2?db(t,e,r):xo(t,t[F],n,e)}function db(t,e,n){if(n===Ct)return Lr(e,t);if(n===an)return Au(e,t);if(n===Yn)return Dg(e,t)}function Eg(t,e,n,r){let o=e[Tt].queries[r];if(o.matches===null){let i=t.data,s=n.matches,a=[];for(let c=0;s!==null&&c<s.length;c+=2){let l=s[c];if(l<0)a.push(null);else{let u=i[l];a.push(ub(e,u,s[c+1],n.metadata.read))}}o.matches=a}return o.matches}function Xl(t,e,n,r){let o=t.queries.getByIndex(n),i=o.matches;if(i!==null){let s=Eg(t,e,o,n);for(let a=0;a<i.length;a+=2){let c=i[a];if(c>0)r.push(s[a/2]);else{let l=i[a+1],u=e[-c];for(let f=De;f<u.length;f++){let m=u[f];m[Jt]===m[Ne]&&Xl(m[F],m,l,r)}if(u[Vn]!==null){let f=u[Vn];for(let m=0;m<f.length;m++){let p=f[m];Xl(p[F],p,l,r)}}}}}return r}function Pu(t,e){return t[Tt].queries[e].queryList}function fb(t,e,n){let r=new Ss((n&4)===4);return ep(t,e,r,r.destroy),(e[Tt]??=new Zl).queries.push(new ql(r))-1}function wg(t,e,n){let r=we();return r.firstCreatePass&&(hb(r,new Yl(t,e,n),-1),(e&2)===2&&(r.staticViewQueries=!0)),fb(r,H(),e)}function pb(t){return t.split(",").map(e=>e.trim())}function hb(t,e,n){t.queries===null&&(t.queries=new Ql),t.queries.track(new Kl(e,n))}function Fu(t,e){return t.queries.getByIndex(e)}function xg(t,e){let n=t[F],r=Fu(n,e);return r.crossesNgTemplate?Xl(n,t,e,[]):Eg(n,t,r,e)}function Ig(t,e,n){let r,o=Zr(()=>{r._dirtyCounter();let i=mb(r,t);if(e&&i===void 0)throw new R(-951,!1);return i});return r=o[Re],r._dirtyCounter=b(0),r._flatValue=void 0,o}function Mg(t){return Ig(!0,!1,t)}function Tg(t){return Ig(!0,!0,t)}function gb(t,e){let n=t[Re];n._lView=H(),n._queryIndex=e,n._queryList=Pu(n._lView,e),n._queryList.onDirty(()=>n._dirtyCounter.update(r=>r+1))}function mb(t,e){let n=t._lView,r=t._queryIndex;if(n===void 0||r===void 0||n[j]&4)return e?void 0:tt;let o=Pu(n,r),i=xg(n,r);return o.reset(i,ah),e?o.first:o._changesDetected||t._flatValue===void 0?t._flatValue=o.toArray():t._flatValue}var No=class{};var Ro=class extends No{injector;componentFactoryResolver=new Gl(this);instance=null;constructor(e){super();let n=new Mn([...e.providers,{provide:No,useValue:this},{provide:ea,useValue:this.componentFactoryResolver}],e.parent||ho(),e.debugName,new Set(["environment"]));this.injector=n,e.runEnvironmentInitializers&&n.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(e){this.injector.onDestroy(e)}};function Sg(t,e,n=null){return new Ro({providers:t,parent:e,debugName:n,runEnvironmentInitializers:!0}).injector}var vb=(()=>{class t{_injector;cachedInjectors=new Map;constructor(n){this._injector=n}getOrCreateStandaloneInjector(n){if(!n.standalone)return null;if(!this.cachedInjectors.has(n)){let r=zc(!1,n.type),o=r.length>0?Sg([r],this._injector,`Standalone[${n.type.name}]`):null;this.cachedInjectors.set(n,o)}return this.cachedInjectors.get(n)}ngOnDestroy(){try{for(let n of this.cachedInjectors.values())n!==null&&n.destroy()}finally{this.cachedInjectors.clear()}}static \u0275prov=B({token:t,providedIn:"environment",factory:()=>new t(Q(Ge))})}return t})();function se(t){return Bs(()=>{let e=Ng(t),n=le(K({},e),{decls:t.decls,vars:t.vars,template:t.template,consts:t.consts||null,ngContentSelectors:t.ngContentSelectors,onPush:t.changeDetection===pu.OnPush,directiveDefs:null,pipeDefs:null,dependencies:e.standalone&&t.dependencies||null,getStandaloneInjector:e.standalone?o=>o.get(vb).getOrCreateStandaloneInjector(n):null,getExternalStyles:null,signals:t.signals??!1,data:t.data||{},encapsulation:t.encapsulation||Ht.Emulated,styles:t.styles||tt,_:null,schemas:t.schemas||null,tView:null,id:""});e.standalone&&ln("NgStandalone"),Rg(n);let r=t.dependencies;return n.directiveDefs=Vp(r,yb),n.pipeDefs=Vp(r,$f),n.id=Cb(n),n})}function yb(t){return An(t)||Uc(t)}function _b(t,e){if(t==null)return Xt;let n={};for(let r in t)if(t.hasOwnProperty(r)){let o=t[r],i,s,a,c;Array.isArray(o)?(a=o[0],i=o[1],s=o[2]??i,c=o[3]||null):(i=o,s=o,a=qs.None,c=null),n[i]=[r,a,c],e[i]=s}return n}function bb(t){if(t==null)return Xt;let e={};for(let n in t)t.hasOwnProperty(n)&&(e[t[n]]=n);return e}function Qn(t){return Bs(()=>{let e=Ng(t);return Rg(e),e})}function na(t){return{type:t.type,name:t.name,factory:null,pure:t.pure!==!1,standalone:t.standalone??!0,onDestroy:t.type.prototype.ngOnDestroy||null}}function Ng(t){let e={};return{type:t.type,providersResolver:null,factory:null,hostBindings:t.hostBindings||null,hostVars:t.hostVars||0,hostAttrs:t.hostAttrs||null,contentQueries:t.contentQueries||null,declaredInputs:e,inputConfig:t.inputs||Xt,exportAs:t.exportAs||null,standalone:t.standalone??!0,signals:t.signals===!0,selectors:t.selectors||tt,viewQuery:t.viewQuery||null,features:t.features||null,setInput:null,resolveHostDirectives:null,hostDirectives:null,inputs:_b(t.inputs,e),outputs:bb(t.outputs),debugInfo:null}}function Rg(t){t.features?.forEach(e=>e(t))}function Vp(t,e){return t?()=>{let n=typeof t=="function"?t():t,r=[];for(let o of n){let i=e(o);i!==null&&r.push(i)}return r}:null}function Cb(t){let e=0,n=typeof t.consts=="function"?"":t.consts,r=[t.selectors,t.ngContentSelectors,t.hostVars,t.hostAttrs,n,t.vars,t.decls,t.encapsulation,t.standalone,t.signals,t.exportAs,JSON.stringify(t.inputs),JSON.stringify(t.outputs),Object.getOwnPropertyNames(t.type.prototype),!!t.contentQueries,!!t.viewQuery];for(let i of r.join("|"))e=Math.imul(31,e)+i.charCodeAt(0)<<0;return e+=2147483648,"c"+e}function Db(t){return Object.getPrototypeOf(t.prototype).constructor}function jo(t){let e=Db(t.type),n=!0,r=[t];for(;e;){let o;if(Nt(t))o=e.\u0275cmp||e.\u0275dir;else{if(e.\u0275cmp)throw new R(903,!1);o=e.\u0275dir}if(o){if(n){r.push(o);let s=t;s.inputs=Il(t.inputs),s.declaredInputs=Il(t.declaredInputs),s.outputs=Il(t.outputs);let a=o.hostBindings;a&&Mb(t,a);let c=o.viewQuery,l=o.contentQueries;if(c&&xb(t,c),l&&Ib(t,l),Eb(t,o),kf(t.outputs,o.outputs),Nt(o)&&o.data.animation){let u=t.data;u.animation=(u.animation||[]).concat(o.data.animation)}}let i=o.features;if(i)for(let s=0;s<i.length;s++){let a=i[s];a&&a.ngInherit&&a(t),a===jo&&(n=!1)}}e=Object.getPrototypeOf(e)}wb(r)}function Eb(t,e){for(let n in e.inputs){if(!e.inputs.hasOwnProperty(n)||t.inputs.hasOwnProperty(n))continue;let r=e.inputs[n];r!==void 0&&(t.inputs[n]=r,t.declaredInputs[n]=e.declaredInputs[n])}}function wb(t){let e=0,n=null;for(let r=t.length-1;r>=0;r--){let o=t[r];o.hostVars=e+=o.hostVars,o.hostAttrs=Ar(o.hostAttrs,n=Ar(n,o.hostAttrs))}}function Il(t){return t===Xt?{}:t===tt?[]:t}function xb(t,e){let n=t.viewQuery;n?t.viewQuery=(r,o)=>{e(r,o),n(r,o)}:t.viewQuery=e}function Ib(t,e){let n=t.contentQueries;n?t.contentQueries=(r,o,i)=>{e(r,o,i),n(r,o,i)}:t.contentQueries=e}function Mb(t,e){let n=t.hostBindings;n?t.hostBindings=(r,o)=>{e(r,o),n(r,o)}:t.hostBindings=e}function kg(t,e,n,r,o,i,s,a){if(n.firstCreatePass){t.mergedAttrs=Ar(t.mergedAttrs,t.attrs);let u=t.tView=vu(2,t,o,i,s,n.directiveRegistry,n.pipeRegistry,null,n.schemas,n.consts,null);n.queries!==null&&(n.queries.template(n,t),u.queries=n.queries.embeddedTView(t))}a&&(t.flags|=a),Tr(t,!1);let c=Sb(n,e,t,r);hs()&&Mu(n,e,c,t),Or(c,e);let l=rg(c,e,c,t);e[r+_e]=l,_u(e,l),sb(l,t,e)}function Tb(t,e,n,r,o,i,s,a,c,l,u){let f=n+_e,m;return e.firstCreatePass?(m=jr(e,f,4,s||null,a||null),al()&&ug(e,t,m,st(e.consts,l),Wh),Qp(e,m)):m=e.data[f],kg(m,t,e,n,r,o,i,c),vo(m)&&Su(e,t,m),l!=null&&Xs(t,m,u),m}function ko(t,e,n,r,o,i,s,a,c,l,u){let f=n+_e,m;if(e.firstCreatePass){if(m=jr(e,f,4,s||null,a||null),l!=null){let p=st(e.consts,l);m.localNames=[];for(let E=0;E<p.length;E+=2)m.localNames.push(p[E],-1)}}else m=e.data[f];return kg(m,t,e,n,r,o,i,c),l!=null&&Xs(t,m,u),m}function ra(t,e,n,r,o,i,s,a){let c=H(),l=we(),u=st(l.consts,i);return Tb(c,l,t,e,n,r,o,u,void 0,s,a),ra}var Sb=Nb;function Nb(t,e,n,r){return gs(!0),e[ge].createComment("")}var Lu=new P("");function Vo(t){return!!t&&typeof t.then=="function"}function oa(t){return!!t&&typeof t.subscribe=="function"}var Ag=new P("");var ju=(()=>{class t{resolve;reject;initialized=!1;done=!1;donePromise=new Promise((n,r)=>{this.resolve=n,this.reject=r});appInits=_(Ag,{optional:!0})??[];injector=_(Ue);constructor(){}runInitializers(){if(this.initialized)return;let n=[];for(let o of this.appInits){let i=wr(this.injector,o);if(Vo(i))n.push(i);else if(oa(i)){let s=new Promise((a,c)=>{i.subscribe({complete:a,error:c})});n.push(s)}}let r=()=>{this.done=!0,this.resolve()};Promise.all(n).then(()=>{r()}).catch(o=>{this.reject(o)}),n.length===0&&r(),this.initialized=!0}static \u0275fac=function(r){return new(r||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Og=new P("");function Pg(){Ja(()=>{let t="";throw new R(600,t)})}function Fg(t){return t.isBoundToModule}var Rb=10;var Kn=(()=>{class t{_runningTick=!1;_destroyed=!1;_destroyListeners=[];_views=[];internalErrorHandler=_(mt);afterRenderManager=_(Ys);zonelessEnabled=_(Co);rootEffectScheduler=_(Do);dirtyFlags=0;tracingSnapshot=null;allTestViews=new Set;autoDetectTestViews=new Set;includeAllTestViews=!1;afterTick=new ye;get allViews(){return[...(this.includeAllTestViews?this.allTestViews:this.autoDetectTestViews).keys(),...this._views]}get destroyed(){return this._destroyed}componentTypes=[];components=[];internalPendingTask=_(on);get isStable(){return this.internalPendingTask.hasPendingTasksObservable.pipe(je(n=>!n))}constructor(){_(cn,{optional:!0})}whenStable(){let n;return new Promise(r=>{n=this.isStable.subscribe({next:o=>{o&&r()}})}).finally(()=>{n.unsubscribe()})}_injector=_(Ge);_rendererFactory=null;get injector(){return this._injector}bootstrap(n,r){return this.bootstrapImpl(n,r)}bootstrapImpl(n,r,o=Ue.NULL){return this._injector.get(ie).run(()=>{te(10);let s=n instanceof Js;if(!this._injector.get(ju).done){let E="";throw new R(405,E)}let c;s?c=n:c=this._injector.get(ea).resolveComponentFactory(n),this.componentTypes.push(c.componentType);let l=Fg(c)?void 0:this._injector.get(No),u=r||c.selector,f=c.create(o,[],u,l),m=f.location.nativeElement,p=f.injector.get(Lu,null);return p?.registerApplication(m),f.onDestroy(()=>{this.detachView(f.hostView),wo(this.components,f),p?.unregisterApplication(m)}),this._loadComponent(f),te(11,f),f})}tick(){this.zonelessEnabled||(this.dirtyFlags|=1),this._tick()}_tick(){te(12),this.tracingSnapshot!==null?this.tracingSnapshot.run(Zs.CHANGE_DETECTION,this.tickImpl):this.tickImpl()}tickImpl=()=>{if(this._runningTick)throw new R(101,!1);let n=L(null);try{this._runningTick=!0,this.synchronize()}finally{this._runningTick=!1,this.tracingSnapshot?.dispose(),this.tracingSnapshot=null,L(n),this.afterTick.next(),te(13)}};synchronize(){this._rendererFactory===null&&!this._injector.destroyed&&(this._rendererFactory=this._injector.get(Ot,null,{optional:!0}));let n=0;for(;this.dirtyFlags!==0&&n++<Rb;)te(14),this.synchronizeOnce(),te(15)}synchronizeOnce(){this.dirtyFlags&16&&(this.dirtyFlags&=-17,this.rootEffectScheduler.flush());let n=!1;if(this.dirtyFlags&7){let r=!!(this.dirtyFlags&1);this.dirtyFlags&=-8,this.dirtyFlags|=8;for(let{_lView:o}of this.allViews){if(!r&&!_o(o))continue;let i=r&&!this.zonelessEnabled?0:1;Jh(o,i),n=!0}if(this.dirtyFlags&=-5,this.syncDirtyFlagsWithViews(),this.dirtyFlags&23)return}n||(this._rendererFactory?.begin?.(),this._rendererFactory?.end?.()),this.dirtyFlags&8&&(this.dirtyFlags&=-9,this.afterRenderManager.execute()),this.syncDirtyFlagsWithViews()}syncDirtyFlagsWithViews(){if(this.allViews.some(({_lView:n})=>_o(n))){this.dirtyFlags|=2;return}else this.dirtyFlags&=-8}attachView(n){let r=n;this._views.push(r),r.attachToAppRef(this)}detachView(n){let r=n;wo(this._views,r),r.detachFromAppRef()}_loadComponent(n){this.attachView(n.hostView);try{this.tick()}catch(o){this.internalErrorHandler(o)}this.components.push(n),this._injector.get(Og,[]).forEach(o=>o(n))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(n=>n()),this._views.slice().forEach(n=>n.destroy())}finally{this._destroyed=!0,this._views=[],this._destroyListeners=[]}}onDestroy(n){return this._destroyListeners.push(n),()=>wo(this._destroyListeners,n)}destroy(){if(this._destroyed)throw new R(406,!1);let n=this._injector;n.destroy&&!n.destroyed&&n.destroy()}get viewCount(){return this._views.length}static \u0275fac=function(r){return new(r||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function wo(t,e){let n=t.indexOf(e);n>-1&&t.splice(n,1)}function ue(t,e,n,r){let o=H(),i=Hn();if(bt(o,i,e)){let s=we(),a=ps();i0(a,o,t,e,n,r)}return ue}var _k=typeof document<"u"&&typeof document?.documentElement?.getAnimations=="function";var Jl=class{destroy(e){}updateValue(e,n){}swap(e,n){let r=Math.min(e,n),o=Math.max(e,n),i=this.detach(o);if(o-r>1){let s=this.detach(r);this.attach(r,i),this.attach(o,s)}else this.attach(r,i)}move(e,n){this.attach(n,this.detach(e))}};function Ml(t,e,n,r,o){return t===n&&Object.is(e,r)?1:Object.is(o(t,e),o(n,r))?-1:0}function kb(t,e,n){let r,o,i=0,s=t.length-1,a=void 0;if(Array.isArray(e)){let c=e.length-1;for(;i<=s&&i<=c;){let l=t.at(i),u=e[i],f=Ml(i,l,i,u,n);if(f!==0){f<0&&t.updateValue(i,u),i++;continue}let m=t.at(s),p=e[c],E=Ml(s,m,c,p,n);if(E!==0){E<0&&t.updateValue(s,p),s--,c--;continue}let N=n(i,l),k=n(s,m),S=n(i,u);if(Object.is(S,k)){let ve=n(c,p);Object.is(ve,N)?(t.swap(i,s),t.updateValue(s,p),c--,s--):t.move(s,i),t.updateValue(i,u),i++;continue}if(r??=new Ls,o??=Hp(t,i,s,n),eu(t,r,i,S))t.updateValue(i,u),i++,s++;else if(o.has(S))r.set(N,t.detach(i)),s--;else{let ve=t.create(i,e[i]);t.attach(i,ve),i++,s++}}for(;i<=c;)Bp(t,r,n,i,e[i]),i++}else if(e!=null){let c=e[Symbol.iterator](),l=c.next();for(;!l.done&&i<=s;){let u=t.at(i),f=l.value,m=Ml(i,u,i,f,n);if(m!==0)m<0&&t.updateValue(i,f),i++,l=c.next();else{r??=new Ls,o??=Hp(t,i,s,n);let p=n(i,f);if(eu(t,r,i,p))t.updateValue(i,f),i++,s++,l=c.next();else if(!o.has(p))t.attach(i,t.create(i,f)),i++,s++,l=c.next();else{let E=n(i,u);r.set(E,t.detach(i)),s--}}}for(;!l.done;)Bp(t,r,n,t.length,l.value),l=c.next()}for(;i<=s;)t.destroy(t.detach(s--));r?.forEach(c=>{t.destroy(c)})}function eu(t,e,n,r){return e!==void 0&&e.has(r)?(t.attach(n,e.get(r)),e.delete(r),!0):!1}function Bp(t,e,n,r,o){if(eu(t,e,r,n(r,o)))t.updateValue(r,o);else{let i=t.create(r,o);t.attach(r,i)}}function Hp(t,e,n,r){let o=new Set;for(let i=e;i<=n;i++)o.add(r(i,t.at(i)));return o}var Ls=class{kvMap=new Map;_vMap=void 0;has(e){return this.kvMap.has(e)}delete(e){if(!this.has(e))return!1;let n=this.kvMap.get(e);return this._vMap!==void 0&&this._vMap.has(n)?(this.kvMap.set(e,this._vMap.get(n)),this._vMap.delete(n)):this.kvMap.delete(e),!0}get(e){return this.kvMap.get(e)}set(e,n){if(this.kvMap.has(e)){let r=this.kvMap.get(e);this._vMap===void 0&&(this._vMap=new Map);let o=this._vMap;for(;o.has(r);)r=o.get(r);o.set(r,n)}else this.kvMap.set(e,n)}forEach(e){for(let[n,r]of this.kvMap)if(e(r,n),this._vMap!==void 0){let o=this._vMap;for(;o.has(r);)r=o.get(r),e(r,n)}}};function I(t,e,n,r,o,i,s,a){ln("NgControlFlow");let c=H(),l=we(),u=st(l.consts,i);return ko(c,l,t,e,n,r,o,u,256,s,a),Bo}function Bo(t,e,n,r,o,i,s,a){ln("NgControlFlow");let c=H(),l=we(),u=st(l.consts,i);return ko(c,l,t,e,n,r,o,u,512,s,a),Bo}function M(t,e){ln("NgControlFlow");let n=H(),r=Hn(),o=n[r]!==Ze?n[r]:-1,i=o!==-1?js(n,_e+o):void 0,s=0;if(bt(n,r,t)){let a=L(null);try{if(i!==void 0&&ig(i,s),t!==-1){let c=_e+t,l=js(n,c),u=ou(n[F],c),f=ag(l,u,n),m=Fo(n,u,e,{dehydratedView:f});Lo(l,m,s,Pr(u,f))}}finally{L(a)}}else if(i!==void 0){let a=og(i,s);a!==void 0&&(a[Ee]=e)}}var tu=class{lContainer;$implicit;$index;constructor(e,n,r){this.lContainer=e,this.$implicit=n,this.$index=r}get $count(){return this.lContainer.length-De}};function Xn(t){return t}function Ho(t,e){return e}var nu=class{hasEmptyBlock;trackByFn;liveCollection;constructor(e,n,r){this.hasEmptyBlock=e,this.trackByFn=n,this.liveCollection=r}};function de(t,e,n,r,o,i,s,a,c,l,u,f,m){ln("NgControlFlow");let p=H(),E=we(),N=c!==void 0,k=H(),S=a?s.bind(k[We][Ee]):s,ve=new nu(N,S);k[_e+t]=ve,ko(p,E,t+1,e,n,r,o,st(E.consts,i),256),N&&ko(p,E,t+2,c,l,u,f,st(E.consts,m),512)}var ru=class extends Jl{lContainer;hostLView;templateTNode;operationsCounter=void 0;needsIndexUpdate=!1;constructor(e,n,r){super(),this.lContainer=e,this.hostLView=n,this.templateTNode=r}get length(){return this.lContainer.length-De}at(e){return this.getLView(e)[Ee].$implicit}attach(e,n){let r=n[On];this.needsIndexUpdate||=e!==this.length,Lo(this.lContainer,n,e,Pr(this.templateTNode,r)),Ab(this.lContainer,e)}detach(e){return this.needsIndexUpdate||=e!==this.length-1,Ob(this.lContainer,e),Pb(this.lContainer,e)}create(e,n){let r=Os(this.lContainer,this.templateTNode.tView.ssrId),o=Fo(this.hostLView,this.templateTNode,new tu(this.lContainer,n,e),{dehydratedView:r});return this.operationsCounter?.recordCreate(),o}destroy(e){Qs(e[F],e),this.operationsCounter?.recordDestroy()}updateValue(e,n){this.getLView(e)[Ee].$implicit=n}reset(){this.needsIndexUpdate=!1,this.operationsCounter?.reset()}updateIndexes(){if(this.needsIndexUpdate)for(let e=0;e<this.length;e++)this.getLView(e)[Ee].$index=e}getLView(e){return Fb(this.lContainer,e)}};function fe(t){let e=L(null),n=Rt();try{let r=H(),o=r[F],i=r[n],s=n+1,a=js(r,s);if(i.liveCollection===void 0){let l=ou(o,s);i.liveCollection=new ru(a,r,l)}else i.liveCollection.reset();let c=i.liveCollection;if(kb(c,t,i.trackByFn),c.updateIndexes(),i.hasEmptyBlock){let l=Hn(),u=c.length===0;if(bt(r,l,u)){let f=n+2,m=js(r,f);if(u){let p=ou(o,f),E=ag(m,p,r),N=Fo(r,p,void 0,{dehydratedView:E});Lo(m,N,0,Pr(p,E))}else o.firstUpdatePass&&S0(m),ig(m,0)}}}finally{L(e)}}function js(t,e){return t[e]}function Ab(t,e){if(t.length<=De)return;let n=De+e,r=t[n],o=r?r[jn]:void 0;if(r&&o&&o.detachedLeaveAnimationFns&&o.detachedLeaveAnimationFns.length>0){let i=r[Vt];F_(i,o),Gn.delete(r),o.detachedLeaveAnimationFns=void 0}}function Ob(t,e){if(t.length<=De)return;let n=De+e,r=t[n],o=r?r[jn]:void 0;o&&o.leave&&o.leave.size>0&&(o.detachedLeaveAnimationFns=[])}function Pb(t,e){return To(t,e)}function Fb(t,e){return og(t,e)}function ou(t,e){return yo(t,e)}function A(t,e,n){let r=H(),o=Hn();if(bt(r,o,e)){let i=we(),s=ps();e0(s,r,t,e,r[ge],n)}return A}function iu(t,e,n,r,o){Nu(e,t,n,o?"class":"style",r)}function g(t,e,n,r){let o=H(),i=o[F],s=t+_e,a=i.firstCreatePass?fg(s,o,2,e,Wh,al(),n,r):i.data[s];if(Gh(a,o,t,e,Lg),vo(a)){let c=o[F];Su(c,o,a),bh(c,a,o)}return r!=null&&Xs(o,a),g}function v(){let t=we(),e=Be(),n=qh(e);return t.firstCreatePass&&pg(t,n),ll(n)&&ul(),sl(),n.classesWithoutHost!=null&&Fy(n)&&iu(t,n,H(),n.classesWithoutHost,!0),n.stylesWithoutHost!=null&&Ly(n)&&iu(t,n,H(),n.stylesWithoutHost,!1),v}function be(t,e,n,r){return g(t,e,n,r),v(),be}function w(t,e,n,r){let o=H(),i=o[F],s=t+_e,a=i.firstCreatePass?U0(s,i,2,e,n,r):i.data[s];return Gh(a,o,t,e,Lg),r!=null&&Xs(o,a),w}function x(){let t=Be(),e=qh(t);return ll(e)&&ul(),sl(),x}function ae(t,e,n,r){return w(t,e,n,r),x(),ae}var Lg=(t,e,n,r,o)=>(gs(!0),wh(e[ge],r,yl()));function $(){return H()}function ce(t,e,n){let r=H(),o=Hn();if(bt(r,o,e)){let i=we(),s=ps();zh(s,r,t,e,r[ge],n)}return ce}var vs=void 0;function Lb(t){let e=Math.floor(Math.abs(t)),n=t.toString().replace(/^[^.]*\.?/,"").length;return e===1&&n===0?1:5}var jb=["en",[["a","p"],["AM","PM"]],[["AM","PM"]],[["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"]],vs,[["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"]],vs,[["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}",vs,"{1} 'at' {0}",vs],[".",",",";","%","+","-","E","\xD7","\u2030","\u221E","NaN",":"],["#,##0.###","#,##0%","\xA4#,##0.00","#E0"],"USD","$","US Dollar",{},"ltr",Lb],Tl={};function Je(t){let e=Vb(t),n=$p(e);if(n)return n;let r=e.split("-")[0];if(n=$p(r),n)return n;if(r==="en")return jb;throw new R(701,!1)}function $p(t){if(!(t in Tl)){let e=Sn.ng&&Sn.ng.common&&Sn.ng.common.locales&&Sn.ng.common.locales[t];return e!==void 0&&(Tl[t]=e),e}return Tl[t]}var Ie=(function(t){return t[t.LocaleId=0]="LocaleId",t[t.DayPeriodsFormat=1]="DayPeriodsFormat",t[t.DayPeriodsStandalone=2]="DayPeriodsStandalone",t[t.DaysFormat=3]="DaysFormat",t[t.DaysStandalone=4]="DaysStandalone",t[t.MonthsFormat=5]="MonthsFormat",t[t.MonthsStandalone=6]="MonthsStandalone",t[t.Eras=7]="Eras",t[t.FirstDayOfWeek=8]="FirstDayOfWeek",t[t.WeekendRange=9]="WeekendRange",t[t.DateFormat=10]="DateFormat",t[t.TimeFormat=11]="TimeFormat",t[t.DateTimeFormat=12]="DateTimeFormat",t[t.NumberSymbols=13]="NumberSymbols",t[t.NumberFormats=14]="NumberFormats",t[t.CurrencyCode=15]="CurrencyCode",t[t.CurrencySymbol=16]="CurrencySymbol",t[t.CurrencyName=17]="CurrencyName",t[t.Currencies=18]="Currencies",t[t.Directionality=19]="Directionality",t[t.PluralCase=20]="PluralCase",t[t.ExtraData=21]="ExtraData",t})(Ie||{});function Vb(t){return t.toLowerCase().replace(/_/g,"-")}var $o="en-US";var Bb=$o;function jg(t){typeof t=="string"&&(Bb=t.toLowerCase().replace(/_/g,"-"))}function T(t,e,n){let r=H(),o=we(),i=Be();return Hb(o,r,r[ge],i,t,e,n),T}function q(t,e,n){let r=H(),o=we(),i=Be();return(i.type&3||n)&&yg(i,o,r,n,r[ge],t,e,Es(i,r,e)),q}function Hb(t,e,n,r,o,i,s){let a=!0,c=null;if((r.type&3||s)&&(c??=Es(r,e,i),yg(r,t,e,s,n,o,i,c)&&(a=!1)),a){let l=r.outputs?.[o],u=r.hostDirectiveOutputs?.[o];if(u&&u.length)for(let f=0;f<u.length;f+=2){let m=u[f],p=u[f+1];c??=Es(r,e,i),Fp(r,e,m,p,o,c)}if(l&&l.length)for(let f of l)c??=Es(r,e,i),Fp(r,e,f,o,o,c)}}function h(t=1){return pp(t)}function $b(t,e){let n=null,r=v_(t);for(let o=0;o<e.length;o++){let i=e[o];if(i==="*"){n=o;continue}if(r===null?Sh(t,i,!0):b_(r,i))return o}return n}function Vu(t){let e=H()[We][ze];if(!e.projection){let n=t?t.length:1,r=e.projection=Bf(n,null),o=r.slice(),i=e.child;for(;i!==null;){if(i.type!==128){let s=t?$b(i,t):0;s!==null&&(o[s]?o[s].projectionNext=i:r[s]=i,o[s]=i)}i=i.next}}}function Bu(t,e=0,n,r,o,i){let s=H(),a=we(),c=r?t+1:null;c!==null&&ko(s,a,c,r,o,i,null,n);let l=jr(a,_e+t,16,null,n||null);l.projection===null&&(l.projection=e),pl();let f=!s[On]||cl();s[We][ze].projection[l.projection]===null&&c!==null?Ub(s,a,c):f&&!Ws(l)&&q_(a,s,l)}function Ub(t,e,n){let r=_e+n,o=e.data[r],i=t[r],s=Os(i,o.tView.ssrId),a=Fo(t,o,void 0,{dehydratedView:s});Lo(i,a,0,Pr(o,s))}function Hu(t,e,n){wg(t,e,n)}function $u(t){let e=H(),n=we(),r=us();bo(r+1);let o=Fu(n,r);if(t.dirty&&Qf(e)===((o.metadata.flags&2)===2)){if(o.matches===null)t.reset([]);else{let i=xg(e,r);t.reset(i,ah),t.notifyOnChanges()}return!0}return!1}function Uu(){return Pu(H(),us())}function Ft(t,e,n,r){gb(t,wg(e,n,r))}function $t(t=1){bo(us()+t)}function ys(t,e){return t<<17|e<<2}function qn(t){return t>>17&32767}function zb(t){return(t&2)==2}function Wb(t,e){return t&131071|e<<17}function su(t){return t|2}function Fr(t){return(t&131068)>>2}function Sl(t,e){return t&-131069|e<<2}function Gb(t){return(t&1)===1}function au(t){return t|1}function qb(t,e,n,r,o,i){let s=i?e.classBindings:e.styleBindings,a=qn(s),c=Fr(s);t[r]=n;let l=!1,u;if(Array.isArray(n)){let f=n;u=f[1],(u===null||Er(f,u)>0)&&(l=!0)}else u=n;if(o)if(c!==0){let m=qn(t[a+1]);t[r+1]=ys(m,a),m!==0&&(t[m+1]=Sl(t[m+1],r)),t[a+1]=Wb(t[a+1],r)}else t[r+1]=ys(a,0),a!==0&&(t[a+1]=Sl(t[a+1],r)),a=r;else t[r+1]=ys(c,0),a===0?a=r:t[c+1]=Sl(t[c+1],r),c=r;l&&(t[r+1]=su(t[r+1])),Up(t,u,r,!0),Up(t,u,r,!1),Zb(e,u,t,r,i),s=ys(a,c),i?e.classBindings=s:e.styleBindings=s}function Zb(t,e,n,r,o){let i=o?t.residualClasses:t.residualStyles;i!=null&&typeof e=="string"&&Er(i,e)>=0&&(n[r+1]=au(n[r+1]))}function Up(t,e,n,r){let o=t[n+1],i=e===null,s=r?qn(o):Fr(o),a=!1;for(;s!==0&&(a===!1||i);){let c=t[s],l=t[s+1];Yb(c,e)&&(a=!0,t[s+1]=r?au(l):su(l)),s=r?qn(l):Fr(l)}a&&(t[n+1]=r?su(o):au(o))}function Yb(t,e){return t===null||e==null||(Array.isArray(t)?t[1]:t)===e?!0:Array.isArray(t)&&typeof e=="string"?Er(t,e)>=0:!1}var yt={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function Qb(t){return t.substring(yt.key,yt.keyEnd)}function Kb(t){return Xb(t),Vg(t,Bg(t,0,yt.textEnd))}function Vg(t,e){let n=yt.textEnd;return n===e?-1:(e=yt.keyEnd=Jb(t,yt.key=e,n),Bg(t,e,n))}function Xb(t){yt.key=0,yt.keyEnd=0,yt.value=0,yt.valueEnd=0,yt.textEnd=t.length}function Bg(t,e,n){for(;e<n&&t.charCodeAt(e)<=32;)e++;return e}function Jb(t,e,n){for(;e<n&&t.charCodeAt(e)>32;)e++;return e}function re(t,e,n){return Hg(t,e,n,!1),re}function Pe(t,e){return Hg(t,e,null,!0),Pe}function Jn(t){tC(aC,eC,t,!0)}function eC(t,e){for(let n=Kb(e);n>=0;n=Vg(e,n))ns(t,Qb(e),!0)}function Hg(t,e,n,r){let o=H(),i=we(),s=cs(2);if(i.firstUpdatePass&&Ug(i,t,s,r),e!==Ze&&bt(o,s,e)){let a=i.data[Rt()];zg(i,a,o,o[ge],t,o[s+1]=lC(e,n),r,s)}}function tC(t,e,n,r){let o=we(),i=cs(2);o.firstUpdatePass&&Ug(o,null,i,r);let s=H();if(n!==Ze&&bt(s,i,n)){let a=o.data[Rt()];if(Wg(a,r)&&!$g(o,i)){let c=r?a.classesWithoutHost:a.stylesWithoutHost;c!==null&&(n=Ki(c,n||"")),iu(o,a,s,n,r)}else cC(o,a,s,s[ge],s[i+1],s[i+1]=sC(t,e,n),r,i)}}function $g(t,e){return e>=t.expandoStartIndex}function Ug(t,e,n,r){let o=t.data;if(o[n+1]===null){let i=o[Rt()],s=$g(t,n);Wg(i,r)&&e===null&&!s&&(e=!1),e=nC(o,i,e,r),qb(o,i,e,n,s,r)}}function nC(t,e,n,r){let o=lp(t),i=r?e.residualClasses:e.residualStyles;if(o===null)(r?e.classBindings:e.styleBindings)===0&&(n=Nl(null,t,e,n,r),n=Ao(n,e.attrs,r),i=null);else{let s=e.directiveStylingLast;if(s===-1||t[s]!==o)if(n=Nl(o,t,e,n,r),i===null){let c=rC(t,e,r);c!==void 0&&Array.isArray(c)&&(c=Nl(null,t,e,c[1],r),c=Ao(c,e.attrs,r),oC(t,e,r,c))}else i=iC(t,e,r)}return i!==void 0&&(r?e.residualClasses=i:e.residualStyles=i),n}function rC(t,e,n){let r=n?e.classBindings:e.styleBindings;if(Fr(r)!==0)return t[qn(r)]}function oC(t,e,n,r){let o=n?e.classBindings:e.styleBindings;t[qn(o)]=r}function iC(t,e,n){let r,o=e.directiveEnd;for(let i=1+e.directiveStylingLast;i<o;i++){let s=t[i].hostAttrs;r=Ao(r,s,n)}return Ao(r,e.attrs,n)}function Nl(t,e,n,r,o){let i=null,s=n.directiveEnd,a=n.directiveStylingLast;for(a===-1?a=n.directiveStart:a++;a<s&&(i=e[a],r=Ao(r,i.hostAttrs,o),i!==t);)a++;return t!==null&&(n.directiveStylingLast=a),r}function Ao(t,e,n){let r=n?1:2,o=-1;if(e!==null)for(let i=0;i<e.length;i++){let s=e[i];typeof s=="number"?o=s:o===r&&(Array.isArray(t)||(t=t===void 0?[]:["",t]),ns(t,s,n?!0:e[++i]))}return t===void 0?null:t}function sC(t,e,n){if(n==null||n==="")return tt;let r=[],o=Gs(n);if(Array.isArray(o))for(let i=0;i<o.length;i++)t(r,o[i],!0);else if(typeof o=="object")for(let i in o)o.hasOwnProperty(i)&&t(r,i,o[i]);else typeof o=="string"&&e(r,o);return r}function aC(t,e,n){let r=String(e);r!==""&&!r.includes(" ")&&ns(t,r,n)}function cC(t,e,n,r,o,i,s,a){o===Ze&&(o=tt);let c=0,l=0,u=0<o.length?o[0]:null,f=0<i.length?i[0]:null;for(;u!==null||f!==null;){let m=c<o.length?o[c+1]:void 0,p=l<i.length?i[l+1]:void 0,E=null,N;u===f?(c+=2,l+=2,m!==p&&(E=f,N=p)):f===null||u!==null&&u<f?(c+=2,E=u):(l+=2,E=f,N=p),E!==null&&zg(t,e,n,r,E,N,s,a),u=c<o.length?o[c]:null,f=l<i.length?i[l]:null}}function zg(t,e,n,r,o,i,s,a){if(!(e.type&3))return;let c=t.data,l=c[a+1],u=Gb(l)?zp(c,e,n,o,Fr(l),s):void 0;if(!Vs(u)){Vs(i)||zb(l)&&(i=zp(c,null,n,o,a,s));let f=Xc(Rt(),n);Y_(r,s,f,o,i)}}function zp(t,e,n,r,o,i){let s=e===null,a;for(;o>0;){let c=t[o],l=Array.isArray(c),u=l?c[1]:c,f=u===null,m=n[o+1];m===Ze&&(m=f?tt:void 0);let p=f?rs(m,r):u===r?m:void 0;if(l&&!Vs(p)&&(p=rs(c,r)),Vs(p)&&(a=p,s))return a;let E=t[o+1];o=s?qn(E):Fr(E)}if(e!==null){let c=i?e.residualClasses:e.residualStyles;c!=null&&(a=rs(c,r))}return a}function Vs(t){return t!==void 0}function lC(t,e){return t==null||t===""||(typeof e=="string"?t=t+e:typeof t=="object"&&(t=Qt(Gs(t)))),t}function Wg(t,e){return(t.flags&(e?8:16))!==0}function y(t,e=""){let n=H(),r=we(),o=t+_e,i=r.firstCreatePass?jr(r,o,1,e,null):r.data[o],s=uC(r,n,i,e,t);n[o]=s,hs()&&Mu(r,n,s,i),Tr(i,!1)}var uC=(t,e,n,r,o)=>(gs(!0),a_(e[ge],r));function dC(t,e,n,r=""){return bt(t,Hn(),n)?e+Rn(n)+r:Ze}function fC(t,e,n,r,o,i=""){let s=op(),a=vg(t,s,n,o);return cs(2),a?e+Rn(n)+r+Rn(o)+i:Ze}function V(t){return Z("",t),V}function Z(t,e,n){let r=H(),o=dC(r,t,e,n);return o!==Ze&&Gg(r,Rt(),o),Z}function Vr(t,e,n,r,o){let i=H(),s=fC(i,t,e,n,r,o);return s!==Ze&&Gg(i,Rt(),s),Vr}function Gg(t,e,n){let r=Xc(e,t);c_(t[ge],r,n)}function pC(t,e,n){let r=we();if(r.firstCreatePass){let o=Nt(t);cu(n,r.data,r.blueprint,o,!0),cu(e,r.data,r.blueprint,o,!1)}}function cu(t,e,n,r,o){if(t=Ve(t),Array.isArray(t))for(let i=0;i<t.length;i++)cu(t[i],e,n,r,o);else{let i=we(),s=H(),a=Be(),c=In(t)?t:Ve(t.provide),l=Gc(t),u=a.providerIndexes&1048575,f=a.directiveStart,m=a.providerIndexes>>20;if(In(t)||!t.multi){let p=new Wn(l,o,Pt,null),E=kl(c,e,o?u:u+m,f);E===-1?(Ol(Ts(a,s),i,c),Rl(i,t,e.length),e.push(c),a.directiveStart++,a.directiveEnd++,o&&(a.providerIndexes+=1048576),n.push(p),s.push(p)):(n[E]=p,s[E]=p)}else{let p=kl(c,e,u+m,f),E=kl(c,e,u,u+m),N=p>=0&&n[p],k=E>=0&&n[E];if(o&&!k||!o&&!N){Ol(Ts(a,s),i,c);let S=mC(o?gC:hC,n.length,o,r,l,t);!o&&k&&(n[E].providerFactory=S),Rl(i,t,e.length,0),e.push(c),a.directiveStart++,a.directiveEnd++,o&&(a.providerIndexes+=1048576),n.push(S),s.push(S)}else{let S=qg(n[o?E:p],l,!o&&r);Rl(i,t,p>-1?p:E,S)}!o&&r&&k&&n[E].componentProviders++}}}function Rl(t,e,n,r){let o=In(e),i=Gf(e);if(o||i){let c=(i?Ve(e.useClass):e).prototype.ngOnDestroy;if(c){let l=t.destroyHooks||(t.destroyHooks=[]);if(!o&&e.multi){let u=l.indexOf(n);u===-1?l.push(n,[r,c]):l[u+1].push(r,c)}else l.push(n,c)}}}function qg(t,e,n){return n&&t.componentProviders++,t.multi.push(e)-1}function kl(t,e,n,r){for(let o=n;o<r;o++)if(e[o]===t)return o;return-1}function hC(t,e,n,r,o){return lu(this.multi,[])}function gC(t,e,n,r,o){let i=this.multi,s;if(this.providerFactory){let a=this.providerFactory.componentProviders,c=xo(r,r[F],this.providerFactory.index,o);s=c.slice(0,a),lu(i,s);for(let l=a;l<c.length;l++)s.push(c[l])}else s=[],lu(i,s);return s}function lu(t,e){for(let n=0;n<t.length;n++){let r=t[n];e.push(r())}return e}function mC(t,e,n,r,o,i){let s=new Wn(t,n,Pt,null);return s.multi=[],s.index=e,s.componentProviders=0,qg(s,o,r&&!n),s}function Uo(t,e=[]){return n=>{n.providersResolver=(r,o)=>pC(r,o?o(t):t,e)}}function Zg(t,e){let n=t[e];return n===Ze?void 0:n}function vC(t,e,n,r,o,i){let s=e+n;return bt(t,s,o)?mg(t,s+1,i?r.call(i,o):r(o)):Zg(t,s+1)}function yC(t,e,n,r,o,i,s){let a=e+n;return vg(t,a,o,i)?mg(t,a+2,s?r.call(s,o,i):r(o,i)):Zg(t,a+2)}function er(t,e){let n=we(),r,o=t+_e;n.firstCreatePass?(r=_C(e,n.pipeRegistry),n.data[o]=r,r.onDestroy&&(n.destroyHooks??=[]).push(o,r.onDestroy)):r=n.data[o];let i=r.factory||(r.factory=xn(r.type,!0)),s,a=$e(Pt);try{let c=Ms(!1),l=i();return Ms(c),el(n,H(),o,l),l}finally{$e(a)}}function _C(t,e){if(e)for(let n=e.length-1;n>=0;n--){let r=e[n];if(t===r.name)return r}}function zu(t,e,n){let r=t+_e,o=H(),i=Jc(o,r);return Yg(o,r)?vC(o,gl(),e,i.transform,n,i):i.transform(n)}function zo(t,e,n,r){let o=t+_e,i=H(),s=Jc(i,o);return Yg(i,o)?yC(i,gl(),e,s.transform,n,r,s):s.transform(n,r)}function Yg(t,e){return t[F].data[e].pure}var bC=(()=>{class t{zone=_(ie);changeDetectionScheduler=_(nt);applicationRef=_(Kn);applicationErrorHandler=_(mt);_onMicrotaskEmptySubscription;initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.changeDetectionScheduler.runningTick||this.zone.run(()=>{try{this.applicationRef.dirtyFlags|=1,this.applicationRef._tick()}catch(n){this.applicationErrorHandler(n)}})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static \u0275fac=function(r){return new(r||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Qg=new P("",{factory:()=>!1});function Wu({ngZoneFactory:t,ignoreChangesOutsideZone:e,scheduleInRootZone:n}){return t??=()=>new ie(le(K({},qu()),{scheduleInRootZone:n})),[{provide:ie,useFactory:t},{provide:kn,multi:!0,useFactory:()=>{let r=_(bC,{optional:!0});return()=>r.initialize()}},{provide:kn,multi:!0,useFactory:()=>{let r=_(CC);return()=>{r.initialize()}}},e===!0?{provide:bl,useValue:!0}:[],{provide:Cl,useValue:n??Ah},{provide:mt,useFactory:()=>{let r=_(ie),o=_(Ge),i;return s=>{r.runOutsideAngular(()=>{o.destroyed&&!i?setTimeout(()=>{throw s}):(i??=o.get(Ke),i.handleError(s))})}}}]}function Gu(t){let e=t?.ignoreChangesOutsideZone,n=t?.scheduleInRootZone,r=Wu({ngZoneFactory:()=>{let o=qu(t);return o.scheduleInRootZone=n,o.shouldCoalesceEventChangeDetection&&ln("NgZone_CoalesceEvent"),new ie(o)},ignoreChangesOutsideZone:e,scheduleInRootZone:n});return fo([{provide:Qg,useValue:!0},{provide:Co,useValue:!1},r])}function qu(t){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:t?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:t?.runCoalescing??!1}}var CC=(()=>{class t{subscription=new me;initialized=!1;zone=_(ie);pendingTasks=_(on);initialize(){if(this.initialized)return;this.initialized=!0;let n=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(n=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{ie.assertNotInAngularZone(),queueMicrotask(()=>{n!==null&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(n),n=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{ie.assertInAngularZone(),n??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static \u0275fac=function(r){return new(r||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var Kg=(()=>{class t{applicationErrorHandler=_(mt);appRef=_(Kn);taskService=_(on);ngZone=_(ie);zonelessEnabled=_(Co);tracing=_(cn,{optional:!0});disableScheduling=_(bl,{optional:!0})??!1;zoneIsDefined=typeof Zone<"u"&&!!Zone.root.run;schedulerTickApplyArgs=[{data:{__scheduler_tick__:!0}}];subscriptions=new me;angularZoneId=this.zoneIsDefined?this.ngZone._inner?.get(ks):null;scheduleInRootZone=!this.zonelessEnabled&&this.zoneIsDefined&&(_(Cl,{optional:!0})??!1);cancelScheduledCallback=null;useMicrotaskScheduler=!1;runningTick=!1;pendingRenderTaskId=null;constructor(){this.subscriptions.add(this.appRef.afterTick.subscribe(()=>{this.runningTick||this.cleanup()})),this.subscriptions.add(this.ngZone.onUnstable.subscribe(()=>{this.runningTick||this.cleanup()})),this.disableScheduling||=!this.zonelessEnabled&&(this.ngZone instanceof As||!this.zoneIsDefined)}notify(n){if(!this.zonelessEnabled&&n===5)return;let r=!1;switch(n){case 0:{this.appRef.dirtyFlags|=2;break}case 3:case 2:case 4:case 5:case 1:{this.appRef.dirtyFlags|=4;break}case 6:{this.appRef.dirtyFlags|=2,r=!0;break}case 12:{this.appRef.dirtyFlags|=16,r=!0;break}case 13:{this.appRef.dirtyFlags|=2,r=!0;break}case 11:{r=!0;break}default:this.appRef.dirtyFlags|=8}if(this.appRef.tracingSnapshot=this.tracing?.snapshot(this.appRef.tracingSnapshot)??null,!this.shouldScheduleTick(r))return;let o=this.useMicrotaskScheduler?Ip:Oh;this.pendingRenderTaskId=this.taskService.add(),this.scheduleInRootZone?this.cancelScheduledCallback=Zone.root.run(()=>o(()=>this.tick())):this.cancelScheduledCallback=this.ngZone.runOutsideAngular(()=>o(()=>this.tick()))}shouldScheduleTick(n){return!(this.disableScheduling&&!n||this.appRef.destroyed||this.pendingRenderTaskId!==null||this.runningTick||this.appRef._runningTick||!this.zonelessEnabled&&this.zoneIsDefined&&Zone.current.get(ks+this.angularZoneId))}tick(){if(this.runningTick||this.appRef.destroyed)return;if(this.appRef.dirtyFlags===0){this.cleanup();return}!this.zonelessEnabled&&this.appRef.dirtyFlags&7&&(this.appRef.dirtyFlags|=1);let n=this.taskService.add();try{this.ngZone.run(()=>{this.runningTick=!0,this.appRef._tick()},void 0,this.schedulerTickApplyArgs)}catch(r){this.taskService.remove(n),this.applicationErrorHandler(r)}finally{this.cleanup()}this.useMicrotaskScheduler=!0,Ip(()=>{this.useMicrotaskScheduler=!1,this.taskService.remove(n)})}ngOnDestroy(){this.subscriptions.unsubscribe(),this.cleanup()}cleanup(){if(this.runningTick=!1,this.cancelScheduledCallback?.(),this.cancelScheduledCallback=null,this.pendingRenderTaskId!==null){let n=this.pendingRenderTaskId;this.pendingRenderTaskId=null,this.taskService.remove(n)}}static \u0275fac=function(r){return new(r||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function DC(){return typeof $localize<"u"&&$localize.locale||$o}var Wo=new P("",{providedIn:"root",factory:()=>_(Wo,{optional:!0,skipSelf:!0})||DC()});var ia=class{destroyed=!1;listeners=null;errorHandler=_(Ke,{optional:!0});destroyRef=_(Oe);constructor(){this.destroyRef.onDestroy(()=>{this.destroyed=!0,this.listeners=null})}subscribe(e){if(this.destroyed)throw new R(953,!1);return(this.listeners??=[]).push(e),{unsubscribe:()=>{let n=this.listeners?.indexOf(e);n!==void 0&&n!==-1&&this.listeners?.splice(n,1)}}}emit(e){if(this.destroyed){console.warn(Tn(953,!1));return}if(this.listeners===null)return;let n=L(null);try{for(let r of this.listeners)try{r(e)}catch(o){this.errorHandler?.handleError(o)}}finally{L(n)}}};function ke(t){return Mf(t)}function U(t,e){return Zr(t,e?.equal)}var Zu=class{[Re];constructor(e){this[Re]=e}destroy(){this[Re].destroy()}};function Me(t,e){let n=e?.injector??_(Ue),r=e?.manualCleanup!==!0?n.get(Oe):null,o,i=n.get($n,null,{optional:!0}),s=n.get(nt);return i!==null?(o=xC(i.view,s,t),r instanceof lo&&r._lView===i.view&&(r=null)):o=IC(t,n.get(Do),s),o.injector=n,r!==null&&(o.onDestroyFn=r.onDestroy(()=>o.destroy())),new Zu(o)}var Xg=le(K({},Tf),{cleanupFns:void 0,zone:null,onDestroyFn:Un,run(){let t=Sr(!1);try{Sf(this)}finally{Sr(t)}},cleanup(){if(!this.cleanupFns?.length)return;let t=L(null);try{for(;this.cleanupFns.length;)this.cleanupFns.pop()()}finally{this.cleanupFns=[],L(t)}}}),EC=le(K({},Xg),{consumerMarkedDirty(){this.scheduler.schedule(this),this.notifier.notify(12)},destroy(){qt(this),this.onDestroyFn(),this.cleanup(),this.scheduler.remove(this)}}),wC=le(K({},Xg),{consumerMarkedDirty(){this.view[j]|=8192,nn(this.view),this.notifier.notify(13)},destroy(){qt(this),this.onDestroyFn(),this.cleanup(),this.view[Bt]?.delete(this)}});function xC(t,e,n){let r=Object.create(wC);return r.view=t,r.zone=typeof Zone<"u"?Zone.current:null,r.notifier=e,r.fn=Jg(r,n),t[Bt]??=new Set,t[Bt].add(r),r.consumerMarkedDirty(r),r}function IC(t,e,n){let r=Object.create(EC);return r.fn=Jg(r,t),r.scheduler=e,r.notifier=n,r.zone=typeof Zone<"u"?Zone.current:null,r.scheduler.add(r),r.notifier.notify(12),r}function Jg(t,e){return()=>{e(n=>(t.cleanupFns??=[]).push(n))}}var om=Symbol("InputSignalNode#UNSET"),BC=le(K({},Yr),{transformFn:void 0,applyValueToInputSignal(t,e){lr(t,e)}});function im(t,e){let n=Object.create(BC);n.value=t,n.transformFn=e?.transform;function r(){if(hn(n),n.value===om){let o=null;throw new R(-950,o)}return n.value}return r[Re]=n,r}var HC=new P("");HC.__NG_ELEMENT_ID__=t=>{let e=Be();if(e===null)throw new R(204,!1);if(e.type&2)return e.value;if(t&8)return null;throw new R(204,!1)};function Y(t){return new ia}function em(t,e){return im(t,e)}function $C(t){return im(om,t)}var O=(em.required=$C,em);function tm(t,e){return Mg(e)}function UC(t,e){return Tg(e)}var Ut=(tm.required=UC,tm);var Qu=new P(""),zC=new P("");function Go(t){return!t.moduleRef}function WC(t){let e=Go(t)?t.r3Injector:t.moduleRef.injector,n=e.get(ie);return n.run(()=>{Go(t)?t.r3Injector.resolveInjectorInitializers():t.moduleRef.resolveInjectorInitializers();let r=e.get(mt),o;if(n.runOutsideAngular(()=>{o=n.onError.subscribe({next:r})}),Go(t)){let i=()=>e.destroy(),s=t.platformInjector.get(Qu);s.add(i),e.onDestroy(()=>{o.unsubscribe(),s.delete(i)})}else{let i=()=>t.moduleRef.destroy(),s=t.platformInjector.get(Qu);s.add(i),t.moduleRef.onDestroy(()=>{wo(t.allPlatformModules,t.moduleRef),o.unsubscribe(),s.delete(i)})}return qC(r,n,()=>{let i=e.get(on),s=i.add(),a=e.get(ju);return a.runInitializers(),a.donePromise.then(()=>{let c=e.get(Wo,$o);if(jg(c||$o),!e.get(zC,!0))return Go(t)?e.get(Kn):(t.allPlatformModules.push(t.moduleRef),t.moduleRef);if(Go(t)){let u=e.get(Kn);return t.rootComponent!==void 0&&u.bootstrap(t.rootComponent),u}else return GC?.(t.moduleRef,t.allPlatformModules),t.moduleRef}).finally(()=>{i.remove(s)})})})}var GC;function qC(t,e,n){try{let r=n();return Vo(r)?r.catch(o=>{throw e.runOutsideAngular(()=>t(o)),o}):r}catch(r){throw e.runOutsideAngular(()=>t(r)),r}}var sa=null;function ZC(t=[],e){return Ue.create({name:e,providers:[{provide:po,useValue:"platform"},{provide:Qu,useValue:new Set([()=>sa=null])},...t]})}function YC(t=[]){if(sa)return sa;let e=ZC(t);return sa=e,Pg(),QC(e),e}function QC(t){let e=t.get(Us,null);wr(t,()=>{e?.forEach(n=>n())})}var la=(()=>{class t{static __NG_ELEMENT_ID__=KC}return t})();function KC(t){return XC(Be(),H(),(t&16)===16)}function XC(t,e,n){if(tn(t)&&!n){let r=it(t.index,e);return new sn(r,r)}else if(t.type&175){let r=e[We];return new sn(r,e)}return null}var Ku=class{constructor(){}supports(e){return Ou(e)}create(e){return new Xu(e)}},JC=(t,e)=>e,Xu=class{length=0;collection;_linkedRecords=null;_unlinkedRecords=null;_previousItHead=null;_itHead=null;_itTail=null;_additionsHead=null;_additionsTail=null;_movesHead=null;_movesTail=null;_removalsHead=null;_removalsTail=null;_identityChangesHead=null;_identityChangesTail=null;_trackByFn;constructor(e){this._trackByFn=e||JC}forEachItem(e){let n;for(n=this._itHead;n!==null;n=n._next)e(n)}forEachOperation(e){let n=this._itHead,r=this._removalsHead,o=0,i=null;for(;n||r;){let s=!r||n&&n.currentIndex<nm(r,o,i)?n:r,a=nm(s,o,i),c=s.currentIndex;if(s===r)o--,r=r._nextRemoved;else if(n=n._next,s.previousIndex==null)o++;else{i||(i=[]);let l=a-o,u=c-o;if(l!=u){for(let m=0;m<l;m++){let p=m<i.length?i[m]:i[m]=0,E=p+m;u<=E&&E<l&&(i[m]=p+1)}let f=s.previousIndex;i[f]=u-l}}a!==c&&e(s,a,c)}}forEachPreviousItem(e){let n;for(n=this._previousItHead;n!==null;n=n._nextPrevious)e(n)}forEachAddedItem(e){let n;for(n=this._additionsHead;n!==null;n=n._nextAdded)e(n)}forEachMovedItem(e){let n;for(n=this._movesHead;n!==null;n=n._nextMoved)e(n)}forEachRemovedItem(e){let n;for(n=this._removalsHead;n!==null;n=n._nextRemoved)e(n)}forEachIdentityChange(e){let n;for(n=this._identityChangesHead;n!==null;n=n._nextIdentityChange)e(n)}diff(e){if(e==null&&(e=[]),!Ou(e))throw new R(900,!1);return this.check(e)?this:null}onDestroy(){}check(e){this._reset();let n=this._itHead,r=!1,o,i,s;if(Array.isArray(e)){this.length=e.length;for(let a=0;a<this.length;a++)i=e[a],s=this._trackByFn(a,i),n===null||!Object.is(n.trackById,s)?(n=this._mismatch(n,i,s,a),r=!0):(r&&(n=this._verifyReinsertion(n,i,s,a)),Object.is(n.item,i)||this._addIdentityChange(n,i)),n=n._next}else o=0,hg(e,a=>{s=this._trackByFn(o,a),n===null||!Object.is(n.trackById,s)?(n=this._mismatch(n,a,s,o),r=!0):(r&&(n=this._verifyReinsertion(n,a,s,o)),Object.is(n.item,a)||this._addIdentityChange(n,a)),n=n._next,o++}),this.length=o;return this._truncate(n),this.collection=e,this.isDirty}get isDirty(){return this._additionsHead!==null||this._movesHead!==null||this._removalsHead!==null||this._identityChangesHead!==null}_reset(){if(this.isDirty){let e;for(e=this._previousItHead=this._itHead;e!==null;e=e._next)e._nextPrevious=e._next;for(e=this._additionsHead;e!==null;e=e._nextAdded)e.previousIndex=e.currentIndex;for(this._additionsHead=this._additionsTail=null,e=this._movesHead;e!==null;e=e._nextMoved)e.previousIndex=e.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(e,n,r,o){let i;return e===null?i=this._itTail:(i=e._prev,this._remove(e)),e=this._unlinkedRecords===null?null:this._unlinkedRecords.get(r,null),e!==null?(Object.is(e.item,n)||this._addIdentityChange(e,n),this._reinsertAfter(e,i,o)):(e=this._linkedRecords===null?null:this._linkedRecords.get(r,o),e!==null?(Object.is(e.item,n)||this._addIdentityChange(e,n),this._moveAfter(e,i,o)):e=this._addAfter(new Ju(n,r),i,o)),e}_verifyReinsertion(e,n,r,o){let i=this._unlinkedRecords===null?null:this._unlinkedRecords.get(r,null);return i!==null?e=this._reinsertAfter(i,e._prev,o):e.currentIndex!=o&&(e.currentIndex=o,this._addToMoves(e,o)),e}_truncate(e){for(;e!==null;){let n=e._next;this._addToRemovals(this._unlink(e)),e=n}this._unlinkedRecords!==null&&this._unlinkedRecords.clear(),this._additionsTail!==null&&(this._additionsTail._nextAdded=null),this._movesTail!==null&&(this._movesTail._nextMoved=null),this._itTail!==null&&(this._itTail._next=null),this._removalsTail!==null&&(this._removalsTail._nextRemoved=null),this._identityChangesTail!==null&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(e,n,r){this._unlinkedRecords!==null&&this._unlinkedRecords.remove(e);let o=e._prevRemoved,i=e._nextRemoved;return o===null?this._removalsHead=i:o._nextRemoved=i,i===null?this._removalsTail=o:i._prevRemoved=o,this._insertAfter(e,n,r),this._addToMoves(e,r),e}_moveAfter(e,n,r){return this._unlink(e),this._insertAfter(e,n,r),this._addToMoves(e,r),e}_addAfter(e,n,r){return this._insertAfter(e,n,r),this._additionsTail===null?this._additionsTail=this._additionsHead=e:this._additionsTail=this._additionsTail._nextAdded=e,e}_insertAfter(e,n,r){let o=n===null?this._itHead:n._next;return e._next=o,e._prev=n,o===null?this._itTail=e:o._prev=e,n===null?this._itHead=e:n._next=e,this._linkedRecords===null&&(this._linkedRecords=new aa),this._linkedRecords.put(e),e.currentIndex=r,e}_remove(e){return this._addToRemovals(this._unlink(e))}_unlink(e){this._linkedRecords!==null&&this._linkedRecords.remove(e);let n=e._prev,r=e._next;return n===null?this._itHead=r:n._next=r,r===null?this._itTail=n:r._prev=n,e}_addToMoves(e,n){return e.previousIndex===n||(this._movesTail===null?this._movesTail=this._movesHead=e:this._movesTail=this._movesTail._nextMoved=e),e}_addToRemovals(e){return this._unlinkedRecords===null&&(this._unlinkedRecords=new aa),this._unlinkedRecords.put(e),e.currentIndex=null,e._nextRemoved=null,this._removalsTail===null?(this._removalsTail=this._removalsHead=e,e._prevRemoved=null):(e._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=e),e}_addIdentityChange(e,n){return e.item=n,this._identityChangesTail===null?this._identityChangesTail=this._identityChangesHead=e:this._identityChangesTail=this._identityChangesTail._nextIdentityChange=e,e}},Ju=class{item;trackById;currentIndex=null;previousIndex=null;_nextPrevious=null;_prev=null;_next=null;_prevDup=null;_nextDup=null;_prevRemoved=null;_nextRemoved=null;_nextAdded=null;_nextMoved=null;_nextIdentityChange=null;constructor(e,n){this.item=e,this.trackById=n}},ed=class{_head=null;_tail=null;add(e){this._head===null?(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,n){let r;for(r=this._head;r!==null;r=r._nextDup)if((n===null||n<=r.currentIndex)&&Object.is(r.trackById,e))return r;return null}remove(e){let n=e._prevDup,r=e._nextDup;return n===null?this._head=r:n._nextDup=r,r===null?this._tail=n:r._prevDup=n,this._head===null}},aa=class{map=new Map;put(e){let n=e.trackById,r=this.map.get(n);r||(r=new ed,this.map.set(n,r)),r.add(e)}get(e,n){let r=e,o=this.map.get(r);return o?o.get(e,n):null}remove(e){let n=e.trackById;return this.map.get(n).remove(e)&&this.map.delete(n),e}get isEmpty(){return this.map.size===0}clear(){this.map.clear()}};function nm(t,e,n){let r=t.previousIndex;if(r===null)return r;let o=0;return n&&r<n.length&&(o=n[r]),r+e+o}function rm(){return new ua([new Ku])}var ua=(()=>{class t{factories;static \u0275prov=B({token:t,providedIn:"root",factory:rm});constructor(n){this.factories=n}static create(n,r){if(r!=null){let o=r.factories.slice();n=n.concat(o)}return new t(n)}static extend(n){return{provide:t,useFactory:()=>{let r=_(t,{optional:!0,skipSelf:!0});return t.create(n,r||rm())}}}find(n){let r=this.factories.find(o=>o.supports(n));if(r!=null)return r;throw new R(901,!1)}}return t})();function sm(t){let{rootComponent:e,appProviders:n,platformProviders:r,platformRef:o}=t;te(8);try{let i=o?.injector??YC(r),s=[Wu({}),{provide:nt,useExisting:Kg},mp,...n||[]],a=new Ro({providers:s,parent:i,debugName:"",runEnvironmentInitializers:!1});return WC({r3Injector:a.injector,platformInjector:i,rootComponent:e})}catch(i){return Promise.reject(i)}finally{te(9)}}function am(t){return typeof t=="boolean"?t:t!=null&&t!=="false"}var Yu=Symbol("NOT_SET"),cm=new Set,eD=le(K({},Yr),{consumerIsAlwaysLive:!0,consumerAllowSignalWrites:!0,value:Yu,cleanup:null,consumerMarkedDirty(){if(this.sequence.impl.executing){if(this.sequence.lastPhase===null||this.sequence.lastPhase<this.phase)return;this.sequence.erroredOrDestroyed=!0}this.sequence.scheduler.notify(7)},phaseFn(t){if(this.sequence.lastPhase=this.phase,!this.dirty)return this.signal;if(this.dirty=!1,this.value!==Yu&&!mn(this))return this.signal;try{for(let o of this.cleanup??cm)o()}finally{this.cleanup?.clear()}let e=[];t!==void 0&&e.push(t),e.push(this.registerCleanupFn);let n=Gt(this),r;try{r=this.userFn.apply(null,e)}finally{gn(this,n)}return(this.value===Yu||!this.equal(this.value,r))&&(this.value=r,this.version++),this.signal}}),td=class extends Io{scheduler;lastPhase=null;nodes=[void 0,void 0,void 0,void 0];constructor(e,n,r,o,i,s=null){super(e,[void 0,void 0,void 0,void 0],r,!1,i.get(Oe),s),this.scheduler=o;for(let a of Eu){let c=n[a];if(c===void 0)continue;let l=Object.create(eD);l.sequence=this,l.phase=a,l.userFn=c,l.dirty=!0,l.signal=()=>(hn(l),l.value),l.signal[Re]=l,l.registerCleanupFn=u=>(l.cleanup??=new Set).add(u),this.nodes[a]=l,this.hooks[a]=u=>l.phaseFn(u)}}afterRun(){super.afterRun(),this.lastPhase=null}destroy(){super.destroy();for(let e of this.nodes)if(e)try{for(let n of e.cleanup??cm)n()}finally{qt(e)}}};function nd(t,e){let n=e?.injector??_(Ue),r=n.get(nt),o=n.get(Ys),i=n.get(cn,null,{optional:!0});o.impl??=n.get(wu);let s=t;typeof s=="function"&&(s={mixedReadWrite:t});let a=n.get($n,null,{optional:!0}),c=new td(o.impl,[s.earlyRead,s.write,s.mixedReadWrite,s.read],a?.view,r,n,i?.snapshot(null));return o.impl.register(c),c}var lm=null;function Zo(){return lm}function rd(t){lm??=t}var qo=class{};var He=(function(t){return t[t.Format=0]="Format",t[t.Standalone=1]="Standalone",t})(He||{}),oe=(function(t){return t[t.Narrow=0]="Narrow",t[t.Abbreviated=1]="Abbreviated",t[t.Wide=2]="Wide",t[t.Short=3]="Short",t})(oe||{}),Ye=(function(t){return t[t.Short=0]="Short",t[t.Medium=1]="Medium",t[t.Long=2]="Long",t[t.Full=3]="Full",t})(Ye||{}),Wt={Decimal:0,Group:1,List:2,PercentSign:3,PlusSign:4,MinusSign:5,Exponential:6,SuperscriptingExponent:7,PerMille:8,Infinity:9,NaN:10,TimeSeparator:11,CurrencyDecimal:12,CurrencyGroup:13};function dm(t){return Je(t)[Ie.LocaleId]}function fm(t,e,n){let r=Je(t),o=[r[Ie.DayPeriodsFormat],r[Ie.DayPeriodsStandalone]],i=ct(o,e);return ct(i,n)}function pm(t,e,n){let r=Je(t),o=[r[Ie.DaysFormat],r[Ie.DaysStandalone]],i=ct(o,e);return ct(i,n)}function hm(t,e,n){let r=Je(t),o=[r[Ie.MonthsFormat],r[Ie.MonthsStandalone]],i=ct(o,e);return ct(i,n)}function gm(t,e){let r=Je(t)[Ie.Eras];return ct(r,e)}function Yo(t,e){let n=Je(t);return ct(n[Ie.DateFormat],e)}function Qo(t,e){let n=Je(t);return ct(n[Ie.TimeFormat],e)}function Ko(t,e){let r=Je(t)[Ie.DateTimeFormat];return ct(r,e)}function Xo(t,e){let n=Je(t),r=n[Ie.NumberSymbols][e];if(typeof r>"u"){if(e===Wt.CurrencyDecimal)return n[Ie.NumberSymbols][Wt.Decimal];if(e===Wt.CurrencyGroup)return n[Ie.NumberSymbols][Wt.Group]}return r}function mm(t){if(!t[Ie.ExtraData])throw new R(2303,!1)}function vm(t){let e=Je(t);return mm(e),(e[Ie.ExtraData][2]||[]).map(r=>typeof r=="string"?od(r):[od(r[0]),od(r[1])])}function ym(t,e,n){let r=Je(t);mm(r);let o=[r[Ie.ExtraData][0],r[Ie.ExtraData][1]],i=ct(o,e)||[];return ct(i,n)||[]}function ct(t,e){for(let n=e;n>-1;n--)if(typeof t[n]<"u")return t[n];throw new R(2304,!1)}function od(t){let[e,n]=t.split(":");return{hours:+e,minutes:+n}}var tD=/^(\d{4,})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/,da={},nD=/((?:[^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]*)/,rD=256;function _m(t,e,n,r){let o=pD(t);oD(e),e=zt(n,e)||e;let s=[],a;for(;e;)if(a=nD.exec(e),a){s=s.concat(a.slice(1));let u=s.pop();if(!u)break;e=u}else{s.push(e);break}let c=o.getTimezoneOffset();r&&(c=Cm(r,c),o=fD(o,r));let l="";return s.forEach(u=>{let f=uD(u);l+=f?f(o,n,c):u==="''"?"'":u.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),l}function oD(t){if(t.length>rD)throw new R(2300,!1)}function ma(t,e,n){let r=new Date(0);return r.setFullYear(t,e,n),r.setHours(0,0,0),r}function zt(t,e){let n=dm(t);if(da[n]??={},da[n][e])return da[n][e];let r="";switch(e){case"shortDate":r=Yo(t,Ye.Short);break;case"mediumDate":r=Yo(t,Ye.Medium);break;case"longDate":r=Yo(t,Ye.Long);break;case"fullDate":r=Yo(t,Ye.Full);break;case"shortTime":r=Qo(t,Ye.Short);break;case"mediumTime":r=Qo(t,Ye.Medium);break;case"longTime":r=Qo(t,Ye.Long);break;case"fullTime":r=Qo(t,Ye.Full);break;case"short":let o=zt(t,"shortTime"),i=zt(t,"shortDate");r=fa(Ko(t,Ye.Short),[o,i]);break;case"medium":let s=zt(t,"mediumTime"),a=zt(t,"mediumDate");r=fa(Ko(t,Ye.Medium),[s,a]);break;case"long":let c=zt(t,"longTime"),l=zt(t,"longDate");r=fa(Ko(t,Ye.Long),[c,l]);break;case"full":let u=zt(t,"fullTime"),f=zt(t,"fullDate");r=fa(Ko(t,Ye.Full),[u,f]);break}return r&&(da[n][e]=r),r}function fa(t,e){return e&&(t=t.replace(/\{([^}]+)}/g,function(n,r){return e!=null&&r in e?e[r]:n})),t}function Dt(t,e,n="-",r,o){let i="";(t<0||o&&t<=0)&&(o?t=-t+1:(t=-t,i=n));let s=String(t);for(;s.length<e;)s="0"+s;return r&&(s=s.slice(s.length-e)),i+s}function iD(t,e){return Dt(t,3).substring(0,e)}function Te(t,e,n=0,r=!1,o=!1){return function(i,s){let a=sD(t,i);if((n>0||a>-n)&&(a+=n),t===3)a===0&&n===-12&&(a=12);else if(t===6)return iD(a,e);let c=Xo(s,Wt.MinusSign);return Dt(a,e,c,r,o)}}function sD(t,e){switch(t){case 0:return e.getFullYear();case 1:return e.getMonth();case 2:return e.getDate();case 3:return e.getHours();case 4:return e.getMinutes();case 5:return e.getSeconds();case 6:return e.getMilliseconds();case 7:return e.getDay();default:throw new R(2301,!1)}}function pe(t,e,n=He.Format,r=!1){return function(o,i){return aD(o,i,t,e,n,r)}}function aD(t,e,n,r,o,i){switch(n){case 2:return hm(e,o,r)[t.getMonth()];case 1:return pm(e,o,r)[t.getDay()];case 0:let s=t.getHours(),a=t.getMinutes();if(i){let l=vm(e),u=ym(e,o,r),f=l.findIndex(m=>{if(Array.isArray(m)){let[p,E]=m,N=s>=p.hours&&a>=p.minutes,k=s<E.hours||s===E.hours&&a<E.minutes;if(p.hours<E.hours){if(N&&k)return!0}else if(N||k)return!0}else if(m.hours===s&&m.minutes===a)return!0;return!1});if(f!==-1)return u[f]}return fm(e,o,r)[s<12?0:1];case 3:return gm(e,r)[t.getFullYear()<=0?0:1];default:let c=n;throw new R(2302,!1)}}function pa(t){return function(e,n,r){let o=-1*r,i=Xo(n,Wt.MinusSign),s=o>0?Math.floor(o/60):Math.ceil(o/60);switch(t){case 0:return(o>=0?"+":"")+Dt(s,2,i)+Dt(Math.abs(o%60),2,i);case 1:return"GMT"+(o>=0?"+":"")+Dt(s,1,i);case 2:return"GMT"+(o>=0?"+":"")+Dt(s,2,i)+":"+Dt(Math.abs(o%60),2,i);case 3:return r===0?"Z":(o>=0?"+":"")+Dt(s,2,i)+":"+Dt(Math.abs(o%60),2,i);default:throw new R(2310,!1)}}}var cD=0,ga=4;function lD(t){let e=ma(t,cD,1).getDay();return ma(t,0,1+(e<=ga?ga:ga+7)-e)}function bm(t){let e=t.getDay(),n=e===0?-3:ga-e;return ma(t.getFullYear(),t.getMonth(),t.getDate()+n)}function id(t,e=!1){return function(n,r){let o;if(e){let i=new Date(n.getFullYear(),n.getMonth(),1).getDay()-1,s=n.getDate();o=1+Math.floor((s+i)/7)}else{let i=bm(n),s=lD(i.getFullYear()),a=i.getTime()-s.getTime();o=1+Math.round(a/6048e5)}return Dt(o,t,Xo(r,Wt.MinusSign))}}function ha(t,e=!1){return function(n,r){let i=bm(n).getFullYear();return Dt(i,t,Xo(r,Wt.MinusSign),e)}}var sd={};function uD(t){if(sd[t])return sd[t];let e;switch(t){case"G":case"GG":case"GGG":e=pe(3,oe.Abbreviated);break;case"GGGG":e=pe(3,oe.Wide);break;case"GGGGG":e=pe(3,oe.Narrow);break;case"y":e=Te(0,1,0,!1,!0);break;case"yy":e=Te(0,2,0,!0,!0);break;case"yyy":e=Te(0,3,0,!1,!0);break;case"yyyy":e=Te(0,4,0,!1,!0);break;case"Y":e=ha(1);break;case"YY":e=ha(2,!0);break;case"YYY":e=ha(3);break;case"YYYY":e=ha(4);break;case"M":case"L":e=Te(1,1,1);break;case"MM":case"LL":e=Te(1,2,1);break;case"MMM":e=pe(2,oe.Abbreviated);break;case"MMMM":e=pe(2,oe.Wide);break;case"MMMMM":e=pe(2,oe.Narrow);break;case"LLL":e=pe(2,oe.Abbreviated,He.Standalone);break;case"LLLL":e=pe(2,oe.Wide,He.Standalone);break;case"LLLLL":e=pe(2,oe.Narrow,He.Standalone);break;case"w":e=id(1);break;case"ww":e=id(2);break;case"W":e=id(1,!0);break;case"d":e=Te(2,1);break;case"dd":e=Te(2,2);break;case"c":case"cc":e=Te(7,1);break;case"ccc":e=pe(1,oe.Abbreviated,He.Standalone);break;case"cccc":e=pe(1,oe.Wide,He.Standalone);break;case"ccccc":e=pe(1,oe.Narrow,He.Standalone);break;case"cccccc":e=pe(1,oe.Short,He.Standalone);break;case"E":case"EE":case"EEE":e=pe(1,oe.Abbreviated);break;case"EEEE":e=pe(1,oe.Wide);break;case"EEEEE":e=pe(1,oe.Narrow);break;case"EEEEEE":e=pe(1,oe.Short);break;case"a":case"aa":case"aaa":e=pe(0,oe.Abbreviated);break;case"aaaa":e=pe(0,oe.Wide);break;case"aaaaa":e=pe(0,oe.Narrow);break;case"b":case"bb":case"bbb":e=pe(0,oe.Abbreviated,He.Standalone,!0);break;case"bbbb":e=pe(0,oe.Wide,He.Standalone,!0);break;case"bbbbb":e=pe(0,oe.Narrow,He.Standalone,!0);break;case"B":case"BB":case"BBB":e=pe(0,oe.Abbreviated,He.Format,!0);break;case"BBBB":e=pe(0,oe.Wide,He.Format,!0);break;case"BBBBB":e=pe(0,oe.Narrow,He.Format,!0);break;case"h":e=Te(3,1,-12);break;case"hh":e=Te(3,2,-12);break;case"H":e=Te(3,1);break;case"HH":e=Te(3,2);break;case"m":e=Te(4,1);break;case"mm":e=Te(4,2);break;case"s":e=Te(5,1);break;case"ss":e=Te(5,2);break;case"S":e=Te(6,1);break;case"SS":e=Te(6,2);break;case"SSS":e=Te(6,3);break;case"Z":case"ZZ":case"ZZZ":e=pa(0);break;case"ZZZZZ":e=pa(3);break;case"O":case"OO":case"OOO":case"z":case"zz":case"zzz":e=pa(1);break;case"OOOO":case"ZZZZ":case"zzzz":e=pa(2);break;default:return null}return sd[t]=e,e}function Cm(t,e){t=t.replace(/:/g,"");let n=Date.parse("Jan 01, 1970 00:00:00 "+t)/6e4;return isNaN(n)?e:n}function dD(t,e){return t=new Date(t.getTime()),t.setMinutes(t.getMinutes()+e),t}function fD(t,e,n){let o=t.getTimezoneOffset(),i=Cm(e,o);return dD(t,-1*(i-o))}function pD(t){if(um(t))return t;if(typeof t=="number"&&!isNaN(t))return new Date(t);if(typeof t=="string"){if(t=t.trim(),/^(\d{4}(-\d{1,2}(-\d{1,2})?)?)$/.test(t)){let[o,i=1,s=1]=t.split("-").map(a=>+a);return ma(o,i-1,s)}let n=parseFloat(t);if(!isNaN(t-n))return new Date(n);let r;if(r=t.match(tD))return hD(r)}let e=new Date(t);if(!um(e))throw new R(2311,!1);return e}function hD(t){let e=new Date(0),n=0,r=0,o=t[8]?e.setUTCFullYear:e.setFullYear,i=t[8]?e.setUTCHours:e.setHours;t[9]&&(n=Number(t[9]+t[10]),r=Number(t[9]+t[11])),o.call(e,Number(t[1]),Number(t[2])-1,Number(t[3]));let s=Number(t[4]||0)-n,a=Number(t[5]||0)-r,c=Number(t[6]||0),l=Math.floor(parseFloat("0."+(t[7]||0))*1e3);return i.call(e,s,a,c,l),e}function um(t){return t instanceof Date&&!isNaN(t.valueOf())}function Dm(t,e){return new R(2100,!1)}var ad=class{createSubscription(e,n,r){return ke(()=>e.subscribe({next:n,error:r}))}dispose(e){ke(()=>e.unsubscribe())}},cd=class{createSubscription(e,n,r){return e.then(o=>n?.(o),o=>r?.(o)),{unsubscribe:()=>{n=null,r=null}}}dispose(e){e.unsubscribe()}},gD=new cd,mD=new ad,ld=(()=>{class t{_ref;_latestValue=null;markForCheckOnValueUpdate=!0;_subscription=null;_obj=null;_strategy=null;applicationErrorHandler=_(mt);constructor(n){this._ref=n}ngOnDestroy(){this._subscription&&this._dispose(),this._ref=null}transform(n){if(!this._obj){if(n)try{this.markForCheckOnValueUpdate=!1,this._subscribe(n)}finally{this.markForCheckOnValueUpdate=!0}return this._latestValue}return n!==this._obj?(this._dispose(),this.transform(n)):this._latestValue}_subscribe(n){this._obj=n,this._strategy=this._selectStrategy(n),this._subscription=this._strategy.createSubscription(n,r=>this._updateLatestValue(n,r),r=>this.applicationErrorHandler(r))}_selectStrategy(n){if(Vo(n))return gD;if(oa(n))return mD;throw Dm(t,n)}_dispose(){this._strategy.dispose(this._subscription),this._latestValue=null,this._subscription=null,this._obj=null}_updateLatestValue(n,r){n===this._obj&&(this._latestValue=r,this.markForCheckOnValueUpdate&&this._ref?.markForCheck())}static \u0275fac=function(r){return new(r||t)(Pt(la,16))};static \u0275pipe=na({name:"async",type:t,pure:!1})}return t})();var vD="mediumDate",Em=new P(""),wm=new P(""),Jo=(()=>{class t{locale;defaultTimezone;defaultOptions;constructor(n,r,o){this.locale=n,this.defaultTimezone=r,this.defaultOptions=o}transform(n,r,o,i){if(n==null||n===""||n!==n)return null;try{let s=r??this.defaultOptions?.dateFormat??vD,a=o??this.defaultOptions?.timezone??this.defaultTimezone??void 0;return _m(n,s,i||this.locale,a)}catch(s){throw Dm(t,s.message)}}static \u0275fac=function(r){return new(r||t)(Pt(Wo,16),Pt(Em,24),Pt(wm,24))};static \u0275pipe=na({name:"date",type:t,pure:!0})}return t})();function ei(t,e){e=encodeURIComponent(e);for(let n of t.split(";")){let r=n.indexOf("="),[o,i]=r==-1?[n,""]:[n.slice(0,r),n.slice(r+1)];if(o.trim()===e)return decodeURIComponent(i)}return null}var tr=class{};var ud="browser";function xm(t){return t===ud}var ti=class{_doc;constructor(e){this._doc=e}manager},va=(()=>{class t extends ti{constructor(n){super(n)}supports(n){return!0}addEventListener(n,r,o,i){return n.addEventListener(r,o,i),()=>this.removeEventListener(n,r,o,i)}removeEventListener(n,r,o,i){return n.removeEventListener(r,o,i)}static \u0275fac=function(r){return new(r||t)(Q(Ae))};static \u0275prov=B({token:t,factory:t.\u0275fac})}return t})(),_a=new P(""),gd=(()=>{class t{_zone;_plugins;_eventNameToPlugin=new Map;constructor(n,r){this._zone=r,n.forEach(s=>{s.manager=this});let o=n.filter(s=>!(s instanceof va));this._plugins=o.slice().reverse();let i=n.find(s=>s instanceof va);i&&this._plugins.push(i)}addEventListener(n,r,o,i){return this._findPluginFor(r).addEventListener(n,r,o,i)}getZone(){return this._zone}_findPluginFor(n){let r=this._eventNameToPlugin.get(n);if(r)return r;if(r=this._plugins.find(i=>i.supports(n)),!r)throw new R(5101,!1);return this._eventNameToPlugin.set(n,r),r}static \u0275fac=function(r){return new(r||t)(Q(_a),Q(ie))};static \u0275prov=B({token:t,factory:t.\u0275fac})}return t})(),dd="ng-app-id";function Im(t){for(let e of t)e.remove()}function Mm(t,e){let n=e.createElement("style");return n.textContent=t,n}function bD(t,e,n,r){let o=t.head?.querySelectorAll(`style[${dd}="${e}"],link[${dd}="${e}"]`);if(o)for(let i of o)i.removeAttribute(dd),i instanceof HTMLLinkElement?r.set(i.href.slice(i.href.lastIndexOf("/")+1),{usage:0,elements:[i]}):i.textContent&&n.set(i.textContent,{usage:0,elements:[i]})}function pd(t,e){let n=e.createElement("link");return n.setAttribute("rel","stylesheet"),n.setAttribute("href",t),n}var md=(()=>{class t{doc;appId;nonce;inline=new Map;external=new Map;hosts=new Set;constructor(n,r,o,i={}){this.doc=n,this.appId=r,this.nonce=o,bD(n,r,this.inline,this.external),this.hosts.add(n.head)}addStyles(n,r){for(let o of n)this.addUsage(o,this.inline,Mm);r?.forEach(o=>this.addUsage(o,this.external,pd))}removeStyles(n,r){for(let o of n)this.removeUsage(o,this.inline);r?.forEach(o=>this.removeUsage(o,this.external))}addUsage(n,r,o){let i=r.get(n);i?i.usage++:r.set(n,{usage:1,elements:[...this.hosts].map(s=>this.addElement(s,o(n,this.doc)))})}removeUsage(n,r){let o=r.get(n);o&&(o.usage--,o.usage<=0&&(Im(o.elements),r.delete(n)))}ngOnDestroy(){for(let[,{elements:n}]of[...this.inline,...this.external])Im(n);this.hosts.clear()}addHost(n){this.hosts.add(n);for(let[r,{elements:o}]of this.inline)o.push(this.addElement(n,Mm(r,this.doc)));for(let[r,{elements:o}]of this.external)o.push(this.addElement(n,pd(r,this.doc)))}removeHost(n){this.hosts.delete(n)}addElement(n,r){return this.nonce&&r.setAttribute("nonce",this.nonce),n.appendChild(r)}static \u0275fac=function(r){return new(r||t)(Q(Ae),Q($s),Q(zs,8),Q(Zn))};static \u0275prov=B({token:t,factory:t.\u0275fac})}return t})(),fd={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/Math/MathML"},vd=/%COMP%/g;var Sm="%COMP%",CD=`_nghost-${Sm}`,DD=`_ngcontent-${Sm}`,ED=!0,wD=new P("",{providedIn:"root",factory:()=>ED});function xD(t){return DD.replace(vd,t)}function ID(t){return CD.replace(vd,t)}function Nm(t,e){return e.map(n=>n.replace(vd,t))}var yd=(()=>{class t{eventManager;sharedStylesHost;appId;removeStylesOnCompDestroy;doc;ngZone;nonce;tracingService;rendererByCompId=new Map;defaultRenderer;platformIsServer;constructor(n,r,o,i,s,a,c=null,l=null){this.eventManager=n,this.sharedStylesHost=r,this.appId=o,this.removeStylesOnCompDestroy=i,this.doc=s,this.ngZone=a,this.nonce=c,this.tracingService=l,this.platformIsServer=!1,this.defaultRenderer=new ni(n,s,a,this.platformIsServer,this.tracingService)}createRenderer(n,r){if(!n||!r)return this.defaultRenderer;let o=this.getOrCreateRenderer(n,r);return o instanceof ya?o.applyToHost(n):o instanceof ri&&o.applyStyles(),o}getOrCreateRenderer(n,r){let o=this.rendererByCompId,i=o.get(r.id);if(!i){let s=this.doc,a=this.ngZone,c=this.eventManager,l=this.sharedStylesHost,u=this.removeStylesOnCompDestroy,f=this.platformIsServer,m=this.tracingService;switch(r.encapsulation){case Ht.Emulated:i=new ya(c,l,r,this.appId,u,s,a,f,m);break;case Ht.ShadowDom:return new hd(c,l,n,r,s,a,this.nonce,f,m);default:i=new ri(c,l,r,u,s,a,f,m);break}o.set(r.id,i)}return i}ngOnDestroy(){this.rendererByCompId.clear()}componentReplaced(n){this.rendererByCompId.delete(n)}static \u0275fac=function(r){return new(r||t)(Q(gd),Q(md),Q($s),Q(wD),Q(Ae),Q(ie),Q(zs),Q(cn,8))};static \u0275prov=B({token:t,factory:t.\u0275fac})}return t})(),ni=class{eventManager;doc;ngZone;platformIsServer;tracingService;data=Object.create(null);throwOnSyntheticProps=!0;constructor(e,n,r,o,i){this.eventManager=e,this.doc=n,this.ngZone=r,this.platformIsServer=o,this.tracingService=i}destroy(){}destroyNode=null;createElement(e,n){return n?this.doc.createElementNS(fd[n]||n,e):this.doc.createElement(e)}createComment(e){return this.doc.createComment(e)}createText(e){return this.doc.createTextNode(e)}appendChild(e,n){(Tm(e)?e.content:e).appendChild(n)}insertBefore(e,n,r){e&&(Tm(e)?e.content:e).insertBefore(n,r)}removeChild(e,n){n.remove()}selectRootElement(e,n){let r=typeof e=="string"?this.doc.querySelector(e):e;if(!r)throw new R(-5104,!1);return n||(r.textContent=""),r}parentNode(e){return e.parentNode}nextSibling(e){return e.nextSibling}setAttribute(e,n,r,o){if(o){n=o+":"+n;let i=fd[o];i?e.setAttributeNS(i,n,r):e.setAttribute(n,r)}else e.setAttribute(n,r)}removeAttribute(e,n,r){if(r){let o=fd[r];o?e.removeAttributeNS(o,n):e.removeAttribute(`${r}:${n}`)}else e.removeAttribute(n)}addClass(e,n){e.classList.add(n)}removeClass(e,n){e.classList.remove(n)}setStyle(e,n,r,o){o&(At.DashCase|At.Important)?e.style.setProperty(n,r,o&At.Important?"important":""):e.style[n]=r}removeStyle(e,n,r){r&At.DashCase?e.style.removeProperty(n):e.style[n]=""}setProperty(e,n,r){e!=null&&(e[n]=r)}setValue(e,n){e.nodeValue=n}listen(e,n,r,o){if(typeof e=="string"&&(e=Zo().getGlobalEventTarget(this.doc,e),!e))throw new R(5102,!1);let i=this.decoratePreventDefault(r);return this.tracingService?.wrapEventListener&&(i=this.tracingService.wrapEventListener(e,n,i)),this.eventManager.addEventListener(e,n,i,o)}decoratePreventDefault(e){return n=>{if(n==="__ngUnwrap__")return e;e(n)===!1&&n.preventDefault()}}};function Tm(t){return t.tagName==="TEMPLATE"&&t.content!==void 0}var hd=class extends ni{sharedStylesHost;hostEl;shadowRoot;constructor(e,n,r,o,i,s,a,c,l){super(e,i,s,c,l),this.sharedStylesHost=n,this.hostEl=r,this.shadowRoot=r.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);let u=o.styles;u=Nm(o.id,u);for(let m of u){let p=document.createElement("style");a&&p.setAttribute("nonce",a),p.textContent=m,this.shadowRoot.appendChild(p)}let f=o.getExternalStyles?.();if(f)for(let m of f){let p=pd(m,i);a&&p.setAttribute("nonce",a),this.shadowRoot.appendChild(p)}}nodeOrShadowRoot(e){return e===this.hostEl?this.shadowRoot:e}appendChild(e,n){return super.appendChild(this.nodeOrShadowRoot(e),n)}insertBefore(e,n,r){return super.insertBefore(this.nodeOrShadowRoot(e),n,r)}removeChild(e,n){return super.removeChild(null,n)}parentNode(e){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(e)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}},ri=class extends ni{sharedStylesHost;removeStylesOnCompDestroy;styles;styleUrls;constructor(e,n,r,o,i,s,a,c,l){super(e,i,s,a,c),this.sharedStylesHost=n,this.removeStylesOnCompDestroy=o;let u=r.styles;this.styles=l?Nm(l,u):u,this.styleUrls=r.getExternalStyles?.(l)}applyStyles(){this.sharedStylesHost.addStyles(this.styles,this.styleUrls)}destroy(){this.removeStylesOnCompDestroy&&Gn.size===0&&this.sharedStylesHost.removeStyles(this.styles,this.styleUrls)}},ya=class extends ri{contentAttr;hostAttr;constructor(e,n,r,o,i,s,a,c,l){let u=o+"-"+r.id;super(e,n,r,i,s,a,c,l,u),this.contentAttr=xD(u),this.hostAttr=ID(u)}applyToHost(e){this.applyStyles(),this.setAttribute(e,this.hostAttr,"")}createElement(e,n){let r=super.createElement(e,n);return super.setAttribute(r,this.contentAttr,""),r}};var ba=class t extends qo{supportsDOMEvents=!0;static makeCurrent(){rd(new t)}onAndCancel(e,n,r,o){return e.addEventListener(n,r,o),()=>{e.removeEventListener(n,r,o)}}dispatchEvent(e,n){e.dispatchEvent(n)}remove(e){e.remove()}createElement(e,n){return n=n||this.getDefaultDocument(),n.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,n){return n==="window"?window:n==="document"?e:n==="body"?e.body:null}getBaseHref(e){let n=MD();return n==null?null:TD(n)}resetBaseElement(){oi=null}getUserAgent(){return window.navigator.userAgent}getCookie(e){return ei(document.cookie,e)}},oi=null;function MD(){return oi=oi||document.head.querySelector("base"),oi?oi.getAttribute("href"):null}function TD(t){return new URL(t,document.baseURI).pathname}var SD=(()=>{class t{build(){return new XMLHttpRequest}static \u0275fac=function(r){return new(r||t)};static \u0275prov=B({token:t,factory:t.\u0275fac})}return t})(),Rm=["alt","control","meta","shift"],ND={"\b":"Backspace"," ":"Tab","\x7F":"Delete","\x1B":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},RD={alt:t=>t.altKey,control:t=>t.ctrlKey,meta:t=>t.metaKey,shift:t=>t.shiftKey},km=(()=>{class t extends ti{constructor(n){super(n)}supports(n){return t.parseEventName(n)!=null}addEventListener(n,r,o,i){let s=t.parseEventName(r),a=t.eventCallback(s.fullKey,o,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Zo().onAndCancel(n,s.domEventName,a,i))}static parseEventName(n){let r=n.toLowerCase().split("."),o=r.shift();if(r.length===0||!(o==="keydown"||o==="keyup"))return null;let i=t._normalizeKey(r.pop()),s="",a=r.indexOf("code");if(a>-1&&(r.splice(a,1),s="code."),Rm.forEach(l=>{let u=r.indexOf(l);u>-1&&(r.splice(u,1),s+=l+".")}),s+=i,r.length!=0||i.length===0)return null;let c={};return c.domEventName=o,c.fullKey=s,c}static matchEventFullKeyCode(n,r){let o=ND[n.key]||n.key,i="";return r.indexOf("code.")>-1&&(o=n.code,i="code."),o==null||!o?!1:(o=o.toLowerCase(),o===" "?o="space":o==="."&&(o="dot"),Rm.forEach(s=>{if(s!==o){let a=RD[s];a(n)&&(i+=s+".")}}),i+=o,i===r)}static eventCallback(n,r,o){return i=>{t.matchEventFullKeyCode(i,n)&&o.runGuarded(()=>r(i))}}static _normalizeKey(n){return n==="esc"?"escape":n}static \u0275fac=function(r){return new(r||t)(Q(Ae))};static \u0275prov=B({token:t,factory:t.\u0275fac})}return t})();function _d(t,e,n){let r=K({rootComponent:t,platformRef:n?.platformRef},kD(e));return sm(r)}function kD(t){return{appProviders:[...LD,...t?.providers??[]],platformProviders:FD}}function AD(){ba.makeCurrent()}function OD(){return new Ke}function PD(){return hu(document),document}var FD=[{provide:Zn,useValue:ud},{provide:Us,useValue:AD,multi:!0},{provide:Ae,useFactory:PD}];var LD=[{provide:po,useValue:"root"},{provide:Ke,useFactory:OD},{provide:_a,useClass:va,multi:!0,deps:[Ae]},{provide:_a,useClass:km,multi:!0,deps:[Ae]},yd,md,gd,{provide:Ot,useExisting:yd},{provide:tr,useClass:SD},[]];var rr=class{},ii=class{},un=class t{headers;normalizedNames=new Map;lazyInit;lazyUpdate=null;constructor(e){e?typeof e=="string"?this.lazyInit=()=>{this.headers=new Map,e.split(`
5
+ `).forEach(n=>{let r=n.indexOf(":");if(r>0){let o=n.slice(0,r),i=n.slice(r+1).trim();this.addHeaderEntry(o,i)}})}:typeof Headers<"u"&&e instanceof Headers?(this.headers=new Map,e.forEach((n,r)=>{this.addHeaderEntry(r,n)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(e).forEach(([n,r])=>{this.setHeaderEntries(n,r)})}:this.headers=new Map}has(e){return this.init(),this.headers.has(e.toLowerCase())}get(e){this.init();let n=this.headers.get(e.toLowerCase());return n&&n.length>0?n[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(e){return this.init(),this.headers.get(e.toLowerCase())||null}append(e,n){return this.clone({name:e,value:n,op:"a"})}set(e,n){return this.clone({name:e,value:n,op:"s"})}delete(e,n){return this.clone({name:e,value:n,op:"d"})}maybeSetNormalizedName(e,n){this.normalizedNames.has(n)||this.normalizedNames.set(n,e)}init(){this.lazyInit&&(this.lazyInit instanceof t?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();for(let[n,r]of e.headers.entries())this.headers.set(n,r),this.normalizedNames.set(n,e.normalizedNames.get(n))}clone(e){let n=new t;return n.lazyInit=this.lazyInit&&this.lazyInit instanceof t?this.lazyInit:this,n.lazyUpdate=(this.lazyUpdate||[]).concat([e]),n}applyUpdate(e){let n=e.name.toLowerCase();switch(e.op){case"a":case"s":let r=e.value;if(typeof r=="string"&&(r=[r]),r.length===0)return;this.maybeSetNormalizedName(e.name,n);let o=e.op==="a"?(this.headers.get(n)||[]).slice():[];o.push(...r),this.headers.set(n,o);break;case"d":let i=e.value;if(i===void 0)this.headers.delete(n),this.normalizedNames.delete(n);else{let s=Array.isArray(i)?i:[i],a=this.headers.get(n);if(!a)return;a=a.filter(c=>s.indexOf(c)===-1),a.length===0?(this.headers.delete(n),this.normalizedNames.delete(n)):this.headers.set(n,a)}break}}addHeaderEntry(e,n){let r=e.toLowerCase();this.maybeSetNormalizedName(e,r),this.headers.has(r)?this.headers.get(r).push(n):this.headers.set(r,[n])}setHeaderEntries(e,n){let r=(Array.isArray(n)?n:[n]).map(i=>i.toString()),o=e.toLowerCase();this.headers.set(o,r),this.maybeSetNormalizedName(e,o)}forEach(e){this.init(),Array.from(this.normalizedNames.keys()).forEach(n=>e(this.normalizedNames.get(n),this.headers.get(n)))}};var Da=class{encodeKey(e){return Am(e)}encodeValue(e){return Am(e)}decodeKey(e){return decodeURIComponent(e)}decodeValue(e){return decodeURIComponent(e)}};function jD(t,e){let n=new Map;return t.length>0&&t.replace(/^\?/,"").split("&").forEach(o=>{let i=o.indexOf("="),[s,a]=i==-1?[e.decodeKey(o),""]:[e.decodeKey(o.slice(0,i)),e.decodeValue(o.slice(i+1))],c=n.get(s)||[];c.push(a),n.set(s,c)}),n}var VD=/%(\d[a-f0-9])/gi,BD={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function Am(t){return encodeURIComponent(t).replace(VD,(e,n)=>BD[n]??e)}function Ca(t){return`${t}`}var Qe=class t{map;encoder;updates=null;cloneFrom=null;constructor(e={}){if(this.encoder=e.encoder||new Da,e.fromString){if(e.fromObject)throw new R(2805,!1);this.map=jD(e.fromString,this.encoder)}else e.fromObject?(this.map=new Map,Object.keys(e.fromObject).forEach(n=>{let r=e.fromObject[n],o=Array.isArray(r)?r.map(Ca):[Ca(r)];this.map.set(n,o)})):this.map=null}has(e){return this.init(),this.map.has(e)}get(e){this.init();let n=this.map.get(e);return n?n[0]:null}getAll(e){return this.init(),this.map.get(e)||null}keys(){return this.init(),Array.from(this.map.keys())}append(e,n){return this.clone({param:e,value:n,op:"a"})}appendAll(e){let n=[];return Object.keys(e).forEach(r=>{let o=e[r];Array.isArray(o)?o.forEach(i=>{n.push({param:r,value:i,op:"a"})}):n.push({param:r,value:o,op:"a"})}),this.clone(n)}set(e,n){return this.clone({param:e,value:n,op:"s"})}delete(e,n){return this.clone({param:e,value:n,op:"d"})}toString(){return this.init(),this.keys().map(e=>{let n=this.encoder.encodeKey(e);return this.map.get(e).map(r=>n+"="+this.encoder.encodeValue(r)).join("&")}).filter(e=>e!=="").join("&")}clone(e){let n=new t({encoder:this.encoder});return n.cloneFrom=this.cloneFrom||this,n.updates=(this.updates||[]).concat(e),n}init(){if(this.map===null&&(this.map=new Map),this.cloneFrom!==null){this.cloneFrom.init();for(let[e,n]of this.cloneFrom.map.entries())this.map.set(e,n);this.updates.forEach(e=>{switch(e.op){case"a":case"s":let n=e.op==="a"?(this.map.get(e.param)||[]).slice():[];n.push(Ca(e.value)),this.map.set(e.param,n);break;case"d":if(e.value!==void 0){let r=(this.map.get(e.param)||[]).slice(),o=r.indexOf(Ca(e.value));o!==-1&&r.splice(o,1),r.length>0?this.map.set(e.param,r):this.map.delete(e.param)}else{this.map.delete(e.param);break}}}),this.cloneFrom=this.updates=null}}};var Ea=class{map=new Map;set(e,n){return this.map.set(e,n),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 HD(t){switch(t){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}function Om(t){return typeof ArrayBuffer<"u"&&t instanceof ArrayBuffer}function Pm(t){return typeof Blob<"u"&&t instanceof Blob}function Fm(t){return typeof FormData<"u"&&t instanceof FormData}function $D(t){return typeof URLSearchParams<"u"&&t instanceof URLSearchParams}var Lm="Content-Type",jm="Accept",Vm="X-Request-URL",Bm="text/plain",Hm="application/json",UD=`${Hm}, ${Bm}, */*`,Br=class t{url;body=null;headers;context;reportProgress=!1;withCredentials=!1;credentials;keepalive=!1;cache;priority;mode;redirect;referrer;integrity;responseType="json";method;params;urlWithParams;transferCache;timeout;constructor(e,n,r,o){this.url=n,this.method=e.toUpperCase();let i;if(HD(this.method)||o?(this.body=r!==void 0?r:null,i=o):i=r,i){if(this.reportProgress=!!i.reportProgress,this.withCredentials=!!i.withCredentials,this.keepalive=!!i.keepalive,i.responseType&&(this.responseType=i.responseType),i.headers&&(this.headers=i.headers),i.context&&(this.context=i.context),i.params&&(this.params=i.params),i.priority&&(this.priority=i.priority),i.cache&&(this.cache=i.cache),i.credentials&&(this.credentials=i.credentials),typeof i.timeout=="number"){if(i.timeout<1||!Number.isInteger(i.timeout))throw new R(2822,"");this.timeout=i.timeout}i.mode&&(this.mode=i.mode),i.redirect&&(this.redirect=i.redirect),i.integrity&&(this.integrity=i.integrity),i.referrer!==void 0&&(this.referrer=i.referrer),this.transferCache=i.transferCache}if(this.headers??=new un,this.context??=new Ea,!this.params)this.params=new Qe,this.urlWithParams=n;else{let s=this.params.toString();if(s.length===0)this.urlWithParams=n;else{let a=n.indexOf("?"),c=a===-1?"?":a<n.length-1?"&":"";this.urlWithParams=n+c+s}}}serializeBody(){return this.body===null?null:typeof this.body=="string"||Om(this.body)||Pm(this.body)||Fm(this.body)||$D(this.body)?this.body:this.body instanceof Qe?this.body.toString():typeof this.body=="object"||typeof this.body=="boolean"||Array.isArray(this.body)?JSON.stringify(this.body):this.body.toString()}detectContentTypeHeader(){return this.body===null||Fm(this.body)?null:Pm(this.body)?this.body.type||null:Om(this.body)?null:typeof this.body=="string"?Bm:this.body instanceof Qe?"application/x-www-form-urlencoded;charset=UTF-8":typeof this.body=="object"||typeof this.body=="number"||typeof this.body=="boolean"?Hm:null}clone(e={}){let n=e.method||this.method,r=e.url||this.url,o=e.responseType||this.responseType,i=e.keepalive??this.keepalive,s=e.priority||this.priority,a=e.cache||this.cache,c=e.mode||this.mode,l=e.redirect||this.redirect,u=e.credentials||this.credentials,f=e.referrer??this.referrer,m=e.integrity||this.integrity,p=e.transferCache??this.transferCache,E=e.timeout??this.timeout,N=e.body!==void 0?e.body:this.body,k=e.withCredentials??this.withCredentials,S=e.reportProgress??this.reportProgress,ve=e.headers||this.headers,ir=e.params||this.params,Fe=e.context??this.context;return e.setHeaders!==void 0&&(ve=Object.keys(e.setHeaders).reduce((dn,fn)=>dn.set(fn,e.setHeaders[fn]),ve)),e.setParams&&(ir=Object.keys(e.setParams).reduce((dn,fn)=>dn.set(fn,e.setParams[fn]),ir)),new t(n,r,N,{params:ir,headers:ve,context:Fe,reportProgress:S,responseType:o,withCredentials:k,transferCache:p,keepalive:i,cache:a,priority:s,timeout:E,mode:c,redirect:l,credentials:u,referrer:f,integrity:m})}},nr=(function(t){return t[t.Sent=0]="Sent",t[t.UploadProgress=1]="UploadProgress",t[t.ResponseHeader=2]="ResponseHeader",t[t.DownloadProgress=3]="DownloadProgress",t[t.Response=4]="Response",t[t.User=5]="User",t})(nr||{}),$r=class{headers;status;statusText;url;ok;type;redirected;constructor(e,n=200,r="OK"){this.headers=e.headers||new un,this.status=e.status!==void 0?e.status:n,this.statusText=e.statusText||r,this.url=e.url||null,this.redirected=e.redirected,this.ok=this.status>=200&&this.status<300}},wa=class t extends $r{constructor(e={}){super(e)}type=nr.ResponseHeader;clone(e={}){return new t({headers:e.headers||this.headers,status:e.status!==void 0?e.status:this.status,statusText:e.statusText||this.statusText,url:e.url||this.url||void 0})}},si=class t extends $r{body;constructor(e={}){super(e),this.body=e.body!==void 0?e.body:null}type=nr.Response;clone(e={}){return new t({body:e.body!==void 0?e.body:this.body,headers:e.headers||this.headers,status:e.status!==void 0?e.status:this.status,statusText:e.statusText||this.statusText,url:e.url||this.url||void 0,redirected:e.redirected??this.redirected})}},Hr=class extends $r{name="HttpErrorResponse";message;error;ok=!1;constructor(e){super(e,0,"Unknown Error"),this.status>=200&&this.status<300?this.message=`Http failure during parsing for ${e.url||"(unknown url)"}`:this.message=`Http failure response for ${e.url||"(unknown url)"}: ${e.status} ${e.statusText}`,this.error=e.error||null}},zD=200,WD=204;function bd(t,e){return{body:e,headers:t.headers,context:t.context,observe:t.observe,params:t.params,reportProgress:t.reportProgress,responseType:t.responseType,withCredentials:t.withCredentials,credentials:t.credentials,transferCache:t.transferCache,timeout:t.timeout,keepalive:t.keepalive,priority:t.priority,cache:t.cache,mode:t.mode,redirect:t.redirect,integrity:t.integrity,referrer:t.referrer}}var Ur=(()=>{class t{handler;constructor(n){this.handler=n}request(n,r,o={}){let i;if(n instanceof Br)i=n;else{let c;o.headers instanceof un?c=o.headers:c=new un(o.headers);let l;o.params&&(o.params instanceof Qe?l=o.params:l=new Qe({fromObject:o.params})),i=new Br(n,r,o.body!==void 0?o.body:null,{headers:c,context:o.context,params:l,reportProgress:o.reportProgress,responseType:o.responseType||"json",withCredentials:o.withCredentials,transferCache:o.transferCache,keepalive:o.keepalive,priority:o.priority,cache:o.cache,mode:o.mode,redirect:o.redirect,credentials:o.credentials,referrer:o.referrer,integrity:o.integrity,timeout:o.timeout})}let s=Se(i).pipe(vc(c=>this.handler.handle(c)));if(n instanceof Br||o.observe==="events")return s;let a=s.pipe(oo(c=>c instanceof si));switch(o.observe||"body"){case"body":switch(i.responseType){case"arraybuffer":return a.pipe(je(c=>{if(c.body!==null&&!(c.body instanceof ArrayBuffer))throw new R(2806,!1);return c.body}));case"blob":return a.pipe(je(c=>{if(c.body!==null&&!(c.body instanceof Blob))throw new R(2807,!1);return c.body}));case"text":return a.pipe(je(c=>{if(c.body!==null&&typeof c.body!="string")throw new R(2808,!1);return c.body}));default:return a.pipe(je(c=>c.body))}case"response":return a;default:throw new R(2809,!1)}}delete(n,r={}){return this.request("DELETE",n,r)}get(n,r={}){return this.request("GET",n,r)}head(n,r={}){return this.request("HEAD",n,r)}jsonp(n,r){return this.request("JSONP",n,{params:new Qe().append(r,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(n,r={}){return this.request("OPTIONS",n,r)}patch(n,r,o={}){return this.request("PATCH",n,bd(o,r))}post(n,r,o={}){return this.request("POST",n,bd(o,r))}put(n,r,o={}){return this.request("PUT",n,bd(o,r))}static \u0275fac=function(r){return new(r||t)(Q(rr))};static \u0275prov=B({token:t,factory:t.\u0275fac})}return t})();var GD=new P("");function qD(t,e){return e(t)}function ZD(t,e,n){return(r,o)=>wr(n,()=>e(r,i=>t(i,o)))}var Dd=new P(""),$m=new P(""),Um=new P("",{providedIn:"root",factory:()=>!0});var xa=(()=>{class t extends rr{backend;injector;chain=null;pendingTasks=_(Nr);contributeToStability=_(Um);constructor(n,r){super(),this.backend=n,this.injector=r}handle(n){if(this.chain===null){let r=this.injector.get(rr,null,{skipSelf:!0}),o=r!==null&&this.backend===r,i=this.injector.get($m,[],o?{self:!0}:void 0),s=Array.from(new Set([...this.injector.get(Dd),...i]));this.chain=s.reduceRight((a,c)=>ZD(a,c,this.injector),qD)}if(this.contributeToStability){let r=this.pendingTasks.add();return this.chain(n,o=>this.backend.handle(o)).pipe(_r(r))}else return this.chain(n,r=>this.backend.handle(r))}static \u0275fac=function(r){return new(r||t)(Q(ii),Q(Ge))};static \u0275prov=B({token:t,factory:t.\u0275fac})}return t})();var YD=/^\)\]\}',?\n/,QD=RegExp(`^${Vm}:`,"m");function KD(t){return"responseURL"in t&&t.responseURL?t.responseURL:QD.test(t.getAllResponseHeaders())?t.getResponseHeader(Vm):null}var Cd=(()=>{class t{xhrFactory;constructor(n){this.xhrFactory=n}handle(n){if(n.method==="JSONP")throw new R(-2800,!1);let r=this.xhrFactory;return Se(null).pipe(ft(()=>new z(i=>{let s=r.build();if(s.open(n.method,n.urlWithParams),n.withCredentials&&(s.withCredentials=!0),n.headers.forEach((k,S)=>s.setRequestHeader(k,S.join(","))),n.headers.has(jm)||s.setRequestHeader(jm,UD),!n.headers.has(Lm)){let k=n.detectContentTypeHeader();k!==null&&s.setRequestHeader(Lm,k)}if(n.timeout&&(s.timeout=n.timeout),n.responseType){let k=n.responseType.toLowerCase();s.responseType=k!=="json"?k:"text"}let a=n.serializeBody(),c=null,l=()=>{if(c!==null)return c;let k=s.statusText||"OK",S=new un(s.getAllResponseHeaders()),ve=KD(s)||n.url;return c=new wa({headers:S,status:s.status,statusText:k,url:ve}),c},u=()=>{let{headers:k,status:S,statusText:ve,url:ir}=l(),Fe=null;S!==WD&&(Fe=typeof s.response>"u"?s.responseText:s.response),S===0&&(S=Fe?zD:0);let dn=S>=200&&S<300;if(n.responseType==="json"&&typeof Fe=="string"){let fn=Fe;Fe=Fe.replace(YD,"");try{Fe=Fe!==""?JSON.parse(Fe):null}catch(gv){Fe=fn,dn&&(dn=!1,Fe={error:gv,text:Fe})}}dn?(i.next(new si({body:Fe,headers:k,status:S,statusText:ve,url:ir||void 0})),i.complete()):i.error(new Hr({error:Fe,headers:k,status:S,statusText:ve,url:ir||void 0}))},f=k=>{let{url:S}=l(),ve=new Hr({error:k,status:s.status||0,statusText:s.statusText||"Unknown Error",url:S||void 0});i.error(ve)},m=f;n.timeout&&(m=k=>{let{url:S}=l(),ve=new Hr({error:new DOMException("Request timed out","TimeoutError"),status:s.status||0,statusText:s.statusText||"Request timeout",url:S||void 0});i.error(ve)});let p=!1,E=k=>{p||(i.next(l()),p=!0);let S={type:nr.DownloadProgress,loaded:k.loaded};k.lengthComputable&&(S.total=k.total),n.responseType==="text"&&s.responseText&&(S.partialText=s.responseText),i.next(S)},N=k=>{let S={type:nr.UploadProgress,loaded:k.loaded};k.lengthComputable&&(S.total=k.total),i.next(S)};return s.addEventListener("load",u),s.addEventListener("error",f),s.addEventListener("timeout",m),s.addEventListener("abort",f),n.reportProgress&&(s.addEventListener("progress",E),a!==null&&s.upload&&s.upload.addEventListener("progress",N)),s.send(a),i.next({type:nr.Sent}),()=>{s.removeEventListener("error",f),s.removeEventListener("abort",f),s.removeEventListener("load",u),s.removeEventListener("timeout",m),n.reportProgress&&(s.removeEventListener("progress",E),a!==null&&s.upload&&s.upload.removeEventListener("progress",N)),s.readyState!==s.DONE&&s.abort()}})))}static \u0275fac=function(r){return new(r||t)(Q(tr))};static \u0275prov=B({token:t,factory:t.\u0275fac})}return t})(),zm=new P(""),XD="XSRF-TOKEN",JD=new P("",{providedIn:"root",factory:()=>XD}),eE="X-XSRF-TOKEN",tE=new P("",{providedIn:"root",factory:()=>eE}),ai=class{},nE=(()=>{class t{doc;cookieName;lastCookieString="";lastToken=null;parseCount=0;constructor(n,r){this.doc=n,this.cookieName=r}getToken(){let n=this.doc.cookie||"";return n!==this.lastCookieString&&(this.parseCount++,this.lastToken=ei(n,this.cookieName),this.lastCookieString=n),this.lastToken}static \u0275fac=function(r){return new(r||t)(Q(Ae),Q(JD))};static \u0275prov=B({token:t,factory:t.\u0275fac})}return t})(),rE=/^(?:https?:)?\/\//i;function oE(t,e){if(!_(zm)||t.method==="GET"||t.method==="HEAD"||rE.test(t.url))return e(t);let n=_(ai).getToken(),r=_(tE);return n!=null&&!t.headers.has(r)&&(t=t.clone({headers:t.headers.set(r,n)})),e(t)}var Ed=(function(t){return t[t.Interceptors=0]="Interceptors",t[t.LegacyInterceptors=1]="LegacyInterceptors",t[t.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",t[t.NoXsrfProtection=3]="NoXsrfProtection",t[t.JsonpSupport=4]="JsonpSupport",t[t.RequestsMadeViaParent=5]="RequestsMadeViaParent",t[t.Fetch=6]="Fetch",t})(Ed||{});function iE(t,e){return{\u0275kind:t,\u0275providers:e}}function wd(...t){let e=[Ur,Cd,xa,{provide:rr,useExisting:xa},{provide:ii,useFactory:()=>_(GD,{optional:!0})??_(Cd)},{provide:Dd,useValue:oE,multi:!0},{provide:zm,useValue:!0},{provide:ai,useClass:nE}];for(let n of t)e.push(...n.\u0275providers);return fo(e)}function xd(t){return iE(Ed.Interceptors,t.map(e=>({provide:Dd,useValue:e,multi:!0})))}var Wm="guitoToken";function Gm(){return new URLSearchParams(window.location.search).get(Wm)??""}var qm=(t,e)=>{let n=Gm();return!n||!t.url.startsWith("/api")?e(t):e(t.clone({setHeaders:{"X-Guito-Token":n}}))};function Zm(t){let e=new URL(t,window.location.origin),n=Gm();return n&&e.searchParams.set(Wm,n),e.toString()}var Ym={providers:[Gu({eventCoalescing:!0}),wd(xd([qm]))]};var Ia=class t{http=_(Ur);cache=new Map;empty=Se(null);get(e){let n=e.trim().toLowerCase();if(!n)return this.empty;let r=this.cache.get(n);if(r&&r.expires>Date.now())return r.image;this.cache.size>=500&&this.cache.delete(this.cache.keys().next().value);let o=this.http.get("/api/avatar",{params:{email:n},responseType:"blob"}).pipe(ft(i=>i.size?new z(s=>{let a=new FileReader;return a.onload=()=>{s.next(String(a.result)),s.complete()},a.onerror=()=>s.error(a.error),a.readAsDataURL(i),()=>{a.readyState===FileReader.LOADING&&a.abort()}}):this.empty),It(()=>this.empty),br({bufferSize:1,refCount:!1}));return this.cache.set(n,{expires:Date.now()+36e5,image:o}),o}static \u0275fac=function(n){return new(n||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})};function sE(t,e){t&1&&ae(0,"img",0),t&2&&ce("src",e,Po)}function aE(t,e){if(t&1&&(w(0,"span",1),y(1),x()),t&2){let n=h();d(),V(n.initials())}}var zr=class t{name=O("");email=O("");avatars=_(Ia);initials(){return this.name().trim().split(/\s+/).slice(0,2).map(e=>e[0]??"").join("").toUpperCase()}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-author-avatar"]],inputs:{name:[1,"name"],email:[1,"email"]},decls:3,vars:3,consts:[["alt","","width","24","height","24",3,"src"],["aria-hidden","true"]],template:function(n,r){if(n&1&&(I(0,sE,1,1,"img",0),er(1,"async"),Bo(2,aE,2,1,"span",1)),n&2){let o;M((o=zu(1,1,r.avatars.get(r.email())))?0:2,o)}},dependencies:[ld],styles:["[_nghost-%COMP%]{display:inline-flex;width:24px;height:24px;flex:0 0 24px;vertical-align:middle;border-radius:50%;overflow:hidden;background:#36516b}img[_ngcontent-%COMP%]{width:100%;height:100%;object-fit:cover}span[_ngcontent-%COMP%]{margin:auto;color:#fff;font-size:10px;line-height:24px}"],changeDetection:0})};var Et="__working__";var Lt=class t{http=_(Ur);base="/api";mutating=b(!1);mutate(e){return gc(()=>this.mutating()?pc(()=>({status:400,error:{error:"Another Git operation is in progress."}})):(this.mutating.set(!0),e().pipe(_r(()=>this.mutating.set(!1)))))}getRepositoryState(){return this.http.get(`${this.base}/repository-state`)}getRepoInfo(){return this.http.get(`${this.base}/repo`)}getCommits(e,n=0){let r=new Qe;return e!==void 0&&(r=r.set("limit",String(e))),n>0&&(r=r.set("skip",String(n))),this.http.get(`${this.base}/commits`,{params:r})}searchCommits(e){let n=new Qe().set("query",e);return this.http.get(`${this.base}/commits/search`,{params:n})}getCommitDetail(e){return this.http.post(`${this.base}/commit/detail`,{hash:e})}getAllBranches(){return this.http.get(`${this.base}/branches/all`)}getCommitDiff(e){return this.http.post(`${this.base}/commit/diff`,{hash:e})}getWorkingChanges(){return this.http.get(`${this.base}/working-changes`)}getFileContent(e,n){return this.http.post(`${this.base}/file-content`,{path:e,ref:n})}fetch(){return this.mutate(()=>this.http.get(`${this.base}/fetch`))}pull(e=!1){return this.mutate(()=>this.http.post(`${this.base}/pull`,{rebase:e}))}push(e=!1){return this.mutate(()=>this.http.post(`${this.base}/push`,{force:e}))}sync(){return this.mutate(()=>this.http.post(`${this.base}/sync`,{}))}checkout(e){return this.mutate(()=>this.http.post(`${this.base}/checkout`,{ref:e}))}revert(e){return this.mutate(()=>this.http.post(`${this.base}/revert`,{commit:e}))}cherryPick(e){return this.mutate(()=>this.http.post(`${this.base}/cherry-pick`,{commit:e}))}dropCommit(e){return this.mutate(()=>this.http.post(`${this.base}/commit/drop`,{commit:e}))}resetToCommit(e,n="hard"){return this.mutate(()=>this.http.post(`${this.base}/reset-commit`,{commit:e,mode:n}))}commit(e,n){return this.mutate(()=>this.http.post(`${this.base}/commit`,{message:e,description:n}))}stage(e){return this.mutate(()=>this.http.post(`${this.base}/stage`,{files:e}))}unstage(e){return this.mutate(()=>this.http.post(`${this.base}/unstage`,{files:e}))}discard(e,n){return this.mutate(()=>this.http.post(`${this.base}/discard`,{files:e,mode:n}))}resetWorking(){return this.mutate(()=>this.http.post(`${this.base}/reset`,{}))}cleanUntracked(){return this.mutate(()=>this.http.post(`${this.base}/clean`,{}))}stashSave(e,n="all"){return this.mutate(()=>this.http.post(`${this.base}/stash/save`,{message:e,scope:n}))}createBranch(e,n){return this.mutate(()=>this.http.post(`${this.base}/branch/create`,{name:e,startPoint:n}))}deleteBranch(e,n=!1){return this.mutate(()=>this.http.post(`${this.base}/branch/delete`,{name:e,force:n}))}deleteRemoteBranch(e,n){return this.mutate(()=>this.http.post(`${this.base}/branch/delete-remote`,{remote:e,branch:n}))}renameBranch(e,n){return this.mutate(()=>this.http.post(`${this.base}/branch/rename`,{oldName:e,newName:n}))}merge(e){return this.mutate(()=>this.http.post(`${this.base}/merge`,{branch:e}))}rebase(e){return this.mutate(()=>this.http.post(`${this.base}/rebase`,{branch:e}))}createTag(e,n){return this.mutate(()=>this.http.post(`${this.base}/tag/create`,{name:e,commit:n}))}deleteTag(e){return this.mutate(()=>this.http.post(`${this.base}/tag/delete`,{name:e}))}pushTag(e,n="origin"){return this.mutate(()=>this.http.post(`${this.base}/tag/push`,{name:e,remote:n}))}getSettings(){return this.http.get(`${this.base}/settings`)}saveSettings(e){return this.http.post(`${this.base}/settings`,{azureDevOpsUrl:e})}createPr(e){return this.mutate(()=>this.http.post(`${this.base}/azure-devops/pullrequest`,e))}searchReviewers(e){return this.http.get(`${this.base}/azure-devops/reviewers`,{params:new Qe().set("query",e)}).pipe(je(n=>n.reviewers))}searchWorkItems(e){return this.http.get(`${this.base}/azure-devops/workitems`,{params:new Qe().set("query",e)}).pipe(je(n=>n.workItems))}getPrTags(){return this.http.get(`${this.base}/azure-devops/tags`).pipe(je(e=>e.tags.map(n=>({name:n}))))}static \u0275fac=function(n){return new(n||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})};var Ma=class t{loading=null;load(){return this.loading||(this.loading=new Promise((e,n)=>{let r=window;if(r.monaco){e(r.monaco);return}let o=document.createElement("script");o.src="vs/loader.js",o.async=!0,o.onload=()=>{let i=r.require;if(!i){n(new Error("Monaco AMD loader not found."));return}i.config({paths:{vs:"vs"}}),i(["vs/editor/editor.main"],()=>{this.applyTheme(r.monaco),e(r.monaco)})},o.onerror=()=>{this.loading=null,n(new Error("Failed to load the Monaco editor."))},document.head.appendChild(o)})),this.loading}applyTheme(e){e.editor.defineTheme("guito",{base:"vs-dark",inherit:!0,rules:[],colors:{"editor.background":"#1e1e1e","editor.foreground":"#cccccc","editorGutter.background":"#1e1e1e","editorLineNumber.foreground":"#5a5a5a","editorLineNumber.activeForeground":"#cccccc","diffEditor.insertedTextBackground":"#89d18526","diffEditor.removedTextBackground":"#f4877126","diffEditor.insertedLineBackground":"#89d1851a","diffEditor.removedLineBackground":"#f487711a","scrollbarSlider.background":"#4a4a4a80","scrollbarSlider.hoverBackground":"#5a5a5a99","editorWidget.background":"#232323","editorWidget.border":"#3c3c3c","editorSuggestWidget.background":"#232323"}})}static \u0275fac=function(n){return new(n||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})};var cE=["host"];function lE(t,e){if(t&1&&(w(0,"span",6),y(1),x()),t&2){let n=h();d(),Z("+",n.file().additions)}}function uE(t,e){if(t&1&&(w(0,"span",7),y(1),x()),t&2){let n=h();d(),Z("\u2212",n.file().deletions)}}function dE(t,e){t&1&&(X(),ae(0,"line",11))}function fE(t,e){t&1&&(X(),ae(0,"line",12))}function pE(t,e){t&1&&(w(0,"div",18),y(1,"Loading diff\u2026"),x())}function hE(t,e){if(t&1&&(w(0,"div",19),y(1),x()),t&2){let n=h();d(),V(n.error())}}function gE(t,e){t&1&&(w(0,"div",18),y(1,"Binary file not shown."),x())}var mE=0,Wr=class t{git=_(Lt);monacoService=_(Ma);file=O.required();originalRef=O.required();modifiedRef=O.required();closed=Y();host=Ut.required("host");loading=b(!0);error=b("");binary=b(!1);sideBySide=b(!0);destroyed=!1;editor=null;models=[];onEscape(){this.closed.emit()}ngAfterViewInit(){return sr(this,null,function*(){this.loading.set(!0),this.error.set(""),this.binary.set(!1);try{let e=yield this.monacoService.load();if(this.destroyed)return;let n=this.file(),r=n.status==="added"&&!n.oldPath?"EMPTY":this.originalRef(),[o,i]=yield Promise.all([Wi(this.git.getFileContent(n.oldPath||n.path,r)),Wi(this.git.getFileContent(n.path,this.modifiedRef()))]);if(this.destroyed)return;if(o.binary||i.binary){this.binary.set(!0),this.loading.set(!1);return}let s=++mE,a=e.editor.createModel(o.content,void 0,e.Uri.parse(`inmemory://diff/${s}/original/${n.oldPath||n.path}`)),c=e.editor.createModel(i.content,void 0,e.Uri.parse(`inmemory://diff/${s}/modified/${n.path}`));this.models=[a,c],this.editor=e.editor.createDiffEditor(this.host().nativeElement,{theme:"guito",readOnly:!0,originalEditable:!1,renderSideBySide:this.sideBySide(),ignoreTrimWhitespace:!1,automaticLayout:!0,fontSize:12,fontFamily:"ui-monospace, 'Cascadia Code', 'SF Mono', Menlo, Consolas, monospace",minimap:{enabled:!1},scrollBeyondLastLine:!1,renderOverviewRuler:!1,hideUnchangedRegions:{enabled:!0,contextLineCount:3},scrollbar:{verticalScrollbarSize:10,horizontalScrollbarSize:10},padding:{top:8}}),this.editor.setModel({original:a,modified:c}),this.loading.set(!1)}catch{this.error.set("Failed to load the diff."),this.loading.set(!1)}})}ngOnDestroy(){this.destroyed=!0,this.editor?.dispose(),this.editor=null;for(let e of this.models)e.dispose();this.models=[]}toggleLayout(){this.sideBySide.update(e=>!e),this.editor?.updateOptions({renderSideBySide:this.sideBySide()})}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-diff-dialog"]],viewQuery:function(n,r){n&1&&Ft(r.host,cE,5),n&2&&$t()},hostBindings:function(n,r){n&1&&T("keydown.escape",function(){return r.onEscape()},qe)},inputs:{file:[1,"file"],originalRef:[1,"originalRef"],modifiedRef:[1,"modifiedRef"]},outputs:{closed:"closed"},decls:25,vars:10,consts:[["host",""],[1,"backdrop",3,"click"],["role","dialog","aria-modal","true",1,"dialog"],[1,"dialog-head"],[1,"path",3,"title"],[1,"counts"],[1,"additions"],[1,"deletions"],["type","button","title","Toggle diff layout",1,"icon-btn",3,"click"],["viewBox","0 0 24 24","aria-hidden","true"],["x","3","y","4","width","18","height","16","rx","2"],["x1","12","y1","4","x2","12","y2","20"],["x1","3","y1","12","x2","21","y2","12"],["type","button","title","Close","aria-label","Close diff",1,"icon-btn",3,"click"],["x1","18","y1","6","x2","6","y2","18"],["x1","6","y1","6","x2","18","y2","18"],[1,"dialog-body"],[1,"editor-host"],[1,"state"],[1,"state","state-error"]],template:function(n,r){if(n&1){let o=$();w(0,"div",1),q("click",function(){return C(o),D(r.closed.emit())}),x(),w(1,"div",2)(2,"header",3)(3,"span"),y(4),x(),w(5,"span",4),y(6),x(),w(7,"span",5),I(8,lE,2,1,"span",6),I(9,uE,2,1,"span",7),x(),w(10,"button",8),q("click",function(){return C(o),D(r.toggleLayout())}),X(),w(11,"svg",9),ae(12,"rect",10),I(13,dE,1,0,":svg:line",11)(14,fE,1,0,":svg:line",12),x()(),xe(),w(15,"button",13),q("click",function(){return C(o),D(r.closed.emit())}),X(),w(16,"svg",9),ae(17,"line",14)(18,"line",15),x()()(),xe(),w(19,"div",16),ae(20,"div",17,0),I(22,pE,2,0,"div",18)(23,hE,2,1,"div",19)(24,gE,2,0,"div",18),x()()}n&2&&(d(3),Jn("status status-"+r.file().status),d(),V(r.file().status),d(),ce("title",r.file().path),d(),V(r.file().path),d(2),M(r.file().additions>0?8:-1),d(),M(r.file().deletions>0?9:-1),d(),ue("aria-label",r.sideBySide()?"Switch to inline view":"Switch to side-by-side view"),d(3),M(r.sideBySide()?13:14),d(9),M(r.loading()?22:r.error()?23:r.binary()?24:-1))},styles:[".backdrop[_ngcontent-%COMP%]{position:fixed;inset:0;background:#0000008c;z-index:200}.dialog[_ngcontent-%COMP%]{position:fixed;top:4vh;left:4vw;right:4vw;bottom:4vh;display:flex;flex-direction:column;background:var(--bg);border:1px solid var(--border);border-radius:8px;box-shadow:0 12px 48px #0009;overflow:hidden;z-index:201}.dialog-head[_ngcontent-%COMP%]{display:flex;align-items:center;gap:10px;flex:none;height:42px;padding:0 10px;background:var(--bg-alt);border-bottom:1px solid var(--border)}.status[_ngcontent-%COMP%]{flex:none;padding:1px 7px;border-radius:3px;font-size:10px;text-transform:uppercase;letter-spacing:.4px}.status-added[_ngcontent-%COMP%]{background:#89d18526;color:#89d185}.status-deleted[_ngcontent-%COMP%]{background:#f4877126;color:#f48771}.status-modified[_ngcontent-%COMP%]{background:#3794ff26;color:#4fc1ff}.status-renamed[_ngcontent-%COMP%]{background:#c586c026;color:#c586c0}.status-binary[_ngcontent-%COMP%]{background:#ffffff14;color:#9d9d9d}.path[_ngcontent-%COMP%]{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:var(--mono);font-size:12px;color:var(--text)}.counts[_ngcontent-%COMP%]{flex:none;display:flex;gap:6px;font-family:var(--mono);font-size:11px}.additions[_ngcontent-%COMP%]{color:#89d185}.deletions[_ngcontent-%COMP%]{color:#f48771}.icon-btn[_ngcontent-%COMP%]{flex:none;width:28px;height:28px;display:inline-flex;align-items:center;justify-content:center;border:none;border-radius:4px;background:transparent;color:var(--text);cursor:pointer}.icon-btn[_ngcontent-%COMP%]:hover{background:var(--bg-hover);color:var(--text-bright)}.icon-btn[_ngcontent-%COMP%] svg[_ngcontent-%COMP%]{width:15px;height:15px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}.dialog-body[_ngcontent-%COMP%]{position:relative;flex:1;min-height:0}.editor-host[_ngcontent-%COMP%]{position:absolute;inset:0}.state[_ngcontent-%COMP%]{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;background:var(--bg);color:var(--text-dim);font-size:13px}.state-error[_ngcontent-%COMP%]{color:var(--red)}"],changeDetection:0})};var vE=(t,e)=>e.path;function yE(t,e){if(t&1&&(g(0,"span",15),y(1,"\u2022"),v(),g(2,"span"),y(3),er(4,"date"),v(),g(5,"span",15),y(6,"\u2022"),v(),g(7,"code",16),y(8),v()),t&2){let n=h();d(3),V(zo(4,2,n.commit().date,"d MMM y HH:mm")),d(5),V(n.commit().hash.slice(0,8))}}function _E(t,e){if(t&1&&(g(0,"pre",10),y(1),v()),t&2){let n=h();d(),V(n.body())}}function bE(t,e){t&1&&(g(0,"div",12),y(1,"Loading changes\u2026"),v())}function CE(t,e){if(t&1&&(g(0,"div",13),y(1),v()),t&2){let n=h();d(),V(n.error())}}function DE(t,e){t&1&&(g(0,"div",12),y(1,"No changes."),v())}function EE(t,e){if(t&1&&(g(0,"span",22),y(1),v()),t&2){let n=h().$implicit;d(),Z("+",n.additions)}}function wE(t,e){if(t&1&&(g(0,"span",23),y(1),v()),t&2){let n=h().$implicit;d(),Z("\u2212",n.deletions)}}function xE(t,e){if(t&1){let n=$();g(0,"button",19),T("click",function(){let o=C(n).$implicit,i=h(3);return D(i.openFile(o))}),g(1,"span"),y(2),v(),g(3,"span",20),y(4),v(),g(5,"span",21),I(6,EE,2,1,"span",22),I(7,wE,2,1,"span",23),v(),X(),g(8,"svg",24),be(9,"polyline",25),v()()}if(t&2){let n=e.$implicit;d(),Jn("file-status status-"+n.status),d(),V(n.status),d(),A("title",n.path),d(),V(n.path),d(2),M(n.additions>0?6:-1),d(),M(n.deletions>0?7:-1)}}function IE(t,e){if(t&1&&(g(0,"div",17),de(1,xE,10,7,"button",18,vE),v()),t&2){let n=h();d(),fe(n.files)}}function ME(t,e){t&1&&I(0,DE,2,0,"div",12)(1,IE,3,0,"div",17),t&2&&M(e.files.length===0?0:1)}function TE(t,e){if(t&1){let n=$();g(0,"app-diff-dialog",26),T("closed",function(){C(n);let o=h();return D(o.dialogFile.set(null))}),v()}if(t&2){let n=h();A("file",e)("originalRef",n.originalRef())("modifiedRef",n.modifiedRef())}}var Ta=class t{git=_(Lt);commit=O.required();closed=Y();diff=b(null);loading=b(!1);error=b("");dialogFile=b(null);body=b("");bodySub=null;workingHash=Et;isWorking=U(()=>this.commit().hash===this.workingHash);originalRef=U(()=>this.isWorking()?"HEAD":`${this.commit().hash}^`);modifiedRef=U(()=>this.isWorking()?"WORKING":this.commit().hash);constructor(){Me(()=>{this.loadDiff(this.commit().hash),this.loadBody(this.commit())})}ngOnDestroy(){this.bodySub?.unsubscribe()}openFile(e){this.dialogFile.set(e)}loadBody(e){if(this.bodySub?.unsubscribe(),this.body.set(""),e.body!==void 0){this.body.set(e.body);return}this.bodySub=this.git.getCommitDetail(e.hash).subscribe({next:n=>this.body.set(n.body??""),error:()=>this.body.set("")})}loadDiff(e){if(this.loading.set(!0),this.error.set(""),this.diff.set(null),this.dialogFile.set(null),e===Et){this.git.getWorkingChanges().subscribe({next:n=>{this.loading.set(!1),this.diff.set({hash:Et,files:n.files})},error:()=>{this.loading.set(!1),this.error.set("Failed to load the working changes.")}});return}this.git.getCommitDiff(e).subscribe({next:n=>{this.loading.set(!1),this.diff.set(n)},error:()=>{this.loading.set(!1),this.error.set("Failed to load the commit diff.")}})}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-commit-detail"]],inputs:{commit:[1,"commit"]},outputs:{closed:"closed"},decls:19,vars:8,consts:[[1,"detail"],[1,"detail-head"],["title","Close",1,"close-btn",3,"click"],["viewBox","0 0 24 24","aria-hidden","true"],["x1","18","y1","6","x2","6","y2","18"],["x1","6","y1","6","x2","18","y2","18"],[1,"subject"],[1,"meta"],[3,"name","email"],[1,"author"],[1,"body"],[1,"detail-body"],[1,"state"],[1,"state","state-error"],[3,"file","originalRef","modifiedRef"],[1,"separator"],[1,"hash"],[1,"file-list"],["type","button",1,"file-row"],["type","button",1,"file-row",3,"click"],[1,"file-path",3,"title"],[1,"file-counts"],[1,"additions"],[1,"deletions"],["viewBox","0 0 24 24","aria-hidden","true",1,"chevron"],["points","9 18 15 12 9 6"],[3,"closed","file","originalRef","modifiedRef"]],template:function(n,r){if(n&1&&(g(0,"aside",0)(1,"header",1)(2,"button",2),T("click",function(){return r.closed.emit()}),X(),g(3,"svg",3),be(4,"line",4)(5,"line",5),v()(),xe(),g(6,"h2",6),y(7),v(),g(8,"div",7),be(9,"app-author-avatar",8),g(10,"span",9),y(11),v(),I(12,yE,9,5),v(),I(13,_E,2,1,"pre",10),v(),g(14,"div",11),I(15,bE,2,0,"div",12)(16,CE,2,1,"div",13)(17,ME,2,1),v()(),I(18,TE,1,3,"app-diff-dialog",14)),n&2){let o,i;d(7),V(r.commit().message),d(2),A("name",r.commit().author_name)("email",r.commit().author_email),d(2),V(r.commit().author_name),d(),M(r.isWorking()?-1:12),d(),M(r.body().trim()?13:-1),d(2),M(r.loading()?15:r.error()?16:(o=r.diff())?17:-1,o),d(3),M((i=r.dialogFile())?18:-1,i)}},dependencies:[zr,Wr,Jo],styles:["[_nghost-%COMP%]{display:flex;flex:none;flex-direction:column;width:480px;min-height:0}.detail[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:100%;height:100%;flex:1;min-height:0;background:var(--bg-alt);border-left:1px solid var(--border)}.file-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;flex:1;min-height:0;padding:6px;gap:2px;overflow-y:auto}.file-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;width:100%;padding:6px 8px;border:none;border-radius:4px;background:transparent;color:var(--text);font-size:12px;font-family:inherit;text-align:left;cursor:pointer}.file-row[_ngcontent-%COMP%]:hover{background:var(--bg-hover)}.chevron[_ngcontent-%COMP%]{flex:none;width:13px;height:13px;fill:none;stroke:var(--text-dim);stroke-width:2;stroke-linecap:round;stroke-linejoin:round}.file-row[_ngcontent-%COMP%]:hover .chevron[_ngcontent-%COMP%]{stroke:var(--accent)}.detail-head[_ngcontent-%COMP%]{flex:none;padding:14px 16px 12px;border-bottom:1px solid var(--border);position:relative}.close-btn[_ngcontent-%COMP%]{position:absolute;top:10px;right:10px;width:26px;height:26px;display:inline-flex;align-items:center;justify-content:center;border:none;border-radius:4px;background:transparent;color:var(--text);cursor:pointer}.close-btn[_ngcontent-%COMP%]:hover{background:var(--bg-hover);color:var(--text-bright)}.close-btn[_ngcontent-%COMP%] svg[_ngcontent-%COMP%]{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round}.subject[_ngcontent-%COMP%]{margin:0 30px 10px 0;font-size:14px;font-weight:600;color:var(--text-bright);word-break:break-word}.meta[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;flex-wrap:wrap;color:var(--text-dim);font-size:12px}.avatar[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:50%;color:#1e1e1e;font-size:10px;font-weight:700}.author[_ngcontent-%COMP%]{color:var(--text)}.hash[_ngcontent-%COMP%]{font-family:var(--mono);color:var(--accent);background:#3794ff1a;padding:1px 6px;border-radius:3px}.body[_ngcontent-%COMP%]{margin:10px 0 0;padding:8px 10px;background:#ffffff0a;border-radius:4px;font-size:12px;font-family:inherit;color:var(--text);white-space:pre-wrap;word-break:break-word;max-height:160px;overflow-y:auto}.detail-body[_ngcontent-%COMP%]{display:flex;flex-direction:column;flex:1;min-height:0;overflow:hidden}.state[_ngcontent-%COMP%]{padding:24px;text-align:center;color:var(--text-dim)}.state-error[_ngcontent-%COMP%]{color:var(--red)}.file-status[_ngcontent-%COMP%]{flex:none;padding:0 6px;border-radius:3px;font-size:10px;text-transform:uppercase;letter-spacing:.4px}.status-added[_ngcontent-%COMP%]{background:#89d18526;color:#89d185}.status-deleted[_ngcontent-%COMP%]{background:#f4877126;color:#f48771}.status-modified[_ngcontent-%COMP%]{background:#3794ff26;color:#4fc1ff}.status-renamed[_ngcontent-%COMP%]{background:#c586c026;color:#c586c0}.status-binary[_ngcontent-%COMP%]{background:#ffffff14;color:#9d9d9d}.file-path[_ngcontent-%COMP%]{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:var(--mono);font-size:12px;color:var(--text)}.file-counts[_ngcontent-%COMP%]{flex:none;font-family:var(--mono);font-size:11px}.additions[_ngcontent-%COMP%]{color:#89d185}.deletions[_ngcontent-%COMP%]{color:#f48771}.binary[_ngcontent-%COMP%]{padding:12px;color:var(--text-dim);font-size:12px}"],changeDetection:0})};function ci(t,e=0){return SE(t)?Number(t):arguments.length===2?e:0}function SE(t){return!isNaN(parseFloat(t))&&!isNaN(Number(t))}function Qm(t){return t instanceof Ct?t.nativeElement:t}var Id;try{Id=typeof Intl<"u"&&Intl.v8BreakIterator}catch{Id=!1}var Sa=(()=>{class t{_platformId=_(Zn);isBrowser=this._platformId?xm(this._platformId):typeof document=="object"&&!!document;EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent);TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent);BLINK=this.isBrowser&&!!(window.chrome||Id)&&typeof CSS<"u"&&!this.EDGE&&!this.TRIDENT;WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT;IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window);FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent);ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT;SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT;constructor(){}static \u0275fac=function(r){return new(r||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var NE=new P("cdk-dir-doc",{providedIn:"root",factory:RE});function RE(){return _(Ae)}var kE=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;function AE(t){let e=t?.toLowerCase()||"";return e==="auto"&&typeof navigator<"u"&&navigator?.language?kE.test(navigator.language)?"rtl":"ltr":e==="rtl"?"rtl":"ltr"}var Km=(()=>{class t{get value(){return this.valueSignal()}valueSignal=b("ltr");change=new _t;constructor(){let n=_(NE,{optional:!0});if(n){let r=n.body?n.body.dir:null,o=n.documentElement?n.documentElement.dir:null;this.valueSignal.set(AE(r||o||"ltr"))}}ngOnDestroy(){this.change.complete()}static \u0275fac=function(r){return new(r||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var wt=(function(t){return t[t.NORMAL=0]="NORMAL",t[t.NEGATED=1]="NEGATED",t[t.INVERTED=2]="INVERTED",t})(wt||{}),Na,or;function Xm(){if(or==null){if(typeof document!="object"||!document||typeof Element!="function"||!Element)return or=!1,or;if(document.documentElement?.style&&"scrollBehavior"in document.documentElement.style)or=!0;else{let t=Element.prototype.scrollTo;t?or=!/\{\s*\[native code\]\s*\}/.test(t.toString()):or=!1}}return or}function Gr(){if(typeof document!="object"||!document)return wt.NORMAL;if(Na==null){let t=document.createElement("div"),e=t.style;t.dir="rtl",e.width="1px",e.overflow="auto",e.visibility="hidden",e.pointerEvents="none",e.position="absolute";let n=document.createElement("div"),r=n.style;r.width="2px",r.height="1px",t.appendChild(n),document.body.appendChild(t),Na=wt.NORMAL,t.scrollLeft===0&&(t.scrollLeft=1,Na=t.scrollLeft===0?wt.NEGATED:wt.INVERTED),t.remove()}return Na}var Ra=class{};function Jm(t){return t&&typeof t.connect=="function"&&!(t instanceof Kr)}var ka=class extends Ra{_data;constructor(e){super(),this._data=e}connect(){return ro(this._data)?this._data:Se(this._data)}disconnect(){}},li=(function(t){return t[t.REPLACED=0]="REPLACED",t[t.INSERTED=1]="INSERTED",t[t.MOVED=2]="MOVED",t[t.REMOVED=3]="REMOVED",t})(li||{}),Md=new P("_ViewRepeater"),Aa=class{viewCacheSize=20;_viewCache=[];applyChanges(e,n,r,o,i){e.forEachOperation((s,a,c)=>{let l,u;if(s.previousIndex==null){let f=()=>r(s,a,c);l=this._insertView(f,c,n,o(s)),u=l?li.INSERTED:li.REPLACED}else c==null?(this._detachAndCacheView(a,n),u=li.REMOVED):(l=this._moveView(a,c,n,o(s)),u=li.MOVED);i&&i({context:l?.context,operation:u,record:s})})}detach(){for(let e of this._viewCache)e.destroy();this._viewCache=[]}_insertView(e,n,r,o){let i=this._insertViewFromCache(n,r);if(i){i.context.$implicit=o;return}let s=e();return r.createEmbeddedView(s.templateRef,s.context,s.index)}_detachAndCacheView(e,n){let r=n.detach(e);this._maybeCacheView(r,n)}_moveView(e,n,r,o){let i=r.get(e);return r.move(i,n),i.context.$implicit=o,i}_maybeCacheView(e,n){if(this._viewCache.length<this.viewCacheSize)this._viewCache.push(e);else{let r=n.indexOf(e);r===-1?e.destroy():n.remove(r)}}_insertViewFromCache(e,n){let r=this._viewCache.pop();return r&&n.insert(r,e),r||null}};var OE=["contentWrapper"],PE=["*"],nv=new P("VIRTUAL_SCROLL_STRATEGY"),Td=class{_scrolledIndexChange=new ye;scrolledIndexChange=this._scrolledIndexChange.pipe(so());_viewport=null;_itemSize;_minBufferPx;_maxBufferPx;constructor(e,n,r){this._itemSize=e,this._minBufferPx=n,this._maxBufferPx=r}attach(e){this._viewport=e,this._updateTotalContentSize(),this._updateRenderedRange()}detach(){this._scrolledIndexChange.complete(),this._viewport=null}updateItemAndBufferSize(e,n,r){r<n,this._itemSize=e,this._minBufferPx=n,this._maxBufferPx=r,this._updateTotalContentSize(),this._updateRenderedRange()}onContentScrolled(){this._updateRenderedRange()}onDataLengthChanged(){this._updateTotalContentSize(),this._updateRenderedRange()}onContentRendered(){}onRenderedOffsetChanged(){}scrollToIndex(e,n){this._viewport&&this._viewport.scrollToOffset(e*this._itemSize,n)}_updateTotalContentSize(){this._viewport&&this._viewport.setTotalContentSize(this._viewport.getDataLength()*this._itemSize)}_updateRenderedRange(){if(!this._viewport)return;let e=this._viewport.getRenderedRange(),n={start:e.start,end:e.end},r=this._viewport.getViewportSize(),o=this._viewport.getDataLength(),i=this._viewport.measureScrollOffset(),s=this._itemSize>0?i/this._itemSize:0;if(n.end>o){let c=Math.ceil(r/this._itemSize),l=Math.max(0,Math.min(s,o-c));s!=l&&(s=l,i=l*this._itemSize,n.start=Math.floor(s)),n.end=Math.max(0,Math.min(o,n.start+c))}let a=i-n.start*this._itemSize;if(a<this._minBufferPx&&n.start!=0){let c=Math.ceil((this._maxBufferPx-a)/this._itemSize);n.start=Math.max(0,n.start-c),n.end=Math.min(o,Math.ceil(s+(r+this._minBufferPx)/this._itemSize))}else{let c=n.end*this._itemSize-(i+r);if(c<this._minBufferPx&&n.end!=o){let l=Math.ceil((this._maxBufferPx-c)/this._itemSize);l>0&&(n.end=Math.min(o,n.end+l),n.start=Math.max(0,Math.floor(s-this._minBufferPx/this._itemSize)))}}this._viewport.setRenderedRange(n),this._viewport.setRenderedContentOffset(Math.round(this._itemSize*n.start)),this._scrolledIndexChange.next(Math.floor(s))}};function FE(t){return t._scrollStrategy}var rv=(()=>{class t{get itemSize(){return this._itemSize}set itemSize(n){this._itemSize=ci(n)}_itemSize=20;get minBufferPx(){return this._minBufferPx}set minBufferPx(n){this._minBufferPx=ci(n)}_minBufferPx=100;get maxBufferPx(){return this._maxBufferPx}set maxBufferPx(n){this._maxBufferPx=ci(n)}_maxBufferPx=200;_scrollStrategy=new Td(this.itemSize,this.minBufferPx,this.maxBufferPx);ngOnChanges(){this._scrollStrategy.updateItemAndBufferSize(this.itemSize,this.minBufferPx,this.maxBufferPx)}static \u0275fac=function(r){return new(r||t)};static \u0275dir=Qn({type:t,selectors:[["cdk-virtual-scroll-viewport","itemSize",""]],inputs:{itemSize:"itemSize",minBufferPx:"minBufferPx",maxBufferPx:"maxBufferPx"},features:[Uo([{provide:nv,useFactory:FE,deps:[Dr(()=>t)]}]),Hs]})}return t})(),LE=20,jE=(()=>{class t{_ngZone=_(ie);_platform=_(Sa);_renderer=_(Ot).createRenderer(null,null);_cleanupGlobalListener;constructor(){}_scrolled=new ye;_scrolledCount=0;scrollContainers=new Map;register(n){this.scrollContainers.has(n)||this.scrollContainers.set(n,n.elementScrolled().subscribe(()=>this._scrolled.next(n)))}deregister(n){let r=this.scrollContainers.get(n);r&&(r.unsubscribe(),this.scrollContainers.delete(n))}scrolled(n=LE){return this._platform.isBrowser?new z(r=>{this._cleanupGlobalListener||(this._cleanupGlobalListener=this._ngZone.runOutsideAngular(()=>this._renderer.listen("document","scroll",()=>this._scrolled.next())));let o=n>0?this._scrolled.pipe(io(n)).subscribe(r):this._scrolled.subscribe(r);return this._scrolledCount++,()=>{o.unsubscribe(),this._scrolledCount--,this._scrolledCount||(this._cleanupGlobalListener?.(),this._cleanupGlobalListener=void 0)}}):Se()}ngOnDestroy(){this._cleanupGlobalListener?.(),this._cleanupGlobalListener=void 0,this.scrollContainers.forEach((n,r)=>this.deregister(r)),this._scrolled.complete()}ancestorScrolled(n,r){let o=this.getAncestorScrollContainers(n);return this.scrolled(r).pipe(oo(i=>!i||o.indexOf(i)>-1))}getAncestorScrollContainers(n){let r=[];return this.scrollContainers.forEach((o,i)=>{this._scrollableContainsElement(i,n)&&r.push(i)}),r}_scrollableContainsElement(n,r){let o=Qm(r),i=n.getElementRef().nativeElement;do if(o==i)return!0;while(o=o.parentElement);return!1}static \u0275fac=function(r){return new(r||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),ov=(()=>{class t{elementRef=_(Ct);scrollDispatcher=_(jE);ngZone=_(ie);dir=_(Km,{optional:!0});_scrollElement=this.elementRef.nativeElement;_destroyed=new ye;_renderer=_(ta);_cleanupScroll;_elementScrolled=new ye;constructor(){}ngOnInit(){this._cleanupScroll=this.ngZone.runOutsideAngular(()=>this._renderer.listen(this._scrollElement,"scroll",n=>this._elementScrolled.next(n))),this.scrollDispatcher.register(this)}ngOnDestroy(){this._cleanupScroll?.(),this._elementScrolled.complete(),this.scrollDispatcher.deregister(this),this._destroyed.next(),this._destroyed.complete()}elementScrolled(){return this._elementScrolled}getElementRef(){return this.elementRef}scrollTo(n){let r=this.elementRef.nativeElement,o=this.dir&&this.dir.value=="rtl";n.left==null&&(n.left=o?n.end:n.start),n.right==null&&(n.right=o?n.start:n.end),n.bottom!=null&&(n.top=r.scrollHeight-r.clientHeight-n.bottom),o&&Gr()!=wt.NORMAL?(n.left!=null&&(n.right=r.scrollWidth-r.clientWidth-n.left),Gr()==wt.INVERTED?n.left=n.right:Gr()==wt.NEGATED&&(n.left=n.right?-n.right:n.right)):n.right!=null&&(n.left=r.scrollWidth-r.clientWidth-n.right),this._applyScrollToOptions(n)}_applyScrollToOptions(n){let r=this.elementRef.nativeElement;Xm()?r.scrollTo(n):(n.top!=null&&(r.scrollTop=n.top),n.left!=null&&(r.scrollLeft=n.left))}measureScrollOffset(n){let r="left",o="right",i=this.elementRef.nativeElement;if(n=="top")return i.scrollTop;if(n=="bottom")return i.scrollHeight-i.clientHeight-i.scrollTop;let s=this.dir&&this.dir.value=="rtl";return n=="start"?n=s?o:r:n=="end"&&(n=s?r:o),s&&Gr()==wt.INVERTED?n==r?i.scrollWidth-i.clientWidth-i.scrollLeft:i.scrollLeft:s&&Gr()==wt.NEGATED?n==r?i.scrollLeft+i.scrollWidth-i.clientWidth:-i.scrollLeft:n==r?i.scrollLeft:i.scrollWidth-i.clientWidth-i.scrollLeft}static \u0275fac=function(r){return new(r||t)};static \u0275dir=Qn({type:t,selectors:[["","cdk-scrollable",""],["","cdkScrollable",""]]})}return t})(),VE=20,BE=(()=>{class t{_platform=_(Sa);_listeners;_viewportSize;_change=new ye;_document=_(Ae);constructor(){let n=_(ie),r=_(Ot).createRenderer(null,null);n.runOutsideAngular(()=>{if(this._platform.isBrowser){let o=i=>this._change.next(i);this._listeners=[r.listen("window","resize",o),r.listen("window","orientationchange",o)]}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){this._listeners?.forEach(n=>n()),this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();let n={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),n}getViewportRect(){let n=this.getViewportScrollPosition(),{width:r,height:o}=this.getViewportSize();return{top:n.top,left:n.left,bottom:n.top+o,right:n.left+r,height:o,width:r}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};let n=this._document,r=this._getWindow(),o=n.documentElement,i=o.getBoundingClientRect(),s=-i.top||n.body.scrollTop||r.scrollY||o.scrollTop||0,a=-i.left||n.body.scrollLeft||r.scrollX||o.scrollLeft||0;return{top:s,left:a}}change(n=VE){return n>0?this._change.pipe(io(n)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){let n=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:n.innerWidth,height:n.innerHeight}:{width:0,height:0}}static \u0275fac=function(r){return new(r||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),ev=new P("VIRTUAL_SCROLLABLE"),HE=(()=>{class t extends ov{constructor(){super()}measureViewportSize(n){let r=this.elementRef.nativeElement;return n==="horizontal"?r.clientWidth:r.clientHeight}static \u0275fac=function(r){return new(r||t)};static \u0275dir=Qn({type:t,features:[jo]})}return t})();function $E(t,e){return t.start==e.start&&t.end==e.end}var UE=typeof requestAnimationFrame<"u"?fc:dc,ui=(()=>{class t extends HE{elementRef=_(Ct);_changeDetectorRef=_(la);_scrollStrategy=_(nv,{optional:!0});scrollable=_(ev,{optional:!0});_platform=_(Sa);_detachedSubject=new ye;_renderedRangeSubject=new ye;get orientation(){return this._orientation}set orientation(n){this._orientation!==n&&(this._orientation=n,this._calculateSpacerSize())}_orientation="vertical";appendOnly=!1;scrolledIndexChange=new z(n=>this._scrollStrategy.scrolledIndexChange.subscribe(r=>Promise.resolve().then(()=>this.ngZone.run(()=>n.next(r)))));_contentWrapper;renderedRangeStream=this._renderedRangeSubject;_totalContentSize=0;_totalContentWidth=b("");_totalContentHeight=b("");_renderedContentTransform;_renderedRange={start:0,end:0};_dataLength=0;_viewportSize=0;_forOf;_renderedContentOffset=0;_renderedContentOffsetNeedsRewrite=!1;_changeDetectionNeeded=b(!1);_runAfterChangeDetection=[];_viewportChanges=me.EMPTY;_injector=_(Ue);_isDestroyed=!1;constructor(){super();let n=_(BE);this._scrollStrategy,this._viewportChanges=n.change().subscribe(()=>{this.checkViewportSize()}),this.scrollable||(this.elementRef.nativeElement.classList.add("cdk-virtual-scrollable"),this.scrollable=this);let r=Me(()=>{this._changeDetectionNeeded()&&this._doChangeDetection()},{injector:_(Kn).injector});_(Oe).onDestroy(()=>{r.destroy()})}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(Gi(null),io(0,UE),Dn(this._destroyed)).subscribe(()=>this._scrollStrategy.onContentScrolled()),this._markChangeDetectionNeeded()})))}ngOnDestroy(){this.detach(),this._scrollStrategy.detach(),this._renderedRangeSubject.complete(),this._detachedSubject.complete(),this._viewportChanges.unsubscribe(),this._isDestroyed=!0,super.ngOnDestroy()}attach(n){this._forOf,this.ngZone.runOutsideAngular(()=>{this._forOf=n,this._forOf.dataStream.pipe(Dn(this._detachedSubject)).subscribe(r=>{let o=r.length;o!==this._dataLength&&(this._dataLength=o,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(n){return this.getElementRef().nativeElement.getBoundingClientRect()[n]}setTotalContentSize(n){this._totalContentSize!==n&&(this._totalContentSize=n,this._calculateSpacerSize(),this._markChangeDetectionNeeded())}setRenderedRange(n){$E(this._renderedRange,n)||(this.appendOnly&&(n={start:0,end:Math.max(this._renderedRange.end,n.end)}),this._renderedRangeSubject.next(this._renderedRange=n),this._markChangeDetectionNeeded(()=>this._scrollStrategy.onContentRendered()))}getOffsetToRenderedContentStart(){return this._renderedContentOffsetNeedsRewrite?null:this._renderedContentOffset}setRenderedContentOffset(n,r="to-start"){n=this.appendOnly&&r==="to-start"?0:n;let o=this.dir&&this.dir.value=="rtl",i=this.orientation=="horizontal",s=i?"X":"Y",c=`translate${s}(${Number((i&&o?-1:1)*n)}px)`;this._renderedContentOffset=n,r==="to-end"&&(c+=` translate${s}(-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(n,r="auto"){let o={behavior:r};this.orientation==="horizontal"?o.start=n:o.top=n,this.scrollable.scrollTo(o)}scrollToIndex(n,r="auto"){this._scrollStrategy.scrollToIndex(n,r)}measureScrollOffset(n){let r;return this.scrollable==this?r=o=>super.measureScrollOffset(o):r=o=>this.scrollable.measureScrollOffset(o),Math.max(0,r(n??(this.orientation==="horizontal"?"start":"top"))-this.measureViewportOffset())}measureViewportOffset(n){let r,o="left",i="right",s=this.dir?.value=="rtl";n=="start"?r=s?i:o:n=="end"?r=s?o:i:n?r=n:r=this.orientation==="horizontal"?"left":"top";let a=this.scrollable.measureBoundingClientRectWithScrollOffset(r);return this.elementRef.nativeElement.getBoundingClientRect()[r]-a}measureRenderedContentSize(){let n=this._contentWrapper.nativeElement;return this.orientation==="horizontal"?n.offsetWidth:n.offsetHeight}measureRangeSize(n){return this._forOf?this._forOf.measureRangeSize(n,this.orientation):0}checkViewportSize(){this._measureViewportSize(),this._scrollStrategy.onDataLengthChanged()}_measureViewportSize(){this._viewportSize=this.scrollable.measureViewportSize(this.orientation)}_markChangeDetectionNeeded(n){n&&this._runAfterChangeDetection.push(n),!ke(this._changeDetectionNeeded)&&this.ngZone.runOutsideAngular(()=>{Promise.resolve().then(()=>{this.ngZone.run(()=>{this._changeDetectionNeeded.set(!0)})})})}_doChangeDetection(){this._isDestroyed||this.ngZone.run(()=>{this._changeDetectorRef.markForCheck(),this._contentWrapper.nativeElement.style.transform=this._renderedContentTransform,xu(()=>{this._changeDetectionNeeded.set(!1);let n=this._runAfterChangeDetection;this._runAfterChangeDetection=[];for(let r of n)r()},{injector:this._injector})})}_calculateSpacerSize(){this._totalContentHeight.set(this.orientation==="horizontal"?"":`${this._totalContentSize}px`),this._totalContentWidth.set(this.orientation==="horizontal"?`${this._totalContentSize}px`:"")}static \u0275fac=function(r){return new(r||t)};static \u0275cmp=se({type:t,selectors:[["cdk-virtual-scroll-viewport"]],viewQuery:function(r,o){if(r&1&&Hu(OE,7),r&2){let i;$u(i=Uu())&&(o._contentWrapper=i.first)}},hostAttrs:[1,"cdk-virtual-scroll-viewport"],hostVars:4,hostBindings:function(r,o){r&2&&Pe("cdk-virtual-scroll-orientation-horizontal",o.orientation==="horizontal")("cdk-virtual-scroll-orientation-vertical",o.orientation!=="horizontal")},inputs:{orientation:"orientation",appendOnly:[2,"appendOnly","appendOnly",am]},outputs:{scrolledIndexChange:"scrolledIndexChange"},features:[Uo([{provide:ov,useFactory:(n,r)=>n||r,deps:[[new du,new uu(ev)],t]}]),jo],ngContentSelectors:PE,decls:4,vars:4,consts:[["contentWrapper",""],[1,"cdk-virtual-scroll-content-wrapper"],[1,"cdk-virtual-scroll-spacer"]],template:function(r,o){r&1&&(Vu(),w(0,"div",1,0),Bu(2),x(),ae(3,"div",2)),r&2&&(d(3),re("width",o._totalContentWidth())("height",o._totalContentHeight()))},styles:[`cdk-virtual-scroll-viewport{display:block;position:relative;transform:translateZ(0)}.cdk-virtual-scrollable{overflow:auto;will-change:scroll-position;contain:strict}.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}
6
+ `],encapsulation:2,changeDetection:0})}return t})();function tv(t,e,n){let r=n;if(!r.getBoundingClientRect)return 0;let o=r.getBoundingClientRect();return t==="horizontal"?e==="start"?o.left:o.right:e==="start"?o.top:o.bottom}var iv=(()=>{class t{_viewContainerRef=_(Yn);_template=_(an);_differs=_(ua);_viewRepeater=_(Md);_viewport=_(ui,{skipSelf:!0});viewChange=new ye;_dataSourceChanges=new ye;get cdkVirtualForOf(){return this._cdkVirtualForOf}set cdkVirtualForOf(n){this._cdkVirtualForOf=n,Jm(n)?this._dataSourceChanges.next(n):this._dataSourceChanges.next(new ka(ro(n)?n:Array.from(n||[])))}_cdkVirtualForOf;get cdkVirtualForTrackBy(){return this._cdkVirtualForTrackBy}set cdkVirtualForTrackBy(n){this._needsUpdate=!0,this._cdkVirtualForTrackBy=n?(r,o)=>n(r+(this._renderedRange?this._renderedRange.start:0),o):void 0}_cdkVirtualForTrackBy;set cdkVirtualForTemplate(n){n&&(this._needsUpdate=!0,this._template=n)}get cdkVirtualForTemplateCacheSize(){return this._viewRepeater.viewCacheSize}set cdkVirtualForTemplateCacheSize(n){this._viewRepeater.viewCacheSize=ci(n)}dataStream=this._dataSourceChanges.pipe(Gi(null),_c(),ft(([n,r])=>this._changeDataSource(n,r)),br(1));_differ=null;_data;_renderedItems;_renderedRange;_needsUpdate=!1;_destroyed=new ye;constructor(){let n=_(ie);this.dataStream.subscribe(r=>{this._data=r,this._onRenderedDataChange()}),this._viewport.renderedRangeStream.pipe(Dn(this._destroyed)).subscribe(r=>{this._renderedRange=r,this.viewChange.observers.length&&n.run(()=>this.viewChange.next(this._renderedRange)),this._onRenderedDataChange()}),this._viewport.attach(this)}measureRangeSize(n,r){if(n.start>=n.end)return 0;n.start<this._renderedRange.start||n.end>this._renderedRange.end;let o=n.start-this._renderedRange.start,i=n.end-n.start,s,a;for(let c=0;c<i;c++){let l=this._viewContainerRef.get(c+o);if(l&&l.rootNodes.length){s=a=l.rootNodes[0];break}}for(let c=i-1;c>-1;c--){let l=this._viewContainerRef.get(c+o);if(l&&l.rootNodes.length){a=l.rootNodes[l.rootNodes.length-1];break}}return s&&a?tv(r,"end",a)-tv(r,"start",s):0}ngDoCheck(){if(this._differ&&this._needsUpdate){let n=this._differ.diff(this._renderedItems);n?this._applyChanges(n):this._updateContext(),this._needsUpdate=!1}}ngOnDestroy(){this._viewport.detach(),this._dataSourceChanges.next(void 0),this._dataSourceChanges.complete(),this.viewChange.complete(),this._destroyed.next(),this._destroyed.complete(),this._viewRepeater.detach()}_onRenderedDataChange(){this._renderedRange&&(this._renderedItems=this._data.slice(this._renderedRange.start,this._renderedRange.end),this._differ||(this._differ=this._differs.find(this._renderedItems).create((n,r)=>this.cdkVirtualForTrackBy?this.cdkVirtualForTrackBy(n,r):r)),this._needsUpdate=!0)}_changeDataSource(n,r){return n&&n.disconnect(this),this._needsUpdate=!0,r?r.connect(this):Se()}_updateContext(){let n=this._data.length,r=this._viewContainerRef.length;for(;r--;){let o=this._viewContainerRef.get(r);o.context.index=this._renderedRange.start+r,o.context.count=n,this._updateComputedContextProperties(o.context),o.detectChanges()}}_applyChanges(n){this._viewRepeater.applyChanges(n,this._viewContainerRef,(i,s,a)=>this._getEmbeddedViewArgs(i,a),i=>i.item),n.forEachIdentityChange(i=>{let s=this._viewContainerRef.get(i.currentIndex);s.context.$implicit=i.item});let r=this._data.length,o=this._viewContainerRef.length;for(;o--;){let i=this._viewContainerRef.get(o);i.context.index=this._renderedRange.start+o,i.context.count=r,this._updateComputedContextProperties(i.context)}}_updateComputedContextProperties(n){n.first=n.index===0,n.last=n.index===n.count-1,n.even=n.index%2===0,n.odd=!n.even}_getEmbeddedViewArgs(n,r){return{templateRef:this._template,context:{$implicit:n.item,cdkVirtualForOf:this._cdkVirtualForOf,index:-1,count:-1,first:!1,last:!1,odd:!1,even:!1},index:r}}static ngTemplateContextGuard(n,r){return!0}static \u0275fac=function(r){return new(r||t)};static \u0275dir=Qn({type:t,selectors:[["","cdkVirtualFor","","cdkVirtualForOf",""]],inputs:{cdkVirtualForOf:"cdkVirtualForOf",cdkVirtualForTrackBy:"cdkVirtualForTrackBy",cdkVirtualForTemplate:"cdkVirtualForTemplate",cdkVirtualForTemplateCacheSize:"cdkVirtualForTemplateCacheSize"},features:[Uo([{provide:Md,useClass:Aa}])]})}return t})();function Oa(t){let e=[],n=new Int32Array(t.length),r=o=>{let i=e.indexOf(o);return i===-1&&(i=e.indexOf(null),i===-1&&(e.push(null),i=e.length-1),e[i]=o),i};for(let o=0;o<t.length;o++){let{hash:i,parents:s}=t[o],a=e.map((l,u)=>l===i?u:-1).filter(l=>l!==-1),c;if(a.length>0){c=a[0];for(let l=1;l<a.length;l++)e[a[l]]=null}else c=r(i);e[c]=s[0]??null;for(let l=1;l<s.length;l++)r(s[l]);n[o]=c}return n}var sv=["#3794ff","#4ec9b0","#d7ba7d","#c586c0","#89d185","#ce9178","#d16969","#569cd6","#b5cea8","#dcdcaa"];function Sd(t){return sv[Math.abs(t)%sv.length]}var zE=2e3,Pa=class t{worker=null;workerBroken=!1;nextId=0;pending=new Map;compute(e){return e.length<=zE?Se(Oa(e)):new z(n=>{let r=this.ensureWorker();if(!r){n.next(Oa(e)),n.complete();return}let o=++this.nextId;this.pending.set(o,{rows:e,subscriber:n});let i=setTimeout(()=>this.fallback(),15e3);try{r.postMessage({id:o,hashes:e.map(s=>s.hash),parents:e.map(s=>[...s.parents])})}catch{this.fallback()}return()=>{clearTimeout(i),this.pending.delete(o)}})}fallback(){this.workerBroken=!0,this.worker?.terminate(),this.worker=null;for(let[e,n]of this.pending)this.pending.delete(e),n.subscriber.next(Oa(n.rows)),n.subscriber.complete()}ensureWorker(){if(this.worker)return this.worker;if(this.workerBroken||typeof Worker>"u")return null;try{return this.worker=new Worker(new URL("worker-O4G7QTZ6.js",import.meta.url),{type:"module"}),this.worker.onmessage=e=>{let n=this.pending.get(e.data.id);if(n){if(!(e.data.lanes instanceof Int32Array)||e.data.lanes.length!==n.rows.length){this.fallback();return}n.subscriber.next(e.data.lanes),n.subscriber.complete()}},this.worker.onerror=()=>this.fallback(),this.worker.onmessageerror=()=>this.fallback(),this.worker}catch{return this.fallback(),null}}ngOnDestroy(){this.worker?.terminate();for(let e of this.pending.values())e.subscriber.complete();this.pending.clear()}static \u0275fac=function(n){return new(n||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})};function av(t){return t?t.split(",").map(e=>e.trim()).filter(Boolean).map(e=>e.startsWith("HEAD -> ")?{type:"head",name:e.slice(8)}:e==="HEAD"?{type:"head",name:"HEAD"}:e.startsWith("tag: ")?{type:"tag",name:e.slice(5)}:e.includes("/")?{type:"remote",name:e}:{type:"local",name:e}):[]}function Nd(t){let e=t.refs;return e?e==="HEAD"||e.startsWith("HEAD,")||e.startsWith("HEAD ->"):!1}function Fa(t,e){if(typeof localStorage>"u")return e;try{let n=localStorage.getItem(t);return n===null?e:JSON.parse(n)}catch{return e}}function La(t,e){if(!(typeof localStorage>"u"))try{localStorage.setItem(t,JSON.stringify(e))}catch{}}var WE=(t,e)=>e.hash,GE=(t,e)=>e.name;function qE(t,e){if(t&1&&(g(0,"span",38),y(1),v()),t&2){let n=h();d(),Z("",n.staged.length," staged")}}function ZE(t,e){if(t&1&&(g(0,"span",39),y(1),v()),t&2){let n=h();d(),Z("",n.unstaged.length," unstaged")}}function YE(t,e){if(t&1&&(g(0,"span",40),y(1),v()),t&2){let n=h();d(),Z("",n.untracked.length," untracked")}}function QE(t,e){if(t&1&&(I(0,qE,2,1,"span",38),I(1,ZE,2,1,"span",39),I(2,YE,2,1,"span",40)),t&2){let n=e;M(n.staged.length>0?0:-1),d(),M(n.unstaged.length>0?1:-1),d(),M(n.untracked.length>0?2:-1)}}function KE(t,e){if(t&1){let n=$();g(0,"div",21),T("click",function(){C(n);let o=h();return D(o.commitClick.emit(o.workingCommit()))})("contextmenu",function(o){C(n);let i=h();return D(i.onWorkingContextMenu(o))}),g(1,"div",22),X(),g(2,"svg",23),be(3,"path",24)(4,"path",25),v()(),xe(),g(5,"div",26)(6,"span",27),X(),g(7,"svg",28),be(8,"circle",29)(9,"path",30)(10,"path",31)(11,"path",32)(12,"path",33),v(),xe(),g(13,"span",34),y(14,"Uncommitted changes"),v()(),I(15,QE,3,3),v(),g(16,"div",35),y(17,"\u2014"),v(),g(18,"div",36),y(19),v(),g(20,"div",37),y(21,"\u2014"),v()()}if(t&2){let n,r=h();re("width",r.tableWidth(),"px")("transform",r.horizontalTransform()),Pe("selected",r.selectedHash()===r.workingHash),d(),re("width",r.graphColumnWidth(),"px"),d(4),re("width",r.descriptionWidth(),"px"),d(10),M((n=r.workingChanges())?15:-1,n),d(),re("width",r.columnWidths().date,"px"),d(2),re("width",r.columnWidths().author,"px"),d(),V(r.identity().name||"You"),d(),re("width",r.columnWidths().commit,"px")}}function XE(t,e){if(t&1&&(g(0,"div",12),be(1,"span",41),y(2),v()),t&2){let n=h();d(2),V(n.pendingLabel())}}function JE(t,e){if(t&1&&(X(),be(0,"path",16)),t&2){let n=e.$implicit;ue("d",n.d)("stroke",n.color)}}function ew(t,e){if(t&1&&(X(),be(0,"circle",42)),t&2){let n=h().$implicit;ue("cx",n.x)("cy",n.y)("stroke",n.color)}}function tw(t,e){if(t&1&&(X(),be(0,"circle",43)),t&2){let n=h().$implicit;ue("cx",n.x)("cy",n.y)("fill",n.color)}}function nw(t,e){if(t&1&&I(0,ew,1,3,":svg:circle",42)(1,tw,1,3,":svg:circle",43),t&2){let n=e.$implicit;M(n.isHead?0:1)}}function rw(t,e){t&1&&(X(),g(0,"svg",28),be(1,"line",51)(2,"circle",52)(3,"circle",53)(4,"path",54),v())}function ow(t,e){t&1&&(X(),g(0,"svg",28),be(1,"path",55)(2,"line",56),v())}function iw(t,e){if(t&1){let n=$();g(0,"span",50),T("contextmenu",function(o){let i=C(n).$implicit,s=h().$implicit,a=h();return D(a.onBadgeContextMenu(o,s.commit,i))}),I(1,rw,5,0,":svg:svg",28)(2,ow,3,0,":svg:svg",28),g(3,"span",34),y(4),v()()}if(t&2){let n=e.$implicit;Jn("badge badge-"+n.type),d(),M(n.type==="head"||n.type==="local"?1:n.type==="tag"?2:-1),d(3),V(n.name)}}function sw(t,e){if(t&1&&(g(0,"mark",57),y(1),v()),t&2){let n=h().$implicit;d(),V(n.text)}}function aw(t,e){if(t&1&&y(0),t&2){let n=h().$implicit;Z(" ",n.text," ")}}function cw(t,e){if(t&1&&I(0,sw,2,1,"mark",57)(1,aw,1,1),t&2){let n=e.$implicit;M(n.match?0:1)}}function lw(t,e){if(t&1&&(g(0,"mark",57),y(1),v()),t&2){let n=h().$implicit;d(),V(n.text)}}function uw(t,e){if(t&1&&y(0),t&2){let n=h().$implicit;Z(" ",n.text," ")}}function dw(t,e){if(t&1&&I(0,lw,2,1,"mark",57)(1,uw,1,1),t&2){let n=e.$implicit;M(n.match?0:1)}}function fw(t,e){if(t&1){let n=$();g(0,"div",44),T("click",function(){let o=C(n).$implicit,i=h();return D(i.commitClick.emit(o.commit))})("contextmenu",function(o){let i=C(n).$implicit,s=h();return D(s.onRowContextMenu(o,i.commit))}),be(1,"div",22),g(2,"div",26),de(3,iw,5,4,"span",45,GE),g(5,"span",46),de(6,cw,2,1,null,null,Xn),v()(),g(8,"div",35),y(9),er(10,"date"),v(),g(11,"div",47),be(12,"app-author-avatar",48),de(13,dw,2,1,null,null,Xn),v(),g(15,"div",49),y(16),v()()}if(t&2){let n=e.$implicit,r=h();re("width",r.tableWidth(),"px"),Pe("selected",n.commit.hash===r.selectedHash()),d(),re("width",r.graphColumnWidth(),"px"),d(),re("width",r.descriptionWidth(),"px"),d(),fe(r.badges(n.commit)),d(2),Pe("head",r.isHead(n.commit)),d(),fe(r.highlight(n.commit.message)),d(2),re("width",r.columnWidths().date,"px"),d(),Z(" ",zo(10,22,n.commit.date,"d MMM y HH:mm")," "),d(2),re("width",r.columnWidths().author,"px"),A("title",n.commit.author_name),d(),A("name",n.commit.author_name)("email",n.commit.author_email),d(),fe(r.highlight(n.commit.author_name)),d(2),re("width",r.columnWidths().commit,"px"),A("title",n.commit.hash),d(),Z(" ",n.commit.hash.slice(0,8)," ")}}function pw(t,e){if(t&1&&(g(0,"div",19),y(1),v()),t&2){let n=h();d(),V(n.search().trim()?"No matching commits":"No commits to show")}}function hw(t,e){if(t&1){let n=$();g(0,"div",20)(1,"button",58),T("click",function(){C(n);let o=h();return D(o.onLoadMoreCommits())}),y(2,"Load more commits"),v(),g(3,"button",58),T("click",function(){C(n);let o=h();return D(o.onLoadAllCommits())}),y(4),v()()}if(t&2){let n=h();d(4),Z("Load all (",n.unloaded(),")")}}var lt=34,Rd=14,cv=10,gw=72,lv=10,dv="guito.columnWidths",uv={graph:0,description:480,date:132,author:150,commit:84},mw={graph:0,description:48,date:48,author:48,commit:48};function vw(){let t=Fa(dv,{}),e=K({},uv);for(let n of Object.keys(uv)){let r=t[n];typeof r=="number"&&Number.isFinite(r)&&r>=mw[n]&&(e[n]=r)}return e}var ja=class t{commits=O.required();selectedHash=O.required();identity=O({name:"",email:""});search=O("");selectedBranch=O("");showRemote=O(!0);workingChanges=O(null);unloaded=O(0);historyLoading=O(!1);loadingLabel=O("");scrollToHash=O(null);graphLoading=b(!1);pendingLabel=U(()=>this.loadingLabel()||(this.graphLoading()?"Drawing commit graph...":""));commitClick=Y();contextMenu=Y();loadMoreRequested=Y();loadAllRequested=Y();rowHeight=lt;graph=_(Pa);viewport=Ut(ui);zone=_(ie);scrollTop=b(0);scrollLeft=b(0);viewportWidth=b(0);viewportHeight=b(0);constructor(){Me(()=>{let e=this.commits();this.updateGraph(e)}),nd(()=>{this.graphCommits(),this.columnWidths();let e=this.viewport();e&&ke(()=>{e.checkViewportSize(),this.measureViewport()})}),nd(()=>{this.selectedBranch(),this.showRemote();let e=this.viewport();e&&ke(()=>{e.scrollToOffset(0),this.measureViewport()})}),Me(()=>{let e=this.scrollToHash();if(!e)return;let n=this.graphCommits().findIndex(o=>o.commit.hash===e.hash);if(n===-1)return;let r=this.viewport();r&&ke(()=>this.scrollToIndex(r,n))}),Me(e=>{let n=this.viewport();if(!n)return;let r=new ResizeObserver(()=>{this.zone.run(()=>{n.checkViewportSize(),this.measureViewport()})});r.observe(n.elementRef.nativeElement);let o=n.elementScrolled().subscribe(()=>{this.zone.run(()=>this.measureViewport())});e(()=>{r.disconnect(),o.unsubscribe()})}),Me(()=>{this.viewportWidth(),this.graphCommits(),ke(()=>{let e=this.viewportWidth()-this.graphColumnWidth()-this.columnWidths().date-this.columnWidths().author-this.columnWidths().commit-this.columnWidths().description;this.fillerWidth.set(Math.max(0,e))})})}measureViewport(){let e=this.viewport()?.elementRef.nativeElement;e&&(this.scrollTop.set(e.scrollTop),this.scrollLeft.set(e.scrollLeft),this.viewportWidth.set(e.clientWidth),this.viewportHeight.set(e.clientHeight))}scrollToIndex(e,n){let r=e.elementRef.nativeElement,o=r.clientHeight||this.viewportHeight(),i=Math.max(0,n*lt-(o-lt)/2),s=0,a=()=>{e.scrollToOffset(i),this.measureViewport(),Math.abs(r.scrollTop-i)>1&&++s<10&&requestAnimationFrame(a)};a()}columnWidths=b(vw());graphCommits=b([]);graphSubscription=null;updateGraph(e){this.graphSubscription?.unsubscribe(),this.graphLoading.set(!0),this.graphSubscription=this.graph.compute(e).subscribe(n=>{n.length===e.length&&(this.graphLoading.set(!1),this.graphCommits.set(e.map((r,o)=>({commit:r,lane:n[o],parents:r.parents??[]}))))})}graphWidth=U(()=>{let e=this.graphCommits().reduce((n,r)=>Math.max(n,r.lane),0)+1;return Math.max(gw,cv*2+e*Rd)});graphColumnWidth=U(()=>Math.max(this.graphWidth(),this.columnWidths().graph));fillerWidth=b(0);descriptionWidth=U(()=>this.columnWidths().description+this.fillerWidth());tableWidth=U(()=>this.graphColumnWidth()+this.columnWidths().date+this.columnWidths().author+this.columnWidths().commit+this.descriptionWidth());horizontalTransform=U(()=>"translateX("+-this.scrollLeft()+"px)");graphHeight=U(()=>this.graphCommits().length*lt);allEdges=U(()=>{let e=this.graphCommits(),n=new Map,r=new Map;e.forEach((i,s)=>{n.set(i.commit.hash,s),r.set(i.commit.hash,i.lane)});let o=[];for(let i=0;i<e.length;i++){let s=e[i];for(let a of s.parents){let c=n.get(a);o.push({childRow:i,childLane:s.lane,parentRow:c??-1,parentLane:c===void 0?s.lane:r.get(a)??s.lane})}}return o});visibleRange=U(()=>{let e=this.graphCommits().length;if(e===0||this.viewportHeight()===0)return{start:0,end:0};let n=Math.max(0,Math.floor(this.scrollTop()/lt)-lv),r=Math.min(e,Math.ceil((this.scrollTop()+this.viewportHeight())/lt)+lv);return{start:n,end:r}});nodes=U(()=>{let{start:e,end:n}=this.visibleRange(),r=[];for(let o=e;o<n;o++){let i=this.graphCommits()[o];r.push({hash:i.commit.hash,x:this.laneX(i.lane),y:o*lt+lt/2,color:Sd(i.lane),isHead:Nd(i.commit)})}return r});edges=U(()=>{let e=this.allEdges(),{start:n,end:r}=this.visibleRange(),o=this.graphHeight(),i=[];for(let s of e){let a=s.parentRow,c=Math.min(s.childRow,a<0?s.childRow:a);if((a<0?Number.MAX_SAFE_INTEGER:Math.max(s.childRow,a))<n||c>=r)continue;let u=Sd(s.childLane),f=this.laneX(s.childLane),m=s.childRow*lt+lt/2;if(a<0){i.push({d:`M ${f} ${m} L ${f} ${o}`,color:u});continue}let p=this.laneX(s.parentLane),E=a*lt+lt/2;if(f===p)i.push({d:`M ${f} ${m} L ${p} ${E}`,color:u});else{let N=(m+E)/2;i.push({d:`M ${f} ${m} C ${f} ${N} ${p} ${N} ${p} ${E}`,color:u})}}return i});hasWorkingChanges=U(()=>{let e=this.workingChanges();return!!e&&e.staged.length+e.unstaged.length+e.untracked.length+e.conflicted.length>0});workingHash=Et;workingCommit=U(()=>({hash:Et,date:new Date().toISOString(),message:"Uncommitted changes",refs:"",body:"",author_name:this.identity().name||"You",author_email:this.identity().email,parents:[]}));resizeState=null;startResize(e,n){if(n.preventDefault(),n.stopPropagation(),e==="graph")this.resizeState={column:e,startX:n.clientX,startWidth:this.graphColumnWidth()};else if(e==="description"){let r=this.descriptionWidth();this.columnWidths.update(o=>le(K({},o),{description:r})),this.fillerWidth.set(0),this.resizeState={column:e,startX:n.clientX,startWidth:r}}else this.resizeState={column:e,startX:n.clientX,startWidth:this.columnWidths()[e]};document.addEventListener("mousemove",this.onResizeMove),document.addEventListener("mouseup",this.onResizeEnd)}onResizeMove=e=>{let n=this.resizeState;if(!n)return;let r=e.clientX-n.startX,o=n.column==="graph"?this.graphWidth():48,i=Math.max(o,n.startWidth+r);this.columnWidths.update(s=>le(K({},s),{[n.column]:i}))};onResizeEnd=()=>{this.resizeState&&La(dv,this.columnWidths()),this.resizeState=null,document.removeEventListener("mousemove",this.onResizeMove),document.removeEventListener("mouseup",this.onResizeEnd)};ngOnDestroy(){this.onResizeEnd(),this.graphSubscription?.unsubscribe()}onRowContextMenu(e,n){e.preventDefault(),e.stopPropagation(),this.contextMenu.emit({x:e.clientX,y:e.clientY,target:{kind:"commit",commit:n}})}onBadgeContextMenu(e,n,r){e.preventDefault(),e.stopPropagation(),this.contextMenu.emit({x:e.clientX,y:e.clientY,target:{kind:r.type==="tag"?"tag":"branch",commit:n,branch:r}})}onWorkingContextMenu(e){e.preventDefault(),e.stopPropagation(),this.contextMenu.emit({x:e.clientX,y:e.clientY,target:{kind:"working"}})}highlight(e){let n=this.search().trim().toLowerCase();if(!n||!e)return[{text:e,match:!1}];let r=[],o=e.toLowerCase(),i=0,s=o.indexOf(n);for(;s!==-1;)s>i&&r.push({text:e.slice(i,s),match:!1}),r.push({text:e.slice(s,s+n.length),match:!0}),i=s+n.length,s=o.indexOf(n,i);return i<e.length&&r.push({text:e.slice(i),match:!1}),r.length>0?r:[{text:e,match:!1}]}onLoadMoreCommits(){this.loadMoreRequested.emit()}onLoadAllCommits(){this.loadAllRequested.emit()}trackByHash(e,n){return n.commit.hash}badges(e){let n=this.selectedBranch(),r=this.showRemote();return av(e.refs).filter(o=>o.type==="remote"&&!r?!1:!n||o.type==="tag"?!0:o.name===n)}isHead(e){return Nd(e)}laneX(e){return cv+Rd/2+e*Rd}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-commit-table"]],viewQuery:function(n,r){n&1&&Ft(r.viewport,ui,5),n&2&&$t()},inputs:{commits:[1,"commits"],selectedHash:[1,"selectedHash"],identity:[1,"identity"],search:[1,"search"],selectedBranch:[1,"selectedBranch"],showRemote:[1,"showRemote"],workingChanges:[1,"workingChanges"],unloaded:[1,"unloaded"],historyLoading:[1,"historyLoading"],loadingLabel:[1,"loadingLabel"],scrollToHash:[1,"scrollToHash"]},outputs:{commitClick:"commitClick",contextMenu:"contextMenu",loadMoreRequested:"loadMoreRequested",loadAllRequested:"loadAllRequested"},decls:38,vars:30,consts:[[1,"table"],[1,"pinned-clip"],[1,"table-head"],[1,"head-cell","cell-graph"],[1,"head-label"],[1,"resizer",3,"mousedown"],[1,"head-cell","cell-desc"],[1,"head-cell","cell-date"],[1,"head-cell","cell-author"],[1,"head-cell","cell-commit"],[1,"row","working-row",3,"width","transform","selected"],[1,"table-body"],["role","status",1,"table-loading"],[1,"list-container"],[1,"graph-clip"],["aria-hidden","true",1,"graph-overlay"],["fill","none","stroke-width","2"],[1,"list-viewport",3,"itemSize"],["class","row",3,"width","selected","click","contextmenu",4,"cdkVirtualFor","cdkVirtualForOf","cdkVirtualForTrackBy"],[1,"empty"],[1,"load-actions"],[1,"row","working-row",3,"click","contextmenu"],[1,"cell","cell-graph"],["viewBox","0 0 24 24","aria-hidden","true",1,"working-icon"],["d","M12 20h9"],["d","M16.5 3.5a2.121 2.121 0 0 1 3 3L7 19l-4 1 1-4L16.5 3.5z"],[1,"cell","cell-desc"],[1,"badge","badge-working"],["viewBox","0 0 24 24","aria-hidden","true",1,"badge-icon"],["cx","12","cy","12","r","3"],["d","M12 2v3"],["d","M12 19v3"],["d","M2 12h3"],["d","M19 12h3"],[1,"badge-name"],[1,"cell","cell-date"],[1,"cell","cell-author"],[1,"cell","cell-commit"],[1,"count-badge","count-staged"],[1,"count-badge","count-unstaged"],[1,"count-badge","count-untracked"],[1,"spinner"],["r","5.5","fill","#1e1e1e","stroke-width","2"],["r","4"],[1,"row",3,"click","contextmenu"],[3,"class"],[1,"message"],[1,"cell","cell-author",3,"title"],[3,"name","email"],[1,"cell","cell-commit",3,"title"],[3,"contextmenu"],["x1","6","y1","3","x2","6","y2","15"],["cx","18","cy","6","r","3"],["cx","6","cy","18","r","3"],["d","M18 9a9 9 0 0 1-9 9"],["d","M20.59 13.41l-7.17 7.17a2 2 0 0 1-2.83 0L2 12V2h10l8.59 8.59a2 2 0 0 1 0 2.83z"],["x1","7","y1","7","x2","7.01","y2","7"],[1,"hl"],[1,"load-more",3,"click"]],template:function(n,r){n&1&&(g(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"span",4),y(5,"Graph"),v(),g(6,"div",5),T("mousedown",function(i){return r.startResize("graph",i)}),v()(),g(7,"div",6)(8,"span",4),y(9,"Description"),v(),g(10,"div",5),T("mousedown",function(i){return r.startResize("description",i)}),v()(),g(11,"div",7)(12,"span",4),y(13,"Date"),v(),g(14,"div",5),T("mousedown",function(i){return r.startResize("date",i)}),v()(),g(15,"div",8)(16,"span",4),y(17,"Author"),v(),g(18,"div",5),T("mousedown",function(i){return r.startResize("author",i)}),v()(),g(19,"div",9)(20,"span",4),y(21,"Commit"),v(),g(22,"div",5),T("mousedown",function(i){return r.startResize("commit",i)}),v()()(),I(23,KE,22,18,"div",10),v(),g(24,"div",11),I(25,XE,3,1,"div",12),g(26,"div",13)(27,"div",14),X(),g(28,"svg",15)(29,"g"),de(30,JE,1,2,":svg:path",16,Xn),de(32,nw,2,1,null,null,WE),v()()(),xe(),g(34,"cdk-virtual-scroll-viewport",17),ra(35,fw,17,25,"div",18),v(),I(36,pw,2,1,"div",19),v(),I(37,hw,5,1,"div",20),v()()),n&2&&(ue("aria-busy",!!r.pendingLabel()),d(),re("width",r.viewportWidth(),"px"),d(),re("width",r.tableWidth(),"px")("transform",r.horizontalTransform()),d(),re("width",r.graphColumnWidth(),"px"),d(4),re("width",r.descriptionWidth(),"px"),d(4),re("width",r.columnWidths().date,"px"),d(4),re("width",r.columnWidths().author,"px"),d(4),re("width",r.columnWidths().commit,"px"),d(4),M(r.hasWorkingChanges()?23:-1),d(2),M(r.pendingLabel()?25:-1),d(2),re("width",r.viewportWidth(),"px"),d(),re("transform",r.horizontalTransform()),ue("width",r.graphWidth()),d(),ue("transform","translate(0 "+-r.scrollTop()+")"),d(),fe(r.edges()),d(2),fe(r.nodes()),d(2),A("itemSize",r.rowHeight),d(),A("cdkVirtualForOf",r.graphCommits())("cdkVirtualForTrackBy",r.trackByHash),d(),M(!r.pendingLabel()&&r.graphCommits().length===0?36:-1),d(),M(r.unloaded()>0&&!r.historyLoading()?37:-1))},dependencies:[zr,rv,iv,ui,Jo],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;flex:1;min-width:0;min-height:0}.table[_ngcontent-%COMP%]{display:flex;flex-direction:column;flex:1;width:100%;min-width:0;min-height:0}.table-head[_ngcontent-%COMP%]{display:flex;align-items:center;height:30px;flex:none;border-bottom:1px solid var(--border);background:var(--bg-alt);font-size:12px;font-weight:600;color:var(--text-bright);-webkit-user-select:none;user-select:none}.head-cell[_ngcontent-%COMP%]{position:relative;padding:0 10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:none}.head-cell.cell-desc[_ngcontent-%COMP%]{flex:none;min-width:0}.resizer[_ngcontent-%COMP%]{position:absolute;top:0;right:0;width:6px;height:100%;cursor:col-resize;z-index:1}.resizer[_ngcontent-%COMP%]:hover, .resizer.active[_ngcontent-%COMP%]{background:var(--accent)}.table-body[_ngcontent-%COMP%]{display:flex;flex-direction:column;flex:1;min-height:0}.list-container[_ngcontent-%COMP%]{position:relative;flex:1;min-height:0}.list-viewport[_ngcontent-%COMP%]{position:absolute;inset:0;width:100%;height:100%}.graph-overlay[_ngcontent-%COMP%]{position:absolute;top:0;left:0;height:100%;pointer-events:none}.row[_ngcontent-%COMP%]{display:flex;align-items:center;height:34px;flex:none;cursor:pointer;-webkit-user-select:none;user-select:none}.row[_ngcontent-%COMP%]:hover{background:var(--bg-hover)}.row.selected[_ngcontent-%COMP%]{background:#04395e}.cell[_ngcontent-%COMP%]{padding:0 10px;overflow:hidden;white-space:nowrap;color:var(--text);min-width:0}.cell-graph[_ngcontent-%COMP%]{flex:none}.cell-desc[_ngcontent-%COMP%]{flex:none;display:flex;align-items:center;gap:6px}.cell-date[_ngcontent-%COMP%]{flex:none;text-align:right;color:var(--text-dim)}.cell-author[_ngcontent-%COMP%]{flex:none;text-align:right;text-overflow:ellipsis}.cell-commit[_ngcontent-%COMP%]{flex:none;text-align:right;font-family:var(--mono);color:var(--text-dim)}.working-row[_ngcontent-%COMP%]{flex:none;border-bottom:1px solid var(--border);background:#d7ba7d0a}.working-row[_ngcontent-%COMP%]:hover{background:#d7ba7d14}.working-row.selected[_ngcontent-%COMP%]{background:#4d3a12}.working-icon[_ngcontent-%COMP%]{width:14px;height:14px;margin-left:4px;fill:none;stroke:#d7ba7d;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}.badge-working[_ngcontent-%COMP%]{background:#d7ba7d24;color:#d7ba7d;border-color:#d7ba7d66}.count-badge[_ngcontent-%COMP%]{flex:none;padding:1px 7px;border-radius:10px;font-size:11px;line-height:16px;white-space:nowrap}.count-staged[_ngcontent-%COMP%]{background:#89d18524;color:#89d185}.count-unstaged[_ngcontent-%COMP%]{background:#f4877124;color:#f48771}.count-untracked[_ngcontent-%COMP%]{background:#3794ff24;color:#4fc1ff}.hl[_ngcontent-%COMP%]{background:#613214;color:#f5c04a;border-radius:2px;padding:0 1px}.message[_ngcontent-%COMP%]{overflow:hidden;text-overflow:ellipsis;font-weight:400}.message.head[_ngcontent-%COMP%]{font-weight:600;color:var(--text-bright)}.badge[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:4px;flex:none;padding:1px 7px;border-radius:10px;border:1px solid transparent;font-size:11px;line-height:16px;white-space:nowrap}.badge-head[_ngcontent-%COMP%]{background:#0078d4;color:#fff}.badge-local[_ngcontent-%COMP%]{background:#3794ff24;color:#4fc1ff;border-color:#3794ff66}.badge-remote[_ngcontent-%COMP%]{background:#ffffff0f;color:#b8b8b8;border-color:#4a4a4a}.badge-tag[_ngcontent-%COMP%]{background:#d7ba7d1f;color:#d7ba7d;border-color:#d7ba7d66}.badge-icon[_ngcontent-%COMP%]{width:10px;height:10px;fill:none;stroke:currentColor;stroke-width:2.5;stroke-linecap:round;stroke-linejoin:round}.badge-name[_ngcontent-%COMP%]{max-width:160px;overflow:hidden;text-overflow:ellipsis}.empty[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;height:240px;color:var(--text-dim)}.load-more[_ngcontent-%COMP%]{display:block;width:100%;padding:10px;background:transparent;border:none;border-top:1px solid var(--border);color:var(--accent);cursor:pointer;font-size:12px;font-family:inherit}.load-more[_ngcontent-%COMP%]:hover{background:var(--bg-hover)}.load-actions[_ngcontent-%COMP%]{display:flex;border-top:1px solid var(--border)}.load-actions[_ngcontent-%COMP%] .load-more[_ngcontent-%COMP%]{border-top:none}.load-actions[_ngcontent-%COMP%] .load-more[_ngcontent-%COMP%] + .load-more[_ngcontent-%COMP%]{border-left:1px solid var(--border)}.history-loading[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;padding:10px;border-top:1px solid var(--border);color:var(--text-dim);font-size:12px}.pinned-clip[_ngcontent-%COMP%]{overflow:hidden;flex:none;max-width:100%}.table-body[_ngcontent-%COMP%]{position:relative}.graph-clip[_ngcontent-%COMP%]{position:absolute;inset:0 auto 0 0;overflow:hidden;pointer-events:none;z-index:1}.table-head[_ngcontent-%COMP%], .row[_ngcontent-%COMP%]{box-sizing:border-box}.head-cell.cell-desc[_ngcontent-%COMP%], .cell-desc[_ngcontent-%COMP%]{min-width:280px}.empty[_ngcontent-%COMP%]{position:absolute;inset:0;display:grid;place-items:center;pointer-events:none}.table-loading[_ngcontent-%COMP%]{position:absolute;top:8px;left:50%;transform:translate(-50%);z-index:3;display:flex;align-items:center;gap:8px;padding:8px 12px;border:1px solid var(--border);border-radius:4px;background:var(--bg-alt);color:var(--text);font-size:12px;white-space:nowrap}.spinner[_ngcontent-%COMP%]{width:14px;height:14px;border:2px solid var(--border);border-top-color:var(--accent);border-radius:50%;animation:_ngcontent-%COMP%_spin .8s linear infinite}@keyframes _ngcontent-%COMP%_spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){.spinner[_ngcontent-%COMP%]{animation:none}}.cell-author[_ngcontent-%COMP%] app-author-avatar[_ngcontent-%COMP%]{margin-right:6px}"],changeDetection:0})};function yw(t,e){t&1&&ae(0,"div",2)}function _w(t,e){if(t&1){let n=$();w(0,"button",4),q("click",function(){C(n);let o=h().$implicit,i=h(2);return D(i.onSelect(o))}),y(1),x()}if(t&2){let n=h().$implicit;Pe("danger",n.danger),ce("disabled",n.disabled),d(),Z(" ",n.label," ")}}function bw(t,e){if(t&1&&I(0,yw,1,0,"div",2)(1,_w,2,4,"button",3),t&2){let n=e.$implicit;M(n.separator?0:1)}}function Cw(t,e){if(t&1){let n=$();w(0,"div",0),q("click",function(){C(n);let o=h();return D(o.closed.emit())})("contextmenu",function(o){C(n);let i=h();return o.preventDefault(),D(i.closed.emit())}),x(),w(1,"div",1),de(2,bw,2,1,null,null,Xn),x()}if(t&2){let n=h();d(),re("left",n.left(),"px")("top",n.top(),"px"),d(),fe(e.items)}}var Va=class t{menu=O.required();select=Y();closed=Y();left=U(()=>{let e=this.menu();return e?Math.max(4,Math.min(e.x,window.innerWidth-250)):0});top=U(()=>{let e=this.menu();if(!e)return 0;let n=e.items.length*30+12;return Math.max(4,Math.min(e.y,window.innerHeight-n-8))});onEscape(){this.menu()&&this.closed.emit()}onSelect(e){e.disabled||!e.action||(this.select.emit(e.action),this.closed.emit())}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-context-menu"]],hostBindings:function(n,r){n&1&&T("keydown.escape",function(){return r.onEscape()},qe)},inputs:{menu:[1,"menu"]},outputs:{select:"select",closed:"closed"},decls:1,vars:1,consts:[[1,"backdrop",3,"click","contextmenu"],["role","menu",1,"menu"],[1,"separator"],["role","menuitem",1,"item",3,"danger","disabled"],["role","menuitem",1,"item",3,"click","disabled"]],template:function(n,r){if(n&1&&I(0,Cw,4,4),n&2){let o;M((o=r.menu())?0:-1,o)}},styles:[".backdrop[_ngcontent-%COMP%]{position:fixed;inset:0;z-index:300}.menu[_ngcontent-%COMP%]{position:fixed;min-width:210px;max-width:300px;padding:4px;display:flex;flex-direction:column;background:var(--bg-alt);border:1px solid var(--border);border-radius:6px;box-shadow:0 6px 24px #0000008c;z-index:301}.item[_ngcontent-%COMP%]{display:block;width:100%;padding:6px 10px;border:none;border-radius:4px;background:transparent;color:var(--text);font-size:12px;font-family:inherit;text-align:left;cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.item[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--bg-hover);color:var(--text-bright)}.item[_ngcontent-%COMP%]:disabled{color:var(--text-dim);opacity:.55;cursor:default}.item.danger[_ngcontent-%COMP%]{color:var(--red)}.item.danger[_ngcontent-%COMP%]:hover:not(:disabled){background:#f487711f;color:#f48771}.separator[_ngcontent-%COMP%]{height:1px;margin:4px 6px;background:var(--border);flex:none}"],changeDetection:0})};function di(t){t||(t=_(Oe));let e=new z(n=>{if(t.destroyed){n.next();return}return t.onDestroy(n.next.bind(n))});return n=>n.pipe(Dn(e))}function Ba(t,e){let n=e?.injector??_(Ue),r=new bn(1),o=Me(()=>{let i;try{i=t()}catch(s){ke(()=>r.error(s));return}ke(()=>r.next(i))},{injector:n,manualCleanup:!0});return n.get(Oe).onDestroy(()=>{o.destroy(),r.complete()}),r.asObservable()}var fv=(t,e)=>e.id;function Dw(t,e){if(t&1){let n=$();w(0,"span",2)(1,"span",6),y(2),x(),w(3,"button",7),q("click",function(){let o=C(n).$implicit,i=h();return D(i.remove.emit(o))}),y(4," \xD7 "),x()()}if(t&2){let n=e.$implicit,r=h();d(),ce("title",n.description??n.label),d(),V(n.label),d(),ce("disabled",r.disabled()),ue("aria-label","Remove "+n.label)}}function Ew(t,e){if(t&1&&(w(0,"p",4),y(1),x()),t&2){let n=h();d(),V(n.error())}}function ww(t,e){t&1&&(w(0,"li",8),y(1,"Searching..."),x())}function xw(t,e){t&1&&(w(0,"li",8),y(1,"No matches"),x())}function Iw(t,e){if(t&1&&(w(0,"span",12),y(1),x()),t&2){let n=h().$implicit;d(),V(n.description)}}function Mw(t,e){if(t&1){let n=$();w(0,"li",10),q("mousedown",function(o){let i=C(n).$implicit,s=h(2);return D(s.onSuggestionMouseDown(o,i))}),w(1,"span",11),y(2),x(),I(3,Iw,2,1,"span",12),x()}if(t&2){let n=e.$implicit,r=e.$index,o=h(2);Pe("active",r===o.highlight()),ue("aria-selected",r===o.highlight()),d(2),V(n.label),d(),M(n.description?3:-1)}}function Tw(t,e){if(t&1&&(w(0,"ul",5),I(1,ww,2,0,"li",8),I(2,xw,2,0,"li",8),de(3,Mw,4,5,"li",9,fv),x()),t&2){let n=h();d(),M(n.loading()?1:-1),d(),M(!n.loading()&&!n.error()&&!n.suggestions().length?2:-1),d(),fe(n.suggestions())}}var Ha=class t{placeholder=O("");chips=O([]);suggestions=O([]);loading=O(!1);query=O("");disabled=O(!1);allowFreeText=O(!1);error=O("");queryChange=Y();select=Y();remove=Y();open=b(!1);highlight=b(0);onInput(e){this.queryChange.emit(e.target.value),this.open.set(!0),this.highlight.set(0)}onKeydown(e){let n=this.suggestions();if(e.key==="ArrowDown"&&n.length)e.preventDefault(),this.highlight.update(r=>Math.min(r+1,n.length-1));else if(e.key==="ArrowUp"&&n.length)e.preventDefault(),this.highlight.update(r=>Math.max(r-1,0));else if(e.key==="Enter"){e.preventDefault();let r=n[this.highlight()];if(r){this.pick(r);return}let o=this.query().trim();this.allowFreeText()&&o&&(this.open.set(!1),this.select.emit({id:o.toLowerCase(),label:o}))}else e.key==="Escape"&&this.open()&&(e.stopPropagation(),this.open.set(!1))}pick(e){this.open.set(!1),this.select.emit(e)}onSuggestionMouseDown(e,n){e.preventDefault(),this.pick(n)}onBlur(){setTimeout(()=>this.open.set(!1),120)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-chip-input"]],inputs:{placeholder:[1,"placeholder"],chips:[1,"chips"],suggestions:[1,"suggestions"],loading:[1,"loading"],query:[1,"query"],disabled:[1,"disabled"],allowFreeText:[1,"allowFreeText"],error:[1,"error"]},outputs:{queryChange:"queryChange",select:"select",remove:"remove"},decls:7,vars:5,consts:[[1,"chip-input"],[1,"chip-row"],[1,"chip"],["type","text",1,"chip-query",3,"input","keydown","focus","blur","value","disabled"],["role","alert",1,"lookup-error"],["role","listbox",1,"suggestions"],[1,"chip-label",3,"title"],["type","button",1,"chip-remove",3,"click","disabled"],[1,"suggestion-hint"],["role","option",3,"active"],["role","option",3,"mousedown"],[1,"suggestion-label"],[1,"suggestion-desc"]],template:function(n,r){n&1&&(w(0,"div",0)(1,"div",1),de(2,Dw,5,4,"span",2,fv),w(4,"input",3),q("input",function(i){return r.onInput(i)})("keydown",function(i){return r.onKeydown(i)})("focus",function(){return r.open.set(!0)})("blur",function(){return r.onBlur()}),x()(),I(5,Ew,2,1,"p",4),I(6,Tw,5,2,"ul",5),x()),n&2&&(d(2),fe(r.chips()),d(2),ce("value",r.query())("disabled",r.disabled()),ue("placeholder",r.chips().length?"":r.placeholder()),d(),M(r.error()?5:-1),d(),M(r.open()&&(r.loading()||r.suggestions().length>0||r.query().trim())?6:-1))},styles:[".chip-input[_ngcontent-%COMP%]{position:relative}.chip-row[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:4px;align-items:center;padding:4px 6px;border:1px solid var(--border);border-radius:4px;background:var(--bg)}.chip-row[_ngcontent-%COMP%]:focus-within{border-color:var(--accent)}.chip[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:2px;padding:2px 4px 2px 8px;border-radius:3px;background:var(--bg-hover);font-size:12px;color:var(--text);max-width:100%}.chip-label[_ngcontent-%COMP%]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.chip-remove[_ngcontent-%COMP%]{border:none;background:transparent;color:var(--text-dim);font-size:13px;line-height:1;cursor:pointer;padding:2px 4px}.chip-remove[_ngcontent-%COMP%]:hover:not(:disabled){color:#f48771}.chip-query[_ngcontent-%COMP%]{flex:1;min-width:90px;border:none;background:transparent;color:var(--text);font-size:12px;font-family:inherit;outline:none;padding:2px}.suggestions[_ngcontent-%COMP%]{position:absolute;top:100%;left:0;right:0;z-index:20;margin:4px 0 0;padding:4px 0;list-style:none;background:var(--bg-alt);border:1px solid var(--border);border-radius:4px;box-shadow:0 6px 18px #00000080;max-height:200px;overflow-y:auto}.suggestions[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2px;padding:6px 10px;font-size:12px;cursor:pointer}.suggestions[_ngcontent-%COMP%] li[_ngcontent-%COMP%]:hover, .suggestions[_ngcontent-%COMP%] li.active[_ngcontent-%COMP%]{background:var(--bg-hover)}.suggestion-hint[_ngcontent-%COMP%]{color:var(--text-dim);cursor:default}.suggestion-label[_ngcontent-%COMP%]{color:var(--text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.suggestion-desc[_ngcontent-%COMP%]{color:var(--text-dim);font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.lookup-error[_ngcontent-%COMP%]{color:var(--danger, #f48771);font-size:12px;margin:4px 0}"],changeDetection:0})};var kd=(t,e)=>e.name;function Sw(t,e){if(t&1&&(g(0,"a",10),y(1," Open in Azure DevOps "),v()),t&2){let n=h();A("href",n.url,Po)}}function Nw(t,e){if(t&1&&(g(0,"p",14),y(1),v()),t&2){let n=e.$implicit;d(),V(n)}}function Rw(t,e){if(t&1&&de(0,Nw,2,1,"p",14,Ho),t&2){let n=h();fe(n.warnings)}}function kw(t,e){if(t&1){let n=$();g(0,"div",8)(1,"p",9),y(2),v(),I(3,Sw,2,1,"a",10),g(4,"p",11),y(5),v(),I(6,Rw,2,0),v(),g(7,"div",12)(8,"button",13),T("click",function(){C(n);let o=h();return D(o.closed.emit())}),y(9,"Close"),v()()}if(t&2){let n=e;d(2),Z("\u2714 Pull Request #",n.id," created"),d(),M(n.url?3:-1),d(2),Z("Source branch: ",n.branch),d(),M(n.warnings!=null&&n.warnings.length?6:-1)}}function Aw(t,e){if(t&1&&(g(0,"option",22),y(1),v()),t&2){let n=e.$implicit,r=h(2);A("value",n.name)("selected",r.source()===n.name),d(),Z(" ",n.name," ")}}function Ow(t,e){if(t&1&&(g(0,"option",22),y(1),v()),t&2){let n=e.$implicit,r=h(2);A("value",n.name)("selected",r.source()===n.name),d(),Z(" ",n.name," ")}}function Pw(t,e){t&1&&(g(0,"p",11),y(1," A new branch (pr/xxxxxx) will be created from the current HEAD and pushed before the pull request is created. "),v())}function Fw(t,e){if(t&1&&(g(0,"option",22),y(1),v()),t&2){let n=e.$implicit,r=h(2);A("value",n.name)("selected",r.target()===n.name),d(),Z(" ",n.name," ")}}function Lw(t,e){if(t&1&&(g(0,"p",11),y(1),v()),t&2){let n=h(2);d(),Z('Press Enter to add "',n.tagQuery().trim(),'" as a new tag.')}}function jw(t,e){if(t&1&&(g(0,"p",30),y(1),v()),t&2){let n=h(2);d(),V(n.error())}}function Vw(t,e){if(t&1){let n=$();g(0,"div",15)(1,"label",16)(2,"span",17),y(3,"Title"),v(),g(4,"input",18),T("input",function(o){C(n);let i=h();return D(i.onTitleInput(o))}),v()(),g(5,"label",16)(6,"span",17),y(7,"Description"),v(),g(8,"textarea",19),T("input",function(o){C(n);let i=h();return D(i.onDescriptionInput(o))}),v()(),g(9,"label",16)(10,"span",17),y(11,"Source branch"),v(),g(12,"select",20),T("change",function(o){C(n);let i=h();return D(i.onSourceChange(o))}),g(13,"optgroup",21)(14,"option",22),y(15," \u2795 Create new branch (random name) "),v()(),g(16,"optgroup",23),de(17,Aw,2,3,"option",22,kd),v(),g(19,"optgroup",24),de(20,Ow,2,3,"option",22,kd),v()()(),I(22,Pw,2,0,"p",11),g(23,"label",16)(24,"span",17),y(25,"Target branch"),v(),g(26,"select",20),T("change",function(o){C(n);let i=h();return D(i.onTargetChange(o))}),de(27,Fw,2,3,"option",22,kd),v()(),g(29,"label",25)(30,"input",26),T("change",function(o){C(n);let i=h();return D(i.isDraft.set(o.target.checked))}),v(),y(31," Create as draft "),v(),g(32,"label",16)(33,"span",17),y(34,"Required reviewers"),v(),g(35,"app-chip-input",27),T("queryChange",function(o){C(n);let i=h();return D(i.requiredReviewerQuery.set(o))})("select",function(o){C(n);let i=h();return D(i.addRequiredReviewer(o))})("remove",function(o){C(n);let i=h();return D(i.removeRequiredReviewer(o))}),v()(),g(36,"label",16)(37,"span",17),y(38,"Optional reviewers"),v(),g(39,"app-chip-input",27),T("queryChange",function(o){C(n);let i=h();return D(i.optionalReviewerQuery.set(o))})("select",function(o){C(n);let i=h();return D(i.addOptionalReviewer(o))})("remove",function(o){C(n);let i=h();return D(i.removeOptionalReviewer(o))}),v()(),g(40,"label",16)(41,"span",17),y(42,"Work items"),v(),g(43,"app-chip-input",28),T("queryChange",function(o){C(n);let i=h();return D(i.workItemQuery.set(o))})("select",function(o){C(n);let i=h();return D(i.addWorkItem(o))})("remove",function(o){C(n);let i=h();return D(i.removeWorkItem(o))}),v()(),g(44,"label",16)(45,"span",17),y(46,"Tags"),v(),g(47,"app-chip-input",29),T("queryChange",function(o){C(n);let i=h();return D(i.tagQuery.set(o))})("select",function(o){C(n);let i=h();return D(i.addTag(o))})("remove",function(o){C(n);let i=h();return D(i.removeTag(o))}),v()(),I(48,Lw,2,1,"p",11),I(49,jw,2,1,"p",30),v(),g(50,"div",12)(51,"button",31),T("click",function(){C(n);let o=h();return D(o.closed.emit())}),y(52," Cancel "),v(),g(53,"button",32),T("click",function(){C(n);let o=h();return D(o.create())}),y(54),v()()}if(t&2){let n=h();d(4),A("value",n.title()),d(4),A("value",n.description()),d(6),A("value",n.newBranchValue)("selected",n.source()===n.newBranchValue),d(3),fe(n.localBranches()),d(3),fe(n.remoteBranches()),d(2),M(n.source()===n.newBranchValue?22:-1),d(5),fe(n.remoteBranches()),d(3),A("checked",n.isDraft())("disabled",n.creating()),d(5),A("chips",n.requiredReviewers())("suggestions",n.requiredReviewerSuggestions())("loading",n.requiredReviewersLoading())("error",n.requiredReviewersError())("query",n.requiredReviewerQuery()),d(4),A("chips",n.optionalReviewers())("suggestions",n.optionalReviewerSuggestions())("loading",n.optionalReviewersLoading())("error",n.optionalReviewersError())("query",n.optionalReviewerQuery()),d(4),A("chips",n.workItemChips())("suggestions",n.workItemSuggestions())("loading",n.workItemsLoading())("error",n.workItemsError())("query",n.workItemQuery()),d(4),A("chips",n.tagChips())("suggestions",n.filteredTagSuggestions())("loading",n.tagsLoading())("error",n.tagsError())("query",n.tagQuery())("allowFreeText",!0),d(),M(n.tagQuery().trim()&&!n.tagSuggestions().length&&!n.tagsLoading()?48:-1),d(),M(n.error()?49:-1),d(2),A("disabled",n.creating()),d(2),A("disabled",!n.canCreate()),d(),Z(" ",n.creating()?"Creating...":"Create Pull Request"," ")}}var pv="__new__",$a=class t{git=_(Lt);destroyRef=_(Oe);branches=O.required();closed=Y();created=Y();newBranchValue=pv;isDraft=b(!1);title=b("");description=b("");source=b("");target=b("");creating=b(!1);error=b("");result=b(null);requiredReviewers=b([]);optionalReviewers=b([]);workItemChips=b([]);tagChips=b([]);requiredReviewerQuery=b("");optionalReviewerQuery=b("");workItemQuery=b("");tagQuery=b("");requiredReviewerSuggestions=b([]);optionalReviewerSuggestions=b([]);workItemSuggestions=b([]);tagSuggestions=b([]);requiredReviewersLoading=b(!1);optionalReviewersLoading=b(!1);requiredReviewersError=b("");optionalReviewersError=b("");workItemsError=b("");tagsError=b("");workItemsLoading=b(!1);tagsLoading=b(!1);localBranches=U(()=>this.branches().filter(e=>!e.remote));remoteBranches=U(()=>this.branches().filter(e=>e.remote));canCreate=U(()=>!this.creating()&&!!this.target()&&!!this.source());filteredTagSuggestions=U(()=>{let e=this.tagQuery().trim().toLowerCase();return e?this.tagSuggestions().filter(n=>n.label.toLowerCase().includes(e)):this.tagSuggestions()});constructor(){this.bindLookup(this.requiredReviewerQuery,this.requiredReviewerSuggestions,this.requiredReviewersLoading,this.requiredReviewersError,e=>this.git.searchReviewers(e),e=>({id:e.id,label:e.label,description:e.description}),2),this.bindLookup(this.optionalReviewerQuery,this.optionalReviewerSuggestions,this.optionalReviewersLoading,this.optionalReviewersError,e=>this.git.searchReviewers(e),e=>({id:e.id,label:e.label,description:e.description}),2),this.bindLookup(this.workItemQuery,this.workItemSuggestions,this.workItemsLoading,this.workItemsError,e=>this.git.searchWorkItems(e),e=>({id:String(e.id),label:`#${e.id} ${e.title}`,description:e.state}),1)}bindLookup(e,n,r,o,i,s,a){Ba(e).pipe(ft(c=>(n.set([]),o.set(""),r.set(c.trim().length>=a),c.trim().length<a?Se([]):new z(l=>{let u=setTimeout(()=>{l.next(c.trim()),l.complete()},300);return()=>clearTimeout(u)}).pipe(ft(i),It(l=>(o.set(l?.error?.error||"Unable to load suggestions. Try searching again."),Se([])))))),di(this.destroyRef)).subscribe(c=>{n.set(c.map(s)),r.set(!1)})}ngOnInit(){let e=this.branches(),n=e.find(s=>s.current&&!s.remote),r=e.find(s=>!s.remote);this.source.set(n?.name??r?.name??""),this.title()||this.title.set(n?.name??"");let o=e.filter(s=>s.remote),i=o.find(s=>s.name==="origin/main")??o.find(s=>s.name==="origin/master");this.target.set(i?.name??o[0]?.name??""),this.tagsLoading.set(!0),this.git.getPrTags().pipe(di(this.destroyRef)).subscribe({next:s=>{this.tagSuggestions.set(s.map(a=>({id:a.name.toLowerCase(),label:a.name}))),this.tagsLoading.set(!1)},error:s=>{this.tagsError.set(s?.error?.error||"Unable to load tags. You can still add a tag with Enter."),this.tagSuggestions.set([]),this.tagsLoading.set(!1)}})}onEscape(){this.creating()||this.closed.emit()}onBackdropClick(){this.creating()||this.closed.emit()}onTitleInput(e){this.title.set(e.target.value)}onDescriptionInput(e){this.description.set(e.target.value)}onSourceChange(e){this.source.set(e.target.value)}onTargetChange(e){this.target.set(e.target.value)}isReviewerSelected(e){return[...this.requiredReviewers(),...this.optionalReviewers()].some(n=>n.id===e)}addRequiredReviewer(e){this.requiredReviewerQuery.set(""),this.requiredReviewerSuggestions.set([]),this.isReviewerSelected(e.id)||this.requiredReviewers.update(n=>[...n,e])}addOptionalReviewer(e){this.optionalReviewerQuery.set(""),this.optionalReviewerSuggestions.set([]),this.isReviewerSelected(e.id)||this.optionalReviewers.update(n=>[...n,e])}removeRequiredReviewer(e){this.requiredReviewers.update(n=>n.filter(r=>r.id!==e.id))}removeOptionalReviewer(e){this.optionalReviewers.update(n=>n.filter(r=>r.id!==e.id))}addWorkItem(e){this.workItemQuery.set(""),this.workItemSuggestions.set([]),this.workItemChips().some(n=>n.id===e.id)||this.workItemChips.update(n=>[...n,e])}removeWorkItem(e){this.workItemChips.update(n=>n.filter(r=>r.id!==e.id))}addTag(e){this.tagQuery.set(""),this.tagChips().some(n=>n.id===e.id)||this.tagChips.update(n=>[...n,e])}removeTag(e){this.tagChips.update(n=>n.filter(r=>r.id!==e.id))}create(){if(!this.canCreate())return;let e=this.source()===pv;this.creating.set(!0),this.error.set("");let n=[...this.requiredReviewers().map(i=>({id:i.id,required:!0})),...this.optionalReviewers().map(i=>({id:i.id,required:!1}))],r=this.workItemChips().map(i=>Number(i.id)).filter(i=>Number.isInteger(i)&&i>0),o=this.tagChips().map(i=>i.label);this.git.createPr({sourceBranch:e?"":this.source(),targetBranch:this.target(),title:this.title().trim()||void 0,description:this.description().trim()||void 0,newBranch:e,isDraft:this.isDraft(),reviewers:n.length?n:void 0,workItems:r.length?r:void 0,labels:o.length?o:void 0}).subscribe({next:i=>{this.creating.set(!1),this.result.set(i),this.created.emit(i)},error:i=>{this.creating.set(!1),this.error.set(this.errorMessage(i))}})}errorMessage(e){let n=e;return n?.status===400&&n.error?.error?n.error.error:"Failed to communicate with the Guito server."}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-create-pr-dialog"]],hostBindings:function(n,r){n&1&&T("keydown.escape",function(){return r.onEscape()},qe)},inputs:{branches:[1,"branches"]},outputs:{closed:"closed",created:"created"},decls:11,vars:2,consts:[[1,"backdrop",3,"click"],["role","dialog","aria-modal","true","aria-labelledby","create-pr-title",1,"dialog"],[1,"dialog-head"],["id","create-pr-title",1,"title"],["type","button","title","Close","aria-label","Close dialog",1,"icon-btn",3,"click","disabled"],["viewBox","0 0 24 24","aria-hidden","true"],["x1","18","y1","6","x2","6","y2","18"],["x1","6","y1","6","x2","18","y2","18"],[1,"success"],[1,"success-line"],["target","_blank","rel","noopener",1,"pr-link",3,"href"],[1,"hint"],[1,"actions"],["type","button",1,"btn","btn-primary",3,"click"],[1,"warning"],[1,"form"],[1,"field"],[1,"field-label"],["type","text","placeholder","Pull request title",1,"input",3,"input","value"],["rows","3","placeholder","Optional description",1,"input","description",3,"input","value"],[1,"input",3,"change"],["label","New branch"],[3,"value","selected"],["label","Local branches"],["label","Remote branches"],[1,"draft-option"],["type","checkbox",3,"change","checked","disabled"],["placeholder","Search users by name or email",3,"queryChange","select","remove","chips","suggestions","loading","error","query"],["placeholder","Search by id or title",3,"queryChange","select","remove","chips","suggestions","loading","error","query"],["placeholder","Add tags (Enter to add)",3,"queryChange","select","remove","chips","suggestions","loading","error","query","allowFreeText"],["role","alert",1,"error"],["type","button",1,"btn",3,"click","disabled"],["type","button",1,"btn","btn-primary",3,"click","disabled"]],template:function(n,r){if(n&1&&(g(0,"div",0),T("click",function(){return r.onBackdropClick()}),v(),g(1,"div",1)(2,"header",2)(3,"h3",3),y(4,"Create Pull Request"),v(),g(5,"button",4),T("click",function(){return r.closed.emit()}),X(),g(6,"svg",5),be(7,"line",6)(8,"line",7),v()()(),I(9,kw,10,4)(10,Vw,55,33),v()),n&2){let o;d(5),A("disabled",r.creating()),d(4),M((o=r.result())?9:10,o)}},dependencies:[Ha],styles:[".backdrop[_ngcontent-%COMP%]{position:fixed;inset:0;background:#00000080;z-index:400}.dialog[_ngcontent-%COMP%]{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);width:min(480px,calc(100vw - 48px));max-height:calc(100vh - 64px);overflow-y:auto;padding:18px;display:flex;flex-direction:column;gap:12px;background:var(--bg-alt);border:1px solid var(--border);border-radius:8px;box-shadow:0 10px 36px #0009;z-index:401}.dialog-head[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:8px}.title[_ngcontent-%COMP%]{margin:0;font-size:14px;font-weight:600;color:var(--text-bright)}.icon-btn[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;width:26px;height:26px;padding:0;border:none;border-radius:4px;background:transparent;color:var(--text-dim);cursor:pointer}.icon-btn[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--bg-hover);color:var(--text-bright)}.icon-btn[_ngcontent-%COMP%] svg[_ngcontent-%COMP%]{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}.form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:12px}.field[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:4px}.field-label[_ngcontent-%COMP%]{font-size:12px;color:var(--text-dim)}.input[_ngcontent-%COMP%]{padding:7px 10px;border:1px solid var(--border);border-radius:4px;background:var(--bg);color:var(--text);font-size:13px;font-family:inherit;outline:none}.input[_ngcontent-%COMP%]:focus{border-color:var(--accent)}textarea.description[_ngcontent-%COMP%]{resize:vertical;min-height:60px}.hint[_ngcontent-%COMP%]{margin:-6px 0 0;font-size:11px;color:var(--text-dim)}.error[_ngcontent-%COMP%]{margin:0;padding:8px 10px;border:1px solid #a1260d;border-radius:4px;background:#a1260d26;color:#f48771;font-size:12px;word-break:break-word}.warning[_ngcontent-%COMP%]{margin:0;padding:8px 10px;border:1px solid #8a6c10;border-radius:4px;background:#8a6c1026;color:#dcb67a;font-size:12px;word-break:break-word}.actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:8px}.btn[_ngcontent-%COMP%]{padding:6px 14px;border:1px solid var(--border);border-radius:4px;background:transparent;color:var(--text);font-size:12px;font-family:inherit;cursor:pointer}.btn[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--bg-hover);color:var(--text-bright)}.btn[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:default}.btn-primary[_ngcontent-%COMP%]{background:var(--accent);border-color:var(--accent);color:#fff}.btn-primary[_ngcontent-%COMP%]:hover:not(:disabled){background:#2b7cd3}.success[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:8px}.success-line[_ngcontent-%COMP%]{margin:0;font-size:13px;color:#4ec9b0}.pr-link[_ngcontent-%COMP%]{font-size:13px;color:var(--accent);text-decoration:none}.pr-link[_ngcontent-%COMP%]:hover{text-decoration:underline}"],changeDetection:0})};var Bw=["inputEl"],Hw=["searchEl"],$w=(t,e)=>e.value;function Uw(t,e){if(t&1&&(w(0,"p",5),y(1),x()),t&2){let n=h();d(),V(n.label)}}function zw(t,e){if(t&1){let n=$();w(0,"input",13,0),q("input",function(o){C(n);let i=h(3);return D(i.onSearch(o))})("keydown.enter",function(o){C(n);let i=h(3);return D(i.onSearchEnter(o))}),x()}if(t&2){let n=h(3);ce("value",n.search())}}function Ww(t,e){if(t&1&&(w(0,"span",18),y(1),x()),t&2){let n=h().$implicit;d(),V(n.description)}}function Gw(t,e){if(t&1){let n=$();w(0,"button",14),q("click",function(){let o=C(n).$implicit,i=h(3);return D(i.choose(o))})("dblclick",function(){C(n);let o=h(3);return D(o.confirm())}),ae(1,"span",15),w(2,"span",16)(3,"span",17),y(4),x(),I(5,Ww,2,1,"span",18),x()()}if(t&2){let n=e.$implicit,r=h(3);Pe("selected",r.choice()===n.value)("danger",n.danger),ue("aria-checked",r.choice()===n.value),d(4),V(n.label),d(),M(n.description?5:-1)}}function qw(t,e){t&1&&(w(0,"p",12),y(1,"No matching branches"),x())}function Zw(t,e){if(t&1&&(I(0,zw,2,1,"input",9),w(1,"div",10),de(2,Gw,6,7,"button",11,$w,!1,qw,2,0,"p",12),x()),t&2){let n=h(),r=h();M(n.searchable?0:-1),d(2),fe(r.filteredOptions())}}function Yw(t,e){if(t&1){let n=$();w(0,"label",19),y(1),x(),w(2,"input",20,1),q("input",function(o){C(n);let i=h(2);return D(i.onInput(o))})("keydown.enter",function(){C(n);let o=h(2);return D(o.confirm())}),x()}if(t&2){let n=h(),r=h();d(),V(n.label||n.title),d(),ce("value",r.value()),ue("placeholder",n.placeholder||" ")("aria-label",n.label||n.title)}}function Qw(t,e){if(t&1){let n=$();w(0,"div",2),q("click",function(){C(n);let o=h();return D(o.cancelled.emit())}),x(),w(1,"div",3)(2,"h3",4),y(3),x(),I(4,Uw,2,1,"p",5),I(5,Zw,5,2)(6,Yw,4,4),w(7,"div",6)(8,"button",7),q("click",function(){C(n);let o=h();return D(o.cancelled.emit())}),y(9,"Cancel"),x(),w(10,"button",8),q("click",function(){C(n);let o=h();return D(o.confirm())}),y(11),x()()()}if(t&2){let n=e,r=h();d(3),V(n.title),d(),M(n.label?4:-1),d(),M(r.options().length>0?5:n.confirmOnly?-1:6),d(5),Pe("btn-danger",n.danger),ce("disabled",r.options().length===0&&!n.confirmOnly&&!n.allowEmpty&&!r.value().trim()||n.searchable&&r.filteredOptions().length===0),d(),Z(" ",n.okLabel||"OK"," ")}}var Ua=class t{state=O.required();confirmed=Y();cancelled=Y();value=b("");choice=b("");options=U(()=>this.state()?.options??[]);search=b("");filteredOptions=U(()=>{let e=this.search().trim().toLowerCase(),n=this.options();return e?n.filter(r=>r.label.toLowerCase().includes(e)||r.value.toLowerCase().includes(e)):n});inputEl=Ut("inputEl");searchEl=Ut("searchEl");constructor(){Me(()=>{let e=this.state();e&&(this.value.set(e.value??""),this.choice.set(e.options?.[0]?.value??""),this.search.set(""));let n=this.inputEl()??this.searchEl();e&&n&&(n.nativeElement.focus(),n.nativeElement.select())})}onEscape(){this.state()&&this.cancelled.emit()}onInput(e){this.value.set(e.target.value)}choose(e){this.choice.set(e.value)}onSearch(e){this.search.set(e.target.value);let n=this.filteredOptions();n.length&&!n.some(r=>r.value===this.choice())&&this.choice.set(n[0].value)}onSearchEnter(e){e.preventDefault(),this.filteredOptions().length>0&&this.confirm()}confirm(){let e=this.state();if(e){if(e.options?.length){this.confirmed.emit(this.choice());return}!e.confirmOnly&&!e.allowEmpty&&!this.value().trim()||this.confirmed.emit(e.confirmOnly?"":this.value().trim())}}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-prompt-dialog"]],viewQuery:function(n,r){n&1&&(Ft(r.inputEl,Bw,5),Ft(r.searchEl,Hw,5)),n&2&&$t(2)},hostBindings:function(n,r){n&1&&T("keydown.escape",function(){return r.onEscape()},qe)},inputs:{state:[1,"state"]},outputs:{confirmed:"confirmed",cancelled:"cancelled"},decls:1,vars:1,consts:[["searchEl",""],["inputEl",""],[1,"backdrop",3,"click"],["role","dialog","aria-modal","true",1,"dialog"],[1,"title"],[1,"label"],[1,"actions"],["type","button",1,"btn",3,"click"],["type","button",1,"btn","btn-primary",3,"click","disabled"],["type","text","placeholder","Search\u2026","aria-label","Search options",1,"input",3,"value"],["role","radiogroup",1,"options"],["type","button","role","radio",1,"option",3,"selected","danger"],[1,"no-results"],["type","text","placeholder","Search\u2026","aria-label","Search options",1,"input",3,"input","keydown.enter","value"],["type","button","role","radio",1,"option",3,"click","dblclick"],["aria-hidden","true",1,"option-radio"],[1,"option-text"],[1,"option-label"],[1,"option-description"],["for","prompt-input",1,"sr-only"],["id","prompt-input","type","text","placeholder"," ","title","Enter a value",1,"input",3,"input","keydown.enter","value"]],template:function(n,r){if(n&1&&I(0,Qw,12,7),n&2){let o;M((o=r.state())?0:-1,o)}},styles:[".backdrop[_ngcontent-%COMP%]{position:fixed;inset:0;background:#00000080;z-index:400}.dialog[_ngcontent-%COMP%]{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);width:min(420px,calc(100vw - 48px));padding:18px;display:flex;flex-direction:column;gap:12px;background:var(--bg-alt);border:1px solid var(--border);border-radius:8px;box-shadow:0 10px 36px #0009;z-index:401}.title[_ngcontent-%COMP%]{margin:0;font-size:14px;font-weight:600;color:var(--text-bright)}.label[_ngcontent-%COMP%]{margin:0;font-size:12px;color:var(--text-dim)}.input[_ngcontent-%COMP%]{padding:7px 10px;border:1px solid var(--border);border-radius:4px;background:var(--bg);color:var(--text);font-size:13px;font-family:inherit;outline:none}.input[_ngcontent-%COMP%]:focus{border-color:var(--accent)}.actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:8px}.btn[_ngcontent-%COMP%]{padding:6px 14px;border:1px solid var(--border);border-radius:4px;background:transparent;color:var(--text);font-size:12px;font-family:inherit;cursor:pointer}.btn[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--bg-hover);color:var(--text-bright)}.btn-primary[_ngcontent-%COMP%]{background:var(--accent);border-color:var(--accent);color:#fff}.btn-primary[_ngcontent-%COMP%]:hover:not(:disabled){background:#2b7cd3}.btn-danger[_ngcontent-%COMP%]{background:#a1260d;border-color:#a1260d;color:#fff}.options[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:4px;max-height:40vh;overflow-y:auto}.no-results[_ngcontent-%COMP%]{margin:0;padding:8px 10px;font-size:12px;color:var(--text-dim)}.option[_ngcontent-%COMP%]{display:flex;align-items:flex-start;gap:10px;padding:8px 10px;border:1px solid var(--border);border-radius:4px;background:transparent;color:var(--text);font-family:inherit;text-align:left;cursor:pointer}.option[_ngcontent-%COMP%]:hover{background:var(--bg-hover)}.option.selected[_ngcontent-%COMP%]{border-color:var(--accent);background:#3794ff1f}.option-radio[_ngcontent-%COMP%]{width:13px;height:13px;margin-top:2px;border:1px solid var(--border);border-radius:50%;flex:none}.option.selected[_ngcontent-%COMP%] .option-radio[_ngcontent-%COMP%]{border-color:var(--accent);background:radial-gradient(circle,var(--accent) 0 40%,transparent 45%)}.option-text[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2px;min-width:0}.option-label[_ngcontent-%COMP%]{font-size:12px;font-weight:600;color:var(--text-bright)}.option.danger[_ngcontent-%COMP%] .option-label[_ngcontent-%COMP%]{color:#f48771}.option-description[_ngcontent-%COMP%]{font-size:11px;color:var(--text-dim)}.btn-danger[_ngcontent-%COMP%]:hover:not(:disabled){background:#c42b1c}.btn[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:default}"],changeDetection:0})};var Kw=["searchInput"];function Xw(t,e){if(t&1){let n=$();w(0,"button",8),q("click",function(){C(n);let o=h();return D(o.clearSearch())}),X(),w(1,"svg",2),ae(2,"line",9)(3,"line",10),x()()}}function Jw(t,e){t&1&&y(0," No matches ")}function ex(t,e){if(t&1&&y(0),t&2){let n=h(2);Z(" ",n.matchCount()," matches ")}}function tx(t,e){if(t&1&&y(0),t&2){let n=h(2);Vr(" ",n.matchIndex()+1," of ",n.matchCount()," ")}}function nx(t,e){if(t&1){let n=$();w(0,"div",7)(1,"button",11),q("click",function(){C(n);let o=h();return D(o.searchNavigate.emit("prev"))}),X(),w(2,"svg",2),ae(3,"polyline",12),x()(),xe(),w(4,"span",13),I(5,Jw,1,0)(6,ex,1,1)(7,tx,1,2),x(),w(8,"button",14),q("click",function(){C(n);let o=h();return D(o.searchNavigate.emit("next"))}),X(),w(9,"svg",2),ae(10,"polyline",15),x()()()}if(t&2){let n=h();d(),ce("disabled",n.matchCount()===0),d(4),M(n.matchCount()===0?5:n.matchIndex()<0?6:7),d(3),ce("disabled",n.matchCount()===0)}}var rx=300,za=class t{matchIndex=O(-1);matchCount=O(0);searchChange=Y();searchNavigate=Y();searchValue=b("");searchInput=Ut("searchInput");constructor(){Ba(this.searchValue).pipe(yc(rx),so(),di()).subscribe(e=>this.searchChange.emit(e))}onSearch(e){this.searchValue.set(e.target.value)}onSearchKeydown(e){e.key==="Enter"&&(e.preventDefault(),this.searchNavigate.emit(e.shiftKey?"prev":"next"))}clearSearch(){this.searchValue.set(""),this.searchInput()?.nativeElement.focus()}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-search-box"]],viewQuery:function(n,r){n&1&&Ft(r.searchInput,Kw,5),n&2&&$t()},inputs:{matchIndex:[1,"matchIndex"],matchCount:[1,"matchCount"]},outputs:{searchChange:"searchChange",searchNavigate:"searchNavigate"},decls:8,vars:3,consts:[["searchInput",""],[1,"search"],["viewBox","0 0 24 24","aria-hidden","true"],["cx","11","cy","11","r","8"],["x1","21","y1","21","x2","16.65","y2","16.65"],["type","text","placeholder","Search commits",3,"input","keydown","value"],["type","button","title","Clear search","aria-label","Clear search",1,"clear-btn"],[1,"search-nav"],["type","button","title","Clear search","aria-label","Clear search",1,"clear-btn",3,"click"],["x1","18","y1","6","x2","6","y2","18"],["x1","6","y1","6","x2","18","y2","18"],["type","button","title","Previous match (Shift+Enter)","aria-label","Previous match",1,"nav-btn",3,"click","disabled"],["points","18 15 12 9 6 15"],[1,"count"],["type","button","title","Next match (Enter)","aria-label","Next match",1,"nav-btn",3,"click","disabled"],["points","6 9 12 15 18 9"]],template:function(n,r){if(n&1){let o=$();w(0,"div",1),X(),w(1,"svg",2),ae(2,"circle",3)(3,"line",4),x(),xe(),w(4,"input",5,0),q("input",function(s){return C(o),D(r.onSearch(s))})("keydown",function(s){return C(o),D(r.onSearchKeydown(s))}),x(),I(6,Xw,4,0,"button",6),x(),I(7,nx,11,3,"div",7)}n&2&&(d(4),ce("value",r.searchValue()),d(2),M(r.searchValue()?6:-1),d(),M(r.searchValue()?7:-1))},styles:["[_nghost-%COMP%]{display:flex;align-items:center;gap:8px}.search[_ngcontent-%COMP%]{display:flex;align-items:center;gap:6px;height:26px;padding:0 8px;border:1px solid var(--border);border-radius:4px;background:#2d2d2d;color:var(--text-dim)}.search[_ngcontent-%COMP%]:focus-within{border-color:var(--accent)}.search[_ngcontent-%COMP%] svg[_ngcontent-%COMP%]{width:13px;height:13px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;flex:none}.search[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{width:170px;border:none;outline:none;background:transparent;color:var(--text);font-size:12px}.search[_ngcontent-%COMP%] input[_ngcontent-%COMP%]::placeholder{color:#777}.clear-btn[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;width:16px;height:16px;padding:0;border:none;border-radius:3px;background:transparent;color:var(--text-dim);cursor:pointer;flex:none}.clear-btn[_ngcontent-%COMP%]:hover{color:var(--text);background:#3a3a3a}.clear-btn[_ngcontent-%COMP%] svg[_ngcontent-%COMP%]{width:11px;height:11px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round}.count[_ngcontent-%COMP%]{font-size:12px;color:var(--text-dim);white-space:nowrap;-webkit-user-select:none;user-select:none}.search-nav[_ngcontent-%COMP%]{display:flex;align-items:center;gap:2px}.nav-btn[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;width:20px;height:20px;padding:0;border:none;border-radius:3px;background:transparent;color:var(--text-dim);cursor:pointer;flex:none}.nav-btn[_ngcontent-%COMP%]:hover:not(:disabled){color:var(--text-bright);background:#3a3a3a}.nav-btn[_ngcontent-%COMP%]:disabled{opacity:.4;cursor:default}.nav-btn[_ngcontent-%COMP%] svg[_ngcontent-%COMP%]{width:13px;height:13px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}"],changeDetection:0})};var ox=(t,e)=>e.path;function ix(t,e){if(t&1&&(g(0,"div",4),be(1,"span",16),y(2),v()),t&2){let n=h();d(2),V(n.statusLoading()?"Refreshing changes\u2026":"Updating repository\u2026")}}function sx(t,e){if(t&1){let n=$();g(0,"div",5),y(1),g(2,"button",3),T("click",function(){C(n);let o=h();return D(o.retry.emit())}),y(3,"Retry status"),v()()}if(t&2){let n=h();d(),Z("",n.statusError()," "),d(),A("disabled",n.busy())}}function ax(t,e){if(t&1){let n=$();g(0,"button",22),T("click",function(){C(n);let o=h(2);return D(o.discardSelected())}),y(1,"Discard selected"),v(),g(2,"button",22),T("click",function(){C(n);let o=h(2);return D(o.discardAll())}),y(3,"Discard all"),v()}if(t&2){let n=h().$implicit,r=h();A("disabled",r.disabled()||!r.selected()[n].size),d(2),A("disabled",r.disabled()||!r.files(n).length)}}function cx(t,e){if(t&1){let n=$();g(0,"div",20)(1,"div",23),T("click",function(o){let i=C(n).$implicit,s=h().$implicit,a=h();return D(a.select(s,i.path,o))})("keydown",function(o){let i=C(n).$implicit,s=h().$implicit,a=h();return D(a.keySelect(s,i.path,o))}),g(2,"span",24),y(3),v(),g(4,"span",25),y(5),v(),g(6,"span",26)(7,"span",27),y(8),v(),g(9,"span",28),y(10),v()()(),g(11,"button",29),T("click",function(){let o=C(n).$implicit,i=h().$implicit,s=h();return D(s.dialog.set({file:o,group:i}))}),y(12,"Diff"),v()()}if(t&2){let n=e.$implicit,r=h().$implicit,o=h();d(),Pe("selected",o.selected()[r].has(n.path)),ue("aria-selected",o.selected()[r].has(n.path))("aria-label",n.path),d(),A("title",n.status),d(),V(n.status.slice(0,1).toUpperCase()),d(),A("title",n.oldPath&&n.oldPath!==n.path?n.oldPath+" \u2192 "+n.path:n.path),d(),V(n.path),d(3),Z("+",n.additions),d(2),Z("\u2212",n.deletions),d(),A("disabled",o.busy()),ue("aria-label","View "+r+" diff for "+n.path)}}function lx(t,e){if(t&1&&(g(0,"p",21),y(1),v()),t&2){let n=h().$implicit;d(),V(n==="staged"?"No staged changes.":"No unstaged changes.")}}function ux(t,e){if(t&1){let n=$();g(0,"section")(1,"h3"),y(2),v(),g(3,"div",17)(4,"span",18),y(5),v(),g(6,"button",3),T("click",function(){let o=C(n).$implicit,i=h();return D(i.moveSelected(o))}),y(7),v(),g(8,"button",3),T("click",function(){let o=C(n).$implicit,i=h();return D(i.moveAll(o))}),y(9),v(),I(10,ax,4,2),v(),g(11,"div",19),de(12,cx,13,12,"div",20,ox,!1,lx,2,1,"p",21),v()()}if(t&2){let n=e.$implicit,r=h();ue("aria-label",n==="staged"?"Staged changes":"Unstaged changes"),d(2),Vr("",n==="staged"?"Staged changes":"Unstaged changes"," (",r.files(n).length,")"),d(3),Z("",r.selected()[n].size," selected"),d(),A("disabled",r.disabled()||!r.selected()[n].size),d(),V(n==="staged"?"Unstage selected":"Stage selected"),d(),A("disabled",r.disabled()||!r.files(n).length),d(),V(n==="staged"?"Unstage all":"Stage all"),d(),M(n==="unstaged"?10:-1),d(),ue("aria-label",n+" files"),d(),fe(r.files(n))}}function dx(t,e){t&1&&(g(0,"p",8),y(1,"Resolve conflicts before committing."),v())}function fx(t,e){if(t&1){let n=$();g(0,"app-diff-dialog",30),T("closed",function(){C(n);let o=h();return D(o.dialog.set(null))}),v()}if(t&2){let n=e;A("file",n.file)("originalRef",n.group==="staged"?"HEAD":"INDEX")("modifiedRef",n.group==="staged"?"INDEX":"WORKING")}}var Wa=class t{changes=O(null);busy=O(!1);statusLoading=O(!1);statusError=O("");subject=O("");description=O("");subjectChange=Y();descriptionChange=Y();stageChange=Y();stashChange=Y();discardRequest=Y();commitRequested=Y();retry=Y();closed=Y();groups=["staged","unstaged"];selected=b({staged:new Set,unstaged:new Set});anchors={staged:null,unstaged:null};dialog=b(null);disabled=U(()=>this.busy()||!!this.statusError()||!this.changes());canCommit=U(()=>!this.disabled()&&!!this.subject().trim()&&!!this.changes()?.staged.length&&!this.changes()?.conflicted.length);constructor(){Me(()=>{let e=this.changes();this.selected.update(n=>{let r=K({},n);for(let o of this.groups){let i=new Set((o==="staged"?e?.stagedFiles:e?.unstagedFiles)?.map(s=>s.path));r[o]=new Set([...n[o]].filter(s=>i.has(s))),this.anchors[o]&&!i.has(this.anchors[o])&&(this.anchors[o]=null)}return r}),this.dialog.set(null)})}files(e){return(e==="staged"?this.changes()?.stagedFiles:this.changes()?.unstagedFiles)??[]}select(e,n,r){let o=r.ctrlKey||r.metaKey,i=this.files(e).map(l=>l.path),s=this.anchors[e],a=r.shiftKey&&s!==null&&i.includes(s),c=o?new Set(this.selected()[e]):new Set;if(a){let l=i.indexOf(s),u=i.indexOf(n);for(let f of i.slice(Math.min(l,u),Math.max(l,u)+1))c.add(f)}else o&&c.has(n)?c.delete(n):c.add(n),this.anchors[e]=n;this.selected.update(l=>le(K({},l),{[e]:c}))}keySelect(e,n,r){if((r.key===" "||r.key==="Enter")&&(r.preventDefault(),this.select(e,n,r)),r.key==="ArrowDown"||r.key==="ArrowUp"){r.preventDefault();let o=Array.from(r.currentTarget.closest(".file-list").querySelectorAll('[role="option"]')),i=o.indexOf(r.currentTarget),s=Math.max(0,Math.min(o.length-1,i+(r.key==="ArrowDown"?1:-1)));o[s]?.focus(),r.shiftKey&&this.select(e,this.files(e)[s].path,r)}}move(e,n){this.disabled()||!n.length||this.stageChange.emit({staged:e==="staged",files:n})}moveSelected(e){this.move(e,[...this.selected()[e]])}moveAll(e){this.move(e,this.files(e).map(n=>n.path))}stash(e){this.disabled()||this.stashChange.emit(e)}discard(e){this.disabled()||!e.length||this.discardRequest.emit(e)}discardSelected(){this.discard([...this.selected().unstaged])}discardAll(){this.discard(this.files("unstaged").map(e=>e.path))}updateSubject(e){this.subjectChange.emit(e.target.value)}updateDescription(e){this.descriptionChange.emit(e.target.value)}commit(e){e.preventDefault(),this.canCommit()&&this.commitRequested.emit()}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-working-panel"]],inputs:{changes:[1,"changes"],busy:[1,"busy"],statusLoading:[1,"statusLoading"],statusError:[1,"statusError"],subject:[1,"subject"],description:[1,"description"]},outputs:{subjectChange:"subjectChange",descriptionChange:"descriptionChange",stageChange:"stageChange",stashChange:"stashChange",discardRequest:"discardRequest",commitRequested:"commitRequested",retry:"retry",closed:"closed"},decls:31,vars:12,consts:[["aria-label","Uncommitted changes",1,"detail"],["type","button","aria-label","Close changes",3,"click"],["role","group","aria-label","Stash changes",1,"stash-actions"],["type","button",3,"click","disabled"],["role","status",1,"state"],["role","alert",1,"error"],[1,"changes"],[3,"submit"],[1,"error"],["for","commit-subject"],["id","commit-subject","placeholder","Summary of your changes","required","",3,"input","value","disabled"],["for","commit-description"],[1,"optional"],["id","commit-description","rows","3",3,"input","value","disabled"],["type","submit",1,"commit-button",3,"disabled"],[3,"file","originalRef","modifiedRef"],[1,"spinner"],[1,"actions"],["aria-live","polite",1,"selection-count"],["role","listbox","aria-multiselectable","true",1,"file-list"],[1,"file-entry"],[1,"empty"],["type","button",1,"danger",3,"click","disabled"],["role","option","tabindex","0",1,"file-row",3,"click","keydown"],[1,"file-status",3,"title"],[1,"file-path",3,"title"],[1,"counts"],[1,"additions"],[1,"deletions"],["type","button",1,"file-action",3,"click","disabled"],[3,"closed","file","originalRef","modifiedRef"]],template:function(n,r){if(n&1&&(g(0,"aside",0)(1,"header")(2,"h2"),y(3,"Uncommitted changes"),v(),g(4,"button",1),T("click",function(){return r.closed.emit()}),y(5,"\xD7"),v()(),g(6,"div",2)(7,"button",3),T("click",function(){return r.stash("all")}),y(8,"Stash all"),v(),g(9,"button",3),T("click",function(){return r.stash("staged")}),y(10,"Stash staged"),v(),g(11,"button",3),T("click",function(){return r.stash("unstaged")}),y(12,"Stash unstaged"),v()(),I(13,ix,3,1,"div",4),I(14,sx,4,2,"div",5),g(15,"div",6),de(16,ux,15,11,"section",null,Ho),v(),g(18,"form",7),T("submit",function(i){return r.commit(i)}),I(19,dx,2,0,"p",8),g(20,"label",9),y(21,"Commit message"),v(),g(22,"input",10),T("input",function(i){return r.updateSubject(i)}),v(),g(23,"label",11),y(24,"Description "),g(25,"span",12),y(26,"(optional)"),v()(),g(27,"textarea",13),T("input",function(i){return r.updateDescription(i)}),v(),g(28,"button",14),y(29,"Commit staged changes"),v()()(),I(30,fx,1,3,"app-diff-dialog",15)),n&2){let o,i;d(7),A("disabled",r.disabled()||!r.files("staged").length&&!r.files("unstaged").length),d(2),A("disabled",r.disabled()||!r.files("staged").length),d(2),A("disabled",r.disabled()||!r.files("unstaged").length),d(2),M(r.busy()?13:-1),d(),M(r.statusError()?14:-1),d(2),fe(r.groups),d(3),M(!((o=r.changes())==null||o.conflicted==null)&&o.conflicted.length?19:-1),d(3),A("value",r.subject())("disabled",r.busy()),d(5),A("value",r.description())("disabled",r.busy()),d(),A("disabled",!r.canCommit()),d(2),M((i=r.dialog())?30:-1,i)}},dependencies:[Wr],styles:["[_nghost-%COMP%]{display:flex;flex:none;width:min(480px,60vw);min-width:320px;min-height:0}.detail[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:100%;min-height:0;background:var(--bg-alt);border-left:1px solid var(--border);color:var(--text)}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:12px;gap:12px}h2[_ngcontent-%COMP%]{font-size:15px;margin:0}h3[_ngcontent-%COMP%]{font-size:13px;margin:0 0 8px}.stash-actions[_ngcontent-%COMP%]{display:flex;align-items:center;gap:5px;padding:0 12px 10px;flex-wrap:wrap;font-size:11px}button[_ngcontent-%COMP%], input[_ngcontent-%COMP%], textarea[_ngcontent-%COMP%]{font:inherit;color:var(--text);border:1px solid var(--border);border-radius:3px;background:var(--bg)}button[_ngcontent-%COMP%]{cursor:pointer;padding:4px 7px;white-space:nowrap}button[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--bg-hover)}button.danger[_ngcontent-%COMP%]{color:#f48771}button.danger[_ngcontent-%COMP%]:hover:not(:disabled){background:#5a1d1d}button[_ngcontent-%COMP%]:disabled{opacity:.45;cursor:default}button[_ngcontent-%COMP%]:focus-visible, input[_ngcontent-%COMP%]:focus-visible, textarea[_ngcontent-%COMP%]:focus-visible, .file-row[_ngcontent-%COMP%]:focus-visible{outline:2px solid var(--accent);outline-offset:-2px}.changes[_ngcontent-%COMP%]{overflow-y:auto;flex:1;min-height:80px}section[_ngcontent-%COMP%]{padding:10px;border-top:1px solid var(--border)}.actions[_ngcontent-%COMP%]{display:flex;align-items:center;gap:5px;margin-bottom:6px;flex-wrap:wrap;font-size:11px}.selection-count[_ngcontent-%COMP%]{margin-right:auto;color:var(--text-dim)}.file-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2px}.file-entry[_ngcontent-%COMP%]{display:flex;align-items:center;gap:3px}.file-row[_ngcontent-%COMP%]{display:flex;align-items:center;flex:1;min-width:0;gap:7px;padding:7px 4px;cursor:pointer;-webkit-user-select:none;user-select:none;font-size:12px}.file-row[_ngcontent-%COMP%]:hover{background:var(--bg-hover)}.file-row.selected[_ngcontent-%COMP%]{background:#04395e}.file-status[_ngcontent-%COMP%]{color:var(--accent);width:12px;flex:none}.file-path[_ngcontent-%COMP%]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1}.counts[_ngcontent-%COMP%]{white-space:nowrap;font-size:11px}.additions[_ngcontent-%COMP%]{color:#89d185}.deletions[_ngcontent-%COMP%], .error[_ngcontent-%COMP%]{color:#f48771}.file-action[_ngcontent-%COMP%]{font-size:11px}.empty[_ngcontent-%COMP%], .optional[_ngcontent-%COMP%]{color:var(--text-dim);font-size:12px}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:6px;padding:12px;border-top:1px solid var(--border);max-height:50%;overflow-y:auto}label[_ngcontent-%COMP%]{font-size:12px}input[_ngcontent-%COMP%], textarea[_ngcontent-%COMP%]{padding:7px;width:100%;box-sizing:border-box}textarea[_ngcontent-%COMP%]{resize:vertical;min-height:50px}.commit-button[_ngcontent-%COMP%]{background:var(--accent);color:#fff;padding:8px;margin-top:4px}.state[_ngcontent-%COMP%], .error[_ngcontent-%COMP%]{padding:8px 12px;font-size:12px}.state[_ngcontent-%COMP%]{display:flex;gap:8px;align-items:center}.spinner[_ngcontent-%COMP%]{width:12px;height:12px;border:2px solid var(--border);border-top-color:var(--accent);border-radius:50%;animation:_ngcontent-%COMP%_spin .8s linear infinite}@keyframes _ngcontent-%COMP%_spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){.spinner[_ngcontent-%COMP%]{animation:none}}"],changeDetection:0})};var px=(t,e)=>e.name;function hx(t,e){if(t&1&&(w(0,"option",5),y(1),x()),t&2){let n=e.$implicit;ce("value",n.name),d(),V(n.name)}}function gx(t,e){if(t&1){let n=$();w(0,"div",16)(1,"button",27),q("click",function(){C(n);let o=h();return D(o.chooseRemoteAction("pull"))}),y(2,"Pull"),x(),w(3,"button",27),q("click",function(){C(n);let o=h();return D(o.chooseRemoteAction("pull-rebase"))}),y(4,"Pull (rebase)"),x(),w(5,"button",27),q("click",function(){C(n);let o=h();return D(o.chooseRemoteAction("rebase-from"))}),y(6,"Rebase (from)..."),x()()}}function mx(t,e){if(t&1){let n=$();w(0,"button",27),q("click",function(){C(n);let o=h(2);return D(o.chooseRemoteAction("create-pr"))}),y(1," Create Pull Request... "),x()}}function vx(t,e){if(t&1){let n=$();w(0,"div",16)(1,"button",27),q("click",function(){C(n);let o=h();return D(o.chooseRemoteAction("push"))}),y(2,"Push"),x(),w(3,"button",28),q("click",function(){C(n);let o=h();return D(o.chooseRemoteAction("push-force"))}),y(4," Push (force) "),x(),w(5,"button",27),q("click",function(){C(n);let o=h();return D(o.chooseRemoteAction("sync"))}),y(6,"Sync"),x(),I(7,mx,2,0,"button",29),x()}if(t&2){let n=h();d(7),M(n.prEnabled()?7:-1)}}var Ga=class t{branches=O.required();selectedBranch=O.required();showRemote=O.required();busy=O.required();prEnabled=O(!1);branchChange=Y();remoteToggle=Y();refresh=Y();remoteAction=Y();settingsClick=Y();openMenu=b(null);visibleBranches=U(()=>this.branches());onBranchChange(e){this.branchChange.emit(e.target.value)}onRemoteToggle(e){this.remoteToggle.emit(e.target.checked)}toggleMenu(e,n){n.stopPropagation(),this.openMenu.update(r=>r===e?null:e)}chooseRemoteAction(e){this.openMenu.set(null),this.remoteAction.emit(e)}closeMenu(){this.openMenu.set(null)}closeMenuOnEscape(){this.openMenu.set(null)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-toolbar"]],hostBindings:function(n,r){n&1&&T("click",function(){return r.closeMenu()},qe)("keydown.escape",function(){return r.closeMenuOnEscape()},qe)},inputs:{branches:[1,"branches"],selectedBranch:[1,"selectedBranch"],showRemote:[1,"showRemote"],busy:[1,"busy"],prEnabled:[1,"prEnabled"]},outputs:{branchChange:"branchChange",remoteToggle:"remoteToggle",refresh:"refresh",remoteAction:"remoteAction",settingsClick:"settingsClick"},decls:40,vars:9,consts:[[1,"toolbar"],[1,"group"],["for","branch-select",1,"label"],["id","branch-select",1,"select",3,"change","value"],["value",""],[3,"value"],[1,"checkbox"],["type","checkbox",3,"change","checked"],["title","Fetch",1,"icon-btn",3,"click","disabled"],["viewBox","0 0 24 24","aria-hidden","true"],["d","M18 10h-1.26A8 8 0 1 0 9 20h9a5 5 0 0 0 0-10z"],[1,"action-menu"],["title","Pull",1,"icon-btn",3,"click","disabled"],["cx","12","cy","12","r","10"],["points","8 12 12 16 16 12"],["x1","12","y1","8","x2","12","y2","16"],["role","menu",1,"remote-menu"],["title","Push",1,"icon-btn",3,"click","disabled"],["points","16 12 12 8 8 12"],["x1","12","y1","16","x2","12","y2","8"],["title","Refresh",1,"icon-btn",3,"click"],["points","23 4 23 10 17 10"],["points","1 20 1 14 7 14"],["d","M3.51 9a9 9 0 0 1 14.85-3.36L23 10M1 14l4.64 4.36A9 9 0 0 0 20.49 15"],["title","Settings",1,"icon-btn",3,"click"],["cx","12","cy","12","r","3"],["d","M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1-2.83 2.83l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-4 0v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1 0-4h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 2.83-2.83l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 4 0v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 0 4h-.09a1.65 1.65 0 0 0-1.51 1z"],["type","button","role","menuitem",3,"click"],["type","button","role","menuitem",1,"danger",3,"click"],["type","button","role","menuitem"]],template:function(n,r){n&1&&(w(0,"div",0)(1,"div",1)(2,"label",2),y(3,"Branches:"),x(),w(4,"select",3),q("change",function(i){return r.onBranchChange(i)}),w(5,"option",4),y(6,"Show All"),x(),de(7,hx,2,2,"option",5,px),x(),w(9,"label",6)(10,"input",7),q("change",function(i){return r.onRemoteToggle(i)}),x(),w(11,"span"),y(12,"Show Remote Branches"),x()()(),w(13,"div",1)(14,"button",8),q("click",function(){return r.remoteAction.emit("fetch")}),X(),w(15,"svg",9),ae(16,"path",10),x()(),xe(),w(17,"div",11)(18,"button",12),q("click",function(i){return r.toggleMenu("pull",i)}),X(),w(19,"svg",9),ae(20,"circle",13)(21,"polyline",14)(22,"line",15),x()(),I(23,gx,7,0,"div",16),x(),xe(),w(24,"div",11)(25,"button",17),q("click",function(i){return r.toggleMenu("push",i)}),X(),w(26,"svg",9),ae(27,"circle",13)(28,"polyline",18)(29,"line",19),x()(),I(30,vx,8,1,"div",16),x(),xe(),w(31,"button",20),q("click",function(){return r.refresh.emit()}),X(),w(32,"svg",9),ae(33,"polyline",21)(34,"polyline",22)(35,"path",23),x()(),xe(),w(36,"button",24),q("click",function(){return r.settingsClick.emit()}),X(),w(37,"svg",9),ae(38,"circle",25)(39,"path",26),x()()()()),n&2&&(d(4),ce("value",r.selectedBranch()),d(3),fe(r.visibleBranches()),d(3),ce("checked",r.showRemote()),d(4),ce("disabled",r.busy()),d(4),ce("disabled",r.busy()),ue("aria-expanded",r.openMenu()==="pull"),d(5),M(r.openMenu()==="pull"?23:-1),d(2),ce("disabled",r.busy()),ue("aria-expanded",r.openMenu()==="push"),d(5),M(r.openMenu()==="push"?30:-1))},styles:[`.toolbar[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:16px;flex:none;height:42px;padding:0 12px;background:var(--bg-alt);border-bottom:1px solid var(--border)}.group[_ngcontent-%COMP%]{display:flex;align-items:center;gap:12px;min-width:0}.label[_ngcontent-%COMP%]{font-size:12px;font-weight:600;color:var(--text-bright);-webkit-user-select:none;user-select:none;white-space:nowrap}.select[_ngcontent-%COMP%]{appearance:none;height:26px;padding:0 26px 0 10px;border:1px solid var(--border);border-radius:4px;background:#2d2d2d url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%23cccccc' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 8px center;color:var(--text);font-size:12px;cursor:pointer;outline:none;max-width:260px;text-overflow:ellipsis}.select[_ngcontent-%COMP%]:hover{border-color:#555}.select[_ngcontent-%COMP%]:focus{border-color:var(--accent)}.checkbox[_ngcontent-%COMP%]{display:flex;align-items:center;gap:6px;font-size:12px;font-weight:600;color:var(--text-bright);-webkit-user-select:none;user-select:none;cursor:pointer;white-space:nowrap}.checkbox[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{accent-color:var(--accent);cursor:pointer}.icon-btn[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;width:28px;height:28px;border:none;border-radius:4px;background:transparent;color:var(--text);cursor:pointer;flex:none}.action-menu[_ngcontent-%COMP%]{position:relative;display:inline-flex}.remote-menu[_ngcontent-%COMP%]{position:absolute;top:calc(100% + 4px);right:0;z-index:20;min-width:132px;padding:4px;background:var(--bg-alt);border:1px solid var(--border);border-radius:4px;box-shadow:0 6px 18px #00000073}.remote-menu[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{display:block;width:100%;padding:6px 10px;border:none;border-radius:3px;background:transparent;color:var(--text);font:inherit;text-align:left;white-space:nowrap;cursor:pointer}.remote-menu[_ngcontent-%COMP%] button[_ngcontent-%COMP%]:hover{background:var(--bg-hover);color:var(--text-bright)}.remote-menu[_ngcontent-%COMP%] button.danger[_ngcontent-%COMP%]{color:var(--red)}.remote-menu[_ngcontent-%COMP%] button.danger[_ngcontent-%COMP%]:hover{background:#f487711f;color:#f48771}.icon-btn[_ngcontent-%COMP%]:hover{background:var(--bg-hover);color:var(--text-bright)}.icon-btn[_ngcontent-%COMP%]:disabled{opacity:.45;cursor:default}.icon-btn[_ngcontent-%COMP%] svg[_ngcontent-%COMP%]{width:15px;height:15px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}`],changeDetection:0})};function yx(t,e){if(t&1){let n=$();g(0,"div",13),y(1),g(2,"button",20),T("click",function(){C(n);let o=h();return D(o.refresh())}),y(3,"Retry"),v()()}if(t&2){let n=h();d(),Z("",n.error()," "),d(),A("disabled",n.loading())}}function _x(t,e){if(t&1){let n=$();g(0,"div",14),y(1),g(2,"button",20),T("click",function(){C(n);let o=h();return D(o.refreshWorking())}),y(3,"Retry status"),v()()}if(t&2){let n=h();d(),Z("",n.statusError()," "),d(),A("disabled",n.statusLoading())}}function bx(t,e){if(t&1){let n=$();g(0,"app-working-panel",23),T("subjectChange",function(o){C(n);let i=h(2);return D(i.commitSubject.set(o))})("descriptionChange",function(o){C(n);let i=h(2);return D(i.commitDescription.set(o))})("stageChange",function(o){C(n);let i=h(2);return D(i.changeStage(o))})("stashChange",function(o){C(n);let i=h(2);return D(i.stashChanges(o))})("discardRequest",function(o){C(n);let i=h(2);return D(i.discardUnstaged(o))})("commitRequested",function(){C(n);let o=h(2);return D(o.commitChanges())})("retry",function(){C(n);let o=h(2);return D(o.refreshWorking())})("closed",function(){C(n);let o=h(2);return D(o.selectedCommit.set(null))}),v()}if(t&2){let n=h(2);A("changes",n.workingChanges())("busy",n.busy()||n.mutationBusy()||n.statusLoading())("statusLoading",n.statusLoading())("statusError",n.statusError())("subject",n.commitSubject())("description",n.commitDescription())}}function Cx(t,e){if(t&1){let n=$();g(0,"app-commit-detail",24),T("closed",function(){C(n);let o=h(2);return D(o.selectedCommit.set(null))}),v()}if(t&2){let n=h();A("commit",n)}}function Dx(t,e){if(t&1&&I(0,bx,1,6,"app-working-panel",21)(1,Cx,1,1,"app-commit-detail",22),t&2){let n=h();M(e.hash===n.workingHash?0:1)}}function Ex(t,e){if(t&1){let n=$();g(0,"app-create-pr-dialog",25),T("closed",function(){C(n);let o=h();return D(o.prDialogOpen.set(!1))})("created",function(){C(n);let o=h();return D(o.onPrCreated())}),v()}if(t&2){let n=h();A("branches",n.branches())}}var Ad=500,hv="guito.commitDraft";function wx(){let t=Fa(hv,{});return{subject:typeof t.subject=="string"?t.subject:"",description:typeof t.description=="string"?t.description:""}}var qa=class t{git=_(Lt);workingHash=Et;mutationBusy=this.git.mutating;statusLoading=b(!1);statusError=b("");commitDraft=wx();commitSubject=b(this.commitDraft.subject);commitDescription=b(this.commitDraft.description);displayedCommits=b([]);searchLoading=b(!1);historyGeneration=b(0);filterFailed=b(!1);tableLoading=U(()=>this.loading()?"Refreshing commits...":this.searchLoading()||this.search().trim()&&this.historyLoading()?"Searching commits...":this.historyLoading()?"Loading history...":"");commits=b([]);branches=b([]);selectedBranch=b("");showRemote=b(!0);search=b("");selectedCommit=b(null);loading=b(!1);busy=b(!1);error=b("");repoName=b("");identity=b({name:"",email:""});lastRepositoryState=null;stateSub=null;refreshTimer=window.setInterval(()=>this.checkRepository(),3e3);workingChanges=b(null);totalCommits=b(0);historyLoading=b(!1);contextMenuState=b(null);contextMenuTarget=b(null);promptState=b(null);azureSettings=b(null);hasAzureUrl=U(()=>!!this.azureSettings()?.azureDevOpsUrl);autoReload=U(()=>this.azureSettings()?.autoReload!==!1);prDialogOpen=b(!1);pendingDiscard=b(null);searchFocusHash=b("");pendingSearchHash=b("");scrollRequest=b(null);scrollRequestCounter=0;bodyMatches=b([]);refreshSub=null;historySub=null;workingSub=null;searchSub=null;unloadedCommits=U(()=>Math.max(0,this.totalCommits()-this.commits().length));commitIndex=U(()=>{let e=new Map;for(let n of this.commits())e.set(n.hash,n);return e});filteredCommits=U(()=>{let e=this.commits(),n=this.selectedBranch(),r=this.branches().filter(i=>this.showRemote()||!i.remote),o=n?r.filter(i=>i.name===n):r;if(o.length>0){let i=new Set;for(let s of o)for(let a of this.ancestorsOf(s.commit))i.add(a);e=e.filter(s=>i.has(s.hash))}else e=[];return e});searchMatches=U(()=>{let e=this.search().trim().toLowerCase();if(!e)return[];let n=new Set(this.bodyMatches()),r=this.filteredCommits().filter(s=>s.message.toLowerCase().includes(e)||s.author_name.toLowerCase().includes(e)||s.hash.toLowerCase().startsWith(e)||n.has(s.hash)).map(s=>s.hash),o=new Set(r),i=this.bodyMatches().filter(s=>!o.has(s));return[...r,...i]});searchIndex=U(()=>{let e=this.searchFocusHash();return e?this.searchMatches().indexOf(e):-1});constructor(){this.refresh(),Me(()=>{let e=this.search().trim();this.selectedBranch(),this.historyGeneration(),ke(()=>{this.searchSub?.unsubscribe(),this.searchLoading.set(!1),this.bodyMatches.set([]),this.filterFailed.set(!1),this.error.set(""),this.searchFocusHash.set(""),this.pendingSearchHash.set(""),!this.loading()&&(this.selectedBranch()&&this.unloadedCommits()>0&&this.loadAllCommits(),e&&this.fetchBodyMatches(e))})}),Me(()=>{!this.loading()&&!this.searchLoading()&&!this.historyLoading()&&!this.filterFailed()&&this.displayedCommits.set(this.filteredCommits())}),Me(()=>{let e=this.pendingSearchHash();if(!e)return;let n=this.displayedCommits().find(r=>r.hash===e);n?ke(()=>{this.selectedCommit.set(n),this.scrollRequestCounter+=1,this.scrollRequest.set({hash:e,id:this.scrollRequestCounter}),this.pendingSearchHash.set("")}):this.unloadedCommits()>0&&!this.historyLoading()&&!this.loading()?ke(()=>this.loadMoreCommits()):!this.historyLoading()&&!this.loading()&&this.pendingSearchHash.set("")}),Me(()=>{La(hv,{subject:this.commitSubject(),description:this.commitDescription()})})}ngOnDestroy(){window.clearInterval(this.refreshTimer),this.stateSub?.unsubscribe(),this.refreshSub?.unsubscribe(),this.historySub?.unsubscribe(),this.workingSub?.unsubscribe(),this.searchSub?.unsubscribe()}checkRepository(){!this.autoReload()||document.hidden||this.loading()||this.historyLoading()||this.statusLoading()||this.busy()||this.mutationBusy()||this.stateSub&&!this.stateSub.closed||(this.stateSub=this.git.getRepositoryState().subscribe({next:e=>{if(this.loading()||this.historyLoading()||this.statusLoading()||this.busy()||this.mutationBusy())return;let n=this.lastRepositoryState;this.lastRepositoryState=e,!n||n.history!==e.history?this.refresh(!0):n.working!==e.working&&this.refreshWorking()},error:()=>{}}))}refresh(e=!1){this.historySub?.unsubscribe(),this.workingSub?.unsubscribe(),this.searchSub?.unsubscribe(),this.searchLoading.set(!1),this.filterFailed.set(!1),this.statusLoading.set(!0),this.historyLoading.set(!1),this.loading.set(!0),this.error.set(""),this.refreshSub?.unsubscribe(),this.refreshSub=mc({history:this.git.getCommits(e?Math.max(Ad,this.commits().length):Ad),branches:this.git.getAllBranches(),repo:this.git.getRepoInfo(),settings:this.git.getSettings().pipe(It(()=>Se(null))),working:this.git.getWorkingChanges().pipe(It(n=>(this.lastRepositoryState=null,this.statusError.set(this.errorMessage(n)),Se(null))))}).subscribe({next:({history:n,branches:r,repo:o,settings:i,working:s})=>{this.commits.set(n.commits),this.totalCommits.set(Math.max(n.total,n.commits.length)),this.branches.set(r),this.repoName.set(o.name),this.identity.set(o.identity??{name:"",email:""}),this.selectedBranch()&&!r.some(c=>c.name===this.selectedBranch())&&this.selectedBranch.set("");let a=this.selectedCommit();if(a&&a.hash!==Et){let c=n.commits.find(l=>l.hash===a.hash);c&&this.selectedCommit.set(K(K({},a),c))}i&&this.azureSettings.set(i),s&&(this.workingChanges.set(s),this.statusError.set("")),this.statusLoading.set(!1),this.loading.set(!1),this.historyGeneration.update(c=>c+1)},error:n=>{this.lastRepositoryState=null,this.error.set(this.errorMessage(n)),this.filterFailed.set(!0),this.statusError.set(this.errorMessage(n)),this.statusLoading.set(!1),this.loading.set(!1)}})}refreshWorking(){this.workingSub?.unsubscribe(),this.statusLoading.set(!0),this.workingSub=this.git.getWorkingChanges().subscribe({next:e=>{this.workingChanges.set(e),this.statusError.set(""),this.statusLoading.set(!1)},error:e=>{this.lastRepositoryState=null,this.statusError.set(this.errorMessage(e)),this.statusLoading.set(!1)}})}changeStage(e){this.busy()||this.mutationBusy()||this.statusLoading()||this.statusError()||(this.busy.set(!0),this.error.set(""),(e.staged?this.git.unstage(e.files):this.git.stage(e.files)).subscribe({next:()=>{this.refreshWorking(),this.busy.set(!1)},error:n=>{this.error.set(this.errorMessage(n)),this.refreshWorking(),this.busy.set(!1)}}))}stashChanges(e){this.busy()||this.mutationBusy()||this.statusLoading()||this.statusError()||this.git.stashSave(void 0,e).subscribe({next:()=>this.refresh(),error:n=>this.error.set(this.errorMessage(n))})}discardUnstaged(e){this.busy()||this.mutationBusy()||this.statusLoading()||this.statusError()||e.length&&(this.pendingDiscard.set(e),this.promptState.set({title:"Discard unstaged changes?",label:e.length===1?`${e[0]} will be discarded. This cannot be undone.`:`${e.length} files will be discarded. This cannot be undone.`,confirmOnly:!0,okLabel:"Discard",danger:!0}))}onPromptCancel(){this.pendingDiscard.set(null),this.promptState.set(null)}commitChanges(){this.busy()||this.mutationBusy()||this.statusLoading()||this.statusError()||!this.commitSubject().trim()||!this.workingChanges()?.staged.length||this.workingChanges()?.conflicted.length||(this.busy.set(!0),this.error.set(""),this.git.commit(this.commitSubject(),this.commitDescription()).subscribe({next:()=>{this.commitSubject.set(""),this.commitDescription.set(""),this.refresh(),this.busy.set(!1)},error:e=>{this.error.set(this.errorMessage(e)),this.refreshWorking(),this.busy.set(!1)}}))}loadMoreCommits(){this.loadHistory(this.git.getCommits(Ad,this.commits().length))}loadAllCommits(){this.loadHistory(this.git.getCommits(void 0,this.commits().length))}loadHistory(e){if(this.historyLoading()||this.loading())return;let n=this.commits().length;this.filterFailed.set(!1),this.historyLoading.set(!0),this.historySub?.unsubscribe(),this.historySub=e.subscribe({next:({commits:r,total:o})=>{this.commits().length===n&&(this.commits.update(i=>[...i,...r]),this.totalCommits.set(r.length>0?Math.max(o,this.commits().length):this.commits().length)),this.historyLoading.set(!1)},error:r=>{this.error.set(this.errorMessage(r)),this.filterFailed.set(!0),this.historyLoading.set(!1)}})}fetchBodyMatches(e){this.searchSub?.unsubscribe(),this.searchLoading.set(!0),this.searchSub=this.git.searchCommits(e).subscribe({next:n=>{this.bodyMatches.set(n.hashes),this.searchLoading.set(!1)},error:n=>{this.filterFailed.set(!0),this.error.set(this.errorMessage(n)),this.searchLoading.set(!1)}})}navigateSearch(e){let n=this.searchMatches();if(n.length===0)return;let r=this.searchIndex(),o=r<0?e==="next"?0:n.length-1:e==="next"?(r+1)%n.length:(r-1+n.length)%n.length,i=n[o];this.searchFocusHash.set(i),this.pendingSearchHash.set(i)}onRemoteToggle(e){this.showRemote.set(e)}runRemoteAction(e){if(this.busy()||this.mutationBusy()||this.statusLoading())return;if(e==="rebase-from"){this.openRebaseFromDialog();return}if(e==="create-pr"){this.prDialogOpen.set(!0);return}if(e==="push-force"){this.promptState.set({title:"Force push?",label:"This will overwrite the remote branch with your local history. Remote commits missing locally may be lost.",confirmOnly:!0,okLabel:"Force Push",danger:!0});return}this.busy.set(!0),this.error.set(""),(e==="fetch"?this.git.fetch():e==="pull"?this.git.pull():e==="pull-rebase"?this.git.pull(!0):e==="push"?this.git.push():this.git.sync()).subscribe({next:()=>{this.busy.set(!1),this.refresh()},error:r=>{this.busy.set(!1),this.error.set(this.errorMessage(r))}})}openRebaseFromDialog(){let e=new Set(this.branches().map(o=>o.name)),n=["origin/main","origin/master"].filter(o=>e.has(o));n.forEach(o=>e.delete(o));let r=[...n,...e];r.length===0&&r.push("origin/main","origin/master"),this.promptState.set({title:"Rebase from branch",label:"Rebase the current branch onto:",options:r.map(o=>({value:o,label:o})),okLabel:"Rebase",searchable:!0})}openAzureSettings(){let e=this.azureSettings(),n=e?.source==="vscode"?"Base URL of your Azure DevOps Server, e.g. https://server/DefaultCollection. Currently provided by the VS Code setting guito.azureDevOpsUrl; a value saved here applies only while that setting is empty.":"Base URL of your Azure DevOps Server, e.g. https://server/DefaultCollection. Leave empty to disable pull request creation.";this.promptState.set({title:"Azure DevOps URL",label:n,value:e?.azureDevOpsUrl??"",placeholder:"https://server/DefaultCollection",allowEmpty:!0,okLabel:"Save"})}onPrCreated(){this.refresh()}onContextMenu(e){let n=[];if(e.target.kind==="commit")n.push({label:"Add Tag...",action:"add-tag"}),n.push({label:"Create Branch...",action:"create-branch"}),n.push({separator:!0}),n.push({label:"Checkout...",action:"checkout-commit"}),n.push({label:"Cherry Pick...",action:"cherry-pick"}),n.push({label:"Revert...",action:"revert-commit",danger:!0}),n.push({label:"Drop...",action:"drop-commit",danger:!0}),n.push({separator:!0}),n.push({label:"Merge into current branch...",action:"merge-commit"}),n.push({label:"Rebase current branch on this Commit...",action:"rebase-commit"}),n.push({label:"Reset current branch to this Commit...",action:"reset-commit",danger:!0}),n.push({separator:!0}),n.push({label:"Copy Commit Hash to Clipboard",action:"copy-hash"}),n.push({label:"Copy Commit Subject to Clipboard",action:"copy-subject"});else if(e.target.kind==="tag")n.push({label:"View Details",action:"tag-details"}),n.push({separator:!0}),n.push({label:"Delete Tag...",action:"tag-delete",danger:!0}),n.push({label:"Push Tag...",action:"tag-push"}),n.push({separator:!0}),n.push({label:"Create Archive",action:"create-archive"}),n.push({label:"Copy Tag Name to Clipboard",action:"copy-tag-name"});else if(e.target.kind==="branch"){let r=e.target.branch.type,o=r==="head"||r==="local";n.push({label:"Checkout Branch...",action:"checkout-branch"}),o&&(n.push({label:"Rename Branch...",action:"rename-branch"}),n.push({label:"Delete Branch...",action:"delete-branch",danger:!0,disabled:r==="head"})),n.push({label:"Delete Remote Branch...",action:"delete-remote-branch",danger:!0}),n.push({label:"Merge into current branch...",action:"merge-branch"}),n.push({label:"Pull into current branch...",action:"pull-branch"}),n.push({separator:!0}),n.push({label:"Create Archive",action:"create-archive"}),n.push({label:"Unselect in Branches Dropdown",action:"unselect-branch"}),n.push({separator:!0}),n.push({label:"Copy Branch Name to Clipboard",action:"copy-branch-name"})}else n.push({label:"Stash uncommitted changes...",action:"stash-working"}),n.push({label:"Reset uncommitted changes...",action:"reset-working",danger:!0}),n.push({label:"Clean untracked files...",action:"clean-untracked",danger:!0}),n.push({separator:!0}),n.push({label:"Open Source Control View",action:"open-source-control"});this.contextMenuTarget.set(e.target),this.contextMenuState.set({x:e.x,y:e.y,items:n})}onContextAction(e){if(this.busy()||this.mutationBusy()||this.statusLoading())return;let n=this.contextMenuTarget()?.commit??this.selectedCommit();switch(e){case"add-tag":this.promptState.set({title:"Add Tag",label:"Tag name",placeholder:"v1.0.0",okLabel:"Add Tag"});break;case"create-branch":this.promptState.set({title:"Create Branch",label:"Branch name",placeholder:"feature/my-branch",okLabel:"Create Branch"});break;case"checkout-commit":n&&this.git.checkout(n.hash).subscribe({next:()=>this.refresh(),error:r=>this.error.set(this.errorMessage(r))});break;case"cherry-pick":n&&this.git.cherryPick(n.hash).subscribe({next:()=>this.refresh(),error:r=>this.error.set(this.errorMessage(r))});break;case"open-commit":this.selectedCommit()===null&&this.selectedCommit.set(this.commits()[0]??null);break;case"copy-hash":n&&navigator.clipboard?.writeText(n.hash);break;case"copy-subject":n&&navigator.clipboard?.writeText(n.message);break;case"view-commit-diff":n&&this.selectedCommit.set(n);break;case"revert-commit":n&&this.git.revert(n.hash).subscribe({next:()=>this.refresh(),error:r=>this.error.set(this.errorMessage(r))});break;case"drop-commit":this.promptState.set({title:"Drop commit?",label:"This will reset the current branch to the commit before it.",confirmOnly:!0,okLabel:"Drop",danger:!0});break;case"merge-commit":n&&this.git.merge(n.hash).subscribe({next:()=>this.refresh(),error:r=>this.error.set(this.errorMessage(r))});break;case"rebase-commit":n&&this.git.rebase(n.hash).subscribe({next:()=>this.refresh(),error:r=>this.error.set(this.errorMessage(r))});break;case"reset-commit":this.promptState.set({title:"Reset current branch to this commit?",label:"Choose the reset type:",options:[{value:"soft",label:"Soft",description:"Keep all changes staged"},{value:"mixed",label:"Mixed",description:"Keep changes, but unstage them"},{value:"hard",label:"Hard",description:"Discard all changes",danger:!0}],okLabel:"Reset",danger:!0});break;case"checkout-branch":this.contextMenuTarget()?.branch?.name&&this.git.checkout(this.contextMenuTarget().branch.name).subscribe({next:()=>this.refresh(),error:r=>this.error.set(this.errorMessage(r))});break;case"delete-remote-branch":{let r=this.contextMenuTarget()?.branch?.name??"",o=r.indexOf("/");o>0&&this.git.deleteRemoteBranch(r.slice(0,o),r.slice(o+1)).subscribe({next:()=>this.refresh(),error:i=>this.error.set(this.errorMessage(i))});break}case"merge-branch":this.contextMenuTarget()?.branch?.name&&this.git.merge(this.contextMenuTarget().branch.name).subscribe({next:()=>this.refresh(),error:r=>this.error.set(this.errorMessage(r))});break;case"pull-branch":this.git.pull().subscribe({next:()=>this.refresh(),error:r=>this.error.set(this.errorMessage(r))});break;case"create-archive":{let r=this.contextMenuTarget(),o=r?.kind==="tag"?r.branch?.name:r?.commit?.hash;o&&window.open(Zm(`/api/archive?ref=${encodeURIComponent(o)}`),"_blank");break}case"tag-details":this.contextMenuTarget()?.commit&&this.selectedCommit.set(this.contextMenuTarget().commit);break;case"tag-delete":{let r=this.contextMenuTarget()?.branch?.name??"";this.promptState.set({title:"Delete tag?",label:`This will delete the tag "${r}".`,confirmOnly:!0,okLabel:"Delete",danger:!0});break}case"tag-push":{let r=this.contextMenuTarget()?.branch?.name??"";this.promptState.set({title:"Push tag?",label:`This will push the tag "${r}" to the remote.`,confirmOnly:!0,okLabel:"Push"});break}case"copy-tag-name":this.contextMenuTarget()?.branch?.name&&navigator.clipboard?.writeText(this.contextMenuTarget().branch.name);break;case"unselect-branch":this.selectedBranch.set("");break;case"copy-branch-name":this.contextMenuTarget()?.branch?.name&&navigator.clipboard?.writeText(this.contextMenuTarget().branch.name);break;case"rename-branch":this.promptState.set({title:"Rename branch",label:"New branch name",placeholder:"feature/my-branch",value:this.contextMenuTarget()?.branch?.name,okLabel:"Rename"});break;case"delete-branch":this.promptState.set({title:"Delete branch?",label:"This will delete the local branch.",confirmOnly:!0,okLabel:"Delete",danger:!0});break;case"open-working":this.selectedCommit.set({hash:Et,date:new Date().toISOString(),message:"Uncommitted changes",refs:"",body:"",author_name:this.identity().name||"You",author_email:this.identity().email,parents:[]});break;case"stash-working":this.promptState.set({title:"Stash uncommitted changes",label:"Stash message (optional)",placeholder:"WIP",allowEmpty:!0,okLabel:"Stash"});break;case"reset-working":this.promptState.set({title:"Reset uncommitted changes?",label:"Tracked changes will be discarded. Untracked files will remain.",confirmOnly:!0,okLabel:"Reset",danger:!0});break;case"clean-untracked":this.promptState.set({title:"Clean untracked files?",label:"Untracked files will be permanently deleted.",confirmOnly:!0,okLabel:"Clean",danger:!0});break;case"discard-working":this.git.getWorkingChanges().subscribe({next:r=>{let o=[...r.files.map(i=>i.path),...r.untracked];o.length>0&&this.git.discard(o).subscribe({next:()=>this.refreshWorking(),error:i=>this.error.set(this.errorMessage(i))})},error:r=>this.error.set(this.errorMessage(r))});break;case"refresh-status":this.refresh();break;case"open-source-control":window.open("vscode://command/workbench.view.scm","_blank");break;default:break}this.contextMenuState.set(null)}onPromptConfirm(e){if(this.busy()||this.mutationBusy()||this.statusLoading())return;let n=this.promptState();if(!n)return;this.promptState.set(null);let r=this.contextMenuTarget()?.commit;if(n.title==="Add Tag"&&r){this.git.createTag(e,r.hash).subscribe({next:()=>this.refresh(),error:o=>this.error.set(this.errorMessage(o))});return}if(n.title==="Create Branch"&&r){this.git.createBranch(e,r.hash).subscribe({next:()=>this.refresh(),error:o=>this.error.set(this.errorMessage(o))});return}if(n.title==="Drop commit?"&&r){this.git.dropCommit(r.hash).subscribe({next:()=>this.refresh(),error:o=>this.error.set(this.errorMessage(o))});return}if(n.title==="Reset current branch to this commit?"&&r){let o=e==="soft"||e==="mixed"?e:"hard";this.git.resetToCommit(r.hash,o).subscribe({next:()=>this.refresh(),error:i=>this.error.set(this.errorMessage(i))});return}if(n.title==="Delete tag?"){let o=this.contextMenuTarget()?.branch?.name;o&&this.git.deleteTag(o).subscribe({next:()=>this.refresh(),error:i=>this.error.set(this.errorMessage(i))});return}if(n.title==="Push tag?"){let o=this.contextMenuTarget()?.branch?.name;o&&this.git.pushTag(o).subscribe({next:()=>this.refresh(),error:i=>this.error.set(this.errorMessage(i))});return}if(n.title==="Force push?"){this.git.push(!0).subscribe({next:()=>this.refresh(),error:o=>this.error.set(this.errorMessage(o))});return}if(n.title==="Discard unstaged changes?"){let o=this.pendingDiscard();this.pendingDiscard.set(null),o?.length&&this.git.discard(o,"unstaged").subscribe({next:()=>this.refreshWorking(),error:i=>this.error.set(this.errorMessage(i))});return}if(n.title==="Stash uncommitted changes"){this.git.stashSave(e||void 0).subscribe({next:()=>this.refresh(),error:o=>this.error.set(this.errorMessage(o))});return}if(n.title==="Reset uncommitted changes?"){this.git.resetWorking().subscribe({next:()=>this.refreshWorking(),error:o=>this.error.set(this.errorMessage(o))});return}if(n.title==="Clean untracked files?"){this.git.cleanUntracked().subscribe({next:()=>this.refreshWorking(),error:o=>this.error.set(this.errorMessage(o))});return}if(n.title==="Rename branch"){let o=this.contextMenuTarget()?.branch?.name,i=e.trim();o&&i&&i!==o&&this.git.renameBranch(o,i).subscribe({next:()=>{this.selectedBranch()===o&&this.selectedBranch.set(i),this.refresh()},error:s=>this.error.set(this.errorMessage(s))});return}if(n.title==="Delete branch?"){let o=this.contextMenuTarget()?.branch?.name;o&&this.git.deleteBranch(o).subscribe({next:()=>{this.selectedBranch()===o&&this.selectedBranch.set(""),this.refresh()},error:i=>this.error.set(this.errorMessage(i))});return}if(n.title==="Rebase from branch"){let o=e.trim();o&&this.git.rebase(o).subscribe({next:()=>this.refresh(),error:i=>this.error.set(this.errorMessage(i))});return}if(n.title==="Azure DevOps URL"){this.git.saveSettings(e.trim()).subscribe({next:o=>this.azureSettings.set(o),error:o=>this.error.set(this.errorMessage(o))});return}}ancestorsOf(e){let n=this.commitIndex(),r=new Set,o=[e];for(;o.length;){let i=o.pop();if(r.has(i))continue;r.add(i);let s=n.get(i);s&&o.push(...s.parents)}return r}errorMessage(e){let n=e;return n?.status===400&&n.error?.error?n.error.error:"Failed to communicate with the Guito server."}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=se({type:t,selectors:[["app-root"]],hostBindings:function(n,r){n&1&&T("focus",function(){return r.checkRepository()},gu)("visibilitychange",function(){return r.checkRepository()},qe)},decls:22,vars:24,consts:[[1,"app"],[1,"titlebar"],["aria-label","Repository logo",1,"brand"],["viewBox","0 0 16 16","aria-hidden","true",1,"logo"],["d","M4.5 2.5v11","stroke","#3794ff","stroke-width","1.6","fill","none"],["d","M4.5 11.5c4.5 0 4.5-7 7.5-7","stroke","#4ec9b0","stroke-width","1.6","fill","none"],["cx","4.5","cy","3.5","r","1.7","fill","#3794ff"],["cx","4.5","cy","8","r","1.7","fill","#3794ff"],["cx","4.5","cy","12.5","r","1.7","fill","#3794ff"],["cx","12","cy","4.5","r","1.7","fill","#4ec9b0"],[1,"title"],[3,"searchChange","searchNavigate","matchIndex","matchCount"],[3,"branchChange","remoteToggle","refresh","remoteAction","settingsClick","branches","selectedBranch","showRemote","busy","prEnabled"],[1,"error-banner"],["role","alert",1,"error-banner"],[1,"content"],[3,"commitClick","contextMenu","loadMoreRequested","loadAllRequested","identity","commits","loadingLabel","selectedHash","search","selectedBranch","showRemote","workingChanges","unloaded","historyLoading","scrollToHash"],[3,"select","closed","menu"],[3,"confirmed","cancelled","state"],[3,"branches"],["type","button",3,"click","disabled"],[3,"changes","busy","statusLoading","statusError","subject","description"],[3,"commit"],[3,"subjectChange","descriptionChange","stageChange","stashChange","discardRequest","commitRequested","retry","closed","changes","busy","statusLoading","statusError","subject","description"],[3,"closed","commit"],[3,"closed","created","branches"]],template:function(n,r){if(n&1&&(g(0,"div",0)(1,"header",1)(2,"div",2),X(),g(3,"svg",3),be(4,"path",4)(5,"path",5)(6,"circle",6)(7,"circle",7)(8,"circle",8)(9,"circle",9),v(),xe(),g(10,"span",10),y(11,"Guito"),v()(),g(12,"app-search-box",11),T("searchChange",function(i){return r.search.set(i)})("searchNavigate",function(i){return r.navigateSearch(i)}),v()(),g(13,"app-toolbar",12),T("branchChange",function(i){return r.selectedBranch.set(i)})("remoteToggle",function(i){return r.onRemoteToggle(i)})("refresh",function(){return r.refresh()})("remoteAction",function(i){return r.runRemoteAction(i)})("settingsClick",function(){return r.openAzureSettings()}),v(),I(14,yx,4,2,"div",13),I(15,_x,4,2,"div",14),g(16,"main",15)(17,"app-commit-table",16),T("commitClick",function(i){return r.selectedCommit.set(i)})("contextMenu",function(i){return r.onContextMenu(i)})("loadMoreRequested",function(){return r.loadMoreCommits()})("loadAllRequested",function(){return r.loadAllCommits()}),v(),I(18,Dx,2,1),v(),g(19,"app-context-menu",17),T("select",function(i){return r.onContextAction(i)})("closed",function(){return r.contextMenuState.set(null)}),v(),g(20,"app-prompt-dialog",18),T("confirmed",function(i){return r.onPromptConfirm(i)})("cancelled",function(){return r.onPromptCancel()}),v(),I(21,Ex,1,1,"app-create-pr-dialog",19),v()),n&2){let o,i,s;d(12),A("matchIndex",r.searchIndex())("matchCount",r.searchMatches().length),d(),A("branches",r.branches())("selectedBranch",r.selectedBranch())("showRemote",r.showRemote())("busy",r.busy()||r.mutationBusy()||r.statusLoading())("prEnabled",r.hasAzureUrl()),d(),M(r.error()?14:-1),d(),M(r.statusError()&&((o=r.selectedCommit())==null?null:o.hash)!==r.workingHash?15:-1),d(2),A("identity",r.identity())("commits",r.displayedCommits())("loadingLabel",r.tableLoading())("selectedHash",((i=r.selectedCommit())==null?null:i.hash)??"")("search",r.search())("selectedBranch",r.selectedBranch())("showRemote",r.showRemote())("workingChanges",r.workingChanges())("unloaded",r.unloadedCommits())("historyLoading",r.historyLoading())("scrollToHash",r.scrollRequest()),d(),M((s=r.selectedCommit())?18:-1,s),d(),A("menu",r.contextMenuState()),d(),A("state",r.promptState()),d(),M(r.prDialogOpen()?21:-1)}},dependencies:[Ga,ja,Ta,Va,Ua,Wa,$a,za],styles:[".app[_ngcontent-%COMP%]{display:flex;flex-direction:column;height:100vh;overflow:hidden}.titlebar[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;flex:none;height:38px;padding:0 14px;background:var(--bg-alt);border-bottom:1px solid var(--border)}.brand[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px}.logo[_ngcontent-%COMP%]{width:18px;height:18px}.title[_ngcontent-%COMP%]{font-size:13px;font-weight:600;color:var(--text-bright);letter-spacing:.2px}.repo[_ngcontent-%COMP%]{font-size:12px;color:var(--text-dim)}.error-banner[_ngcontent-%COMP%]{flex:none;padding:8px 14px;background:#5a1d1d;color:#f48771;border-bottom:1px solid #7a2d2d;font-size:12px}.content[_ngcontent-%COMP%]{display:flex;flex:1;min-height:0}.loading-overlay[_ngcontent-%COMP%]{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;background:#1e1e1e8c;z-index:100}.spinner[_ngcontent-%COMP%]{width:28px;height:28px;border:3px solid rgba(255,255,255,.15);border-top-color:var(--accent);border-radius:50%;animation:_ngcontent-%COMP%_spin .8s linear infinite}@keyframes _ngcontent-%COMP%_spin{to{transform:rotate(360deg)}}"],changeDetection:0})};_d(qa,Ym).catch(t=>console.error(t));