aiservermanager 0.5.5 → 0.5.7

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.
@@ -1,5 +1,5 @@
1
- import{$ as xe,$a as Qa,$b as Ys,A as Kt,Aa as eo,Ab as Ue,Ac as vd,B as qc,Ba as to,Bb as dt,Bc as $o,C as Vt,Ca as id,Cb as jt,Cc as ir,D as ct,Da as nd,Db as Je,E as Kc,Ea as od,Eb as A,Ec as bd,F as xi,Fa as ad,Fb as er,G as qa,Ga as rd,Gb as D,Gc as nr,H as Bs,Ha as sd,Hb as ce,I as Yc,Ia as ld,Ib as U,Ic as yd,J as zs,Ja as Ct,Jb as at,K as Ka,Ka as Us,Kb as Me,L as ke,La as io,Lb as O,M as We,Ma as cd,Mb as P,N as oe,Na as Gs,Nb as md,Nc as Cd,O as Xc,Oa as Xa,Ob as ud,P as di,Pa as Be,Pb as Ks,Q as ae,Qa as c,Qb as Ne,R as nt,Ra as Ye,Rb as He,S as re,Sa as ot,Sb as p,T as z,Ta as ve,Tb as et,U as C,Ua as b,Ub as m,V as ne,Va as y,Vb as q,W as d,Wa as zo,Wb as he,X as Bo,Xa as de,Xb as Mn,Y as Zc,Ya as Za,Yb as J,Z as mi,Za as Xe,Zb as jo,_ as Qc,_a as $s,_b as Ho,a as V,aa as we,ab as T,ac as Xs,b as Oe,ba as wi,bb as j,bc as W,c as ye,ca as js,cb as k,cc as pt,d as De,da as X,db as Ws,dc as Di,e as yt,ea as $,eb as qs,ec as hd,f as Gc,fa as Bt,fb as dd,fc as no,g as I,ga as K,gb as Q,gc as Uo,h as Xn,ha as H,hb as ze,hc as pd,i as Ha,ia as kn,ib as Ja,ic as Go,j as Ns,ja as R,jb as Qi,jc as te,k as Ls,ka as Sn,kb as Z,kc as fd,l as Ua,la as Jc,lb as M,lc as gd,m as $c,ma as Qn,mb as E,mc as L,n as ge,na as Pi,nb as xt,nc as wt,o as Ga,oa as Jn,ob as me,oc as _d,p as Vs,pa as ed,pb as ue,pc as tr,q as Te,qa as zt,qb as x,r as Pe,ra as Xi,rb as s,s as Zn,sa as Hs,sb as l,t as Wc,ta as Se,tb as v,u as Yi,ua as _e,ub as Ie,v as $a,va as Y,vb as je,w as Wa,wa as N,wb as ht,x as $e,xa as Zi,xb as ui,y as Ce,ya as td,yb as hi,z as Vo,za as Ya,zb as Yt}from"./chunk-JGNPKRLU.js";var xd=null;function Xt(){return xd}function Zs(i){xd??=i}var Wo=class{},oo=(()=>{class i{historyGo(e){throw new Error("")}static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:()=>d(wd),providedIn:"platform"})}return i})();var wd=(()=>{class i extends oo{_location;_history;_doc=d($);constructor(){super(),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return Xt().getBaseHref(this._doc)}onPopState(e){let t=Xt().getGlobalEventTarget(this._doc,"window");return t.addEventListener("popstate",e,!1),()=>t.removeEventListener("popstate",e)}onHashChange(e){let t=Xt().getGlobalEventTarget(this._doc,"window");return t.addEventListener("hashchange",e,!1),()=>t.removeEventListener("hashchange",e)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(e){this._location.pathname=e}pushState(e,t,n){this._history.pushState(e,t,n)}replaceState(e,t,n){this._history.replaceState(e,t,n)}forward(){this._history.forward()}back(){this._history.back()}historyGo(e=0){this._history.go(e)}getState(){return this._history.state}static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:()=>new i,providedIn:"platform"})}return i})();function Sd(i,o){return i?o?i.endsWith("/")?o.startsWith("/")?i+o.slice(1):i+o:o.startsWith("/")?i+o:`${i}/${o}`:i:o}function Dd(i){let o=i.search(/#|\?|$/);return i[o-1]==="/"?i.slice(0,o-1)+i.slice(o):i}function Ji(i){return i&&i[0]!=="?"?`?${i}`:i}var or=(()=>{class i{historyGo(e){throw new Error("")}static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:()=>d(Np),providedIn:"root"})}return i})(),Fp=new C(""),Np=(()=>{class i extends or{_platformLocation;_baseHref;_removeListenerFns=[];constructor(e,t){super(),this._platformLocation=e,this._baseHref=t??this._platformLocation.getBaseHrefFromDOM()??d($).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(e){this._removeListenerFns.push(this._platformLocation.onPopState(e),this._platformLocation.onHashChange(e))}getBaseHref(){return this._baseHref}prepareExternalUrl(e){return Sd(this._baseHref,e)}path(e=!1){let t=this._platformLocation.pathname+Ji(this._platformLocation.search),n=this._platformLocation.hash;return n&&e?`${t}${n}`:t}pushState(e,t,n,a){let r=this.prepareExternalUrl(n+Ji(a));this._platformLocation.pushState(e,t,r)}replaceState(e,t,n,a){let r=this.prepareExternalUrl(n+Ji(a));this._platformLocation.replaceState(e,t,r)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(e=0){this._platformLocation.historyGo?.(e)}static \u0275fac=function(t){return new(t||i)(ne(oo),ne(Fp,8))};static \u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var ar=(()=>{class i{_subject=new I;_basePath;_locationStrategy;_urlChangeListeners=[];_urlChangeSubscription=null;constructor(e){this._locationStrategy=e;let t=this._locationStrategy.getBaseHref();this._basePath=Bp(Dd(kd(t))),this._locationStrategy.onPopState(n=>{this._subject.next({url:this.path(!0),pop:!0,state:n.state,type:n.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(e=!1){return this.normalize(this._locationStrategy.path(e))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(e,t=""){return this.path()==this.normalize(e+Ji(t))}normalize(e){return i.stripTrailingSlash(Vp(this._basePath,kd(e)))}prepareExternalUrl(e){return e&&e[0]!=="/"&&(e="/"+e),this._locationStrategy.prepareExternalUrl(e)}go(e,t="",n=null){this._locationStrategy.pushState(n,"",e,t),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+Ji(t)),n)}replaceState(e,t="",n=null){this._locationStrategy.replaceState(n,"",e,t),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+Ji(t)),n)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(e=0){this._locationStrategy.historyGo?.(e)}onUrlChange(e){return this._urlChangeListeners.push(e),this._urlChangeSubscription??=this.subscribe(t=>{this._notifyUrlChangeListeners(t.url,t.state)}),()=>{let t=this._urlChangeListeners.indexOf(e);this._urlChangeListeners.splice(t,1),this._urlChangeListeners.length===0&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(e="",t){this._urlChangeListeners.forEach(n=>n(e,t))}subscribe(e,t,n){return this._subject.subscribe({next:e,error:t??void 0,complete:n??void 0})}static normalizeQueryParams=Ji;static joinWithSlash=Sd;static stripTrailingSlash=Dd;static \u0275fac=function(t){return new(t||i)(ne(or))};static \u0275prov=re({token:i,factory:()=>Lp(),providedIn:"root"})}return i})();function Lp(){return new ar(ne(or))}function Vp(i,o){if(!i||!o.startsWith(i))return o;let e=o.substring(i.length);return e===""||["/",";","?","#"].includes(e[0])?e:o}function kd(i){return i.replace(/\/index\.html$/,"")}function Bp(i){if(new RegExp("^(https?:)?//").test(i)){let[,e]=i.split(/\/\/[^\/]+/);return e}return i}var ol=(function(i){return i[i.Decimal=0]="Decimal",i[i.Percent=1]="Percent",i[i.Currency=2]="Currency",i[i.Scientific=3]="Scientific",i})(ol||{});var ft=(function(i){return i[i.Format=0]="Format",i[i.Standalone=1]="Standalone",i})(ft||{}),Re=(function(i){return i[i.Narrow=0]="Narrow",i[i.Abbreviated=1]="Abbreviated",i[i.Wide=2]="Wide",i[i.Short=3]="Short",i})(Re||{}),Tt=(function(i){return i[i.Short=0]="Short",i[i.Medium=1]="Medium",i[i.Long=2]="Long",i[i.Full=3]="Full",i})(Tt||{}),It={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 Id(i){return jt(i)[Je.LocaleId]}function Rd(i,o,e){let t=jt(i),n=[t[Je.DayPeriodsFormat],t[Je.DayPeriodsStandalone]],a=Zt(n,o);return Zt(a,e)}function Od(i,o,e){let t=jt(i),n=[t[Je.DaysFormat],t[Je.DaysStandalone]],a=Zt(n,o);return Zt(a,e)}function Pd(i,o,e){let t=jt(i),n=[t[Je.MonthsFormat],t[Je.MonthsStandalone]],a=Zt(n,o);return Zt(a,e)}function Fd(i,o){let t=jt(i)[Je.Eras];return Zt(t,o)}function qo(i,o){let e=jt(i);return Zt(e[Je.DateFormat],o)}function Ko(i,o){let e=jt(i);return Zt(e[Je.TimeFormat],o)}function Yo(i,o){let t=jt(i)[Je.DateTimeFormat];return Zt(t,o)}function ki(i,o){let e=jt(i),t=e[Je.NumberSymbols][o];if(typeof t>"u"){if(o===It.CurrencyDecimal)return e[Je.NumberSymbols][It.Decimal];if(o===It.CurrencyGroup)return e[Je.NumberSymbols][It.Group]}return t}function Nd(i,o){return jt(i)[Je.NumberFormats][o]}function Ld(i){if(!i[Je.ExtraData])throw new ae(2303,!1)}function Vd(i){let o=jt(i);return Ld(o),(o[Je.ExtraData][2]||[]).map(t=>typeof t=="string"?Qs(t):[Qs(t[0]),Qs(t[1])])}function Bd(i,o,e){let t=jt(i);Ld(t);let n=[t[Je.ExtraData][0],t[Je.ExtraData][1]],a=Zt(n,o)||[];return Zt(a,e)||[]}function Zt(i,o){for(let e=o;e>-1;e--)if(typeof i[e]<"u")return i[e];throw new ae(2304,!1)}function Qs(i){let[o,e]=i.split(":");return{hours:+o,minutes:+e}}var zp=/^(\d{4,})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/,rr={},jp=/((?:[^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]*)/,Hp=256;function zd(i,o,e,t){let n=Qp(i);Up(o),o=Fi(e,o)||o;let r=[],u;for(;o;)if(u=jp.exec(o),u){r=r.concat(u.slice(1));let _=r.pop();if(!_)break;o=_}else{r.push(o);break}let h=n.getTimezoneOffset();t&&(h=Hd(t,h),n=Zp(n,t));let g="";return r.forEach(_=>{let w=Yp(_);g+=w?w(n,e,h):_==="''"?"'":_.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),g}function Up(i){if(i.length>Hp)throw new ae(2300,!1)}function mr(i,o,e){let t=new Date(0);return t.setFullYear(i,o,e),t.setHours(0,0,0),t}function Fi(i,o){let e=Id(i);if(rr[e]??={},rr[e][o])return rr[e][o];let t="";switch(o){case"shortDate":t=qo(i,Tt.Short);break;case"mediumDate":t=qo(i,Tt.Medium);break;case"longDate":t=qo(i,Tt.Long);break;case"fullDate":t=qo(i,Tt.Full);break;case"shortTime":t=Ko(i,Tt.Short);break;case"mediumTime":t=Ko(i,Tt.Medium);break;case"longTime":t=Ko(i,Tt.Long);break;case"fullTime":t=Ko(i,Tt.Full);break;case"short":let n=Fi(i,"shortTime"),a=Fi(i,"shortDate");t=sr(Yo(i,Tt.Short),[n,a]);break;case"medium":let r=Fi(i,"mediumTime"),u=Fi(i,"mediumDate");t=sr(Yo(i,Tt.Medium),[r,u]);break;case"long":let h=Fi(i,"longTime"),g=Fi(i,"longDate");t=sr(Yo(i,Tt.Long),[h,g]);break;case"full":let _=Fi(i,"fullTime"),w=Fi(i,"fullDate");t=sr(Yo(i,Tt.Full),[_,w]);break}return t&&(rr[e][o]=t),t}function sr(i,o){return o&&(i=i.replace(/\{([^}]+)}/g,function(e,t){return Object.hasOwn(o,t)?o[t]:e})),i}function pi(i,o,e="-",t,n){let a="";(i<0||n&&i<=0)&&(n?i=-i+1:(i=-i,a=e));let r=String(i);for(;r.length<o;)r="0"+r;return t&&(r=r.slice(r.length-o)),a+r}function Gp(i,o){return pi(i,3).substring(0,o)}function tt(i,o,e=0,t=!1,n=!1){return function(a,r){let u=$p(i,a);if((e>0||u>-e)&&(u+=e),i===3)u===0&&e===-12&&(u=12);else if(i===6)return Gp(u,o);let h=ki(r,It.MinusSign);return pi(u,o,h,t,n)}}function $p(i,o){switch(i){case 0:return o.getFullYear();case 1:return o.getMonth();case 2:return o.getDate();case 3:return o.getHours();case 4:return o.getMinutes();case 5:return o.getSeconds();case 6:return o.getMilliseconds();case 7:return o.getDay();default:throw new ae(2301,!1)}}function Le(i,o,e=ft.Format,t=!1){return function(n,a){return Wp(n,a,i,o,e,t)}}function Wp(i,o,e,t,n,a){switch(e){case 2:return Pd(o,n,t)[i.getMonth()];case 1:return Od(o,n,t)[i.getDay()];case 0:let r=i.getHours(),u=i.getMinutes();if(a){let g=Vd(o),_=Bd(o,n,t),w=g.findIndex(B=>{if(Array.isArray(B)){let[G,ie]=B,fe=r>=G.hours&&u>=G.minutes,se=r<ie.hours||r===ie.hours&&u<ie.minutes;if(G.hours<ie.hours){if(fe&&se)return!0}else if(fe||se)return!0}else if(B.hours===r&&B.minutes===u)return!0;return!1});if(w!==-1)return _[w]}return Rd(o,n,t)[r<12?0:1];case 3:return Fd(o,t)[i.getFullYear()<=0?0:1];default:let h=e;throw new ae(2302,!1)}}function lr(i){return function(o,e,t){let n=-1*t,a=ki(e,It.MinusSign),r=n>0?Math.floor(n/60):Math.ceil(n/60);switch(i){case 0:return(n>=0?"+":"")+pi(r,2,a)+pi(Math.abs(n%60),2,a);case 1:return"GMT"+(n>=0?"+":"")+pi(r,1,a);case 2:return"GMT"+(n>=0?"+":"")+pi(r,2,a)+":"+pi(Math.abs(n%60),2,a);case 3:return t===0?"Z":(n>=0?"+":"")+pi(r,2,a)+":"+pi(Math.abs(n%60),2,a);default:throw new ae(2310,!1)}}}var qp=0,dr=4;function Kp(i){let o=mr(i,qp,1).getDay();return mr(i,0,1+(o<=dr?dr:dr+7)-o)}function jd(i){let o=i.getDay(),e=o===0?-3:dr-o;return mr(i.getFullYear(),i.getMonth(),i.getDate()+e)}function Js(i,o=!1){return function(e,t){let n;if(o){let a=new Date(e.getFullYear(),e.getMonth(),1).getDay()-1,r=e.getDate();n=1+Math.floor((r+a)/7)}else{let a=jd(e),r=Kp(a.getFullYear()),u=a.getTime()-r.getTime();n=1+Math.round(u/6048e5)}return pi(n,i,ki(t,It.MinusSign))}}function cr(i,o=!1){return function(e,t){let a=jd(e).getFullYear();return pi(a,i,ki(t,It.MinusSign),o)}}var el={};function Yp(i){if(el[i])return el[i];let o;switch(i){case"G":case"GG":case"GGG":o=Le(3,Re.Abbreviated);break;case"GGGG":o=Le(3,Re.Wide);break;case"GGGGG":o=Le(3,Re.Narrow);break;case"y":o=tt(0,1,0,!1,!0);break;case"yy":o=tt(0,2,0,!0,!0);break;case"yyy":o=tt(0,3,0,!1,!0);break;case"yyyy":o=tt(0,4,0,!1,!0);break;case"Y":o=cr(1);break;case"YY":o=cr(2,!0);break;case"YYY":o=cr(3);break;case"YYYY":o=cr(4);break;case"M":case"L":o=tt(1,1,1);break;case"MM":case"LL":o=tt(1,2,1);break;case"MMM":o=Le(2,Re.Abbreviated);break;case"MMMM":o=Le(2,Re.Wide);break;case"MMMMM":o=Le(2,Re.Narrow);break;case"LLL":o=Le(2,Re.Abbreviated,ft.Standalone);break;case"LLLL":o=Le(2,Re.Wide,ft.Standalone);break;case"LLLLL":o=Le(2,Re.Narrow,ft.Standalone);break;case"w":o=Js(1);break;case"ww":o=Js(2);break;case"W":o=Js(1,!0);break;case"d":o=tt(2,1);break;case"dd":o=tt(2,2);break;case"c":case"cc":o=tt(7,1);break;case"ccc":o=Le(1,Re.Abbreviated,ft.Standalone);break;case"cccc":o=Le(1,Re.Wide,ft.Standalone);break;case"ccccc":o=Le(1,Re.Narrow,ft.Standalone);break;case"cccccc":o=Le(1,Re.Short,ft.Standalone);break;case"E":case"EE":case"EEE":o=Le(1,Re.Abbreviated);break;case"EEEE":o=Le(1,Re.Wide);break;case"EEEEE":o=Le(1,Re.Narrow);break;case"EEEEEE":o=Le(1,Re.Short);break;case"a":case"aa":case"aaa":o=Le(0,Re.Abbreviated);break;case"aaaa":o=Le(0,Re.Wide);break;case"aaaaa":o=Le(0,Re.Narrow);break;case"b":case"bb":case"bbb":o=Le(0,Re.Abbreviated,ft.Standalone,!0);break;case"bbbb":o=Le(0,Re.Wide,ft.Standalone,!0);break;case"bbbbb":o=Le(0,Re.Narrow,ft.Standalone,!0);break;case"B":case"BB":case"BBB":o=Le(0,Re.Abbreviated,ft.Format,!0);break;case"BBBB":o=Le(0,Re.Wide,ft.Format,!0);break;case"BBBBB":o=Le(0,Re.Narrow,ft.Format,!0);break;case"h":o=tt(3,1,-12);break;case"hh":o=tt(3,2,-12);break;case"H":o=tt(3,1);break;case"HH":o=tt(3,2);break;case"m":o=tt(4,1);break;case"mm":o=tt(4,2);break;case"s":o=tt(5,1);break;case"ss":o=tt(5,2);break;case"S":o=tt(6,1);break;case"SS":o=tt(6,2);break;case"SSS":o=tt(6,3);break;case"Z":case"ZZ":case"ZZZ":o=lr(0);break;case"ZZZZZ":o=lr(3);break;case"O":case"OO":case"OOO":case"z":case"zz":case"zzz":o=lr(1);break;case"OOOO":case"ZZZZ":case"zzzz":o=lr(2);break;default:return null}return el[i]=o,o}function Hd(i,o){i=i.replace(/:/g,"");let e=Date.parse("Jan 01, 1970 00:00:00 "+i)/6e4;return isNaN(e)?o:e}function Xp(i,o){return i=new Date(i.getTime()),i.setMinutes(i.getMinutes()+o),i}function Zp(i,o,e){let n=i.getTimezoneOffset(),a=Hd(o,n);return Xp(i,-1*(a-n))}function Qp(i){if(Md(i))return i;if(typeof i=="number"&&!isNaN(i))return new Date(i);if(typeof i=="string"){if(i=i.trim(),/^(\d{4}(-\d{1,2}(-\d{1,2})?)?)$/.test(i)){let[n,a=1,r=1]=i.split("-").map(u=>+u);return mr(n,a-1,r)}let e=parseFloat(i);if(!isNaN(i-e))return new Date(e);let t;if(t=i.match(zp))return Jp(t)}let o=new Date(i);if(!Md(o))throw new ae(2311,!1);return o}function Jp(i){let o=new Date(0),e=0,t=0,n=i[8]?o.setUTCFullYear:o.setFullYear,a=i[8]?o.setUTCHours:o.setHours;i[9]&&(e=Number(i[9]+i[10]),t=Number(i[9]+i[11])),n.call(o,Number(i[1]),Number(i[2])-1,Number(i[3]));let r=Number(i[4]||0)-e,u=Number(i[5]||0)-t,h=Number(i[6]||0),g=Math.floor(parseFloat("0."+(i[7]||0))*1e3);return a.call(o,r,u,h,g),o}function Md(i){return i instanceof Date&&!isNaN(i.valueOf())}var ef=/^(\d+)?\.((\d+)(-(\d+))?)?$/,Ed=22,ur=".",Xo="0",tf=";",nf=",",tl="#";function of(i,o,e,t,n,a,r=!1){let u="",h=!1;if(!isFinite(i))u=ki(e,It.Infinity);else{let g=sf(i);r&&(g=rf(g));let _=o.minInt,w=o.minFrac,B=o.maxFrac;if(a){let lt=a.match(ef);if(lt===null)throw new ae(2306,!1);let li=lt[1],Ci=lt[3],Ki=lt[5];li!=null&&(_=il(li)),Ci!=null&&(w=il(Ci)),Ki!=null?B=il(Ki):Ci!=null&&w>B&&(B=w);let ci=100;if(_>ci||w>ci||B>ci)throw new ae(2306,!1)}lf(g,w,B);let G=g.digits,ie=g.integerLen,fe=g.exponent,se=[];for(h=G.every(lt=>!lt);ie<_;ie++)G.unshift(0);for(;ie<0;ie++)G.unshift(0);ie>0?se=G.splice(ie,G.length):(se=G,G=[0]);let Ae=[];for(G.length>=o.lgSize&&Ae.unshift(G.splice(-o.lgSize,G.length).join(""));G.length>o.gSize;)Ae.unshift(G.splice(-o.gSize,G.length).join(""));G.length&&Ae.unshift(G.join("")),u=Ae.join(ki(e,t)),se.length&&(u+=ki(e,n)+se.join("")),fe&&(u+=ki(e,It.Exponential)+"+"+fe)}return i<0&&!h?u=o.negPre+u+o.negSuf:u=o.posPre+u+o.posSuf,u}function Ud(i,o,e){let t=Nd(o,ol.Decimal),n=af(t,ki(o,It.MinusSign));return of(i,n,o,It.Group,It.Decimal,e)}function af(i,o="-"){let e={minInt:1,minFrac:0,maxFrac:0,posPre:"",posSuf:"",negPre:"",negSuf:"",gSize:0,lgSize:0},t=i.split(tf),n=t[0],a=t[1],r=n.indexOf(ur)!==-1?n.split(ur):[n.substring(0,n.lastIndexOf(Xo)+1),n.substring(n.lastIndexOf(Xo)+1)],u=r[0],h=r[1]||"";e.posPre=u.substring(0,u.indexOf(tl));for(let _=0;_<h.length;_++){let w=h.charAt(_);w===Xo?e.minFrac=e.maxFrac=_+1:w===tl?e.maxFrac=_+1:e.posSuf+=w}let g=u.split(nf);if(e.gSize=g[1]?g[1].length:0,e.lgSize=g[2]||g[1]?(g[2]||g[1]).length:0,a){let _=n.length-e.posPre.length-e.posSuf.length,w=a.indexOf(tl);e.negPre=a.substring(0,w).replace(/'/g,""),e.negSuf=a.slice(w+_).replace(/'/g,"")}else e.negPre=o+e.posPre,e.negSuf=e.posSuf;return e}function rf(i){if(i.digits[0]===0)return i;let o=i.digits.length-i.integerLen;return i.exponent?i.exponent+=2:(o===0?i.digits.push(0,0):o===1&&i.digits.push(0),i.integerLen+=2),i}function sf(i){let o=Math.abs(i)+"",e=0,t,n,a,r,u;for((n=o.indexOf(ur))>-1&&(o=o.replace(ur,"")),(a=o.search(/e/i))>0?(n<0&&(n=a),n+=+o.slice(a+1),o=o.substring(0,a)):n<0&&(n=o.length),a=0;o.charAt(a)===Xo;a++);if(a===(u=o.length))t=[0],n=1;else{for(u--;o.charAt(u)===Xo;)u--;for(n-=a,t=[],r=0;a<=u;a++,r++)t[r]=Number(o.charAt(a))}return n>Ed&&(t=t.splice(0,Ed-1),e=n-1,n=1),{digits:t,exponent:e,integerLen:n}}function lf(i,o,e){if(o>e)throw new ae(2307,!1);let t=i.digits,n=t.length-i.integerLen,a=Math.min(Math.max(o,n),e),r=a+i.integerLen,u=t[r];if(r>0){t.splice(Math.max(i.integerLen,r));for(let w=r;w<t.length;w++)t[w]=0}else{n=Math.max(0,n),i.integerLen=1,t.length=Math.max(1,r=a+1),t[0]=0;for(let w=1;w<r;w++)t[w]=0}if(u>=5)if(r-1<0){for(let w=0;w>r;w--)t.unshift(0),i.integerLen++;t.unshift(1),i.integerLen++}else t[r-1]++;for(;n<Math.max(0,a);n++)t.push(0);let h=a!==0,g=o+i.integerLen,_=t.reduceRight(function(w,B,G,ie){return B=B+w,ie[G]=B<10?B:B-10,h&&(ie[G]===0&&G>=g?ie.pop():h=!1),B>=10?1:0},0);_&&(t.unshift(_),i.integerLen++)}function il(i){let o=parseInt(i);if(isNaN(o))throw new ae(2305,!1);return o}var nl=/\s+/,Ad=[],al=(()=>{class i{_ngEl;_renderer;initialClasses=Ad;rawClass;stateMap=new Map;constructor(e,t){this._ngEl=e,this._renderer=t}set klass(e){this.initialClasses=e!=null?e.trim().split(nl):Ad}set ngClass(e){this.rawClass=typeof e=="string"?e.trim().split(nl):e}ngDoCheck(){for(let t of this.initialClasses)this._updateState(t,!0);let e=this.rawClass;if(Array.isArray(e)||e instanceof Set)for(let t of e)this._updateState(t,!0);else if(e!=null)for(let t of Object.keys(e))this._updateState(t,!!e[t]);this._applyStateDiff()}_updateState(e,t){let n=this.stateMap.get(e);n!==void 0?(n.enabled!==t&&(n.changed=!0,n.enabled=t),n.touched=!0):this.stateMap.set(e,{enabled:t,changed:!0,touched:!0})}_applyStateDiff(){for(let e of this.stateMap){let t=e[0],n=e[1];n.changed?(this._toggleClass(t,n.enabled),n.changed=!1):n.touched||(n.enabled&&this._toggleClass(t,!1),this.stateMap.delete(t)),n.touched=!1}}_toggleClass(e,t){e=e.trim(),e.length>0&&e.split(nl).forEach(n=>{t?this._renderer.addClass(this._ngEl.nativeElement,n):this._renderer.removeClass(this._ngEl.nativeElement,n)})}static \u0275fac=function(t){return new(t||i)(de(N),de(ve))};static \u0275dir=k({type:i,selectors:[["","ngClass",""]],inputs:{klass:[0,"class","klass"],ngClass:"ngClass"}})}return i})();var rl=(()=>{class i{_viewContainerRef;_viewRef=null;ngTemplateOutletContext=null;ngTemplateOutlet=null;ngTemplateOutletInjector=null;injector=d(X);constructor(e){this._viewContainerRef=e}ngOnChanges(e){if(this._shouldRecreateView(e)){let t=this._viewContainerRef;if(this._viewRef&&t.remove(t.indexOf(this._viewRef)),!this.ngTemplateOutlet){this._viewRef=null;return}let n=this._createContextForwardProxy();this._viewRef=t.createEmbeddedView(this.ngTemplateOutlet,n,{injector:this._getInjector()})}}_getInjector(){return this.ngTemplateOutletInjector==="outlet"?this.injector:this.ngTemplateOutletInjector??void 0}_shouldRecreateView(e){return!!e.ngTemplateOutlet||!!e.ngTemplateOutletInjector}_createContextForwardProxy(){return new Proxy({},{set:(e,t,n)=>this.ngTemplateOutletContext?Reflect.set(this.ngTemplateOutletContext,t,n):!1,get:(e,t,n)=>{if(this.ngTemplateOutletContext)return Reflect.get(this.ngTemplateOutletContext,t,n)}})}static \u0275fac=function(t){return new(t||i)(de(Xe))};static \u0275dir=k({type:i,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet",ngTemplateOutletInjector:"ngTemplateOutletInjector"},features:[Se]})}return i})();function Gd(i,o){return new ae(2100,!1)}var cf="mediumDate",$d=new C(""),Wd=new C(""),sl=(()=>{class i{locale;defaultTimezone;defaultOptions;constructor(e,t,n){this.locale=e,this.defaultTimezone=t,this.defaultOptions=n}transform(e,t,n,a){if(e==null||e===""||e!==e)return null;try{let r=t??this.defaultOptions?.dateFormat??cf,u=n??this.defaultOptions?.timezone??this.defaultTimezone??void 0;return zd(e,r,a||this.locale,u)}catch(r){throw Gd(i,r.message)}}static \u0275fac=function(t){return new(t||i)(de(Xs,16),de($d,24),de(Wd,24))};static \u0275pipe=Ws({name:"date",type:i,pure:!0})}return i})();var ll=(()=>{class i{_locale;constructor(e){this._locale=e}transform(e,t,n){if(!df(e))return null;n||=this._locale;try{let a=mf(e);return Ud(a,n,t)}catch(a){throw Gd(i,a.message)}}static \u0275fac=function(t){return new(t||i)(de(Xs,16))};static \u0275pipe=Ws({name:"number",type:i,pure:!0})}return i})();function df(i){return!(i==null||i===""||i!==i)}function mf(i){if(typeof i=="string"&&!isNaN(Number(i)-parseFloat(i)))return Number(i);if(typeof i!="number")throw new ae(2309,!1);return i}var Ve=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();function Zo(i,o){o=encodeURIComponent(o);for(let e of i.split(";")){let t=e.indexOf("="),[n,a]=t==-1?[e,""]:[e.slice(0,t),e.slice(t+1)];if(n.trim()===o)return decodeURIComponent(a)}return null}var cl="browser";function qd(i){return i===cl}var Qo=class{_doc;constructor(o){this._doc=o}manager},hr=(()=>{class i extends Qo{constructor(e){super(e)}supports(e){return!0}addEventListener(e,t,n,a){return e.addEventListener(t,n,a),()=>this.removeEventListener(e,t,n,a)}removeEventListener(e,t,n,a){return e.removeEventListener(t,n,a)}static \u0275fac=function(t){return new(t||i)(ne($))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})(),gr=new C(""),hl=(()=>{class i{_zone;_plugins;_eventNameToPlugin=new Map;constructor(e,t){this._zone=t,e.forEach(r=>{r.manager=this});let n=e.filter(r=>!(r instanceof hr));this._plugins=n.slice().reverse();let a=e.find(r=>r instanceof hr);a&&this._plugins.push(a)}addEventListener(e,t,n,a){return this._findPluginFor(t).addEventListener(e,t,n,a)}getZone(){return this._zone}_findPluginFor(e){let t=this._eventNameToPlugin.get(e);if(t)return t;if(t=this._plugins.find(a=>a.supports(e)),!t)throw new ae(-5101,!1);return this._eventNameToPlugin.set(e,t),t}static \u0275fac=function(t){return new(t||i)(ne(gr),ne(H))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})(),dl="ng-app-id";function Yd(i){for(let o of i)o.remove()}function Xd(i,o){let e=o.createElement("style");return e.textContent=i,e}function pf(i,o,e,t){let n=i.head?.querySelectorAll(`style[${dl}="${o}"],link[${dl}="${o}"]`);if(!n||n.length===0)return!1;for(let a of n)a.removeAttribute(dl),a instanceof HTMLLinkElement?t.set(a.href.slice(a.href.lastIndexOf("/")+1),{usage:0,elements:[a]}):a.textContent&&e.set(a.textContent,{usage:0,elements:[a]});return!0}function ul(i,o){let e=o.createElement("link");return e.setAttribute("rel","stylesheet"),e.setAttribute("href",i),e}var pl=(()=>{class i{doc;appId;nonce;inline=new Map;external=new Map;hosts=new Set;constructor(e,t,n,a={}){this.doc=e,this.appId=t,this.nonce=n,pf(e,t,this.inline,this.external)&&this.hosts.add(e.head)}addStyles(e,t){for(let n of e)this.addUsage(n,this.inline,Xd);t?.forEach(n=>this.addUsage(n,this.external,ul))}removeStyles(e,t){for(let n of e)this.removeUsage(n,this.inline);t?.forEach(n=>this.removeUsage(n,this.external))}addUsage(e,t,n){let a=t.get(e);a?a.usage++:t.set(e,{usage:1,elements:[...this.hosts].map(r=>this.addElement(r,n(e,this.doc)))})}removeUsage(e,t){let n=t.get(e);n&&(n.usage--,n.usage<=0&&(Yd(n.elements),t.delete(e)))}ngOnDestroy(){for(let[,{elements:e}]of[...this.inline,...this.external])Yd(e);this.hosts.clear()}addHost(e){if(!this.hosts.has(e)){this.hosts.add(e);for(let[t,{elements:n}]of this.inline)n.push(this.addElement(e,Xd(t,this.doc)));for(let[t,{elements:n}]of this.external)n.push(this.addElement(e,ul(t,this.doc)))}}removeHost(e){this.hosts.delete(e);for(let t of[...this.inline.values(),...this.external.values()]){let n=[];for(let a of t.elements)a.parentNode===e?a.remove():n.push(a);t.elements=n}}addElement(e,t){return this.nonce&&t.setAttribute("nonce",this.nonce),e.appendChild(t)}static \u0275fac=function(t){return new(t||i)(ne($),ne(Sn),ne(Jn,8),ne(Qn))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})(),ml={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"},fl=/%COMP%/g;var Qd="%COMP%",ff=`_nghost-${Qd}`,gf=`_ngcontent-${Qd}`,_f=!0,vf=new C("",{factory:()=>_f});function bf(i){return gf.replace(fl,i)}function yf(i){return ff.replace(fl,i)}function Jd(i,o){return o.map(e=>e.replace(fl,i))}var En=(()=>{class i{eventManager;sharedStylesHost;appId;removeStylesOnCompDestroy;doc;ngZone;nonce;tracingService;rendererByCompId=new Map;defaultRenderer;constructor(e,t,n,a,r,u,h=null,g=null){this.eventManager=e,this.sharedStylesHost=t,this.appId=n,this.removeStylesOnCompDestroy=a,this.doc=r,this.ngZone=u,this.nonce=h,this.tracingService=g,this.defaultRenderer=new Jo(e,r,u,this.tracingService)}createRenderer(e,t){if(!e||!t)return this.defaultRenderer;let n=this.getOrCreateRenderer(e,t);return n instanceof fr?n.applyToHost(e):n instanceof ea&&n.applyStyles(),n}getOrCreateRenderer(e,t){let n=this.rendererByCompId,a=n.get(t.id);if(!a){let r=this.doc,u=this.ngZone,h=this.eventManager,g=this.sharedStylesHost,_=this.removeStylesOnCompDestroy,w=this.tracingService;switch(t.encapsulation){case Ya.Emulated:a=new fr(h,g,t,this.appId,_,r,u,w);break;case Ya.ShadowDom:return new pr(h,e,t,r,u,this.nonce,w,g);case Ya.ExperimentalIsolatedShadowDom:return new pr(h,e,t,r,u,this.nonce,w);default:a=new ea(h,g,t,_,r,u,w);break}n.set(t.id,a)}return a}ngOnDestroy(){this.rendererByCompId.clear()}componentReplaced(e){this.rendererByCompId.delete(e)}static \u0275fac=function(t){return new(t||i)(ne(hl),ne(zo),ne(Sn),ne(vf),ne($),ne(H),ne(Jn),ne(Gs,8))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})(),Jo=class{eventManager;doc;ngZone;tracingService;data=Object.create(null);throwOnSyntheticProps=!0;constructor(o,e,t,n){this.eventManager=o,this.doc=e,this.ngZone=t,this.tracingService=n}destroy(){}destroyNode=null;createElement(o,e){return e?this.doc.createElementNS(ml[e]||e,o):this.doc.createElement(o)}createComment(o){return this.doc.createComment(o)}createText(o){return this.doc.createTextNode(o)}appendChild(o,e){(Zd(o)?o.content:o).appendChild(e)}insertBefore(o,e,t){o&&(Zd(o)?o.content:o).insertBefore(e,t)}removeChild(o,e){e.remove()}selectRootElement(o,e){let t=typeof o=="string"?this.doc.querySelector(o):o;if(!t)throw new ae(-5104,!1);return e||(t.textContent=""),t}parentNode(o){return o.parentNode}nextSibling(o){return o.nextSibling}setAttribute(o,e,t,n){if(n){e=n+":"+e;let a=ml[n];a?o.setAttributeNS(a,e,t):o.setAttribute(e,t)}else o.setAttribute(e,t)}removeAttribute(o,e,t){if(t){let n=ml[t];n?o.removeAttributeNS(n,e):o.removeAttribute(`${t}:${e}`)}else o.removeAttribute(e)}addClass(o,e){o.classList.add(e)}removeClass(o,e){o.classList.remove(e)}setStyle(o,e,t,n){n&(io.DashCase|io.Important)?o.style.setProperty(e,t,n&io.Important?"important":""):o.style[e]=t}removeStyle(o,e,t){t&io.DashCase?o.style.removeProperty(e):o.style[e]=""}setProperty(o,e,t){o!=null&&(o[e]=t)}setValue(o,e){o.nodeValue=e}listen(o,e,t,n){if(typeof o=="string"&&(o=Xt().getGlobalEventTarget(this.doc,o),!o))throw new ae(-5102,!1);let a=this.decoratePreventDefault(t);return this.tracingService?.wrapEventListener&&(a=this.tracingService.wrapEventListener(o,e,a)),this.eventManager.addEventListener(o,e,a,n)}decoratePreventDefault(o){return e=>{if(e==="__ngUnwrap__")return o;o(e)===!1&&e.preventDefault()}}};function Zd(i){return i.tagName==="TEMPLATE"&&i.content!==void 0}var pr=class extends Jo{hostEl;sharedStylesHost;shadowRoot;constructor(o,e,t,n,a,r,u,h){super(o,n,a,u),this.hostEl=e,this.sharedStylesHost=h,this.shadowRoot=e.attachShadow({mode:"open"}),this.sharedStylesHost&&this.sharedStylesHost.addHost(this.shadowRoot);let g=t.styles;g=Jd(t.id,g);for(let w of g){let B=document.createElement("style");r&&B.setAttribute("nonce",r),B.textContent=w,this.shadowRoot.appendChild(B)}let _=t.getExternalStyles?.();if(_)for(let w of _){let B=ul(w,n);r&&B.setAttribute("nonce",r),this.shadowRoot.appendChild(B)}}nodeOrShadowRoot(o){return o===this.hostEl?this.shadowRoot:o}appendChild(o,e){return super.appendChild(this.nodeOrShadowRoot(o),e)}insertBefore(o,e,t){return super.insertBefore(this.nodeOrShadowRoot(o),e,t)}removeChild(o,e){return super.removeChild(null,e)}parentNode(o){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(o)))}destroy(){this.sharedStylesHost&&this.sharedStylesHost.removeHost(this.shadowRoot)}},ea=class extends Jo{sharedStylesHost;removeStylesOnCompDestroy;styles;styleUrls;constructor(o,e,t,n,a,r,u,h){super(o,a,r,u),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=n;let g=t.styles;this.styles=h?Jd(h,g):g,this.styleUrls=t.getExternalStyles?.(h)}applyStyles(){this.sharedStylesHost.addStyles(this.styles,this.styleUrls)}destroy(){this.removeStylesOnCompDestroy&&cd.size===0&&this.sharedStylesHost.removeStyles(this.styles,this.styleUrls)}},fr=class extends ea{contentAttr;hostAttr;constructor(o,e,t,n,a,r,u,h){let g=n+"-"+t.id;super(o,e,t,a,r,u,h,g),this.contentAttr=bf(g),this.hostAttr=yf(g)}applyToHost(o){this.applyStyles(),this.setAttribute(o,this.hostAttr,"")}createElement(o,e){let t=super.createElement(o,e);return super.setAttribute(t,this.contentAttr,""),t}};var _r=class i extends Wo{supportsDOMEvents=!0;static makeCurrent(){Zs(new i)}onAndCancel(o,e,t,n){return o.addEventListener(e,t,n),()=>{o.removeEventListener(e,t,n)}}dispatchEvent(o,e){o.dispatchEvent(e)}remove(o){o.remove()}createElement(o,e){return e=e||this.getDefaultDocument(),e.createElement(o)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(o){return o.nodeType===Node.ELEMENT_NODE}isShadowRoot(o){return o instanceof DocumentFragment}getGlobalEventTarget(o,e){return e==="window"?window:e==="document"?o:e==="body"?o.body:null}getBaseHref(o){let e=xf();return e==null?null:wf(e)}resetBaseElement(){ta=null}getUserAgent(){return window.navigator.userAgent}getCookie(o){return Zo(document.cookie,o)}},ta=null;function xf(){return ta=ta||document.head.querySelector("base"),ta?ta.getAttribute("href"):null}function wf(i){return new URL(i,document.baseURI).pathname}var em=["alt","control","meta","shift"],Df={"\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"},kf={alt:i=>i.altKey,control:i=>i.ctrlKey,meta:i=>i.metaKey,shift:i=>i.shiftKey},tm=(()=>{class i extends Qo{constructor(e){super(e)}supports(e){return i.parseEventName(e)!=null}addEventListener(e,t,n,a){let r=i.parseEventName(t),u=i.eventCallback(r.fullKey,n,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Xt().onAndCancel(e,r.domEventName,u,a))}static parseEventName(e){let t=e.toLowerCase().split("."),n=t.shift();if(t.length===0||!(n==="keydown"||n==="keyup"))return null;let a=i._normalizeKey(t.pop()),r="",u=t.indexOf("code");if(u>-1&&(t.splice(u,1),r="code."),em.forEach(g=>{let _=t.indexOf(g);_>-1&&(t.splice(_,1),r+=g+".")}),r+=a,t.length!=0||a.length===0)return null;let h={};return h.domEventName=n,h.fullKey=r,h}static matchEventFullKeyCode(e,t){let n=Df[e.key]||e.key,a="";return t.indexOf("code.")>-1&&(n=e.code,a="code."),n==null||!n?!1:(n=n.toLowerCase(),n===" "?n="space":n==="."&&(n="dot"),em.forEach(r=>{if(r!==n){let u=kf[r];u(e)&&(a+=r+".")}}),a+=n,a===t)}static eventCallback(e,t,n){return a=>{i.matchEventFullKeyCode(a,e)&&n.runGuarded(()=>t(a))}}static _normalizeKey(e){return e==="esc"?"escape":e}static \u0275fac=function(t){return new(t||i)(ne($))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})();function gl(i,o,e){return ye(this,null,function*(){let t=V({rootComponent:i},Sf(o,e));return gd(t)})}function Sf(i,o){return{platformRef:o?.platformRef,appProviders:[...If,...i?.providers??[]],platformProviders:Tf}}function Mf(){_r.makeCurrent()}function Ef(){return new kn}function Af(){return td(document),document}var Tf=[{provide:Qn,useValue:cl},{provide:Jc,useValue:Mf,multi:!0},{provide:$,useFactory:Af}];var If=[{provide:Zc,useValue:"root"},{provide:kn,useFactory:Ef},{provide:gr,useClass:hr,multi:!0},{provide:gr,useClass:tm,multi:!0},En,{provide:zo,useClass:pl},{provide:pl,useExisting:zo},hl,{provide:ot,useExisting:En},[]];var Li=class i{headers;normalizedNames=new Map;lazyInit;lazyUpdate=null;constructor(o){o?typeof o=="string"?this.lazyInit=()=>{this.headers=new Map,o.split(`
2
- `).forEach(e=>{let t=e.indexOf(":");if(t>0){let n=e.slice(0,t),a=e.slice(t+1).trim();this.addHeaderEntry(n,a)}})}:typeof Headers<"u"&&o instanceof Headers?(this.headers=new Map,o.forEach((e,t)=>{this.addHeaderEntry(t,e)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(o).forEach(([e,t])=>{this.setHeaderEntries(e,t)})}:this.headers=new Map}has(o){return this.init(),this.headers.has(o.toLowerCase())}get(o){this.init();let e=this.headers.get(o.toLowerCase());return e&&e.length>0?e[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(o){return this.init(),this.headers.get(o.toLowerCase())||null}append(o,e){return this.clone({name:o,value:e,op:"a"})}set(o,e){return this.clone({name:o,value:e,op:"s"})}delete(o,e){return this.clone({name:o,value:e,op:"d"})}maybeSetNormalizedName(o,e){this.normalizedNames.has(e)||this.normalizedNames.set(e,o)}init(){this.lazyInit&&(this.lazyInit instanceof i?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(o=>this.applyUpdate(o)),this.lazyUpdate=null))}copyFrom(o){o.init(),Array.from(o.headers.keys()).forEach(e=>{this.headers.set(e,o.headers.get(e)),this.normalizedNames.set(e,o.normalizedNames.get(e))})}clone(o){let e=new i;return e.lazyInit=this.lazyInit&&this.lazyInit instanceof i?this.lazyInit:this,e.lazyUpdate=(this.lazyUpdate||[]).concat([o]),e}applyUpdate(o){let e=o.name.toLowerCase();switch(o.op){case"a":case"s":let t=o.value;if(typeof t=="string"&&(t=[t]),t.length===0)return;this.maybeSetNormalizedName(o.name,e);let n=(o.op==="a"?this.headers.get(e):void 0)||[];n.push(...t),this.headers.set(e,n);break;case"d":let a=o.value;if(!a)this.headers.delete(e),this.normalizedNames.delete(e);else{let r=this.headers.get(e);if(!r)return;r=r.filter(u=>a.indexOf(u)===-1),r.length===0?(this.headers.delete(e),this.normalizedNames.delete(e)):this.headers.set(e,r)}break}}addHeaderEntry(o,e){let t=o.toLowerCase();this.maybeSetNormalizedName(o,t),this.headers.has(t)?this.headers.get(t).push(e):this.headers.set(t,[e])}setHeaderEntries(o,e){let t=(Array.isArray(e)?e:[e]).map(a=>a.toString()),n=o.toLowerCase();this.headers.set(n,t),this.maybeSetNormalizedName(o,n)}forEach(o){this.init(),Array.from(this.normalizedNames.keys()).forEach(e=>o(this.normalizedNames.get(e),this.headers.get(e)))}};var br=class{map=new Map;set(o,e){return this.map.set(o,e),this}get(o){return this.map.has(o)||this.map.set(o,o.defaultValue()),this.map.get(o)}delete(o){return this.map.delete(o),this}has(o){return this.map.has(o)}keys(){return this.map.keys()}},yr=class{encodeKey(o){return im(o)}encodeValue(o){return im(o)}decodeKey(o){return decodeURIComponent(o)}decodeValue(o){return decodeURIComponent(o)}};function Rf(i,o){let e=new Map;return i.length>0&&i.replace(/^\?/,"").split("&").forEach(n=>{let a=n.indexOf("="),[r,u]=a==-1?[o.decodeKey(n),""]:[o.decodeKey(n.slice(0,a)),o.decodeValue(n.slice(a+1))],h=e.get(r)||[];h.push(u),e.set(r,h)}),e}var Of=/%(\d[a-f0-9])/gi,Pf={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function im(i){return encodeURIComponent(i).replace(Of,(o,e)=>Pf[e]??o)}function vr(i){return`${i}`}var Ni=class i{map;encoder;updates=null;cloneFrom=null;constructor(o={}){if(this.encoder=o.encoder||new yr,o.fromString){if(o.fromObject)throw new ae(2805,!1);this.map=Rf(o.fromString,this.encoder)}else o.fromObject?(this.map=new Map,Object.keys(o.fromObject).forEach(e=>{let t=o.fromObject[e],n=Array.isArray(t)?t.map(vr):[vr(t)];this.map.set(e,n)})):this.map=null}has(o){return this.init(),this.map.has(o)}get(o){this.init();let e=this.map.get(o);return e?e[0]:null}getAll(o){return this.init(),this.map.get(o)||null}keys(){return this.init(),Array.from(this.map.keys())}append(o,e){return this.clone({param:o,value:e,op:"a"})}appendAll(o){let e=[];return Object.keys(o).forEach(t=>{let n=o[t];Array.isArray(n)?n.forEach(a=>{e.push({param:t,value:a,op:"a"})}):e.push({param:t,value:n,op:"a"})}),this.clone(e)}set(o,e){return this.clone({param:o,value:e,op:"s"})}delete(o,e){return this.clone({param:o,value:e,op:"d"})}toString(){return this.init(),this.keys().map(o=>{let e=this.encoder.encodeKey(o);return this.map.get(o).map(t=>e+"="+this.encoder.encodeValue(t)).join("&")}).filter(o=>o!=="").join("&")}clone(o){let e=new i({encoder:this.encoder});return e.cloneFrom=this.cloneFrom||this,e.updates=(this.updates||[]).concat(o),e}init(){this.map===null&&(this.map=new Map),this.cloneFrom!==null&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(o=>this.map.set(o,this.cloneFrom.map.get(o))),this.updates.forEach(o=>{switch(o.op){case"a":case"s":let e=(o.op==="a"?this.map.get(o.param):void 0)||[];e.push(vr(o.value)),this.map.set(o.param,e);break;case"d":if(o.value!==void 0){let t=this.map.get(o.param)||[],n=t.indexOf(vr(o.value));n!==-1&&t.splice(n,1),t.length>0?this.map.set(o.param,t):this.map.delete(o.param)}else{this.map.delete(o.param);break}}}),this.cloneFrom=this.updates=null)}};function Ff(i){switch(i){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}function nm(i){return typeof ArrayBuffer<"u"&&i instanceof ArrayBuffer}function om(i){return typeof Blob<"u"&&i instanceof Blob}function am(i){return typeof FormData<"u"&&i instanceof FormData}function Nf(i){return typeof URLSearchParams<"u"&&i instanceof URLSearchParams}var _l="Content-Type",rm="Accept",lm="text/plain",cm="application/json",Lf=`${cm}, ${lm}, */*`,ao=class i{url;body=null;headers;context;reportProgress=!1;reportUploadProgress=!1;reportDownloadProgress=!1;withCredentials=!1;credentials;keepalive=!1;cache;priority;mode;redirect;referrer;integrity;referrerPolicy;responseType="json";method;params;urlWithParams;transferCache;timeout;constructor(o,e,t,n){this.url=e,this.method=o.toUpperCase();let a;if(Ff(this.method)||n?(this.body=t!==void 0?t:null,a=n):a=t,a){if(this.reportProgress=!!a.reportProgress,this.reportUploadProgress=!!a.reportUploadProgress,this.reportDownloadProgress=!!a.reportDownloadProgress,this.withCredentials=!!a.withCredentials,this.keepalive=!!a.keepalive,a.responseType&&(this.responseType=a.responseType),a.headers&&(this.headers=a.headers),a.context&&(this.context=a.context),a.params&&(this.params=a.params),a.priority&&(this.priority=a.priority),a.cache&&(this.cache=a.cache),a.credentials&&(this.credentials=a.credentials),typeof a.timeout=="number"){if(a.timeout<1||!Number.isInteger(a.timeout))throw new ae(2822,"");this.timeout=a.timeout}a.mode&&(this.mode=a.mode),a.redirect&&(this.redirect=a.redirect),a.integrity&&(this.integrity=a.integrity),a.referrer!==void 0&&(this.referrer=a.referrer),a.referrerPolicy&&(this.referrerPolicy=a.referrerPolicy),this.transferCache=a.transferCache}if(this.headers??=new Li,this.context??=new br,!this.params)this.params=new Ni,this.urlWithParams=e;else{let r=this.params.toString();if(r.length===0)this.urlWithParams=e;else{let u=e,h="",g=e.indexOf("#");g!==-1&&(h=e.substring(g),u=e.substring(0,g));let _=u.indexOf("?"),w=_===-1?"?":_<u.length-1?"&":"";this.urlWithParams=u+w+r+h}}}serializeBody(){return this.body===null?null:typeof this.body=="string"||nm(this.body)||om(this.body)||am(this.body)||Nf(this.body)?this.body:this.body instanceof Ni?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||am(this.body)?null:om(this.body)?this.body.type||null:nm(this.body)?null:typeof this.body=="string"?lm:this.body instanceof Ni?"application/x-www-form-urlencoded;charset=UTF-8":typeof this.body=="object"||typeof this.body=="number"||typeof this.body=="boolean"?cm:null}clone(o={}){let e=o.method||this.method,t=o.url||this.url,n=o.responseType||this.responseType,a=o.keepalive??this.keepalive,r=o.priority||this.priority,u=o.cache||this.cache,h=o.mode||this.mode,g=o.redirect||this.redirect,_=o.credentials||this.credentials,w=o.referrer??this.referrer,B=o.integrity||this.integrity,G=o.referrerPolicy||this.referrerPolicy,ie=o.transferCache??this.transferCache,fe=o.timeout??this.timeout,se=o.body!==void 0?o.body:this.body,Ae=o.withCredentials??this.withCredentials,lt=o.reportProgress??this.reportProgress,li=o.reportUploadProgress??this.reportUploadProgress,Ci=o.reportDownloadProgress??this.reportDownloadProgress,Ki=o.headers||this.headers,ci=o.params||this.params,ja=o.context??this.context;return o.setHeaders!==void 0&&(Ki=Object.keys(o.setHeaders).reduce((Yn,Dn)=>Yn.set(Dn,o.setHeaders[Dn]),Ki)),o.setParams&&(ci=Object.keys(o.setParams).reduce((Yn,Dn)=>Yn.set(Dn,o.setParams[Dn]),ci)),new i(e,t,se,{params:ci,headers:Ki,context:ja,reportProgress:lt,reportUploadProgress:li,reportDownloadProgress:Ci,responseType:n,withCredentials:Ae,transferCache:ie,keepalive:a,cache:u,priority:r,timeout:fe,mode:h,redirect:g,credentials:_,referrer:w,integrity:B,referrerPolicy:G})}},ro=(function(i){return i[i.Sent=0]="Sent",i[i.UploadProgress=1]="UploadProgress",i[i.ResponseHeader=2]="ResponseHeader",i[i.DownloadProgress=3]="DownloadProgress",i[i.Response=4]="Response",i[i.User=5]="User",i})(ro||{}),so=class{headers;status;statusText;url;ok;type;redirected;responseType;constructor(o,e=200,t="OK"){this.headers=o.headers||new Li,this.status=o.status!==void 0?o.status:e,this.statusText=o.statusText||t,this.url=o.url||null,this.redirected=o.redirected,this.responseType=o.responseType,this.ok=this.status>=200&&this.status<300}},Cr=class i extends so{constructor(o={}){super(o)}type=ro.ResponseHeader;clone(o={}){return new i({headers:o.headers||this.headers,status:o.status!==void 0?o.status:this.status,statusText:o.statusText||this.statusText,url:o.url||this.url||void 0})}},ia=class i extends so{body;constructor(o={}){super(o),this.body=o.body!==void 0?o.body:null}type=ro.Response;clone(o={}){return new i({body:o.body!==void 0?o.body:this.body,headers:o.headers||this.headers,status:o.status!==void 0?o.status:this.status,statusText:o.statusText||this.statusText,url:o.url||this.url||void 0,redirected:o.redirected??this.redirected,responseType:o.responseType??this.responseType})}},An=class extends so{name="HttpErrorResponse";message;error;ok=!1;constructor(o){super(o,0,"Unknown Error"),this.status>=200&&this.status<300?this.message=`Http failure during parsing for ${o.url||"(unknown url)"}`:this.message=`Http failure response for ${o.url||"(unknown url)"}: ${o.status} ${o.statusText}`,this.error=o.error||null}},Vf=200;var Bf=/^\)\]\}',?\n/,Uw=1024*1024,dm=new C("",{factory:()=>null}),xr=(()=>{class i{fetchImpl=d(bl,{optional:!0})?.fetch??((...e)=>globalThis.fetch(...e));ngZone=d(H);destroyRef=d(Bt);maxResponseSize=d(dm);handle(e){return new yt(t=>{let n=new AbortController;this.doRequest(e,n.signal,t).then(yl,r=>t.error(new An({error:r})));let a;return e.timeout&&(a=this.ngZone.runOutsideAngular(()=>setTimeout(()=>{n.signal.aborted||n.abort(new DOMException("signal timed out","TimeoutError"))},e.timeout))),()=>{a!==void 0&&clearTimeout(a),n.abort()}})}doRequest(e,t,n){return ye(this,null,function*(){let a=this.createRequestInit(e),r;try{let se=this.ngZone.runOutsideAngular(()=>this.fetchImpl(e.urlWithParams,V({signal:t},a)));zf(se),n.next({type:ro.Sent}),r=yield se}catch(se){n.error(new An({error:se,status:se.status??0,statusText:se.statusText,url:e.urlWithParams,headers:se.headers}));return}let u=new Li(r.headers),h=r.statusText,g=r.url||e.urlWithParams,_=r.status,w=null,B=e.reportProgress||e.reportDownloadProgress;if(B&&n.next(new Cr({headers:u,status:_,statusText:h,url:g})),r.body){let se=r.headers.get("content-length"),Ae=se!==null?Number(se):NaN;this.maxResponseSize!==null&&Number.isFinite(Ae)&&Ae>this.maxResponseSize&&sm(this.maxResponseSize);let lt=[],li=r.body.getReader(),Ci=0,Ki,ci,ja=typeof Zone<"u"&&Zone.current,Yn=!1;if(yield this.ngZone.runOutsideAngular(()=>ye(this,null,function*(){for(;;){if(this.destroyRef.destroyed){yield li.cancel(),Yn=!0;break}let{done:Lo,value:Fs}=yield li.read();if(Lo)break;if(lt.push(Fs),Ci+=Fs.length,this.maxResponseSize!==null&&Ci>this.maxResponseSize&&(yield li.cancel(),sm(this.maxResponseSize)),B){ci=e.responseType==="text"?(ci??"")+(Ki??=new TextDecoder).decode(Fs,{stream:!0}):void 0;let Uc=()=>n.next({type:ro.DownloadProgress,total:Number.isFinite(Ae)?Ae:void 0,loaded:Ci,partialText:ci});ja?ja.run(Uc):Uc()}}})),Yn){n.complete();return}let Dn=this.concatChunks(lt,Ci);try{let Lo=r.headers.get(_l)??"";w=this.parseBody(e,Dn,Lo,_)}catch(Lo){n.error(new An({error:Lo,headers:new Li(r.headers),status:r.status,statusText:r.statusText,url:r.url||e.urlWithParams}));return}}_===0&&(_=w?Vf:0);let G=_>=200&&_<300,ie=r.redirected,fe=r.type;G?(n.next(new ia({body:w,headers:u,status:_,statusText:h,url:g,redirected:ie,responseType:fe})),n.complete()):n.error(new An({error:w,headers:u,status:_,statusText:h,url:g,redirected:ie,responseType:fe}))})}parseBody(e,t,n,a){switch(e.responseType){case"json":let r=new TextDecoder().decode(t).replace(Bf,"");if(r==="")return null;try{return JSON.parse(r)}catch(u){if(a<200||a>=300)return r;throw u}case"text":return new TextDecoder().decode(t);case"blob":return new Blob([t],{type:n});case"arraybuffer":return t.buffer}}createRequestInit(e){if(e.reportUploadProgress)throw new ae(2824,!1);let t={},n;if(n=e.credentials,e.withCredentials&&(n="include"),e.headers.forEach((a,r)=>t[a]=r.join(",")),e.headers.has(rm)||(t[rm]=Lf),!e.headers.has(_l)){let a=e.detectContentTypeHeader();a!==null&&(t[_l]=a)}return{body:e.serializeBody(),method:e.method,headers:t,credentials:n,keepalive:e.keepalive,cache:e.cache,priority:e.priority,mode:e.mode,redirect:e.redirect,referrer:e.referrer,integrity:e.integrity,referrerPolicy:e.referrerPolicy}}concatChunks(e,t){let n=new Uint8Array(t),a=0;for(let r of e)n.set(r,a),a+=r.length;return n}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),bl=class{};function yl(){}function zf(i){i.then(yl,yl)}function sm(i){throw new ae(-2825,!1)}function jf(i,o){return o(i)}function Hf(i,o,e){return(t,n)=>Qc(e,()=>o(t,a=>i(a,n)))}var Cl=new C("",{factory:()=>[]}),mm=new C(""),um=new C("",{factory:()=>!0});var xl=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:function(t){let n=null;return t?n=new(t||i):n=ne(xr),n},providedIn:"root"})}return i})();var wr=(()=>{class i{backend;injector;chain=null;pendingTasks=d(Hs);contributeToStability=d(um);constructor(e,t){this.backend=e,this.injector=t}handle(e){if(this.chain===null){let t=Array.from(new Set([...this.injector.get(Cl),...this.injector.get(mm,[])]));this.chain=t.reduceRight((n,a)=>Hf(n,a,this.injector),jf)}if(this.contributeToStability){let t=this.pendingTasks.add();return this.chain(e,n=>this.backend.handle(n)).pipe(qa(t))}else return this.chain(e,t=>this.backend.handle(t))}static \u0275fac=function(t){return new(t||i)(ne(xl),ne(mi))};static \u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})(),wl=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:function(t){let n=null;return t?n=new(t||i):n=ne(wr),n},providedIn:"root"})}return i})();function vl(i,o){return V({body:o},i)}var Qt=(()=>{class i{handler;constructor(e){this.handler=e}request(e,t,n={}){let a;if(e instanceof ao)a=e;else{let h;n.headers instanceof Li?h=n.headers:h=new Li(n.headers);let g;n.params&&(n.params instanceof Ni?g=n.params:g=new Ni({fromObject:n.params})),a=new ao(e,t,n.body!==void 0?n.body:null,{headers:h,context:n.context,params:g,reportProgress:n.reportProgress,reportUploadProgress:n.reportUploadProgress,reportDownloadProgress:n.reportDownloadProgress,responseType:n.responseType||"json",withCredentials:n.withCredentials,transferCache:n.transferCache,keepalive:n.keepalive,priority:n.priority,cache:n.cache,mode:n.mode,redirect:n.redirect,credentials:n.credentials,referrer:n.referrer,referrerPolicy:n.referrerPolicy,integrity:n.integrity,timeout:n.timeout})}let r=ge(a).pipe(qc(h=>this.handler.handle(h)));if(e instanceof ao||n.observe==="events")return r;let u=r.pipe(Ce(h=>h instanceof ia));switch(n.observe||"body"){case"body":switch(a.responseType){case"arraybuffer":return u.pipe(Pe(h=>{if(h.body!==null&&!(h.body instanceof ArrayBuffer))throw new ae(2806,!1);return h.body}));case"blob":return u.pipe(Pe(h=>{if(h.body!==null&&!(h.body instanceof Blob))throw new ae(2807,!1);return h.body}));case"text":return u.pipe(Pe(h=>{if(h.body!==null&&typeof h.body!="string")throw new ae(2808,!1);return h.body}));default:return u.pipe(Pe(h=>h.body))}case"response":return u;default:throw new ae(2809,!1)}}delete(e,t={}){return this.request("DELETE",e,t)}get(e,t={}){return this.request("GET",e,t)}head(e,t={}){return this.request("HEAD",e,t)}jsonp(e,t){return this.request("JSONP",e,{params:new Ni().append(t,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(e,t={}){return this.request("OPTIONS",e,t)}patch(e,t,n={}){return this.request("PATCH",e,vl(n,t))}post(e,t,n={}){return this.request("POST",e,vl(n,t))}put(e,t,n={}){return this.request("PUT",e,vl(n,t))}static \u0275fac=function(t){return new(t||i)(ne(wl))};static \u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var Uf=new C("",{factory:()=>!0}),Gf="XSRF-TOKEN",$f=new C("",{factory:()=>Gf}),Wf="X-XSRF-TOKEN",qf=new C("",{factory:()=>Wf}),Kf=(()=>{class i{cookieName=d($f);doc=d($);lastCookieString="";lastToken=null;parseCount=0;getToken(){let e=this.doc.cookie||"";return e!==this.lastCookieString&&(this.parseCount++,this.lastToken=Zo(e,this.cookieName),this.lastCookieString=e),this.lastToken}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),hm=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:function(t){let n=null;return t?n=new(t||i):n=ne(Kf),n},providedIn:"root"})}return i})();function Yf(i,o){if(!d(Uf)||i.method==="GET"||i.method==="HEAD")return o(i);try{let n=d(oo).href,{origin:a}=new URL(n),{origin:r}=new URL(i.url,a);if(a!==r)return o(i)}catch(n){return o(i)}let e=d(hm).getToken(),t=d(qf);return e!=null&&!i.headers.has(t)&&(i=i.clone({headers:i.headers.set(t,e)})),o(i)}var Dl=(function(i){return i[i.Interceptors=0]="Interceptors",i[i.LegacyInterceptors=1]="LegacyInterceptors",i[i.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",i[i.NoXsrfProtection=3]="NoXsrfProtection",i[i.JsonpSupport=4]="JsonpSupport",i[i.RequestsMadeViaParent=5]="RequestsMadeViaParent",i[i.Fetch=6]="Fetch",i[i.Xhr=7]="Xhr",i})(Dl||{});function Xf(i,o){return{\u0275kind:i,\u0275providers:o}}function kl(...i){let o=[Qt,xr,wr,{provide:wl,useExisting:wr},{provide:xl,useFactory:()=>d(xr)},{provide:Cl,useValue:Yf,multi:!0}];for(let e of i)o.push(...e.\u0275providers);return Bo(o)}function Sl(i){return Xf(Dl.Interceptors,i.map(o=>({provide:Cl,useValue:o,multi:!0})))}var na=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:function(t){let n=null;return t?n=new(t||i):n=ne(Jf),n},providedIn:"root"})}return i})(),Jf=(()=>{class i extends na{_doc=d($);sanitize(e,t){if(t==null)return null;switch(e){case Ct.NONE:return t;case Ct.HTML:return to(t,"HTML")?eo(t):ld(this._doc,String(t)).toString();case Ct.STYLE:return to(t,"Style")?eo(t):t;case Ct.SCRIPT:if(to(t,"Script"))return eo(t);throw new ae(5200,!1);case Ct.URL:return to(t,"URL")?eo(t):sd(String(t));case Ct.RESOURCE_URL:if(to(t,"ResourceURL"))return eo(t);throw new ae(5201,!1);default:throw new ae(5202,!1)}}bypassSecurityTrustHtml(e){return id(e)}bypassSecurityTrustStyle(e){return nd(e)}bypassSecurityTrustScript(e){return od(e)}bypassSecurityTrustUrl(e){return ad(e)}bypassSecurityTrustResourceUrl(e){return rd(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var tg=(()=>{class i extends nr{constructor(e,t,n){super(e,t,n)}ngOnDestroy(){this.flush()}static \u0275fac=function(t){return new(t||i)(ne($),ne($o),ne(ir))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})();function ig(){return new bd}function ng(){return new Cd(d(En),d(nr),d(H))}var pm=[{provide:ir,useFactory:ig},{provide:nr,useClass:tg},{provide:ot,useFactory:ng}],UD=[{provide:$o,useClass:vd},{provide:Pi,useValue:"NoopAnimations"},...pm],og=[{provide:$o,useFactory:()=>new yd},{provide:Pi,useFactory:()=>"BrowserAnimations"},...pm];function fm(){return Xa("NgEagerAnimations"),[...og]}var ag="@",rg=(()=>{class i{doc;delegate;zone;animationType;moduleImpl;_rendererFactoryPromise=null;scheduler=null;injector=d(X);loadingSchedulerFn=d(sg,{optional:!0});_engine;constructor(e,t,n,a,r){this.doc=e,this.delegate=t,this.zone=n,this.animationType=a,this.moduleImpl=r}ngOnDestroy(){this._engine?.flush()}loadImpl(){let e=()=>this.moduleImpl??import("./chunk-34LU6STA.js").then(n=>n),t;return this.loadingSchedulerFn?t=this.loadingSchedulerFn(e):t=e(),t.catch(n=>{throw new ae(5300,!1)}).then(({\u0275createEngine:n,\u0275AnimationRendererFactory:a})=>{this._engine=n(this.animationType,this.doc);let r=new a(this.delegate,this._engine,this.zone);return this.delegate=r,r})}createRenderer(e,t){let n=this.delegate.createRenderer(e,t);if(n.\u0275type===0)return n;typeof n.throwOnSyntheticProps=="boolean"&&(n.throwOnSyntheticProps=!1);let a=new Ml(n);return t?.data?.animation&&!this._rendererFactoryPromise&&(this._rendererFactoryPromise=this.loadImpl()),this._rendererFactoryPromise?.then(r=>{let u=r.createRenderer(e,t);a.use(u),this.scheduler??=this.injector.get(ed,null,{optional:!0}),this.scheduler?.notify(10)}).catch(r=>{a.use(n)}),a}begin(){this.delegate.begin?.()}end(){this.delegate.end?.()}whenRenderingDone(){return this.delegate.whenRenderingDone?.()??Promise.resolve()}componentReplaced(e){this._engine?.flush(),this.delegate.componentReplaced?.(e)}static \u0275fac=function(t){Za()};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})(),Ml=class{delegate;replay=[];\u0275type=1;constructor(o){this.delegate=o}use(o){if(this.delegate=o,this.replay!==null){for(let e of this.replay)e(o);this.replay=null}}get data(){return this.delegate.data}destroy(){this.replay=null,this.delegate.destroy()}createElement(o,e){return this.delegate.createElement(o,e)}createComment(o){return this.delegate.createComment(o)}createText(o){return this.delegate.createText(o)}get destroyNode(){return this.delegate.destroyNode}appendChild(o,e){this.delegate.appendChild(o,e)}insertBefore(o,e,t,n){this.delegate.insertBefore(o,e,t,n)}removeChild(o,e,t,n){this.delegate.removeChild(o,e,t,n)}selectRootElement(o,e){return this.delegate.selectRootElement(o,e)}parentNode(o){return this.delegate.parentNode(o)}nextSibling(o){return this.delegate.nextSibling(o)}setAttribute(o,e,t,n){this.delegate.setAttribute(o,e,t,n)}removeAttribute(o,e,t){this.delegate.removeAttribute(o,e,t)}addClass(o,e){this.delegate.addClass(o,e)}removeClass(o,e){this.delegate.removeClass(o,e)}setStyle(o,e,t,n){this.delegate.setStyle(o,e,t,n)}removeStyle(o,e,t){this.delegate.removeStyle(o,e,t)}setProperty(o,e,t){this.shouldReplay(e)&&this.replay.push(n=>n.setProperty(o,e,t)),this.delegate.setProperty(o,e,t)}setValue(o,e){this.delegate.setValue(o,e)}listen(o,e,t,n){return this.shouldReplay(e)&&this.replay.push(a=>a.listen(o,e,t,n)),this.delegate.listen(o,e,t,n)}shouldReplay(o){return this.replay!==null&&o.startsWith(ag)}},sg=new C("");function gm(i="animations"){return Xa("NgAsyncAnimations"),Bo([{provide:ot,useFactory:()=>new rg(d($),d(En),d(H),i)},{provide:Pi,useValue:i==="noop"?"NoopAnimations":"BrowserAnimations"}])}var Dr="asm_token",kr=(()=>{class i{constructor(){this.http=d(Qt),this.authState=new Xn(this.hasToken())}login(e){return ye(this,null,function*(){try{let t=yield Te(this.http.post("/api/auth/login",{password:e}));return localStorage.setItem(Dr,t.token),this.authState.next(!0),!0}catch(t){return!1}})}logout(){localStorage.removeItem(Dr),this.authState.next(!1)}getToken(){return localStorage.getItem(Dr)}isAuthenticated(){return this.hasToken()}hasToken(){return!!localStorage.getItem(Dr)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var _m=(i,o)=>{let e=d(kr),t=e.getToken(),n=i.url.includes("/api/auth/login"),a=t&&!n?i.clone({setHeaders:{Authorization:`Bearer ${t}`}}):i;return o(a).pipe(Kt(r=>(r.status===401&&!n&&e.logout(),Ga(()=>r))))};var vm={providers:[fd({eventCoalescing:!0}),kl(Sl([_m])),fm(),gm()]};var El;try{El=typeof Intl<"u"&&Intl.v8BreakIterator}catch(i){El=!1}var le=(()=>{class i{_platformId=d(Qn);isBrowser=this._platformId?qd(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||El)&&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;static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function Vi(i){return Array.isArray(i)?i:[i]}var bm=new Set,Tn,lo=(()=>{class i{_platform=d(le);_nonce=d(Jn,{optional:!0});_matchMedia;constructor(){this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):cg}matchMedia(e){return(this._platform.WEBKIT||this._platform.BLINK)&&lg(e,this._nonce),this._matchMedia(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function lg(i,o){if(!bm.has(i))try{Tn||(Tn=document.createElement("style"),o&&Tn.setAttribute("nonce",o),Tn.setAttribute("type","text/css"),document.head.appendChild(Tn)),Tn.sheet&&(Tn.sheet.insertRule(`@media ${i.replace(/[{}]/g,"")} {body{ }}`,0),bm.add(i))}catch(e){console.error(e)}}function cg(i){return{matches:i==="all"||i==="",media:i,addListener:()=>{},removeListener:()=>{}}}var In=(()=>{class i{_mediaMatcher=d(lo);_zone=d(H);_queries=new Map;_destroySubject=new I;ngOnDestroy(){this._destroySubject.next(),this._destroySubject.complete()}isMatched(e){return ym(Vi(e)).some(n=>this._registerQuery(n).mql.matches)}observe(e){let n=ym(Vi(e)).map(r=>this._registerQuery(r).observable),a=Zn(n);return a=Wc(a.pipe(ct(1)),a.pipe(Ka(1),Vt(0))),a.pipe(Pe(r=>{let u={matches:!1,breakpoints:{}};return r.forEach(({matches:h,query:g})=>{u.matches=u.matches||h,u.breakpoints[g]=h}),u}))}_registerQuery(e){if(this._queries.has(e))return this._queries.get(e);let t=this._mediaMatcher.matchMedia(e),a={observable:new yt(r=>{let u=h=>this._zone.run(()=>r.next(h));return t.addListener(u),()=>{t.removeListener(u)}}).pipe(ke(t),Pe(({matches:r})=>({query:e,matches:r})),oe(this._destroySubject)),mql:t};return this._queries.set(e,a),a}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function ym(i){return i.map(o=>o.split(",")).reduce((o,e)=>o.concat(e)).map(o=>o.trim())}var Sr={XSmall:"(max-width: 599.98px)",Small:"(min-width: 600px) and (max-width: 959.98px)",Medium:"(min-width: 960px) and (max-width: 1279.98px)",Large:"(min-width: 1280px) and (max-width: 1919.98px)",XLarge:"(min-width: 1920px)",Handset:"(max-width: 599.98px) and (orientation: portrait), (max-width: 959.98px) and (orientation: landscape)",Tablet:"(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait), (min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)",Web:"(min-width: 840px) and (orientation: portrait), (min-width: 1280px) and (orientation: landscape)",HandsetPortrait:"(max-width: 599.98px) and (orientation: portrait)",TabletPortrait:"(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait)",WebPortrait:"(min-width: 840px) and (orientation: portrait)",HandsetLandscape:"(max-width: 959.98px) and (orientation: landscape)",TabletLandscape:"(min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)",WebLandscape:"(min-width: 1280px) and (orientation: landscape)"};var dg=new C("MATERIAL_ANIMATIONS"),Cm=null;function Al(){return d(dg,{optional:!0})?.animationsDisabled||d(Pi,{optional:!0})==="NoopAnimations"?"di-disabled":(Cm??=d(lo).matchMedia("(prefers-reduced-motion)").matches,Cm?"reduced-motion":"enabled")}function pe(){return Al()!=="enabled"}var mg=new C("cdk-dir-doc",{providedIn:"root",factory:()=>d($)}),ug=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;function xm(i){let o=i?.toLowerCase()||"";return o==="auto"&&typeof navigator<"u"&&navigator?.language?ug.test(navigator.language)?"rtl":"ltr":o==="rtl"?"rtl":"ltr"}var qe=(()=>{class i{get value(){return this.valueSignal()}valueSignal=R("ltr");change=new K;constructor(){let e=d(mg,{optional:!0});if(e){let t=e.body?e.body.dir:null,n=e.documentElement?e.documentElement.dir:null;this.valueSignal.set(xm(t||n||"ltr"))}}ngOnDestroy(){this.change.complete()}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var ee=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();function hg(i,o){i&1&&ht(0,"div",2)}var pg=new C("MAT_PROGRESS_BAR_DEFAULT_OPTIONS");var en=(()=>{class i{_elementRef=d(N);_ngZone=d(H);_changeDetectorRef=d(te);_renderer=d(ve);_cleanupTransitionEnd;constructor(){let e=Al(),t=d(pg,{optional:!0});this._isNoopAnimation=e==="di-disabled",e==="reduced-motion"&&this._elementRef.nativeElement.classList.add("mat-progress-bar-reduced-motion"),t&&(t.color&&(this.color=this._defaultColor=t.color),this.mode=t.mode||this.mode)}_isNoopAnimation;get color(){return this._color||this._defaultColor}set color(e){this._color=e}_color;_defaultColor="primary";get value(){return this._value}set value(e){this._value=wm(e||0),this._changeDetectorRef.markForCheck()}_value=0;get bufferValue(){return this._bufferValue||0}set bufferValue(e){this._bufferValue=wm(e||0),this._changeDetectorRef.markForCheck()}_bufferValue=0;animationEnd=new K;get mode(){return this._mode}set mode(e){this._mode=e,this._changeDetectorRef.markForCheck()}_mode="determinate";ngAfterViewInit(){this._ngZone.runOutsideAngular(()=>{this._cleanupTransitionEnd=this._renderer.listen(this._elementRef.nativeElement,"transitionend",this._transitionendHandler)})}ngOnDestroy(){this._cleanupTransitionEnd?.()}_getPrimaryBarTransform(){return`scaleX(${this._isIndeterminate()?1:this.value/100})`}_getBufferBarFlexBasis(){return`${this.mode==="buffer"?this.bufferValue:100}%`}_isIndeterminate(){return this.mode==="indeterminate"||this.mode==="query"}_transitionendHandler=e=>{this.animationEnd.observers.length===0||!e.target||!e.target.classList.contains("mdc-linear-progress__primary-bar")||(this.mode==="determinate"||this.mode==="buffer")&&this._ngZone.run(()=>this.animationEnd.next({value:this.value}))};static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-progress-bar"]],hostAttrs:["role","progressbar","aria-valuemin","0","aria-valuemax","100","tabindex","-1",1,"mat-mdc-progress-bar","mdc-linear-progress"],hostVars:10,hostBindings:function(t,n){t&2&&(Z("aria-valuenow",n._isIndeterminate()?null:n.value)("mode",n.mode),et("mat-"+n.color),p("_mat-animation-noopable",n._isNoopAnimation)("mdc-linear-progress--animation-ready",!n._isNoopAnimation)("mdc-linear-progress--indeterminate",n._isIndeterminate()))},inputs:{color:"color",value:[2,"value","value",wt],bufferValue:[2,"bufferValue","bufferValue",wt],mode:"mode"},outputs:{animationEnd:"animationEnd"},exportAs:["matProgressBar"],decls:7,vars:5,consts:[["aria-hidden","true",1,"mdc-linear-progress__buffer"],[1,"mdc-linear-progress__buffer-bar"],[1,"mdc-linear-progress__buffer-dots"],["aria-hidden","true",1,"mdc-linear-progress__bar","mdc-linear-progress__primary-bar"],[1,"mdc-linear-progress__bar-inner"],["aria-hidden","true",1,"mdc-linear-progress__bar","mdc-linear-progress__secondary-bar"]],template:function(t,n){t&1&&(Ie(0,"div",0),ht(1,"div",1),M(2,hg,1,0,"div",2),je(),Ie(3,"div",3),ht(4,"span",4),je(),Ie(5,"div",5),ht(6,"span",4),je()),t&2&&(c(),He("flex-basis",n._getBufferBarFlexBasis()),c(),E(n.mode==="buffer"?2:-1),c(),He("transform",n._getPrimaryBarTransform()))},styles:[`.mat-mdc-progress-bar {
1
+ import{$ as xe,$a as tr,$b as Xs,A as Kt,Aa as io,Ab as Ue,Ac as vd,B as qc,Ba as no,Bb as dt,Bc as qo,C as Vt,Ca as id,Cb as jt,Cc as ar,D as ct,Da as nd,Db as Je,E as Kc,Ea as od,Eb as A,Ec as bd,F as xi,Fa as ad,Fb as nr,G as Xa,Ga as rd,Gb as D,Gc as rr,H as zs,Ha as sd,Hb as ce,I as Yc,Ia as ld,Ib as U,Ic as yd,J as js,Ja as Ct,Jb as at,K as Za,Ka as Gs,Kb as Me,L as ke,La as oo,Lb as O,M as We,Ma as cd,Mb as P,N as oe,Na as $s,Nb as md,Nc as Cd,O as Xc,Oa as Ja,Ob as ud,P as di,Pa as Be,Pb as Ys,Q as ae,Qa as c,Qb as Fe,R as nt,Ra as Ye,Rb as He,S as re,Sa as ot,Sb as p,T as z,Ta as ve,Tb as et,U as x,Ua as b,Ub as m,V as ne,Va as y,Vb as q,W as d,Wa as Ho,Wb as he,X as jo,Xa as de,Xb as An,Y as Zc,Ya as er,Yb as J,Z as mi,Za as Xe,Zb as Uo,_ as Qc,_a as Ws,_b as Go,a as V,aa as we,ab as T,ac as Zs,b as Oe,ba as wi,bb as j,bc as $,c as ye,ca as Hs,cb as k,cc as pt,d as De,da as X,db as qs,dc as Di,e as yt,ea as W,eb as Ks,ec as hd,f as Gc,fa as Bt,fb as dd,fc as ao,g as I,ga as K,gb as Q,gc as $o,h as Qn,ha as H,hb as ze,hc as pd,i as $a,ia as Mn,ib as ir,ic as Wo,j as Ls,ja as R,jb as Qi,jc as te,k as Vs,ka as En,kb as Z,kc as fd,l as Wa,la as Jc,lb as M,lc as gd,m as $c,ma as eo,mb as E,mc as L,n as ge,na as Pi,nb as xt,nc as wt,o as qa,oa as to,ob as me,oc as _d,p as Bs,pa as ed,pb as ue,pc as or,q as Te,qa as zt,qb as C,r as Pe,ra as Xi,rb as s,s as Jn,sa as Us,sb as l,t as Wc,ta as Se,tb as v,u as Yi,ua as _e,ub as Ie,v as Ka,va as Y,vb as je,w as Ya,wa as N,wb as ht,x as $e,xa as Zi,xb as ui,y as Ce,ya as td,yb as hi,z as zo,za as Qa,zb as Yt}from"./chunk-JGNPKRLU.js";var xd=null;function Xt(){return xd}function Qs(i){xd??=i}var Ko=class{},ro=(()=>{class i{historyGo(e){throw new Error("")}static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:()=>d(wd),providedIn:"platform"})}return i})();var wd=(()=>{class i extends ro{_location;_history;_doc=d(W);constructor(){super(),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return Xt().getBaseHref(this._doc)}onPopState(e){let t=Xt().getGlobalEventTarget(this._doc,"window");return t.addEventListener("popstate",e,!1),()=>t.removeEventListener("popstate",e)}onHashChange(e){let t=Xt().getGlobalEventTarget(this._doc,"window");return t.addEventListener("hashchange",e,!1),()=>t.removeEventListener("hashchange",e)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(e){this._location.pathname=e}pushState(e,t,n){this._history.pushState(e,t,n)}replaceState(e,t,n){this._history.replaceState(e,t,n)}forward(){this._history.forward()}back(){this._history.back()}historyGo(e=0){this._history.go(e)}getState(){return this._history.state}static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:()=>new i,providedIn:"platform"})}return i})();function Sd(i,o){return i?o?i.endsWith("/")?o.startsWith("/")?i+o.slice(1):i+o:o.startsWith("/")?i+o:`${i}/${o}`:i:o}function Dd(i){let o=i.search(/#|\?|$/);return i[o-1]==="/"?i.slice(0,o-1)+i.slice(o):i}function Ji(i){return i&&i[0]!=="?"?`?${i}`:i}var sr=(()=>{class i{historyGo(e){throw new Error("")}static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:()=>d(Np),providedIn:"root"})}return i})(),Fp=new x(""),Np=(()=>{class i extends sr{_platformLocation;_baseHref;_removeListenerFns=[];constructor(e,t){super(),this._platformLocation=e,this._baseHref=t??this._platformLocation.getBaseHrefFromDOM()??d(W).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(e){this._removeListenerFns.push(this._platformLocation.onPopState(e),this._platformLocation.onHashChange(e))}getBaseHref(){return this._baseHref}prepareExternalUrl(e){return Sd(this._baseHref,e)}path(e=!1){let t=this._platformLocation.pathname+Ji(this._platformLocation.search),n=this._platformLocation.hash;return n&&e?`${t}${n}`:t}pushState(e,t,n,a){let r=this.prepareExternalUrl(n+Ji(a));this._platformLocation.pushState(e,t,r)}replaceState(e,t,n,a){let r=this.prepareExternalUrl(n+Ji(a));this._platformLocation.replaceState(e,t,r)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(e=0){this._platformLocation.historyGo?.(e)}static \u0275fac=function(t){return new(t||i)(ne(ro),ne(Fp,8))};static \u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var lr=(()=>{class i{_subject=new I;_basePath;_locationStrategy;_urlChangeListeners=[];_urlChangeSubscription=null;constructor(e){this._locationStrategy=e;let t=this._locationStrategy.getBaseHref();this._basePath=Bp(Dd(kd(t))),this._locationStrategy.onPopState(n=>{this._subject.next({url:this.path(!0),pop:!0,state:n.state,type:n.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(e=!1){return this.normalize(this._locationStrategy.path(e))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(e,t=""){return this.path()==this.normalize(e+Ji(t))}normalize(e){return i.stripTrailingSlash(Vp(this._basePath,kd(e)))}prepareExternalUrl(e){return e&&e[0]!=="/"&&(e="/"+e),this._locationStrategy.prepareExternalUrl(e)}go(e,t="",n=null){this._locationStrategy.pushState(n,"",e,t),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+Ji(t)),n)}replaceState(e,t="",n=null){this._locationStrategy.replaceState(n,"",e,t),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+Ji(t)),n)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(e=0){this._locationStrategy.historyGo?.(e)}onUrlChange(e){return this._urlChangeListeners.push(e),this._urlChangeSubscription??=this.subscribe(t=>{this._notifyUrlChangeListeners(t.url,t.state)}),()=>{let t=this._urlChangeListeners.indexOf(e);this._urlChangeListeners.splice(t,1),this._urlChangeListeners.length===0&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(e="",t){this._urlChangeListeners.forEach(n=>n(e,t))}subscribe(e,t,n){return this._subject.subscribe({next:e,error:t??void 0,complete:n??void 0})}static normalizeQueryParams=Ji;static joinWithSlash=Sd;static stripTrailingSlash=Dd;static \u0275fac=function(t){return new(t||i)(ne(sr))};static \u0275prov=re({token:i,factory:()=>Lp(),providedIn:"root"})}return i})();function Lp(){return new lr(ne(sr))}function Vp(i,o){if(!i||!o.startsWith(i))return o;let e=o.substring(i.length);return e===""||["/",";","?","#"].includes(e[0])?e:o}function kd(i){return i.replace(/\/index\.html$/,"")}function Bp(i){if(new RegExp("^(https?:)?//").test(i)){let[,e]=i.split(/\/\/[^\/]+/);return e}return i}var al=(function(i){return i[i.Decimal=0]="Decimal",i[i.Percent=1]="Percent",i[i.Currency=2]="Currency",i[i.Scientific=3]="Scientific",i})(al||{});var ft=(function(i){return i[i.Format=0]="Format",i[i.Standalone=1]="Standalone",i})(ft||{}),Re=(function(i){return i[i.Narrow=0]="Narrow",i[i.Abbreviated=1]="Abbreviated",i[i.Wide=2]="Wide",i[i.Short=3]="Short",i})(Re||{}),Tt=(function(i){return i[i.Short=0]="Short",i[i.Medium=1]="Medium",i[i.Long=2]="Long",i[i.Full=3]="Full",i})(Tt||{}),It={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 Id(i){return jt(i)[Je.LocaleId]}function Rd(i,o,e){let t=jt(i),n=[t[Je.DayPeriodsFormat],t[Je.DayPeriodsStandalone]],a=Zt(n,o);return Zt(a,e)}function Od(i,o,e){let t=jt(i),n=[t[Je.DaysFormat],t[Je.DaysStandalone]],a=Zt(n,o);return Zt(a,e)}function Pd(i,o,e){let t=jt(i),n=[t[Je.MonthsFormat],t[Je.MonthsStandalone]],a=Zt(n,o);return Zt(a,e)}function Fd(i,o){let t=jt(i)[Je.Eras];return Zt(t,o)}function Yo(i,o){let e=jt(i);return Zt(e[Je.DateFormat],o)}function Xo(i,o){let e=jt(i);return Zt(e[Je.TimeFormat],o)}function Zo(i,o){let t=jt(i)[Je.DateTimeFormat];return Zt(t,o)}function ki(i,o){let e=jt(i),t=e[Je.NumberSymbols][o];if(typeof t>"u"){if(o===It.CurrencyDecimal)return e[Je.NumberSymbols][It.Decimal];if(o===It.CurrencyGroup)return e[Je.NumberSymbols][It.Group]}return t}function Nd(i,o){return jt(i)[Je.NumberFormats][o]}function Ld(i){if(!i[Je.ExtraData])throw new ae(2303,!1)}function Vd(i){let o=jt(i);return Ld(o),(o[Je.ExtraData][2]||[]).map(t=>typeof t=="string"?Js(t):[Js(t[0]),Js(t[1])])}function Bd(i,o,e){let t=jt(i);Ld(t);let n=[t[Je.ExtraData][0],t[Je.ExtraData][1]],a=Zt(n,o)||[];return Zt(a,e)||[]}function Zt(i,o){for(let e=o;e>-1;e--)if(typeof i[e]<"u")return i[e];throw new ae(2304,!1)}function Js(i){let[o,e]=i.split(":");return{hours:+o,minutes:+e}}var zp=/^(\d{4,})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/,cr={},jp=/((?:[^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]*)/,Hp=256;function zd(i,o,e,t){let n=Qp(i);Up(o),o=Fi(e,o)||o;let r=[],u;for(;o;)if(u=jp.exec(o),u){r=r.concat(u.slice(1));let _=r.pop();if(!_)break;o=_}else{r.push(o);break}let h=n.getTimezoneOffset();t&&(h=Hd(t,h),n=Zp(n,t));let g="";return r.forEach(_=>{let w=Yp(_);g+=w?w(n,e,h):_==="''"?"'":_.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),g}function Up(i){if(i.length>Hp)throw new ae(2300,!1)}function pr(i,o,e){let t=new Date(0);return t.setFullYear(i,o,e),t.setHours(0,0,0),t}function Fi(i,o){let e=Id(i);if(cr[e]??={},cr[e][o])return cr[e][o];let t="";switch(o){case"shortDate":t=Yo(i,Tt.Short);break;case"mediumDate":t=Yo(i,Tt.Medium);break;case"longDate":t=Yo(i,Tt.Long);break;case"fullDate":t=Yo(i,Tt.Full);break;case"shortTime":t=Xo(i,Tt.Short);break;case"mediumTime":t=Xo(i,Tt.Medium);break;case"longTime":t=Xo(i,Tt.Long);break;case"fullTime":t=Xo(i,Tt.Full);break;case"short":let n=Fi(i,"shortTime"),a=Fi(i,"shortDate");t=dr(Zo(i,Tt.Short),[n,a]);break;case"medium":let r=Fi(i,"mediumTime"),u=Fi(i,"mediumDate");t=dr(Zo(i,Tt.Medium),[r,u]);break;case"long":let h=Fi(i,"longTime"),g=Fi(i,"longDate");t=dr(Zo(i,Tt.Long),[h,g]);break;case"full":let _=Fi(i,"fullTime"),w=Fi(i,"fullDate");t=dr(Zo(i,Tt.Full),[_,w]);break}return t&&(cr[e][o]=t),t}function dr(i,o){return o&&(i=i.replace(/\{([^}]+)}/g,function(e,t){return Object.hasOwn(o,t)?o[t]:e})),i}function pi(i,o,e="-",t,n){let a="";(i<0||n&&i<=0)&&(n?i=-i+1:(i=-i,a=e));let r=String(i);for(;r.length<o;)r="0"+r;return t&&(r=r.slice(r.length-o)),a+r}function Gp(i,o){return pi(i,3).substring(0,o)}function tt(i,o,e=0,t=!1,n=!1){return function(a,r){let u=$p(i,a);if((e>0||u>-e)&&(u+=e),i===3)u===0&&e===-12&&(u=12);else if(i===6)return Gp(u,o);let h=ki(r,It.MinusSign);return pi(u,o,h,t,n)}}function $p(i,o){switch(i){case 0:return o.getFullYear();case 1:return o.getMonth();case 2:return o.getDate();case 3:return o.getHours();case 4:return o.getMinutes();case 5:return o.getSeconds();case 6:return o.getMilliseconds();case 7:return o.getDay();default:throw new ae(2301,!1)}}function Le(i,o,e=ft.Format,t=!1){return function(n,a){return Wp(n,a,i,o,e,t)}}function Wp(i,o,e,t,n,a){switch(e){case 2:return Pd(o,n,t)[i.getMonth()];case 1:return Od(o,n,t)[i.getDay()];case 0:let r=i.getHours(),u=i.getMinutes();if(a){let g=Vd(o),_=Bd(o,n,t),w=g.findIndex(B=>{if(Array.isArray(B)){let[G,ie]=B,fe=r>=G.hours&&u>=G.minutes,se=r<ie.hours||r===ie.hours&&u<ie.minutes;if(G.hours<ie.hours){if(fe&&se)return!0}else if(fe||se)return!0}else if(B.hours===r&&B.minutes===u)return!0;return!1});if(w!==-1)return _[w]}return Rd(o,n,t)[r<12?0:1];case 3:return Fd(o,t)[i.getFullYear()<=0?0:1];default:let h=e;throw new ae(2302,!1)}}function mr(i){return function(o,e,t){let n=-1*t,a=ki(e,It.MinusSign),r=n>0?Math.floor(n/60):Math.ceil(n/60);switch(i){case 0:return(n>=0?"+":"")+pi(r,2,a)+pi(Math.abs(n%60),2,a);case 1:return"GMT"+(n>=0?"+":"")+pi(r,1,a);case 2:return"GMT"+(n>=0?"+":"")+pi(r,2,a)+":"+pi(Math.abs(n%60),2,a);case 3:return t===0?"Z":(n>=0?"+":"")+pi(r,2,a)+":"+pi(Math.abs(n%60),2,a);default:throw new ae(2310,!1)}}}var qp=0,hr=4;function Kp(i){let o=pr(i,qp,1).getDay();return pr(i,0,1+(o<=hr?hr:hr+7)-o)}function jd(i){let o=i.getDay(),e=o===0?-3:hr-o;return pr(i.getFullYear(),i.getMonth(),i.getDate()+e)}function el(i,o=!1){return function(e,t){let n;if(o){let a=new Date(e.getFullYear(),e.getMonth(),1).getDay()-1,r=e.getDate();n=1+Math.floor((r+a)/7)}else{let a=jd(e),r=Kp(a.getFullYear()),u=a.getTime()-r.getTime();n=1+Math.round(u/6048e5)}return pi(n,i,ki(t,It.MinusSign))}}function ur(i,o=!1){return function(e,t){let a=jd(e).getFullYear();return pi(a,i,ki(t,It.MinusSign),o)}}var tl={};function Yp(i){if(tl[i])return tl[i];let o;switch(i){case"G":case"GG":case"GGG":o=Le(3,Re.Abbreviated);break;case"GGGG":o=Le(3,Re.Wide);break;case"GGGGG":o=Le(3,Re.Narrow);break;case"y":o=tt(0,1,0,!1,!0);break;case"yy":o=tt(0,2,0,!0,!0);break;case"yyy":o=tt(0,3,0,!1,!0);break;case"yyyy":o=tt(0,4,0,!1,!0);break;case"Y":o=ur(1);break;case"YY":o=ur(2,!0);break;case"YYY":o=ur(3);break;case"YYYY":o=ur(4);break;case"M":case"L":o=tt(1,1,1);break;case"MM":case"LL":o=tt(1,2,1);break;case"MMM":o=Le(2,Re.Abbreviated);break;case"MMMM":o=Le(2,Re.Wide);break;case"MMMMM":o=Le(2,Re.Narrow);break;case"LLL":o=Le(2,Re.Abbreviated,ft.Standalone);break;case"LLLL":o=Le(2,Re.Wide,ft.Standalone);break;case"LLLLL":o=Le(2,Re.Narrow,ft.Standalone);break;case"w":o=el(1);break;case"ww":o=el(2);break;case"W":o=el(1,!0);break;case"d":o=tt(2,1);break;case"dd":o=tt(2,2);break;case"c":case"cc":o=tt(7,1);break;case"ccc":o=Le(1,Re.Abbreviated,ft.Standalone);break;case"cccc":o=Le(1,Re.Wide,ft.Standalone);break;case"ccccc":o=Le(1,Re.Narrow,ft.Standalone);break;case"cccccc":o=Le(1,Re.Short,ft.Standalone);break;case"E":case"EE":case"EEE":o=Le(1,Re.Abbreviated);break;case"EEEE":o=Le(1,Re.Wide);break;case"EEEEE":o=Le(1,Re.Narrow);break;case"EEEEEE":o=Le(1,Re.Short);break;case"a":case"aa":case"aaa":o=Le(0,Re.Abbreviated);break;case"aaaa":o=Le(0,Re.Wide);break;case"aaaaa":o=Le(0,Re.Narrow);break;case"b":case"bb":case"bbb":o=Le(0,Re.Abbreviated,ft.Standalone,!0);break;case"bbbb":o=Le(0,Re.Wide,ft.Standalone,!0);break;case"bbbbb":o=Le(0,Re.Narrow,ft.Standalone,!0);break;case"B":case"BB":case"BBB":o=Le(0,Re.Abbreviated,ft.Format,!0);break;case"BBBB":o=Le(0,Re.Wide,ft.Format,!0);break;case"BBBBB":o=Le(0,Re.Narrow,ft.Format,!0);break;case"h":o=tt(3,1,-12);break;case"hh":o=tt(3,2,-12);break;case"H":o=tt(3,1);break;case"HH":o=tt(3,2);break;case"m":o=tt(4,1);break;case"mm":o=tt(4,2);break;case"s":o=tt(5,1);break;case"ss":o=tt(5,2);break;case"S":o=tt(6,1);break;case"SS":o=tt(6,2);break;case"SSS":o=tt(6,3);break;case"Z":case"ZZ":case"ZZZ":o=mr(0);break;case"ZZZZZ":o=mr(3);break;case"O":case"OO":case"OOO":case"z":case"zz":case"zzz":o=mr(1);break;case"OOOO":case"ZZZZ":case"zzzz":o=mr(2);break;default:return null}return tl[i]=o,o}function Hd(i,o){i=i.replace(/:/g,"");let e=Date.parse("Jan 01, 1970 00:00:00 "+i)/6e4;return isNaN(e)?o:e}function Xp(i,o){return i=new Date(i.getTime()),i.setMinutes(i.getMinutes()+o),i}function Zp(i,o,e){let n=i.getTimezoneOffset(),a=Hd(o,n);return Xp(i,-1*(a-n))}function Qp(i){if(Md(i))return i;if(typeof i=="number"&&!isNaN(i))return new Date(i);if(typeof i=="string"){if(i=i.trim(),/^(\d{4}(-\d{1,2}(-\d{1,2})?)?)$/.test(i)){let[n,a=1,r=1]=i.split("-").map(u=>+u);return pr(n,a-1,r)}let e=parseFloat(i);if(!isNaN(i-e))return new Date(e);let t;if(t=i.match(zp))return Jp(t)}let o=new Date(i);if(!Md(o))throw new ae(2311,!1);return o}function Jp(i){let o=new Date(0),e=0,t=0,n=i[8]?o.setUTCFullYear:o.setFullYear,a=i[8]?o.setUTCHours:o.setHours;i[9]&&(e=Number(i[9]+i[10]),t=Number(i[9]+i[11])),n.call(o,Number(i[1]),Number(i[2])-1,Number(i[3]));let r=Number(i[4]||0)-e,u=Number(i[5]||0)-t,h=Number(i[6]||0),g=Math.floor(parseFloat("0."+(i[7]||0))*1e3);return a.call(o,r,u,h,g),o}function Md(i){return i instanceof Date&&!isNaN(i.valueOf())}var ef=/^(\d+)?\.((\d+)(-(\d+))?)?$/,Ed=22,fr=".",Qo="0",tf=";",nf=",",il="#";function of(i,o,e,t,n,a,r=!1){let u="",h=!1;if(!isFinite(i))u=ki(e,It.Infinity);else{let g=sf(i);r&&(g=rf(g));let _=o.minInt,w=o.minFrac,B=o.maxFrac;if(a){let lt=a.match(ef);if(lt===null)throw new ae(2306,!1);let li=lt[1],Ci=lt[3],Ki=lt[5];li!=null&&(_=nl(li)),Ci!=null&&(w=nl(Ci)),Ki!=null?B=nl(Ki):Ci!=null&&w>B&&(B=w);let ci=100;if(_>ci||w>ci||B>ci)throw new ae(2306,!1)}lf(g,w,B);let G=g.digits,ie=g.integerLen,fe=g.exponent,se=[];for(h=G.every(lt=>!lt);ie<_;ie++)G.unshift(0);for(;ie<0;ie++)G.unshift(0);ie>0?se=G.splice(ie,G.length):(se=G,G=[0]);let Ae=[];for(G.length>=o.lgSize&&Ae.unshift(G.splice(-o.lgSize,G.length).join(""));G.length>o.gSize;)Ae.unshift(G.splice(-o.gSize,G.length).join(""));G.length&&Ae.unshift(G.join("")),u=Ae.join(ki(e,t)),se.length&&(u+=ki(e,n)+se.join("")),fe&&(u+=ki(e,It.Exponential)+"+"+fe)}return i<0&&!h?u=o.negPre+u+o.negSuf:u=o.posPre+u+o.posSuf,u}function Ud(i,o,e){let t=Nd(o,al.Decimal),n=af(t,ki(o,It.MinusSign));return of(i,n,o,It.Group,It.Decimal,e)}function af(i,o="-"){let e={minInt:1,minFrac:0,maxFrac:0,posPre:"",posSuf:"",negPre:"",negSuf:"",gSize:0,lgSize:0},t=i.split(tf),n=t[0],a=t[1],r=n.indexOf(fr)!==-1?n.split(fr):[n.substring(0,n.lastIndexOf(Qo)+1),n.substring(n.lastIndexOf(Qo)+1)],u=r[0],h=r[1]||"";e.posPre=u.substring(0,u.indexOf(il));for(let _=0;_<h.length;_++){let w=h.charAt(_);w===Qo?e.minFrac=e.maxFrac=_+1:w===il?e.maxFrac=_+1:e.posSuf+=w}let g=u.split(nf);if(e.gSize=g[1]?g[1].length:0,e.lgSize=g[2]||g[1]?(g[2]||g[1]).length:0,a){let _=n.length-e.posPre.length-e.posSuf.length,w=a.indexOf(il);e.negPre=a.substring(0,w).replace(/'/g,""),e.negSuf=a.slice(w+_).replace(/'/g,"")}else e.negPre=o+e.posPre,e.negSuf=e.posSuf;return e}function rf(i){if(i.digits[0]===0)return i;let o=i.digits.length-i.integerLen;return i.exponent?i.exponent+=2:(o===0?i.digits.push(0,0):o===1&&i.digits.push(0),i.integerLen+=2),i}function sf(i){let o=Math.abs(i)+"",e=0,t,n,a,r,u;for((n=o.indexOf(fr))>-1&&(o=o.replace(fr,"")),(a=o.search(/e/i))>0?(n<0&&(n=a),n+=+o.slice(a+1),o=o.substring(0,a)):n<0&&(n=o.length),a=0;o.charAt(a)===Qo;a++);if(a===(u=o.length))t=[0],n=1;else{for(u--;o.charAt(u)===Qo;)u--;for(n-=a,t=[],r=0;a<=u;a++,r++)t[r]=Number(o.charAt(a))}return n>Ed&&(t=t.splice(0,Ed-1),e=n-1,n=1),{digits:t,exponent:e,integerLen:n}}function lf(i,o,e){if(o>e)throw new ae(2307,!1);let t=i.digits,n=t.length-i.integerLen,a=Math.min(Math.max(o,n),e),r=a+i.integerLen,u=t[r];if(r>0){t.splice(Math.max(i.integerLen,r));for(let w=r;w<t.length;w++)t[w]=0}else{n=Math.max(0,n),i.integerLen=1,t.length=Math.max(1,r=a+1),t[0]=0;for(let w=1;w<r;w++)t[w]=0}if(u>=5)if(r-1<0){for(let w=0;w>r;w--)t.unshift(0),i.integerLen++;t.unshift(1),i.integerLen++}else t[r-1]++;for(;n<Math.max(0,a);n++)t.push(0);let h=a!==0,g=o+i.integerLen,_=t.reduceRight(function(w,B,G,ie){return B=B+w,ie[G]=B<10?B:B-10,h&&(ie[G]===0&&G>=g?ie.pop():h=!1),B>=10?1:0},0);_&&(t.unshift(_),i.integerLen++)}function nl(i){let o=parseInt(i);if(isNaN(o))throw new ae(2305,!1);return o}var ol=/\s+/,Ad=[],rl=(()=>{class i{_ngEl;_renderer;initialClasses=Ad;rawClass;stateMap=new Map;constructor(e,t){this._ngEl=e,this._renderer=t}set klass(e){this.initialClasses=e!=null?e.trim().split(ol):Ad}set ngClass(e){this.rawClass=typeof e=="string"?e.trim().split(ol):e}ngDoCheck(){for(let t of this.initialClasses)this._updateState(t,!0);let e=this.rawClass;if(Array.isArray(e)||e instanceof Set)for(let t of e)this._updateState(t,!0);else if(e!=null)for(let t of Object.keys(e))this._updateState(t,!!e[t]);this._applyStateDiff()}_updateState(e,t){let n=this.stateMap.get(e);n!==void 0?(n.enabled!==t&&(n.changed=!0,n.enabled=t),n.touched=!0):this.stateMap.set(e,{enabled:t,changed:!0,touched:!0})}_applyStateDiff(){for(let e of this.stateMap){let t=e[0],n=e[1];n.changed?(this._toggleClass(t,n.enabled),n.changed=!1):n.touched||(n.enabled&&this._toggleClass(t,!1),this.stateMap.delete(t)),n.touched=!1}}_toggleClass(e,t){e=e.trim(),e.length>0&&e.split(ol).forEach(n=>{t?this._renderer.addClass(this._ngEl.nativeElement,n):this._renderer.removeClass(this._ngEl.nativeElement,n)})}static \u0275fac=function(t){return new(t||i)(de(N),de(ve))};static \u0275dir=k({type:i,selectors:[["","ngClass",""]],inputs:{klass:[0,"class","klass"],ngClass:"ngClass"}})}return i})();var sl=(()=>{class i{_viewContainerRef;_viewRef=null;ngTemplateOutletContext=null;ngTemplateOutlet=null;ngTemplateOutletInjector=null;injector=d(X);constructor(e){this._viewContainerRef=e}ngOnChanges(e){if(this._shouldRecreateView(e)){let t=this._viewContainerRef;if(this._viewRef&&t.remove(t.indexOf(this._viewRef)),!this.ngTemplateOutlet){this._viewRef=null;return}let n=this._createContextForwardProxy();this._viewRef=t.createEmbeddedView(this.ngTemplateOutlet,n,{injector:this._getInjector()})}}_getInjector(){return this.ngTemplateOutletInjector==="outlet"?this.injector:this.ngTemplateOutletInjector??void 0}_shouldRecreateView(e){return!!e.ngTemplateOutlet||!!e.ngTemplateOutletInjector}_createContextForwardProxy(){return new Proxy({},{set:(e,t,n)=>this.ngTemplateOutletContext?Reflect.set(this.ngTemplateOutletContext,t,n):!1,get:(e,t,n)=>{if(this.ngTemplateOutletContext)return Reflect.get(this.ngTemplateOutletContext,t,n)}})}static \u0275fac=function(t){return new(t||i)(de(Xe))};static \u0275dir=k({type:i,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet",ngTemplateOutletInjector:"ngTemplateOutletInjector"},features:[Se]})}return i})();function Gd(i,o){return new ae(2100,!1)}var cf="mediumDate",$d=new x(""),Wd=new x(""),ll=(()=>{class i{locale;defaultTimezone;defaultOptions;constructor(e,t,n){this.locale=e,this.defaultTimezone=t,this.defaultOptions=n}transform(e,t,n,a){if(e==null||e===""||e!==e)return null;try{let r=t??this.defaultOptions?.dateFormat??cf,u=n??this.defaultOptions?.timezone??this.defaultTimezone??void 0;return zd(e,r,a||this.locale,u)}catch(r){throw Gd(i,r.message)}}static \u0275fac=function(t){return new(t||i)(de(Zs,16),de($d,24),de(Wd,24))};static \u0275pipe=qs({name:"date",type:i,pure:!0})}return i})();var cl=(()=>{class i{_locale;constructor(e){this._locale=e}transform(e,t,n){if(!df(e))return null;n||=this._locale;try{let a=mf(e);return Ud(a,n,t)}catch(a){throw Gd(i,a.message)}}static \u0275fac=function(t){return new(t||i)(de(Zs,16))};static \u0275pipe=qs({name:"number",type:i,pure:!0})}return i})();function df(i){return!(i==null||i===""||i!==i)}function mf(i){if(typeof i=="string"&&!isNaN(Number(i)-parseFloat(i)))return Number(i);if(typeof i!="number")throw new ae(2309,!1);return i}var Ve=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();function Jo(i,o){o=encodeURIComponent(o);for(let e of i.split(";")){let t=e.indexOf("="),[n,a]=t==-1?[e,""]:[e.slice(0,t),e.slice(t+1)];if(n.trim()===o)return decodeURIComponent(a)}return null}var dl="browser";function qd(i){return i===dl}var ea=class{_doc;constructor(o){this._doc=o}manager},gr=(()=>{class i extends ea{constructor(e){super(e)}supports(e){return!0}addEventListener(e,t,n,a){return e.addEventListener(t,n,a),()=>this.removeEventListener(e,t,n,a)}removeEventListener(e,t,n,a){return e.removeEventListener(t,n,a)}static \u0275fac=function(t){return new(t||i)(ne(W))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})(),br=new x(""),pl=(()=>{class i{_zone;_plugins;_eventNameToPlugin=new Map;constructor(e,t){this._zone=t,e.forEach(r=>{r.manager=this});let n=e.filter(r=>!(r instanceof gr));this._plugins=n.slice().reverse();let a=e.find(r=>r instanceof gr);a&&this._plugins.push(a)}addEventListener(e,t,n,a){return this._findPluginFor(t).addEventListener(e,t,n,a)}getZone(){return this._zone}_findPluginFor(e){let t=this._eventNameToPlugin.get(e);if(t)return t;if(t=this._plugins.find(a=>a.supports(e)),!t)throw new ae(-5101,!1);return this._eventNameToPlugin.set(e,t),t}static \u0275fac=function(t){return new(t||i)(ne(br),ne(H))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})(),ml="ng-app-id";function Yd(i){for(let o of i)o.remove()}function Xd(i,o){let e=o.createElement("style");return e.textContent=i,e}function pf(i,o,e,t){let n=i.head?.querySelectorAll(`style[${ml}="${o}"],link[${ml}="${o}"]`);if(!n||n.length===0)return!1;for(let a of n)a.removeAttribute(ml),a instanceof HTMLLinkElement?t.set(a.href.slice(a.href.lastIndexOf("/")+1),{usage:0,elements:[a]}):a.textContent&&e.set(a.textContent,{usage:0,elements:[a]});return!0}function hl(i,o){let e=o.createElement("link");return e.setAttribute("rel","stylesheet"),e.setAttribute("href",i),e}var fl=(()=>{class i{doc;appId;nonce;inline=new Map;external=new Map;hosts=new Set;constructor(e,t,n,a={}){this.doc=e,this.appId=t,this.nonce=n,pf(e,t,this.inline,this.external)&&this.hosts.add(e.head)}addStyles(e,t){for(let n of e)this.addUsage(n,this.inline,Xd);t?.forEach(n=>this.addUsage(n,this.external,hl))}removeStyles(e,t){for(let n of e)this.removeUsage(n,this.inline);t?.forEach(n=>this.removeUsage(n,this.external))}addUsage(e,t,n){let a=t.get(e);a?a.usage++:t.set(e,{usage:1,elements:[...this.hosts].map(r=>this.addElement(r,n(e,this.doc)))})}removeUsage(e,t){let n=t.get(e);n&&(n.usage--,n.usage<=0&&(Yd(n.elements),t.delete(e)))}ngOnDestroy(){for(let[,{elements:e}]of[...this.inline,...this.external])Yd(e);this.hosts.clear()}addHost(e){if(!this.hosts.has(e)){this.hosts.add(e);for(let[t,{elements:n}]of this.inline)n.push(this.addElement(e,Xd(t,this.doc)));for(let[t,{elements:n}]of this.external)n.push(this.addElement(e,hl(t,this.doc)))}}removeHost(e){this.hosts.delete(e);for(let t of[...this.inline.values(),...this.external.values()]){let n=[];for(let a of t.elements)a.parentNode===e?a.remove():n.push(a);t.elements=n}}addElement(e,t){return this.nonce&&t.setAttribute("nonce",this.nonce),e.appendChild(t)}static \u0275fac=function(t){return new(t||i)(ne(W),ne(En),ne(to,8),ne(eo))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})(),ul={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"},gl=/%COMP%/g;var Qd="%COMP%",ff=`_nghost-${Qd}`,gf=`_ngcontent-${Qd}`,_f=!0,vf=new x("",{factory:()=>_f});function bf(i){return gf.replace(gl,i)}function yf(i){return ff.replace(gl,i)}function Jd(i,o){return o.map(e=>e.replace(gl,i))}var Tn=(()=>{class i{eventManager;sharedStylesHost;appId;removeStylesOnCompDestroy;doc;ngZone;nonce;tracingService;rendererByCompId=new Map;defaultRenderer;constructor(e,t,n,a,r,u,h=null,g=null){this.eventManager=e,this.sharedStylesHost=t,this.appId=n,this.removeStylesOnCompDestroy=a,this.doc=r,this.ngZone=u,this.nonce=h,this.tracingService=g,this.defaultRenderer=new ta(e,r,u,this.tracingService)}createRenderer(e,t){if(!e||!t)return this.defaultRenderer;let n=this.getOrCreateRenderer(e,t);return n instanceof vr?n.applyToHost(e):n instanceof ia&&n.applyStyles(),n}getOrCreateRenderer(e,t){let n=this.rendererByCompId,a=n.get(t.id);if(!a){let r=this.doc,u=this.ngZone,h=this.eventManager,g=this.sharedStylesHost,_=this.removeStylesOnCompDestroy,w=this.tracingService;switch(t.encapsulation){case Qa.Emulated:a=new vr(h,g,t,this.appId,_,r,u,w);break;case Qa.ShadowDom:return new _r(h,e,t,r,u,this.nonce,w,g);case Qa.ExperimentalIsolatedShadowDom:return new _r(h,e,t,r,u,this.nonce,w);default:a=new ia(h,g,t,_,r,u,w);break}n.set(t.id,a)}return a}ngOnDestroy(){this.rendererByCompId.clear()}componentReplaced(e){this.rendererByCompId.delete(e)}static \u0275fac=function(t){return new(t||i)(ne(pl),ne(Ho),ne(En),ne(vf),ne(W),ne(H),ne(to),ne($s,8))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})(),ta=class{eventManager;doc;ngZone;tracingService;data=Object.create(null);throwOnSyntheticProps=!0;constructor(o,e,t,n){this.eventManager=o,this.doc=e,this.ngZone=t,this.tracingService=n}destroy(){}destroyNode=null;createElement(o,e){return e?this.doc.createElementNS(ul[e]||e,o):this.doc.createElement(o)}createComment(o){return this.doc.createComment(o)}createText(o){return this.doc.createTextNode(o)}appendChild(o,e){(Zd(o)?o.content:o).appendChild(e)}insertBefore(o,e,t){o&&(Zd(o)?o.content:o).insertBefore(e,t)}removeChild(o,e){e.remove()}selectRootElement(o,e){let t=typeof o=="string"?this.doc.querySelector(o):o;if(!t)throw new ae(-5104,!1);return e||(t.textContent=""),t}parentNode(o){return o.parentNode}nextSibling(o){return o.nextSibling}setAttribute(o,e,t,n){if(n){e=n+":"+e;let a=ul[n];a?o.setAttributeNS(a,e,t):o.setAttribute(e,t)}else o.setAttribute(e,t)}removeAttribute(o,e,t){if(t){let n=ul[t];n?o.removeAttributeNS(n,e):o.removeAttribute(`${t}:${e}`)}else o.removeAttribute(e)}addClass(o,e){o.classList.add(e)}removeClass(o,e){o.classList.remove(e)}setStyle(o,e,t,n){n&(oo.DashCase|oo.Important)?o.style.setProperty(e,t,n&oo.Important?"important":""):o.style[e]=t}removeStyle(o,e,t){t&oo.DashCase?o.style.removeProperty(e):o.style[e]=""}setProperty(o,e,t){o!=null&&(o[e]=t)}setValue(o,e){o.nodeValue=e}listen(o,e,t,n){if(typeof o=="string"&&(o=Xt().getGlobalEventTarget(this.doc,o),!o))throw new ae(-5102,!1);let a=this.decoratePreventDefault(t);return this.tracingService?.wrapEventListener&&(a=this.tracingService.wrapEventListener(o,e,a)),this.eventManager.addEventListener(o,e,a,n)}decoratePreventDefault(o){return e=>{if(e==="__ngUnwrap__")return o;o(e)===!1&&e.preventDefault()}}};function Zd(i){return i.tagName==="TEMPLATE"&&i.content!==void 0}var _r=class extends ta{hostEl;sharedStylesHost;shadowRoot;constructor(o,e,t,n,a,r,u,h){super(o,n,a,u),this.hostEl=e,this.sharedStylesHost=h,this.shadowRoot=e.attachShadow({mode:"open"}),this.sharedStylesHost&&this.sharedStylesHost.addHost(this.shadowRoot);let g=t.styles;g=Jd(t.id,g);for(let w of g){let B=document.createElement("style");r&&B.setAttribute("nonce",r),B.textContent=w,this.shadowRoot.appendChild(B)}let _=t.getExternalStyles?.();if(_)for(let w of _){let B=hl(w,n);r&&B.setAttribute("nonce",r),this.shadowRoot.appendChild(B)}}nodeOrShadowRoot(o){return o===this.hostEl?this.shadowRoot:o}appendChild(o,e){return super.appendChild(this.nodeOrShadowRoot(o),e)}insertBefore(o,e,t){return super.insertBefore(this.nodeOrShadowRoot(o),e,t)}removeChild(o,e){return super.removeChild(null,e)}parentNode(o){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(o)))}destroy(){this.sharedStylesHost&&this.sharedStylesHost.removeHost(this.shadowRoot)}},ia=class extends ta{sharedStylesHost;removeStylesOnCompDestroy;styles;styleUrls;constructor(o,e,t,n,a,r,u,h){super(o,a,r,u),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=n;let g=t.styles;this.styles=h?Jd(h,g):g,this.styleUrls=t.getExternalStyles?.(h)}applyStyles(){this.sharedStylesHost.addStyles(this.styles,this.styleUrls)}destroy(){this.removeStylesOnCompDestroy&&cd.size===0&&this.sharedStylesHost.removeStyles(this.styles,this.styleUrls)}},vr=class extends ia{contentAttr;hostAttr;constructor(o,e,t,n,a,r,u,h){let g=n+"-"+t.id;super(o,e,t,a,r,u,h,g),this.contentAttr=bf(g),this.hostAttr=yf(g)}applyToHost(o){this.applyStyles(),this.setAttribute(o,this.hostAttr,"")}createElement(o,e){let t=super.createElement(o,e);return super.setAttribute(t,this.contentAttr,""),t}};var yr=class i extends Ko{supportsDOMEvents=!0;static makeCurrent(){Qs(new i)}onAndCancel(o,e,t,n){return o.addEventListener(e,t,n),()=>{o.removeEventListener(e,t,n)}}dispatchEvent(o,e){o.dispatchEvent(e)}remove(o){o.remove()}createElement(o,e){return e=e||this.getDefaultDocument(),e.createElement(o)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(o){return o.nodeType===Node.ELEMENT_NODE}isShadowRoot(o){return o instanceof DocumentFragment}getGlobalEventTarget(o,e){return e==="window"?window:e==="document"?o:e==="body"?o.body:null}getBaseHref(o){let e=xf();return e==null?null:wf(e)}resetBaseElement(){na=null}getUserAgent(){return window.navigator.userAgent}getCookie(o){return Jo(document.cookie,o)}},na=null;function xf(){return na=na||document.head.querySelector("base"),na?na.getAttribute("href"):null}function wf(i){return new URL(i,document.baseURI).pathname}var em=["alt","control","meta","shift"],Df={"\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"},kf={alt:i=>i.altKey,control:i=>i.ctrlKey,meta:i=>i.metaKey,shift:i=>i.shiftKey},tm=(()=>{class i extends ea{constructor(e){super(e)}supports(e){return i.parseEventName(e)!=null}addEventListener(e,t,n,a){let r=i.parseEventName(t),u=i.eventCallback(r.fullKey,n,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Xt().onAndCancel(e,r.domEventName,u,a))}static parseEventName(e){let t=e.toLowerCase().split("."),n=t.shift();if(t.length===0||!(n==="keydown"||n==="keyup"))return null;let a=i._normalizeKey(t.pop()),r="",u=t.indexOf("code");if(u>-1&&(t.splice(u,1),r="code."),em.forEach(g=>{let _=t.indexOf(g);_>-1&&(t.splice(_,1),r+=g+".")}),r+=a,t.length!=0||a.length===0)return null;let h={};return h.domEventName=n,h.fullKey=r,h}static matchEventFullKeyCode(e,t){let n=Df[e.key]||e.key,a="";return t.indexOf("code.")>-1&&(n=e.code,a="code."),n==null||!n?!1:(n=n.toLowerCase(),n===" "?n="space":n==="."&&(n="dot"),em.forEach(r=>{if(r!==n){let u=kf[r];u(e)&&(a+=r+".")}}),a+=n,a===t)}static eventCallback(e,t,n){return a=>{i.matchEventFullKeyCode(a,e)&&n.runGuarded(()=>t(a))}}static _normalizeKey(e){return e==="esc"?"escape":e}static \u0275fac=function(t){return new(t||i)(ne(W))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})();function _l(i,o,e){return ye(this,null,function*(){let t=V({rootComponent:i},Sf(o,e));return gd(t)})}function Sf(i,o){return{platformRef:o?.platformRef,appProviders:[...If,...i?.providers??[]],platformProviders:Tf}}function Mf(){yr.makeCurrent()}function Ef(){return new Mn}function Af(){return td(document),document}var Tf=[{provide:eo,useValue:dl},{provide:Jc,useValue:Mf,multi:!0},{provide:W,useFactory:Af}];var If=[{provide:Zc,useValue:"root"},{provide:Mn,useFactory:Ef},{provide:br,useClass:gr,multi:!0},{provide:br,useClass:tm,multi:!0},Tn,{provide:Ho,useClass:fl},{provide:fl,useExisting:Ho},pl,{provide:ot,useExisting:Tn},[]];var Li=class i{headers;normalizedNames=new Map;lazyInit;lazyUpdate=null;constructor(o){o?typeof o=="string"?this.lazyInit=()=>{this.headers=new Map,o.split(`
2
+ `).forEach(e=>{let t=e.indexOf(":");if(t>0){let n=e.slice(0,t),a=e.slice(t+1).trim();this.addHeaderEntry(n,a)}})}:typeof Headers<"u"&&o instanceof Headers?(this.headers=new Map,o.forEach((e,t)=>{this.addHeaderEntry(t,e)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(o).forEach(([e,t])=>{this.setHeaderEntries(e,t)})}:this.headers=new Map}has(o){return this.init(),this.headers.has(o.toLowerCase())}get(o){this.init();let e=this.headers.get(o.toLowerCase());return e&&e.length>0?e[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(o){return this.init(),this.headers.get(o.toLowerCase())||null}append(o,e){return this.clone({name:o,value:e,op:"a"})}set(o,e){return this.clone({name:o,value:e,op:"s"})}delete(o,e){return this.clone({name:o,value:e,op:"d"})}maybeSetNormalizedName(o,e){this.normalizedNames.has(e)||this.normalizedNames.set(e,o)}init(){this.lazyInit&&(this.lazyInit instanceof i?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(o=>this.applyUpdate(o)),this.lazyUpdate=null))}copyFrom(o){o.init(),Array.from(o.headers.keys()).forEach(e=>{this.headers.set(e,o.headers.get(e)),this.normalizedNames.set(e,o.normalizedNames.get(e))})}clone(o){let e=new i;return e.lazyInit=this.lazyInit&&this.lazyInit instanceof i?this.lazyInit:this,e.lazyUpdate=(this.lazyUpdate||[]).concat([o]),e}applyUpdate(o){let e=o.name.toLowerCase();switch(o.op){case"a":case"s":let t=o.value;if(typeof t=="string"&&(t=[t]),t.length===0)return;this.maybeSetNormalizedName(o.name,e);let n=(o.op==="a"?this.headers.get(e):void 0)||[];n.push(...t),this.headers.set(e,n);break;case"d":let a=o.value;if(!a)this.headers.delete(e),this.normalizedNames.delete(e);else{let r=this.headers.get(e);if(!r)return;r=r.filter(u=>a.indexOf(u)===-1),r.length===0?(this.headers.delete(e),this.normalizedNames.delete(e)):this.headers.set(e,r)}break}}addHeaderEntry(o,e){let t=o.toLowerCase();this.maybeSetNormalizedName(o,t),this.headers.has(t)?this.headers.get(t).push(e):this.headers.set(t,[e])}setHeaderEntries(o,e){let t=(Array.isArray(e)?e:[e]).map(a=>a.toString()),n=o.toLowerCase();this.headers.set(n,t),this.maybeSetNormalizedName(o,n)}forEach(o){this.init(),Array.from(this.normalizedNames.keys()).forEach(e=>o(this.normalizedNames.get(e),this.headers.get(e)))}};var xr=class{map=new Map;set(o,e){return this.map.set(o,e),this}get(o){return this.map.has(o)||this.map.set(o,o.defaultValue()),this.map.get(o)}delete(o){return this.map.delete(o),this}has(o){return this.map.has(o)}keys(){return this.map.keys()}},wr=class{encodeKey(o){return im(o)}encodeValue(o){return im(o)}decodeKey(o){return decodeURIComponent(o)}decodeValue(o){return decodeURIComponent(o)}};function Rf(i,o){let e=new Map;return i.length>0&&i.replace(/^\?/,"").split("&").forEach(n=>{let a=n.indexOf("="),[r,u]=a==-1?[o.decodeKey(n),""]:[o.decodeKey(n.slice(0,a)),o.decodeValue(n.slice(a+1))],h=e.get(r)||[];h.push(u),e.set(r,h)}),e}var Of=/%(\d[a-f0-9])/gi,Pf={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function im(i){return encodeURIComponent(i).replace(Of,(o,e)=>Pf[e]??o)}function Cr(i){return`${i}`}var Ni=class i{map;encoder;updates=null;cloneFrom=null;constructor(o={}){if(this.encoder=o.encoder||new wr,o.fromString){if(o.fromObject)throw new ae(2805,!1);this.map=Rf(o.fromString,this.encoder)}else o.fromObject?(this.map=new Map,Object.keys(o.fromObject).forEach(e=>{let t=o.fromObject[e],n=Array.isArray(t)?t.map(Cr):[Cr(t)];this.map.set(e,n)})):this.map=null}has(o){return this.init(),this.map.has(o)}get(o){this.init();let e=this.map.get(o);return e?e[0]:null}getAll(o){return this.init(),this.map.get(o)||null}keys(){return this.init(),Array.from(this.map.keys())}append(o,e){return this.clone({param:o,value:e,op:"a"})}appendAll(o){let e=[];return Object.keys(o).forEach(t=>{let n=o[t];Array.isArray(n)?n.forEach(a=>{e.push({param:t,value:a,op:"a"})}):e.push({param:t,value:n,op:"a"})}),this.clone(e)}set(o,e){return this.clone({param:o,value:e,op:"s"})}delete(o,e){return this.clone({param:o,value:e,op:"d"})}toString(){return this.init(),this.keys().map(o=>{let e=this.encoder.encodeKey(o);return this.map.get(o).map(t=>e+"="+this.encoder.encodeValue(t)).join("&")}).filter(o=>o!=="").join("&")}clone(o){let e=new i({encoder:this.encoder});return e.cloneFrom=this.cloneFrom||this,e.updates=(this.updates||[]).concat(o),e}init(){this.map===null&&(this.map=new Map),this.cloneFrom!==null&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(o=>this.map.set(o,this.cloneFrom.map.get(o))),this.updates.forEach(o=>{switch(o.op){case"a":case"s":let e=(o.op==="a"?this.map.get(o.param):void 0)||[];e.push(Cr(o.value)),this.map.set(o.param,e);break;case"d":if(o.value!==void 0){let t=this.map.get(o.param)||[],n=t.indexOf(Cr(o.value));n!==-1&&t.splice(n,1),t.length>0?this.map.set(o.param,t):this.map.delete(o.param)}else{this.map.delete(o.param);break}}}),this.cloneFrom=this.updates=null)}};function Ff(i){switch(i){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}function nm(i){return typeof ArrayBuffer<"u"&&i instanceof ArrayBuffer}function om(i){return typeof Blob<"u"&&i instanceof Blob}function am(i){return typeof FormData<"u"&&i instanceof FormData}function Nf(i){return typeof URLSearchParams<"u"&&i instanceof URLSearchParams}var vl="Content-Type",rm="Accept",lm="text/plain",cm="application/json",Lf=`${cm}, ${lm}, */*`,so=class i{url;body=null;headers;context;reportProgress=!1;reportUploadProgress=!1;reportDownloadProgress=!1;withCredentials=!1;credentials;keepalive=!1;cache;priority;mode;redirect;referrer;integrity;referrerPolicy;responseType="json";method;params;urlWithParams;transferCache;timeout;constructor(o,e,t,n){this.url=e,this.method=o.toUpperCase();let a;if(Ff(this.method)||n?(this.body=t!==void 0?t:null,a=n):a=t,a){if(this.reportProgress=!!a.reportProgress,this.reportUploadProgress=!!a.reportUploadProgress,this.reportDownloadProgress=!!a.reportDownloadProgress,this.withCredentials=!!a.withCredentials,this.keepalive=!!a.keepalive,a.responseType&&(this.responseType=a.responseType),a.headers&&(this.headers=a.headers),a.context&&(this.context=a.context),a.params&&(this.params=a.params),a.priority&&(this.priority=a.priority),a.cache&&(this.cache=a.cache),a.credentials&&(this.credentials=a.credentials),typeof a.timeout=="number"){if(a.timeout<1||!Number.isInteger(a.timeout))throw new ae(2822,"");this.timeout=a.timeout}a.mode&&(this.mode=a.mode),a.redirect&&(this.redirect=a.redirect),a.integrity&&(this.integrity=a.integrity),a.referrer!==void 0&&(this.referrer=a.referrer),a.referrerPolicy&&(this.referrerPolicy=a.referrerPolicy),this.transferCache=a.transferCache}if(this.headers??=new Li,this.context??=new xr,!this.params)this.params=new Ni,this.urlWithParams=e;else{let r=this.params.toString();if(r.length===0)this.urlWithParams=e;else{let u=e,h="",g=e.indexOf("#");g!==-1&&(h=e.substring(g),u=e.substring(0,g));let _=u.indexOf("?"),w=_===-1?"?":_<u.length-1?"&":"";this.urlWithParams=u+w+r+h}}}serializeBody(){return this.body===null?null:typeof this.body=="string"||nm(this.body)||om(this.body)||am(this.body)||Nf(this.body)?this.body:this.body instanceof Ni?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||am(this.body)?null:om(this.body)?this.body.type||null:nm(this.body)?null:typeof this.body=="string"?lm:this.body instanceof Ni?"application/x-www-form-urlencoded;charset=UTF-8":typeof this.body=="object"||typeof this.body=="number"||typeof this.body=="boolean"?cm:null}clone(o={}){let e=o.method||this.method,t=o.url||this.url,n=o.responseType||this.responseType,a=o.keepalive??this.keepalive,r=o.priority||this.priority,u=o.cache||this.cache,h=o.mode||this.mode,g=o.redirect||this.redirect,_=o.credentials||this.credentials,w=o.referrer??this.referrer,B=o.integrity||this.integrity,G=o.referrerPolicy||this.referrerPolicy,ie=o.transferCache??this.transferCache,fe=o.timeout??this.timeout,se=o.body!==void 0?o.body:this.body,Ae=o.withCredentials??this.withCredentials,lt=o.reportProgress??this.reportProgress,li=o.reportUploadProgress??this.reportUploadProgress,Ci=o.reportDownloadProgress??this.reportDownloadProgress,Ki=o.headers||this.headers,ci=o.params||this.params,Ga=o.context??this.context;return o.setHeaders!==void 0&&(Ki=Object.keys(o.setHeaders).reduce((Zn,Sn)=>Zn.set(Sn,o.setHeaders[Sn]),Ki)),o.setParams&&(ci=Object.keys(o.setParams).reduce((Zn,Sn)=>Zn.set(Sn,o.setParams[Sn]),ci)),new i(e,t,se,{params:ci,headers:Ki,context:Ga,reportProgress:lt,reportUploadProgress:li,reportDownloadProgress:Ci,responseType:n,withCredentials:Ae,transferCache:ie,keepalive:a,cache:u,priority:r,timeout:fe,mode:h,redirect:g,credentials:_,referrer:w,integrity:B,referrerPolicy:G})}},lo=(function(i){return i[i.Sent=0]="Sent",i[i.UploadProgress=1]="UploadProgress",i[i.ResponseHeader=2]="ResponseHeader",i[i.DownloadProgress=3]="DownloadProgress",i[i.Response=4]="Response",i[i.User=5]="User",i})(lo||{}),co=class{headers;status;statusText;url;ok;type;redirected;responseType;constructor(o,e=200,t="OK"){this.headers=o.headers||new Li,this.status=o.status!==void 0?o.status:e,this.statusText=o.statusText||t,this.url=o.url||null,this.redirected=o.redirected,this.responseType=o.responseType,this.ok=this.status>=200&&this.status<300}},Dr=class i extends co{constructor(o={}){super(o)}type=lo.ResponseHeader;clone(o={}){return new i({headers:o.headers||this.headers,status:o.status!==void 0?o.status:this.status,statusText:o.statusText||this.statusText,url:o.url||this.url||void 0})}},oa=class i extends co{body;constructor(o={}){super(o),this.body=o.body!==void 0?o.body:null}type=lo.Response;clone(o={}){return new i({body:o.body!==void 0?o.body:this.body,headers:o.headers||this.headers,status:o.status!==void 0?o.status:this.status,statusText:o.statusText||this.statusText,url:o.url||this.url||void 0,redirected:o.redirected??this.redirected,responseType:o.responseType??this.responseType})}},In=class extends co{name="HttpErrorResponse";message;error;ok=!1;constructor(o){super(o,0,"Unknown Error"),this.status>=200&&this.status<300?this.message=`Http failure during parsing for ${o.url||"(unknown url)"}`:this.message=`Http failure response for ${o.url||"(unknown url)"}: ${o.status} ${o.statusText}`,this.error=o.error||null}},Vf=200;var Bf=/^\)\]\}',?\n/,$w=1024*1024,dm=new x("",{factory:()=>null}),kr=(()=>{class i{fetchImpl=d(yl,{optional:!0})?.fetch??((...e)=>globalThis.fetch(...e));ngZone=d(H);destroyRef=d(Bt);maxResponseSize=d(dm);handle(e){return new yt(t=>{let n=new AbortController;this.doRequest(e,n.signal,t).then(Cl,r=>t.error(new In({error:r})));let a;return e.timeout&&(a=this.ngZone.runOutsideAngular(()=>setTimeout(()=>{n.signal.aborted||n.abort(new DOMException("signal timed out","TimeoutError"))},e.timeout))),()=>{a!==void 0&&clearTimeout(a),n.abort()}})}doRequest(e,t,n){return ye(this,null,function*(){let a=this.createRequestInit(e),r;try{let se=this.ngZone.runOutsideAngular(()=>this.fetchImpl(e.urlWithParams,V({signal:t},a)));zf(se),n.next({type:lo.Sent}),r=yield se}catch(se){n.error(new In({error:se,status:se.status??0,statusText:se.statusText,url:e.urlWithParams,headers:se.headers}));return}let u=new Li(r.headers),h=r.statusText,g=r.url||e.urlWithParams,_=r.status,w=null,B=e.reportProgress||e.reportDownloadProgress;if(B&&n.next(new Dr({headers:u,status:_,statusText:h,url:g})),r.body){let se=r.headers.get("content-length"),Ae=se!==null?Number(se):NaN;this.maxResponseSize!==null&&Number.isFinite(Ae)&&Ae>this.maxResponseSize&&sm(this.maxResponseSize);let lt=[],li=r.body.getReader(),Ci=0,Ki,ci,Ga=typeof Zone<"u"&&Zone.current,Zn=!1;if(yield this.ngZone.runOutsideAngular(()=>ye(this,null,function*(){for(;;){if(this.destroyRef.destroyed){yield li.cancel(),Zn=!0;break}let{done:Bo,value:Ns}=yield li.read();if(Bo)break;if(lt.push(Ns),Ci+=Ns.length,this.maxResponseSize!==null&&Ci>this.maxResponseSize&&(yield li.cancel(),sm(this.maxResponseSize)),B){ci=e.responseType==="text"?(ci??"")+(Ki??=new TextDecoder).decode(Ns,{stream:!0}):void 0;let Uc=()=>n.next({type:lo.DownloadProgress,total:Number.isFinite(Ae)?Ae:void 0,loaded:Ci,partialText:ci});Ga?Ga.run(Uc):Uc()}}})),Zn){n.complete();return}let Sn=this.concatChunks(lt,Ci);try{let Bo=r.headers.get(vl)??"";w=this.parseBody(e,Sn,Bo,_)}catch(Bo){n.error(new In({error:Bo,headers:new Li(r.headers),status:r.status,statusText:r.statusText,url:r.url||e.urlWithParams}));return}}_===0&&(_=w?Vf:0);let G=_>=200&&_<300,ie=r.redirected,fe=r.type;G?(n.next(new oa({body:w,headers:u,status:_,statusText:h,url:g,redirected:ie,responseType:fe})),n.complete()):n.error(new In({error:w,headers:u,status:_,statusText:h,url:g,redirected:ie,responseType:fe}))})}parseBody(e,t,n,a){switch(e.responseType){case"json":let r=new TextDecoder().decode(t).replace(Bf,"");if(r==="")return null;try{return JSON.parse(r)}catch(u){if(a<200||a>=300)return r;throw u}case"text":return new TextDecoder().decode(t);case"blob":return new Blob([t],{type:n});case"arraybuffer":return t.buffer}}createRequestInit(e){if(e.reportUploadProgress)throw new ae(2824,!1);let t={},n;if(n=e.credentials,e.withCredentials&&(n="include"),e.headers.forEach((a,r)=>t[a]=r.join(",")),e.headers.has(rm)||(t[rm]=Lf),!e.headers.has(vl)){let a=e.detectContentTypeHeader();a!==null&&(t[vl]=a)}return{body:e.serializeBody(),method:e.method,headers:t,credentials:n,keepalive:e.keepalive,cache:e.cache,priority:e.priority,mode:e.mode,redirect:e.redirect,referrer:e.referrer,integrity:e.integrity,referrerPolicy:e.referrerPolicy}}concatChunks(e,t){let n=new Uint8Array(t),a=0;for(let r of e)n.set(r,a),a+=r.length;return n}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),yl=class{};function Cl(){}function zf(i){i.then(Cl,Cl)}function sm(i){throw new ae(-2825,!1)}function jf(i,o){return o(i)}function Hf(i,o,e){return(t,n)=>Qc(e,()=>o(t,a=>i(a,n)))}var xl=new x("",{factory:()=>[]}),mm=new x(""),um=new x("",{factory:()=>!0});var wl=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:function(t){let n=null;return t?n=new(t||i):n=ne(kr),n},providedIn:"root"})}return i})();var Sr=(()=>{class i{backend;injector;chain=null;pendingTasks=d(Us);contributeToStability=d(um);constructor(e,t){this.backend=e,this.injector=t}handle(e){if(this.chain===null){let t=Array.from(new Set([...this.injector.get(xl),...this.injector.get(mm,[])]));this.chain=t.reduceRight((n,a)=>Hf(n,a,this.injector),jf)}if(this.contributeToStability){let t=this.pendingTasks.add();return this.chain(e,n=>this.backend.handle(n)).pipe(Xa(t))}else return this.chain(e,t=>this.backend.handle(t))}static \u0275fac=function(t){return new(t||i)(ne(wl),ne(mi))};static \u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})(),Dl=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:function(t){let n=null;return t?n=new(t||i):n=ne(Sr),n},providedIn:"root"})}return i})();function bl(i,o){return V({body:o},i)}var Qt=(()=>{class i{handler;constructor(e){this.handler=e}request(e,t,n={}){let a;if(e instanceof so)a=e;else{let h;n.headers instanceof Li?h=n.headers:h=new Li(n.headers);let g;n.params&&(n.params instanceof Ni?g=n.params:g=new Ni({fromObject:n.params})),a=new so(e,t,n.body!==void 0?n.body:null,{headers:h,context:n.context,params:g,reportProgress:n.reportProgress,reportUploadProgress:n.reportUploadProgress,reportDownloadProgress:n.reportDownloadProgress,responseType:n.responseType||"json",withCredentials:n.withCredentials,transferCache:n.transferCache,keepalive:n.keepalive,priority:n.priority,cache:n.cache,mode:n.mode,redirect:n.redirect,credentials:n.credentials,referrer:n.referrer,referrerPolicy:n.referrerPolicy,integrity:n.integrity,timeout:n.timeout})}let r=ge(a).pipe(qc(h=>this.handler.handle(h)));if(e instanceof so||n.observe==="events")return r;let u=r.pipe(Ce(h=>h instanceof oa));switch(n.observe||"body"){case"body":switch(a.responseType){case"arraybuffer":return u.pipe(Pe(h=>{if(h.body!==null&&!(h.body instanceof ArrayBuffer))throw new ae(2806,!1);return h.body}));case"blob":return u.pipe(Pe(h=>{if(h.body!==null&&!(h.body instanceof Blob))throw new ae(2807,!1);return h.body}));case"text":return u.pipe(Pe(h=>{if(h.body!==null&&typeof h.body!="string")throw new ae(2808,!1);return h.body}));default:return u.pipe(Pe(h=>h.body))}case"response":return u;default:throw new ae(2809,!1)}}delete(e,t={}){return this.request("DELETE",e,t)}get(e,t={}){return this.request("GET",e,t)}head(e,t={}){return this.request("HEAD",e,t)}jsonp(e,t){return this.request("JSONP",e,{params:new Ni().append(t,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(e,t={}){return this.request("OPTIONS",e,t)}patch(e,t,n={}){return this.request("PATCH",e,bl(n,t))}post(e,t,n={}){return this.request("POST",e,bl(n,t))}put(e,t,n={}){return this.request("PUT",e,bl(n,t))}static \u0275fac=function(t){return new(t||i)(ne(Dl))};static \u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var Uf=new x("",{factory:()=>!0}),Gf="XSRF-TOKEN",$f=new x("",{factory:()=>Gf}),Wf="X-XSRF-TOKEN",qf=new x("",{factory:()=>Wf}),Kf=(()=>{class i{cookieName=d($f);doc=d(W);lastCookieString="";lastToken=null;parseCount=0;getToken(){let e=this.doc.cookie||"";return e!==this.lastCookieString&&(this.parseCount++,this.lastToken=Jo(e,this.cookieName),this.lastCookieString=e),this.lastToken}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),hm=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:function(t){let n=null;return t?n=new(t||i):n=ne(Kf),n},providedIn:"root"})}return i})();function Yf(i,o){if(!d(Uf)||i.method==="GET"||i.method==="HEAD")return o(i);try{let n=d(ro).href,{origin:a}=new URL(n),{origin:r}=new URL(i.url,a);if(a!==r)return o(i)}catch(n){return o(i)}let e=d(hm).getToken(),t=d(qf);return e!=null&&!i.headers.has(t)&&(i=i.clone({headers:i.headers.set(t,e)})),o(i)}var kl=(function(i){return i[i.Interceptors=0]="Interceptors",i[i.LegacyInterceptors=1]="LegacyInterceptors",i[i.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",i[i.NoXsrfProtection=3]="NoXsrfProtection",i[i.JsonpSupport=4]="JsonpSupport",i[i.RequestsMadeViaParent=5]="RequestsMadeViaParent",i[i.Fetch=6]="Fetch",i[i.Xhr=7]="Xhr",i})(kl||{});function Xf(i,o){return{\u0275kind:i,\u0275providers:o}}function Sl(...i){let o=[Qt,kr,Sr,{provide:Dl,useExisting:Sr},{provide:wl,useFactory:()=>d(kr)},{provide:xl,useValue:Yf,multi:!0}];for(let e of i)o.push(...e.\u0275providers);return jo(o)}function Ml(i){return Xf(kl.Interceptors,i.map(o=>({provide:xl,useValue:o,multi:!0})))}var aa=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275prov=re({token:i,factory:function(t){let n=null;return t?n=new(t||i):n=ne(Jf),n},providedIn:"root"})}return i})(),Jf=(()=>{class i extends aa{_doc=d(W);sanitize(e,t){if(t==null)return null;switch(e){case Ct.NONE:return t;case Ct.HTML:return no(t,"HTML")?io(t):ld(this._doc,String(t)).toString();case Ct.STYLE:return no(t,"Style")?io(t):t;case Ct.SCRIPT:if(no(t,"Script"))return io(t);throw new ae(5200,!1);case Ct.URL:return no(t,"URL")?io(t):sd(String(t));case Ct.RESOURCE_URL:if(no(t,"ResourceURL"))return io(t);throw new ae(5201,!1);default:throw new ae(5202,!1)}}bypassSecurityTrustHtml(e){return id(e)}bypassSecurityTrustStyle(e){return nd(e)}bypassSecurityTrustScript(e){return od(e)}bypassSecurityTrustUrl(e){return ad(e)}bypassSecurityTrustResourceUrl(e){return rd(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var tg=(()=>{class i extends rr{constructor(e,t,n){super(e,t,n)}ngOnDestroy(){this.flush()}static \u0275fac=function(t){return new(t||i)(ne(W),ne(qo),ne(ar))};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})();function ig(){return new bd}function ng(){return new Cd(d(Tn),d(rr),d(H))}var pm=[{provide:ar,useFactory:ig},{provide:rr,useClass:tg},{provide:ot,useFactory:ng}],$D=[{provide:qo,useClass:vd},{provide:Pi,useValue:"NoopAnimations"},...pm],og=[{provide:qo,useFactory:()=>new yd},{provide:Pi,useFactory:()=>"BrowserAnimations"},...pm];function fm(){return Ja("NgEagerAnimations"),[...og]}var ag="@",rg=(()=>{class i{doc;delegate;zone;animationType;moduleImpl;_rendererFactoryPromise=null;scheduler=null;injector=d(X);loadingSchedulerFn=d(sg,{optional:!0});_engine;constructor(e,t,n,a,r){this.doc=e,this.delegate=t,this.zone=n,this.animationType=a,this.moduleImpl=r}ngOnDestroy(){this._engine?.flush()}loadImpl(){let e=()=>this.moduleImpl??import("./chunk-34LU6STA.js").then(n=>n),t;return this.loadingSchedulerFn?t=this.loadingSchedulerFn(e):t=e(),t.catch(n=>{throw new ae(5300,!1)}).then(({\u0275createEngine:n,\u0275AnimationRendererFactory:a})=>{this._engine=n(this.animationType,this.doc);let r=new a(this.delegate,this._engine,this.zone);return this.delegate=r,r})}createRenderer(e,t){let n=this.delegate.createRenderer(e,t);if(n.\u0275type===0)return n;typeof n.throwOnSyntheticProps=="boolean"&&(n.throwOnSyntheticProps=!1);let a=new El(n);return t?.data?.animation&&!this._rendererFactoryPromise&&(this._rendererFactoryPromise=this.loadImpl()),this._rendererFactoryPromise?.then(r=>{let u=r.createRenderer(e,t);a.use(u),this.scheduler??=this.injector.get(ed,null,{optional:!0}),this.scheduler?.notify(10)}).catch(r=>{a.use(n)}),a}begin(){this.delegate.begin?.()}end(){this.delegate.end?.()}whenRenderingDone(){return this.delegate.whenRenderingDone?.()??Promise.resolve()}componentReplaced(e){this._engine?.flush(),this.delegate.componentReplaced?.(e)}static \u0275fac=function(t){er()};static \u0275prov=re({token:i,factory:i.\u0275fac})}return i})(),El=class{delegate;replay=[];\u0275type=1;constructor(o){this.delegate=o}use(o){if(this.delegate=o,this.replay!==null){for(let e of this.replay)e(o);this.replay=null}}get data(){return this.delegate.data}destroy(){this.replay=null,this.delegate.destroy()}createElement(o,e){return this.delegate.createElement(o,e)}createComment(o){return this.delegate.createComment(o)}createText(o){return this.delegate.createText(o)}get destroyNode(){return this.delegate.destroyNode}appendChild(o,e){this.delegate.appendChild(o,e)}insertBefore(o,e,t,n){this.delegate.insertBefore(o,e,t,n)}removeChild(o,e,t,n){this.delegate.removeChild(o,e,t,n)}selectRootElement(o,e){return this.delegate.selectRootElement(o,e)}parentNode(o){return this.delegate.parentNode(o)}nextSibling(o){return this.delegate.nextSibling(o)}setAttribute(o,e,t,n){this.delegate.setAttribute(o,e,t,n)}removeAttribute(o,e,t){this.delegate.removeAttribute(o,e,t)}addClass(o,e){this.delegate.addClass(o,e)}removeClass(o,e){this.delegate.removeClass(o,e)}setStyle(o,e,t,n){this.delegate.setStyle(o,e,t,n)}removeStyle(o,e,t){this.delegate.removeStyle(o,e,t)}setProperty(o,e,t){this.shouldReplay(e)&&this.replay.push(n=>n.setProperty(o,e,t)),this.delegate.setProperty(o,e,t)}setValue(o,e){this.delegate.setValue(o,e)}listen(o,e,t,n){return this.shouldReplay(e)&&this.replay.push(a=>a.listen(o,e,t,n)),this.delegate.listen(o,e,t,n)}shouldReplay(o){return this.replay!==null&&o.startsWith(ag)}},sg=new x("");function gm(i="animations"){return Ja("NgAsyncAnimations"),jo([{provide:ot,useFactory:()=>new rg(d(W),d(Tn),d(H),i)},{provide:Pi,useValue:i==="noop"?"NoopAnimations":"BrowserAnimations"}])}var Mr="asm_token",Er=(()=>{class i{constructor(){this.http=d(Qt),this.authState=new Qn(this.hasToken())}login(e){return ye(this,null,function*(){try{let t=yield Te(this.http.post("/api/auth/login",{password:e}));return localStorage.setItem(Mr,t.token),this.authState.next(!0),!0}catch(t){return!1}})}logout(){localStorage.removeItem(Mr),this.authState.next(!1)}getToken(){return localStorage.getItem(Mr)}isAuthenticated(){return this.hasToken()}hasToken(){return!!localStorage.getItem(Mr)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var _m=(i,o)=>{let e=d(Er),t=e.getToken(),n=i.url.includes("/api/auth/login"),a=t&&!n?i.clone({setHeaders:{Authorization:`Bearer ${t}`}}):i;return o(a).pipe(Kt(r=>(r.status===401&&!n&&e.logout(),qa(()=>r))))};var vm={providers:[fd({eventCoalescing:!0}),Sl(Ml([_m])),fm(),gm()]};var Al;try{Al=typeof Intl<"u"&&Intl.v8BreakIterator}catch(i){Al=!1}var le=(()=>{class i{_platformId=d(eo);isBrowser=this._platformId?qd(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||Al)&&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;static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function Vi(i){return Array.isArray(i)?i:[i]}var bm=new Set,Rn,mo=(()=>{class i{_platform=d(le);_nonce=d(to,{optional:!0});_matchMedia;constructor(){this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):cg}matchMedia(e){return(this._platform.WEBKIT||this._platform.BLINK)&&lg(e,this._nonce),this._matchMedia(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function lg(i,o){if(!bm.has(i))try{Rn||(Rn=document.createElement("style"),o&&Rn.setAttribute("nonce",o),Rn.setAttribute("type","text/css"),document.head.appendChild(Rn)),Rn.sheet&&(Rn.sheet.insertRule(`@media ${i.replace(/[{}]/g,"")} {body{ }}`,0),bm.add(i))}catch(e){console.error(e)}}function cg(i){return{matches:i==="all"||i==="",media:i,addListener:()=>{},removeListener:()=>{}}}var On=(()=>{class i{_mediaMatcher=d(mo);_zone=d(H);_queries=new Map;_destroySubject=new I;ngOnDestroy(){this._destroySubject.next(),this._destroySubject.complete()}isMatched(e){return ym(Vi(e)).some(n=>this._registerQuery(n).mql.matches)}observe(e){let n=ym(Vi(e)).map(r=>this._registerQuery(r).observable),a=Jn(n);return a=Wc(a.pipe(ct(1)),a.pipe(Za(1),Vt(0))),a.pipe(Pe(r=>{let u={matches:!1,breakpoints:{}};return r.forEach(({matches:h,query:g})=>{u.matches=u.matches||h,u.breakpoints[g]=h}),u}))}_registerQuery(e){if(this._queries.has(e))return this._queries.get(e);let t=this._mediaMatcher.matchMedia(e),a={observable:new yt(r=>{let u=h=>this._zone.run(()=>r.next(h));return t.addListener(u),()=>{t.removeListener(u)}}).pipe(ke(t),Pe(({matches:r})=>({query:e,matches:r})),oe(this._destroySubject)),mql:t};return this._queries.set(e,a),a}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function ym(i){return i.map(o=>o.split(",")).reduce((o,e)=>o.concat(e)).map(o=>o.trim())}var Ar={XSmall:"(max-width: 599.98px)",Small:"(min-width: 600px) and (max-width: 959.98px)",Medium:"(min-width: 960px) and (max-width: 1279.98px)",Large:"(min-width: 1280px) and (max-width: 1919.98px)",XLarge:"(min-width: 1920px)",Handset:"(max-width: 599.98px) and (orientation: portrait), (max-width: 959.98px) and (orientation: landscape)",Tablet:"(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait), (min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)",Web:"(min-width: 840px) and (orientation: portrait), (min-width: 1280px) and (orientation: landscape)",HandsetPortrait:"(max-width: 599.98px) and (orientation: portrait)",TabletPortrait:"(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait)",WebPortrait:"(min-width: 840px) and (orientation: portrait)",HandsetLandscape:"(max-width: 959.98px) and (orientation: landscape)",TabletLandscape:"(min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)",WebLandscape:"(min-width: 1280px) and (orientation: landscape)"};var dg=new x("MATERIAL_ANIMATIONS"),Cm=null;function Tl(){return d(dg,{optional:!0})?.animationsDisabled||d(Pi,{optional:!0})==="NoopAnimations"?"di-disabled":(Cm??=d(mo).matchMedia("(prefers-reduced-motion)").matches,Cm?"reduced-motion":"enabled")}function pe(){return Tl()!=="enabled"}var mg=new x("cdk-dir-doc",{providedIn:"root",factory:()=>d(W)}),ug=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;function xm(i){let o=i?.toLowerCase()||"";return o==="auto"&&typeof navigator<"u"&&navigator?.language?ug.test(navigator.language)?"rtl":"ltr":o==="rtl"?"rtl":"ltr"}var qe=(()=>{class i{get value(){return this.valueSignal()}valueSignal=R("ltr");change=new K;constructor(){let e=d(mg,{optional:!0});if(e){let t=e.body?e.body.dir:null,n=e.documentElement?e.documentElement.dir:null;this.valueSignal.set(xm(t||n||"ltr"))}}ngOnDestroy(){this.change.complete()}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var ee=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();function hg(i,o){i&1&&ht(0,"div",2)}var pg=new x("MAT_PROGRESS_BAR_DEFAULT_OPTIONS");var en=(()=>{class i{_elementRef=d(N);_ngZone=d(H);_changeDetectorRef=d(te);_renderer=d(ve);_cleanupTransitionEnd;constructor(){let e=Tl(),t=d(pg,{optional:!0});this._isNoopAnimation=e==="di-disabled",e==="reduced-motion"&&this._elementRef.nativeElement.classList.add("mat-progress-bar-reduced-motion"),t&&(t.color&&(this.color=this._defaultColor=t.color),this.mode=t.mode||this.mode)}_isNoopAnimation;get color(){return this._color||this._defaultColor}set color(e){this._color=e}_color;_defaultColor="primary";get value(){return this._value}set value(e){this._value=wm(e||0),this._changeDetectorRef.markForCheck()}_value=0;get bufferValue(){return this._bufferValue||0}set bufferValue(e){this._bufferValue=wm(e||0),this._changeDetectorRef.markForCheck()}_bufferValue=0;animationEnd=new K;get mode(){return this._mode}set mode(e){this._mode=e,this._changeDetectorRef.markForCheck()}_mode="determinate";ngAfterViewInit(){this._ngZone.runOutsideAngular(()=>{this._cleanupTransitionEnd=this._renderer.listen(this._elementRef.nativeElement,"transitionend",this._transitionendHandler)})}ngOnDestroy(){this._cleanupTransitionEnd?.()}_getPrimaryBarTransform(){return`scaleX(${this._isIndeterminate()?1:this.value/100})`}_getBufferBarFlexBasis(){return`${this.mode==="buffer"?this.bufferValue:100}%`}_isIndeterminate(){return this.mode==="indeterminate"||this.mode==="query"}_transitionendHandler=e=>{this.animationEnd.observers.length===0||!e.target||!e.target.classList.contains("mdc-linear-progress__primary-bar")||(this.mode==="determinate"||this.mode==="buffer")&&this._ngZone.run(()=>this.animationEnd.next({value:this.value}))};static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-progress-bar"]],hostAttrs:["role","progressbar","aria-valuemin","0","aria-valuemax","100","tabindex","-1",1,"mat-mdc-progress-bar","mdc-linear-progress"],hostVars:10,hostBindings:function(t,n){t&2&&(Z("aria-valuenow",n._isIndeterminate()?null:n.value)("mode",n.mode),et("mat-"+n.color),p("_mat-animation-noopable",n._isNoopAnimation)("mdc-linear-progress--animation-ready",!n._isNoopAnimation)("mdc-linear-progress--indeterminate",n._isIndeterminate()))},inputs:{color:"color",value:[2,"value","value",wt],bufferValue:[2,"bufferValue","bufferValue",wt],mode:"mode"},outputs:{animationEnd:"animationEnd"},exportAs:["matProgressBar"],decls:7,vars:5,consts:[["aria-hidden","true",1,"mdc-linear-progress__buffer"],[1,"mdc-linear-progress__buffer-bar"],[1,"mdc-linear-progress__buffer-dots"],["aria-hidden","true",1,"mdc-linear-progress__bar","mdc-linear-progress__primary-bar"],[1,"mdc-linear-progress__bar-inner"],["aria-hidden","true",1,"mdc-linear-progress__bar","mdc-linear-progress__secondary-bar"]],template:function(t,n){t&1&&(Ie(0,"div",0),ht(1,"div",1),M(2,hg,1,0,"div",2),je(),Ie(3,"div",3),ht(4,"span",4),je(),Ie(5,"div",5),ht(6,"span",4),je()),t&2&&(c(),He("flex-basis",n._getBufferBarFlexBasis()),c(),E(n.mode==="buffer"?2:-1),c(),He("transform",n._getPrimaryBarTransform()))},styles:[`.mat-mdc-progress-bar {
3
3
  --mat-progress-bar-animation-multiplier: 1;
4
4
  display: block;
5
5
  text-align: start;
@@ -253,7 +253,7 @@ import{$ as xe,$a as Qa,$b as Ys,A as Kt,Aa as eo,Ab as Ue,Ac as vd,B as qc,Ba a
253
253
  transform: translateX(-10px);
254
254
  }
255
255
  }
256
- `],encapsulation:2})}return i})();function wm(i,o=0,e=100){return Math.max(o,Math.min(e,i))}var Si=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();var fg=["*"];var gg=new C("MAT_CARD_CONFIG"),tn=(()=>{class i{appearance;constructor(){let e=d(gg,{optional:!0});this.appearance=e?.appearance||"raised"}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-card"]],hostAttrs:[1,"mat-mdc-card","mdc-card"],hostVars:8,hostBindings:function(t,n){t&2&&p("mat-mdc-card-outlined",n.appearance==="outlined")("mdc-card--outlined",n.appearance==="outlined")("mat-mdc-card-filled",n.appearance==="filled")("mdc-card--filled",n.appearance==="filled")},inputs:{appearance:"appearance"},exportAs:["matCard"],ngContentSelectors:fg,decls:1,vars:0,template:function(t,n){t&1&&(ce(),U(0))},styles:[`.mat-mdc-card {
256
+ `],encapsulation:2})}return i})();function wm(i,o=0,e=100){return Math.max(o,Math.min(e,i))}var Si=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();var fg=["*"];var gg=new x("MAT_CARD_CONFIG"),tn=(()=>{class i{appearance;constructor(){let e=d(gg,{optional:!0});this.appearance=e?.appearance||"raised"}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-card"]],hostAttrs:[1,"mat-mdc-card","mdc-card"],hostVars:8,hostBindings:function(t,n){t&2&&p("mat-mdc-card-outlined",n.appearance==="outlined")("mdc-card--outlined",n.appearance==="outlined")("mat-mdc-card-filled",n.appearance==="filled")("mdc-card--filled",n.appearance==="filled")},inputs:{appearance:"appearance"},exportAs:["matCard"],ngContentSelectors:fg,decls:1,vars:0,template:function(t,n){t&1&&(ce(),U(0))},styles:[`.mat-mdc-card {
257
257
  display: flex;
258
258
  flex-direction: column;
259
259
  box-sizing: border-box;
@@ -423,7 +423,7 @@ import{$ as xe,$a as Qa,$b as Ys,A as Kt,Aa as eo,Ab as Ue,Ac as vd,B as qc,Ba a
423
423
  .mat-mdc-card-actions-align-end {
424
424
  justify-content: flex-end;
425
425
  }
426
- `],encapsulation:2})}return i})();var nn=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-card-content"]],hostAttrs:[1,"mat-mdc-card-content"]})}return i})();var on=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();function Ht(i,o=0){return Dm(i)?Number(i):arguments.length===2?o:0}function Dm(i){return!isNaN(parseFloat(i))&&!isNaN(Number(i))}function Dt(i){return i instanceof N?i.nativeElement:i}function Ze(i){return i==null?"":typeof i=="string"?i:`${i}px`}function mt(i){return i!=null&&`${i}`!="false"}var fi=(function(i){return i[i.NORMAL=0]="NORMAL",i[i.NEGATED=1]="NEGATED",i[i.INVERTED=2]="INVERTED",i})(fi||{}),Ar,Rn;function Tr(){if(Rn==null){if(typeof document!="object"||!document||typeof Element!="function"||!Element)return Rn=!1,Rn;if(document.documentElement?.style&&"scrollBehavior"in document.documentElement.style)Rn=!0;else{let i=Element.prototype.scrollTo;i?Rn=!/\{\s*\[native code\]\s*\}/.test(i.toString()):Rn=!1}}return Rn}function co(){if(typeof document!="object"||!document)return fi.NORMAL;if(Ar==null){let i=document.createElement("div"),o=i.style;i.dir="rtl",o.width="1px",o.overflow="auto",o.visibility="hidden",o.pointerEvents="none",o.position="absolute";let e=document.createElement("div"),t=e.style;t.width="2px",t.height="1px",i.appendChild(e),document.body.appendChild(i),Ar=fi.NORMAL,i.scrollLeft===0&&(i.scrollLeft=1,Ar=i.scrollLeft===0?fi.NEGATED:fi.INVERTED),i.remove()}return Ar}var Tl;function km(){if(Tl==null){let i=typeof document<"u"?document.head:null;Tl=!!(i&&(i.createShadowRoot||i.attachShadow))}return Tl}function Il(i){if(km()){let o=i.getRootNode?i.getRootNode():null;if(typeof ShadowRoot<"u"&&ShadowRoot&&o instanceof ShadowRoot)return o}return null}function an(){let i=typeof document<"u"&&document?document.activeElement:null;for(;i&&i.shadowRoot;){let o=i.shadowRoot.activeElement;if(o===i)break;i=o}return i}function rt(i){if(i.composedPath)try{return i.composedPath()[0]}catch(o){}return i.target}function Rl(){return typeof __karma__<"u"&&!!__karma__||typeof jasmine<"u"&&!!jasmine||typeof jest<"u"&&!!jest||typeof Mocha<"u"&&!!Mocha}var oa;function Sm(){if(oa==null&&typeof window<"u")try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>oa=!0}))}finally{oa=oa||!1}return oa}function mo(i){return Sm()?i:!!i.capture}var uo,Mm=["color","button","checkbox","date","datetime-local","email","file","hidden","image","month","number","password","radio","range","reset","search","submit","tel","text","time","url","week"];function Ol(){if(uo)return uo;if(typeof document!="object"||!document)return uo=new Set(Mm),uo;let i=document.createElement("input");return uo=new Set(Mm.filter(o=>(i.setAttribute("type",o),i.type===o))),uo}var Ir=new WeakMap,Fe=(()=>{class i{_appRef;_injector=d(X);_environmentInjector=d(mi);load(e){let t=this._appRef=this._appRef||this._injector.get(Qi),n=Ir.get(t);n||(n={loaders:new Set,refs:[]},Ir.set(t,n),t.onDestroy(()=>{Ir.get(t)?.refs.forEach(a=>a.destroy()),Ir.delete(t)})),n.loaders.has(e)||(n.loaders.add(e),n.refs.push(tr(e,{environmentInjector:this._environmentInjector})))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var _g=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["ng-component"]],hostAttrs:["cdk-text-field-style-loader",""],decls:0,vars:0,template:function(t,n){},styles:[`textarea.cdk-textarea-autosize {
426
+ `],encapsulation:2})}return i})();var nn=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-card-content"]],hostAttrs:[1,"mat-mdc-card-content"]})}return i})();var on=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();function Ht(i,o=0){return Dm(i)?Number(i):arguments.length===2?o:0}function Dm(i){return!isNaN(parseFloat(i))&&!isNaN(Number(i))}function Dt(i){return i instanceof N?i.nativeElement:i}function Ze(i){return i==null?"":typeof i=="string"?i:`${i}px`}function mt(i){return i!=null&&`${i}`!="false"}var fi=(function(i){return i[i.NORMAL=0]="NORMAL",i[i.NEGATED=1]="NEGATED",i[i.INVERTED=2]="INVERTED",i})(fi||{}),Rr,Pn;function Or(){if(Pn==null){if(typeof document!="object"||!document||typeof Element!="function"||!Element)return Pn=!1,Pn;if(document.documentElement?.style&&"scrollBehavior"in document.documentElement.style)Pn=!0;else{let i=Element.prototype.scrollTo;i?Pn=!/\{\s*\[native code\]\s*\}/.test(i.toString()):Pn=!1}}return Pn}function uo(){if(typeof document!="object"||!document)return fi.NORMAL;if(Rr==null){let i=document.createElement("div"),o=i.style;i.dir="rtl",o.width="1px",o.overflow="auto",o.visibility="hidden",o.pointerEvents="none",o.position="absolute";let e=document.createElement("div"),t=e.style;t.width="2px",t.height="1px",i.appendChild(e),document.body.appendChild(i),Rr=fi.NORMAL,i.scrollLeft===0&&(i.scrollLeft=1,Rr=i.scrollLeft===0?fi.NEGATED:fi.INVERTED),i.remove()}return Rr}var Il;function km(){if(Il==null){let i=typeof document<"u"?document.head:null;Il=!!(i&&(i.createShadowRoot||i.attachShadow))}return Il}function Rl(i){if(km()){let o=i.getRootNode?i.getRootNode():null;if(typeof ShadowRoot<"u"&&ShadowRoot&&o instanceof ShadowRoot)return o}return null}function an(){let i=typeof document<"u"&&document?document.activeElement:null;for(;i&&i.shadowRoot;){let o=i.shadowRoot.activeElement;if(o===i)break;i=o}return i}function rt(i){if(i.composedPath)try{return i.composedPath()[0]}catch(o){}return i.target}function Ol(){return typeof __karma__<"u"&&!!__karma__||typeof jasmine<"u"&&!!jasmine||typeof jest<"u"&&!!jest||typeof Mocha<"u"&&!!Mocha}var ra;function Sm(){if(ra==null&&typeof window<"u")try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>ra=!0}))}finally{ra=ra||!1}return ra}function ho(i){return Sm()?i:!!i.capture}var po,Mm=["color","button","checkbox","date","datetime-local","email","file","hidden","image","month","number","password","radio","range","reset","search","submit","tel","text","time","url","week"];function Pl(){if(po)return po;if(typeof document!="object"||!document)return po=new Set(Mm),po;let i=document.createElement("input");return po=new Set(Mm.filter(o=>(i.setAttribute("type",o),i.type===o))),po}var Pr=new WeakMap,Ne=(()=>{class i{_appRef;_injector=d(X);_environmentInjector=d(mi);load(e){let t=this._appRef=this._appRef||this._injector.get(Qi),n=Pr.get(t);n||(n={loaders:new Set,refs:[]},Pr.set(t,n),t.onDestroy(()=>{Pr.get(t)?.refs.forEach(a=>a.destroy()),Pr.delete(t)})),n.loaders.has(e)||(n.loaders.add(e),n.refs.push(or(e,{environmentInjector:this._environmentInjector})))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var _g=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["ng-component"]],hostAttrs:["cdk-text-field-style-loader",""],decls:0,vars:0,template:function(t,n){},styles:[`textarea.cdk-textarea-autosize {
427
427
  resize: none;
428
428
  }
429
429
 
@@ -449,7 +449,7 @@ textarea.cdk-textarea-autosize-measuring-firefox {
449
449
  .cdk-text-field-autofill-monitored:not(:-webkit-autofill) {
450
450
  animation: cdk-text-field-autofill-end 0s 1ms;
451
451
  }
452
- `],encapsulation:2})}return i})(),vg={passive:!0},Em=(()=>{class i{_platform=d(le);_ngZone=d(H);_renderer=d(ot).createRenderer(null,null);_styleLoader=d(Fe);_monitoredElements=new Map;monitor(e){if(!this._platform.isBrowser)return Ua;this._styleLoader.load(_g);let t=Dt(e),n=this._monitoredElements.get(t);if(n)return n.subject;let a=new I,r="cdk-text-field-autofilled",u=g=>{g.animationName==="cdk-text-field-autofill-start"&&!t.classList.contains(r)?(t.classList.add(r),this._ngZone.run(()=>a.next({target:g.target,isAutofilled:!0}))):g.animationName==="cdk-text-field-autofill-end"&&t.classList.contains(r)&&(t.classList.remove(r),this._ngZone.run(()=>a.next({target:g.target,isAutofilled:!1})))},h=this._ngZone.runOutsideAngular(()=>(t.classList.add("cdk-text-field-autofill-monitored"),this._renderer.listen(t,"animationstart",u,vg)));return this._monitoredElements.set(t,{subject:a,unlisten:h}),a}stopMonitoring(e){let t=Dt(e),n=this._monitoredElements.get(t);n&&(n.unlisten(),n.subject.complete(),t.classList.remove("cdk-text-field-autofill-monitored"),t.classList.remove("cdk-text-field-autofilled"),this._monitoredElements.delete(t))}ngOnDestroy(){this._monitoredElements.forEach((e,t)=>this.stopMonitoring(t))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Am=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();function On(i){return i.buttons===0||i.detail===0}function Pn(i){let o=i.touches&&i.touches[0]||i.changedTouches&&i.changedTouches[0];return!!o&&o.identifier===-1&&(o.radiusX==null||o.radiusX===1)&&(o.radiusY==null||o.radiusY===1)}var Tm=new C("cdk-input-modality-detector-options"),Im={ignoreKeys:[18,17,224,91,16]},Rm=650,Pl={passive:!0,capture:!0},Om=(()=>{class i{_platform=d(le);_listenerCleanups;modalityDetected;modalityChanged;get mostRecentModality(){return this._modality.value}_mostRecentTarget=null;_modality=new Xn(null);_options;_lastTouchMs=0;_onKeydown=e=>{this._options?.ignoreKeys?.some(t=>t===e.keyCode)||(this._modality.next("keyboard"),this._mostRecentTarget=rt(e))};_onMousedown=e=>{Date.now()-this._lastTouchMs<Rm||(this._modality.next(On(e)?"keyboard":"mouse"),this._mostRecentTarget=rt(e))};_onTouchstart=e=>{if(Pn(e)){this._modality.next("keyboard");return}this._lastTouchMs=Date.now(),this._modality.next("touch"),this._mostRecentTarget=rt(e)};constructor(){let e=d(H),t=d($),n=d(Tm,{optional:!0});if(this._options=V(V({},Im),n),this.modalityDetected=this._modality.pipe(Ka(1)),this.modalityChanged=this.modalityDetected.pipe(xi()),this._platform.isBrowser){let a=d(ot).createRenderer(null,null);this._listenerCleanups=e.runOutsideAngular(()=>[a.listen(t,"keydown",this._onKeydown,Pl),a.listen(t,"mousedown",this._onMousedown,Pl),a.listen(t,"touchstart",this._onTouchstart,Pl)])}}ngOnDestroy(){this._modality.complete(),this._listenerCleanups?.forEach(e=>e())}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),aa=(function(i){return i[i.IMMEDIATE=0]="IMMEDIATE",i[i.EVENTUAL=1]="EVENTUAL",i})(aa||{}),Pm=new C("cdk-focus-monitor-default-options"),Rr=mo({passive:!0,capture:!0}),Rt=(()=>{class i{_ngZone=d(H);_platform=d(le);_inputModalityDetector=d(Om);_origin=null;_lastFocusOrigin=null;_windowFocused=!1;_windowFocusTimeoutId;_originTimeoutId;_originFromTouchInteraction=!1;_elementInfo=new Map;_monitoredElementCount=0;_rootNodeFocusListenerCount=new Map;_detectionMode;_windowFocusListener=()=>{this._windowFocused=!0,this._windowFocusTimeoutId=setTimeout(()=>this._windowFocused=!1)};_document=d($);_stopInputModalityDetector=new I;constructor(){let e=d(Pm,{optional:!0});this._detectionMode=e?.detectionMode||aa.IMMEDIATE}_rootNodeFocusAndBlurListener=e=>{let t=rt(e);for(let n=t;n;n=n.parentElement)e.type==="focus"?this._onFocus(e,n):this._onBlur(e,n)};monitor(e,t=!1){let n=Dt(e);if(!this._platform.isBrowser||n.nodeType!==1)return ge();let a=Il(n)||this._document,r=this._elementInfo.get(n);if(r)return t&&(r.checkChildren=!0),r.subject;let u={checkChildren:t,subject:new I,rootNode:a};return this._elementInfo.set(n,u),this._registerGlobalListeners(u),u.subject}stopMonitoring(e){let t=Dt(e),n=this._elementInfo.get(t);n&&(n.subject.complete(),this._setClasses(t),this._elementInfo.delete(t),this._removeGlobalListeners(n))}focusVia(e,t,n){let a=Dt(e),r=this._document.activeElement;a===r?this._getClosestElementsInfo(a).forEach(([u,h])=>this._originChanged(u,t,h)):(this._setOrigin(t),typeof a.focus=="function"&&a.focus(n))}ngOnDestroy(){this._elementInfo.forEach((e,t)=>this.stopMonitoring(t))}_getWindow(){return this._document.defaultView||window}_getFocusOrigin(e){return this._origin?this._originFromTouchInteraction?this._shouldBeAttributedToTouch(e)?"touch":"program":this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:e&&this._isLastInteractionFromInputLabel(e)?"mouse":"program"}_shouldBeAttributedToTouch(e){return this._detectionMode===aa.EVENTUAL||!!e?.contains(this._inputModalityDetector._mostRecentTarget)}_setClasses(e,t){e.classList.toggle("cdk-focused",!!t),e.classList.toggle("cdk-touch-focused",t==="touch"),e.classList.toggle("cdk-keyboard-focused",t==="keyboard"),e.classList.toggle("cdk-mouse-focused",t==="mouse"),e.classList.toggle("cdk-program-focused",t==="program")}_setOrigin(e,t=!1){this._ngZone.runOutsideAngular(()=>{if(this._origin=e,this._originFromTouchInteraction=e==="touch"&&t,this._detectionMode===aa.IMMEDIATE){clearTimeout(this._originTimeoutId);let n=this._originFromTouchInteraction?Rm:1;this._originTimeoutId=setTimeout(()=>this._origin=null,n)}})}_onFocus(e,t){let n=this._elementInfo.get(t),a=rt(e);!n||!n.checkChildren&&t!==a||this._originChanged(t,this._getFocusOrigin(a),n)}_onBlur(e,t){let n=this._elementInfo.get(t);!n||n.checkChildren&&e.relatedTarget instanceof Node&&t.contains(e.relatedTarget)||(this._setClasses(t),this._emitOrigin(n,null))}_emitOrigin(e,t){e.subject.observers.length&&this._ngZone.run(()=>e.subject.next(t))}_registerGlobalListeners(e){if(!this._platform.isBrowser)return;let t=e.rootNode,n=this._rootNodeFocusListenerCount.get(t)||0;n||this._ngZone.runOutsideAngular(()=>{t.addEventListener("focus",this._rootNodeFocusAndBlurListener,Rr),t.addEventListener("blur",this._rootNodeFocusAndBlurListener,Rr)}),this._rootNodeFocusListenerCount.set(t,n+1),++this._monitoredElementCount===1&&(this._ngZone.runOutsideAngular(()=>{this._getWindow().addEventListener("focus",this._windowFocusListener)}),this._inputModalityDetector.modalityDetected.pipe(oe(this._stopInputModalityDetector)).subscribe(a=>{this._setOrigin(a,!0)}))}_removeGlobalListeners(e){let t=e.rootNode;if(this._rootNodeFocusListenerCount.has(t)){let n=this._rootNodeFocusListenerCount.get(t);n>1?this._rootNodeFocusListenerCount.set(t,n-1):(t.removeEventListener("focus",this._rootNodeFocusAndBlurListener,Rr),t.removeEventListener("blur",this._rootNodeFocusAndBlurListener,Rr),this._rootNodeFocusListenerCount.delete(t))}--this._monitoredElementCount||(this._getWindow().removeEventListener("focus",this._windowFocusListener),this._stopInputModalityDetector.next(),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._originTimeoutId))}_originChanged(e,t,n){this._setClasses(e,t),this._emitOrigin(n,t),this._lastFocusOrigin=t}_getClosestElementsInfo(e){let t=[];return this._elementInfo.forEach((n,a)=>{(a===e||n.checkChildren&&a.contains(e))&&t.push([a,n])}),t}_isLastInteractionFromInputLabel(e){let{_mostRecentTarget:t,mostRecentModality:n}=this._inputModalityDetector;if(n!=="mouse"||!t||t===e||e.nodeName!=="INPUT"&&e.nodeName!=="TEXTAREA"||e.disabled)return!1;let a=e.labels;if(a){for(let r=0;r<a.length;r++)if(a[r].contains(t))return!0}return!1}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var rn=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["ng-component"]],exportAs:["cdkVisuallyHidden"],decls:0,vars:0,template:function(t,n){},styles:[`.cdk-visually-hidden {
452
+ `],encapsulation:2})}return i})(),vg={passive:!0},Em=(()=>{class i{_platform=d(le);_ngZone=d(H);_renderer=d(ot).createRenderer(null,null);_styleLoader=d(Ne);_monitoredElements=new Map;monitor(e){if(!this._platform.isBrowser)return Wa;this._styleLoader.load(_g);let t=Dt(e),n=this._monitoredElements.get(t);if(n)return n.subject;let a=new I,r="cdk-text-field-autofilled",u=g=>{g.animationName==="cdk-text-field-autofill-start"&&!t.classList.contains(r)?(t.classList.add(r),this._ngZone.run(()=>a.next({target:g.target,isAutofilled:!0}))):g.animationName==="cdk-text-field-autofill-end"&&t.classList.contains(r)&&(t.classList.remove(r),this._ngZone.run(()=>a.next({target:g.target,isAutofilled:!1})))},h=this._ngZone.runOutsideAngular(()=>(t.classList.add("cdk-text-field-autofill-monitored"),this._renderer.listen(t,"animationstart",u,vg)));return this._monitoredElements.set(t,{subject:a,unlisten:h}),a}stopMonitoring(e){let t=Dt(e),n=this._monitoredElements.get(t);n&&(n.unlisten(),n.subject.complete(),t.classList.remove("cdk-text-field-autofill-monitored"),t.classList.remove("cdk-text-field-autofilled"),this._monitoredElements.delete(t))}ngOnDestroy(){this._monitoredElements.forEach((e,t)=>this.stopMonitoring(t))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Am=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();function Fn(i){return i.buttons===0||i.detail===0}function Nn(i){let o=i.touches&&i.touches[0]||i.changedTouches&&i.changedTouches[0];return!!o&&o.identifier===-1&&(o.radiusX==null||o.radiusX===1)&&(o.radiusY==null||o.radiusY===1)}var Tm=new x("cdk-input-modality-detector-options"),Im={ignoreKeys:[18,17,224,91,16]},Rm=650,Fl={passive:!0,capture:!0},Om=(()=>{class i{_platform=d(le);_listenerCleanups;modalityDetected;modalityChanged;get mostRecentModality(){return this._modality.value}_mostRecentTarget=null;_modality=new Qn(null);_options;_lastTouchMs=0;_onKeydown=e=>{this._options?.ignoreKeys?.some(t=>t===e.keyCode)||(this._modality.next("keyboard"),this._mostRecentTarget=rt(e))};_onMousedown=e=>{Date.now()-this._lastTouchMs<Rm||(this._modality.next(Fn(e)?"keyboard":"mouse"),this._mostRecentTarget=rt(e))};_onTouchstart=e=>{if(Nn(e)){this._modality.next("keyboard");return}this._lastTouchMs=Date.now(),this._modality.next("touch"),this._mostRecentTarget=rt(e)};constructor(){let e=d(H),t=d(W),n=d(Tm,{optional:!0});if(this._options=V(V({},Im),n),this.modalityDetected=this._modality.pipe(Za(1)),this.modalityChanged=this.modalityDetected.pipe(xi()),this._platform.isBrowser){let a=d(ot).createRenderer(null,null);this._listenerCleanups=e.runOutsideAngular(()=>[a.listen(t,"keydown",this._onKeydown,Fl),a.listen(t,"mousedown",this._onMousedown,Fl),a.listen(t,"touchstart",this._onTouchstart,Fl)])}}ngOnDestroy(){this._modality.complete(),this._listenerCleanups?.forEach(e=>e())}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),sa=(function(i){return i[i.IMMEDIATE=0]="IMMEDIATE",i[i.EVENTUAL=1]="EVENTUAL",i})(sa||{}),Pm=new x("cdk-focus-monitor-default-options"),Fr=ho({passive:!0,capture:!0}),Rt=(()=>{class i{_ngZone=d(H);_platform=d(le);_inputModalityDetector=d(Om);_origin=null;_lastFocusOrigin=null;_windowFocused=!1;_windowFocusTimeoutId;_originTimeoutId;_originFromTouchInteraction=!1;_elementInfo=new Map;_monitoredElementCount=0;_rootNodeFocusListenerCount=new Map;_detectionMode;_windowFocusListener=()=>{this._windowFocused=!0,this._windowFocusTimeoutId=setTimeout(()=>this._windowFocused=!1)};_document=d(W);_stopInputModalityDetector=new I;constructor(){let e=d(Pm,{optional:!0});this._detectionMode=e?.detectionMode||sa.IMMEDIATE}_rootNodeFocusAndBlurListener=e=>{let t=rt(e);for(let n=t;n;n=n.parentElement)e.type==="focus"?this._onFocus(e,n):this._onBlur(e,n)};monitor(e,t=!1){let n=Dt(e);if(!this._platform.isBrowser||n.nodeType!==1)return ge();let a=Rl(n)||this._document,r=this._elementInfo.get(n);if(r)return t&&(r.checkChildren=!0),r.subject;let u={checkChildren:t,subject:new I,rootNode:a};return this._elementInfo.set(n,u),this._registerGlobalListeners(u),u.subject}stopMonitoring(e){let t=Dt(e),n=this._elementInfo.get(t);n&&(n.subject.complete(),this._setClasses(t),this._elementInfo.delete(t),this._removeGlobalListeners(n))}focusVia(e,t,n){let a=Dt(e),r=this._document.activeElement;a===r?this._getClosestElementsInfo(a).forEach(([u,h])=>this._originChanged(u,t,h)):(this._setOrigin(t),typeof a.focus=="function"&&a.focus(n))}ngOnDestroy(){this._elementInfo.forEach((e,t)=>this.stopMonitoring(t))}_getWindow(){return this._document.defaultView||window}_getFocusOrigin(e){return this._origin?this._originFromTouchInteraction?this._shouldBeAttributedToTouch(e)?"touch":"program":this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:e&&this._isLastInteractionFromInputLabel(e)?"mouse":"program"}_shouldBeAttributedToTouch(e){return this._detectionMode===sa.EVENTUAL||!!e?.contains(this._inputModalityDetector._mostRecentTarget)}_setClasses(e,t){e.classList.toggle("cdk-focused",!!t),e.classList.toggle("cdk-touch-focused",t==="touch"),e.classList.toggle("cdk-keyboard-focused",t==="keyboard"),e.classList.toggle("cdk-mouse-focused",t==="mouse"),e.classList.toggle("cdk-program-focused",t==="program")}_setOrigin(e,t=!1){this._ngZone.runOutsideAngular(()=>{if(this._origin=e,this._originFromTouchInteraction=e==="touch"&&t,this._detectionMode===sa.IMMEDIATE){clearTimeout(this._originTimeoutId);let n=this._originFromTouchInteraction?Rm:1;this._originTimeoutId=setTimeout(()=>this._origin=null,n)}})}_onFocus(e,t){let n=this._elementInfo.get(t),a=rt(e);!n||!n.checkChildren&&t!==a||this._originChanged(t,this._getFocusOrigin(a),n)}_onBlur(e,t){let n=this._elementInfo.get(t);!n||n.checkChildren&&e.relatedTarget instanceof Node&&t.contains(e.relatedTarget)||(this._setClasses(t),this._emitOrigin(n,null))}_emitOrigin(e,t){e.subject.observers.length&&this._ngZone.run(()=>e.subject.next(t))}_registerGlobalListeners(e){if(!this._platform.isBrowser)return;let t=e.rootNode,n=this._rootNodeFocusListenerCount.get(t)||0;n||this._ngZone.runOutsideAngular(()=>{t.addEventListener("focus",this._rootNodeFocusAndBlurListener,Fr),t.addEventListener("blur",this._rootNodeFocusAndBlurListener,Fr)}),this._rootNodeFocusListenerCount.set(t,n+1),++this._monitoredElementCount===1&&(this._ngZone.runOutsideAngular(()=>{this._getWindow().addEventListener("focus",this._windowFocusListener)}),this._inputModalityDetector.modalityDetected.pipe(oe(this._stopInputModalityDetector)).subscribe(a=>{this._setOrigin(a,!0)}))}_removeGlobalListeners(e){let t=e.rootNode;if(this._rootNodeFocusListenerCount.has(t)){let n=this._rootNodeFocusListenerCount.get(t);n>1?this._rootNodeFocusListenerCount.set(t,n-1):(t.removeEventListener("focus",this._rootNodeFocusAndBlurListener,Fr),t.removeEventListener("blur",this._rootNodeFocusAndBlurListener,Fr),this._rootNodeFocusListenerCount.delete(t))}--this._monitoredElementCount||(this._getWindow().removeEventListener("focus",this._windowFocusListener),this._stopInputModalityDetector.next(),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._originTimeoutId))}_originChanged(e,t,n){this._setClasses(e,t),this._emitOrigin(n,t),this._lastFocusOrigin=t}_getClosestElementsInfo(e){let t=[];return this._elementInfo.forEach((n,a)=>{(a===e||n.checkChildren&&a.contains(e))&&t.push([a,n])}),t}_isLastInteractionFromInputLabel(e){let{_mostRecentTarget:t,mostRecentModality:n}=this._inputModalityDetector;if(n!=="mouse"||!t||t===e||e.nodeName!=="INPUT"&&e.nodeName!=="TEXTAREA"||e.disabled)return!1;let a=e.labels;if(a){for(let r=0;r<a.length;r++)if(a[r].contains(t))return!0}return!1}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var rn=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["ng-component"]],exportAs:["cdkVisuallyHidden"],decls:0,vars:0,template:function(t,n){},styles:[`.cdk-visually-hidden {
453
453
  border: 0;
454
454
  clip: rect(0 0 0 0);
455
455
  height: 1px;
@@ -468,7 +468,7 @@ textarea.cdk-textarea-autosize-measuring-firefox {
468
468
  left: auto;
469
469
  right: 0;
470
470
  }
471
- `],encapsulation:2})}return i})(),Or;function bg(){if(Or===void 0&&(Or=null,typeof window<"u")){let i=window;i.trustedTypes!==void 0&&(Or=i.trustedTypes.createPolicy("angular#components",{createHTML:o=>o}))}return Or}function Fn(i){return bg()?.createHTML(i)||i}function Fm(i,o,e){let t=e.sanitize(Ct.HTML,o);i.innerHTML=Fn(t||"")}function yg(i){if(i.type==="characterData"&&i.target instanceof Comment)return!0;if(i.type==="childList"){for(let o=0;o<i.addedNodes.length;o++)if(!(i.addedNodes[o]instanceof Comment))return!1;for(let o=0;o<i.removedNodes.length;o++)if(!(i.removedNodes[o]instanceof Comment))return!1;return!0}return!1}var Nm=(()=>{class i{create(e){return typeof MutationObserver>"u"?null:new MutationObserver(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Lm=(()=>{class i{_mutationObserverFactory=d(Nm);_observedElements=new Map;_ngZone=d(H);ngOnDestroy(){this._observedElements.forEach((e,t)=>this._cleanupObserver(t))}observe(e){let t=Dt(e);return new yt(n=>{let r=this._observeElement(t).pipe(Pe(u=>u.filter(h=>!yg(h))),Ce(u=>!!u.length)).subscribe(u=>{this._ngZone.run(()=>{n.next(u)})});return()=>{r.unsubscribe(),this._unobserveElement(t)}})}_observeElement(e){return this._ngZone.runOutsideAngular(()=>{if(this._observedElements.has(e))this._observedElements.get(e).count++;else{let t=new I,n=this._mutationObserverFactory.create(a=>t.next(a));n&&n.observe(e,{characterData:!0,childList:!0,subtree:!0}),this._observedElements.set(e,{observer:n,stream:t,count:1})}return this._observedElements.get(e).stream})}_unobserveElement(e){this._observedElements.has(e)&&(this._observedElements.get(e).count--,this._observedElements.get(e).count||this._cleanupObserver(e))}_cleanupObserver(e){if(this._observedElements.has(e)){let{observer:t,stream:n}=this._observedElements.get(e);t&&t.disconnect(),n.complete(),this._observedElements.delete(e)}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Vm=(()=>{class i{_contentObserver=d(Lm);_elementRef=d(N);event=new K;get disabled(){return this._disabled}set disabled(e){this._disabled=e,this._disabled?this._unsubscribe():this._subscribe()}_disabled=!1;get debounce(){return this._debounce}set debounce(e){this._debounce=Ht(e),this._subscribe()}_debounce;_currentSubscription=null;ngAfterContentInit(){!this._currentSubscription&&!this.disabled&&this._subscribe()}ngOnDestroy(){this._unsubscribe()}_subscribe(){this._unsubscribe();let e=this._contentObserver.observe(this._elementRef);this._currentSubscription=(this.debounce?e.pipe(Vt(this.debounce)):e).subscribe(this.event)}_unsubscribe(){this._currentSubscription?.unsubscribe()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkObserveContent",""]],inputs:{disabled:[2,"cdkObserveContentDisabled","disabled",L],debounce:"debounce"},outputs:{event:"cdkObserveContent"},exportAs:["cdkObserveContent"]})}return i})(),ho=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({providers:[Nm]})}return i})();var Ll=(()=>{class i{_platform=d(le);isDisabled(e){return e.hasAttribute("disabled")}isVisible(e){return xg(e)&&getComputedStyle(e).visibility==="visible"}isTabbable(e){if(!this._platform.isBrowser)return!1;let t=Cg(Tg(e));if(t&&(Bm(t)===-1||!this.isVisible(t)))return!1;let n=e.nodeName.toLowerCase(),a=Bm(e);return e.hasAttribute("contenteditable")?a!==-1:n==="iframe"||n==="object"||this._platform.WEBKIT&&this._platform.IOS&&!Eg(e)?!1:n==="audio"?e.hasAttribute("controls")?a!==-1:!1:n==="video"?a===-1?!1:a!==null?!0:this._platform.FIREFOX||e.hasAttribute("controls"):e.tabIndex>=0}isFocusable(e,t){return Ag(e)&&!this.isDisabled(e)&&(t?.ignoreVisibility||this.isVisible(e))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function Cg(i){try{return i.frameElement}catch(o){return null}}function xg(i){return!!(i.offsetWidth||i.offsetHeight||typeof i.getClientRects=="function"&&i.getClientRects().length)}function wg(i){let o=i.nodeName.toLowerCase();return o==="input"||o==="select"||o==="button"||o==="textarea"}function Dg(i){return Sg(i)&&i.type=="hidden"}function kg(i){return Mg(i)&&i.hasAttribute("href")}function Sg(i){return i.nodeName.toLowerCase()=="input"}function Mg(i){return i.nodeName.toLowerCase()=="a"}function Hm(i){if(!i.hasAttribute("tabindex")||i.tabIndex===void 0)return!1;let o=i.getAttribute("tabindex");return!!(o&&!isNaN(parseInt(o,10)))}function Bm(i){if(!Hm(i))return null;let o=parseInt(i.getAttribute("tabindex")||"",10);return isNaN(o)?-1:o}function Eg(i){let o=i.nodeName.toLowerCase(),e=o==="input"&&i.type;return e==="text"||e==="password"||o==="select"||o==="textarea"}function Ag(i){return Dg(i)?!1:wg(i)||kg(i)||i.hasAttribute("contenteditable")||Hm(i)}function Tg(i){return i.ownerDocument&&i.ownerDocument.defaultView||window}var Nl=class{_element;_checker;_ngZone;_document;_injector;_startAnchor=null;_endAnchor=null;_hasAttached=!1;startAnchorListener=()=>this.focusLastTabbableElement();endAnchorListener=()=>this.focusFirstTabbableElement();get enabled(){return this._enabled}set enabled(o){this._enabled=o,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(o,this._startAnchor),this._toggleAnchorTabIndex(o,this._endAnchor))}_enabled=!0;constructor(o,e,t,n,a=!1,r){this._element=o,this._checker=e,this._ngZone=t,this._document=n,this._injector=r,a||this.attachAnchors()}destroy(){let o=this._startAnchor,e=this._endAnchor;o&&(o.removeEventListener("focus",this.startAnchorListener),o.remove()),e&&(e.removeEventListener("focus",this.endAnchorListener),e.remove()),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}attachAnchors(){return this._hasAttached?!0:(this._ngZone.runOutsideAngular(()=>{this._startAnchor||(this._startAnchor=this._createAnchor(),this._startAnchor.addEventListener("focus",this.startAnchorListener)),this._endAnchor||(this._endAnchor=this._createAnchor(),this._endAnchor.addEventListener("focus",this.endAnchorListener))}),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}focusInitialElementWhenReady(o){return new Promise(e=>{this._executeOnStable(()=>e(this.focusInitialElement(o)))})}focusFirstTabbableElementWhenReady(o){return new Promise(e=>{this._executeOnStable(()=>e(this.focusFirstTabbableElement(o)))})}focusLastTabbableElementWhenReady(o){return new Promise(e=>{this._executeOnStable(()=>e(this.focusLastTabbableElement(o)))})}_getRegionBoundary(o){let e=this._element.querySelectorAll(`[cdk-focus-region-${o}], [cdkFocusRegion${o}], [cdk-focus-${o}]`);return o=="start"?e.length?e[0]:this._getFirstTabbableElement(this._element):e.length?e[e.length-1]:this._getLastTabbableElement(this._element)}focusInitialElement(o){let e=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");if(e){if(!this._checker.isFocusable(e)){let t=this._getFirstTabbableElement(e);return t?.focus(o),!!t}return e.focus(o),!0}return this.focusFirstTabbableElement(o)}focusFirstTabbableElement(o){let e=this._getRegionBoundary("start");return e&&e.focus(o),!!e}focusLastTabbableElement(o){let e=this._getRegionBoundary("end");return e&&e.focus(o),!!e}hasAttached(){return this._hasAttached}_getFirstTabbableElement(o){if(this._checker.isFocusable(o)&&this._checker.isTabbable(o))return o;let e=o.children;for(let t=0;t<e.length;t++){let n=e[t].nodeType===this._document.ELEMENT_NODE?this._getFirstTabbableElement(e[t]):null;if(n)return n}return null}_getLastTabbableElement(o){if(this._checker.isFocusable(o)&&this._checker.isTabbable(o))return o;let e=o.children;for(let t=e.length-1;t>=0;t--){let n=e[t].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(e[t]):null;if(n)return n}return null}_createAnchor(){let o=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,o),o.classList.add("cdk-visually-hidden"),o.classList.add("cdk-focus-trap-anchor"),o.setAttribute("aria-hidden","true"),o}_toggleAnchorTabIndex(o,e){o?e.setAttribute("tabindex","0"):e.removeAttribute("tabindex")}toggleAnchors(o){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(o,this._startAnchor),this._toggleAnchorTabIndex(o,this._endAnchor))}_executeOnStable(o){Be(o,{injector:this._injector})}},Vl=(()=>{class i{_checker=d(Ll);_ngZone=d(H);_document=d($);_injector=d(X);constructor(){d(Fe).load(rn)}create(e,t=!1){return new Nl(e,this._checker,this._ngZone,this._document,t,this._injector)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Um=new C("liveAnnouncerElement",{providedIn:"root",factory:()=>null}),Gm=new C("LIVE_ANNOUNCER_DEFAULT_OPTIONS"),Ig=0,ra=(()=>{class i{_ngZone=d(H);_defaultOptions=d(Gm,{optional:!0});_liveElement;_document=d($);_sanitizer=d(na);_previousTimeout;_currentPromise;_currentResolve;constructor(){let e=d(Um,{optional:!0});this._liveElement=e||this._createLiveElement()}announce(e,...t){let n=this._defaultOptions,a,r;return t.length===1&&typeof t[0]=="number"?r=t[0]:[a,r]=t,this.clear(),clearTimeout(this._previousTimeout),a||(a=n&&n.politeness?n.politeness:"polite"),r==null&&n&&(r=n.duration),this._liveElement.setAttribute("aria-live",a),this._liveElement.id&&this._exposeAnnouncerToModals(this._liveElement.id),this._ngZone.runOutsideAngular(()=>(this._currentPromise||(this._currentPromise=new Promise(u=>this._currentResolve=u)),clearTimeout(this._previousTimeout),this._previousTimeout=setTimeout(()=>{!e||typeof e=="string"?this._liveElement.textContent=e:Fm(this._liveElement,e,this._sanitizer),typeof r=="number"&&(this._previousTimeout=setTimeout(()=>this.clear(),r)),this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0},100),this._currentPromise))}clear(){this._liveElement&&(this._liveElement.textContent="")}ngOnDestroy(){clearTimeout(this._previousTimeout),this._liveElement?.remove(),this._liveElement=null,this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0}_createLiveElement(){let e="cdk-live-announcer-element",t=this._document.getElementsByClassName(e),n=this._document.createElement("div");for(let a=0;a<t.length;a++)t[a].remove();return n.classList.add(e),n.classList.add("cdk-visually-hidden"),n.setAttribute("aria-atomic","true"),n.setAttribute("aria-live","polite"),n.id=`cdk-live-announcer-${Ig++}`,this._document.body.appendChild(n),n}_exposeAnnouncerToModals(e){let t=this._document.querySelectorAll('body > .cdk-overlay-container [aria-modal="true"]');for(let n=0;n<t.length;n++){let a=t[n],r=a.getAttribute("aria-owns");r?r.indexOf(e)===-1&&a.setAttribute("aria-owns",r+" "+e):a.setAttribute("aria-owns",e)}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var sn=(function(i){return i[i.NONE=0]="NONE",i[i.BLACK_ON_WHITE=1]="BLACK_ON_WHITE",i[i.WHITE_ON_BLACK=2]="WHITE_ON_BLACK",i})(sn||{}),zm="cdk-high-contrast-black-on-white",jm="cdk-high-contrast-white-on-black",Fl="cdk-high-contrast-active",$m=(()=>{class i{_platform=d(le);_hasCheckedHighContrastMode=!1;_document=d($);_breakpointSubscription;constructor(){this._breakpointSubscription=d(In).observe("(forced-colors: active)").subscribe(()=>{this._hasCheckedHighContrastMode&&(this._hasCheckedHighContrastMode=!1,this._applyBodyHighContrastModeCssClasses())})}getHighContrastMode(){if(!this._platform.isBrowser)return sn.NONE;let e=this._document.createElement("div");e.style.backgroundColor="rgb(1,2,3)",e.style.position="absolute",this._document.body.appendChild(e);let t=this._document.defaultView||window,n=t&&t.getComputedStyle?t.getComputedStyle(e):null,a=(n&&n.backgroundColor||"").replace(/ /g,"");switch(e.remove(),a){case"rgb(0,0,0)":case"rgb(45,50,54)":case"rgb(32,32,32)":return sn.WHITE_ON_BLACK;case"rgb(255,255,255)":case"rgb(255,250,239)":return sn.BLACK_ON_WHITE}return sn.NONE}ngOnDestroy(){this._breakpointSubscription.unsubscribe()}_applyBodyHighContrastModeCssClasses(){if(!this._hasCheckedHighContrastMode&&this._platform.isBrowser&&this._document.body){let e=this._document.body.classList;e.remove(Fl,zm,jm),this._hasCheckedHighContrastMode=!0;let t=this.getHighContrastMode();t===sn.BLACK_ON_WHITE?e.add(Fl,zm):t===sn.WHITE_ON_BLACK&&e.add(Fl,jm)}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),sa=(()=>{class i{constructor(){d($m)._applyBodyHighContrastModeCssClasses()}static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ho]})}return i})();var Rg=200,Pr=class{_letterKeyStream=new I;_items=[];_selectedItemIndex=-1;_pressedLetters=[];_skipPredicateFn;_selectedItem=new I;selectedItem=this._selectedItem;constructor(o,e){let t=typeof e?.debounceInterval=="number"?e.debounceInterval:Rg;e?.skipPredicate&&(this._skipPredicateFn=e.skipPredicate),this.setItems(o),this._setupKeyHandler(t)}destroy(){this._pressedLetters=[],this._letterKeyStream.complete(),this._selectedItem.complete()}setCurrentSelectedItemIndex(o){this._selectedItemIndex=o}setItems(o){this._items=o}handleKey(o){let e=o.keyCode;o.key&&o.key.length===1?this._letterKeyStream.next(o.key.toLocaleUpperCase()):(e>=65&&e<=90||e>=48&&e<=57)&&this._letterKeyStream.next(String.fromCharCode(e))}isTyping(){return this._pressedLetters.length>0}reset(){this._pressedLetters=[]}_setupKeyHandler(o){this._letterKeyStream.pipe(di(e=>this._pressedLetters.push(e)),Vt(o),Ce(()=>this._pressedLetters.length>0),Pe(()=>this._pressedLetters.join("").toLocaleUpperCase())).subscribe(e=>{for(let t=1;t<this._items.length+1;t++){let n=(this._selectedItemIndex+t)%this._items.length,a=this._items[n];if(!this._skipPredicateFn?.(a)&&a.getLabel?.().toLocaleUpperCase().trim().indexOf(e)===0){this._selectedItem.next(a);break}}this._pressedLetters=[]})}};function Ge(i,...o){return o.length?o.some(e=>i[e]):i.altKey||i.shiftKey||i.ctrlKey||i.metaKey}var po=class{_items;_activeItemIndex=R(-1);_activeItem=R(null);_wrap=!1;_typeaheadSubscription=De.EMPTY;_itemChangesSubscription;_vertical=!0;_horizontal=null;_allowedModifierKeys=[];_homeAndEnd=!1;_pageUpAndDown={enabled:!1,delta:10};_effectRef;_typeahead;_skipPredicateFn=o=>o.disabled;constructor(o,e){this._items=o,o instanceof Zi?this._itemChangesSubscription=o.changes.subscribe(t=>this._itemsChanged(t.toArray())):Xi(o)&&(this._effectRef=zt(()=>this._itemsChanged(o()),{injector:e}))}tabOut=new I;change=new I;skipPredicate(o){return this._skipPredicateFn=o,this}withWrap(o=!0){return this._wrap=o,this}withVerticalOrientation(o=!0){return this._vertical=o,this}withHorizontalOrientation(o){return this._horizontal=o,this}withAllowedModifierKeys(o){return this._allowedModifierKeys=o,this}withTypeAhead(o=200){this._typeaheadSubscription.unsubscribe();let e=this._getItemsArray();return this._typeahead=new Pr(e,{debounceInterval:typeof o=="number"?o:void 0,skipPredicate:t=>this._skipPredicateFn(t)}),this._typeaheadSubscription=this._typeahead.selectedItem.subscribe(t=>{this.setActiveItem(t)}),this}cancelTypeahead(){return this._typeahead?.reset(),this}withHomeAndEnd(o=!0){return this._homeAndEnd=o,this}withPageUpDown(o=!0,e=10){return this._pageUpAndDown={enabled:o,delta:e},this}setActiveItem(o){let e=this._activeItem();this.updateActiveItem(o),this._activeItem()!==e&&this.change.next(this._activeItemIndex())}onKeydown(o){let e=o.keyCode,n=["altKey","ctrlKey","metaKey","shiftKey"].every(a=>!o[a]||this._allowedModifierKeys.indexOf(a)>-1);switch(e){case 9:this.tabOut.next();return;case 40:if(this._vertical&&n){this.setNextItemActive();break}else return;case 38:if(this._vertical&&n){this.setPreviousItemActive();break}else return;case 39:if(this._horizontal&&n){this._horizontal==="rtl"?this.setPreviousItemActive():this.setNextItemActive();break}else return;case 37:if(this._horizontal&&n){this._horizontal==="rtl"?this.setNextItemActive():this.setPreviousItemActive();break}else return;case 36:if(this._homeAndEnd&&n){this.setFirstItemActive();break}else return;case 35:if(this._homeAndEnd&&n){this.setLastItemActive();break}else return;case 33:if(this._pageUpAndDown.enabled&&n){let a=this._activeItemIndex()-this._pageUpAndDown.delta;this._setActiveItemByIndex(a>0?a:0,1);break}else return;case 34:if(this._pageUpAndDown.enabled&&n){let a=this._activeItemIndex()+this._pageUpAndDown.delta,r=this._getItemsArray().length;this._setActiveItemByIndex(a<r?a:r-1,-1);break}else return;default:(n||Ge(o,"shiftKey"))&&this._typeahead?.handleKey(o);return}this._typeahead?.reset(),o.preventDefault()}get activeItemIndex(){return this._activeItemIndex()}get activeItem(){return this._activeItem()}isTyping(){return!!this._typeahead&&this._typeahead.isTyping()}setFirstItemActive(){this._setActiveItemByIndex(0,1)}setLastItemActive(){this._setActiveItemByIndex(this._getItemsArray().length-1,-1)}setNextItemActive(){this._activeItemIndex()<0?this.setFirstItemActive():this._setActiveItemByDelta(1)}setPreviousItemActive(){this._activeItemIndex()<0&&this._wrap?this.setLastItemActive():this._setActiveItemByDelta(-1)}updateActiveItem(o){let e=this._getItemsArray(),t=typeof o=="number"?o:e.indexOf(o),n=e[t];this._activeItem.set(n??null),this._activeItemIndex.set(t),this._typeahead?.setCurrentSelectedItemIndex(t)}destroy(){this._typeaheadSubscription.unsubscribe(),this._itemChangesSubscription?.unsubscribe(),this._effectRef?.destroy(),this._typeahead?.destroy(),this.tabOut.complete(),this.change.complete()}_setActiveItemByDelta(o){this._wrap?this._setActiveInWrapMode(o):this._setActiveInDefaultMode(o)}_setActiveInWrapMode(o){let e=this._getItemsArray();for(let t=1;t<=e.length;t++){let n=(this._activeItemIndex()+o*t+e.length)%e.length,a=e[n];if(!this._skipPredicateFn(a)){this.setActiveItem(n);return}}}_setActiveInDefaultMode(o){this._setActiveItemByIndex(this._activeItemIndex()+o,o)}_setActiveItemByIndex(o,e){let t=this._getItemsArray();if(t[o]){for(;this._skipPredicateFn(t[o]);)if(o+=e,!t[o])return;this.setActiveItem(o)}}_getItemsArray(){return Xi(this._items)?this._items():this._items instanceof Zi?this._items.toArray():this._items}_itemsChanged(o){this._typeahead?.setItems(o);let e=this._activeItem();if(e){let t=o.indexOf(e);t>-1&&t!==this._activeItemIndex()&&(this._activeItemIndex.set(t),this._typeahead?.setCurrentSelectedItemIndex(t))}}};var Ln=class extends po{setActiveItem(o){this.activeItem&&this.activeItem.setInactiveStyles(),super.setActiveItem(o),this.activeItem&&this.activeItem.setActiveStyles()}};var cn=class extends po{_origin="program";setFocusOrigin(o){return this._origin=o,this}setActiveItem(o){super.setActiveItem(o),this.activeItem&&this.activeItem.focus(this._origin)}};var Km=new Map,be=class i{_appId=d(Sn);static _infix=`a${Math.floor(Math.random()*1e5).toString()}`;getId(o,e=!1){this._appId!=="ng"&&(o+=this._appId);let t=Km.get(o);return t===void 0?t=0:t++,Km.set(o,t),`${o}${e?i._infix+"-":""}${t}`}static \u0275fac=function(e){return new(e||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})};var Xm=" ";function Og(i,o,e){let t=Nr(i,o);e=e.trim(),!t.some(n=>n.trim()===e)&&(t.push(e),i.setAttribute(o,t.join(Xm)))}function Pg(i,o,e){let t=Nr(i,o);e=e.trim();let n=t.filter(a=>a!==e);n.length?i.setAttribute(o,n.join(Xm)):i.removeAttribute(o)}function Nr(i,o){return i.getAttribute(o)?.match(/\S+/g)??[]}var Zm="cdk-describedby-message",Fr="cdk-describedby-host",zl=0,Qm=(()=>{class i{_platform=d(le);_document=d($);_messageRegistry=new Map;_messagesContainer=null;_id=`${zl++}`;constructor(){d(Fe).load(rn),this._id=d(Sn)+"-"+zl++}describe(e,t,n){if(!this._canBeDescribed(e,t))return;let a=Bl(t,n);typeof t!="string"?(Ym(t,this._id),this._messageRegistry.set(a,{messageElement:t,referenceCount:0})):this._messageRegistry.has(a)||this._createMessageElement(t,n),this._isElementDescribedByMessage(e,a)||this._addMessageReference(e,a)}removeDescription(e,t,n){if(!t||!this._isElementNode(e))return;let a=Bl(t,n);if(this._isElementDescribedByMessage(e,a)&&this._removeMessageReference(e,a),typeof t=="string"){let r=this._messageRegistry.get(a);r&&r.referenceCount===0&&this._deleteMessageElement(a)}this._messagesContainer?.childNodes.length===0&&(this._messagesContainer.remove(),this._messagesContainer=null)}ngOnDestroy(){let e=this._document.querySelectorAll(`[${Fr}="${this._id}"]`);for(let t=0;t<e.length;t++)this._removeCdkDescribedByReferenceIds(e[t]),e[t].removeAttribute(Fr);this._messagesContainer?.remove(),this._messagesContainer=null,this._messageRegistry.clear()}_createMessageElement(e,t){let n=this._document.createElement("div");Ym(n,this._id),n.textContent=e,t&&n.setAttribute("role",t),this._createMessagesContainer(),this._messagesContainer.appendChild(n),this._messageRegistry.set(Bl(e,t),{messageElement:n,referenceCount:0})}_deleteMessageElement(e){this._messageRegistry.get(e)?.messageElement?.remove(),this._messageRegistry.delete(e)}_createMessagesContainer(){if(this._messagesContainer)return;let e="cdk-describedby-message-container",t=this._document.querySelectorAll(`.${e}[platform="server"]`);for(let a=0;a<t.length;a++)t[a].remove();let n=this._document.createElement("div");n.style.visibility="hidden",n.classList.add(e),n.classList.add("cdk-visually-hidden"),this._platform.isBrowser||n.setAttribute("platform","server"),this._document.body.appendChild(n),this._messagesContainer=n}_removeCdkDescribedByReferenceIds(e){let t=Nr(e,"aria-describedby").filter(n=>n.indexOf(Zm)!=0);e.setAttribute("aria-describedby",t.join(" "))}_addMessageReference(e,t){let n=this._messageRegistry.get(t);Og(e,"aria-describedby",n.messageElement.id),e.setAttribute(Fr,this._id),n.referenceCount++}_removeMessageReference(e,t){let n=this._messageRegistry.get(t);n.referenceCount--,Pg(e,"aria-describedby",n.messageElement.id),e.removeAttribute(Fr)}_isElementDescribedByMessage(e,t){let n=Nr(e,"aria-describedby"),a=this._messageRegistry.get(t),r=a&&a.messageElement.id;return!!r&&n.indexOf(r)!=-1}_canBeDescribed(e,t){if(!this._isElementNode(e))return!1;if(t&&typeof t=="object")return!0;let n=t==null?"":`${t}`.trim(),a=e.getAttribute("aria-label");return n?!a||a.trim()!==n:!1}_isElementNode(e){return e.nodeType===this._document.ELEMENT_NODE}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function Bl(i,o){return typeof i=="string"?`${o||""}/${i}`:i}function Ym(i,o){i.id||(i.id=`${Zm}-${o}-${zl++}`)}var su=(()=>{class i{_renderer;_elementRef;onChange=e=>{};onTouched=()=>{};constructor(e,t){this._renderer=e,this._elementRef=t}setProperty(e,t){this._renderer.setProperty(this._elementRef.nativeElement,e,t)}registerOnTouched(e){this.onTouched=e}registerOnChange(e){this.onChange=e}setDisabledState(e){this.setProperty("disabled",e)}static \u0275fac=function(t){return new(t||i)(de(ve),de(N))};static \u0275dir=k({type:i})}return i})(),lu=(()=>{class i extends su{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,features:[Q]})}return i})(),Mi=new C("");var Fg={provide:Mi,useExisting:nt(()=>Ei),multi:!0};function Ng(){let i=Xt()?Xt().getUserAgent():"";return/android (\d+)/.test(i.toLowerCase())}var Lg=new C(""),Ei=(()=>{class i extends su{_compositionMode;_composing=!1;constructor(e,t,n){super(e,t),this._compositionMode=n,this._compositionMode==null&&(this._compositionMode=!Ng())}writeValue(e){let t=e??"";this.setProperty("value",t)}_handleInput(e){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(e)}_compositionStart(){this._composing=!0}_compositionEnd(e){this._composing=!1,this._compositionMode&&this.onChange(e)}static \u0275fac=function(t){return new(t||i)(de(ve),de(N),de(Lg,8))};static \u0275dir=k({type:i,selectors:[["input","formControlName","",3,"type","checkbox",3,"ngNoCva",""],["textarea","formControlName","",3,"ngNoCva",""],["input","formControl","",3,"type","checkbox",3,"ngNoCva",""],["textarea","formControl","",3,"ngNoCva",""],["input","ngModel","",3,"type","checkbox",3,"ngNoCva",""],["textarea","ngModel","",3,"ngNoCva",""],["","ngDefaultControl",""]],hostBindings:function(t,n){t&1&&A("input",function(r){return n._handleInput(r.target.value)})("blur",function(){return n.onTouched()})("compositionstart",function(){return n._compositionStart()})("compositionend",function(r){return n._compositionEnd(r.target.value)})},standalone:!1,features:[J([Fg]),Q]})}return i})();function Wl(i){return i==null||ql(i)===0}function ql(i){return i==null?null:Array.isArray(i)||typeof i=="string"?i.length:i instanceof Set?i.size:null}var zi=new C(""),Wr=new C(""),Vg=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,st=class{static min(o){return cu(o)}static max(o){return du(o)}static required(o){return mu(o)}static requiredTrue(o){return Bg(o)}static email(o){return zg(o)}static minLength(o){return jg(o)}static maxLength(o){return Hg(o)}static pattern(o){return Ug(o)}static nullValidator(o){return Vr()}static compose(o){return _u(o)}static composeAsync(o){return vu(o)}};function cu(i){return o=>{if(o.value==null||i==null)return null;let e=parseFloat(o.value);return!isNaN(e)&&e<i?{min:{min:i,actual:o.value}}:null}}function du(i){return o=>{if(o.value==null||i==null)return null;let e=parseFloat(o.value);return!isNaN(e)&&e>i?{max:{max:i,actual:o.value}}:null}}function mu(i){return Wl(i.value)?{required:!0}:null}function Bg(i){return i.value===!0?null:{required:!0}}function zg(i){return Wl(i.value)||Vg.test(i.value)?null:{email:!0}}function jg(i){return o=>{let e=o.value?.length??ql(o.value);return e===null||e===0?null:e<i?{minlength:{requiredLength:i,actualLength:e}}:null}}function Hg(i){return o=>{let e=o.value?.length??ql(o.value);return e!==null&&e>i?{maxlength:{requiredLength:i,actualLength:e}}:null}}function Ug(i){if(!i)return Vr;let o,e;return typeof i=="string"?(e="",i.charAt(0)!=="^"&&(e+="^"),e+=i,i.charAt(i.length-1)!=="$"&&(e+="$"),o=new RegExp(e)):(e=i.toString(),o=i),t=>{if(Wl(t.value))return null;let n=t.value;return o.test(n)?null:{pattern:{requiredPattern:e,actualValue:n}}}}function Vr(i){return null}function uu(i){return i!=null}function hu(i){return $s(i)?$c(i):i}function pu(i){let o={};return i.forEach(e=>{o=e!=null?V(V({},o),e):o}),Object.keys(o).length===0?null:o}function fu(i,o){return o.map(e=>e(i))}function Gg(i){return!i.validate}function gu(i){return i.map(o=>Gg(o)?o:e=>o.validate(e))}function _u(i){if(!i)return null;let o=i.filter(uu);return o.length==0?null:function(e){return pu(fu(e,o))}}function Kl(i){return i!=null?_u(gu(i)):null}function vu(i){if(!i)return null;let o=i.filter(uu);return o.length==0?null:function(e){let t=fu(e,o).map(hu);return $a(t).pipe(Pe(pu))}}function Yl(i){return i!=null?vu(gu(i)):null}function Jm(i,o){return i===null?[o]:Array.isArray(i)?[...i,o]:[i,o]}function bu(i){return i._rawValidators}function yu(i){return i._rawAsyncValidators}function jl(i){return i?Array.isArray(i)?i:[i]:[]}function Br(i,o){return Array.isArray(i)?i.includes(o):i===o}function eu(i,o){let e=jl(o);return jl(i).forEach(n=>{Br(e,n)||e.push(n)}),e}function tu(i,o){return jl(o).filter(e=>!Br(i,e))}var zr=class{get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators=[];_rawAsyncValidators=[];_setValidators(o){this._rawValidators=o||[],this._composedValidatorFn=Kl(this._rawValidators)}_setAsyncValidators(o){this._rawAsyncValidators=o||[],this._composedAsyncValidatorFn=Yl(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_onDestroyCallbacks=[];_registerOnDestroy(o){this._onDestroyCallbacks.push(o)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(o=>o()),this._onDestroyCallbacks=[]}reset(o=void 0){this.control?.reset(o)}hasError(o,e){return this.control?this.control.hasError(o,e):!1}getError(o,e){return this.control?this.control.getError(o,e):null}},Bi=class extends zr{name;get formDirective(){return null}get path(){return null}};var da="VALID",Lr="INVALID",fo="PENDING",ma="DISABLED",dn=class{},jr=class extends dn{value;source;constructor(o,e){super(),this.value=o,this.source=e}},ha=class extends dn{pristine;source;constructor(o,e){super(),this.pristine=o,this.source=e}},pa=class extends dn{touched;source;constructor(o,e){super(),this.touched=o,this.source=e}},go=class extends dn{status;source;constructor(o,e){super(),this.status=o,this.source=e}},Hr=class extends dn{source;constructor(o){super(),this.source=o}},Vn=class extends dn{source;constructor(o){super(),this.source=o}};function Xl(i){return(qr(i)?i.validators:i)||null}function $g(i){return Array.isArray(i)?Kl(i):i||null}function Zl(i,o){return(qr(o)?o.asyncValidators:i)||null}function Wg(i){return Array.isArray(i)?Yl(i):i||null}function qr(i){return i!=null&&!Array.isArray(i)&&typeof i=="object"}function Cu(i,o,e){let t=i.controls;if(!(o?Object.keys(t):t).length)throw new ae(1e3,"");if(!wu(t,e))throw new ae(1001,"")}function xu(i,o,e){i._forEachChild((t,n)=>{if(e[n]===void 0)throw new ae(-1002,"")})}var _o=class{_pendingDirty=!1;_hasOwnPendingAsyncValidator=null;_pendingTouched=!1;_onCollectionChange=()=>{};_updateOn;_hasRequired=R(!1);_parent=null;_asyncValidationSubscription;_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators;_rawAsyncValidators;value;constructor(o,e){this._assignValidators(o),this._assignAsyncValidators(e)}get validator(){return this._composedValidatorFn}set validator(o){this._rawValidators=this._composedValidatorFn=o,this._updateHasRequiredValidator()}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(o){this._rawAsyncValidators=this._composedAsyncValidatorFn=o}get parent(){return this._parent}get status(){return pt(this.statusReactive)}set status(o){pt(()=>this.statusReactive.set(o))}_status=W(()=>this.statusReactive());statusReactive=R(void 0);get valid(){return this.status===da}get invalid(){return this.status===Lr}get pending(){return this.status===fo}get disabled(){return this.status===ma}get enabled(){return this.status!==ma}errors;get pristine(){return pt(this.pristineReactive)}set pristine(o){pt(()=>this.pristineReactive.set(o))}_pristine=W(()=>this.pristineReactive());pristineReactive=R(!0);get dirty(){return!this.pristine}get touched(){return pt(this.touchedReactive)}set touched(o){pt(()=>this.touchedReactive.set(o))}_touched=W(()=>this.touchedReactive());touchedReactive=R(!1);get untouched(){return!this.touched}_events=new I;events=this._events.asObservable();valueChanges;statusChanges;get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(o){this._assignValidators(o)}setAsyncValidators(o){this._assignAsyncValidators(o)}addValidators(o){this.setValidators(eu(o,this._rawValidators))}addAsyncValidators(o){this.setAsyncValidators(eu(o,this._rawAsyncValidators))}removeValidators(o){this.setValidators(tu(o,this._rawValidators))}removeAsyncValidators(o){this.setAsyncValidators(tu(o,this._rawAsyncValidators))}hasValidator(o){return Br(this._rawValidators,o)}hasAsyncValidator(o){return Br(this._rawAsyncValidators,o)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(o={}){let e=this.touched===!1;this.touched=!0;let t=o.sourceControl??this;o.onlySelf||this._parent?.markAsTouched(Oe(V({},o),{sourceControl:t})),e&&o.emitEvent!==!1&&this._events.next(new pa(!0,t))}markAllAsDirty(o={}){this.markAsDirty({onlySelf:!0,emitEvent:o.emitEvent,sourceControl:this}),this._forEachChild(e=>e.markAllAsDirty(o))}markAllAsTouched(o={}){this.markAsTouched({onlySelf:!0,emitEvent:o.emitEvent,sourceControl:this}),this._forEachChild(e=>e.markAllAsTouched(o))}markAsUntouched(o={}){let e=this.touched===!0;this.touched=!1,this._pendingTouched=!1;let t=o.sourceControl??this;this._forEachChild(n=>{n.markAsUntouched({onlySelf:!0,emitEvent:o.emitEvent,sourceControl:t})}),o.onlySelf||this._parent?._updateTouched(o,t),e&&o.emitEvent!==!1&&this._events.next(new pa(!1,t))}markAsDirty(o={}){let e=this.pristine===!0;this.pristine=!1;let t=o.sourceControl??this;o.onlySelf||this._parent?.markAsDirty(Oe(V({},o),{sourceControl:t})),e&&o.emitEvent!==!1&&this._events.next(new ha(!1,t))}markAsPristine(o={}){let e=this.pristine===!1;this.pristine=!0,this._pendingDirty=!1;let t=o.sourceControl??this;this._forEachChild(n=>{n.markAsPristine({onlySelf:!0,emitEvent:o.emitEvent})}),o.onlySelf||this._parent?._updatePristine(o,t),e&&o.emitEvent!==!1&&this._events.next(new ha(!0,t))}markAsPending(o={}){this.status=fo;let e=o.sourceControl??this;o.emitEvent!==!1&&(this._events.next(new go(this.status,e)),this.statusChanges.emit(this.status)),o.onlySelf||this._parent?.markAsPending(Oe(V({},o),{sourceControl:e}))}disable(o={}){let e=this._parentMarkedDirty(o.onlySelf);this.status=ma,this.errors=null,this._forEachChild(n=>{n.disable(Oe(V({},o),{onlySelf:!0}))}),this._updateValue();let t=o.sourceControl??this;o.emitEvent!==!1&&(this._events.next(new jr(this.value,t)),this._events.next(new go(this.status,t)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(Oe(V({},o),{skipPristineCheck:e}),this),this._onDisabledChange.forEach(n=>n(!0))}enable(o={}){let e=this._parentMarkedDirty(o.onlySelf);this.status=da,this._forEachChild(t=>{t.enable(Oe(V({},o),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:o.emitEvent}),this._updateAncestors(Oe(V({},o),{skipPristineCheck:e}),this),this._onDisabledChange.forEach(t=>t(!1))}_updateAncestors(o,e){o.onlySelf||(this._parent?.updateValueAndValidity(o),o.skipPristineCheck||this._parent?._updatePristine({},e),this._parent?._updateTouched({},e))}setParent(o){this._parent=o}getRawValue(){return this.value}updateValueAndValidity(o={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){let t=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===da||this.status===fo)&&this._runAsyncValidator(t,o.emitEvent)}let e=o.sourceControl??this;o.emitEvent!==!1&&(this._events.next(new jr(this.value,e)),this._events.next(new go(this.status,e)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),o.onlySelf||this._parent?.updateValueAndValidity(Oe(V({},o),{sourceControl:e}))}_updateTreeValidity(o={emitEvent:!0}){this._forEachChild(e=>e._updateTreeValidity(o)),this.updateValueAndValidity({onlySelf:!0,emitEvent:o.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?ma:da}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(o,e){if(this.asyncValidator){this.status=fo,this._hasOwnPendingAsyncValidator={emitEvent:e!==!1,shouldHaveEmitted:o!==!1};let t=hu(this.asyncValidator(this));this._asyncValidationSubscription=t.subscribe(n=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(n,{emitEvent:e,shouldHaveEmitted:o})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();let o=(this._hasOwnPendingAsyncValidator?.emitEvent||this._hasOwnPendingAsyncValidator?.shouldHaveEmitted)??!1;return this._hasOwnPendingAsyncValidator=null,o}return!1}setErrors(o,e={}){this.errors=o,this._updateControlsErrors(e.emitEvent!==!1,this,e.shouldHaveEmitted)}get(o){let e=o;return e==null||(Array.isArray(e)||(e=e.split(".")),e.length===0)?null:e.reduce((t,n)=>t&&t._find(n),this)}getError(o,e){let t=e?this.get(e):this;return t?.errors?t.errors[o]:null}hasError(o,e){return!!this.getError(o,e)}get root(){let o=this;for(;o._parent;)o=o._parent;return o}_updateControlsErrors(o,e,t){this.status=this._calculateStatus(),o&&this.statusChanges.emit(this.status),(o||t)&&this._events.next(new go(this.status,e)),this._parent&&this._parent._updateControlsErrors(o,e,t)}_initObservables(){this.valueChanges=new K,this.statusChanges=new K}_calculateStatus(){return this._allControlsDisabled()?ma:this.errors?Lr:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(fo)?fo:this._anyControlsHaveStatus(Lr)?Lr:da}_anyControlsHaveStatus(o){return this._anyControls(e=>e.status===o)}_anyControlsDirty(){return this._anyControls(o=>o.dirty)}_anyControlsTouched(){return this._anyControls(o=>o.touched)}_updatePristine(o,e){let t=!this._anyControlsDirty(),n=this.pristine!==t;this.pristine=t,o.onlySelf||this._parent?._updatePristine(o,e),n&&this._events.next(new ha(this.pristine,e))}_updateTouched(o={},e){this.touched=this._anyControlsTouched(),this._events.next(new pa(this.touched,e)),o.onlySelf||this._parent?._updateTouched(o,e)}_onDisabledChange=[];_registerOnCollectionChange(o){this._onCollectionChange=o}_setUpdateStrategy(o){qr(o)&&o.updateOn!=null&&(this._updateOn=o.updateOn)}_parentMarkedDirty(o){return!o&&!!this._parent?.dirty&&!this._parent._anyControlsDirty()}_find(o){return null}_assignValidators(o){this._rawValidators=Array.isArray(o)?o.slice():o,this._composedValidatorFn=$g(this._rawValidators),this._updateHasRequiredValidator()}_assignAsyncValidators(o){this._rawAsyncValidators=Array.isArray(o)?o.slice():o,this._composedAsyncValidatorFn=Wg(this._rawAsyncValidators)}_updateHasRequiredValidator(){pt(()=>this._hasRequired.set(this.hasValidator(st.required)))}};function wu(i,o){return Object.hasOwn(i,o)}function qg(i){return i.tagName==="INPUT"||i.tagName==="SELECT"||i.tagName==="TEXTAREA"}function Kg(i,o,e,t){switch(e){case"name":i.setAttribute(o,e,t);break;case"disabled":case"readonly":case"required":t?i.setAttribute(o,e,""):i.removeAttribute(o,e);break;case"max":case"min":case"minLength":case"maxLength":t!==void 0?i.setAttribute(o,e,t.toString()):i.removeAttribute(o,e);break}}var Hl=class{kind;context;control;message;constructor({kind:o,context:e,control:t}){this.kind=o,this.context=e,this.control=t}};function Du(i){return typeof i=="number"?i:parseFloat(i)}var Ql=(()=>{class i{_validator=Vr;_onChange;_enabled;ngOnChanges(e){if(this.inputName in e){let t=this.normalizeInput(e[this.inputName].currentValue);this._enabled=this.enabled(t),this._validator=this._enabled?this.createValidator(t):Vr,this._onChange?.()}}validate(e){return this._validator(e)}registerOnValidatorChange(e){this._onChange=e}enabled(e){return e!=null}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,features:[Se]})}return i})(),Yg={provide:zi,useExisting:nt(()=>Jl),multi:!0},Jl=(()=>{class i extends Ql{max;inputName="max";normalizeInput=e=>Du(e);createValidator=e=>du(e);static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["input","type","number","max","","formControlName",""],["input","type","number","max","","formControl",""],["input","type","number","max","","ngModel",""]],hostVars:1,hostBindings:function(t,n){t&2&&Z("max",n._enabled?n.max:null)},inputs:{max:"max"},standalone:!1,features:[J([Yg]),Q]})}return i})(),Xg={provide:zi,useExisting:nt(()=>ec),multi:!0},ec=(()=>{class i extends Ql{min;inputName="min";normalizeInput=e=>Du(e);createValidator=e=>cu(e);static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["input","type","number","min","","formControlName",""],["input","type","number","min","","formControl",""],["input","type","number","min","","ngModel",""]],hostVars:1,hostBindings:function(t,n){t&2&&Z("min",n._enabled?n.min:null)},inputs:{min:"min"},standalone:!1,features:[J([Xg]),Q]})}return i})(),Zg={provide:zi,useExisting:nt(()=>Kr),multi:!0};var Kr=(()=>{class i extends Ql{required;inputName="required";normalizeInput=L;createValidator=e=>mu;enabled(e){return e}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","required","","formControlName","",3,"type","checkbox"],["","required","","formControl","",3,"type","checkbox"],["","required","","ngModel","",3,"type","checkbox"]],hostVars:1,hostBindings:function(t,n){t&2&&Z("required",n._enabled?"":null)},inputs:{required:"required"},standalone:!1,features:[J([Zg]),Q]})}return i})();var Qg=new C(""),ga=new C("",{factory:()=>Yr}),Yr="always";function ku(i,o){return[...o.path,i]}function Ul(i,o,e=Yr){tc(i,o),o.valueAccessor.writeValue(i.value),(i.disabled||e==="always")&&o.valueAccessor.setDisabledState?.(i.disabled),e_(i,o),i_(i,o),t_(i,o),Jg(i,o)}function iu(i,o,e=!0){let t=()=>{};o?.valueAccessor?.registerOnChange(t),o?.valueAccessor?.registerOnTouched(t),Gr(i,o),i&&(o._invokeOnDestroyCallbacks(),i._registerOnCollectionChange(()=>{}))}function Ur(i,o){i.forEach(e=>{e.registerOnValidatorChange&&e.registerOnValidatorChange(o)})}function Jg(i,o){if(o.valueAccessor.setDisabledState){let e=t=>{o.valueAccessor.setDisabledState(t)};i.registerOnDisabledChange(e),o._registerOnDestroy(()=>{i._unregisterOnDisabledChange(e)})}}function tc(i,o){let e=bu(i);o.validator!==null?i.setValidators(Jm(e,o.validator)):typeof e=="function"&&i.setValidators([e]);let t=yu(i);o.asyncValidator!==null?i.setAsyncValidators(Jm(t,o.asyncValidator)):typeof t=="function"&&i.setAsyncValidators([t]);let n=()=>i.updateValueAndValidity();Ur(o._rawValidators,n),Ur(o._rawAsyncValidators,n)}function Gr(i,o){let e=!1;if(i!==null){if(o.validator!==null){let n=bu(i);if(Array.isArray(n)&&n.length>0){let a=n.filter(r=>r!==o.validator);a.length!==n.length&&(e=!0,i.setValidators(a))}}if(o.asyncValidator!==null){let n=yu(i);if(Array.isArray(n)&&n.length>0){let a=n.filter(r=>r!==o.asyncValidator);a.length!==n.length&&(e=!0,i.setAsyncValidators(a))}}}let t=()=>{};return Ur(o._rawValidators,t),Ur(o._rawAsyncValidators,t),e}function e_(i,o){o.valueAccessor.registerOnChange(e=>{i._pendingValue=e,i._pendingChange=!0,i._pendingDirty=!0,i.updateOn==="change"&&Su(i,o)})}function t_(i,o){o.valueAccessor.registerOnTouched(()=>{i._pendingTouched=!0,i.updateOn==="blur"&&i._pendingChange&&Su(i,o),i.updateOn!=="submit"&&i.markAsTouched()})}function Su(i,o){i._pendingDirty&&i.markAsDirty(),i.setValue(i._pendingValue,{emitModelToViewChange:!1}),o.viewToModelUpdate(i._pendingValue),i._pendingChange=!1}function i_(i,o){let e=(t,n)=>{o.valueAccessor.writeValue(t),n&&o.viewToModelUpdate(t)};i.registerOnChange(e),o._registerOnDestroy(()=>{i._unregisterOnChange(e)})}function Mu(i,o){i==null,tc(i,o)}function n_(i,o){return Gr(i,o)}function Eu(i,o){if(!i.hasOwnProperty("model"))return!1;let e=i.model;return e.isFirstChange()?!0:!Object.is(o,e.currentValue)}function o_(i){return Object.getPrototypeOf(i.constructor)===lu}function Au(i,o){i._syncPendingControls(),o.forEach(e=>{let t=e.control;t.updateOn==="submit"&&t._pendingChange&&(e.viewToModelUpdate(t._pendingValue),t._pendingChange=!1)})}function a_(i,o){if(!o)return null;Array.isArray(o);let e,t,n;return o.forEach(a=>{a.constructor===Ei?e=a:o_(a)?t=a:n=a}),n||t||e||null}function r_(i,o){let e=i.indexOf(o);e>-1&&i.splice(e,1)}var Tu={provide:Qg,useFactory:()=>{let i=d(Jt,{self:!0});return{setParseErrors:o=>{i.setParseErrorSource(o)},set onReset(o){i.onReset=o}}}},Jt=class extends zr{_parent=null;name=null;valueAccessor=null;isCustomControlBased=!1;userOnReset;resetSubscription;set onReset(o){this.userOnReset=o,this.resetSubscription?.unsubscribe(),this.resetSubscription=void 0,this.control&&(this.resetSubscription=this.control.events.subscribe(e=>{e instanceof Vn&&this.control&&this.userOnReset?.(this.control.value)}),this.subscription?.add(this.resetSubscription))}isNativeFormElement=!1;rawValueAccessors;_selectedValueAccessor=null;get selectedValueAccessor(){return this._selectedValueAccessor??=a_(this,this.rawValueAccessors)}parseErrorsValidator=null;renderer;injector;requiredValidatorViaDi;subscription;customControlBindings=null;constructor(o,e,t){super(),this.injector=o,this.renderer=e,this.rawValueAccessors=t,this.injector?.get(Bt)?.onDestroy(()=>{this.removeParseErrorsValidator(this.control),this.subscription?.unsubscribe()})}setupCustomControl(){this.subscription?.unsubscribe();let o=this.injector?.get(te);if(!this.control||!o)return;let e=o.markForCheck.bind(o);this.subscription=new De,this.subscription.add(this.control.valueChanges.subscribe(e)),this.subscription.add(this.control.statusChanges.subscribe(e)),this.resetSubscription?.unsubscribe(),this.resetSubscription=void 0,this.userOnReset&&(this.resetSubscription=this.control.events.subscribe(t=>{t instanceof Vn&&this.control&&this.userOnReset?.(this.control.value)}),this.subscription.add(this.resetSubscription)),this.parseErrorsValidator&&this.control.addValidators(this.parseErrorsValidator)}ngControlCreate(o){!o.nativeElement.hasAttribute?.("ngNoCva")&&(this.rawValueAccessors&&this.rawValueAccessors.length>0||this.valueAccessor!==null)||!o.customControl||(this.isCustomControlBased=!0,o.listenToCustomControlModel(n=>{this.control?.setValue(n,{emitModelToViewChange:!1}),this.control?.markAsDirty(),this.viewToModelUpdate(n)}),o.listenToCustomControlOutput("touch",()=>{this.control?.markAsTouched()}),this.customControlBindings={},this.isNativeFormElement=qg(o.nativeElement),this.requiredValidatorViaDi=this._rawValidators.find(n=>n instanceof Kr))}ngControlUpdate(o,e){if(!this.isCustomControlBased)return;let t=this.control,n=this.customControlBindings;Object.is(n.value,t.value)||(n.value=t.value,o.setCustomControlModelInput(t.value)),this.bindControlProperty(o,n,"touched",t.touched),this.bindControlProperty(o,n,"dirty",t.dirty),this.bindControlProperty(o,n,"valid",t.valid),this.bindControlProperty(o,n,"invalid",t.invalid),this.bindControlProperty(o,n,"pending",t.pending),this.bindControlProperty(o,n,"disabled",t.disabled),this.shouldBindRequired&&this.bindControlProperty(o,n,"required",this.isRequired);let a=t.errors;if(n.errors!==a){n.errors=a;let r=this._convertErrors(a);o.setInputOnDirectives("errors",r)}}get isRequired(){return(this.requiredValidatorViaDi?._enabled||this.control?._hasRequired())??!1}get shouldBindRequired(){return!0}bindControlProperty(o,e,t,n){if(e[t]===n)return;e[t]=n;let a=o.setInputOnDirectives(t,n);this.isNativeFormElement&&!a&&(t==="disabled"||t==="required")&&this.renderer&&Kg(this.renderer,o.nativeElement,t,n)}_convertErrors(o){if(o===null)return[];let e=this.control;return Object.entries(o).map(([t,n])=>new Hl({context:n,kind:t,control:e}))}setParseErrorSource(o){if(o===void 0)return;let e=null,t=W(()=>{let n=o();return n.length===0?null:n.reduce((a,r)=>(a[r.kind]=r,a),{})});this.parseErrorsValidator=(()=>e).bind(this),zt(()=>{e=t(),this.control?.updateValueAndValidity({emitEvent:!1})},{injector:this.injector})}removeParseErrorsValidator(o){this.parseErrorsValidator&&(o?.removeValidators(this.parseErrorsValidator),o?.updateValueAndValidity({emitEvent:!1}))}},$r=class{_cd;constructor(o){this._cd=o}get isTouched(){return this._cd?.control?._touched?.(),!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return this._cd?.control?._pristine?.(),!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return this._cd?.control?._status?.(),!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return this._cd?._submitted?.(),!!this._cd?.submitted}};var Ai=(()=>{class i extends $r{constructor(e){super(e)}static \u0275fac=function(t){return new(t||i)(de(Jt,2))};static \u0275dir=k({type:i,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(t,n){t&2&&p("ng-untouched",n.isUntouched)("ng-touched",n.isTouched)("ng-pristine",n.isPristine)("ng-dirty",n.isDirty)("ng-valid",n.isValid)("ng-invalid",n.isInvalid)("ng-pending",n.isPending)},standalone:!1,features:[Q]})}return i})(),mn=(()=>{class i extends $r{constructor(e){super(e)}static \u0275fac=function(t){return new(t||i)(de(Bi,10))};static \u0275dir=k({type:i,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["","formArray",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(t,n){t&2&&p("ng-untouched",n.isUntouched)("ng-touched",n.isTouched)("ng-pristine",n.isPristine)("ng-dirty",n.isDirty)("ng-valid",n.isValid)("ng-invalid",n.isInvalid)("ng-pending",n.isPending)("ng-submitted",n.isSubmitted)},standalone:!1,features:[Q]})}return i})(),vo=class extends _o{constructor(o,e,t){super(Xl(e),Zl(t,e)),this.controls=o,this._initObservables(),this._setUpdateStrategy(e),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;registerControl(o,e){let t=this._find(o);return t||(this.controls[o]=e,e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange),e)}addControl(o,e,t={}){this.registerControl(o,e),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}removeControl(o,e={}){let t=this._find(o);t&&t._registerOnCollectionChange(()=>{}),delete this.controls[o],this.updateValueAndValidity({emitEvent:e.emitEvent}),this._onCollectionChange()}setControl(o,e,t={}){let n=this._find(o);n&&n._registerOnCollectionChange(()=>{}),delete this.controls[o],e&&this.registerControl(o,e),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}contains(o){return this._find(o)?.enabled===!0}setValue(o,e={}){pt(()=>{xu(this,!0,o),Object.keys(o).forEach(t=>{Cu(this,!0,t),this.controls[t].setValue(o[t],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e)})}patchValue(o,e={}){o!=null&&(Object.keys(o).forEach(t=>{let n=this._find(t);n&&n.patchValue(o[t],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e))}reset(o={},e={}){this._forEachChild((t,n)=>{t.reset(o?o[n]:null,Oe(V({},e),{onlySelf:!0}))}),this._updatePristine(e,this),this._updateTouched(e,this),this.updateValueAndValidity(e),e?.emitEvent!==!1&&this._events.next(new Vn(this))}getRawValue(){return this._reduceChildren({},(o,e,t)=>(o[t]=e.getRawValue(),o))}_syncPendingControls(){let o=this._reduceChildren(!1,(e,t)=>t._syncPendingControls()?!0:e);return o&&this.updateValueAndValidity({onlySelf:!0}),o}_forEachChild(o){Object.keys(this.controls).forEach(e=>{let t=this.controls[e];t&&o(t,e)})}_setUpControls(){this._forEachChild(o=>{o.setParent(this),o._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(o){for(let[e,t]of Object.entries(this.controls))if(this.contains(e)&&o(t))return!0;return!1}_reduceValue(){let o={};return this._reduceChildren(o,(e,t,n)=>((t.enabled||this.disabled)&&(e[n]=t.value),e))}_reduceChildren(o,e){let t=o;return this._forEachChild((n,a)=>{t=e(t,n,a)}),t}_allControlsDisabled(){for(let o of Object.keys(this.controls))if(this.controls[o].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(o){return wu(this.controls,o)?this.controls[o]:null}};var Gl=class extends vo{};var s_={provide:Bi,useExisting:nt(()=>_a)},ua=Promise.resolve(),_a=(()=>{class i extends Bi{callSetDisabledState;get submitted(){return pt(this.submittedReactive)}_submitted=W(()=>this.submittedReactive());submittedReactive=R(!1);_directives=new Set;form;ngSubmit=new K;options;constructor(e,t,n){super(),this.callSetDisabledState=n,this.form=new vo({},Kl(e),Yl(t))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(e){ua.then(()=>{let t=this._findContainer(e.path);e.control=t.registerControl(e.name,e.control),e._setupWithForm(this.callSetDisabledState),e.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(e)})}getControl(e){return this.form.get(e.path)}removeControl(e){ua.then(()=>{this._findContainer(e.path)?.removeControl(e.name),this._directives.delete(e)})}addFormGroup(e){ua.then(()=>{let t=this._findContainer(e.path),n=new vo({});Mu(n,e),t.registerControl(e.name,n),n.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(e){ua.then(()=>{this._findContainer(e.path)?.removeControl?.(e.name)})}getFormGroup(e){return this.form.get(e.path)}updateModel(e,t){ua.then(()=>{this.form.get(e.path).setValue(t)})}setValue(e){this.control.setValue(e)}onSubmit(e){return this.submittedReactive.set(!0),Au(this.form,this._directives),this.ngSubmit.emit(e),this.form._events.next(new Hr(this.control)),e?.target?.method==="dialog"}onReset(){this.resetForm()}resetForm(e=void 0){this.form.reset(e),this.submittedReactive.set(!1)}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.form._updateOn=this.options.updateOn)}_findContainer(e){return e.pop(),e.length?this.form.get(e):this.form}static \u0275fac=function(t){return new(t||i)(de(zi,10),de(Wr,10),de(ga,8))};static \u0275dir=k({type:i,selectors:[["form",3,"ngNoForm","",3,"formGroup","",3,"formArray",""],["ng-form"],["","ngForm",""]],hostBindings:function(t,n){t&1&&A("submit",function(r){return n.onSubmit(r)})("reset",function(){return n.onReset()})},inputs:{options:[0,"ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[J([s_]),Q]})}return i})();function nu(i,o){let e=i.indexOf(o);e>-1&&i.splice(e,1)}function ou(i){return typeof i=="object"&&i!==null&&Object.keys(i).length===2&&"value"in i&&"disabled"in i}var fa=class extends _o{defaultValue=null;_onChange=[];_pendingValue;_pendingChange=!1;constructor(o=null,e,t){super(Xl(e),Zl(t,e)),this._applyFormState(o),this._setUpdateStrategy(e),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),qr(e)&&(e.nonNullable||e.initialValueIsDefault)&&(ou(o)?this.defaultValue=o.value:this.defaultValue=o)}setValue(o,e={}){pt(()=>{this.value=this._pendingValue=o,this._onChange.length&&e.emitModelToViewChange!==!1&&this._onChange.forEach(t=>t(this.value,e.emitViewToModelChange!==!1)),this.updateValueAndValidity(e)})}patchValue(o,e={}){this.setValue(o,e)}reset(o=this.defaultValue,e={}){this._applyFormState(o),this.markAsPristine(e),this.markAsUntouched(e),this.setValue(this.value,e),e.overwriteDefaultValue&&(this.defaultValue=this.value),this._pendingChange=!1,e?.emitEvent!==!1&&this._events.next(new Vn(this))}_updateValue(){}_anyControls(o){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(o){this._onChange.push(o)}_unregisterOnChange(o){nu(this._onChange,o)}registerOnDisabledChange(o){this._onDisabledChange.push(o)}_unregisterOnDisabledChange(o){nu(this._onDisabledChange,o)}_forEachChild(o){}_syncPendingControls(){return this.updateOn==="submit"&&(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),this._pendingChange)?(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),!0):!1}_applyFormState(o){ou(o)?(this.value=this._pendingValue=o.value,o.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=o}};var l_=i=>i instanceof fa;var c_={provide:Jt,useExisting:nt(()=>ic)},au=Promise.resolve(),ic=(()=>{class i extends Jt{_changeDetectorRef;callSetDisabledState;control=new fa;static ngAcceptInputType_isDisabled;_registered=!1;viewModel;name="";isDisabled;model;options;update=new K;constructor(e,t,n,a,r,u,h,g){super(h,g,a),this._changeDetectorRef=r,this.callSetDisabledState=u,this._parent=e,this._setValidators(t),this._setAsyncValidators(n)}ngOnChanges(e){if(this._checkForErrors(),!this._registered||"name"in e){if(this._registered&&(this._checkName(),this.formDirective)){let t=e.name.previousValue;this.formDirective.removeControl({name:t,path:this._getPath(t)})}this._setUpControl()}"isDisabled"in e&&this._updateDisabled(e),Eu(e,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective?.removeControl(this)}\u0275ngControlCreate(e){super.ngControlCreate(e)}\u0275ngControlUpdate(e){super.ngControlUpdate(e,!1)}get shouldBindRequired(){return!1}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!!(this.options&&this.options.standalone)}_setUpStandalone(){this.isCustomControlBased?this.setupCustomControl():(this.valueAccessor??=this.selectedValueAccessor,Ul(this.control,this,this.callSetDisabledState)),this.control.updateValueAndValidity({emitEvent:!1})}_setupWithForm(e){this.isCustomControlBased?this.setupCustomControl():(this.valueAccessor??=this.selectedValueAccessor,Ul(this.control,this,e))}_checkForErrors(){this._checkName()}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),!this._isStandalone()&&this.name}_updateValue(e){au.then(()=>{this.control.setValue(e,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(e){let t=e.isDisabled.currentValue,n=t!==0&&L(t);au.then(()=>{n&&!this.control.disabled?this.control.disable():!n&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(e){return this._parent?ku(e,this._parent):[e]}static \u0275fac=function(t){return new(t||i)(de(Bi,9),de(zi,10),de(Wr,10),de(Mi,10),de(te,8),de(ga,8),de(X,8),de(ve,8))};static \u0275dir=k({type:i,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"],options:[0,"ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],standalone:!1,features:[J([c_,Tu]),Q,Se,qs(null)]})}return i})();var bo=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""],standalone:!1})}return i})(),d_={provide:Mi,useExisting:nt(()=>va),multi:!0},va=(()=>{class i extends lu{writeValue(e){let t=e??"";this.setProperty("value",t)}registerOnChange(e){this.onChange=t=>{e(t==""?null:parseFloat(t))}}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["input","type","number","formControlName","",3,"ngNoCva",""],["input","type","number","formControl","",3,"ngNoCva",""],["input","type","number","ngModel","",3,"ngNoCva",""]],hostBindings:function(t,n){t&1&&A("input",function(r){return n.onChange(r.target.value)})("blur",function(){return n.onTouched()})},standalone:!1,features:[J([d_]),Q]})}return i})();var $l=class extends _o{constructor(o,e,t){super(Xl(e),Zl(t,e)),this.controls=o,this._initObservables(),this._setUpdateStrategy(e),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;at(o){return this.controls[this._adjustIndex(o)]}push(o,e={}){Array.isArray(o)?o.forEach(t=>{this.controls.push(t),this._registerControl(t)}):(this.controls.push(o),this._registerControl(o)),this.updateValueAndValidity({emitEvent:e.emitEvent}),this._onCollectionChange()}insert(o,e,t={}){this.controls.splice(o,0,e),this._registerControl(e),this.updateValueAndValidity({emitEvent:t.emitEvent})}removeAt(o,e={}){let t=this._adjustIndex(o);t<0&&(t=0),this.controls[t]&&this.controls[t]._registerOnCollectionChange(()=>{}),this.controls.splice(t,1),this.updateValueAndValidity({emitEvent:e.emitEvent})}setControl(o,e,t={}){let n=this._adjustIndex(o);n<0&&(n=0),this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),this.controls.splice(n,1),e&&(this.controls.splice(n,0,e),this._registerControl(e)),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(o,e={}){pt(()=>{xu(this,!1,o),o.forEach((t,n)=>{Cu(this,!1,n),this.at(n).setValue(t,{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e)})}patchValue(o,e={}){o!=null&&(o.forEach((t,n)=>{this.at(n)&&this.at(n).patchValue(t,{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e))}reset(o=[],e={}){this._forEachChild((t,n)=>{t.reset(o[n],Oe(V({},e),{onlySelf:!0}))}),this._updatePristine(e,this),this._updateTouched(e,this),this.updateValueAndValidity(e),e?.emitEvent!==!1&&this._events.next(new Vn(this))}getRawValue(){return this.controls.map(o=>o.getRawValue())}clear(o={}){this.controls.length<1||(this._forEachChild(e=>e._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:o.emitEvent}))}_adjustIndex(o){return o<0?o+this.length:o}_syncPendingControls(){let o=this.controls.reduce((e,t)=>t._syncPendingControls()?!0:e,!1);return o&&this.updateValueAndValidity({onlySelf:!0}),o}_forEachChild(o){this.controls.forEach((e,t)=>{o(e,t)})}_updateValue(){this.value=this.controls.filter(o=>o.enabled||this.disabled).map(o=>o.value)}_anyControls(o){return this.controls.some(e=>e.enabled&&o(e))}_setUpControls(){this._forEachChild(o=>this._registerControl(o))}_allControlsDisabled(){for(let o of this.controls)if(o.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(o){o.setParent(this),o._registerOnCollectionChange(this._onCollectionChange)}_find(o){return this.at(o)??null}};var m_=(()=>{class i extends Bi{callSetDisabledState;get submitted(){return pt(this._submittedReactive)}set submitted(e){this._submittedReactive.set(e)}_submitted=W(()=>this._submittedReactive());_submittedReactive=R(!1);_oldForm;_onCollectionChange=()=>this._updateDomValue();directives=[];constructor(e,t,n){super(),this.callSetDisabledState=n,this._setValidators(e),this._setAsyncValidators(t)}ngOnChanges(e){this.onChanges(e)}ngOnDestroy(){this.onDestroy()}onChanges(e){this._checkFormPresent(),e.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}onDestroy(){this.form&&(Gr(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get path(){return[]}addControl(e){let t=this.form.get(e.path);return e._setupWithForm(t,this.callSetDisabledState),t.updateValueAndValidity({emitEvent:!1}),this.directives.push(e),t}getControl(e){return this.form.get(e.path)}removeControl(e){iu(e.control||null,e,!1),r_(this.directives,e)}addFormGroup(e){this._setUpFormContainer(e)}removeFormGroup(e){this._cleanUpFormContainer(e)}getFormGroup(e){return this.form.get(e.path)}getFormArray(e){return this.form.get(e.path)}addFormArray(e){this._setUpFormContainer(e)}removeFormArray(e){this._cleanUpFormContainer(e)}updateModel(e,t){this.form.get(e.path).setValue(t)}onReset(){this.resetForm()}resetForm(e=void 0,t={}){this.form.reset(e,t),this._submittedReactive.set(!1)}onSubmit(e){return this.submitted=!0,Au(this.form,this.directives),this.ngSubmit.emit(e),this.form._events.next(new Hr(this.control)),e?.target?.method==="dialog"}_updateDomValue(){this.directives.forEach(e=>{let t=e.control,n=this.form.get(e.path);t!==n&&(iu(t||null,e),l_(n)&&e._setupWithForm(n,this.callSetDisabledState))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(e){let t=this.form.get(e.path);Mu(t,e),t.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(e){let t=this.form?.get(e.path);t&&n_(t,e)&&t.updateValueAndValidity({emitEvent:!1})}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm?._registerOnCollectionChange(()=>{})}_updateValidators(){tc(this.form,this),this._oldForm&&Gr(this._oldForm,this)}_checkFormPresent(){this.form}static \u0275fac=function(t){return new(t||i)(de(zi,10),de(Wr,10),de(ga,8))};static \u0275dir=k({type:i,features:[Q,Se]})}return i})();var Iu=new C("");var u_={provide:Jt,useExisting:nt(()=>ji)},ji=(()=>{class i extends Jt{_ngModelWarningConfig;_added=!1;viewModel;control;name=null;set isDisabled(e){}model;update=new K;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(e,t,n,a,r,u,h){super(h,u,a),this._ngModelWarningConfig=r,this._parent=e,this._setValidators(t),this._setAsyncValidators(n)}_setupWithForm(e,t){this.control=e,this.isCustomControlBased?this.setupCustomControl():(this.valueAccessor??=this.selectedValueAccessor,Ul(e,this,t))}ngOnChanges(e){this._added||this._setUpControl(),Eu(e,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective?.removeControl(this)}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}get path(){return ku(this.name==null?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_setUpControl(){this.control=this.formDirective.addControl(this),this._added=!0}\u0275ngControlCreate(e){super.ngControlCreate(e)}\u0275ngControlUpdate(e){this.isCustomControlBased&&(this._added||this._setUpControl(),super.ngControlUpdate(e,!0))}static \u0275fac=function(t){return new(t||i)(de(Bi,13),de(zi,10),de(Wr,10),de(Mi,10),de(Iu,8),de(ve,8),de(X,8))};static \u0275dir=k({type:i,selectors:[["","formControlName",""]],inputs:{name:[0,"formControlName","name"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},standalone:!1,features:[J([u_,Tu]),Q,Se,qs(null)]})}return i})();var h_={provide:Bi,useExisting:nt(()=>Ut)},Ut=(()=>{class i extends m_{form=null;ngSubmit=new K;get control(){return this.form}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","formGroup",""]],hostBindings:function(t,n){t&1&&A("submit",function(r){return n.onSubmit(r)})("reset",function(){return n.onReset()})},inputs:{form:[0,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[J([h_]),Q]})}return i})();var Ru=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();function ru(i){return!!i&&(i.asyncValidators!==void 0||i.validators!==void 0||i.updateOn!==void 0)}var un=(()=>{class i{useNonNullable=!1;get nonNullable(){let e=new i;return e.useNonNullable=!0,e}group(e,t=null){let n=this._reduceControls(e),a={};return ru(t)?a=t:t!==null&&(a.validators=t.validator,a.asyncValidators=t.asyncValidator),new vo(n,a)}record(e,t=null){let n=this._reduceControls(e);return new Gl(n,t)}control(e,t,n){let a={};return this.useNonNullable?(ru(t)?a=t:(a.validators=t,a.asyncValidators=n),new fa(e,Oe(V({},a),{nonNullable:!0}))):new fa(e,t,n)}array(e,t,n){let a=e.map(r=>this._createControl(r));return new $l(a,t,n)}_reduceControls(e){let t={};return Object.keys(e).forEach(n=>{t[n]=this._createControl(e[n])}),t}_createControl(e){if(e instanceof fa)return e;if(e instanceof _o)return e;if(Array.isArray(e)){let t=e[0],n=e.length>1?e[1]:null,a=e.length>2?e[2]:null;return this.control(t,n,a)}else return this.control(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var hn=(()=>{class i{static withConfig(e){return{ngModule:i,providers:[{provide:ga,useValue:e.callSetDisabledState??Yr}]}}static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Ru]})}return i})(),pn=(()=>{class i{static withConfig(e){return{ngModule:i,providers:[{provide:Iu,useValue:e.warnOnNgModelWithFormControl??"always"},{provide:ga,useValue:e.callSetDisabledState??Yr}]}}static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Ru]})}return i})();var Ou=new C("MAT_INPUT_VALUE_ACCESSOR");var nc=class{_box;_destroyed=new I;_resizeSubject=new I;_resizeObserver;_elementObservables=new Map;constructor(o){this._box=o,typeof ResizeObserver<"u"&&(this._resizeObserver=new ResizeObserver(e=>this._resizeSubject.next(e)))}observe(o){return this._elementObservables.has(o)||this._elementObservables.set(o,new yt(e=>{let t=this._resizeSubject.subscribe(e);return this._resizeObserver?.observe(o,{box:this._box}),()=>{this._resizeObserver?.unobserve(o),t.unsubscribe(),this._elementObservables.delete(o)}}).pipe(Ce(e=>e.some(t=>t.target===o)),zs({bufferSize:1,refCount:!0}),oe(this._destroyed))),this._elementObservables.get(o)}destroy(){this._destroyed.next(),this._destroyed.complete(),this._resizeSubject.complete(),this._elementObservables.clear()}},Pu=(()=>{class i{_cleanupErrorListener;_observers=new Map;_ngZone=d(H);constructor(){typeof ResizeObserver<"u"}ngOnDestroy(){for(let[,e]of this._observers)e.destroy();this._observers.clear(),this._cleanupErrorListener?.()}observe(e,t){let n=t?.box||"content-box";return this._observers.has(n)||this._observers.set(n,new nc(n)),this._observers.get(n).observe(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var p_=["notch"],f_=["*"],Fu=["iconPrefixContainer"],Nu=["textPrefixContainer"],Lu=["iconSuffixContainer"],Vu=["textSuffixContainer"],g_=["textField"],__=["*",[["mat-label"]],[["","matPrefix",""],["","matIconPrefix",""]],[["","matTextPrefix",""]],[["","matTextSuffix",""]],[["","matSuffix",""],["","matIconSuffix",""]],[["mat-error"],["","matError",""]],[["mat-hint",3,"align","end"]],[["mat-hint","align","end"]]],v_=["*","mat-label","[matPrefix], [matIconPrefix]","[matTextPrefix]","[matTextSuffix]","[matSuffix], [matIconSuffix]","mat-error, [matError]","mat-hint:not([align='end'])","mat-hint[align='end']"];function b_(i,o){i&1&&v(0,"span",21)}function y_(i,o){if(i&1&&(s(0,"label",20),U(1,1),M(2,b_,1,0,"span",21),l()),i&2){let e=D(2);x("floating",e._shouldLabelFloat())("monitorResize",e._hasOutline())("id",e._labelId),Z("for",e._control.disableAutomaticLabeling?null:e._control.id),c(2),E(!e.hideRequiredMarker&&e._control.required?2:-1)}}function C_(i,o){if(i&1&&M(0,y_,3,5,"label",20),i&2){let e=D();E(e._hasFloatingLabel()?0:-1)}}function x_(i,o){i&1&&v(0,"div",7)}function w_(i,o){}function D_(i,o){if(i&1&&ze(0,w_,0,0,"ng-template",13),i&2){D(2);let e=Ne(1);x("ngTemplateOutlet",e)}}function k_(i,o){if(i&1&&(s(0,"div",9),M(1,D_,1,1,null,13),l()),i&2){let e=D();x("matFormFieldNotchedOutlineOpen",e._shouldLabelFloat()),c(),E(e._forceDisplayInfixLabel()?-1:1)}}function S_(i,o){i&1&&(s(0,"div",10,2),U(2,2),l())}function M_(i,o){i&1&&(s(0,"div",11,3),U(2,3),l())}function E_(i,o){}function A_(i,o){if(i&1&&ze(0,E_,0,0,"ng-template",13),i&2){D();let e=Ne(1);x("ngTemplateOutlet",e)}}function T_(i,o){i&1&&(s(0,"div",14,4),U(2,4),l())}function I_(i,o){i&1&&(s(0,"div",15,5),U(2,5),l())}function R_(i,o){i&1&&v(0,"div",16)}function O_(i,o){i&1&&(s(0,"div",18),U(1,6),l())}function P_(i,o){if(i&1&&(s(0,"mat-hint",22),m(1),l()),i&2){let e=D(2);x("id",e._hintLabelId),c(),q(e.hintLabel)}}function F_(i,o){if(i&1&&(s(0,"div",19),M(1,P_,2,2,"mat-hint",22),U(2,7),v(3,"div",23),U(4,8),l()),i&2){let e=D();c(),E(e.hintLabel?1:-1)}}var Ot=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-label"]]})}return i})(),$u=new C("MatError"),fn=(()=>{class i{id=d(be).getId("mat-mdc-error-");static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-error"],["","matError",""]],hostAttrs:[1,"mat-mdc-form-field-error","mat-mdc-form-field-bottom-align"],hostVars:1,hostBindings:function(t,n){t&2&&dt("id",n.id)},inputs:{id:"id"},features:[J([{provide:$u,useExisting:i}])]})}return i})(),Zr=(()=>{class i{align="start";id=d(be).getId("mat-mdc-hint-");static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-hint"]],hostAttrs:[1,"mat-mdc-form-field-hint","mat-mdc-form-field-bottom-align"],hostVars:4,hostBindings:function(t,n){t&2&&(dt("id",n.id),Z("align",null),p("mat-mdc-form-field-hint-end",n.align==="end"))},inputs:{align:"align",id:"id"}})}return i})(),N_=new C("MatPrefix");var L_=new C("MatSuffix");var Wu=new C("FloatingLabelParent"),Bu=(()=>{class i{_elementRef=d(N);get floating(){return this._floating}set floating(e){this._floating=e,this.monitorResize&&this._handleResize()}_floating=!1;get monitorResize(){return this._monitorResize}set monitorResize(e){this._monitorResize=e,this._monitorResize?this._subscribeToResize():this._resizeSubscription.unsubscribe()}_monitorResize=!1;_resizeObserver=d(Pu);_ngZone=d(H);_parent=d(Wu);_resizeSubscription=new De;ngOnDestroy(){this._resizeSubscription.unsubscribe()}getWidth(){return V_(this._elementRef.nativeElement)}get element(){return this._elementRef.nativeElement}_handleResize(){setTimeout(()=>this._parent._handleLabelResized())}_subscribeToResize(){this._resizeSubscription.unsubscribe(),this._ngZone.runOutsideAngular(()=>{this._resizeSubscription=this._resizeObserver.observe(this._elementRef.nativeElement,{box:"border-box"}).subscribe(()=>this._handleResize())})}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["label","matFormFieldFloatingLabel",""]],hostAttrs:[1,"mdc-floating-label","mat-mdc-floating-label"],hostVars:2,hostBindings:function(t,n){t&2&&p("mdc-floating-label--float-above",n.floating)},inputs:{floating:"floating",monitorResize:"monitorResize"}})}return i})();function V_(i){let o=i;if(o.offsetParent!==null)return o.scrollWidth;let e=o.cloneNode(!0);e.style.setProperty("position","absolute"),e.style.setProperty("transform","translate(-9999px, -9999px)"),document.documentElement.appendChild(e);let t=e.scrollWidth;return e.remove(),t}var zu="mdc-line-ripple--active",Xr="mdc-line-ripple--deactivating",ju=(()=>{class i{_elementRef=d(N);_cleanupTransitionEnd;constructor(){let e=d(H),t=d(ve);e.runOutsideAngular(()=>{this._cleanupTransitionEnd=t.listen(this._elementRef.nativeElement,"transitionend",this._handleTransitionEnd)})}activate(){let e=this._elementRef.nativeElement.classList;e.remove(Xr),e.add(zu)}deactivate(){this._elementRef.nativeElement.classList.add(Xr)}_handleTransitionEnd=e=>{let t=this._elementRef.nativeElement.classList,n=t.contains(Xr);e.propertyName==="opacity"&&n&&t.remove(zu,Xr)};ngOnDestroy(){this._cleanupTransitionEnd()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["div","matFormFieldLineRipple",""]],hostAttrs:[1,"mdc-line-ripple"]})}return i})(),Hu=(()=>{class i{_elementRef=d(N);_ngZone=d(H);open=!1;_notch;ngAfterViewInit(){let e=this._elementRef.nativeElement,t=e.querySelector(".mdc-floating-label");t?(e.classList.add("mdc-notched-outline--upgraded"),typeof requestAnimationFrame=="function"&&(t.style.transitionDuration="0s",this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>t.style.transitionDuration="")}))):e.classList.add("mdc-notched-outline--no-label")}_setNotchWidth(e){let t=this._notch.nativeElement;!this.open||!e?t.style.width="":t.style.width=`calc(${e}px * var(--mat-mdc-form-field-floating-label-scale, 0.75) + 9px)`}_setMaxWidth(e){this._notch.nativeElement.style.setProperty("--mat-form-field-notch-max-width",`calc(100% - ${e}px)`)}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["div","matFormFieldNotchedOutline",""]],viewQuery:function(t,n){if(t&1&&Me(p_,5),t&2){let a;O(a=P())&&(n._notch=a.first)}},hostAttrs:[1,"mdc-notched-outline"],hostVars:2,hostBindings:function(t,n){t&2&&p("mdc-notched-outline--notched",n.open)},inputs:{open:[0,"matFormFieldNotchedOutlineOpen","open"]},ngContentSelectors:f_,decls:5,vars:0,consts:[["notch",""],[1,"mat-mdc-notch-piece","mdc-notched-outline__leading"],[1,"mat-mdc-notch-piece","mdc-notched-outline__notch"],[1,"mat-mdc-notch-piece","mdc-notched-outline__trailing"]],template:function(t,n){t&1&&(ce(),ht(0,"div",1),Ie(1,"div",2,0),U(3),je(),ht(4,"div",3))},encapsulation:2})}return i})(),ya=(()=>{class i{value=null;stateChanges;id;placeholder;ngControl=null;focused=!1;empty=!1;shouldLabelFloat=!1;required=!1;disabled=!1;errorState=!1;controlType;autofilled;userAriaDescribedBy;disableAutomaticLabeling;describedByIds;static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i})}return i})();var Bn=new C("MatFormField"),B_=new C("MAT_FORM_FIELD_DEFAULT_OPTIONS"),Uu="fill",z_="auto",Gu="fixed",j_="translateY(-50%)",kt=(()=>{class i{_elementRef=d(N);_changeDetectorRef=d(te);_platform=d(le);_idGenerator=d(be);_ngZone=d(H);_defaults=d(B_,{optional:!0});_currentDirection;_textField;_iconPrefixContainer;_textPrefixContainer;_iconSuffixContainer;_textSuffixContainer;_floatingLabel;_notchedOutline;_lineRipple;_iconPrefixContainerSignal=Uo("iconPrefixContainer");_textPrefixContainerSignal=Uo("textPrefixContainer");_iconSuffixContainerSignal=Uo("iconSuffixContainer");_textSuffixContainerSignal=Uo("textSuffixContainer");_prefixSuffixContainers=W(()=>[this._iconPrefixContainerSignal(),this._textPrefixContainerSignal(),this._iconSuffixContainerSignal(),this._textSuffixContainerSignal()].map(e=>e?.nativeElement).filter(e=>e!==void 0));_formFieldControl;_prefixChildren;_suffixChildren;_errorChildren;_hintChildren;_labelChild=pd(Ot);get hideRequiredMarker(){return this._hideRequiredMarker}set hideRequiredMarker(e){this._hideRequiredMarker=mt(e)}_hideRequiredMarker=!1;color="primary";get floatLabel(){return this._floatLabel||this._defaults?.floatLabel||z_}set floatLabel(e){e!==this._floatLabel&&(this._floatLabel=e,this._changeDetectorRef.markForCheck())}_floatLabel;get appearance(){return this._appearanceSignal()}set appearance(e){let t=e||this._defaults?.appearance||Uu;this._appearanceSignal.set(t)}_appearanceSignal=R(Uu);get subscriptSizing(){return this._subscriptSizing||this._defaults?.subscriptSizing||Gu}set subscriptSizing(e){this._subscriptSizing=e||this._defaults?.subscriptSizing||Gu}_subscriptSizing=null;get hintLabel(){return this._hintLabel}set hintLabel(e){this._hintLabel=e,this._processHints()}_hintLabel="";_hasIconPrefix=!1;_hasTextPrefix=!1;_hasIconSuffix=!1;_hasTextSuffix=!1;_labelId=this._idGenerator.getId("mat-mdc-form-field-label-");_hintLabelId=this._idGenerator.getId("mat-mdc-hint-");_describedByIds;get _control(){return this._explicitFormFieldControl||this._formFieldControl}set _control(e){this._explicitFormFieldControl=e}_destroyed=new I;_isFocused=null;_explicitFormFieldControl;_previousControl=null;_previousControlValidatorFn=null;_stateChanges;_valueChanges;_describedByChanges;_outlineLabelOffsetResizeObserver=null;_animationsDisabled=pe();constructor(){let e=this._defaults,t=d(qe);e&&(e.appearance&&(this.appearance=e.appearance),this._hideRequiredMarker=!!e?.hideRequiredMarker,e.color&&(this.color=e.color)),zt(()=>this._currentDirection=t.valueSignal()),this._syncOutlineLabelOffset()}ngAfterViewInit(){this._updateFocusState(),this._animationsDisabled||this._ngZone.runOutsideAngular(()=>{setTimeout(()=>{this._elementRef.nativeElement.classList.add("mat-form-field-animations-enabled")},300)}),this._changeDetectorRef.detectChanges()}ngAfterContentInit(){this._assertFormFieldControl(),this._initializeSubscript(),this._initializePrefixAndSuffix()}ngAfterContentChecked(){this._assertFormFieldControl(),this._control!==this._previousControl&&(this._initializeControl(this._previousControl),this._control.ngControl&&this._control.ngControl.control&&(this._previousControlValidatorFn=this._control.ngControl.control.validator),this._previousControl=this._control),this._control.ngControl&&this._control.ngControl.control&&this._control.ngControl.control.validator!==this._previousControlValidatorFn&&this._changeDetectorRef.markForCheck()}ngOnDestroy(){this._outlineLabelOffsetResizeObserver?.disconnect(),this._stateChanges?.unsubscribe(),this._valueChanges?.unsubscribe(),this._describedByChanges?.unsubscribe(),this._destroyed.next(),this._destroyed.complete()}getLabelId=W(()=>this._hasFloatingLabel()?this._labelId:null);getConnectedOverlayOrigin(){return this._textField||this._elementRef}_animateAndLockLabel(){this._hasFloatingLabel()&&(this.floatLabel="always")}_initializeControl(e){let t=this._control,n="mat-mdc-form-field-type-";e&&this._elementRef.nativeElement.classList.remove(n+e.controlType),t.controlType&&this._elementRef.nativeElement.classList.add(n+t.controlType),this._stateChanges?.unsubscribe(),this._stateChanges=t.stateChanges.subscribe(()=>{this._updateFocusState(),this._changeDetectorRef.markForCheck()}),this._describedByChanges?.unsubscribe(),this._describedByChanges=t.stateChanges.pipe(ke([void 0,void 0]),Pe(()=>[t.errorState,t.userAriaDescribedBy]),Bs(),Ce(([[a,r],[u,h]])=>a!==u||r!==h)).subscribe(()=>this._syncDescribedByIds()),this._valueChanges?.unsubscribe(),t.ngControl&&t.ngControl.valueChanges&&(this._valueChanges=t.ngControl.valueChanges.pipe(oe(this._destroyed)).subscribe(()=>this._changeDetectorRef.markForCheck()))}_checkPrefixAndSuffixTypes(){this._hasIconPrefix=!!this._prefixChildren.find(e=>!e._isText),this._hasTextPrefix=!!this._prefixChildren.find(e=>e._isText),this._hasIconSuffix=!!this._suffixChildren.find(e=>!e._isText),this._hasTextSuffix=!!this._suffixChildren.find(e=>e._isText)}_initializePrefixAndSuffix(){this._checkPrefixAndSuffixTypes(),$e(this._prefixChildren.changes,this._suffixChildren.changes).subscribe(()=>{this._checkPrefixAndSuffixTypes(),this._changeDetectorRef.markForCheck()})}_initializeSubscript(){this._hintChildren.changes.subscribe(()=>{this._processHints(),this._changeDetectorRef.markForCheck()}),this._errorChildren.changes.subscribe(()=>{this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),this._validateHints(),this._syncDescribedByIds()}_assertFormFieldControl(){this._control}_updateFocusState(){let e=this._control.focused;e&&!this._isFocused?(this._isFocused=!0,this._lineRipple?.activate()):!e&&(this._isFocused||this._isFocused===null)&&(this._isFocused=!1,this._lineRipple?.deactivate()),this._elementRef.nativeElement.classList.toggle("mat-focused",e),this._textField?.nativeElement.classList.toggle("mdc-text-field--focused",e)}_syncOutlineLabelOffset(){_d({earlyRead:()=>{if(this._appearanceSignal()!=="outline")return this._outlineLabelOffsetResizeObserver?.disconnect(),null;if(globalThis.ResizeObserver){this._outlineLabelOffsetResizeObserver||=new globalThis.ResizeObserver(()=>{this._writeOutlinedLabelStyles(this._getOutlinedLabelOffset())});for(let e of this._prefixSuffixContainers())this._outlineLabelOffsetResizeObserver.observe(e,{box:"border-box"})}return this._getOutlinedLabelOffset()},write:e=>this._writeOutlinedLabelStyles(e())})}_shouldAlwaysFloat(){return this.floatLabel==="always"}_hasOutline(){return this.appearance==="outline"}_forceDisplayInfixLabel(){return!this._platform.isBrowser&&this._prefixChildren.length&&!this._shouldLabelFloat()}_hasFloatingLabel=W(()=>!!this._labelChild());_shouldLabelFloat(){return this._hasFloatingLabel()?this._control.shouldLabelFloat||this._shouldAlwaysFloat():!1}_shouldForward(e){let t=this._control?this._control.ngControl:null;return t&&t[e]}_getSubscriptMessageType(){return this._errorChildren&&this._errorChildren.length>0&&this._control.errorState?"error":"hint"}_handleLabelResized(){this._refreshOutlineNotchWidth()}_refreshOutlineNotchWidth(){!this._hasOutline()||!this._floatingLabel||!this._shouldLabelFloat()?this._notchedOutline?._setNotchWidth(0):this._notchedOutline?._setNotchWidth(this._floatingLabel.getWidth())}_processHints(){this._validateHints(),this._syncDescribedByIds()}_validateHints(){this._hintChildren}_syncDescribedByIds(){if(this._control){let e=[];if(this._control.userAriaDescribedBy&&typeof this._control.userAriaDescribedBy=="string"&&e.push(...this._control.userAriaDescribedBy.split(" ")),this._getSubscriptMessageType()==="hint"){let a=this._hintChildren?this._hintChildren.find(u=>u.align==="start"):null,r=this._hintChildren?this._hintChildren.find(u=>u.align==="end"):null;a?e.push(a.id):this._hintLabel&&e.push(this._hintLabelId),r&&e.push(r.id)}else this._errorChildren&&e.push(...this._errorChildren.map(a=>a.id));let t=this._control.describedByIds,n;if(t){let a=this._describedByIds||e;n=e.concat(t.filter(r=>r&&!a.includes(r)))}else n=e;this._control.setDescribedByIds(n),this._describedByIds=e}}_getOutlinedLabelOffset(){if(!this._hasOutline()||!this._floatingLabel)return null;if(!this._iconPrefixContainer&&!this._textPrefixContainer)return["",null];if(!this._isAttachedToDom())return null;let e=this._iconPrefixContainer?.nativeElement,t=this._textPrefixContainer?.nativeElement,n=this._iconSuffixContainer?.nativeElement,a=this._textSuffixContainer?.nativeElement,r=e?.getBoundingClientRect().width??0,u=t?.getBoundingClientRect().width??0,h=n?.getBoundingClientRect().width??0,g=a?.getBoundingClientRect().width??0,_=this._currentDirection==="rtl"?"-1":"1",w=`${r+u}px`,G=`calc(${_} * (${w} + var(--mat-mdc-form-field-label-offset-x, 0px)))`,ie=`var(--mat-mdc-form-field-label-transform, ${j_} translateX(${G}))`,fe=r+u+h+g;return[ie,fe]}_writeOutlinedLabelStyles(e){if(e!==null){let[t,n]=e;this._floatingLabel&&(this._floatingLabel.element.style.transform=t),n!==null&&this._notchedOutline?._setMaxWidth(n)}}_isAttachedToDom(){let e=this._elementRef.nativeElement;if(e.getRootNode){let t=e.getRootNode();return t&&t!==e}return document.documentElement.contains(e)}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-form-field"]],contentQueries:function(t,n,a){if(t&1&&(md(a,n._labelChild,Ot,5),at(a,ya,5)(a,N_,5)(a,L_,5)(a,$u,5)(a,Zr,5)),t&2){Ks();let r;O(r=P())&&(n._formFieldControl=r.first),O(r=P())&&(n._prefixChildren=r),O(r=P())&&(n._suffixChildren=r),O(r=P())&&(n._errorChildren=r),O(r=P())&&(n._hintChildren=r)}},viewQuery:function(t,n){if(t&1&&(ud(n._iconPrefixContainerSignal,Fu,5)(n._textPrefixContainerSignal,Nu,5)(n._iconSuffixContainerSignal,Lu,5)(n._textSuffixContainerSignal,Vu,5),Me(g_,5)(Fu,5)(Nu,5)(Lu,5)(Vu,5)(Bu,5)(Hu,5)(ju,5)),t&2){Ks(4);let a;O(a=P())&&(n._textField=a.first),O(a=P())&&(n._iconPrefixContainer=a.first),O(a=P())&&(n._textPrefixContainer=a.first),O(a=P())&&(n._iconSuffixContainer=a.first),O(a=P())&&(n._textSuffixContainer=a.first),O(a=P())&&(n._floatingLabel=a.first),O(a=P())&&(n._notchedOutline=a.first),O(a=P())&&(n._lineRipple=a.first)}},hostAttrs:[1,"mat-mdc-form-field"],hostVars:38,hostBindings:function(t,n){t&2&&p("mat-mdc-form-field-label-always-float",n._shouldAlwaysFloat())("mat-mdc-form-field-has-icon-prefix",n._hasIconPrefix)("mat-mdc-form-field-has-icon-suffix",n._hasIconSuffix)("mat-form-field-invalid",n._control.errorState)("mat-form-field-disabled",n._control.disabled)("mat-form-field-autofilled",n._control.autofilled)("mat-form-field-appearance-fill",n.appearance=="fill")("mat-form-field-appearance-outline",n.appearance=="outline")("mat-form-field-hide-placeholder",n._hasFloatingLabel()&&!n._shouldLabelFloat())("mat-primary",n.color!=="accent"&&n.color!=="warn")("mat-accent",n.color==="accent")("mat-warn",n.color==="warn")("ng-untouched",n._shouldForward("untouched"))("ng-touched",n._shouldForward("touched"))("ng-pristine",n._shouldForward("pristine"))("ng-dirty",n._shouldForward("dirty"))("ng-valid",n._shouldForward("valid"))("ng-invalid",n._shouldForward("invalid"))("ng-pending",n._shouldForward("pending"))},inputs:{hideRequiredMarker:"hideRequiredMarker",color:"color",floatLabel:"floatLabel",appearance:"appearance",subscriptSizing:"subscriptSizing",hintLabel:"hintLabel"},exportAs:["matFormField"],features:[J([{provide:Bn,useExisting:i},{provide:Wu,useExisting:i}])],ngContentSelectors:v_,decls:18,vars:21,consts:[["labelTemplate",""],["textField",""],["iconPrefixContainer",""],["textPrefixContainer",""],["textSuffixContainer",""],["iconSuffixContainer",""],[1,"mat-mdc-text-field-wrapper","mdc-text-field",3,"click"],[1,"mat-mdc-form-field-focus-overlay"],[1,"mat-mdc-form-field-flex"],["matFormFieldNotchedOutline","",3,"matFormFieldNotchedOutlineOpen"],[1,"mat-mdc-form-field-icon-prefix"],[1,"mat-mdc-form-field-text-prefix"],[1,"mat-mdc-form-field-infix"],[3,"ngTemplateOutlet"],[1,"mat-mdc-form-field-text-suffix"],[1,"mat-mdc-form-field-icon-suffix"],["matFormFieldLineRipple",""],["aria-atomic","true","aria-live","polite",1,"mat-mdc-form-field-subscript-wrapper","mat-mdc-form-field-bottom-align"],[1,"mat-mdc-form-field-error-wrapper"],[1,"mat-mdc-form-field-hint-wrapper"],["matFormFieldFloatingLabel","",3,"floating","monitorResize","id"],["aria-hidden","true",1,"mat-mdc-form-field-required-marker","mdc-floating-label--required"],[3,"id"],[1,"mat-mdc-form-field-hint-spacer"]],template:function(t,n){if(t&1&&(ce(__),ze(0,C_,1,1,"ng-template",null,0,Ys),s(2,"div",6,1),A("click",function(r){return n._control.onContainerClick(r)}),M(4,x_,1,0,"div",7),s(5,"div",8),M(6,k_,2,2,"div",9),M(7,S_,3,0,"div",10),M(8,M_,3,0,"div",11),s(9,"div",12),M(10,A_,1,1,null,13),U(11),l(),M(12,T_,3,0,"div",14),M(13,I_,3,0,"div",15),l(),M(14,R_,1,0,"div",16),l(),s(15,"div",17),M(16,O_,2,0,"div",18)(17,F_,5,1,"div",19),l()),t&2){let a;c(2),p("mdc-text-field--filled",!n._hasOutline())("mdc-text-field--outlined",n._hasOutline())("mdc-text-field--no-label",!n._hasFloatingLabel())("mdc-text-field--disabled",n._control.disabled)("mdc-text-field--invalid",n._control.errorState),c(2),E(!n._hasOutline()&&!n._control.disabled?4:-1),c(2),E(n._hasOutline()?6:-1),c(),E(n._hasIconPrefix?7:-1),c(),E(n._hasTextPrefix?8:-1),c(2),E(!n._hasOutline()||n._forceDisplayInfixLabel()?10:-1),c(2),E(n._hasTextSuffix?12:-1),c(),E(n._hasIconSuffix?13:-1),c(),E(n._hasOutline()?-1:14),c(),p("mat-mdc-form-field-subscript-dynamic-size",n.subscriptSizing==="dynamic");let r=n._getSubscriptMessageType();c(),E((a=r)==="error"?16:a==="hint"?17:-1)}},dependencies:[Bu,Hu,rl,ju,Zr],styles:[`.mdc-text-field {
471
+ `],encapsulation:2})}return i})(),Nr;function bg(){if(Nr===void 0&&(Nr=null,typeof window<"u")){let i=window;i.trustedTypes!==void 0&&(Nr=i.trustedTypes.createPolicy("angular#components",{createHTML:o=>o}))}return Nr}function Ln(i){return bg()?.createHTML(i)||i}function Fm(i,o,e){let t=e.sanitize(Ct.HTML,o);i.innerHTML=Ln(t||"")}function yg(i){if(i.type==="characterData"&&i.target instanceof Comment)return!0;if(i.type==="childList"){for(let o=0;o<i.addedNodes.length;o++)if(!(i.addedNodes[o]instanceof Comment))return!1;for(let o=0;o<i.removedNodes.length;o++)if(!(i.removedNodes[o]instanceof Comment))return!1;return!0}return!1}var Nm=(()=>{class i{create(e){return typeof MutationObserver>"u"?null:new MutationObserver(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Lm=(()=>{class i{_mutationObserverFactory=d(Nm);_observedElements=new Map;_ngZone=d(H);ngOnDestroy(){this._observedElements.forEach((e,t)=>this._cleanupObserver(t))}observe(e){let t=Dt(e);return new yt(n=>{let r=this._observeElement(t).pipe(Pe(u=>u.filter(h=>!yg(h))),Ce(u=>!!u.length)).subscribe(u=>{this._ngZone.run(()=>{n.next(u)})});return()=>{r.unsubscribe(),this._unobserveElement(t)}})}_observeElement(e){return this._ngZone.runOutsideAngular(()=>{if(this._observedElements.has(e))this._observedElements.get(e).count++;else{let t=new I,n=this._mutationObserverFactory.create(a=>t.next(a));n&&n.observe(e,{characterData:!0,childList:!0,subtree:!0}),this._observedElements.set(e,{observer:n,stream:t,count:1})}return this._observedElements.get(e).stream})}_unobserveElement(e){this._observedElements.has(e)&&(this._observedElements.get(e).count--,this._observedElements.get(e).count||this._cleanupObserver(e))}_cleanupObserver(e){if(this._observedElements.has(e)){let{observer:t,stream:n}=this._observedElements.get(e);t&&t.disconnect(),n.complete(),this._observedElements.delete(e)}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Vm=(()=>{class i{_contentObserver=d(Lm);_elementRef=d(N);event=new K;get disabled(){return this._disabled}set disabled(e){this._disabled=e,this._disabled?this._unsubscribe():this._subscribe()}_disabled=!1;get debounce(){return this._debounce}set debounce(e){this._debounce=Ht(e),this._subscribe()}_debounce;_currentSubscription=null;ngAfterContentInit(){!this._currentSubscription&&!this.disabled&&this._subscribe()}ngOnDestroy(){this._unsubscribe()}_subscribe(){this._unsubscribe();let e=this._contentObserver.observe(this._elementRef);this._currentSubscription=(this.debounce?e.pipe(Vt(this.debounce)):e).subscribe(this.event)}_unsubscribe(){this._currentSubscription?.unsubscribe()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkObserveContent",""]],inputs:{disabled:[2,"cdkObserveContentDisabled","disabled",L],debounce:"debounce"},outputs:{event:"cdkObserveContent"},exportAs:["cdkObserveContent"]})}return i})(),fo=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({providers:[Nm]})}return i})();var Vl=(()=>{class i{_platform=d(le);isDisabled(e){return e.hasAttribute("disabled")}isVisible(e){return xg(e)&&getComputedStyle(e).visibility==="visible"}isTabbable(e){if(!this._platform.isBrowser)return!1;let t=Cg(Tg(e));if(t&&(Bm(t)===-1||!this.isVisible(t)))return!1;let n=e.nodeName.toLowerCase(),a=Bm(e);return e.hasAttribute("contenteditable")?a!==-1:n==="iframe"||n==="object"||this._platform.WEBKIT&&this._platform.IOS&&!Eg(e)?!1:n==="audio"?e.hasAttribute("controls")?a!==-1:!1:n==="video"?a===-1?!1:a!==null?!0:this._platform.FIREFOX||e.hasAttribute("controls"):e.tabIndex>=0}isFocusable(e,t){return Ag(e)&&!this.isDisabled(e)&&(t?.ignoreVisibility||this.isVisible(e))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function Cg(i){try{return i.frameElement}catch(o){return null}}function xg(i){return!!(i.offsetWidth||i.offsetHeight||typeof i.getClientRects=="function"&&i.getClientRects().length)}function wg(i){let o=i.nodeName.toLowerCase();return o==="input"||o==="select"||o==="button"||o==="textarea"}function Dg(i){return Sg(i)&&i.type=="hidden"}function kg(i){return Mg(i)&&i.hasAttribute("href")}function Sg(i){return i.nodeName.toLowerCase()=="input"}function Mg(i){return i.nodeName.toLowerCase()=="a"}function Hm(i){if(!i.hasAttribute("tabindex")||i.tabIndex===void 0)return!1;let o=i.getAttribute("tabindex");return!!(o&&!isNaN(parseInt(o,10)))}function Bm(i){if(!Hm(i))return null;let o=parseInt(i.getAttribute("tabindex")||"",10);return isNaN(o)?-1:o}function Eg(i){let o=i.nodeName.toLowerCase(),e=o==="input"&&i.type;return e==="text"||e==="password"||o==="select"||o==="textarea"}function Ag(i){return Dg(i)?!1:wg(i)||kg(i)||i.hasAttribute("contenteditable")||Hm(i)}function Tg(i){return i.ownerDocument&&i.ownerDocument.defaultView||window}var Ll=class{_element;_checker;_ngZone;_document;_injector;_startAnchor=null;_endAnchor=null;_hasAttached=!1;startAnchorListener=()=>this.focusLastTabbableElement();endAnchorListener=()=>this.focusFirstTabbableElement();get enabled(){return this._enabled}set enabled(o){this._enabled=o,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(o,this._startAnchor),this._toggleAnchorTabIndex(o,this._endAnchor))}_enabled=!0;constructor(o,e,t,n,a=!1,r){this._element=o,this._checker=e,this._ngZone=t,this._document=n,this._injector=r,a||this.attachAnchors()}destroy(){let o=this._startAnchor,e=this._endAnchor;o&&(o.removeEventListener("focus",this.startAnchorListener),o.remove()),e&&(e.removeEventListener("focus",this.endAnchorListener),e.remove()),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}attachAnchors(){return this._hasAttached?!0:(this._ngZone.runOutsideAngular(()=>{this._startAnchor||(this._startAnchor=this._createAnchor(),this._startAnchor.addEventListener("focus",this.startAnchorListener)),this._endAnchor||(this._endAnchor=this._createAnchor(),this._endAnchor.addEventListener("focus",this.endAnchorListener))}),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}focusInitialElementWhenReady(o){return new Promise(e=>{this._executeOnStable(()=>e(this.focusInitialElement(o)))})}focusFirstTabbableElementWhenReady(o){return new Promise(e=>{this._executeOnStable(()=>e(this.focusFirstTabbableElement(o)))})}focusLastTabbableElementWhenReady(o){return new Promise(e=>{this._executeOnStable(()=>e(this.focusLastTabbableElement(o)))})}_getRegionBoundary(o){let e=this._element.querySelectorAll(`[cdk-focus-region-${o}], [cdkFocusRegion${o}], [cdk-focus-${o}]`);return o=="start"?e.length?e[0]:this._getFirstTabbableElement(this._element):e.length?e[e.length-1]:this._getLastTabbableElement(this._element)}focusInitialElement(o){let e=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");if(e){if(!this._checker.isFocusable(e)){let t=this._getFirstTabbableElement(e);return t?.focus(o),!!t}return e.focus(o),!0}return this.focusFirstTabbableElement(o)}focusFirstTabbableElement(o){let e=this._getRegionBoundary("start");return e&&e.focus(o),!!e}focusLastTabbableElement(o){let e=this._getRegionBoundary("end");return e&&e.focus(o),!!e}hasAttached(){return this._hasAttached}_getFirstTabbableElement(o){if(this._checker.isFocusable(o)&&this._checker.isTabbable(o))return o;let e=o.children;for(let t=0;t<e.length;t++){let n=e[t].nodeType===this._document.ELEMENT_NODE?this._getFirstTabbableElement(e[t]):null;if(n)return n}return null}_getLastTabbableElement(o){if(this._checker.isFocusable(o)&&this._checker.isTabbable(o))return o;let e=o.children;for(let t=e.length-1;t>=0;t--){let n=e[t].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(e[t]):null;if(n)return n}return null}_createAnchor(){let o=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,o),o.classList.add("cdk-visually-hidden"),o.classList.add("cdk-focus-trap-anchor"),o.setAttribute("aria-hidden","true"),o}_toggleAnchorTabIndex(o,e){o?e.setAttribute("tabindex","0"):e.removeAttribute("tabindex")}toggleAnchors(o){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(o,this._startAnchor),this._toggleAnchorTabIndex(o,this._endAnchor))}_executeOnStable(o){Be(o,{injector:this._injector})}},Bl=(()=>{class i{_checker=d(Vl);_ngZone=d(H);_document=d(W);_injector=d(X);constructor(){d(Ne).load(rn)}create(e,t=!1){return new Ll(e,this._checker,this._ngZone,this._document,t,this._injector)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Um=new x("liveAnnouncerElement",{providedIn:"root",factory:()=>null}),Gm=new x("LIVE_ANNOUNCER_DEFAULT_OPTIONS"),Ig=0,la=(()=>{class i{_ngZone=d(H);_defaultOptions=d(Gm,{optional:!0});_liveElement;_document=d(W);_sanitizer=d(aa);_previousTimeout;_currentPromise;_currentResolve;constructor(){let e=d(Um,{optional:!0});this._liveElement=e||this._createLiveElement()}announce(e,...t){let n=this._defaultOptions,a,r;return t.length===1&&typeof t[0]=="number"?r=t[0]:[a,r]=t,this.clear(),clearTimeout(this._previousTimeout),a||(a=n&&n.politeness?n.politeness:"polite"),r==null&&n&&(r=n.duration),this._liveElement.setAttribute("aria-live",a),this._liveElement.id&&this._exposeAnnouncerToModals(this._liveElement.id),this._ngZone.runOutsideAngular(()=>(this._currentPromise||(this._currentPromise=new Promise(u=>this._currentResolve=u)),clearTimeout(this._previousTimeout),this._previousTimeout=setTimeout(()=>{!e||typeof e=="string"?this._liveElement.textContent=e:Fm(this._liveElement,e,this._sanitizer),typeof r=="number"&&(this._previousTimeout=setTimeout(()=>this.clear(),r)),this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0},100),this._currentPromise))}clear(){this._liveElement&&(this._liveElement.textContent="")}ngOnDestroy(){clearTimeout(this._previousTimeout),this._liveElement?.remove(),this._liveElement=null,this._currentResolve?.(),this._currentPromise=this._currentResolve=void 0}_createLiveElement(){let e="cdk-live-announcer-element",t=this._document.getElementsByClassName(e),n=this._document.createElement("div");for(let a=0;a<t.length;a++)t[a].remove();return n.classList.add(e),n.classList.add("cdk-visually-hidden"),n.setAttribute("aria-atomic","true"),n.setAttribute("aria-live","polite"),n.id=`cdk-live-announcer-${Ig++}`,this._document.body.appendChild(n),n}_exposeAnnouncerToModals(e){let t=this._document.querySelectorAll('body > .cdk-overlay-container [aria-modal="true"]');for(let n=0;n<t.length;n++){let a=t[n],r=a.getAttribute("aria-owns");r?r.indexOf(e)===-1&&a.setAttribute("aria-owns",r+" "+e):a.setAttribute("aria-owns",e)}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var sn=(function(i){return i[i.NONE=0]="NONE",i[i.BLACK_ON_WHITE=1]="BLACK_ON_WHITE",i[i.WHITE_ON_BLACK=2]="WHITE_ON_BLACK",i})(sn||{}),zm="cdk-high-contrast-black-on-white",jm="cdk-high-contrast-white-on-black",Nl="cdk-high-contrast-active",$m=(()=>{class i{_platform=d(le);_hasCheckedHighContrastMode=!1;_document=d(W);_breakpointSubscription;constructor(){this._breakpointSubscription=d(On).observe("(forced-colors: active)").subscribe(()=>{this._hasCheckedHighContrastMode&&(this._hasCheckedHighContrastMode=!1,this._applyBodyHighContrastModeCssClasses())})}getHighContrastMode(){if(!this._platform.isBrowser)return sn.NONE;let e=this._document.createElement("div");e.style.backgroundColor="rgb(1,2,3)",e.style.position="absolute",this._document.body.appendChild(e);let t=this._document.defaultView||window,n=t&&t.getComputedStyle?t.getComputedStyle(e):null,a=(n&&n.backgroundColor||"").replace(/ /g,"");switch(e.remove(),a){case"rgb(0,0,0)":case"rgb(45,50,54)":case"rgb(32,32,32)":return sn.WHITE_ON_BLACK;case"rgb(255,255,255)":case"rgb(255,250,239)":return sn.BLACK_ON_WHITE}return sn.NONE}ngOnDestroy(){this._breakpointSubscription.unsubscribe()}_applyBodyHighContrastModeCssClasses(){if(!this._hasCheckedHighContrastMode&&this._platform.isBrowser&&this._document.body){let e=this._document.body.classList;e.remove(Nl,zm,jm),this._hasCheckedHighContrastMode=!0;let t=this.getHighContrastMode();t===sn.BLACK_ON_WHITE?e.add(Nl,zm):t===sn.WHITE_ON_BLACK&&e.add(Nl,jm)}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),ca=(()=>{class i{constructor(){d($m)._applyBodyHighContrastModeCssClasses()}static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[fo]})}return i})();var Rg=200,Lr=class{_letterKeyStream=new I;_items=[];_selectedItemIndex=-1;_pressedLetters=[];_skipPredicateFn;_selectedItem=new I;selectedItem=this._selectedItem;constructor(o,e){let t=typeof e?.debounceInterval=="number"?e.debounceInterval:Rg;e?.skipPredicate&&(this._skipPredicateFn=e.skipPredicate),this.setItems(o),this._setupKeyHandler(t)}destroy(){this._pressedLetters=[],this._letterKeyStream.complete(),this._selectedItem.complete()}setCurrentSelectedItemIndex(o){this._selectedItemIndex=o}setItems(o){this._items=o}handleKey(o){let e=o.keyCode;o.key&&o.key.length===1?this._letterKeyStream.next(o.key.toLocaleUpperCase()):(e>=65&&e<=90||e>=48&&e<=57)&&this._letterKeyStream.next(String.fromCharCode(e))}isTyping(){return this._pressedLetters.length>0}reset(){this._pressedLetters=[]}_setupKeyHandler(o){this._letterKeyStream.pipe(di(e=>this._pressedLetters.push(e)),Vt(o),Ce(()=>this._pressedLetters.length>0),Pe(()=>this._pressedLetters.join("").toLocaleUpperCase())).subscribe(e=>{for(let t=1;t<this._items.length+1;t++){let n=(this._selectedItemIndex+t)%this._items.length,a=this._items[n];if(!this._skipPredicateFn?.(a)&&a.getLabel?.().toLocaleUpperCase().trim().indexOf(e)===0){this._selectedItem.next(a);break}}this._pressedLetters=[]})}};function Ge(i,...o){return o.length?o.some(e=>i[e]):i.altKey||i.shiftKey||i.ctrlKey||i.metaKey}var go=class{_items;_activeItemIndex=R(-1);_activeItem=R(null);_wrap=!1;_typeaheadSubscription=De.EMPTY;_itemChangesSubscription;_vertical=!0;_horizontal=null;_allowedModifierKeys=[];_homeAndEnd=!1;_pageUpAndDown={enabled:!1,delta:10};_effectRef;_typeahead;_skipPredicateFn=o=>o.disabled;constructor(o,e){this._items=o,o instanceof Zi?this._itemChangesSubscription=o.changes.subscribe(t=>this._itemsChanged(t.toArray())):Xi(o)&&(this._effectRef=zt(()=>this._itemsChanged(o()),{injector:e}))}tabOut=new I;change=new I;skipPredicate(o){return this._skipPredicateFn=o,this}withWrap(o=!0){return this._wrap=o,this}withVerticalOrientation(o=!0){return this._vertical=o,this}withHorizontalOrientation(o){return this._horizontal=o,this}withAllowedModifierKeys(o){return this._allowedModifierKeys=o,this}withTypeAhead(o=200){this._typeaheadSubscription.unsubscribe();let e=this._getItemsArray();return this._typeahead=new Lr(e,{debounceInterval:typeof o=="number"?o:void 0,skipPredicate:t=>this._skipPredicateFn(t)}),this._typeaheadSubscription=this._typeahead.selectedItem.subscribe(t=>{this.setActiveItem(t)}),this}cancelTypeahead(){return this._typeahead?.reset(),this}withHomeAndEnd(o=!0){return this._homeAndEnd=o,this}withPageUpDown(o=!0,e=10){return this._pageUpAndDown={enabled:o,delta:e},this}setActiveItem(o){let e=this._activeItem();this.updateActiveItem(o),this._activeItem()!==e&&this.change.next(this._activeItemIndex())}onKeydown(o){let e=o.keyCode,n=["altKey","ctrlKey","metaKey","shiftKey"].every(a=>!o[a]||this._allowedModifierKeys.indexOf(a)>-1);switch(e){case 9:this.tabOut.next();return;case 40:if(this._vertical&&n){this.setNextItemActive();break}else return;case 38:if(this._vertical&&n){this.setPreviousItemActive();break}else return;case 39:if(this._horizontal&&n){this._horizontal==="rtl"?this.setPreviousItemActive():this.setNextItemActive();break}else return;case 37:if(this._horizontal&&n){this._horizontal==="rtl"?this.setNextItemActive():this.setPreviousItemActive();break}else return;case 36:if(this._homeAndEnd&&n){this.setFirstItemActive();break}else return;case 35:if(this._homeAndEnd&&n){this.setLastItemActive();break}else return;case 33:if(this._pageUpAndDown.enabled&&n){let a=this._activeItemIndex()-this._pageUpAndDown.delta;this._setActiveItemByIndex(a>0?a:0,1);break}else return;case 34:if(this._pageUpAndDown.enabled&&n){let a=this._activeItemIndex()+this._pageUpAndDown.delta,r=this._getItemsArray().length;this._setActiveItemByIndex(a<r?a:r-1,-1);break}else return;default:(n||Ge(o,"shiftKey"))&&this._typeahead?.handleKey(o);return}this._typeahead?.reset(),o.preventDefault()}get activeItemIndex(){return this._activeItemIndex()}get activeItem(){return this._activeItem()}isTyping(){return!!this._typeahead&&this._typeahead.isTyping()}setFirstItemActive(){this._setActiveItemByIndex(0,1)}setLastItemActive(){this._setActiveItemByIndex(this._getItemsArray().length-1,-1)}setNextItemActive(){this._activeItemIndex()<0?this.setFirstItemActive():this._setActiveItemByDelta(1)}setPreviousItemActive(){this._activeItemIndex()<0&&this._wrap?this.setLastItemActive():this._setActiveItemByDelta(-1)}updateActiveItem(o){let e=this._getItemsArray(),t=typeof o=="number"?o:e.indexOf(o),n=e[t];this._activeItem.set(n??null),this._activeItemIndex.set(t),this._typeahead?.setCurrentSelectedItemIndex(t)}destroy(){this._typeaheadSubscription.unsubscribe(),this._itemChangesSubscription?.unsubscribe(),this._effectRef?.destroy(),this._typeahead?.destroy(),this.tabOut.complete(),this.change.complete()}_setActiveItemByDelta(o){this._wrap?this._setActiveInWrapMode(o):this._setActiveInDefaultMode(o)}_setActiveInWrapMode(o){let e=this._getItemsArray();for(let t=1;t<=e.length;t++){let n=(this._activeItemIndex()+o*t+e.length)%e.length,a=e[n];if(!this._skipPredicateFn(a)){this.setActiveItem(n);return}}}_setActiveInDefaultMode(o){this._setActiveItemByIndex(this._activeItemIndex()+o,o)}_setActiveItemByIndex(o,e){let t=this._getItemsArray();if(t[o]){for(;this._skipPredicateFn(t[o]);)if(o+=e,!t[o])return;this.setActiveItem(o)}}_getItemsArray(){return Xi(this._items)?this._items():this._items instanceof Zi?this._items.toArray():this._items}_itemsChanged(o){this._typeahead?.setItems(o);let e=this._activeItem();if(e){let t=o.indexOf(e);t>-1&&t!==this._activeItemIndex()&&(this._activeItemIndex.set(t),this._typeahead?.setCurrentSelectedItemIndex(t))}}};var Bn=class extends go{setActiveItem(o){this.activeItem&&this.activeItem.setInactiveStyles(),super.setActiveItem(o),this.activeItem&&this.activeItem.setActiveStyles()}};var cn=class extends go{_origin="program";setFocusOrigin(o){return this._origin=o,this}setActiveItem(o){super.setActiveItem(o),this.activeItem&&this.activeItem.focus(this._origin)}};var Km=new Map,be=class i{_appId=d(En);static _infix=`a${Math.floor(Math.random()*1e5).toString()}`;getId(o,e=!1){this._appId!=="ng"&&(o+=this._appId);let t=Km.get(o);return t===void 0?t=0:t++,Km.set(o,t),`${o}${e?i._infix+"-":""}${t}`}static \u0275fac=function(e){return new(e||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})};var Xm=" ";function Og(i,o,e){let t=Br(i,o);e=e.trim(),!t.some(n=>n.trim()===e)&&(t.push(e),i.setAttribute(o,t.join(Xm)))}function Pg(i,o,e){let t=Br(i,o);e=e.trim();let n=t.filter(a=>a!==e);n.length?i.setAttribute(o,n.join(Xm)):i.removeAttribute(o)}function Br(i,o){return i.getAttribute(o)?.match(/\S+/g)??[]}var Zm="cdk-describedby-message",Vr="cdk-describedby-host",jl=0,Qm=(()=>{class i{_platform=d(le);_document=d(W);_messageRegistry=new Map;_messagesContainer=null;_id=`${jl++}`;constructor(){d(Ne).load(rn),this._id=d(En)+"-"+jl++}describe(e,t,n){if(!this._canBeDescribed(e,t))return;let a=zl(t,n);typeof t!="string"?(Ym(t,this._id),this._messageRegistry.set(a,{messageElement:t,referenceCount:0})):this._messageRegistry.has(a)||this._createMessageElement(t,n),this._isElementDescribedByMessage(e,a)||this._addMessageReference(e,a)}removeDescription(e,t,n){if(!t||!this._isElementNode(e))return;let a=zl(t,n);if(this._isElementDescribedByMessage(e,a)&&this._removeMessageReference(e,a),typeof t=="string"){let r=this._messageRegistry.get(a);r&&r.referenceCount===0&&this._deleteMessageElement(a)}this._messagesContainer?.childNodes.length===0&&(this._messagesContainer.remove(),this._messagesContainer=null)}ngOnDestroy(){let e=this._document.querySelectorAll(`[${Vr}="${this._id}"]`);for(let t=0;t<e.length;t++)this._removeCdkDescribedByReferenceIds(e[t]),e[t].removeAttribute(Vr);this._messagesContainer?.remove(),this._messagesContainer=null,this._messageRegistry.clear()}_createMessageElement(e,t){let n=this._document.createElement("div");Ym(n,this._id),n.textContent=e,t&&n.setAttribute("role",t),this._createMessagesContainer(),this._messagesContainer.appendChild(n),this._messageRegistry.set(zl(e,t),{messageElement:n,referenceCount:0})}_deleteMessageElement(e){this._messageRegistry.get(e)?.messageElement?.remove(),this._messageRegistry.delete(e)}_createMessagesContainer(){if(this._messagesContainer)return;let e="cdk-describedby-message-container",t=this._document.querySelectorAll(`.${e}[platform="server"]`);for(let a=0;a<t.length;a++)t[a].remove();let n=this._document.createElement("div");n.style.visibility="hidden",n.classList.add(e),n.classList.add("cdk-visually-hidden"),this._platform.isBrowser||n.setAttribute("platform","server"),this._document.body.appendChild(n),this._messagesContainer=n}_removeCdkDescribedByReferenceIds(e){let t=Br(e,"aria-describedby").filter(n=>n.indexOf(Zm)!=0);e.setAttribute("aria-describedby",t.join(" "))}_addMessageReference(e,t){let n=this._messageRegistry.get(t);Og(e,"aria-describedby",n.messageElement.id),e.setAttribute(Vr,this._id),n.referenceCount++}_removeMessageReference(e,t){let n=this._messageRegistry.get(t);n.referenceCount--,Pg(e,"aria-describedby",n.messageElement.id),e.removeAttribute(Vr)}_isElementDescribedByMessage(e,t){let n=Br(e,"aria-describedby"),a=this._messageRegistry.get(t),r=a&&a.messageElement.id;return!!r&&n.indexOf(r)!=-1}_canBeDescribed(e,t){if(!this._isElementNode(e))return!1;if(t&&typeof t=="object")return!0;let n=t==null?"":`${t}`.trim(),a=e.getAttribute("aria-label");return n?!a||a.trim()!==n:!1}_isElementNode(e){return e.nodeType===this._document.ELEMENT_NODE}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function zl(i,o){return typeof i=="string"?`${o||""}/${i}`:i}function Ym(i,o){i.id||(i.id=`${Zm}-${o}-${jl++}`)}var su=(()=>{class i{_renderer;_elementRef;onChange=e=>{};onTouched=()=>{};constructor(e,t){this._renderer=e,this._elementRef=t}setProperty(e,t){this._renderer.setProperty(this._elementRef.nativeElement,e,t)}registerOnTouched(e){this.onTouched=e}registerOnChange(e){this.onChange=e}setDisabledState(e){this.setProperty("disabled",e)}static \u0275fac=function(t){return new(t||i)(de(ve),de(N))};static \u0275dir=k({type:i})}return i})(),lu=(()=>{class i extends su{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,features:[Q]})}return i})(),Mi=new x("");var Fg={provide:Mi,useExisting:nt(()=>Ei),multi:!0};function Ng(){let i=Xt()?Xt().getUserAgent():"";return/android (\d+)/.test(i.toLowerCase())}var Lg=new x(""),Ei=(()=>{class i extends su{_compositionMode;_composing=!1;constructor(e,t,n){super(e,t),this._compositionMode=n,this._compositionMode==null&&(this._compositionMode=!Ng())}writeValue(e){let t=e??"";this.setProperty("value",t)}_handleInput(e){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(e)}_compositionStart(){this._composing=!0}_compositionEnd(e){this._composing=!1,this._compositionMode&&this.onChange(e)}static \u0275fac=function(t){return new(t||i)(de(ve),de(N),de(Lg,8))};static \u0275dir=k({type:i,selectors:[["input","formControlName","",3,"type","checkbox",3,"ngNoCva",""],["textarea","formControlName","",3,"ngNoCva",""],["input","formControl","",3,"type","checkbox",3,"ngNoCva",""],["textarea","formControl","",3,"ngNoCva",""],["input","ngModel","",3,"type","checkbox",3,"ngNoCva",""],["textarea","ngModel","",3,"ngNoCva",""],["","ngDefaultControl",""]],hostBindings:function(t,n){t&1&&A("input",function(r){return n._handleInput(r.target.value)})("blur",function(){return n.onTouched()})("compositionstart",function(){return n._compositionStart()})("compositionend",function(r){return n._compositionEnd(r.target.value)})},standalone:!1,features:[J([Fg]),Q]})}return i})();function ql(i){return i==null||Kl(i)===0}function Kl(i){return i==null?null:Array.isArray(i)||typeof i=="string"?i.length:i instanceof Set?i.size:null}var zi=new x(""),Yr=new x(""),Vg=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,st=class{static min(o){return cu(o)}static max(o){return du(o)}static required(o){return mu(o)}static requiredTrue(o){return Bg(o)}static email(o){return zg(o)}static minLength(o){return jg(o)}static maxLength(o){return Hg(o)}static pattern(o){return Ug(o)}static nullValidator(o){return jr()}static compose(o){return _u(o)}static composeAsync(o){return vu(o)}};function cu(i){return o=>{if(o.value==null||i==null)return null;let e=parseFloat(o.value);return!isNaN(e)&&e<i?{min:{min:i,actual:o.value}}:null}}function du(i){return o=>{if(o.value==null||i==null)return null;let e=parseFloat(o.value);return!isNaN(e)&&e>i?{max:{max:i,actual:o.value}}:null}}function mu(i){return ql(i.value)?{required:!0}:null}function Bg(i){return i.value===!0?null:{required:!0}}function zg(i){return ql(i.value)||Vg.test(i.value)?null:{email:!0}}function jg(i){return o=>{let e=o.value?.length??Kl(o.value);return e===null||e===0?null:e<i?{minlength:{requiredLength:i,actualLength:e}}:null}}function Hg(i){return o=>{let e=o.value?.length??Kl(o.value);return e!==null&&e>i?{maxlength:{requiredLength:i,actualLength:e}}:null}}function Ug(i){if(!i)return jr;let o,e;return typeof i=="string"?(e="",i.charAt(0)!=="^"&&(e+="^"),e+=i,i.charAt(i.length-1)!=="$"&&(e+="$"),o=new RegExp(e)):(e=i.toString(),o=i),t=>{if(ql(t.value))return null;let n=t.value;return o.test(n)?null:{pattern:{requiredPattern:e,actualValue:n}}}}function jr(i){return null}function uu(i){return i!=null}function hu(i){return Ws(i)?$c(i):i}function pu(i){let o={};return i.forEach(e=>{o=e!=null?V(V({},o),e):o}),Object.keys(o).length===0?null:o}function fu(i,o){return o.map(e=>e(i))}function Gg(i){return!i.validate}function gu(i){return i.map(o=>Gg(o)?o:e=>o.validate(e))}function _u(i){if(!i)return null;let o=i.filter(uu);return o.length==0?null:function(e){return pu(fu(e,o))}}function Yl(i){return i!=null?_u(gu(i)):null}function vu(i){if(!i)return null;let o=i.filter(uu);return o.length==0?null:function(e){let t=fu(e,o).map(hu);return Ka(t).pipe(Pe(pu))}}function Xl(i){return i!=null?vu(gu(i)):null}function Jm(i,o){return i===null?[o]:Array.isArray(i)?[...i,o]:[i,o]}function bu(i){return i._rawValidators}function yu(i){return i._rawAsyncValidators}function Hl(i){return i?Array.isArray(i)?i:[i]:[]}function Hr(i,o){return Array.isArray(i)?i.includes(o):i===o}function eu(i,o){let e=Hl(o);return Hl(i).forEach(n=>{Hr(e,n)||e.push(n)}),e}function tu(i,o){return Hl(o).filter(e=>!Hr(i,e))}var Ur=class{get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators=[];_rawAsyncValidators=[];_setValidators(o){this._rawValidators=o||[],this._composedValidatorFn=Yl(this._rawValidators)}_setAsyncValidators(o){this._rawAsyncValidators=o||[],this._composedAsyncValidatorFn=Xl(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_onDestroyCallbacks=[];_registerOnDestroy(o){this._onDestroyCallbacks.push(o)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(o=>o()),this._onDestroyCallbacks=[]}reset(o=void 0){this.control?.reset(o)}hasError(o,e){return this.control?this.control.hasError(o,e):!1}getError(o,e){return this.control?this.control.getError(o,e):null}},Bi=class extends Ur{name;get formDirective(){return null}get path(){return null}};var ua="VALID",zr="INVALID",_o="PENDING",ha="DISABLED",dn=class{},Gr=class extends dn{value;source;constructor(o,e){super(),this.value=o,this.source=e}},fa=class extends dn{pristine;source;constructor(o,e){super(),this.pristine=o,this.source=e}},ga=class extends dn{touched;source;constructor(o,e){super(),this.touched=o,this.source=e}},vo=class extends dn{status;source;constructor(o,e){super(),this.status=o,this.source=e}},$r=class extends dn{source;constructor(o){super(),this.source=o}},zn=class extends dn{source;constructor(o){super(),this.source=o}};function Zl(i){return(Xr(i)?i.validators:i)||null}function $g(i){return Array.isArray(i)?Yl(i):i||null}function Ql(i,o){return(Xr(o)?o.asyncValidators:i)||null}function Wg(i){return Array.isArray(i)?Xl(i):i||null}function Xr(i){return i!=null&&!Array.isArray(i)&&typeof i=="object"}function Cu(i,o,e){let t=i.controls;if(!(o?Object.keys(t):t).length)throw new ae(1e3,"");if(!wu(t,e))throw new ae(1001,"")}function xu(i,o,e){i._forEachChild((t,n)=>{if(e[n]===void 0)throw new ae(-1002,"")})}var bo=class{_pendingDirty=!1;_hasOwnPendingAsyncValidator=null;_pendingTouched=!1;_onCollectionChange=()=>{};_updateOn;_hasRequired=R(!1);_parent=null;_asyncValidationSubscription;_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators;_rawAsyncValidators;value;constructor(o,e){this._assignValidators(o),this._assignAsyncValidators(e)}get validator(){return this._composedValidatorFn}set validator(o){this._rawValidators=this._composedValidatorFn=o,this._updateHasRequiredValidator()}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(o){this._rawAsyncValidators=this._composedAsyncValidatorFn=o}get parent(){return this._parent}get status(){return pt(this.statusReactive)}set status(o){pt(()=>this.statusReactive.set(o))}_status=$(()=>this.statusReactive());statusReactive=R(void 0);get valid(){return this.status===ua}get invalid(){return this.status===zr}get pending(){return this.status===_o}get disabled(){return this.status===ha}get enabled(){return this.status!==ha}errors;get pristine(){return pt(this.pristineReactive)}set pristine(o){pt(()=>this.pristineReactive.set(o))}_pristine=$(()=>this.pristineReactive());pristineReactive=R(!0);get dirty(){return!this.pristine}get touched(){return pt(this.touchedReactive)}set touched(o){pt(()=>this.touchedReactive.set(o))}_touched=$(()=>this.touchedReactive());touchedReactive=R(!1);get untouched(){return!this.touched}_events=new I;events=this._events.asObservable();valueChanges;statusChanges;get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(o){this._assignValidators(o)}setAsyncValidators(o){this._assignAsyncValidators(o)}addValidators(o){this.setValidators(eu(o,this._rawValidators))}addAsyncValidators(o){this.setAsyncValidators(eu(o,this._rawAsyncValidators))}removeValidators(o){this.setValidators(tu(o,this._rawValidators))}removeAsyncValidators(o){this.setAsyncValidators(tu(o,this._rawAsyncValidators))}hasValidator(o){return Hr(this._rawValidators,o)}hasAsyncValidator(o){return Hr(this._rawAsyncValidators,o)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(o={}){let e=this.touched===!1;this.touched=!0;let t=o.sourceControl??this;o.onlySelf||this._parent?.markAsTouched(Oe(V({},o),{sourceControl:t})),e&&o.emitEvent!==!1&&this._events.next(new ga(!0,t))}markAllAsDirty(o={}){this.markAsDirty({onlySelf:!0,emitEvent:o.emitEvent,sourceControl:this}),this._forEachChild(e=>e.markAllAsDirty(o))}markAllAsTouched(o={}){this.markAsTouched({onlySelf:!0,emitEvent:o.emitEvent,sourceControl:this}),this._forEachChild(e=>e.markAllAsTouched(o))}markAsUntouched(o={}){let e=this.touched===!0;this.touched=!1,this._pendingTouched=!1;let t=o.sourceControl??this;this._forEachChild(n=>{n.markAsUntouched({onlySelf:!0,emitEvent:o.emitEvent,sourceControl:t})}),o.onlySelf||this._parent?._updateTouched(o,t),e&&o.emitEvent!==!1&&this._events.next(new ga(!1,t))}markAsDirty(o={}){let e=this.pristine===!0;this.pristine=!1;let t=o.sourceControl??this;o.onlySelf||this._parent?.markAsDirty(Oe(V({},o),{sourceControl:t})),e&&o.emitEvent!==!1&&this._events.next(new fa(!1,t))}markAsPristine(o={}){let e=this.pristine===!1;this.pristine=!0,this._pendingDirty=!1;let t=o.sourceControl??this;this._forEachChild(n=>{n.markAsPristine({onlySelf:!0,emitEvent:o.emitEvent})}),o.onlySelf||this._parent?._updatePristine(o,t),e&&o.emitEvent!==!1&&this._events.next(new fa(!0,t))}markAsPending(o={}){this.status=_o;let e=o.sourceControl??this;o.emitEvent!==!1&&(this._events.next(new vo(this.status,e)),this.statusChanges.emit(this.status)),o.onlySelf||this._parent?.markAsPending(Oe(V({},o),{sourceControl:e}))}disable(o={}){let e=this._parentMarkedDirty(o.onlySelf);this.status=ha,this.errors=null,this._forEachChild(n=>{n.disable(Oe(V({},o),{onlySelf:!0}))}),this._updateValue();let t=o.sourceControl??this;o.emitEvent!==!1&&(this._events.next(new Gr(this.value,t)),this._events.next(new vo(this.status,t)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(Oe(V({},o),{skipPristineCheck:e}),this),this._onDisabledChange.forEach(n=>n(!0))}enable(o={}){let e=this._parentMarkedDirty(o.onlySelf);this.status=ua,this._forEachChild(t=>{t.enable(Oe(V({},o),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:o.emitEvent}),this._updateAncestors(Oe(V({},o),{skipPristineCheck:e}),this),this._onDisabledChange.forEach(t=>t(!1))}_updateAncestors(o,e){o.onlySelf||(this._parent?.updateValueAndValidity(o),o.skipPristineCheck||this._parent?._updatePristine({},e),this._parent?._updateTouched({},e))}setParent(o){this._parent=o}getRawValue(){return this.value}updateValueAndValidity(o={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){let t=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===ua||this.status===_o)&&this._runAsyncValidator(t,o.emitEvent)}let e=o.sourceControl??this;o.emitEvent!==!1&&(this._events.next(new Gr(this.value,e)),this._events.next(new vo(this.status,e)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),o.onlySelf||this._parent?.updateValueAndValidity(Oe(V({},o),{sourceControl:e}))}_updateTreeValidity(o={emitEvent:!0}){this._forEachChild(e=>e._updateTreeValidity(o)),this.updateValueAndValidity({onlySelf:!0,emitEvent:o.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?ha:ua}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(o,e){if(this.asyncValidator){this.status=_o,this._hasOwnPendingAsyncValidator={emitEvent:e!==!1,shouldHaveEmitted:o!==!1};let t=hu(this.asyncValidator(this));this._asyncValidationSubscription=t.subscribe(n=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(n,{emitEvent:e,shouldHaveEmitted:o})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();let o=(this._hasOwnPendingAsyncValidator?.emitEvent||this._hasOwnPendingAsyncValidator?.shouldHaveEmitted)??!1;return this._hasOwnPendingAsyncValidator=null,o}return!1}setErrors(o,e={}){this.errors=o,this._updateControlsErrors(e.emitEvent!==!1,this,e.shouldHaveEmitted)}get(o){let e=o;return e==null||(Array.isArray(e)||(e=e.split(".")),e.length===0)?null:e.reduce((t,n)=>t&&t._find(n),this)}getError(o,e){let t=e?this.get(e):this;return t?.errors?t.errors[o]:null}hasError(o,e){return!!this.getError(o,e)}get root(){let o=this;for(;o._parent;)o=o._parent;return o}_updateControlsErrors(o,e,t){this.status=this._calculateStatus(),o&&this.statusChanges.emit(this.status),(o||t)&&this._events.next(new vo(this.status,e)),this._parent&&this._parent._updateControlsErrors(o,e,t)}_initObservables(){this.valueChanges=new K,this.statusChanges=new K}_calculateStatus(){return this._allControlsDisabled()?ha:this.errors?zr:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(_o)?_o:this._anyControlsHaveStatus(zr)?zr:ua}_anyControlsHaveStatus(o){return this._anyControls(e=>e.status===o)}_anyControlsDirty(){return this._anyControls(o=>o.dirty)}_anyControlsTouched(){return this._anyControls(o=>o.touched)}_updatePristine(o,e){let t=!this._anyControlsDirty(),n=this.pristine!==t;this.pristine=t,o.onlySelf||this._parent?._updatePristine(o,e),n&&this._events.next(new fa(this.pristine,e))}_updateTouched(o={},e){this.touched=this._anyControlsTouched(),this._events.next(new ga(this.touched,e)),o.onlySelf||this._parent?._updateTouched(o,e)}_onDisabledChange=[];_registerOnCollectionChange(o){this._onCollectionChange=o}_setUpdateStrategy(o){Xr(o)&&o.updateOn!=null&&(this._updateOn=o.updateOn)}_parentMarkedDirty(o){return!o&&!!this._parent?.dirty&&!this._parent._anyControlsDirty()}_find(o){return null}_assignValidators(o){this._rawValidators=Array.isArray(o)?o.slice():o,this._composedValidatorFn=$g(this._rawValidators),this._updateHasRequiredValidator()}_assignAsyncValidators(o){this._rawAsyncValidators=Array.isArray(o)?o.slice():o,this._composedAsyncValidatorFn=Wg(this._rawAsyncValidators)}_updateHasRequiredValidator(){pt(()=>this._hasRequired.set(this.hasValidator(st.required)))}};function wu(i,o){return Object.hasOwn(i,o)}function qg(i){return i.tagName==="INPUT"||i.tagName==="SELECT"||i.tagName==="TEXTAREA"}function Kg(i,o,e,t){switch(e){case"name":i.setAttribute(o,e,t);break;case"disabled":case"readonly":case"required":t?i.setAttribute(o,e,""):i.removeAttribute(o,e);break;case"max":case"min":case"minLength":case"maxLength":t!==void 0?i.setAttribute(o,e,t.toString()):i.removeAttribute(o,e);break}}var Ul=class{kind;context;control;message;constructor({kind:o,context:e,control:t}){this.kind=o,this.context=e,this.control=t}};function Du(i){return typeof i=="number"?i:parseFloat(i)}var Jl=(()=>{class i{_validator=jr;_onChange;_enabled;ngOnChanges(e){if(this.inputName in e){let t=this.normalizeInput(e[this.inputName].currentValue);this._enabled=this.enabled(t),this._validator=this._enabled?this.createValidator(t):jr,this._onChange?.()}}validate(e){return this._validator(e)}registerOnValidatorChange(e){this._onChange=e}enabled(e){return e!=null}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,features:[Se]})}return i})(),Yg={provide:zi,useExisting:nt(()=>ec),multi:!0},ec=(()=>{class i extends Jl{max;inputName="max";normalizeInput=e=>Du(e);createValidator=e=>du(e);static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["input","type","number","max","","formControlName",""],["input","type","number","max","","formControl",""],["input","type","number","max","","ngModel",""]],hostVars:1,hostBindings:function(t,n){t&2&&Z("max",n._enabled?n.max:null)},inputs:{max:"max"},standalone:!1,features:[J([Yg]),Q]})}return i})(),Xg={provide:zi,useExisting:nt(()=>tc),multi:!0},tc=(()=>{class i extends Jl{min;inputName="min";normalizeInput=e=>Du(e);createValidator=e=>cu(e);static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["input","type","number","min","","formControlName",""],["input","type","number","min","","formControl",""],["input","type","number","min","","ngModel",""]],hostVars:1,hostBindings:function(t,n){t&2&&Z("min",n._enabled?n.min:null)},inputs:{min:"min"},standalone:!1,features:[J([Xg]),Q]})}return i})(),Zg={provide:zi,useExisting:nt(()=>Zr),multi:!0};var Zr=(()=>{class i extends Jl{required;inputName="required";normalizeInput=L;createValidator=e=>mu;enabled(e){return e}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","required","","formControlName","",3,"type","checkbox"],["","required","","formControl","",3,"type","checkbox"],["","required","","ngModel","",3,"type","checkbox"]],hostVars:1,hostBindings:function(t,n){t&2&&Z("required",n._enabled?"":null)},inputs:{required:"required"},standalone:!1,features:[J([Zg]),Q]})}return i})();var Qg=new x(""),va=new x("",{factory:()=>Qr}),Qr="always";function ku(i,o){return[...o.path,i]}function Gl(i,o,e=Qr){ic(i,o),o.valueAccessor.writeValue(i.value),(i.disabled||e==="always")&&o.valueAccessor.setDisabledState?.(i.disabled),e_(i,o),i_(i,o),t_(i,o),Jg(i,o)}function iu(i,o,e=!0){let t=()=>{};o?.valueAccessor?.registerOnChange(t),o?.valueAccessor?.registerOnTouched(t),qr(i,o),i&&(o._invokeOnDestroyCallbacks(),i._registerOnCollectionChange(()=>{}))}function Wr(i,o){i.forEach(e=>{e.registerOnValidatorChange&&e.registerOnValidatorChange(o)})}function Jg(i,o){if(o.valueAccessor.setDisabledState){let e=t=>{o.valueAccessor.setDisabledState(t)};i.registerOnDisabledChange(e),o._registerOnDestroy(()=>{i._unregisterOnDisabledChange(e)})}}function ic(i,o){let e=bu(i);o.validator!==null?i.setValidators(Jm(e,o.validator)):typeof e=="function"&&i.setValidators([e]);let t=yu(i);o.asyncValidator!==null?i.setAsyncValidators(Jm(t,o.asyncValidator)):typeof t=="function"&&i.setAsyncValidators([t]);let n=()=>i.updateValueAndValidity();Wr(o._rawValidators,n),Wr(o._rawAsyncValidators,n)}function qr(i,o){let e=!1;if(i!==null){if(o.validator!==null){let n=bu(i);if(Array.isArray(n)&&n.length>0){let a=n.filter(r=>r!==o.validator);a.length!==n.length&&(e=!0,i.setValidators(a))}}if(o.asyncValidator!==null){let n=yu(i);if(Array.isArray(n)&&n.length>0){let a=n.filter(r=>r!==o.asyncValidator);a.length!==n.length&&(e=!0,i.setAsyncValidators(a))}}}let t=()=>{};return Wr(o._rawValidators,t),Wr(o._rawAsyncValidators,t),e}function e_(i,o){o.valueAccessor.registerOnChange(e=>{i._pendingValue=e,i._pendingChange=!0,i._pendingDirty=!0,i.updateOn==="change"&&Su(i,o)})}function t_(i,o){o.valueAccessor.registerOnTouched(()=>{i._pendingTouched=!0,i.updateOn==="blur"&&i._pendingChange&&Su(i,o),i.updateOn!=="submit"&&i.markAsTouched()})}function Su(i,o){i._pendingDirty&&i.markAsDirty(),i.setValue(i._pendingValue,{emitModelToViewChange:!1}),o.viewToModelUpdate(i._pendingValue),i._pendingChange=!1}function i_(i,o){let e=(t,n)=>{o.valueAccessor.writeValue(t),n&&o.viewToModelUpdate(t)};i.registerOnChange(e),o._registerOnDestroy(()=>{i._unregisterOnChange(e)})}function Mu(i,o){i==null,ic(i,o)}function n_(i,o){return qr(i,o)}function Eu(i,o){if(!i.hasOwnProperty("model"))return!1;let e=i.model;return e.isFirstChange()?!0:!Object.is(o,e.currentValue)}function o_(i){return Object.getPrototypeOf(i.constructor)===lu}function Au(i,o){i._syncPendingControls(),o.forEach(e=>{let t=e.control;t.updateOn==="submit"&&t._pendingChange&&(e.viewToModelUpdate(t._pendingValue),t._pendingChange=!1)})}function a_(i,o){if(!o)return null;Array.isArray(o);let e,t,n;return o.forEach(a=>{a.constructor===Ei?e=a:o_(a)?t=a:n=a}),n||t||e||null}function r_(i,o){let e=i.indexOf(o);e>-1&&i.splice(e,1)}var Tu={provide:Qg,useFactory:()=>{let i=d(Jt,{self:!0});return{setParseErrors:o=>{i.setParseErrorSource(o)},set onReset(o){i.onReset=o}}}},Jt=class extends Ur{_parent=null;name=null;valueAccessor=null;isCustomControlBased=!1;userOnReset;resetSubscription;set onReset(o){this.userOnReset=o,this.resetSubscription?.unsubscribe(),this.resetSubscription=void 0,this.control&&(this.resetSubscription=this.control.events.subscribe(e=>{e instanceof zn&&this.control&&this.userOnReset?.(this.control.value)}),this.subscription?.add(this.resetSubscription))}isNativeFormElement=!1;rawValueAccessors;_selectedValueAccessor=null;get selectedValueAccessor(){return this._selectedValueAccessor??=a_(this,this.rawValueAccessors)}parseErrorsValidator=null;renderer;injector;requiredValidatorViaDi;subscription;customControlBindings=null;constructor(o,e,t){super(),this.injector=o,this.renderer=e,this.rawValueAccessors=t,this.injector?.get(Bt)?.onDestroy(()=>{this.removeParseErrorsValidator(this.control),this.subscription?.unsubscribe()})}setupCustomControl(){this.subscription?.unsubscribe();let o=this.injector?.get(te);if(!this.control||!o)return;let e=o.markForCheck.bind(o);this.subscription=new De,this.subscription.add(this.control.valueChanges.subscribe(e)),this.subscription.add(this.control.statusChanges.subscribe(e)),this.resetSubscription?.unsubscribe(),this.resetSubscription=void 0,this.userOnReset&&(this.resetSubscription=this.control.events.subscribe(t=>{t instanceof zn&&this.control&&this.userOnReset?.(this.control.value)}),this.subscription.add(this.resetSubscription)),this.parseErrorsValidator&&this.control.addValidators(this.parseErrorsValidator)}ngControlCreate(o){!o.nativeElement.hasAttribute?.("ngNoCva")&&(this.rawValueAccessors&&this.rawValueAccessors.length>0||this.valueAccessor!==null)||!o.customControl||(this.isCustomControlBased=!0,o.listenToCustomControlModel(n=>{this.control?.setValue(n,{emitModelToViewChange:!1}),this.control?.markAsDirty(),this.viewToModelUpdate(n)}),o.listenToCustomControlOutput("touch",()=>{this.control?.markAsTouched()}),this.customControlBindings={},this.isNativeFormElement=qg(o.nativeElement),this.requiredValidatorViaDi=this._rawValidators.find(n=>n instanceof Zr))}ngControlUpdate(o,e){if(!this.isCustomControlBased)return;let t=this.control,n=this.customControlBindings;Object.is(n.value,t.value)||(n.value=t.value,o.setCustomControlModelInput(t.value)),this.bindControlProperty(o,n,"touched",t.touched),this.bindControlProperty(o,n,"dirty",t.dirty),this.bindControlProperty(o,n,"valid",t.valid),this.bindControlProperty(o,n,"invalid",t.invalid),this.bindControlProperty(o,n,"pending",t.pending),this.bindControlProperty(o,n,"disabled",t.disabled),this.shouldBindRequired&&this.bindControlProperty(o,n,"required",this.isRequired);let a=t.errors;if(n.errors!==a){n.errors=a;let r=this._convertErrors(a);o.setInputOnDirectives("errors",r)}}get isRequired(){return(this.requiredValidatorViaDi?._enabled||this.control?._hasRequired())??!1}get shouldBindRequired(){return!0}bindControlProperty(o,e,t,n){if(e[t]===n)return;e[t]=n;let a=o.setInputOnDirectives(t,n);this.isNativeFormElement&&!a&&(t==="disabled"||t==="required")&&this.renderer&&Kg(this.renderer,o.nativeElement,t,n)}_convertErrors(o){if(o===null)return[];let e=this.control;return Object.entries(o).map(([t,n])=>new Ul({context:n,kind:t,control:e}))}setParseErrorSource(o){if(o===void 0)return;let e=null,t=$(()=>{let n=o();return n.length===0?null:n.reduce((a,r)=>(a[r.kind]=r,a),{})});this.parseErrorsValidator=(()=>e).bind(this),zt(()=>{e=t(),this.control?.updateValueAndValidity({emitEvent:!1})},{injector:this.injector})}removeParseErrorsValidator(o){this.parseErrorsValidator&&(o?.removeValidators(this.parseErrorsValidator),o?.updateValueAndValidity({emitEvent:!1}))}},Kr=class{_cd;constructor(o){this._cd=o}get isTouched(){return this._cd?.control?._touched?.(),!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return this._cd?.control?._pristine?.(),!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return this._cd?.control?._status?.(),!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return this._cd?._submitted?.(),!!this._cd?.submitted}};var Ai=(()=>{class i extends Kr{constructor(e){super(e)}static \u0275fac=function(t){return new(t||i)(de(Jt,2))};static \u0275dir=k({type:i,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(t,n){t&2&&p("ng-untouched",n.isUntouched)("ng-touched",n.isTouched)("ng-pristine",n.isPristine)("ng-dirty",n.isDirty)("ng-valid",n.isValid)("ng-invalid",n.isInvalid)("ng-pending",n.isPending)},standalone:!1,features:[Q]})}return i})(),mn=(()=>{class i extends Kr{constructor(e){super(e)}static \u0275fac=function(t){return new(t||i)(de(Bi,10))};static \u0275dir=k({type:i,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["","formArray",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(t,n){t&2&&p("ng-untouched",n.isUntouched)("ng-touched",n.isTouched)("ng-pristine",n.isPristine)("ng-dirty",n.isDirty)("ng-valid",n.isValid)("ng-invalid",n.isInvalid)("ng-pending",n.isPending)("ng-submitted",n.isSubmitted)},standalone:!1,features:[Q]})}return i})(),yo=class extends bo{constructor(o,e,t){super(Zl(e),Ql(t,e)),this.controls=o,this._initObservables(),this._setUpdateStrategy(e),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;registerControl(o,e){let t=this._find(o);return t||(this.controls[o]=e,e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange),e)}addControl(o,e,t={}){this.registerControl(o,e),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}removeControl(o,e={}){let t=this._find(o);t&&t._registerOnCollectionChange(()=>{}),delete this.controls[o],this.updateValueAndValidity({emitEvent:e.emitEvent}),this._onCollectionChange()}setControl(o,e,t={}){let n=this._find(o);n&&n._registerOnCollectionChange(()=>{}),delete this.controls[o],e&&this.registerControl(o,e),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}contains(o){return this._find(o)?.enabled===!0}setValue(o,e={}){pt(()=>{xu(this,!0,o),Object.keys(o).forEach(t=>{Cu(this,!0,t),this.controls[t].setValue(o[t],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e)})}patchValue(o,e={}){o!=null&&(Object.keys(o).forEach(t=>{let n=this._find(t);n&&n.patchValue(o[t],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e))}reset(o={},e={}){this._forEachChild((t,n)=>{t.reset(o?o[n]:null,Oe(V({},e),{onlySelf:!0}))}),this._updatePristine(e,this),this._updateTouched(e,this),this.updateValueAndValidity(e),e?.emitEvent!==!1&&this._events.next(new zn(this))}getRawValue(){return this._reduceChildren({},(o,e,t)=>(o[t]=e.getRawValue(),o))}_syncPendingControls(){let o=this._reduceChildren(!1,(e,t)=>t._syncPendingControls()?!0:e);return o&&this.updateValueAndValidity({onlySelf:!0}),o}_forEachChild(o){Object.keys(this.controls).forEach(e=>{let t=this.controls[e];t&&o(t,e)})}_setUpControls(){this._forEachChild(o=>{o.setParent(this),o._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(o){for(let[e,t]of Object.entries(this.controls))if(this.contains(e)&&o(t))return!0;return!1}_reduceValue(){let o={};return this._reduceChildren(o,(e,t,n)=>((t.enabled||this.disabled)&&(e[n]=t.value),e))}_reduceChildren(o,e){let t=o;return this._forEachChild((n,a)=>{t=e(t,n,a)}),t}_allControlsDisabled(){for(let o of Object.keys(this.controls))if(this.controls[o].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(o){return wu(this.controls,o)?this.controls[o]:null}};var $l=class extends yo{};var s_={provide:Bi,useExisting:nt(()=>ba)},pa=Promise.resolve(),ba=(()=>{class i extends Bi{callSetDisabledState;get submitted(){return pt(this.submittedReactive)}_submitted=$(()=>this.submittedReactive());submittedReactive=R(!1);_directives=new Set;form;ngSubmit=new K;options;constructor(e,t,n){super(),this.callSetDisabledState=n,this.form=new yo({},Yl(e),Xl(t))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(e){pa.then(()=>{let t=this._findContainer(e.path);e.control=t.registerControl(e.name,e.control),e._setupWithForm(this.callSetDisabledState),e.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(e)})}getControl(e){return this.form.get(e.path)}removeControl(e){pa.then(()=>{this._findContainer(e.path)?.removeControl(e.name),this._directives.delete(e)})}addFormGroup(e){pa.then(()=>{let t=this._findContainer(e.path),n=new yo({});Mu(n,e),t.registerControl(e.name,n),n.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(e){pa.then(()=>{this._findContainer(e.path)?.removeControl?.(e.name)})}getFormGroup(e){return this.form.get(e.path)}updateModel(e,t){pa.then(()=>{this.form.get(e.path).setValue(t)})}setValue(e){this.control.setValue(e)}onSubmit(e){return this.submittedReactive.set(!0),Au(this.form,this._directives),this.ngSubmit.emit(e),this.form._events.next(new $r(this.control)),e?.target?.method==="dialog"}onReset(){this.resetForm()}resetForm(e=void 0){this.form.reset(e),this.submittedReactive.set(!1)}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.form._updateOn=this.options.updateOn)}_findContainer(e){return e.pop(),e.length?this.form.get(e):this.form}static \u0275fac=function(t){return new(t||i)(de(zi,10),de(Yr,10),de(va,8))};static \u0275dir=k({type:i,selectors:[["form",3,"ngNoForm","",3,"formGroup","",3,"formArray",""],["ng-form"],["","ngForm",""]],hostBindings:function(t,n){t&1&&A("submit",function(r){return n.onSubmit(r)})("reset",function(){return n.onReset()})},inputs:{options:[0,"ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[J([s_]),Q]})}return i})();function nu(i,o){let e=i.indexOf(o);e>-1&&i.splice(e,1)}function ou(i){return typeof i=="object"&&i!==null&&Object.keys(i).length===2&&"value"in i&&"disabled"in i}var _a=class extends bo{defaultValue=null;_onChange=[];_pendingValue;_pendingChange=!1;constructor(o=null,e,t){super(Zl(e),Ql(t,e)),this._applyFormState(o),this._setUpdateStrategy(e),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),Xr(e)&&(e.nonNullable||e.initialValueIsDefault)&&(ou(o)?this.defaultValue=o.value:this.defaultValue=o)}setValue(o,e={}){pt(()=>{this.value=this._pendingValue=o,this._onChange.length&&e.emitModelToViewChange!==!1&&this._onChange.forEach(t=>t(this.value,e.emitViewToModelChange!==!1)),this.updateValueAndValidity(e)})}patchValue(o,e={}){this.setValue(o,e)}reset(o=this.defaultValue,e={}){this._applyFormState(o),this.markAsPristine(e),this.markAsUntouched(e),this.setValue(this.value,e),e.overwriteDefaultValue&&(this.defaultValue=this.value),this._pendingChange=!1,e?.emitEvent!==!1&&this._events.next(new zn(this))}_updateValue(){}_anyControls(o){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(o){this._onChange.push(o)}_unregisterOnChange(o){nu(this._onChange,o)}registerOnDisabledChange(o){this._onDisabledChange.push(o)}_unregisterOnDisabledChange(o){nu(this._onDisabledChange,o)}_forEachChild(o){}_syncPendingControls(){return this.updateOn==="submit"&&(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),this._pendingChange)?(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),!0):!1}_applyFormState(o){ou(o)?(this.value=this._pendingValue=o.value,o.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=o}};var l_=i=>i instanceof _a;var c_={provide:Jt,useExisting:nt(()=>nc)},au=Promise.resolve(),nc=(()=>{class i extends Jt{_changeDetectorRef;callSetDisabledState;control=new _a;static ngAcceptInputType_isDisabled;_registered=!1;viewModel;name="";isDisabled;model;options;update=new K;constructor(e,t,n,a,r,u,h,g){super(h,g,a),this._changeDetectorRef=r,this.callSetDisabledState=u,this._parent=e,this._setValidators(t),this._setAsyncValidators(n)}ngOnChanges(e){if(this._checkForErrors(),!this._registered||"name"in e){if(this._registered&&(this._checkName(),this.formDirective)){let t=e.name.previousValue;this.formDirective.removeControl({name:t,path:this._getPath(t)})}this._setUpControl()}"isDisabled"in e&&this._updateDisabled(e),Eu(e,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective?.removeControl(this)}\u0275ngControlCreate(e){super.ngControlCreate(e)}\u0275ngControlUpdate(e){super.ngControlUpdate(e,!1)}get shouldBindRequired(){return!1}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!!(this.options&&this.options.standalone)}_setUpStandalone(){this.isCustomControlBased?this.setupCustomControl():(this.valueAccessor??=this.selectedValueAccessor,Gl(this.control,this,this.callSetDisabledState)),this.control.updateValueAndValidity({emitEvent:!1})}_setupWithForm(e){this.isCustomControlBased?this.setupCustomControl():(this.valueAccessor??=this.selectedValueAccessor,Gl(this.control,this,e))}_checkForErrors(){this._checkName()}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),!this._isStandalone()&&this.name}_updateValue(e){au.then(()=>{this.control.setValue(e,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(e){let t=e.isDisabled.currentValue,n=t!==0&&L(t);au.then(()=>{n&&!this.control.disabled?this.control.disable():!n&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(e){return this._parent?ku(e,this._parent):[e]}static \u0275fac=function(t){return new(t||i)(de(Bi,9),de(zi,10),de(Yr,10),de(Mi,10),de(te,8),de(va,8),de(X,8),de(ve,8))};static \u0275dir=k({type:i,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"],options:[0,"ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],standalone:!1,features:[J([c_,Tu]),Q,Se,Ks(null)]})}return i})();var Co=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""],standalone:!1})}return i})(),d_={provide:Mi,useExisting:nt(()=>ya),multi:!0},ya=(()=>{class i extends lu{writeValue(e){let t=e??"";this.setProperty("value",t)}registerOnChange(e){this.onChange=t=>{e(t==""?null:parseFloat(t))}}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["input","type","number","formControlName","",3,"ngNoCva",""],["input","type","number","formControl","",3,"ngNoCva",""],["input","type","number","ngModel","",3,"ngNoCva",""]],hostBindings:function(t,n){t&1&&A("input",function(r){return n.onChange(r.target.value)})("blur",function(){return n.onTouched()})},standalone:!1,features:[J([d_]),Q]})}return i})();var Wl=class extends bo{constructor(o,e,t){super(Zl(e),Ql(t,e)),this.controls=o,this._initObservables(),this._setUpdateStrategy(e),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;at(o){return this.controls[this._adjustIndex(o)]}push(o,e={}){Array.isArray(o)?o.forEach(t=>{this.controls.push(t),this._registerControl(t)}):(this.controls.push(o),this._registerControl(o)),this.updateValueAndValidity({emitEvent:e.emitEvent}),this._onCollectionChange()}insert(o,e,t={}){this.controls.splice(o,0,e),this._registerControl(e),this.updateValueAndValidity({emitEvent:t.emitEvent})}removeAt(o,e={}){let t=this._adjustIndex(o);t<0&&(t=0),this.controls[t]&&this.controls[t]._registerOnCollectionChange(()=>{}),this.controls.splice(t,1),this.updateValueAndValidity({emitEvent:e.emitEvent})}setControl(o,e,t={}){let n=this._adjustIndex(o);n<0&&(n=0),this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),this.controls.splice(n,1),e&&(this.controls.splice(n,0,e),this._registerControl(e)),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(o,e={}){pt(()=>{xu(this,!1,o),o.forEach((t,n)=>{Cu(this,!1,n),this.at(n).setValue(t,{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e)})}patchValue(o,e={}){o!=null&&(o.forEach((t,n)=>{this.at(n)&&this.at(n).patchValue(t,{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e))}reset(o=[],e={}){this._forEachChild((t,n)=>{t.reset(o[n],Oe(V({},e),{onlySelf:!0}))}),this._updatePristine(e,this),this._updateTouched(e,this),this.updateValueAndValidity(e),e?.emitEvent!==!1&&this._events.next(new zn(this))}getRawValue(){return this.controls.map(o=>o.getRawValue())}clear(o={}){this.controls.length<1||(this._forEachChild(e=>e._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:o.emitEvent}))}_adjustIndex(o){return o<0?o+this.length:o}_syncPendingControls(){let o=this.controls.reduce((e,t)=>t._syncPendingControls()?!0:e,!1);return o&&this.updateValueAndValidity({onlySelf:!0}),o}_forEachChild(o){this.controls.forEach((e,t)=>{o(e,t)})}_updateValue(){this.value=this.controls.filter(o=>o.enabled||this.disabled).map(o=>o.value)}_anyControls(o){return this.controls.some(e=>e.enabled&&o(e))}_setUpControls(){this._forEachChild(o=>this._registerControl(o))}_allControlsDisabled(){for(let o of this.controls)if(o.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(o){o.setParent(this),o._registerOnCollectionChange(this._onCollectionChange)}_find(o){return this.at(o)??null}};var m_=(()=>{class i extends Bi{callSetDisabledState;get submitted(){return pt(this._submittedReactive)}set submitted(e){this._submittedReactive.set(e)}_submitted=$(()=>this._submittedReactive());_submittedReactive=R(!1);_oldForm;_onCollectionChange=()=>this._updateDomValue();directives=[];constructor(e,t,n){super(),this.callSetDisabledState=n,this._setValidators(e),this._setAsyncValidators(t)}ngOnChanges(e){this.onChanges(e)}ngOnDestroy(){this.onDestroy()}onChanges(e){this._checkFormPresent(),e.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}onDestroy(){this.form&&(qr(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get path(){return[]}addControl(e){let t=this.form.get(e.path);return e._setupWithForm(t,this.callSetDisabledState),t.updateValueAndValidity({emitEvent:!1}),this.directives.push(e),t}getControl(e){return this.form.get(e.path)}removeControl(e){iu(e.control||null,e,!1),r_(this.directives,e)}addFormGroup(e){this._setUpFormContainer(e)}removeFormGroup(e){this._cleanUpFormContainer(e)}getFormGroup(e){return this.form.get(e.path)}getFormArray(e){return this.form.get(e.path)}addFormArray(e){this._setUpFormContainer(e)}removeFormArray(e){this._cleanUpFormContainer(e)}updateModel(e,t){this.form.get(e.path).setValue(t)}onReset(){this.resetForm()}resetForm(e=void 0,t={}){this.form.reset(e,t),this._submittedReactive.set(!1)}onSubmit(e){return this.submitted=!0,Au(this.form,this.directives),this.ngSubmit.emit(e),this.form._events.next(new $r(this.control)),e?.target?.method==="dialog"}_updateDomValue(){this.directives.forEach(e=>{let t=e.control,n=this.form.get(e.path);t!==n&&(iu(t||null,e),l_(n)&&e._setupWithForm(n,this.callSetDisabledState))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(e){let t=this.form.get(e.path);Mu(t,e),t.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(e){let t=this.form?.get(e.path);t&&n_(t,e)&&t.updateValueAndValidity({emitEvent:!1})}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm?._registerOnCollectionChange(()=>{})}_updateValidators(){ic(this.form,this),this._oldForm&&qr(this._oldForm,this)}_checkFormPresent(){this.form}static \u0275fac=function(t){return new(t||i)(de(zi,10),de(Yr,10),de(va,8))};static \u0275dir=k({type:i,features:[Q,Se]})}return i})();var Iu=new x("");var u_={provide:Jt,useExisting:nt(()=>ji)},ji=(()=>{class i extends Jt{_ngModelWarningConfig;_added=!1;viewModel;control;name=null;set isDisabled(e){}model;update=new K;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(e,t,n,a,r,u,h){super(h,u,a),this._ngModelWarningConfig=r,this._parent=e,this._setValidators(t),this._setAsyncValidators(n)}_setupWithForm(e,t){this.control=e,this.isCustomControlBased?this.setupCustomControl():(this.valueAccessor??=this.selectedValueAccessor,Gl(e,this,t))}ngOnChanges(e){this._added||this._setUpControl(),Eu(e,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective?.removeControl(this)}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}get path(){return ku(this.name==null?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_setUpControl(){this.control=this.formDirective.addControl(this),this._added=!0}\u0275ngControlCreate(e){super.ngControlCreate(e)}\u0275ngControlUpdate(e){this.isCustomControlBased&&(this._added||this._setUpControl(),super.ngControlUpdate(e,!0))}static \u0275fac=function(t){return new(t||i)(de(Bi,13),de(zi,10),de(Yr,10),de(Mi,10),de(Iu,8),de(ve,8),de(X,8))};static \u0275dir=k({type:i,selectors:[["","formControlName",""]],inputs:{name:[0,"formControlName","name"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},standalone:!1,features:[J([u_,Tu]),Q,Se,Ks(null)]})}return i})();var h_={provide:Bi,useExisting:nt(()=>Ut)},Ut=(()=>{class i extends m_{form=null;ngSubmit=new K;get control(){return this.form}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","formGroup",""]],hostBindings:function(t,n){t&1&&A("submit",function(r){return n.onSubmit(r)})("reset",function(){return n.onReset()})},inputs:{form:[0,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[J([h_]),Q]})}return i})();var Ru=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();function ru(i){return!!i&&(i.asyncValidators!==void 0||i.validators!==void 0||i.updateOn!==void 0)}var un=(()=>{class i{useNonNullable=!1;get nonNullable(){let e=new i;return e.useNonNullable=!0,e}group(e,t=null){let n=this._reduceControls(e),a={};return ru(t)?a=t:t!==null&&(a.validators=t.validator,a.asyncValidators=t.asyncValidator),new yo(n,a)}record(e,t=null){let n=this._reduceControls(e);return new $l(n,t)}control(e,t,n){let a={};return this.useNonNullable?(ru(t)?a=t:(a.validators=t,a.asyncValidators=n),new _a(e,Oe(V({},a),{nonNullable:!0}))):new _a(e,t,n)}array(e,t,n){let a=e.map(r=>this._createControl(r));return new Wl(a,t,n)}_reduceControls(e){let t={};return Object.keys(e).forEach(n=>{t[n]=this._createControl(e[n])}),t}_createControl(e){if(e instanceof _a)return e;if(e instanceof bo)return e;if(Array.isArray(e)){let t=e[0],n=e.length>1?e[1]:null,a=e.length>2?e[2]:null;return this.control(t,n,a)}else return this.control(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var hn=(()=>{class i{static withConfig(e){return{ngModule:i,providers:[{provide:va,useValue:e.callSetDisabledState??Qr}]}}static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Ru]})}return i})(),pn=(()=>{class i{static withConfig(e){return{ngModule:i,providers:[{provide:Iu,useValue:e.warnOnNgModelWithFormControl??"always"},{provide:va,useValue:e.callSetDisabledState??Qr}]}}static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Ru]})}return i})();var Ou=new x("MAT_INPUT_VALUE_ACCESSOR");var oc=class{_box;_destroyed=new I;_resizeSubject=new I;_resizeObserver;_elementObservables=new Map;constructor(o){this._box=o,typeof ResizeObserver<"u"&&(this._resizeObserver=new ResizeObserver(e=>this._resizeSubject.next(e)))}observe(o){return this._elementObservables.has(o)||this._elementObservables.set(o,new yt(e=>{let t=this._resizeSubject.subscribe(e);return this._resizeObserver?.observe(o,{box:this._box}),()=>{this._resizeObserver?.unobserve(o),t.unsubscribe(),this._elementObservables.delete(o)}}).pipe(Ce(e=>e.some(t=>t.target===o)),js({bufferSize:1,refCount:!0}),oe(this._destroyed))),this._elementObservables.get(o)}destroy(){this._destroyed.next(),this._destroyed.complete(),this._resizeSubject.complete(),this._elementObservables.clear()}},Pu=(()=>{class i{_cleanupErrorListener;_observers=new Map;_ngZone=d(H);constructor(){typeof ResizeObserver<"u"}ngOnDestroy(){for(let[,e]of this._observers)e.destroy();this._observers.clear(),this._cleanupErrorListener?.()}observe(e,t){let n=t?.box||"content-box";return this._observers.has(n)||this._observers.set(n,new oc(n)),this._observers.get(n).observe(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var p_=["notch"],f_=["*"],Fu=["iconPrefixContainer"],Nu=["textPrefixContainer"],Lu=["iconSuffixContainer"],Vu=["textSuffixContainer"],g_=["textField"],__=["*",[["mat-label"]],[["","matPrefix",""],["","matIconPrefix",""]],[["","matTextPrefix",""]],[["","matTextSuffix",""]],[["","matSuffix",""],["","matIconSuffix",""]],[["mat-error"],["","matError",""]],[["mat-hint",3,"align","end"]],[["mat-hint","align","end"]]],v_=["*","mat-label","[matPrefix], [matIconPrefix]","[matTextPrefix]","[matTextSuffix]","[matSuffix], [matIconSuffix]","mat-error, [matError]","mat-hint:not([align='end'])","mat-hint[align='end']"];function b_(i,o){i&1&&v(0,"span",21)}function y_(i,o){if(i&1&&(s(0,"label",20),U(1,1),M(2,b_,1,0,"span",21),l()),i&2){let e=D(2);C("floating",e._shouldLabelFloat())("monitorResize",e._hasOutline())("id",e._labelId),Z("for",e._control.disableAutomaticLabeling?null:e._control.id),c(2),E(!e.hideRequiredMarker&&e._control.required?2:-1)}}function C_(i,o){if(i&1&&M(0,y_,3,5,"label",20),i&2){let e=D();E(e._hasFloatingLabel()?0:-1)}}function x_(i,o){i&1&&v(0,"div",7)}function w_(i,o){}function D_(i,o){if(i&1&&ze(0,w_,0,0,"ng-template",13),i&2){D(2);let e=Fe(1);C("ngTemplateOutlet",e)}}function k_(i,o){if(i&1&&(s(0,"div",9),M(1,D_,1,1,null,13),l()),i&2){let e=D();C("matFormFieldNotchedOutlineOpen",e._shouldLabelFloat()),c(),E(e._forceDisplayInfixLabel()?-1:1)}}function S_(i,o){i&1&&(s(0,"div",10,2),U(2,2),l())}function M_(i,o){i&1&&(s(0,"div",11,3),U(2,3),l())}function E_(i,o){}function A_(i,o){if(i&1&&ze(0,E_,0,0,"ng-template",13),i&2){D();let e=Fe(1);C("ngTemplateOutlet",e)}}function T_(i,o){i&1&&(s(0,"div",14,4),U(2,4),l())}function I_(i,o){i&1&&(s(0,"div",15,5),U(2,5),l())}function R_(i,o){i&1&&v(0,"div",16)}function O_(i,o){i&1&&(s(0,"div",18),U(1,6),l())}function P_(i,o){if(i&1&&(s(0,"mat-hint",22),m(1),l()),i&2){let e=D(2);C("id",e._hintLabelId),c(),q(e.hintLabel)}}function F_(i,o){if(i&1&&(s(0,"div",19),M(1,P_,2,2,"mat-hint",22),U(2,7),v(3,"div",23),U(4,8),l()),i&2){let e=D();c(),E(e.hintLabel?1:-1)}}var Ot=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-label"]]})}return i})(),$u=new x("MatError"),fn=(()=>{class i{id=d(be).getId("mat-mdc-error-");static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-error"],["","matError",""]],hostAttrs:[1,"mat-mdc-form-field-error","mat-mdc-form-field-bottom-align"],hostVars:1,hostBindings:function(t,n){t&2&&dt("id",n.id)},inputs:{id:"id"},features:[J([{provide:$u,useExisting:i}])]})}return i})(),es=(()=>{class i{align="start";id=d(be).getId("mat-mdc-hint-");static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-hint"]],hostAttrs:[1,"mat-mdc-form-field-hint","mat-mdc-form-field-bottom-align"],hostVars:4,hostBindings:function(t,n){t&2&&(dt("id",n.id),Z("align",null),p("mat-mdc-form-field-hint-end",n.align==="end"))},inputs:{align:"align",id:"id"}})}return i})(),N_=new x("MatPrefix");var L_=new x("MatSuffix");var Wu=new x("FloatingLabelParent"),Bu=(()=>{class i{_elementRef=d(N);get floating(){return this._floating}set floating(e){this._floating=e,this.monitorResize&&this._handleResize()}_floating=!1;get monitorResize(){return this._monitorResize}set monitorResize(e){this._monitorResize=e,this._monitorResize?this._subscribeToResize():this._resizeSubscription.unsubscribe()}_monitorResize=!1;_resizeObserver=d(Pu);_ngZone=d(H);_parent=d(Wu);_resizeSubscription=new De;ngOnDestroy(){this._resizeSubscription.unsubscribe()}getWidth(){return V_(this._elementRef.nativeElement)}get element(){return this._elementRef.nativeElement}_handleResize(){setTimeout(()=>this._parent._handleLabelResized())}_subscribeToResize(){this._resizeSubscription.unsubscribe(),this._ngZone.runOutsideAngular(()=>{this._resizeSubscription=this._resizeObserver.observe(this._elementRef.nativeElement,{box:"border-box"}).subscribe(()=>this._handleResize())})}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["label","matFormFieldFloatingLabel",""]],hostAttrs:[1,"mdc-floating-label","mat-mdc-floating-label"],hostVars:2,hostBindings:function(t,n){t&2&&p("mdc-floating-label--float-above",n.floating)},inputs:{floating:"floating",monitorResize:"monitorResize"}})}return i})();function V_(i){let o=i;if(o.offsetParent!==null)return o.scrollWidth;let e=o.cloneNode(!0);e.style.setProperty("position","absolute"),e.style.setProperty("transform","translate(-9999px, -9999px)"),document.documentElement.appendChild(e);let t=e.scrollWidth;return e.remove(),t}var zu="mdc-line-ripple--active",Jr="mdc-line-ripple--deactivating",ju=(()=>{class i{_elementRef=d(N);_cleanupTransitionEnd;constructor(){let e=d(H),t=d(ve);e.runOutsideAngular(()=>{this._cleanupTransitionEnd=t.listen(this._elementRef.nativeElement,"transitionend",this._handleTransitionEnd)})}activate(){let e=this._elementRef.nativeElement.classList;e.remove(Jr),e.add(zu)}deactivate(){this._elementRef.nativeElement.classList.add(Jr)}_handleTransitionEnd=e=>{let t=this._elementRef.nativeElement.classList,n=t.contains(Jr);e.propertyName==="opacity"&&n&&t.remove(zu,Jr)};ngOnDestroy(){this._cleanupTransitionEnd()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["div","matFormFieldLineRipple",""]],hostAttrs:[1,"mdc-line-ripple"]})}return i})(),Hu=(()=>{class i{_elementRef=d(N);_ngZone=d(H);open=!1;_notch;ngAfterViewInit(){let e=this._elementRef.nativeElement,t=e.querySelector(".mdc-floating-label");t?(e.classList.add("mdc-notched-outline--upgraded"),typeof requestAnimationFrame=="function"&&(t.style.transitionDuration="0s",this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>t.style.transitionDuration="")}))):e.classList.add("mdc-notched-outline--no-label")}_setNotchWidth(e){let t=this._notch.nativeElement;!this.open||!e?t.style.width="":t.style.width=`calc(${e}px * var(--mat-mdc-form-field-floating-label-scale, 0.75) + 9px)`}_setMaxWidth(e){this._notch.nativeElement.style.setProperty("--mat-form-field-notch-max-width",`calc(100% - ${e}px)`)}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["div","matFormFieldNotchedOutline",""]],viewQuery:function(t,n){if(t&1&&Me(p_,5),t&2){let a;O(a=P())&&(n._notch=a.first)}},hostAttrs:[1,"mdc-notched-outline"],hostVars:2,hostBindings:function(t,n){t&2&&p("mdc-notched-outline--notched",n.open)},inputs:{open:[0,"matFormFieldNotchedOutlineOpen","open"]},ngContentSelectors:f_,decls:5,vars:0,consts:[["notch",""],[1,"mat-mdc-notch-piece","mdc-notched-outline__leading"],[1,"mat-mdc-notch-piece","mdc-notched-outline__notch"],[1,"mat-mdc-notch-piece","mdc-notched-outline__trailing"]],template:function(t,n){t&1&&(ce(),ht(0,"div",1),Ie(1,"div",2,0),U(3),je(),ht(4,"div",3))},encapsulation:2})}return i})(),xa=(()=>{class i{value=null;stateChanges;id;placeholder;ngControl=null;focused=!1;empty=!1;shouldLabelFloat=!1;required=!1;disabled=!1;errorState=!1;controlType;autofilled;userAriaDescribedBy;disableAutomaticLabeling;describedByIds;static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i})}return i})();var jn=new x("MatFormField"),B_=new x("MAT_FORM_FIELD_DEFAULT_OPTIONS"),Uu="fill",z_="auto",Gu="fixed",j_="translateY(-50%)",kt=(()=>{class i{_elementRef=d(N);_changeDetectorRef=d(te);_platform=d(le);_idGenerator=d(be);_ngZone=d(H);_defaults=d(B_,{optional:!0});_currentDirection;_textField;_iconPrefixContainer;_textPrefixContainer;_iconSuffixContainer;_textSuffixContainer;_floatingLabel;_notchedOutline;_lineRipple;_iconPrefixContainerSignal=$o("iconPrefixContainer");_textPrefixContainerSignal=$o("textPrefixContainer");_iconSuffixContainerSignal=$o("iconSuffixContainer");_textSuffixContainerSignal=$o("textSuffixContainer");_prefixSuffixContainers=$(()=>[this._iconPrefixContainerSignal(),this._textPrefixContainerSignal(),this._iconSuffixContainerSignal(),this._textSuffixContainerSignal()].map(e=>e?.nativeElement).filter(e=>e!==void 0));_formFieldControl;_prefixChildren;_suffixChildren;_errorChildren;_hintChildren;_labelChild=pd(Ot);get hideRequiredMarker(){return this._hideRequiredMarker}set hideRequiredMarker(e){this._hideRequiredMarker=mt(e)}_hideRequiredMarker=!1;color="primary";get floatLabel(){return this._floatLabel||this._defaults?.floatLabel||z_}set floatLabel(e){e!==this._floatLabel&&(this._floatLabel=e,this._changeDetectorRef.markForCheck())}_floatLabel;get appearance(){return this._appearanceSignal()}set appearance(e){let t=e||this._defaults?.appearance||Uu;this._appearanceSignal.set(t)}_appearanceSignal=R(Uu);get subscriptSizing(){return this._subscriptSizing||this._defaults?.subscriptSizing||Gu}set subscriptSizing(e){this._subscriptSizing=e||this._defaults?.subscriptSizing||Gu}_subscriptSizing=null;get hintLabel(){return this._hintLabel}set hintLabel(e){this._hintLabel=e,this._processHints()}_hintLabel="";_hasIconPrefix=!1;_hasTextPrefix=!1;_hasIconSuffix=!1;_hasTextSuffix=!1;_labelId=this._idGenerator.getId("mat-mdc-form-field-label-");_hintLabelId=this._idGenerator.getId("mat-mdc-hint-");_describedByIds;get _control(){return this._explicitFormFieldControl||this._formFieldControl}set _control(e){this._explicitFormFieldControl=e}_destroyed=new I;_isFocused=null;_explicitFormFieldControl;_previousControl=null;_previousControlValidatorFn=null;_stateChanges;_valueChanges;_describedByChanges;_outlineLabelOffsetResizeObserver=null;_animationsDisabled=pe();constructor(){let e=this._defaults,t=d(qe);e&&(e.appearance&&(this.appearance=e.appearance),this._hideRequiredMarker=!!e?.hideRequiredMarker,e.color&&(this.color=e.color)),zt(()=>this._currentDirection=t.valueSignal()),this._syncOutlineLabelOffset()}ngAfterViewInit(){this._updateFocusState(),this._animationsDisabled||this._ngZone.runOutsideAngular(()=>{setTimeout(()=>{this._elementRef.nativeElement.classList.add("mat-form-field-animations-enabled")},300)}),this._changeDetectorRef.detectChanges()}ngAfterContentInit(){this._assertFormFieldControl(),this._initializeSubscript(),this._initializePrefixAndSuffix()}ngAfterContentChecked(){this._assertFormFieldControl(),this._control!==this._previousControl&&(this._initializeControl(this._previousControl),this._control.ngControl&&this._control.ngControl.control&&(this._previousControlValidatorFn=this._control.ngControl.control.validator),this._previousControl=this._control),this._control.ngControl&&this._control.ngControl.control&&this._control.ngControl.control.validator!==this._previousControlValidatorFn&&this._changeDetectorRef.markForCheck()}ngOnDestroy(){this._outlineLabelOffsetResizeObserver?.disconnect(),this._stateChanges?.unsubscribe(),this._valueChanges?.unsubscribe(),this._describedByChanges?.unsubscribe(),this._destroyed.next(),this._destroyed.complete()}getLabelId=$(()=>this._hasFloatingLabel()?this._labelId:null);getConnectedOverlayOrigin(){return this._textField||this._elementRef}_animateAndLockLabel(){this._hasFloatingLabel()&&(this.floatLabel="always")}_initializeControl(e){let t=this._control,n="mat-mdc-form-field-type-";e&&this._elementRef.nativeElement.classList.remove(n+e.controlType),t.controlType&&this._elementRef.nativeElement.classList.add(n+t.controlType),this._stateChanges?.unsubscribe(),this._stateChanges=t.stateChanges.subscribe(()=>{this._updateFocusState(),this._changeDetectorRef.markForCheck()}),this._describedByChanges?.unsubscribe(),this._describedByChanges=t.stateChanges.pipe(ke([void 0,void 0]),Pe(()=>[t.errorState,t.userAriaDescribedBy]),zs(),Ce(([[a,r],[u,h]])=>a!==u||r!==h)).subscribe(()=>this._syncDescribedByIds()),this._valueChanges?.unsubscribe(),t.ngControl&&t.ngControl.valueChanges&&(this._valueChanges=t.ngControl.valueChanges.pipe(oe(this._destroyed)).subscribe(()=>this._changeDetectorRef.markForCheck()))}_checkPrefixAndSuffixTypes(){this._hasIconPrefix=!!this._prefixChildren.find(e=>!e._isText),this._hasTextPrefix=!!this._prefixChildren.find(e=>e._isText),this._hasIconSuffix=!!this._suffixChildren.find(e=>!e._isText),this._hasTextSuffix=!!this._suffixChildren.find(e=>e._isText)}_initializePrefixAndSuffix(){this._checkPrefixAndSuffixTypes(),$e(this._prefixChildren.changes,this._suffixChildren.changes).subscribe(()=>{this._checkPrefixAndSuffixTypes(),this._changeDetectorRef.markForCheck()})}_initializeSubscript(){this._hintChildren.changes.subscribe(()=>{this._processHints(),this._changeDetectorRef.markForCheck()}),this._errorChildren.changes.subscribe(()=>{this._syncDescribedByIds(),this._changeDetectorRef.markForCheck()}),this._validateHints(),this._syncDescribedByIds()}_assertFormFieldControl(){this._control}_updateFocusState(){let e=this._control.focused;e&&!this._isFocused?(this._isFocused=!0,this._lineRipple?.activate()):!e&&(this._isFocused||this._isFocused===null)&&(this._isFocused=!1,this._lineRipple?.deactivate()),this._elementRef.nativeElement.classList.toggle("mat-focused",e),this._textField?.nativeElement.classList.toggle("mdc-text-field--focused",e)}_syncOutlineLabelOffset(){_d({earlyRead:()=>{if(this._appearanceSignal()!=="outline")return this._outlineLabelOffsetResizeObserver?.disconnect(),null;if(globalThis.ResizeObserver){this._outlineLabelOffsetResizeObserver||=new globalThis.ResizeObserver(()=>{this._writeOutlinedLabelStyles(this._getOutlinedLabelOffset())});for(let e of this._prefixSuffixContainers())this._outlineLabelOffsetResizeObserver.observe(e,{box:"border-box"})}return this._getOutlinedLabelOffset()},write:e=>this._writeOutlinedLabelStyles(e())})}_shouldAlwaysFloat(){return this.floatLabel==="always"}_hasOutline(){return this.appearance==="outline"}_forceDisplayInfixLabel(){return!this._platform.isBrowser&&this._prefixChildren.length&&!this._shouldLabelFloat()}_hasFloatingLabel=$(()=>!!this._labelChild());_shouldLabelFloat(){return this._hasFloatingLabel()?this._control.shouldLabelFloat||this._shouldAlwaysFloat():!1}_shouldForward(e){let t=this._control?this._control.ngControl:null;return t&&t[e]}_getSubscriptMessageType(){return this._errorChildren&&this._errorChildren.length>0&&this._control.errorState?"error":"hint"}_handleLabelResized(){this._refreshOutlineNotchWidth()}_refreshOutlineNotchWidth(){!this._hasOutline()||!this._floatingLabel||!this._shouldLabelFloat()?this._notchedOutline?._setNotchWidth(0):this._notchedOutline?._setNotchWidth(this._floatingLabel.getWidth())}_processHints(){this._validateHints(),this._syncDescribedByIds()}_validateHints(){this._hintChildren}_syncDescribedByIds(){if(this._control){let e=[];if(this._control.userAriaDescribedBy&&typeof this._control.userAriaDescribedBy=="string"&&e.push(...this._control.userAriaDescribedBy.split(" ")),this._getSubscriptMessageType()==="hint"){let a=this._hintChildren?this._hintChildren.find(u=>u.align==="start"):null,r=this._hintChildren?this._hintChildren.find(u=>u.align==="end"):null;a?e.push(a.id):this._hintLabel&&e.push(this._hintLabelId),r&&e.push(r.id)}else this._errorChildren&&e.push(...this._errorChildren.map(a=>a.id));let t=this._control.describedByIds,n;if(t){let a=this._describedByIds||e;n=e.concat(t.filter(r=>r&&!a.includes(r)))}else n=e;this._control.setDescribedByIds(n),this._describedByIds=e}}_getOutlinedLabelOffset(){if(!this._hasOutline()||!this._floatingLabel)return null;if(!this._iconPrefixContainer&&!this._textPrefixContainer)return["",null];if(!this._isAttachedToDom())return null;let e=this._iconPrefixContainer?.nativeElement,t=this._textPrefixContainer?.nativeElement,n=this._iconSuffixContainer?.nativeElement,a=this._textSuffixContainer?.nativeElement,r=e?.getBoundingClientRect().width??0,u=t?.getBoundingClientRect().width??0,h=n?.getBoundingClientRect().width??0,g=a?.getBoundingClientRect().width??0,_=this._currentDirection==="rtl"?"-1":"1",w=`${r+u}px`,G=`calc(${_} * (${w} + var(--mat-mdc-form-field-label-offset-x, 0px)))`,ie=`var(--mat-mdc-form-field-label-transform, ${j_} translateX(${G}))`,fe=r+u+h+g;return[ie,fe]}_writeOutlinedLabelStyles(e){if(e!==null){let[t,n]=e;this._floatingLabel&&(this._floatingLabel.element.style.transform=t),n!==null&&this._notchedOutline?._setMaxWidth(n)}}_isAttachedToDom(){let e=this._elementRef.nativeElement;if(e.getRootNode){let t=e.getRootNode();return t&&t!==e}return document.documentElement.contains(e)}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-form-field"]],contentQueries:function(t,n,a){if(t&1&&(md(a,n._labelChild,Ot,5),at(a,xa,5)(a,N_,5)(a,L_,5)(a,$u,5)(a,es,5)),t&2){Ys();let r;O(r=P())&&(n._formFieldControl=r.first),O(r=P())&&(n._prefixChildren=r),O(r=P())&&(n._suffixChildren=r),O(r=P())&&(n._errorChildren=r),O(r=P())&&(n._hintChildren=r)}},viewQuery:function(t,n){if(t&1&&(ud(n._iconPrefixContainerSignal,Fu,5)(n._textPrefixContainerSignal,Nu,5)(n._iconSuffixContainerSignal,Lu,5)(n._textSuffixContainerSignal,Vu,5),Me(g_,5)(Fu,5)(Nu,5)(Lu,5)(Vu,5)(Bu,5)(Hu,5)(ju,5)),t&2){Ys(4);let a;O(a=P())&&(n._textField=a.first),O(a=P())&&(n._iconPrefixContainer=a.first),O(a=P())&&(n._textPrefixContainer=a.first),O(a=P())&&(n._iconSuffixContainer=a.first),O(a=P())&&(n._textSuffixContainer=a.first),O(a=P())&&(n._floatingLabel=a.first),O(a=P())&&(n._notchedOutline=a.first),O(a=P())&&(n._lineRipple=a.first)}},hostAttrs:[1,"mat-mdc-form-field"],hostVars:38,hostBindings:function(t,n){t&2&&p("mat-mdc-form-field-label-always-float",n._shouldAlwaysFloat())("mat-mdc-form-field-has-icon-prefix",n._hasIconPrefix)("mat-mdc-form-field-has-icon-suffix",n._hasIconSuffix)("mat-form-field-invalid",n._control.errorState)("mat-form-field-disabled",n._control.disabled)("mat-form-field-autofilled",n._control.autofilled)("mat-form-field-appearance-fill",n.appearance=="fill")("mat-form-field-appearance-outline",n.appearance=="outline")("mat-form-field-hide-placeholder",n._hasFloatingLabel()&&!n._shouldLabelFloat())("mat-primary",n.color!=="accent"&&n.color!=="warn")("mat-accent",n.color==="accent")("mat-warn",n.color==="warn")("ng-untouched",n._shouldForward("untouched"))("ng-touched",n._shouldForward("touched"))("ng-pristine",n._shouldForward("pristine"))("ng-dirty",n._shouldForward("dirty"))("ng-valid",n._shouldForward("valid"))("ng-invalid",n._shouldForward("invalid"))("ng-pending",n._shouldForward("pending"))},inputs:{hideRequiredMarker:"hideRequiredMarker",color:"color",floatLabel:"floatLabel",appearance:"appearance",subscriptSizing:"subscriptSizing",hintLabel:"hintLabel"},exportAs:["matFormField"],features:[J([{provide:jn,useExisting:i},{provide:Wu,useExisting:i}])],ngContentSelectors:v_,decls:18,vars:21,consts:[["labelTemplate",""],["textField",""],["iconPrefixContainer",""],["textPrefixContainer",""],["textSuffixContainer",""],["iconSuffixContainer",""],[1,"mat-mdc-text-field-wrapper","mdc-text-field",3,"click"],[1,"mat-mdc-form-field-focus-overlay"],[1,"mat-mdc-form-field-flex"],["matFormFieldNotchedOutline","",3,"matFormFieldNotchedOutlineOpen"],[1,"mat-mdc-form-field-icon-prefix"],[1,"mat-mdc-form-field-text-prefix"],[1,"mat-mdc-form-field-infix"],[3,"ngTemplateOutlet"],[1,"mat-mdc-form-field-text-suffix"],[1,"mat-mdc-form-field-icon-suffix"],["matFormFieldLineRipple",""],["aria-atomic","true","aria-live","polite",1,"mat-mdc-form-field-subscript-wrapper","mat-mdc-form-field-bottom-align"],[1,"mat-mdc-form-field-error-wrapper"],[1,"mat-mdc-form-field-hint-wrapper"],["matFormFieldFloatingLabel","",3,"floating","monitorResize","id"],["aria-hidden","true",1,"mat-mdc-form-field-required-marker","mdc-floating-label--required"],[3,"id"],[1,"mat-mdc-form-field-hint-spacer"]],template:function(t,n){if(t&1&&(ce(__),ze(0,C_,1,1,"ng-template",null,0,Xs),s(2,"div",6,1),A("click",function(r){return n._control.onContainerClick(r)}),M(4,x_,1,0,"div",7),s(5,"div",8),M(6,k_,2,2,"div",9),M(7,S_,3,0,"div",10),M(8,M_,3,0,"div",11),s(9,"div",12),M(10,A_,1,1,null,13),U(11),l(),M(12,T_,3,0,"div",14),M(13,I_,3,0,"div",15),l(),M(14,R_,1,0,"div",16),l(),s(15,"div",17),M(16,O_,2,0,"div",18)(17,F_,5,1,"div",19),l()),t&2){let a;c(2),p("mdc-text-field--filled",!n._hasOutline())("mdc-text-field--outlined",n._hasOutline())("mdc-text-field--no-label",!n._hasFloatingLabel())("mdc-text-field--disabled",n._control.disabled)("mdc-text-field--invalid",n._control.errorState),c(2),E(!n._hasOutline()&&!n._control.disabled?4:-1),c(2),E(n._hasOutline()?6:-1),c(),E(n._hasIconPrefix?7:-1),c(),E(n._hasTextPrefix?8:-1),c(2),E(!n._hasOutline()||n._forceDisplayInfixLabel()?10:-1),c(2),E(n._hasTextSuffix?12:-1),c(),E(n._hasIconSuffix?13:-1),c(),E(n._hasOutline()?-1:14),c(),p("mat-mdc-form-field-subscript-dynamic-size",n.subscriptSizing==="dynamic");let r=n._getSubscriptMessageType();c(),E((a=r)==="error"?16:a==="hint"?17:-1)}},dependencies:[Bu,Hu,sl,ju,es],styles:[`.mdc-text-field {
472
472
  display: inline-flex;
473
473
  align-items: baseline;
474
474
  padding: 0 16px;
@@ -1417,7 +1417,7 @@ select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) optio
1417
1417
  .mdc-notched-outline--upgraded .mdc-floating-label--float-above {
1418
1418
  max-width: calc(133.3333333333% + 1px);
1419
1419
  }
1420
- `],encapsulation:2})}return i})();var yo=(()=>{class i{isErrorState(e,t){return!!(e&&e.invalid&&(e.touched||t&&t.submitted))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Co=class{_defaultMatcher;ngControl;_parentFormGroup;_parentForm;_stateChanges;errorState=!1;matcher;constructor(o,e,t,n,a){this._defaultMatcher=o,this.ngControl=e,this._parentFormGroup=t,this._parentForm=n,this._stateChanges=a}updateErrorState(){let o=this.errorState,e=this._parentFormGroup||this._parentForm,t=this.matcher||this._defaultMatcher,n=this.ngControl?this.ngControl.control:null,a=t?.isErrorState(n,e)??!1;a!==o&&(this.errorState=a,this._stateChanges.next())}};var St=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ho,kt,ee]})}return i})();var G_=["button","checkbox","file","hidden","image","radio","range","reset","submit"],$_=new C("MAT_INPUT_CONFIG"),ei=(()=>{class i{_elementRef=d(N);_platform=d(le);ngControl=d(Jt,{optional:!0,self:!0});_autofillMonitor=d(Em);_ngZone=d(H);_formField=d(Bn,{optional:!0});_renderer=d(ve);_uid=d(be).getId("mat-input-");_previousNativeValue;_inputValueAccessor;_signalBasedValueAccessor;_previousPlaceholder=null;_errorStateTracker;_config=d($_,{optional:!0});_cleanupIosKeyup;_cleanupWebkitWheel;_isServer=!1;_isNativeSelect=!1;_isTextarea=!1;_isInFormField=!1;focused=!1;stateChanges=new I;controlType="mat-input";autofilled=!1;get disabled(){return this._disabled}set disabled(e){this._disabled=mt(e),this.focused&&(this.focused=!1,this.stateChanges.next())}_disabled=!1;get id(){return this._id}set id(e){this._id=e||this._uid}_id;placeholder;name;get required(){return this._required??this.ngControl?.control?.hasValidator(st.required)??!1}set required(e){this._required=mt(e)}_required;get type(){return this._type}set type(e){this._type=e||"text",this._validateType(),!this._isTextarea&&Ol().has(this._type)&&(this._elementRef.nativeElement.type=this._type)}_type="text";get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(e){this._errorStateTracker.matcher=e}userAriaDescribedBy;get value(){return this._signalBasedValueAccessor?this._signalBasedValueAccessor.value():this._inputValueAccessor.value}set value(e){e!==this.value&&(this._signalBasedValueAccessor?this._signalBasedValueAccessor.value.set(e):this._inputValueAccessor.value=e,this.stateChanges.next())}get readonly(){return this._readonly}set readonly(e){this._readonly=mt(e)}_readonly=!1;disabledInteractive;get errorState(){return this._errorStateTracker.errorState}set errorState(e){this._errorStateTracker.errorState=e}_neverEmptyInputTypes=["date","datetime","datetime-local","month","time","week"].filter(e=>Ol().has(e));constructor(){let e=d(_a,{optional:!0}),t=d(Ut,{optional:!0}),n=d(yo),a=d(Ou,{optional:!0,self:!0}),r=this._elementRef.nativeElement,u=r.nodeName.toLowerCase();a?Xi(a.value)?this._signalBasedValueAccessor=a:this._inputValueAccessor=a:this._inputValueAccessor=r,this._previousNativeValue=this.value,this.id=this.id,this._platform.IOS&&this._ngZone.runOutsideAngular(()=>{this._cleanupIosKeyup=this._renderer.listen(r,"keyup",this._iOSKeyupListener)}),this._errorStateTracker=new Co(n,this.ngControl,t,e,this.stateChanges),this._isServer=!this._platform.isBrowser,this._isNativeSelect=u==="select",this._isTextarea=u==="textarea",this._isInFormField=!!this._formField,this.disabledInteractive=this._config?.disabledInteractive||!1,this._isNativeSelect&&(this.controlType=r.multiple?"mat-native-select-multiple":"mat-native-select"),this._signalBasedValueAccessor&&zt(()=>{this._signalBasedValueAccessor.value(),this.stateChanges.next()})}ngAfterViewInit(){this._platform.isBrowser&&this._autofillMonitor.monitor(this._elementRef.nativeElement).subscribe(e=>{this.autofilled=e.isAutofilled,this.stateChanges.next()})}ngOnChanges(){this.stateChanges.next()}ngOnDestroy(){this.stateChanges.complete(),this._platform.isBrowser&&this._autofillMonitor.stopMonitoring(this._elementRef.nativeElement),this._cleanupIosKeyup?.(),this._cleanupWebkitWheel?.()}ngDoCheck(){this.ngControl&&(this.updateErrorState(),this.ngControl.disabled!==null&&this.ngControl.disabled!==this.disabled&&(this.disabled=this.ngControl.disabled,this.stateChanges.next())),this._dirtyCheckNativeValue(),this._dirtyCheckPlaceholder()}focus(e){this._elementRef.nativeElement.focus(e)}updateErrorState(){this._errorStateTracker.updateErrorState()}_focusChanged(e){if(e!==this.focused){if(!this._isNativeSelect&&e&&this.disabled&&this.disabledInteractive){let t=this._elementRef.nativeElement;t.type==="number"?(t.type="text",t.setSelectionRange(0,0),t.type="number"):t.setSelectionRange(0,0)}this.focused=e,this.stateChanges.next()}}_onInput(){}_dirtyCheckNativeValue(){let e=this._elementRef.nativeElement.value;this._previousNativeValue!==e&&(this._previousNativeValue=e,this.stateChanges.next())}_dirtyCheckPlaceholder(){let e=this._getPlaceholder();if(e!==this._previousPlaceholder){let t=this._elementRef.nativeElement;this._previousPlaceholder=e,e?t.setAttribute("placeholder",e):t.removeAttribute("placeholder")}}_getPlaceholder(){return this.placeholder||null}_validateType(){G_.indexOf(this._type)>-1}_isNeverEmpty(){return this._neverEmptyInputTypes.indexOf(this._type)>-1}_isBadInput(){let e=this._elementRef.nativeElement.validity;return e&&e.badInput}get empty(){return!this._isNeverEmpty()&&!this._elementRef.nativeElement.value&&!this._isBadInput()&&!this.autofilled}get shouldLabelFloat(){if(this._isNativeSelect){let e=this._elementRef.nativeElement,t=e.options[0];return this.focused||e.multiple||!this.empty||!!(e.selectedIndex>-1&&t&&t.label)}else return this.focused&&!this.disabled||!this.empty}get describedByIds(){return this._elementRef.nativeElement.getAttribute("aria-describedby")?.split(" ")||[]}setDescribedByIds(e){let t=this._elementRef.nativeElement;e.length?t.setAttribute("aria-describedby",e.join(" ")):t.removeAttribute("aria-describedby")}onContainerClick(){this.focused||this.focus()}_isInlineSelect(){let e=this._elementRef.nativeElement;return this._isNativeSelect&&(e.multiple||e.size>1)}_iOSKeyupListener=e=>{let t=e.target;!t.value&&t.selectionStart===0&&t.selectionEnd===0&&(t.setSelectionRange(1,1),t.setSelectionRange(0,0))};_getReadonlyAttribute(){return this._isNativeSelect?null:this.readonly||this.disabled&&this.disabledInteractive?"true":null}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["input","matInput",""],["textarea","matInput",""],["select","matNativeControl",""],["input","matNativeControl",""],["textarea","matNativeControl",""]],hostAttrs:[1,"mat-mdc-input-element"],hostVars:21,hostBindings:function(t,n){t&1&&A("focus",function(){return n._focusChanged(!0)})("blur",function(){return n._focusChanged(!1)})("input",function(){return n._onInput()}),t&2&&(dt("id",n.id)("disabled",n.disabled&&!n.disabledInteractive)("required",n.required),Z("name",n.name||null)("readonly",n._getReadonlyAttribute())("aria-disabled",n.disabled&&n.disabledInteractive?"true":null)("aria-invalid",n.empty&&n.required?null:n.errorState)("aria-required",n.required)("id",n.id),p("mat-input-server",n._isServer)("mat-mdc-form-field-textarea-control",n._isInFormField&&n._isTextarea)("mat-mdc-form-field-input-control",n._isInFormField)("mat-mdc-input-disabled-interactive",n.disabledInteractive)("mdc-text-field__input",n._isInFormField)("mat-mdc-native-select-inline",n._isInlineSelect()))},inputs:{disabled:"disabled",id:"id",placeholder:"placeholder",name:"name",required:"required",type:"type",errorStateMatcher:"errorStateMatcher",userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],value:"value",readonly:"readonly",disabledInteractive:[2,"disabledInteractive","disabledInteractive",L]},exportAs:["matInput"],features:[J([{provide:ya,useExisting:i}]),Se]})}return i})(),ti=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[St,St,Am,ee]})}return i})();var ii=(function(i){return i[i.FADING_IN=0]="FADING_IN",i[i.VISIBLE=1]="VISIBLE",i[i.FADING_OUT=2]="FADING_OUT",i[i.HIDDEN=3]="HIDDEN",i})(ii||{}),oc=class{_renderer;element;config;_animationForciblyDisabledThroughCss;state=ii.HIDDEN;constructor(o,e,t,n=!1){this._renderer=o,this.element=e,this.config=t,this._animationForciblyDisabledThroughCss=n}fadeOut(){this._renderer.fadeOutRipple(this)}},qu=mo({passive:!0,capture:!0}),ac=class{_events=new Map;addHandler(o,e,t,n){let a=this._events.get(e);if(a){let r=a.get(t);r?r.add(n):a.set(t,new Set([n]))}else this._events.set(e,new Map([[t,new Set([n])]])),o.runOutsideAngular(()=>{document.addEventListener(e,this._delegateEventHandler,qu)})}removeHandler(o,e,t){let n=this._events.get(o);if(!n)return;let a=n.get(e);a&&(a.delete(t),a.size===0&&n.delete(e),n.size===0&&(this._events.delete(o),document.removeEventListener(o,this._delegateEventHandler,qu)))}_delegateEventHandler=o=>{let e=rt(o);e&&this._events.get(o.type)?.forEach((t,n)=>{(n===e||n.contains(e))&&t.forEach(a=>a.handleEvent(o))})}},Ca={enterDuration:225,exitDuration:150},W_=800,Ku=mo({passive:!0,capture:!0}),Yu=["mousedown","touchstart"],Xu=["mouseup","mouseleave","touchend","touchcancel"],q_=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["ng-component"]],hostAttrs:["mat-ripple-style-loader",""],decls:0,vars:0,template:function(t,n){},styles:[`.mat-ripple {
1420
+ `],encapsulation:2})}return i})();var xo=(()=>{class i{isErrorState(e,t){return!!(e&&e.invalid&&(e.touched||t&&t.submitted))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var wo=class{_defaultMatcher;ngControl;_parentFormGroup;_parentForm;_stateChanges;errorState=!1;matcher;constructor(o,e,t,n,a){this._defaultMatcher=o,this.ngControl=e,this._parentFormGroup=t,this._parentForm=n,this._stateChanges=a}updateErrorState(){let o=this.errorState,e=this._parentFormGroup||this._parentForm,t=this.matcher||this._defaultMatcher,n=this.ngControl?this.ngControl.control:null,a=t?.isErrorState(n,e)??!1;a!==o&&(this.errorState=a,this._stateChanges.next())}};var St=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[fo,kt,ee]})}return i})();var G_=["button","checkbox","file","hidden","image","radio","range","reset","submit"],$_=new x("MAT_INPUT_CONFIG"),ei=(()=>{class i{_elementRef=d(N);_platform=d(le);ngControl=d(Jt,{optional:!0,self:!0});_autofillMonitor=d(Em);_ngZone=d(H);_formField=d(jn,{optional:!0});_renderer=d(ve);_uid=d(be).getId("mat-input-");_previousNativeValue;_inputValueAccessor;_signalBasedValueAccessor;_previousPlaceholder=null;_errorStateTracker;_config=d($_,{optional:!0});_cleanupIosKeyup;_cleanupWebkitWheel;_isServer=!1;_isNativeSelect=!1;_isTextarea=!1;_isInFormField=!1;focused=!1;stateChanges=new I;controlType="mat-input";autofilled=!1;get disabled(){return this._disabled}set disabled(e){this._disabled=mt(e),this.focused&&(this.focused=!1,this.stateChanges.next())}_disabled=!1;get id(){return this._id}set id(e){this._id=e||this._uid}_id;placeholder;name;get required(){return this._required??this.ngControl?.control?.hasValidator(st.required)??!1}set required(e){this._required=mt(e)}_required;get type(){return this._type}set type(e){this._type=e||"text",this._validateType(),!this._isTextarea&&Pl().has(this._type)&&(this._elementRef.nativeElement.type=this._type)}_type="text";get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(e){this._errorStateTracker.matcher=e}userAriaDescribedBy;get value(){return this._signalBasedValueAccessor?this._signalBasedValueAccessor.value():this._inputValueAccessor.value}set value(e){e!==this.value&&(this._signalBasedValueAccessor?this._signalBasedValueAccessor.value.set(e):this._inputValueAccessor.value=e,this.stateChanges.next())}get readonly(){return this._readonly}set readonly(e){this._readonly=mt(e)}_readonly=!1;disabledInteractive;get errorState(){return this._errorStateTracker.errorState}set errorState(e){this._errorStateTracker.errorState=e}_neverEmptyInputTypes=["date","datetime","datetime-local","month","time","week"].filter(e=>Pl().has(e));constructor(){let e=d(ba,{optional:!0}),t=d(Ut,{optional:!0}),n=d(xo),a=d(Ou,{optional:!0,self:!0}),r=this._elementRef.nativeElement,u=r.nodeName.toLowerCase();a?Xi(a.value)?this._signalBasedValueAccessor=a:this._inputValueAccessor=a:this._inputValueAccessor=r,this._previousNativeValue=this.value,this.id=this.id,this._platform.IOS&&this._ngZone.runOutsideAngular(()=>{this._cleanupIosKeyup=this._renderer.listen(r,"keyup",this._iOSKeyupListener)}),this._errorStateTracker=new wo(n,this.ngControl,t,e,this.stateChanges),this._isServer=!this._platform.isBrowser,this._isNativeSelect=u==="select",this._isTextarea=u==="textarea",this._isInFormField=!!this._formField,this.disabledInteractive=this._config?.disabledInteractive||!1,this._isNativeSelect&&(this.controlType=r.multiple?"mat-native-select-multiple":"mat-native-select"),this._signalBasedValueAccessor&&zt(()=>{this._signalBasedValueAccessor.value(),this.stateChanges.next()})}ngAfterViewInit(){this._platform.isBrowser&&this._autofillMonitor.monitor(this._elementRef.nativeElement).subscribe(e=>{this.autofilled=e.isAutofilled,this.stateChanges.next()})}ngOnChanges(){this.stateChanges.next()}ngOnDestroy(){this.stateChanges.complete(),this._platform.isBrowser&&this._autofillMonitor.stopMonitoring(this._elementRef.nativeElement),this._cleanupIosKeyup?.(),this._cleanupWebkitWheel?.()}ngDoCheck(){this.ngControl&&(this.updateErrorState(),this.ngControl.disabled!==null&&this.ngControl.disabled!==this.disabled&&(this.disabled=this.ngControl.disabled,this.stateChanges.next())),this._dirtyCheckNativeValue(),this._dirtyCheckPlaceholder()}focus(e){this._elementRef.nativeElement.focus(e)}updateErrorState(){this._errorStateTracker.updateErrorState()}_focusChanged(e){if(e!==this.focused){if(!this._isNativeSelect&&e&&this.disabled&&this.disabledInteractive){let t=this._elementRef.nativeElement;t.type==="number"?(t.type="text",t.setSelectionRange(0,0),t.type="number"):t.setSelectionRange(0,0)}this.focused=e,this.stateChanges.next()}}_onInput(){}_dirtyCheckNativeValue(){let e=this._elementRef.nativeElement.value;this._previousNativeValue!==e&&(this._previousNativeValue=e,this.stateChanges.next())}_dirtyCheckPlaceholder(){let e=this._getPlaceholder();if(e!==this._previousPlaceholder){let t=this._elementRef.nativeElement;this._previousPlaceholder=e,e?t.setAttribute("placeholder",e):t.removeAttribute("placeholder")}}_getPlaceholder(){return this.placeholder||null}_validateType(){G_.indexOf(this._type)>-1}_isNeverEmpty(){return this._neverEmptyInputTypes.indexOf(this._type)>-1}_isBadInput(){let e=this._elementRef.nativeElement.validity;return e&&e.badInput}get empty(){return!this._isNeverEmpty()&&!this._elementRef.nativeElement.value&&!this._isBadInput()&&!this.autofilled}get shouldLabelFloat(){if(this._isNativeSelect){let e=this._elementRef.nativeElement,t=e.options[0];return this.focused||e.multiple||!this.empty||!!(e.selectedIndex>-1&&t&&t.label)}else return this.focused&&!this.disabled||!this.empty}get describedByIds(){return this._elementRef.nativeElement.getAttribute("aria-describedby")?.split(" ")||[]}setDescribedByIds(e){let t=this._elementRef.nativeElement;e.length?t.setAttribute("aria-describedby",e.join(" ")):t.removeAttribute("aria-describedby")}onContainerClick(){this.focused||this.focus()}_isInlineSelect(){let e=this._elementRef.nativeElement;return this._isNativeSelect&&(e.multiple||e.size>1)}_iOSKeyupListener=e=>{let t=e.target;!t.value&&t.selectionStart===0&&t.selectionEnd===0&&(t.setSelectionRange(1,1),t.setSelectionRange(0,0))};_getReadonlyAttribute(){return this._isNativeSelect?null:this.readonly||this.disabled&&this.disabledInteractive?"true":null}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["input","matInput",""],["textarea","matInput",""],["select","matNativeControl",""],["input","matNativeControl",""],["textarea","matNativeControl",""]],hostAttrs:[1,"mat-mdc-input-element"],hostVars:21,hostBindings:function(t,n){t&1&&A("focus",function(){return n._focusChanged(!0)})("blur",function(){return n._focusChanged(!1)})("input",function(){return n._onInput()}),t&2&&(dt("id",n.id)("disabled",n.disabled&&!n.disabledInteractive)("required",n.required),Z("name",n.name||null)("readonly",n._getReadonlyAttribute())("aria-disabled",n.disabled&&n.disabledInteractive?"true":null)("aria-invalid",n.empty&&n.required?null:n.errorState)("aria-required",n.required)("id",n.id),p("mat-input-server",n._isServer)("mat-mdc-form-field-textarea-control",n._isInFormField&&n._isTextarea)("mat-mdc-form-field-input-control",n._isInFormField)("mat-mdc-input-disabled-interactive",n.disabledInteractive)("mdc-text-field__input",n._isInFormField)("mat-mdc-native-select-inline",n._isInlineSelect()))},inputs:{disabled:"disabled",id:"id",placeholder:"placeholder",name:"name",required:"required",type:"type",errorStateMatcher:"errorStateMatcher",userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],value:"value",readonly:"readonly",disabledInteractive:[2,"disabledInteractive","disabledInteractive",L]},exportAs:["matInput"],features:[J([{provide:xa,useExisting:i}]),Se]})}return i})(),ti=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[St,St,Am,ee]})}return i})();var ii=(function(i){return i[i.FADING_IN=0]="FADING_IN",i[i.VISIBLE=1]="VISIBLE",i[i.FADING_OUT=2]="FADING_OUT",i[i.HIDDEN=3]="HIDDEN",i})(ii||{}),ac=class{_renderer;element;config;_animationForciblyDisabledThroughCss;state=ii.HIDDEN;constructor(o,e,t,n=!1){this._renderer=o,this.element=e,this.config=t,this._animationForciblyDisabledThroughCss=n}fadeOut(){this._renderer.fadeOutRipple(this)}},qu=ho({passive:!0,capture:!0}),rc=class{_events=new Map;addHandler(o,e,t,n){let a=this._events.get(e);if(a){let r=a.get(t);r?r.add(n):a.set(t,new Set([n]))}else this._events.set(e,new Map([[t,new Set([n])]])),o.runOutsideAngular(()=>{document.addEventListener(e,this._delegateEventHandler,qu)})}removeHandler(o,e,t){let n=this._events.get(o);if(!n)return;let a=n.get(e);a&&(a.delete(t),a.size===0&&n.delete(e),n.size===0&&(this._events.delete(o),document.removeEventListener(o,this._delegateEventHandler,qu)))}_delegateEventHandler=o=>{let e=rt(o);e&&this._events.get(o.type)?.forEach((t,n)=>{(n===e||n.contains(e))&&t.forEach(a=>a.handleEvent(o))})}},wa={enterDuration:225,exitDuration:150},W_=800,Ku=ho({passive:!0,capture:!0}),Yu=["mousedown","touchstart"],Xu=["mouseup","mouseleave","touchend","touchcancel"],q_=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["ng-component"]],hostAttrs:["mat-ripple-style-loader",""],decls:0,vars:0,template:function(t,n){},styles:[`.mat-ripple {
1421
1421
  overflow: hidden;
1422
1422
  position: relative;
1423
1423
  }
@@ -1445,7 +1445,7 @@ select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) optio
1445
1445
  .cdk-drag-preview .mat-ripple-element, .cdk-drag-placeholder .mat-ripple-element {
1446
1446
  display: none;
1447
1447
  }
1448
- `],encapsulation:2})}return i})(),zn=class i{_target;_ngZone;_platform;_containerElement;_triggerElement=null;_isPointerDown=!1;_activeRipples=new Map;_mostRecentTransientRipple=null;_lastTouchStartEvent;_pointerUpEventsRegistered=!1;_containerRect=null;static _eventManager=new ac;constructor(o,e,t,n,a){this._target=o,this._ngZone=e,this._platform=n,n.isBrowser&&(this._containerElement=Dt(t)),a&&a.get(Fe).load(q_)}fadeInRipple(o,e,t={}){let n=this._containerRect=this._containerRect||this._containerElement.getBoundingClientRect(),a=V(V({},Ca),t.animation);t.centered&&(o=n.left+n.width/2,e=n.top+n.height/2);let r=t.radius||K_(o,e,n),u=o-n.left,h=e-n.top,g=a.enterDuration,_=document.createElement("div");_.classList.add("mat-ripple-element"),_.style.left=`${u-r}px`,_.style.top=`${h-r}px`,_.style.height=`${r*2}px`,_.style.width=`${r*2}px`,t.color!=null&&(_.style.backgroundColor=t.color),_.style.transitionDuration=`${g}ms`,this._containerElement.appendChild(_);let w=window.getComputedStyle(_),B=w.transitionProperty,G=w.transitionDuration,ie=B==="none"||G==="0s"||G==="0s, 0s"||n.width===0&&n.height===0,fe=new oc(this,_,t,ie);_.style.transform="scale3d(1, 1, 1)",fe.state=ii.FADING_IN,t.persistent||(this._mostRecentTransientRipple=fe);let se=null;return!ie&&(g||a.exitDuration)&&this._ngZone.runOutsideAngular(()=>{let Ae=()=>{se&&(se.fallbackTimer=null),clearTimeout(li),this._finishRippleTransition(fe)},lt=()=>this._destroyRipple(fe),li=setTimeout(lt,g+100);_.addEventListener("transitionend",Ae),_.addEventListener("transitioncancel",lt),se={onTransitionEnd:Ae,onTransitionCancel:lt,fallbackTimer:li}}),this._activeRipples.set(fe,se),(ie||!g)&&this._finishRippleTransition(fe),fe}fadeOutRipple(o){if(o.state===ii.FADING_OUT||o.state===ii.HIDDEN)return;let e=o.element,t=V(V({},Ca),o.config.animation);e.style.transitionDuration=`${t.exitDuration}ms`,e.style.opacity="0",o.state=ii.FADING_OUT,(o._animationForciblyDisabledThroughCss||!t.exitDuration)&&this._finishRippleTransition(o)}fadeOutAll(){this._getActiveRipples().forEach(o=>o.fadeOut())}fadeOutAllNonPersistent(){this._getActiveRipples().forEach(o=>{o.config.persistent||o.fadeOut()})}setupTriggerEvents(o){let e=Dt(o);!this._platform.isBrowser||!e||e===this._triggerElement||(this._removeTriggerEvents(),this._triggerElement=e,Yu.forEach(t=>{i._eventManager.addHandler(this._ngZone,t,e,this)}))}handleEvent(o){o.type==="mousedown"?this._onMousedown(o):o.type==="touchstart"?this._onTouchStart(o):this._onPointerUp(),this._pointerUpEventsRegistered||(this._ngZone.runOutsideAngular(()=>{Xu.forEach(e=>{this._triggerElement.addEventListener(e,this,Ku)})}),this._pointerUpEventsRegistered=!0)}_finishRippleTransition(o){o.state===ii.FADING_IN?this._startFadeOutTransition(o):o.state===ii.FADING_OUT&&this._destroyRipple(o)}_startFadeOutTransition(o){let e=o===this._mostRecentTransientRipple,{persistent:t}=o.config;o.state=ii.VISIBLE,!t&&(!e||!this._isPointerDown)&&o.fadeOut()}_destroyRipple(o){let e=this._activeRipples.get(o)??null;this._activeRipples.delete(o),this._activeRipples.size||(this._containerRect=null),o===this._mostRecentTransientRipple&&(this._mostRecentTransientRipple=null),o.state=ii.HIDDEN,e!==null&&(o.element.removeEventListener("transitionend",e.onTransitionEnd),o.element.removeEventListener("transitioncancel",e.onTransitionCancel),e.fallbackTimer!==null&&clearTimeout(e.fallbackTimer)),o.element.remove()}_onMousedown(o){let e=On(o),t=this._lastTouchStartEvent&&Date.now()<this._lastTouchStartEvent+W_;!this._target.rippleDisabled&&!e&&!t&&(this._isPointerDown=!0,this.fadeInRipple(o.clientX,o.clientY,this._target.rippleConfig))}_onTouchStart(o){if(!this._target.rippleDisabled&&!Pn(o)){this._lastTouchStartEvent=Date.now(),this._isPointerDown=!0;let e=o.changedTouches;if(e)for(let t=0;t<e.length;t++)this.fadeInRipple(e[t].clientX,e[t].clientY,this._target.rippleConfig)}}_onPointerUp(){this._isPointerDown&&(this._isPointerDown=!1,this._getActiveRipples().forEach(o=>{let e=o.state===ii.VISIBLE||o.config.terminateOnPointerUp&&o.state===ii.FADING_IN;!o.config.persistent&&e&&o.fadeOut()}))}_getActiveRipples(){return Array.from(this._activeRipples.keys())}_removeTriggerEvents(){let o=this._triggerElement;o&&(Yu.forEach(e=>i._eventManager.removeHandler(e,o,this)),this._pointerUpEventsRegistered&&(Xu.forEach(e=>o.removeEventListener(e,this,Ku)),this._pointerUpEventsRegistered=!1))}};function K_(i,o,e){let t=Math.max(Math.abs(i-e.left),Math.abs(i-e.right)),n=Math.max(Math.abs(o-e.top),Math.abs(o-e.bottom));return Math.sqrt(t*t+n*n)}var jn=new C("mat-ripple-global-options"),wo=(()=>{class i{_elementRef=d(N);_animationsDisabled=pe();color;unbounded=!1;centered=!1;radius=0;animation;get disabled(){return this._disabled}set disabled(e){e&&this.fadeOutAllNonPersistent(),this._disabled=e,this._setupTriggerEventsIfEnabled()}_disabled=!1;get trigger(){return this._trigger||this._elementRef.nativeElement}set trigger(e){this._trigger=e,this._setupTriggerEventsIfEnabled()}_trigger;_rippleRenderer;_globalOptions;_isInitialized=!1;constructor(){let e=d(H),t=d(le),n=d(jn,{optional:!0}),a=d(X);this._globalOptions=n||{},this._rippleRenderer=new zn(this,e,this._elementRef,t,a)}ngOnInit(){this._isInitialized=!0,this._setupTriggerEventsIfEnabled()}ngOnDestroy(){this._rippleRenderer._removeTriggerEvents()}fadeOutAll(){this._rippleRenderer.fadeOutAll()}fadeOutAllNonPersistent(){this._rippleRenderer.fadeOutAllNonPersistent()}get rippleConfig(){return{centered:this.centered,radius:this.radius,color:this.color,animation:V(V(V({},this._globalOptions.animation),this._animationsDisabled?{enterDuration:0,exitDuration:0}:{}),this.animation),terminateOnPointerUp:this._globalOptions.terminateOnPointerUp}}get rippleDisabled(){return this.disabled||!!this._globalOptions.disabled}_setupTriggerEventsIfEnabled(){!this.disabled&&this._isInitialized&&this._rippleRenderer.setupTriggerEvents(this.trigger)}launch(e,t=0,n){return typeof e=="number"?this._rippleRenderer.fadeInRipple(e,t,V(V({},this.rippleConfig),n)):this._rippleRenderer.fadeInRipple(0,0,V(V({},this.rippleConfig),e))}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","mat-ripple",""],["","matRipple",""]],hostAttrs:[1,"mat-ripple"],hostVars:2,hostBindings:function(t,n){t&2&&p("mat-ripple-unbounded",n.unbounded)},inputs:{color:[0,"matRippleColor","color"],unbounded:[0,"matRippleUnbounded","unbounded"],centered:[0,"matRippleCentered","centered"],radius:[0,"matRippleRadius","radius"],animation:[0,"matRippleAnimation","animation"],disabled:[0,"matRippleDisabled","disabled"],trigger:[0,"matRippleTrigger","trigger"]},exportAs:["matRipple"]})}return i})();var Y_={capture:!0},X_=["focus","mousedown","mouseenter","touchstart"],rc="mat-ripple-loader-uninitialized",sc="mat-ripple-loader-class-name",Zu="mat-ripple-loader-centered",Qr="mat-ripple-loader-disabled",Jr=(()=>{class i{_document=d($);_animationsDisabled=pe();_globalRippleOptions=d(jn,{optional:!0});_platform=d(le);_ngZone=d(H);_injector=d(X);_eventCleanups;_hosts=new Map;constructor(){let e=d(ot).createRenderer(null,null);this._eventCleanups=this._ngZone.runOutsideAngular(()=>X_.map(t=>e.listen(this._document,t,this._onInteraction,Y_)))}ngOnDestroy(){let e=this._hosts.keys();for(let t of e)this.destroyRipple(t);this._eventCleanups.forEach(t=>t())}configureRipple(e,t){e.setAttribute(rc,this._globalRippleOptions?.namespace??""),(t.className||!e.hasAttribute(sc))&&e.setAttribute(sc,t.className||""),t.centered&&e.setAttribute(Zu,""),t.disabled&&e.setAttribute(Qr,"")}setDisabled(e,t){let n=this._hosts.get(e);n?(n.target.rippleDisabled=t,!t&&!n.hasSetUpEvents&&(n.hasSetUpEvents=!0,n.renderer.setupTriggerEvents(e))):t?e.setAttribute(Qr,""):e.removeAttribute(Qr)}_onInteraction=e=>{let t=rt(e);if(t instanceof HTMLElement){let n=t.closest(`[${rc}="${this._globalRippleOptions?.namespace??""}"]`);n&&this._createRipple(n)}};_createRipple(e){if(!this._document||this._hosts.has(e))return;e.querySelector(".mat-ripple")?.remove();let t=this._document.createElement("span");t.classList.add("mat-ripple",e.getAttribute(sc)),e.append(t);let n=this._globalRippleOptions,a=this._animationsDisabled?0:n?.animation?.enterDuration??Ca.enterDuration,r=this._animationsDisabled?0:n?.animation?.exitDuration??Ca.exitDuration,u={rippleDisabled:this._animationsDisabled||n?.disabled||e.hasAttribute(Qr),rippleConfig:{centered:e.hasAttribute(Zu),terminateOnPointerUp:n?.terminateOnPointerUp,animation:{enterDuration:a,exitDuration:r}}},h=new zn(u,this._ngZone,t,this._platform,this._injector),g=!u.rippleDisabled;g&&h.setupTriggerEvents(e),this._hosts.set(e,{target:u,renderer:h,hasSetUpEvents:g}),e.removeAttribute(rc)}destroyRipple(e){let t=this._hosts.get(e);t&&(t.renderer._removeTriggerEvents(),this._hosts.delete(e))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Mt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["structural-styles"]],decls:0,vars:0,template:function(t,n){},styles:[`.mat-focus-indicator {
1448
+ `],encapsulation:2})}return i})(),Hn=class i{_target;_ngZone;_platform;_containerElement;_triggerElement=null;_isPointerDown=!1;_activeRipples=new Map;_mostRecentTransientRipple=null;_lastTouchStartEvent;_pointerUpEventsRegistered=!1;_containerRect=null;static _eventManager=new rc;constructor(o,e,t,n,a){this._target=o,this._ngZone=e,this._platform=n,n.isBrowser&&(this._containerElement=Dt(t)),a&&a.get(Ne).load(q_)}fadeInRipple(o,e,t={}){let n=this._containerRect=this._containerRect||this._containerElement.getBoundingClientRect(),a=V(V({},wa),t.animation);t.centered&&(o=n.left+n.width/2,e=n.top+n.height/2);let r=t.radius||K_(o,e,n),u=o-n.left,h=e-n.top,g=a.enterDuration,_=document.createElement("div");_.classList.add("mat-ripple-element"),_.style.left=`${u-r}px`,_.style.top=`${h-r}px`,_.style.height=`${r*2}px`,_.style.width=`${r*2}px`,t.color!=null&&(_.style.backgroundColor=t.color),_.style.transitionDuration=`${g}ms`,this._containerElement.appendChild(_);let w=window.getComputedStyle(_),B=w.transitionProperty,G=w.transitionDuration,ie=B==="none"||G==="0s"||G==="0s, 0s"||n.width===0&&n.height===0,fe=new ac(this,_,t,ie);_.style.transform="scale3d(1, 1, 1)",fe.state=ii.FADING_IN,t.persistent||(this._mostRecentTransientRipple=fe);let se=null;return!ie&&(g||a.exitDuration)&&this._ngZone.runOutsideAngular(()=>{let Ae=()=>{se&&(se.fallbackTimer=null),clearTimeout(li),this._finishRippleTransition(fe)},lt=()=>this._destroyRipple(fe),li=setTimeout(lt,g+100);_.addEventListener("transitionend",Ae),_.addEventListener("transitioncancel",lt),se={onTransitionEnd:Ae,onTransitionCancel:lt,fallbackTimer:li}}),this._activeRipples.set(fe,se),(ie||!g)&&this._finishRippleTransition(fe),fe}fadeOutRipple(o){if(o.state===ii.FADING_OUT||o.state===ii.HIDDEN)return;let e=o.element,t=V(V({},wa),o.config.animation);e.style.transitionDuration=`${t.exitDuration}ms`,e.style.opacity="0",o.state=ii.FADING_OUT,(o._animationForciblyDisabledThroughCss||!t.exitDuration)&&this._finishRippleTransition(o)}fadeOutAll(){this._getActiveRipples().forEach(o=>o.fadeOut())}fadeOutAllNonPersistent(){this._getActiveRipples().forEach(o=>{o.config.persistent||o.fadeOut()})}setupTriggerEvents(o){let e=Dt(o);!this._platform.isBrowser||!e||e===this._triggerElement||(this._removeTriggerEvents(),this._triggerElement=e,Yu.forEach(t=>{i._eventManager.addHandler(this._ngZone,t,e,this)}))}handleEvent(o){o.type==="mousedown"?this._onMousedown(o):o.type==="touchstart"?this._onTouchStart(o):this._onPointerUp(),this._pointerUpEventsRegistered||(this._ngZone.runOutsideAngular(()=>{Xu.forEach(e=>{this._triggerElement.addEventListener(e,this,Ku)})}),this._pointerUpEventsRegistered=!0)}_finishRippleTransition(o){o.state===ii.FADING_IN?this._startFadeOutTransition(o):o.state===ii.FADING_OUT&&this._destroyRipple(o)}_startFadeOutTransition(o){let e=o===this._mostRecentTransientRipple,{persistent:t}=o.config;o.state=ii.VISIBLE,!t&&(!e||!this._isPointerDown)&&o.fadeOut()}_destroyRipple(o){let e=this._activeRipples.get(o)??null;this._activeRipples.delete(o),this._activeRipples.size||(this._containerRect=null),o===this._mostRecentTransientRipple&&(this._mostRecentTransientRipple=null),o.state=ii.HIDDEN,e!==null&&(o.element.removeEventListener("transitionend",e.onTransitionEnd),o.element.removeEventListener("transitioncancel",e.onTransitionCancel),e.fallbackTimer!==null&&clearTimeout(e.fallbackTimer)),o.element.remove()}_onMousedown(o){let e=Fn(o),t=this._lastTouchStartEvent&&Date.now()<this._lastTouchStartEvent+W_;!this._target.rippleDisabled&&!e&&!t&&(this._isPointerDown=!0,this.fadeInRipple(o.clientX,o.clientY,this._target.rippleConfig))}_onTouchStart(o){if(!this._target.rippleDisabled&&!Nn(o)){this._lastTouchStartEvent=Date.now(),this._isPointerDown=!0;let e=o.changedTouches;if(e)for(let t=0;t<e.length;t++)this.fadeInRipple(e[t].clientX,e[t].clientY,this._target.rippleConfig)}}_onPointerUp(){this._isPointerDown&&(this._isPointerDown=!1,this._getActiveRipples().forEach(o=>{let e=o.state===ii.VISIBLE||o.config.terminateOnPointerUp&&o.state===ii.FADING_IN;!o.config.persistent&&e&&o.fadeOut()}))}_getActiveRipples(){return Array.from(this._activeRipples.keys())}_removeTriggerEvents(){let o=this._triggerElement;o&&(Yu.forEach(e=>i._eventManager.removeHandler(e,o,this)),this._pointerUpEventsRegistered&&(Xu.forEach(e=>o.removeEventListener(e,this,Ku)),this._pointerUpEventsRegistered=!1))}};function K_(i,o,e){let t=Math.max(Math.abs(i-e.left),Math.abs(i-e.right)),n=Math.max(Math.abs(o-e.top),Math.abs(o-e.bottom));return Math.sqrt(t*t+n*n)}var Un=new x("mat-ripple-global-options"),ko=(()=>{class i{_elementRef=d(N);_animationsDisabled=pe();color;unbounded=!1;centered=!1;radius=0;animation;get disabled(){return this._disabled}set disabled(e){e&&this.fadeOutAllNonPersistent(),this._disabled=e,this._setupTriggerEventsIfEnabled()}_disabled=!1;get trigger(){return this._trigger||this._elementRef.nativeElement}set trigger(e){this._trigger=e,this._setupTriggerEventsIfEnabled()}_trigger;_rippleRenderer;_globalOptions;_isInitialized=!1;constructor(){let e=d(H),t=d(le),n=d(Un,{optional:!0}),a=d(X);this._globalOptions=n||{},this._rippleRenderer=new Hn(this,e,this._elementRef,t,a)}ngOnInit(){this._isInitialized=!0,this._setupTriggerEventsIfEnabled()}ngOnDestroy(){this._rippleRenderer._removeTriggerEvents()}fadeOutAll(){this._rippleRenderer.fadeOutAll()}fadeOutAllNonPersistent(){this._rippleRenderer.fadeOutAllNonPersistent()}get rippleConfig(){return{centered:this.centered,radius:this.radius,color:this.color,animation:V(V(V({},this._globalOptions.animation),this._animationsDisabled?{enterDuration:0,exitDuration:0}:{}),this.animation),terminateOnPointerUp:this._globalOptions.terminateOnPointerUp}}get rippleDisabled(){return this.disabled||!!this._globalOptions.disabled}_setupTriggerEventsIfEnabled(){!this.disabled&&this._isInitialized&&this._rippleRenderer.setupTriggerEvents(this.trigger)}launch(e,t=0,n){return typeof e=="number"?this._rippleRenderer.fadeInRipple(e,t,V(V({},this.rippleConfig),n)):this._rippleRenderer.fadeInRipple(0,0,V(V({},this.rippleConfig),e))}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","mat-ripple",""],["","matRipple",""]],hostAttrs:[1,"mat-ripple"],hostVars:2,hostBindings:function(t,n){t&2&&p("mat-ripple-unbounded",n.unbounded)},inputs:{color:[0,"matRippleColor","color"],unbounded:[0,"matRippleUnbounded","unbounded"],centered:[0,"matRippleCentered","centered"],radius:[0,"matRippleRadius","radius"],animation:[0,"matRippleAnimation","animation"],disabled:[0,"matRippleDisabled","disabled"],trigger:[0,"matRippleTrigger","trigger"]},exportAs:["matRipple"]})}return i})();var Y_={capture:!0},X_=["focus","mousedown","mouseenter","touchstart"],sc="mat-ripple-loader-uninitialized",lc="mat-ripple-loader-class-name",Zu="mat-ripple-loader-centered",ts="mat-ripple-loader-disabled",is=(()=>{class i{_document=d(W);_animationsDisabled=pe();_globalRippleOptions=d(Un,{optional:!0});_platform=d(le);_ngZone=d(H);_injector=d(X);_eventCleanups;_hosts=new Map;constructor(){let e=d(ot).createRenderer(null,null);this._eventCleanups=this._ngZone.runOutsideAngular(()=>X_.map(t=>e.listen(this._document,t,this._onInteraction,Y_)))}ngOnDestroy(){let e=this._hosts.keys();for(let t of e)this.destroyRipple(t);this._eventCleanups.forEach(t=>t())}configureRipple(e,t){e.setAttribute(sc,this._globalRippleOptions?.namespace??""),(t.className||!e.hasAttribute(lc))&&e.setAttribute(lc,t.className||""),t.centered&&e.setAttribute(Zu,""),t.disabled&&e.setAttribute(ts,"")}setDisabled(e,t){let n=this._hosts.get(e);n?(n.target.rippleDisabled=t,!t&&!n.hasSetUpEvents&&(n.hasSetUpEvents=!0,n.renderer.setupTriggerEvents(e))):t?e.setAttribute(ts,""):e.removeAttribute(ts)}_onInteraction=e=>{let t=rt(e);if(t instanceof HTMLElement){let n=t.closest(`[${sc}="${this._globalRippleOptions?.namespace??""}"]`);n&&this._createRipple(n)}};_createRipple(e){if(!this._document||this._hosts.has(e))return;e.querySelector(".mat-ripple")?.remove();let t=this._document.createElement("span");t.classList.add("mat-ripple",e.getAttribute(lc)),e.append(t);let n=this._globalRippleOptions,a=this._animationsDisabled?0:n?.animation?.enterDuration??wa.enterDuration,r=this._animationsDisabled?0:n?.animation?.exitDuration??wa.exitDuration,u={rippleDisabled:this._animationsDisabled||n?.disabled||e.hasAttribute(ts),rippleConfig:{centered:e.hasAttribute(Zu),terminateOnPointerUp:n?.terminateOnPointerUp,animation:{enterDuration:a,exitDuration:r}}},h=new Hn(u,this._ngZone,t,this._platform,this._injector),g=!u.rippleDisabled;g&&h.setupTriggerEvents(e),this._hosts.set(e,{target:u,renderer:h,hasSetUpEvents:g}),e.removeAttribute(sc)}destroyRipple(e){let t=this._hosts.get(e);t&&(t.renderer._removeTriggerEvents(),this._hosts.delete(e))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Mt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["structural-styles"]],decls:0,vars:0,template:function(t,n){},styles:[`.mat-focus-indicator {
1449
1449
  position: relative;
1450
1450
  }
1451
1451
  .mat-focus-indicator::before {
@@ -1471,7 +1471,7 @@ select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) optio
1471
1471
  --mat-focus-indicator-display: block;
1472
1472
  }
1473
1473
  }
1474
- `],encapsulation:2})}return i})();var Z_=["*",[["","progressIndicator",""]]],Q_=["*","[progressIndicator]"];function J_(i,o){i&1&&(Ie(0,"div",1),U(1,1),je())}var ev=new C("MAT_BUTTON_CONFIG");function Qu(i){return i==null?void 0:wt(i)}var lc=(()=>{class i{_elementRef=d(N);_ngZone=d(H);_animationsDisabled=pe();_config=d(ev,{optional:!0});_focusMonitor=d(Rt);_cleanupClick;_renderer=d(ve);_rippleLoader=d(Jr);_isAnchor;_isFab=!1;color;get disableRipple(){return this._disableRipple}set disableRipple(e){this._disableRipple=e,this._updateRippleDisabled()}_disableRipple=!1;get disabled(){return this._disabled}set disabled(e){this._disabled=e,this._updateRippleDisabled()}_disabled=!1;ariaDisabled;disabledInteractive;tabIndex;set _tabindex(e){this.tabIndex=e}showProgress=no(!1,{transform:L});constructor(){d(Fe).load(Mt);let e=this._elementRef.nativeElement;this._isAnchor=e.tagName==="A",this.disabledInteractive=this._config?.disabledInteractive??!1,this.color=this._config?.color??null,this._rippleLoader?.configureRipple(e,{className:"mat-mdc-button-ripple"})}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0),this._isAnchor&&this._setupAsAnchor()}ngOnDestroy(){this._cleanupClick?.(),this._focusMonitor.stopMonitoring(this._elementRef),this._rippleLoader?.destroyRipple(this._elementRef.nativeElement)}focus(e="program",t){e?this._focusMonitor.focusVia(this._elementRef.nativeElement,e,t):this._elementRef.nativeElement.focus(t)}_getAriaDisabled(){return this.ariaDisabled!=null?this.ariaDisabled:this._isAnchor?this.disabled||null:this.disabled&&this.disabledInteractive?!0:null}_getDisabledAttribute(){return this.disabledInteractive||!this.disabled?null:!0}_updateRippleDisabled(){this._rippleLoader?.setDisabled(this._elementRef.nativeElement,this.disableRipple||this.disabled)}_getTabIndex(){return this._isAnchor?this.disabled&&!this.disabledInteractive?-1:this.tabIndex:this.tabIndex}_setupAsAnchor(){this._cleanupClick=this._ngZone.runOutsideAngular(()=>this._renderer.listen(this._elementRef.nativeElement,"click",e=>{this.disabled&&(e.preventDefault(),e.stopImmediatePropagation())}))}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,hostAttrs:[1,"mat-mdc-button-base"],hostVars:15,hostBindings:function(t,n){t&2&&(Z("disabled",n._getDisabledAttribute())("aria-disabled",n._getAriaDisabled())("tabindex",n._getTabIndex()),et(n.color?"mat-"+n.color:""),p("mat-mdc-button-progress-indicator-shown",n.showProgress())("mat-mdc-button-disabled",n.disabled)("mat-mdc-button-disabled-interactive",n.disabledInteractive)("mat-unthemed",!n.color)("_mat-animation-noopable",n._animationsDisabled))},inputs:{color:"color",disableRipple:[2,"disableRipple","disableRipple",L],disabled:[2,"disabled","disabled",L],ariaDisabled:[2,"aria-disabled","ariaDisabled",L],disabledInteractive:[2,"disabledInteractive","disabledInteractive",L],tabIndex:[2,"tabIndex","tabIndex",Qu],_tabindex:[2,"tabindex","_tabindex",Qu],showProgress:[1,"showProgress"]}})}return i})(),Hi=(()=>{class i extends lc{constructor(){super(),this._rippleLoader.configureRipple(this._elementRef.nativeElement,{centered:!0})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["button","mat-icon-button",""],["a","mat-icon-button",""],["button","matIconButton",""],["a","matIconButton",""]],hostAttrs:[1,"mdc-icon-button","mat-mdc-icon-button"],exportAs:["matButton","matAnchor"],features:[Q],ngContentSelectors:Q_,decls:5,vars:1,consts:[[1,"mat-mdc-button-persistent-ripple","mdc-icon-button__ripple"],[1,"mat-mdc-button-progress-indicator-container"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(t,n){t&1&&(ce(Z_),ht(0,"span",0),U(1),M(2,J_,2,0,"div",1),ht(3,"span",2)(4,"span",3)),t&2&&(c(2),E(n.showProgress()?2:-1))},styles:[`.mat-mdc-icon-button {
1474
+ `],encapsulation:2})}return i})();var Z_=["*",[["","progressIndicator",""]]],Q_=["*","[progressIndicator]"];function J_(i,o){i&1&&(Ie(0,"div",1),U(1,1),je())}var ev=new x("MAT_BUTTON_CONFIG");function Qu(i){return i==null?void 0:wt(i)}var cc=(()=>{class i{_elementRef=d(N);_ngZone=d(H);_animationsDisabled=pe();_config=d(ev,{optional:!0});_focusMonitor=d(Rt);_cleanupClick;_renderer=d(ve);_rippleLoader=d(is);_isAnchor;_isFab=!1;color;get disableRipple(){return this._disableRipple}set disableRipple(e){this._disableRipple=e,this._updateRippleDisabled()}_disableRipple=!1;get disabled(){return this._disabled}set disabled(e){this._disabled=e,this._updateRippleDisabled()}_disabled=!1;ariaDisabled;disabledInteractive;tabIndex;set _tabindex(e){this.tabIndex=e}showProgress=ao(!1,{transform:L});constructor(){d(Ne).load(Mt);let e=this._elementRef.nativeElement;this._isAnchor=e.tagName==="A",this.disabledInteractive=this._config?.disabledInteractive??!1,this.color=this._config?.color??null,this._rippleLoader?.configureRipple(e,{className:"mat-mdc-button-ripple"})}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0),this._isAnchor&&this._setupAsAnchor()}ngOnDestroy(){this._cleanupClick?.(),this._focusMonitor.stopMonitoring(this._elementRef),this._rippleLoader?.destroyRipple(this._elementRef.nativeElement)}focus(e="program",t){e?this._focusMonitor.focusVia(this._elementRef.nativeElement,e,t):this._elementRef.nativeElement.focus(t)}_getAriaDisabled(){return this.ariaDisabled!=null?this.ariaDisabled:this._isAnchor?this.disabled||null:this.disabled&&this.disabledInteractive?!0:null}_getDisabledAttribute(){return this.disabledInteractive||!this.disabled?null:!0}_updateRippleDisabled(){this._rippleLoader?.setDisabled(this._elementRef.nativeElement,this.disableRipple||this.disabled)}_getTabIndex(){return this._isAnchor?this.disabled&&!this.disabledInteractive?-1:this.tabIndex:this.tabIndex}_setupAsAnchor(){this._cleanupClick=this._ngZone.runOutsideAngular(()=>this._renderer.listen(this._elementRef.nativeElement,"click",e=>{this.disabled&&(e.preventDefault(),e.stopImmediatePropagation())}))}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,hostAttrs:[1,"mat-mdc-button-base"],hostVars:15,hostBindings:function(t,n){t&2&&(Z("disabled",n._getDisabledAttribute())("aria-disabled",n._getAriaDisabled())("tabindex",n._getTabIndex()),et(n.color?"mat-"+n.color:""),p("mat-mdc-button-progress-indicator-shown",n.showProgress())("mat-mdc-button-disabled",n.disabled)("mat-mdc-button-disabled-interactive",n.disabledInteractive)("mat-unthemed",!n.color)("_mat-animation-noopable",n._animationsDisabled))},inputs:{color:"color",disableRipple:[2,"disableRipple","disableRipple",L],disabled:[2,"disabled","disabled",L],ariaDisabled:[2,"aria-disabled","ariaDisabled",L],disabledInteractive:[2,"disabledInteractive","disabledInteractive",L],tabIndex:[2,"tabIndex","tabIndex",Qu],_tabindex:[2,"tabindex","_tabindex",Qu],showProgress:[1,"showProgress"]}})}return i})(),Hi=(()=>{class i extends cc{constructor(){super(),this._rippleLoader.configureRipple(this._elementRef.nativeElement,{centered:!0})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["button","mat-icon-button",""],["a","mat-icon-button",""],["button","matIconButton",""],["a","matIconButton",""]],hostAttrs:[1,"mdc-icon-button","mat-mdc-icon-button"],exportAs:["matButton","matAnchor"],features:[Q],ngContentSelectors:Q_,decls:5,vars:1,consts:[[1,"mat-mdc-button-persistent-ripple","mdc-icon-button__ripple"],[1,"mat-mdc-button-progress-indicator-container"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(t,n){t&1&&(ce(Z_),ht(0,"span",0),U(1),M(2,J_,2,0,"div",1),ht(3,"span",2)(4,"span",3)),t&2&&(c(2),E(n.showProgress()?2:-1))},styles:[`.mat-mdc-icon-button {
1475
1475
  -webkit-user-select: none;
1476
1476
  user-select: none;
1477
1477
  display: inline-block;
@@ -1619,7 +1619,7 @@ select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) optio
1619
1619
  outline: solid 1px;
1620
1620
  }
1621
1621
  }
1622
- `],encapsulation:2})}return i})();var Ti=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();var tv=[[["",8,"material-icons",3,"iconPositionEnd",""],["mat-icon",3,"iconPositionEnd",""],["","matButtonIcon","",3,"iconPositionEnd",""]],"*",[["","iconPositionEnd","",8,"material-icons"],["mat-icon","iconPositionEnd",""],["","matButtonIcon","","iconPositionEnd",""]],[["","progressIndicator",""]]],iv=[".material-icons:not([iconPositionEnd]), mat-icon:not([iconPositionEnd]), [matButtonIcon]:not([iconPositionEnd])","*",".material-icons[iconPositionEnd], mat-icon[iconPositionEnd], [matButtonIcon][iconPositionEnd]","[progressIndicator]"];function nv(i,o){i&1&&(Ie(0,"div",2),U(1,3),je())}var Ju=new Map([["text",["mat-mdc-button"]],["filled",["mdc-button--unelevated","mat-mdc-unelevated-button"]],["elevated",["mdc-button--raised","mat-mdc-raised-button"]],["outlined",["mdc-button--outlined","mat-mdc-outlined-button"]],["tonal",["mat-tonal-button"]]]),it=(()=>{class i extends lc{get appearance(){return this._appearance}set appearance(e){this.setAppearance(e||this._config?.defaultAppearance||"text")}_appearance=null;constructor(){super();let e=ov(this._elementRef.nativeElement);e&&this.setAppearance(e)}setAppearance(e){if(e===this._appearance)return;let t=this._elementRef.nativeElement.classList,n=this._appearance?Ju.get(this._appearance):null,a=Ju.get(e);n&&t.remove(...n),t.add(...a),this._appearance=e}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["button","matButton",""],["a","matButton",""],["button","mat-button",""],["button","mat-raised-button",""],["button","mat-flat-button",""],["button","mat-stroked-button",""],["a","mat-button",""],["a","mat-raised-button",""],["a","mat-flat-button",""],["a","mat-stroked-button",""]],hostAttrs:[1,"mdc-button"],inputs:{appearance:[0,"matButton","appearance"]},exportAs:["matButton","matAnchor"],features:[Q],ngContentSelectors:iv,decls:8,vars:5,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-mdc-button-progress-indicator-container"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(t,n){t&1&&(ce(tv),ht(0,"span",0),U(1),Ie(2,"span",1),U(3,1),je(),U(4,2),M(5,nv,2,0,"div",2),ht(6,"span",3)(7,"span",4)),t&2&&(p("mdc-button__ripple",!n._isFab)("mdc-fab__ripple",n._isFab),c(5),E(n.showProgress()?5:-1))},styles:[`.mat-mdc-button-base {
1622
+ `],encapsulation:2})}return i})();var Ti=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();var tv=[[["",8,"material-icons",3,"iconPositionEnd",""],["mat-icon",3,"iconPositionEnd",""],["","matButtonIcon","",3,"iconPositionEnd",""]],"*",[["","iconPositionEnd","",8,"material-icons"],["mat-icon","iconPositionEnd",""],["","matButtonIcon","","iconPositionEnd",""]],[["","progressIndicator",""]]],iv=[".material-icons:not([iconPositionEnd]), mat-icon:not([iconPositionEnd]), [matButtonIcon]:not([iconPositionEnd])","*",".material-icons[iconPositionEnd], mat-icon[iconPositionEnd], [matButtonIcon][iconPositionEnd]","[progressIndicator]"];function nv(i,o){i&1&&(Ie(0,"div",2),U(1,3),je())}var Ju=new Map([["text",["mat-mdc-button"]],["filled",["mdc-button--unelevated","mat-mdc-unelevated-button"]],["elevated",["mdc-button--raised","mat-mdc-raised-button"]],["outlined",["mdc-button--outlined","mat-mdc-outlined-button"]],["tonal",["mat-tonal-button"]]]),it=(()=>{class i extends cc{get appearance(){return this._appearance}set appearance(e){this.setAppearance(e||this._config?.defaultAppearance||"text")}_appearance=null;constructor(){super();let e=ov(this._elementRef.nativeElement);e&&this.setAppearance(e)}setAppearance(e){if(e===this._appearance)return;let t=this._elementRef.nativeElement.classList,n=this._appearance?Ju.get(this._appearance):null,a=Ju.get(e);n&&t.remove(...n),t.add(...a),this._appearance=e}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["button","matButton",""],["a","matButton",""],["button","mat-button",""],["button","mat-raised-button",""],["button","mat-flat-button",""],["button","mat-stroked-button",""],["a","mat-button",""],["a","mat-raised-button",""],["a","mat-flat-button",""],["a","mat-stroked-button",""]],hostAttrs:[1,"mdc-button"],inputs:{appearance:[0,"matButton","appearance"]},exportAs:["matButton","matAnchor"],features:[Q],ngContentSelectors:iv,decls:8,vars:5,consts:[[1,"mat-mdc-button-persistent-ripple"],[1,"mdc-button__label"],[1,"mat-mdc-button-progress-indicator-container"],[1,"mat-focus-indicator"],[1,"mat-mdc-button-touch-target"]],template:function(t,n){t&1&&(ce(tv),ht(0,"span",0),U(1),Ie(2,"span",1),U(3,1),je(),U(4,2),M(5,nv,2,0,"div",2),ht(6,"span",3)(7,"span",4)),t&2&&(p("mdc-button__ripple",!n._isFab)("mdc-fab__ripple",n._isFab),c(5),E(n.showProgress()?5:-1))},styles:[`.mat-mdc-button-base {
1623
1623
  text-decoration: none;
1624
1624
  }
1625
1625
  .mat-mdc-button-base .mat-icon {
@@ -2184,7 +2184,7 @@ select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) optio
2184
2184
  outline: solid 1px;
2185
2185
  }
2186
2186
  }
2187
- `],encapsulation:2})}return i})();function ov(i){return i.hasAttribute("mat-raised-button")?"elevated":i.hasAttribute("mat-stroked-button")?"outlined":i.hasAttribute("mat-flat-button")?"filled":i.hasAttribute("mat-button")?"text":null}var Qe=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Ti,ee]})}return i})();function eh(i){return Error(`Unable to find icon with the name "${i}"`)}function av(){return Error("Could not find HttpClient for use with Angular Material icons. Please add provideHttpClient() to your providers.")}function th(i){return Error(`The URL provided to MatIconRegistry was not trusted as a resource URL via Angular's DomSanitizer. Attempted URL was "${i}".`)}function ih(i){return Error(`The literal provided to MatIconRegistry was not trusted as safe HTML by Angular's DomSanitizer. Attempted literal was "${i}".`)}var Ui=class{url;svgText;options;svgElement=null;constructor(o,e,t){this.url=o,this.svgText=e,this.options=t}},oh=(()=>{class i{_httpClient;_sanitizer;_errorHandler;_document;_svgIconConfigs=new Map;_iconSetConfigs=new Map;_cachedIconsByUrl=new Map;_inProgressUrlFetches=new Map;_fontCssClassesByAlias=new Map;_resolvers=[];_defaultFontSetClass=["material-icons","mat-ligature-font"];constructor(e,t,n,a){this._httpClient=e,this._sanitizer=t,this._errorHandler=a,this._document=n}addSvgIcon(e,t,n){return this.addSvgIconInNamespace("",e,t,n)}addSvgIconLiteral(e,t,n){return this.addSvgIconLiteralInNamespace("",e,t,n)}addSvgIconInNamespace(e,t,n,a){return this._addSvgIconConfig(e,t,new Ui(n,null,a))}addSvgIconResolver(e){return this._resolvers.push(e),this}addSvgIconLiteralInNamespace(e,t,n,a){let r=this._sanitizer.sanitize(Ct.HTML,n);if(!r)throw ih(n);let u=Fn(r);return this._addSvgIconConfig(e,t,new Ui("",u,a))}addSvgIconSet(e,t){return this.addSvgIconSetInNamespace("",e,t)}addSvgIconSetLiteral(e,t){return this.addSvgIconSetLiteralInNamespace("",e,t)}addSvgIconSetInNamespace(e,t,n){return this._addSvgIconSetConfig(e,new Ui(t,null,n))}addSvgIconSetLiteralInNamespace(e,t,n){let a=this._sanitizer.sanitize(Ct.HTML,t);if(!a)throw ih(t);let r=Fn(a);return this._addSvgIconSetConfig(e,new Ui("",r,n))}registerFontClassAlias(e,t=e){return this._fontCssClassesByAlias.set(e,t),this}classNameForFontAlias(e){return this._fontCssClassesByAlias.get(e)||e}setDefaultFontSetClass(...e){return this._defaultFontSetClass=e,this}getDefaultFontSetClass(){return this._defaultFontSetClass}getSvgIconFromUrl(e){let t=this._sanitizer.sanitize(Ct.RESOURCE_URL,e);if(!t)throw th(e);let n=this._cachedIconsByUrl.get(t);return n?ge(es(n)):this._loadSvgIconFromConfig(new Ui(e,null)).pipe(di(a=>this._cachedIconsByUrl.set(t,a)),Pe(a=>es(a)))}getNamedSvgIcon(e,t=""){let n=nh(t,e),a=this._svgIconConfigs.get(n);if(a)return this._getSvgFromConfig(a);if(a=this._getIconConfigFromResolvers(t,e),a)return this._svgIconConfigs.set(n,a),this._getSvgFromConfig(a);let r=this._iconSetConfigs.get(t);return r?this._getSvgFromIconSetConfigs(e,r):Ga(eh(n))}ngOnDestroy(){this._resolvers=[],this._svgIconConfigs.clear(),this._iconSetConfigs.clear(),this._cachedIconsByUrl.clear()}_getSvgFromConfig(e){return e.svgText?ge(es(this._svgElementFromConfig(e))):this._loadSvgIconFromConfig(e).pipe(Pe(t=>es(t)))}_getSvgFromIconSetConfigs(e,t){let n=this._extractIconWithNameFromAnySet(e,t);if(n)return ge(n);let a=t.filter(r=>!r.svgText).map(r=>this._loadSvgIconSetFromConfig(r).pipe(Kt(u=>{let g=`Loading icon set URL: ${this._sanitizer.sanitize(Ct.RESOURCE_URL,r.url)} failed: ${u.message}`;return this._errorHandler.handleError(new Error(g)),ge(null)})));return $a(a).pipe(Pe(()=>{let r=this._extractIconWithNameFromAnySet(e,t);if(!r)throw eh(e);return r}))}_extractIconWithNameFromAnySet(e,t){for(let n=t.length-1;n>=0;n--){let a=t[n];if(a.svgText&&a.svgText.toString().indexOf(e)>-1){let r=this._svgElementFromConfig(a),u=this._extractSvgIconFromSet(r,e,a.options);if(u)return u}}return null}_loadSvgIconFromConfig(e){return this._fetchIcon(e).pipe(di(t=>e.svgText=t),Pe(()=>this._svgElementFromConfig(e)))}_loadSvgIconSetFromConfig(e){return e.svgText?ge(null):this._fetchIcon(e).pipe(di(t=>e.svgText=t))}_extractSvgIconFromSet(e,t,n){let a=e.querySelector(`[id="${t}"]`);if(!a)return null;let r=a.cloneNode(!0);if(r.removeAttribute("id"),r.nodeName.toLowerCase()==="svg")return this._setSvgAttributes(r,n);if(r.nodeName.toLowerCase()==="symbol")return this._setSvgAttributes(this._toSvgElement(r),n);let u=this._svgElementFromString(Fn("<svg></svg>"));return u.appendChild(r),this._setSvgAttributes(u,n)}_svgElementFromString(e){let t=this._document.createElement("DIV");t.innerHTML=e;let n=t.querySelector("svg");if(!n)throw Error("<svg> tag not found");return n}_toSvgElement(e){let t=this._svgElementFromString(Fn("<svg></svg>")),n=e.attributes;for(let a=0;a<n.length;a++){let{name:r,value:u}=n[a];r!=="id"&&t.setAttribute(r,u)}for(let a=0;a<e.childNodes.length;a++)e.childNodes[a].nodeType===this._document.ELEMENT_NODE&&t.appendChild(e.childNodes[a].cloneNode(!0));return t}_setSvgAttributes(e,t){return e.setAttribute("fit",""),e.setAttribute("height","100%"),e.setAttribute("width","100%"),e.setAttribute("preserveAspectRatio","xMidYMid meet"),e.setAttribute("focusable","false"),t&&t.viewBox&&e.setAttribute("viewBox",t.viewBox),e}_fetchIcon(e){let{url:t,options:n}=e,a=n?.withCredentials??!1;if(!this._httpClient)throw av();if(t==null)throw Error(`Cannot fetch icon from URL "${t}".`);let r=this._sanitizer.sanitize(Ct.RESOURCE_URL,t);if(!r)throw th(t);let u=this._inProgressUrlFetches.get(r);if(u)return u;let h=this._httpClient.get(r,{responseType:"text",withCredentials:a}).pipe(Pe(g=>Fn(g)),qa(()=>this._inProgressUrlFetches.delete(r)),Yc());return this._inProgressUrlFetches.set(r,h),h}_addSvgIconConfig(e,t,n){return this._svgIconConfigs.set(nh(e,t),n),this}_addSvgIconSetConfig(e,t){let n=this._iconSetConfigs.get(e);return n?n.push(t):this._iconSetConfigs.set(e,[t]),this}_svgElementFromConfig(e){if(!e.svgElement){let t=this._svgElementFromString(e.svgText);this._setSvgAttributes(t,e.options),e.svgElement=t}return e.svgElement}_getIconConfigFromResolvers(e,t){for(let n=0;n<this._resolvers.length;n++){let a=this._resolvers[n](t,e);if(a)return rv(a)?new Ui(a.url,null,a.options):new Ui(a,null)}}static \u0275fac=function(t){return new(t||i)(ne(Qt,8),ne(na),ne($,8),ne(kn))};static \u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();function es(i){return i.cloneNode(!0)}function nh(i,o){return i+":"+o}function rv(i){return!!(i.url&&i.options)}var sv=["*"],lv=new C("MAT_ICON_DEFAULT_OPTIONS"),cv=new C("mat-icon-location",{providedIn:"root",factory:()=>{let i=d($),o=i?i.location:null;return{getPathname:()=>o?o.pathname+o.search:""}}}),ah=["clip-path","color-profile","src","cursor","fill","filter","marker","marker-start","marker-mid","marker-end","mask","stroke"],dv=ah.map(i=>`[${i}]`).join(", "),mv=/^url\(['"]?#(.*?)['"]?\)$/,Pt=(()=>{class i{_elementRef=d(N);_iconRegistry=d(oh);_location=d(cv);_errorHandler=d(kn);_defaultColor;get color(){return this._color||this._defaultColor}set color(e){this._color=e}_color;inline=!1;get svgIcon(){return this._svgIcon}set svgIcon(e){e!==this._svgIcon&&(e?this._updateSvgIcon(e):this._svgIcon&&this._clearSvgElement(),this._svgIcon=e)}_svgIcon;get fontSet(){return this._fontSet}set fontSet(e){let t=this._cleanupFontValue(e);t!==this._fontSet&&(this._fontSet=t,this._updateFontIconClasses())}_fontSet;get fontIcon(){return this._fontIcon}set fontIcon(e){let t=this._cleanupFontValue(e);t!==this._fontIcon&&(this._fontIcon=t,this._updateFontIconClasses())}_fontIcon;_previousFontSetClass=[];_previousFontIconClass;_svgName=null;_svgNamespace=null;_previousPath;_elementsWithExternalReferences;_currentIconFetch=De.EMPTY;constructor(){let e=d(new Di("aria-hidden"),{optional:!0}),t=d(lv,{optional:!0});t&&(t.color&&(this.color=this._defaultColor=t.color),t.fontSet&&(this.fontSet=t.fontSet)),e||this._elementRef.nativeElement.setAttribute("aria-hidden","true")}_splitIconName(e){if(!e)return["",""];let t=e.split(":");switch(t.length){case 1:return["",t[0]];case 2:return t;default:throw Error(`Invalid icon name: "${e}"`)}}ngOnInit(){this._updateFontIconClasses()}ngAfterViewChecked(){let e=this._elementsWithExternalReferences;if(e&&e.size){let t=this._location.getPathname();t!==this._previousPath&&(this._previousPath=t,this._prependPathToReferences(t))}}ngOnDestroy(){this._currentIconFetch.unsubscribe(),this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear()}_usingFontIcon(){return!this.svgIcon}_setSvgElement(e){this._clearSvgElement();let t=this._location.getPathname();this._previousPath=t,this._cacheChildrenWithExternalReferences(e),this._prependPathToReferences(t),this._elementRef.nativeElement.appendChild(e)}_clearSvgElement(){let e=this._elementRef.nativeElement,t=e.childNodes.length;for(this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear();t--;){let n=e.childNodes[t];(n.nodeType!==1||n.nodeName.toLowerCase()==="svg")&&n.remove()}}_updateFontIconClasses(){if(!this._usingFontIcon())return;let e=this._elementRef.nativeElement,t=(this.fontSet?this._iconRegistry.classNameForFontAlias(this.fontSet).split(/ +/):this._iconRegistry.getDefaultFontSetClass()).filter(n=>n.length>0);this._previousFontSetClass.forEach(n=>e.classList.remove(n)),t.forEach(n=>e.classList.add(n)),this._previousFontSetClass=t,this.fontIcon!==this._previousFontIconClass&&!t.includes("mat-ligature-font")&&(this._previousFontIconClass&&e.classList.remove(this._previousFontIconClass),this.fontIcon&&e.classList.add(this.fontIcon),this._previousFontIconClass=this.fontIcon)}_cleanupFontValue(e){return typeof e=="string"?e.trim().split(" ")[0]:e}_prependPathToReferences(e){let t=this._elementsWithExternalReferences;t&&t.forEach((n,a)=>{n.forEach(r=>{a.setAttribute(r.name,`url('${e}#${r.value}')`)})})}_cacheChildrenWithExternalReferences(e){let t=e.querySelectorAll(dv),n=this._elementsWithExternalReferences=this._elementsWithExternalReferences||new Map;for(let a=0;a<t.length;a++)ah.forEach(r=>{let u=t[a],h=u.getAttribute(r),g=h?h.match(mv):null;if(g){let _=n.get(u);_||(_=[],n.set(u,_)),_.push({name:r,value:g[1]})}})}_updateSvgIcon(e){if(this._svgNamespace=null,this._svgName=null,this._currentIconFetch.unsubscribe(),e){let[t,n]=this._splitIconName(e);t&&(this._svgNamespace=t),n&&(this._svgName=n),this._currentIconFetch=this._iconRegistry.getNamedSvgIcon(n,t).pipe(ct(1)).subscribe(a=>this._setSvgElement(a),a=>{let r=`Error retrieving icon ${t}:${n}! ${a.message}`;this._errorHandler.handleError(new Error(r))})}}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-icon"]],hostAttrs:["role","img",1,"mat-icon","notranslate"],hostVars:10,hostBindings:function(t,n){t&2&&(Z("data-mat-icon-type",n._usingFontIcon()?"font":"svg")("data-mat-icon-name",n._svgName||n.fontIcon)("data-mat-icon-namespace",n._svgNamespace||n.fontSet)("fontIcon",n._usingFontIcon()?n.fontIcon:null),et(n.color?"mat-"+n.color:""),p("mat-icon-inline",n.inline)("mat-icon-no-color",n.color!=="primary"&&n.color!=="accent"&&n.color!=="warn"))},inputs:{color:"color",inline:[2,"inline","inline",L],svgIcon:"svgIcon",fontSet:"fontSet",fontIcon:"fontIcon"},exportAs:["matIcon"],ngContentSelectors:sv,decls:1,vars:0,template:function(t,n){t&1&&(ce(),U(0))},styles:[`mat-icon, mat-icon.mat-primary, mat-icon.mat-accent, mat-icon.mat-warn {
2187
+ `],encapsulation:2})}return i})();function ov(i){return i.hasAttribute("mat-raised-button")?"elevated":i.hasAttribute("mat-stroked-button")?"outlined":i.hasAttribute("mat-flat-button")?"filled":i.hasAttribute("mat-button")?"text":null}var Qe=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Ti,ee]})}return i})();function eh(i){return Error(`Unable to find icon with the name "${i}"`)}function av(){return Error("Could not find HttpClient for use with Angular Material icons. Please add provideHttpClient() to your providers.")}function th(i){return Error(`The URL provided to MatIconRegistry was not trusted as a resource URL via Angular's DomSanitizer. Attempted URL was "${i}".`)}function ih(i){return Error(`The literal provided to MatIconRegistry was not trusted as safe HTML by Angular's DomSanitizer. Attempted literal was "${i}".`)}var Ui=class{url;svgText;options;svgElement=null;constructor(o,e,t){this.url=o,this.svgText=e,this.options=t}},oh=(()=>{class i{_httpClient;_sanitizer;_errorHandler;_document;_svgIconConfigs=new Map;_iconSetConfigs=new Map;_cachedIconsByUrl=new Map;_inProgressUrlFetches=new Map;_fontCssClassesByAlias=new Map;_resolvers=[];_defaultFontSetClass=["material-icons","mat-ligature-font"];constructor(e,t,n,a){this._httpClient=e,this._sanitizer=t,this._errorHandler=a,this._document=n}addSvgIcon(e,t,n){return this.addSvgIconInNamespace("",e,t,n)}addSvgIconLiteral(e,t,n){return this.addSvgIconLiteralInNamespace("",e,t,n)}addSvgIconInNamespace(e,t,n,a){return this._addSvgIconConfig(e,t,new Ui(n,null,a))}addSvgIconResolver(e){return this._resolvers.push(e),this}addSvgIconLiteralInNamespace(e,t,n,a){let r=this._sanitizer.sanitize(Ct.HTML,n);if(!r)throw ih(n);let u=Ln(r);return this._addSvgIconConfig(e,t,new Ui("",u,a))}addSvgIconSet(e,t){return this.addSvgIconSetInNamespace("",e,t)}addSvgIconSetLiteral(e,t){return this.addSvgIconSetLiteralInNamespace("",e,t)}addSvgIconSetInNamespace(e,t,n){return this._addSvgIconSetConfig(e,new Ui(t,null,n))}addSvgIconSetLiteralInNamespace(e,t,n){let a=this._sanitizer.sanitize(Ct.HTML,t);if(!a)throw ih(t);let r=Ln(a);return this._addSvgIconSetConfig(e,new Ui("",r,n))}registerFontClassAlias(e,t=e){return this._fontCssClassesByAlias.set(e,t),this}classNameForFontAlias(e){return this._fontCssClassesByAlias.get(e)||e}setDefaultFontSetClass(...e){return this._defaultFontSetClass=e,this}getDefaultFontSetClass(){return this._defaultFontSetClass}getSvgIconFromUrl(e){let t=this._sanitizer.sanitize(Ct.RESOURCE_URL,e);if(!t)throw th(e);let n=this._cachedIconsByUrl.get(t);return n?ge(ns(n)):this._loadSvgIconFromConfig(new Ui(e,null)).pipe(di(a=>this._cachedIconsByUrl.set(t,a)),Pe(a=>ns(a)))}getNamedSvgIcon(e,t=""){let n=nh(t,e),a=this._svgIconConfigs.get(n);if(a)return this._getSvgFromConfig(a);if(a=this._getIconConfigFromResolvers(t,e),a)return this._svgIconConfigs.set(n,a),this._getSvgFromConfig(a);let r=this._iconSetConfigs.get(t);return r?this._getSvgFromIconSetConfigs(e,r):qa(eh(n))}ngOnDestroy(){this._resolvers=[],this._svgIconConfigs.clear(),this._iconSetConfigs.clear(),this._cachedIconsByUrl.clear()}_getSvgFromConfig(e){return e.svgText?ge(ns(this._svgElementFromConfig(e))):this._loadSvgIconFromConfig(e).pipe(Pe(t=>ns(t)))}_getSvgFromIconSetConfigs(e,t){let n=this._extractIconWithNameFromAnySet(e,t);if(n)return ge(n);let a=t.filter(r=>!r.svgText).map(r=>this._loadSvgIconSetFromConfig(r).pipe(Kt(u=>{let g=`Loading icon set URL: ${this._sanitizer.sanitize(Ct.RESOURCE_URL,r.url)} failed: ${u.message}`;return this._errorHandler.handleError(new Error(g)),ge(null)})));return Ka(a).pipe(Pe(()=>{let r=this._extractIconWithNameFromAnySet(e,t);if(!r)throw eh(e);return r}))}_extractIconWithNameFromAnySet(e,t){for(let n=t.length-1;n>=0;n--){let a=t[n];if(a.svgText&&a.svgText.toString().indexOf(e)>-1){let r=this._svgElementFromConfig(a),u=this._extractSvgIconFromSet(r,e,a.options);if(u)return u}}return null}_loadSvgIconFromConfig(e){return this._fetchIcon(e).pipe(di(t=>e.svgText=t),Pe(()=>this._svgElementFromConfig(e)))}_loadSvgIconSetFromConfig(e){return e.svgText?ge(null):this._fetchIcon(e).pipe(di(t=>e.svgText=t))}_extractSvgIconFromSet(e,t,n){let a=e.querySelector(`[id="${t}"]`);if(!a)return null;let r=a.cloneNode(!0);if(r.removeAttribute("id"),r.nodeName.toLowerCase()==="svg")return this._setSvgAttributes(r,n);if(r.nodeName.toLowerCase()==="symbol")return this._setSvgAttributes(this._toSvgElement(r),n);let u=this._svgElementFromString(Ln("<svg></svg>"));return u.appendChild(r),this._setSvgAttributes(u,n)}_svgElementFromString(e){let t=this._document.createElement("DIV");t.innerHTML=e;let n=t.querySelector("svg");if(!n)throw Error("<svg> tag not found");return n}_toSvgElement(e){let t=this._svgElementFromString(Ln("<svg></svg>")),n=e.attributes;for(let a=0;a<n.length;a++){let{name:r,value:u}=n[a];r!=="id"&&t.setAttribute(r,u)}for(let a=0;a<e.childNodes.length;a++)e.childNodes[a].nodeType===this._document.ELEMENT_NODE&&t.appendChild(e.childNodes[a].cloneNode(!0));return t}_setSvgAttributes(e,t){return e.setAttribute("fit",""),e.setAttribute("height","100%"),e.setAttribute("width","100%"),e.setAttribute("preserveAspectRatio","xMidYMid meet"),e.setAttribute("focusable","false"),t&&t.viewBox&&e.setAttribute("viewBox",t.viewBox),e}_fetchIcon(e){let{url:t,options:n}=e,a=n?.withCredentials??!1;if(!this._httpClient)throw av();if(t==null)throw Error(`Cannot fetch icon from URL "${t}".`);let r=this._sanitizer.sanitize(Ct.RESOURCE_URL,t);if(!r)throw th(t);let u=this._inProgressUrlFetches.get(r);if(u)return u;let h=this._httpClient.get(r,{responseType:"text",withCredentials:a}).pipe(Pe(g=>Ln(g)),Xa(()=>this._inProgressUrlFetches.delete(r)),Yc());return this._inProgressUrlFetches.set(r,h),h}_addSvgIconConfig(e,t,n){return this._svgIconConfigs.set(nh(e,t),n),this}_addSvgIconSetConfig(e,t){let n=this._iconSetConfigs.get(e);return n?n.push(t):this._iconSetConfigs.set(e,[t]),this}_svgElementFromConfig(e){if(!e.svgElement){let t=this._svgElementFromString(e.svgText);this._setSvgAttributes(t,e.options),e.svgElement=t}return e.svgElement}_getIconConfigFromResolvers(e,t){for(let n=0;n<this._resolvers.length;n++){let a=this._resolvers[n](t,e);if(a)return rv(a)?new Ui(a.url,null,a.options):new Ui(a,null)}}static \u0275fac=function(t){return new(t||i)(ne(Qt,8),ne(aa),ne(W,8),ne(Mn))};static \u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();function ns(i){return i.cloneNode(!0)}function nh(i,o){return i+":"+o}function rv(i){return!!(i.url&&i.options)}var sv=["*"],lv=new x("MAT_ICON_DEFAULT_OPTIONS"),cv=new x("mat-icon-location",{providedIn:"root",factory:()=>{let i=d(W),o=i?i.location:null;return{getPathname:()=>o?o.pathname+o.search:""}}}),ah=["clip-path","color-profile","src","cursor","fill","filter","marker","marker-start","marker-mid","marker-end","mask","stroke"],dv=ah.map(i=>`[${i}]`).join(", "),mv=/^url\(['"]?#(.*?)['"]?\)$/,Pt=(()=>{class i{_elementRef=d(N);_iconRegistry=d(oh);_location=d(cv);_errorHandler=d(Mn);_defaultColor;get color(){return this._color||this._defaultColor}set color(e){this._color=e}_color;inline=!1;get svgIcon(){return this._svgIcon}set svgIcon(e){e!==this._svgIcon&&(e?this._updateSvgIcon(e):this._svgIcon&&this._clearSvgElement(),this._svgIcon=e)}_svgIcon;get fontSet(){return this._fontSet}set fontSet(e){let t=this._cleanupFontValue(e);t!==this._fontSet&&(this._fontSet=t,this._updateFontIconClasses())}_fontSet;get fontIcon(){return this._fontIcon}set fontIcon(e){let t=this._cleanupFontValue(e);t!==this._fontIcon&&(this._fontIcon=t,this._updateFontIconClasses())}_fontIcon;_previousFontSetClass=[];_previousFontIconClass;_svgName=null;_svgNamespace=null;_previousPath;_elementsWithExternalReferences;_currentIconFetch=De.EMPTY;constructor(){let e=d(new Di("aria-hidden"),{optional:!0}),t=d(lv,{optional:!0});t&&(t.color&&(this.color=this._defaultColor=t.color),t.fontSet&&(this.fontSet=t.fontSet)),e||this._elementRef.nativeElement.setAttribute("aria-hidden","true")}_splitIconName(e){if(!e)return["",""];let t=e.split(":");switch(t.length){case 1:return["",t[0]];case 2:return t;default:throw Error(`Invalid icon name: "${e}"`)}}ngOnInit(){this._updateFontIconClasses()}ngAfterViewChecked(){let e=this._elementsWithExternalReferences;if(e&&e.size){let t=this._location.getPathname();t!==this._previousPath&&(this._previousPath=t,this._prependPathToReferences(t))}}ngOnDestroy(){this._currentIconFetch.unsubscribe(),this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear()}_usingFontIcon(){return!this.svgIcon}_setSvgElement(e){this._clearSvgElement();let t=this._location.getPathname();this._previousPath=t,this._cacheChildrenWithExternalReferences(e),this._prependPathToReferences(t),this._elementRef.nativeElement.appendChild(e)}_clearSvgElement(){let e=this._elementRef.nativeElement,t=e.childNodes.length;for(this._elementsWithExternalReferences&&this._elementsWithExternalReferences.clear();t--;){let n=e.childNodes[t];(n.nodeType!==1||n.nodeName.toLowerCase()==="svg")&&n.remove()}}_updateFontIconClasses(){if(!this._usingFontIcon())return;let e=this._elementRef.nativeElement,t=(this.fontSet?this._iconRegistry.classNameForFontAlias(this.fontSet).split(/ +/):this._iconRegistry.getDefaultFontSetClass()).filter(n=>n.length>0);this._previousFontSetClass.forEach(n=>e.classList.remove(n)),t.forEach(n=>e.classList.add(n)),this._previousFontSetClass=t,this.fontIcon!==this._previousFontIconClass&&!t.includes("mat-ligature-font")&&(this._previousFontIconClass&&e.classList.remove(this._previousFontIconClass),this.fontIcon&&e.classList.add(this.fontIcon),this._previousFontIconClass=this.fontIcon)}_cleanupFontValue(e){return typeof e=="string"?e.trim().split(" ")[0]:e}_prependPathToReferences(e){let t=this._elementsWithExternalReferences;t&&t.forEach((n,a)=>{n.forEach(r=>{a.setAttribute(r.name,`url('${e}#${r.value}')`)})})}_cacheChildrenWithExternalReferences(e){let t=e.querySelectorAll(dv),n=this._elementsWithExternalReferences=this._elementsWithExternalReferences||new Map;for(let a=0;a<t.length;a++)ah.forEach(r=>{let u=t[a],h=u.getAttribute(r),g=h?h.match(mv):null;if(g){let _=n.get(u);_||(_=[],n.set(u,_)),_.push({name:r,value:g[1]})}})}_updateSvgIcon(e){if(this._svgNamespace=null,this._svgName=null,this._currentIconFetch.unsubscribe(),e){let[t,n]=this._splitIconName(e);t&&(this._svgNamespace=t),n&&(this._svgName=n),this._currentIconFetch=this._iconRegistry.getNamedSvgIcon(n,t).pipe(ct(1)).subscribe(a=>this._setSvgElement(a),a=>{let r=`Error retrieving icon ${t}:${n}! ${a.message}`;this._errorHandler.handleError(new Error(r))})}}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-icon"]],hostAttrs:["role","img",1,"mat-icon","notranslate"],hostVars:10,hostBindings:function(t,n){t&2&&(Z("data-mat-icon-type",n._usingFontIcon()?"font":"svg")("data-mat-icon-name",n._svgName||n.fontIcon)("data-mat-icon-namespace",n._svgNamespace||n.fontSet)("fontIcon",n._usingFontIcon()?n.fontIcon:null),et(n.color?"mat-"+n.color:""),p("mat-icon-inline",n.inline)("mat-icon-no-color",n.color!=="primary"&&n.color!=="accent"&&n.color!=="warn"))},inputs:{color:"color",inline:[2,"inline","inline",L],svgIcon:"svgIcon",fontSet:"fontSet",fontIcon:"fontIcon"},exportAs:["matIcon"],ngContentSelectors:sv,decls:1,vars:0,template:function(t,n){t&1&&(ce(),U(0))},styles:[`mat-icon, mat-icon.mat-primary, mat-icon.mat-accent, mat-icon.mat-warn {
2188
2188
  color: var(--mat-icon-color, inherit);
2189
2189
  }
2190
2190
 
@@ -2220,10 +2220,10 @@ select.mat-mdc-form-field-input-control:not(.mat-mdc-native-select-inline) optio
2220
2220
  .mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mat-icon {
2221
2221
  margin: auto;
2222
2222
  }
2223
- `],encapsulation:2})}return i})(),Ft=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();var rh=(()=>{class i{constructor(){this.http=d(Qt),this.staticUrl="/api/gpus",this.usageUrl="/api/gpus/usage"}fetchGpus(){return this.http.get(this.staticUrl).pipe(di({error:e=>console.error("[GpuService] static fetch error:",e)}))}fetchStatus(){return this.http.get(this.usageUrl).pipe(di({error:e=>console.error("[GpuService] status fetch error:",e)}))}watchStatus(e){return Wa(0,e).pipe(We(()=>this.fetchStatus()))}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();function ts(i){return i&&typeof i.connect=="function"&&!(i instanceof Gc)}var gi=(function(i){return i[i.REPLACED=0]="REPLACED",i[i.INSERTED=1]="INSERTED",i[i.MOVED=2]="MOVED",i[i.REMOVED=3]="REMOVED",i})(gi||{}),is=class{viewCacheSize=20;_viewCache=[];applyChanges(o,e,t,n,a){o.forEachOperation((r,u,h)=>{let g,_;if(r.previousIndex==null){let w=()=>t(r,u,h);g=this._insertView(w,h,e,n(r)),_=g?gi.INSERTED:gi.REPLACED}else h==null?(this._detachAndCacheView(u,e),_=gi.REMOVED):(g=this._moveView(u,h,e,n(r)),_=gi.MOVED);a&&a({context:g?.context,operation:_,record:r})})}detach(){for(let o of this._viewCache)o.destroy();this._viewCache=[]}_insertView(o,e,t,n){let a=this._insertViewFromCache(e,t);if(a){a.context.$implicit=n;return}let r=o();return t.createEmbeddedView(r.templateRef,r.context,r.index)}_detachAndCacheView(o,e){let t=e.detach(o);this._maybeCacheView(t,e)}_moveView(o,e,t,n){let a=t.get(o);return t.move(a,e),a.context.$implicit=n,a}_maybeCacheView(o,e){if(this._viewCache.length<this.viewCacheSize)this._viewCache.push(o);else{let t=e.indexOf(o);t===-1?o.destroy():e.remove(t)}}_insertViewFromCache(o,e){let t=this._viewCache.pop();return t&&e.insert(t,o),t||null}};var uv=20,gn=(()=>{class i{_ngZone=d(H);_platform=d(le);_renderer=d(ot).createRenderer(null,null);_cleanupGlobalListener;_scrolled=new I;_scrolledCount=0;scrollContainers=new Map;register(e){this.scrollContainers.has(e)||this.scrollContainers.set(e,e.elementScrolled().subscribe(()=>this._scrolled.next(e)))}deregister(e){let t=this.scrollContainers.get(e);t&&(t.unsubscribe(),this.scrollContainers.delete(e))}scrolled(e=uv){return this._platform.isBrowser?new yt(t=>{this._cleanupGlobalListener||(this._cleanupGlobalListener=this._ngZone.runOutsideAngular(()=>this._renderer.listen("document","scroll",()=>this._scrolled.next())));let n=e>0?this._scrolled.pipe(Vo(e)).subscribe(t):this._scrolled.subscribe(t);return this._scrolledCount++,()=>{n.unsubscribe(),this._scrolledCount--,this._scrolledCount||(this._cleanupGlobalListener?.(),this._cleanupGlobalListener=void 0)}}):ge()}ngOnDestroy(){this._cleanupGlobalListener?.(),this._cleanupGlobalListener=void 0,this.scrollContainers.forEach((e,t)=>this.deregister(t)),this._scrolled.complete()}ancestorScrolled(e,t){let n=this.getAncestorScrollContainers(e);return this.scrolled(t).pipe(Ce(a=>!a||n.indexOf(a)>-1))}getAncestorScrollContainers(e){let t=[];return this.scrollContainers.forEach((n,a)=>{this._targetContainsElement(a,e)&&t.push(a)}),t}_targetContainsElement(e,t){let n=Dt(t),a=e.getElementRef().nativeElement;do if(n==a)return!0;while(n=n.parentElement);return!1}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),cc=(()=>{class i{elementRef=d(N);scrollDispatcher=d(gn);ngZone=d(H);dir=d(qe,{optional:!0});_scrollElement=this.elementRef.nativeElement;_destroyed=new I;_renderer=d(ve);_cleanupScroll;_elementScrolled=new I;ngOnInit(){this._cleanupScroll=this.ngZone.runOutsideAngular(()=>this._renderer.listen(this._scrollElement,"scroll",e=>this._elementScrolled.next(e))),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(e){let t=this.elementRef.nativeElement,n=this.dir&&this.dir.value=="rtl";e.left==null&&(e.left=n?e.end:e.start),e.right==null&&(e.right=n?e.start:e.end),e.bottom!=null&&(e.top=t.scrollHeight-t.clientHeight-e.bottom),n&&co()!=fi.NORMAL?(e.left!=null&&(e.right=t.scrollWidth-t.clientWidth-e.left),co()==fi.INVERTED?e.left=e.right:co()==fi.NEGATED&&(e.left=e.right?-e.right:e.right)):e.right!=null&&(e.left=t.scrollWidth-t.clientWidth-e.right),this._applyScrollToOptions(e)}_applyScrollToOptions(e){let t=this.elementRef.nativeElement;Tr()?t.scrollTo(e):(e.top!=null&&(t.scrollTop=e.top),e.left!=null&&(t.scrollLeft=e.left))}measureScrollOffset(e){let t="left",n="right",a=this.elementRef.nativeElement;if(e=="top")return a.scrollTop;if(e=="bottom")return a.scrollHeight-a.clientHeight-a.scrollTop;let r=this.dir&&this.dir.value=="rtl";return e=="start"?e=r?n:t:e=="end"&&(e=r?t:n),r&&co()==fi.INVERTED?e==t?a.scrollWidth-a.clientWidth-a.scrollLeft:a.scrollLeft:r&&co()==fi.NEGATED?e==t?a.scrollLeft+a.scrollWidth-a.clientWidth:-a.scrollLeft:e==t?a.scrollLeft:a.scrollWidth-a.clientWidth-a.scrollLeft}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdk-scrollable",""],["","cdkScrollable",""]]})}return i})(),hv=20,Gt=(()=>{class i{_platform=d(le);_listeners;_viewportSize=null;_change=new I;_document=d($);constructor(){let e=d(H),t=d(ot).createRenderer(null,null);e.runOutsideAngular(()=>{if(this._platform.isBrowser){let n=a=>this._change.next(a);this._listeners=[t.listen("window","resize",n),t.listen("window","orientationchange",n)]}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){this._listeners?.forEach(e=>e()),this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();let e={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),e}getViewportRect(){let e=this.getViewportScrollPosition(),{width:t,height:n}=this.getViewportSize();return{top:e.top,left:e.left,bottom:e.top+n,right:e.left+t,height:n,width:t}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};let e=this._document,t=this._getWindow(),n=e.documentElement,a=n.getBoundingClientRect(),r=-a.top||e.body?.scrollTop||t.scrollY||n.scrollTop||0,u=-a.left||e.body?.scrollLeft||t.scrollX||n.scrollLeft||0;return{top:r,left:u}}change(e=hv){return e>0?this._change.pipe(Vo(e)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){let e=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:e.innerWidth,height:e.innerHeight}:{width:0,height:0}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var sh=new C("CDK_VIRTUAL_SCROLL_VIEWPORT");var _i=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})(),xa=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee,_i,ee,_i]})}return i})();var ns=class{applyChanges(o,e,t,n,a){o.forEachOperation((r,u,h)=>{let g,_;if(r.previousIndex==null){let w=t(r,u,h);g=e.createEmbeddedView(w.templateRef,w.context,w.index),_=gi.INSERTED}else h==null?(e.remove(u),_=gi.REMOVED):(g=e.get(u),e.move(g,h),_=gi.MOVED);a&&a({context:g?.context,operation:_,record:r})})}detach(){}};var fv=[[["caption"]],[["colgroup"],["col"]],"*"],gv=["caption","colgroup, col","*"];function _v(i,o){i&1&&U(0,2)}function vv(i,o){i&1&&(s(0,"thead",0),Yt(1,1),l(),s(2,"tbody",0),Yt(3,2)(4,3),l(),s(5,"tfoot",0),Yt(6,4),l())}function bv(i,o){i&1&&Yt(0,1)(1,2)(2,3)(3,4)}var vi=new C("CDK_TABLE");var as=(()=>{class i{template=d(Ye);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkCellDef",""]]})}return i})(),dh=(()=>{class i{template=d(Ye);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkHeaderCellDef",""]]})}return i})(),mh=(()=>{class i{template=d(Ye);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkFooterCellDef",""]]})}return i})(),ka=(()=>{class i{_table=d(vi,{optional:!0});_hasStickyChanged=!1;get name(){return this._name}set name(e){this._setNameInput(e)}_name;get sticky(){return this._sticky}set sticky(e){e!==this._sticky&&(this._sticky=e,this._hasStickyChanged=!0)}_sticky=!1;get stickyEnd(){return this._stickyEnd}set stickyEnd(e){e!==this._stickyEnd&&(this._stickyEnd=e,this._hasStickyChanged=!0)}_stickyEnd=!1;cell;headerCell;footerCell;cssClassFriendlyName;_columnCssClassName;hasStickyChanged(){let e=this._hasStickyChanged;return this.resetStickyChanged(),e}resetStickyChanged(){this._hasStickyChanged=!1}_updateColumnCssClassName(){this._columnCssClassName=[`cdk-column-${this.cssClassFriendlyName}`]}_setNameInput(e){e&&(this._name=e,this.cssClassFriendlyName=e.replace(/[^a-z0-9_-]/gi,"-"),this._updateColumnCssClassName())}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkColumnDef",""]],contentQueries:function(t,n,a){if(t&1&&at(a,as,5)(a,dh,5)(a,mh,5),t&2){let r;O(r=P())&&(n.cell=r.first),O(r=P())&&(n.headerCell=r.first),O(r=P())&&(n.footerCell=r.first)}},inputs:{name:[0,"cdkColumnDef","name"],sticky:[2,"sticky","sticky",L],stickyEnd:[2,"stickyEnd","stickyEnd",L]}})}return i})(),dc=class{constructor(o,e){e.nativeElement.classList.add(...o._columnCssClassName)}};var uh=(()=>{class i extends dc{constructor(){let e=d(ka),t=d(N);super(e,t);let n=e._table?._getCellRole();n&&t.nativeElement.setAttribute("role",n)}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["cdk-cell"],["td","cdk-cell",""]],hostAttrs:[1,"cdk-cell"],features:[Q]})}return i})();var uc=(()=>{class i{template=d(Ye);_differs=d(Go);columns;_columnsDiffer;ngOnChanges(e){if(!this._columnsDiffer){let t=e.columns&&e.columns.currentValue||[];this._columnsDiffer=this._differs.find(t).create(),this._columnsDiffer.diff(t)}}getColumnsDiff(){return this._columnsDiffer.diff(this.columns)}extractCellTemplate(e){return this instanceof hc?e.headerCell.template:this instanceof pc?e.footerCell.template:e.cell.template}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,features:[Se]})}return i})(),hc=(()=>{class i extends uc{_table=d(vi,{optional:!0});_hasStickyChanged=!1;get sticky(){return this._sticky}set sticky(e){e!==this._sticky&&(this._sticky=e,this._hasStickyChanged=!0)}_sticky=!1;ngOnChanges(e){super.ngOnChanges(e)}hasStickyChanged(){let e=this._hasStickyChanged;return this.resetStickyChanged(),e}resetStickyChanged(){this._hasStickyChanged=!1}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","cdkHeaderRowDef",""]],inputs:{columns:[0,"cdkHeaderRowDef","columns"],sticky:[2,"cdkHeaderRowDefSticky","sticky",L]},features:[Q,Se]})}return i})(),pc=(()=>{class i extends uc{_table=d(vi,{optional:!0});_hasStickyChanged=!1;get sticky(){return this._sticky}set sticky(e){e!==this._sticky&&(this._sticky=e,this._hasStickyChanged=!0)}_sticky=!1;ngOnChanges(e){super.ngOnChanges(e)}hasStickyChanged(){let e=this._hasStickyChanged;return this.resetStickyChanged(),e}resetStickyChanged(){this._hasStickyChanged=!1}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","cdkFooterRowDef",""]],inputs:{columns:[0,"cdkFooterRowDef","columns"],sticky:[2,"cdkFooterRowDefSticky","sticky",L]},features:[Q,Se]})}return i})(),rs=(()=>{class i extends uc{_table=d(vi,{optional:!0});when;static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","cdkRowDef",""]],inputs:{columns:[0,"cdkRowDefColumns","columns"],when:[0,"cdkRowDefWhen","when"]},features:[Q]})}return i})(),Da=(()=>{class i{_viewContainer=d(Xe);cells;context;static mostRecentCellOutlet=null;constructor(){i.mostRecentCellOutlet=this}ngOnDestroy(){i.mostRecentCellOutlet===this&&(i.mostRecentCellOutlet=null)}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkCellOutlet",""]]})}return i})();var fc=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["cdk-row"],["tr","cdk-row",""]],hostAttrs:["role","row",1,"cdk-row"],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(t,n){t&1&&Yt(0,0)},dependencies:[Da],encapsulation:2,changeDetection:1})}return i})(),hh=(()=>{class i{templateRef=d(Ye);_contentClassNames=["cdk-no-data-row","cdk-row"];_cellClassNames=["cdk-cell","cdk-no-data-cell"];_cellSelector="td, cdk-cell, [cdk-cell], .cdk-cell";static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["ng-template","cdkNoDataRow",""]]})}return i})(),lh=["top","bottom","left","right"],mc=class{_isNativeHtmlTable;_stickCellCss;_isBrowser;_needsPositionStickyOnElement;direction;_positionListener;_tableInjector;_elemSizeCache=new WeakMap;_resizeObserver=globalThis?.ResizeObserver?new globalThis.ResizeObserver(o=>this._updateCachedSizes(o)):null;_updatedStickyColumnsParamsToReplay=[];_stickyColumnsReplayTimeout=null;_cachedCellWidths=[];_borderCellCss;_destroyed=!1;constructor(o,e,t=!0,n=!0,a,r,u){this._isNativeHtmlTable=o,this._stickCellCss=e,this._isBrowser=t,this._needsPositionStickyOnElement=n,this.direction=a,this._positionListener=r,this._tableInjector=u,this._borderCellCss={top:`${e}-border-elem-top`,bottom:`${e}-border-elem-bottom`,left:`${e}-border-elem-left`,right:`${e}-border-elem-right`}}clearStickyPositioning(o,e){(e.includes("left")||e.includes("right"))&&this._removeFromStickyColumnReplayQueue(o);let t=[];for(let n of o)n.nodeType===n.ELEMENT_NODE&&t.push(n,...Array.from(n.children));Be({write:()=>{for(let n of t)this._removeStickyStyle(n,e)}},{injector:this._tableInjector})}updateStickyColumns(o,e,t,n=!0,a=!0){if(!o.length||!this._isBrowser||!(e.some(se=>se)||t.some(se=>se))){this._positionListener?.stickyColumnsUpdated({sizes:[]}),this._positionListener?.stickyEndColumnsUpdated({sizes:[]});return}let r=o[0],u=r.children.length,h=this.direction==="rtl",g=h?"right":"left",_=h?"left":"right",w=e.lastIndexOf(!0),B=t.indexOf(!0),G,ie,fe;a&&this._updateStickyColumnReplayQueue({rows:[...o],stickyStartStates:[...e],stickyEndStates:[...t]}),Be({earlyRead:()=>{G=this._getCellWidths(r,n),ie=this._getStickyStartColumnPositions(G,e),fe=this._getStickyEndColumnPositions(G,t)},write:()=>{for(let se of o)for(let Ae=0;Ae<u;Ae++){let lt=se.children[Ae];e[Ae]&&this._addStickyStyle(lt,g,ie[Ae],Ae===w),t[Ae]&&this._addStickyStyle(lt,_,fe[Ae],Ae===B)}this._positionListener&&G.some(se=>!!se)&&(this._positionListener.stickyColumnsUpdated({sizes:w===-1?[]:G.slice(0,w+1).map((se,Ae)=>e[Ae]?se:null)}),this._positionListener.stickyEndColumnsUpdated({sizes:B===-1?[]:G.slice(B).map((se,Ae)=>t[Ae+B]?se:null).reverse()}))}},{injector:this._tableInjector})}stickRows(o,e,t){if(!this._isBrowser)return;let n=t==="bottom"?o.slice().reverse():o,a=t==="bottom"?e.slice().reverse():e,r=[],u=[],h=[];Be({earlyRead:()=>{for(let g=0,_=0;g<n.length;g++){if(!a[g])continue;r[g]=_;let w=n[g];h[g]=this._isNativeHtmlTable?Array.from(w.children):[w];let B=this._retrieveElementSize(w).height;_+=B,u[g]=B}},write:()=>{let g=a.lastIndexOf(!0);for(let _=0;_<n.length;_++){if(!a[_])continue;let w=r[_],B=_===g;for(let G of h[_])this._addStickyStyle(G,t,w,B)}t==="top"?this._positionListener?.stickyHeaderRowsUpdated({sizes:u,offsets:r,elements:h}):this._positionListener?.stickyFooterRowsUpdated({sizes:u,offsets:r,elements:h})}},{injector:this._tableInjector})}updateStickyFooterContainer(o,e){this._isNativeHtmlTable&&Be({write:()=>{let t=o.querySelector("tfoot");t&&(e.some(n=>!n)?this._removeStickyStyle(t,["bottom"]):this._addStickyStyle(t,"bottom",0,!1))}},{injector:this._tableInjector})}destroy(){this._stickyColumnsReplayTimeout&&clearTimeout(this._stickyColumnsReplayTimeout),this._resizeObserver?.disconnect(),this._destroyed=!0}_removeStickyStyle(o,e){if(!o.classList.contains(this._stickCellCss))return;for(let n of e)o.style[n]="",o.classList.remove(this._borderCellCss[n]);lh.some(n=>e.indexOf(n)===-1&&o.style[n])?o.style.zIndex=this._getCalculatedZIndex(o):(o.style.zIndex="",this._needsPositionStickyOnElement&&(o.style.position=""),o.classList.remove(this._stickCellCss))}_addStickyStyle(o,e,t,n){o.classList.add(this._stickCellCss),n&&o.classList.add(this._borderCellCss[e]),o.style[e]=`${t}px`,o.style.zIndex=this._getCalculatedZIndex(o),this._needsPositionStickyOnElement&&(o.style.cssText+="position: -webkit-sticky; position: sticky; ")}_getCalculatedZIndex(o){let e={top:100,bottom:10,left:1,right:1},t=0;for(let n of lh)o.style[n]&&(t+=e[n]);return t?`${t}`:""}_getCellWidths(o,e=!0){if(!e&&this._cachedCellWidths.length)return this._cachedCellWidths;let t=[],n=o.children;for(let a=0;a<n.length;a++){let r=n[a];t.push(this._retrieveElementSize(r).width)}return this._cachedCellWidths=t,t}_getStickyStartColumnPositions(o,e){let t=[],n=0;for(let a=0;a<o.length;a++)e[a]&&(t[a]=n,n+=o[a]);return t}_getStickyEndColumnPositions(o,e){let t=[],n=0;for(let a=o.length;a>0;a--)e[a]&&(t[a]=n,n+=o[a]);return t}_retrieveElementSize(o){let e=this._elemSizeCache.get(o);if(e)return e;let t=o.getBoundingClientRect(),n={width:t.width,height:t.height};return this._resizeObserver&&(this._elemSizeCache.set(o,n),this._resizeObserver.observe(o,{box:"border-box"})),n}_updateStickyColumnReplayQueue(o){this._removeFromStickyColumnReplayQueue(o.rows),this._stickyColumnsReplayTimeout||this._updatedStickyColumnsParamsToReplay.push(o)}_removeFromStickyColumnReplayQueue(o){let e=new Set(o);for(let t of this._updatedStickyColumnsParamsToReplay)t.rows=t.rows.filter(n=>!e.has(n));this._updatedStickyColumnsParamsToReplay=this._updatedStickyColumnsParamsToReplay.filter(t=>!!t.rows.length)}_updateCachedSizes(o){let e=!1;for(let t of o){let n=t.borderBoxSize?.length?{width:t.borderBoxSize[0].inlineSize,height:t.borderBoxSize[0].blockSize}:{width:t.contentRect.width,height:t.contentRect.height};n.width!==this._elemSizeCache.get(t.target)?.width&&yv(t.target)&&(e=!0),this._elemSizeCache.set(t.target,n)}e&&this._updatedStickyColumnsParamsToReplay.length&&(this._stickyColumnsReplayTimeout&&clearTimeout(this._stickyColumnsReplayTimeout),this._stickyColumnsReplayTimeout=setTimeout(()=>{if(!this._destroyed){for(let t of this._updatedStickyColumnsParamsToReplay)this.updateStickyColumns(t.rows,t.stickyStartStates,t.stickyEndStates,!0,!1);this._updatedStickyColumnsParamsToReplay=[],this._stickyColumnsReplayTimeout=null}},0))}};function yv(i){return["cdk-cell","cdk-header-cell","cdk-footer-cell"].some(o=>i.classList.contains(o))}var wa=new C("STICKY_POSITIONING_LISTENER");var gc=(()=>{class i{viewContainer=d(Xe);elementRef=d(N);constructor(){let e=d(vi);e._rowOutlet=this,e._outletAssigned()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","rowOutlet",""]]})}return i})(),_c=(()=>{class i{viewContainer=d(Xe);elementRef=d(N);constructor(){let e=d(vi);e._headerRowOutlet=this,e._outletAssigned()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","headerRowOutlet",""]]})}return i})(),vc=(()=>{class i{viewContainer=d(Xe);elementRef=d(N);constructor(){let e=d(vi);e._footerRowOutlet=this,e._outletAssigned()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","footerRowOutlet",""]]})}return i})(),bc=(()=>{class i{viewContainer=d(Xe);elementRef=d(N);constructor(){let e=d(vi);e._noDataRowOutlet=this,e._outletAssigned()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","noDataRowOutlet",""]]})}return i})(),yc=(()=>{class i{_differs=d(Go);_changeDetectorRef=d(te);_elementRef=d(N);_dir=d(qe,{optional:!0});_platform=d(le);_viewRepeater;_viewportRuler=d(Gt);_injector=d(X);_virtualScrollViewport=d(sh,{optional:!0,host:!0});_positionListener=d(wa,{optional:!0})||d(wa,{optional:!0,skipSelf:!0});_document=d($);_data;_renderedRange;_onDestroy=new I;_renderRows;_renderChangeSubscription=null;_columnDefsByName=new Map;_rowDefs;_headerRowDefs;_footerRowDefs;_dataDiffer;_defaultRowDef=null;_customColumnDefs=new Set;_customRowDefs=new Set;_customHeaderRowDefs=new Set;_customFooterRowDefs=new Set;_customNoDataRow=null;_headerRowDefChanged=!0;_footerRowDefChanged=!0;_stickyColumnStylesNeedReset=!0;_forceRecalculateCellWidths=!0;_cachedRenderRowsMap=new Map;_isNativeHtmlTable;_stickyStyler;stickyCssClass="cdk-table-sticky";needsPositionStickyOnElement=!0;_isServer;_isShowingNoDataRow=!1;_hasAllOutlets=!1;_hasInitialized=!1;_headerRowStickyUpdates=new I;_footerRowStickyUpdates=new I;_disableVirtualScrolling=!1;_getCellRole(){if(this._cellRoleInternal===void 0){let e=this._elementRef.nativeElement.getAttribute("role");return e==="grid"||e==="treegrid"?"gridcell":"cell"}return this._cellRoleInternal}_cellRoleInternal=void 0;get trackBy(){return this._trackByFn}set trackBy(e){this._trackByFn=e}_trackByFn;get dataSource(){return this._dataSource}set dataSource(e){this._dataSource!==e&&(this._switchDataSource(e),this._changeDetectorRef.markForCheck())}_dataSource;_dataSourceChanges=new I;_dataStream=new I;get multiTemplateDataRows(){return this._multiTemplateDataRows}set multiTemplateDataRows(e){this._multiTemplateDataRows=e,this._rowOutlet&&this._rowOutlet.viewContainer.length&&(this._forceRenderDataRows(),this.updateStickyColumnStyles())}_multiTemplateDataRows=!1;get fixedLayout(){return this._virtualScrollEnabled()?!0:this._fixedLayout}set fixedLayout(e){this._fixedLayout=e,this._forceRecalculateCellWidths=!0,this._stickyColumnStylesNeedReset=!0}_fixedLayout=!1;recycleRows=!1;contentChanged=new K;viewChange=new Xn({start:0,end:Number.MAX_VALUE});_rowOutlet;_headerRowOutlet;_footerRowOutlet;_noDataRowOutlet;_contentColumnDefs;_contentRowDefs;_contentHeaderRowDefs;_contentFooterRowDefs;_noDataRow;get renderedRows(){return this._renderRows}constructor(){d(new Di("role"),{optional:!0})||this._elementRef.nativeElement.setAttribute("role","table"),this._isServer=!this._platform.isBrowser,this._isNativeHtmlTable=this._elementRef.nativeElement.nodeName==="TABLE",this._dataDiffer=this._differs.find([]).create((t,n)=>this.trackBy?this.trackBy(n.dataIndex,n.data):n)}ngOnInit(){this._setupStickyStyler(),this._viewportRuler.change().pipe(oe(this._onDestroy)).subscribe(()=>{this._forceRecalculateCellWidths=!0})}ngAfterContentInit(){this._viewRepeater=this.recycleRows||this._virtualScrollEnabled()?new is:new ns,this._virtualScrollEnabled()&&this._setupVirtualScrolling(this._virtualScrollViewport),this._hasInitialized=!0}ngAfterContentChecked(){this._canRender()&&this._render()}ngOnDestroy(){this._stickyStyler?.destroy(),[this._rowOutlet?.viewContainer,this._headerRowOutlet?.viewContainer,this._footerRowOutlet?.viewContainer,this._cachedRenderRowsMap,this._customColumnDefs,this._customRowDefs,this._customHeaderRowDefs,this._customFooterRowDefs,this._columnDefsByName].forEach(e=>{e?.clear()}),this._headerRowDefs=[],this._footerRowDefs=[],this._defaultRowDef=null,this._headerRowStickyUpdates.complete(),this._footerRowStickyUpdates.complete(),this._onDestroy.next(),this._onDestroy.complete(),ts(this.dataSource)&&this.dataSource.disconnect(this)}renderRows(){this._renderRows=this._getAllRenderRows();let e=this._dataDiffer.diff(this._renderRows);if(!e){this._updateNoDataRow(),this.contentChanged.next();return}let t=this._rowOutlet.viewContainer;this._viewRepeater.applyChanges(e,t,(n,a,r)=>this._getEmbeddedViewArgs(n.item,r),n=>n.item.data,n=>{n.operation===gi.INSERTED&&n.context&&this._renderCellTemplateForItem(n.record.item.rowDef,n.context)}),this._updateRowIndexContext(),e.forEachIdentityChange(n=>{let a=t.get(n.currentIndex);a.context.$implicit=n.item.data}),this._updateNoDataRow(),this.contentChanged.next(),this.updateStickyColumnStyles()}addColumnDef(e){this._customColumnDefs.add(e)}removeColumnDef(e){this._customColumnDefs.delete(e)}addRowDef(e){this._customRowDefs.add(e)}removeRowDef(e){this._customRowDefs.delete(e)}addHeaderRowDef(e){this._customHeaderRowDefs.add(e),this._headerRowDefChanged=!0}removeHeaderRowDef(e){this._customHeaderRowDefs.delete(e),this._headerRowDefChanged=!0}addFooterRowDef(e){this._customFooterRowDefs.add(e),this._footerRowDefChanged=!0}removeFooterRowDef(e){this._customFooterRowDefs.delete(e),this._footerRowDefChanged=!0}setNoDataRow(e){this._customNoDataRow=e}updateStickyHeaderRowStyles(){let e=this._getRenderedRows(this._headerRowOutlet);if(this._isNativeHtmlTable){let n=ch(this._headerRowOutlet,"thead");n&&(n.style.display=e.length?"":"none")}let t=this._headerRowDefs.map(n=>n.sticky);this._stickyStyler.clearStickyPositioning(e,["top"]),this._stickyStyler.stickRows(e,t,"top"),this._headerRowDefs.forEach(n=>n.resetStickyChanged())}updateStickyFooterRowStyles(){let e=this._getRenderedRows(this._footerRowOutlet);if(this._isNativeHtmlTable){let n=ch(this._footerRowOutlet,"tfoot");n&&(n.style.display=e.length?"":"none")}let t=this._footerRowDefs.map(n=>n.sticky);this._stickyStyler.clearStickyPositioning(e,["bottom"]),this._stickyStyler.stickRows(e,t,"bottom"),this._stickyStyler.updateStickyFooterContainer(this._elementRef.nativeElement,t),this._footerRowDefs.forEach(n=>n.resetStickyChanged())}updateStickyColumnStyles(){let e=this._getRenderedRows(this._headerRowOutlet),t=this._getRenderedRows(this._rowOutlet),n=this._getRenderedRows(this._footerRowOutlet);(this._isNativeHtmlTable&&!this.fixedLayout||this._stickyColumnStylesNeedReset)&&(this._stickyStyler.clearStickyPositioning([...e,...t,...n],["left","right"]),this._stickyColumnStylesNeedReset=!1),e.forEach((a,r)=>{this._addStickyColumnStyles([a],this._headerRowDefs[r])}),this._rowDefs.forEach(a=>{let r=[];for(let u=0;u<t.length;u++)this._renderRows[u].rowDef===a&&r.push(t[u]);this._addStickyColumnStyles(r,a)}),n.forEach((a,r)=>{this._addStickyColumnStyles([a],this._footerRowDefs[r])}),Array.from(this._columnDefsByName.values()).forEach(a=>a.resetStickyChanged())}stickyColumnsUpdated(e){this._positionListener?.stickyColumnsUpdated(e)}stickyEndColumnsUpdated(e){this._positionListener?.stickyEndColumnsUpdated(e)}stickyHeaderRowsUpdated(e){this._headerRowStickyUpdates.next(e),this._positionListener?.stickyHeaderRowsUpdated(e)}stickyFooterRowsUpdated(e){this._footerRowStickyUpdates.next(e),this._positionListener?.stickyFooterRowsUpdated(e)}_outletAssigned(){!this._hasAllOutlets&&this._rowOutlet&&this._headerRowOutlet&&this._footerRowOutlet&&this._noDataRowOutlet&&(this._hasAllOutlets=!0,this._canRender()&&this._render())}_canRender(){return this._hasAllOutlets&&this._hasInitialized}_render(){this._cacheRowDefs(),this._cacheColumnDefs(),!this._headerRowDefs.length&&!this._footerRowDefs.length&&this._rowDefs.length;let t=this._renderUpdatedColumns()||this._headerRowDefChanged||this._footerRowDefChanged;this._stickyColumnStylesNeedReset=this._stickyColumnStylesNeedReset||t,this._forceRecalculateCellWidths=t,this._headerRowDefChanged&&(this._forceRenderHeaderRows(),this._headerRowDefChanged=!1),this._footerRowDefChanged&&(this._forceRenderFooterRows(),this._footerRowDefChanged=!1),this.dataSource&&this._rowDefs.length>0&&!this._renderChangeSubscription?this._observeRenderChanges():this._stickyColumnStylesNeedReset&&this.updateStickyColumnStyles(),this._checkStickyStates()}_getAllRenderRows(){if(!Array.isArray(this._data)||!this._renderedRange)return[];let e=[],t=Math.min(this._data.length,this._renderedRange.end),n=this._cachedRenderRowsMap;this._cachedRenderRowsMap=new Map;for(let a=this._renderedRange.start;a<t;a++){let r=this._data[a],u=this._getRenderRowsForData(r,a,n.get(r));this._cachedRenderRowsMap.has(r)||this._cachedRenderRowsMap.set(r,new WeakMap);for(let h=0;h<u.length;h++){let g=u[h],_=this._cachedRenderRowsMap.get(g.data);_.has(g.rowDef)?_.get(g.rowDef).push(g):_.set(g.rowDef,[g]),e.push(g)}}return e}_getRenderRowsForData(e,t,n){return this._getRowDefs(e,t).map(r=>{let u=n&&n.has(r)?n.get(r):[];if(u.length){let h=u.shift();return h.dataIndex=t,h}else return{data:e,rowDef:r,dataIndex:t}})}_cacheColumnDefs(){this._columnDefsByName.clear(),os(this._getOwnDefs(this._contentColumnDefs),this._customColumnDefs).forEach(t=>{this._columnDefsByName.has(t.name),this._columnDefsByName.set(t.name,t)})}_cacheRowDefs(){this._headerRowDefs=os(this._getOwnDefs(this._contentHeaderRowDefs),this._customHeaderRowDefs),this._footerRowDefs=os(this._getOwnDefs(this._contentFooterRowDefs),this._customFooterRowDefs),this._rowDefs=os(this._getOwnDefs(this._contentRowDefs),this._customRowDefs);let e=this._rowDefs.filter(t=>!t.when);this._defaultRowDef=e[0]}_renderUpdatedColumns(){let e=(r,u)=>{let h=!!u.getColumnsDiff();return r||h},t=this._rowDefs.reduce(e,!1);t&&this._forceRenderDataRows();let n=this._headerRowDefs.reduce(e,!1);n&&this._forceRenderHeaderRows();let a=this._footerRowDefs.reduce(e,!1);return a&&this._forceRenderFooterRows(),t||n||a}_switchDataSource(e){this._data=[],ts(this.dataSource)&&this.dataSource.disconnect(this),this._renderChangeSubscription&&(this._renderChangeSubscription.unsubscribe(),this._renderChangeSubscription=null),e||(this._dataDiffer&&this._dataDiffer.diff([]),this._rowOutlet&&this._rowOutlet.viewContainer.clear()),this._dataSource=e}_observeRenderChanges(){if(!this.dataSource)return;let e;ts(this.dataSource)?e=this.dataSource.connect(this):Vs(this.dataSource)?e=this.dataSource:Array.isArray(this.dataSource)&&(e=ge(this.dataSource)),this._renderChangeSubscription=Zn([e,this.viewChange]).pipe(oe(this._onDestroy)).subscribe(([t,n])=>{this._data=t||[],this._renderedRange=n,this._dataStream.next(t),this.renderRows()})}_forceRenderHeaderRows(){this._headerRowOutlet.viewContainer.length>0&&this._headerRowOutlet.viewContainer.clear(),this._headerRowDefs.forEach((e,t)=>this._renderRow(this._headerRowOutlet,e,t)),this.updateStickyHeaderRowStyles()}_forceRenderFooterRows(){this._footerRowOutlet.viewContainer.length>0&&this._footerRowOutlet.viewContainer.clear(),this._footerRowDefs.forEach((e,t)=>this._renderRow(this._footerRowOutlet,e,t)),this.updateStickyFooterRowStyles()}_addStickyColumnStyles(e,t){let n=Array.from(t?.columns||[]).map(u=>{let h=this._columnDefsByName.get(u);return h}),a=n.map(u=>u.sticky),r=n.map(u=>u.stickyEnd);this._stickyStyler.updateStickyColumns(e,a,r,!this.fixedLayout||this._forceRecalculateCellWidths)}_getRenderedRows(e){let t=[];for(let n=0;n<e.viewContainer.length;n++){let a=e.viewContainer.get(n);t.push(a.rootNodes[0])}return t}_getRowDefs(e,t){if(this._rowDefs.length===1)return[this._rowDefs[0]];let n=[];if(this.multiTemplateDataRows)n=this._rowDefs.filter(a=>!a.when||a.when(t,e));else{let a=this._rowDefs.find(r=>r.when&&r.when(t,e))||this._defaultRowDef;a&&n.push(a)}return n.length,n}_getEmbeddedViewArgs(e,t){let n=e.rowDef,a={$implicit:e.data};return{templateRef:n.template,context:a,index:t}}_renderRow(e,t,n,a={}){let r=e.viewContainer.createEmbeddedView(t.template,a,n);return this._renderCellTemplateForItem(t,a),r}_renderCellTemplateForItem(e,t){for(let n of this._getCellTemplates(e))Da.mostRecentCellOutlet&&Da.mostRecentCellOutlet._viewContainer.createEmbeddedView(n,t);this._changeDetectorRef.markForCheck()}_updateRowIndexContext(){let e=this._rowOutlet.viewContainer;for(let t=0,n=e.length;t<n;t++){let r=e.get(t).context;r.count=n,r.first=t===0,r.last=t===n-1,r.even=t%2===0,r.odd=!r.even,this.multiTemplateDataRows?(r.dataIndex=this._renderRows[t].dataIndex,r.renderIndex=t):r.index=this._renderRows[t].dataIndex}}_getCellTemplates(e){return!e||!e.columns?[]:Array.from(e.columns,t=>{let n=this._columnDefsByName.get(t);return e.extractCellTemplate(n)})}_forceRenderDataRows(){this._dataDiffer.diff([]),this._rowOutlet.viewContainer.clear(),this.renderRows()}_checkStickyStates(){let e=(t,n)=>t||n.hasStickyChanged();this._headerRowDefs.reduce(e,!1)&&this.updateStickyHeaderRowStyles(),this._footerRowDefs.reduce(e,!1)&&this.updateStickyFooterRowStyles(),Array.from(this._columnDefsByName.values()).reduce(e,!1)&&(this._stickyColumnStylesNeedReset=!0,this.updateStickyColumnStyles())}_setupStickyStyler(){let e=this._dir?this._dir.value:"ltr",t=this._injector;this._stickyStyler=new mc(this._isNativeHtmlTable,this.stickyCssClass,this._platform.isBrowser,this.needsPositionStickyOnElement,e,this,t),(this._dir?this._dir.change:ge()).pipe(oe(this._onDestroy)).subscribe(n=>{this._stickyStyler.direction=n,this.updateStickyColumnStyles()})}_setupVirtualScrolling(e){let t=typeof requestAnimationFrame<"u"?Ls:Ns;this.viewChange.next({start:0,end:0}),e.renderedRangeStream.pipe(Vo(0,t),oe(this._onDestroy)).subscribe(this.viewChange),e.attach({dataStream:this._dataStream,measureRangeSize:(n,a)=>this._measureRangeSize(n,a)}),Zn([e.renderedContentOffset,this._headerRowStickyUpdates]).pipe(oe(this._onDestroy)).subscribe(([n,a])=>{if(!(!a.sizes||!a.offsets||!a.elements))for(let r=0;r<a.elements.length;r++){let u=a.elements[r];if(u){let h=a.offsets[r],g=n!==0?Math.max(n-h,h):-h;for(let _ of u)_.style.top=`${-g}px`}}}),Zn([e.renderedContentOffset,this._footerRowStickyUpdates]).pipe(oe(this._onDestroy)).subscribe(([n,a])=>{if(!(!a.sizes||!a.offsets||!a.elements))for(let r=0;r<a.elements.length;r++){let u=a.elements[r];if(u)for(let h of u)h.style.bottom=`${n+a.offsets[r]}px`}})}_getOwnDefs(e){return e.filter(t=>!t._table||t._table===this)}_updateNoDataRow(){let e=this._customNoDataRow||this._noDataRow;if(!e)return;let t=this._rowOutlet.viewContainer.length===0;if(t===this._isShowingNoDataRow)return;let n=this._noDataRowOutlet.viewContainer;if(t){let a=n.createEmbeddedView(e.templateRef),r=a.rootNodes[0];if(a.rootNodes.length===1&&r?.nodeType===this._document.ELEMENT_NODE){r.setAttribute("role","row"),r.classList.add(...e._contentClassNames);let u=r.querySelectorAll(e._cellSelector);for(let h=0;h<u.length;h++)u[h].classList.add(...e._cellClassNames)}}else n.clear();this._isShowingNoDataRow=t,this._changeDetectorRef.markForCheck()}_measureRangeSize(e,t){if(e.start>=e.end||t!=="vertical")return 0;let n=this.viewChange.value,a=this._rowOutlet.viewContainer;e.start<n.start||e.end>n.end;let r=e.start-n.start,u=e.end-e.start,h,g;for(let B=0;B<u;B++){let G=a.get(B+r);if(G&&G.rootNodes.length){h=g=G.rootNodes[0];break}}for(let B=u-1;B>-1;B--){let G=a.get(B+r);if(G&&G.rootNodes.length){g=G.rootNodes[G.rootNodes.length-1];break}}let _=h?.getBoundingClientRect?.(),w=g?.getBoundingClientRect?.();return _&&w?w.bottom-_.top:0}_virtualScrollEnabled(){return!this._disableVirtualScrolling&&this._virtualScrollViewport!=null}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["cdk-table"],["table","cdk-table",""]],contentQueries:function(t,n,a){if(t&1&&at(a,hh,5)(a,ka,5)(a,rs,5)(a,hc,5)(a,pc,5),t&2){let r;O(r=P())&&(n._noDataRow=r.first),O(r=P())&&(n._contentColumnDefs=r),O(r=P())&&(n._contentRowDefs=r),O(r=P())&&(n._contentHeaderRowDefs=r),O(r=P())&&(n._contentFooterRowDefs=r)}},hostAttrs:[1,"cdk-table"],hostVars:2,hostBindings:function(t,n){t&2&&p("cdk-table-fixed-layout",n.fixedLayout)},inputs:{trackBy:"trackBy",dataSource:"dataSource",multiTemplateDataRows:[2,"multiTemplateDataRows","multiTemplateDataRows",L],fixedLayout:[2,"fixedLayout","fixedLayout",L],recycleRows:[2,"recycleRows","recycleRows",L]},outputs:{contentChanged:"contentChanged"},exportAs:["cdkTable"],features:[J([{provide:vi,useExisting:i},{provide:wa,useValue:null}])],ngContentSelectors:gv,decls:5,vars:2,consts:[["role","rowgroup"],["headerRowOutlet",""],["rowOutlet",""],["noDataRowOutlet",""],["footerRowOutlet",""]],template:function(t,n){t&1&&(ce(fv),U(0),U(1,1),M(2,_v,1,0),M(3,vv,7,0)(4,bv,4,0)),t&2&&(c(2),E(n._isServer?2:-1),c(),E(n._isNativeHtmlTable?3:4))},dependencies:[_c,gc,bc,vc],styles:[`.cdk-table-fixed-layout {
2223
+ `],encapsulation:2})}return i})(),Ft=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();var rh=(()=>{class i{constructor(){this.http=d(Qt),this.staticUrl="/api/gpus",this.usageUrl="/api/gpus/usage"}fetchGpus(){return this.http.get(this.staticUrl).pipe(di({error:e=>console.error("[GpuService] static fetch error:",e)}))}fetchStatus(){return this.http.get(this.usageUrl).pipe(di({error:e=>console.error("[GpuService] status fetch error:",e)}))}watchStatus(e){return Ya(0,e).pipe(We(()=>this.fetchStatus()))}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();function os(i){return i&&typeof i.connect=="function"&&!(i instanceof Gc)}var gi=(function(i){return i[i.REPLACED=0]="REPLACED",i[i.INSERTED=1]="INSERTED",i[i.MOVED=2]="MOVED",i[i.REMOVED=3]="REMOVED",i})(gi||{}),as=class{viewCacheSize=20;_viewCache=[];applyChanges(o,e,t,n,a){o.forEachOperation((r,u,h)=>{let g,_;if(r.previousIndex==null){let w=()=>t(r,u,h);g=this._insertView(w,h,e,n(r)),_=g?gi.INSERTED:gi.REPLACED}else h==null?(this._detachAndCacheView(u,e),_=gi.REMOVED):(g=this._moveView(u,h,e,n(r)),_=gi.MOVED);a&&a({context:g?.context,operation:_,record:r})})}detach(){for(let o of this._viewCache)o.destroy();this._viewCache=[]}_insertView(o,e,t,n){let a=this._insertViewFromCache(e,t);if(a){a.context.$implicit=n;return}let r=o();return t.createEmbeddedView(r.templateRef,r.context,r.index)}_detachAndCacheView(o,e){let t=e.detach(o);this._maybeCacheView(t,e)}_moveView(o,e,t,n){let a=t.get(o);return t.move(a,e),a.context.$implicit=n,a}_maybeCacheView(o,e){if(this._viewCache.length<this.viewCacheSize)this._viewCache.push(o);else{let t=e.indexOf(o);t===-1?o.destroy():e.remove(t)}}_insertViewFromCache(o,e){let t=this._viewCache.pop();return t&&e.insert(t,o),t||null}};var uv=20,gn=(()=>{class i{_ngZone=d(H);_platform=d(le);_renderer=d(ot).createRenderer(null,null);_cleanupGlobalListener;_scrolled=new I;_scrolledCount=0;scrollContainers=new Map;register(e){this.scrollContainers.has(e)||this.scrollContainers.set(e,e.elementScrolled().subscribe(()=>this._scrolled.next(e)))}deregister(e){let t=this.scrollContainers.get(e);t&&(t.unsubscribe(),this.scrollContainers.delete(e))}scrolled(e=uv){return this._platform.isBrowser?new yt(t=>{this._cleanupGlobalListener||(this._cleanupGlobalListener=this._ngZone.runOutsideAngular(()=>this._renderer.listen("document","scroll",()=>this._scrolled.next())));let n=e>0?this._scrolled.pipe(zo(e)).subscribe(t):this._scrolled.subscribe(t);return this._scrolledCount++,()=>{n.unsubscribe(),this._scrolledCount--,this._scrolledCount||(this._cleanupGlobalListener?.(),this._cleanupGlobalListener=void 0)}}):ge()}ngOnDestroy(){this._cleanupGlobalListener?.(),this._cleanupGlobalListener=void 0,this.scrollContainers.forEach((e,t)=>this.deregister(t)),this._scrolled.complete()}ancestorScrolled(e,t){let n=this.getAncestorScrollContainers(e);return this.scrolled(t).pipe(Ce(a=>!a||n.indexOf(a)>-1))}getAncestorScrollContainers(e){let t=[];return this.scrollContainers.forEach((n,a)=>{this._targetContainsElement(a,e)&&t.push(a)}),t}_targetContainsElement(e,t){let n=Dt(t),a=e.getElementRef().nativeElement;do if(n==a)return!0;while(n=n.parentElement);return!1}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),dc=(()=>{class i{elementRef=d(N);scrollDispatcher=d(gn);ngZone=d(H);dir=d(qe,{optional:!0});_scrollElement=this.elementRef.nativeElement;_destroyed=new I;_renderer=d(ve);_cleanupScroll;_elementScrolled=new I;ngOnInit(){this._cleanupScroll=this.ngZone.runOutsideAngular(()=>this._renderer.listen(this._scrollElement,"scroll",e=>this._elementScrolled.next(e))),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(e){let t=this.elementRef.nativeElement,n=this.dir&&this.dir.value=="rtl";e.left==null&&(e.left=n?e.end:e.start),e.right==null&&(e.right=n?e.start:e.end),e.bottom!=null&&(e.top=t.scrollHeight-t.clientHeight-e.bottom),n&&uo()!=fi.NORMAL?(e.left!=null&&(e.right=t.scrollWidth-t.clientWidth-e.left),uo()==fi.INVERTED?e.left=e.right:uo()==fi.NEGATED&&(e.left=e.right?-e.right:e.right)):e.right!=null&&(e.left=t.scrollWidth-t.clientWidth-e.right),this._applyScrollToOptions(e)}_applyScrollToOptions(e){let t=this.elementRef.nativeElement;Or()?t.scrollTo(e):(e.top!=null&&(t.scrollTop=e.top),e.left!=null&&(t.scrollLeft=e.left))}measureScrollOffset(e){let t="left",n="right",a=this.elementRef.nativeElement;if(e=="top")return a.scrollTop;if(e=="bottom")return a.scrollHeight-a.clientHeight-a.scrollTop;let r=this.dir&&this.dir.value=="rtl";return e=="start"?e=r?n:t:e=="end"&&(e=r?t:n),r&&uo()==fi.INVERTED?e==t?a.scrollWidth-a.clientWidth-a.scrollLeft:a.scrollLeft:r&&uo()==fi.NEGATED?e==t?a.scrollLeft+a.scrollWidth-a.clientWidth:-a.scrollLeft:e==t?a.scrollLeft:a.scrollWidth-a.clientWidth-a.scrollLeft}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdk-scrollable",""],["","cdkScrollable",""]]})}return i})(),hv=20,Gt=(()=>{class i{_platform=d(le);_listeners;_viewportSize=null;_change=new I;_document=d(W);constructor(){let e=d(H),t=d(ot).createRenderer(null,null);e.runOutsideAngular(()=>{if(this._platform.isBrowser){let n=a=>this._change.next(a);this._listeners=[t.listen("window","resize",n),t.listen("window","orientationchange",n)]}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){this._listeners?.forEach(e=>e()),this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();let e={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),e}getViewportRect(){let e=this.getViewportScrollPosition(),{width:t,height:n}=this.getViewportSize();return{top:e.top,left:e.left,bottom:e.top+n,right:e.left+t,height:n,width:t}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};let e=this._document,t=this._getWindow(),n=e.documentElement,a=n.getBoundingClientRect(),r=-a.top||e.body?.scrollTop||t.scrollY||n.scrollTop||0,u=-a.left||e.body?.scrollLeft||t.scrollX||n.scrollLeft||0;return{top:r,left:u}}change(e=hv){return e>0?this._change.pipe(zo(e)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){let e=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:e.innerWidth,height:e.innerHeight}:{width:0,height:0}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var sh=new x("CDK_VIRTUAL_SCROLL_VIEWPORT");var _i=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})(),Da=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee,_i,ee,_i]})}return i})();var rs=class{applyChanges(o,e,t,n,a){o.forEachOperation((r,u,h)=>{let g,_;if(r.previousIndex==null){let w=t(r,u,h);g=e.createEmbeddedView(w.templateRef,w.context,w.index),_=gi.INSERTED}else h==null?(e.remove(u),_=gi.REMOVED):(g=e.get(u),e.move(g,h),_=gi.MOVED);a&&a({context:g?.context,operation:_,record:r})})}detach(){}};var fv=[[["caption"]],[["colgroup"],["col"]],"*"],gv=["caption","colgroup, col","*"];function _v(i,o){i&1&&U(0,2)}function vv(i,o){i&1&&(s(0,"thead",0),Yt(1,1),l(),s(2,"tbody",0),Yt(3,2)(4,3),l(),s(5,"tfoot",0),Yt(6,4),l())}function bv(i,o){i&1&&Yt(0,1)(1,2)(2,3)(3,4)}var vi=new x("CDK_TABLE");var ls=(()=>{class i{template=d(Ye);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkCellDef",""]]})}return i})(),dh=(()=>{class i{template=d(Ye);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkHeaderCellDef",""]]})}return i})(),mh=(()=>{class i{template=d(Ye);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkFooterCellDef",""]]})}return i})(),Ma=(()=>{class i{_table=d(vi,{optional:!0});_hasStickyChanged=!1;get name(){return this._name}set name(e){this._setNameInput(e)}_name;get sticky(){return this._sticky}set sticky(e){e!==this._sticky&&(this._sticky=e,this._hasStickyChanged=!0)}_sticky=!1;get stickyEnd(){return this._stickyEnd}set stickyEnd(e){e!==this._stickyEnd&&(this._stickyEnd=e,this._hasStickyChanged=!0)}_stickyEnd=!1;cell;headerCell;footerCell;cssClassFriendlyName;_columnCssClassName;hasStickyChanged(){let e=this._hasStickyChanged;return this.resetStickyChanged(),e}resetStickyChanged(){this._hasStickyChanged=!1}_updateColumnCssClassName(){this._columnCssClassName=[`cdk-column-${this.cssClassFriendlyName}`]}_setNameInput(e){e&&(this._name=e,this.cssClassFriendlyName=e.replace(/[^a-z0-9_-]/gi,"-"),this._updateColumnCssClassName())}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkColumnDef",""]],contentQueries:function(t,n,a){if(t&1&&at(a,ls,5)(a,dh,5)(a,mh,5),t&2){let r;O(r=P())&&(n.cell=r.first),O(r=P())&&(n.headerCell=r.first),O(r=P())&&(n.footerCell=r.first)}},inputs:{name:[0,"cdkColumnDef","name"],sticky:[2,"sticky","sticky",L],stickyEnd:[2,"stickyEnd","stickyEnd",L]}})}return i})(),mc=class{constructor(o,e){e.nativeElement.classList.add(...o._columnCssClassName)}};var uh=(()=>{class i extends mc{constructor(){let e=d(Ma),t=d(N);super(e,t);let n=e._table?._getCellRole();n&&t.nativeElement.setAttribute("role",n)}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["cdk-cell"],["td","cdk-cell",""]],hostAttrs:[1,"cdk-cell"],features:[Q]})}return i})();var hc=(()=>{class i{template=d(Ye);_differs=d(Wo);columns;_columnsDiffer;ngOnChanges(e){if(!this._columnsDiffer){let t=e.columns&&e.columns.currentValue||[];this._columnsDiffer=this._differs.find(t).create(),this._columnsDiffer.diff(t)}}getColumnsDiff(){return this._columnsDiffer.diff(this.columns)}extractCellTemplate(e){return this instanceof pc?e.headerCell.template:this instanceof fc?e.footerCell.template:e.cell.template}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,features:[Se]})}return i})(),pc=(()=>{class i extends hc{_table=d(vi,{optional:!0});_hasStickyChanged=!1;get sticky(){return this._sticky}set sticky(e){e!==this._sticky&&(this._sticky=e,this._hasStickyChanged=!0)}_sticky=!1;ngOnChanges(e){super.ngOnChanges(e)}hasStickyChanged(){let e=this._hasStickyChanged;return this.resetStickyChanged(),e}resetStickyChanged(){this._hasStickyChanged=!1}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","cdkHeaderRowDef",""]],inputs:{columns:[0,"cdkHeaderRowDef","columns"],sticky:[2,"cdkHeaderRowDefSticky","sticky",L]},features:[Q,Se]})}return i})(),fc=(()=>{class i extends hc{_table=d(vi,{optional:!0});_hasStickyChanged=!1;get sticky(){return this._sticky}set sticky(e){e!==this._sticky&&(this._sticky=e,this._hasStickyChanged=!0)}_sticky=!1;ngOnChanges(e){super.ngOnChanges(e)}hasStickyChanged(){let e=this._hasStickyChanged;return this.resetStickyChanged(),e}resetStickyChanged(){this._hasStickyChanged=!1}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","cdkFooterRowDef",""]],inputs:{columns:[0,"cdkFooterRowDef","columns"],sticky:[2,"cdkFooterRowDefSticky","sticky",L]},features:[Q,Se]})}return i})(),cs=(()=>{class i extends hc{_table=d(vi,{optional:!0});when;static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","cdkRowDef",""]],inputs:{columns:[0,"cdkRowDefColumns","columns"],when:[0,"cdkRowDefWhen","when"]},features:[Q]})}return i})(),Sa=(()=>{class i{_viewContainer=d(Xe);cells;context;static mostRecentCellOutlet=null;constructor(){i.mostRecentCellOutlet=this}ngOnDestroy(){i.mostRecentCellOutlet===this&&(i.mostRecentCellOutlet=null)}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdkCellOutlet",""]]})}return i})();var gc=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["cdk-row"],["tr","cdk-row",""]],hostAttrs:["role","row",1,"cdk-row"],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(t,n){t&1&&Yt(0,0)},dependencies:[Sa],encapsulation:2,changeDetection:1})}return i})(),hh=(()=>{class i{templateRef=d(Ye);_contentClassNames=["cdk-no-data-row","cdk-row"];_cellClassNames=["cdk-cell","cdk-no-data-cell"];_cellSelector="td, cdk-cell, [cdk-cell], .cdk-cell";static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["ng-template","cdkNoDataRow",""]]})}return i})(),lh=["top","bottom","left","right"],uc=class{_isNativeHtmlTable;_stickCellCss;_isBrowser;_needsPositionStickyOnElement;direction;_positionListener;_tableInjector;_elemSizeCache=new WeakMap;_resizeObserver=globalThis?.ResizeObserver?new globalThis.ResizeObserver(o=>this._updateCachedSizes(o)):null;_updatedStickyColumnsParamsToReplay=[];_stickyColumnsReplayTimeout=null;_cachedCellWidths=[];_borderCellCss;_destroyed=!1;constructor(o,e,t=!0,n=!0,a,r,u){this._isNativeHtmlTable=o,this._stickCellCss=e,this._isBrowser=t,this._needsPositionStickyOnElement=n,this.direction=a,this._positionListener=r,this._tableInjector=u,this._borderCellCss={top:`${e}-border-elem-top`,bottom:`${e}-border-elem-bottom`,left:`${e}-border-elem-left`,right:`${e}-border-elem-right`}}clearStickyPositioning(o,e){(e.includes("left")||e.includes("right"))&&this._removeFromStickyColumnReplayQueue(o);let t=[];for(let n of o)n.nodeType===n.ELEMENT_NODE&&t.push(n,...Array.from(n.children));Be({write:()=>{for(let n of t)this._removeStickyStyle(n,e)}},{injector:this._tableInjector})}updateStickyColumns(o,e,t,n=!0,a=!0){if(!o.length||!this._isBrowser||!(e.some(se=>se)||t.some(se=>se))){this._positionListener?.stickyColumnsUpdated({sizes:[]}),this._positionListener?.stickyEndColumnsUpdated({sizes:[]});return}let r=o[0],u=r.children.length,h=this.direction==="rtl",g=h?"right":"left",_=h?"left":"right",w=e.lastIndexOf(!0),B=t.indexOf(!0),G,ie,fe;a&&this._updateStickyColumnReplayQueue({rows:[...o],stickyStartStates:[...e],stickyEndStates:[...t]}),Be({earlyRead:()=>{G=this._getCellWidths(r,n),ie=this._getStickyStartColumnPositions(G,e),fe=this._getStickyEndColumnPositions(G,t)},write:()=>{for(let se of o)for(let Ae=0;Ae<u;Ae++){let lt=se.children[Ae];e[Ae]&&this._addStickyStyle(lt,g,ie[Ae],Ae===w),t[Ae]&&this._addStickyStyle(lt,_,fe[Ae],Ae===B)}this._positionListener&&G.some(se=>!!se)&&(this._positionListener.stickyColumnsUpdated({sizes:w===-1?[]:G.slice(0,w+1).map((se,Ae)=>e[Ae]?se:null)}),this._positionListener.stickyEndColumnsUpdated({sizes:B===-1?[]:G.slice(B).map((se,Ae)=>t[Ae+B]?se:null).reverse()}))}},{injector:this._tableInjector})}stickRows(o,e,t){if(!this._isBrowser)return;let n=t==="bottom"?o.slice().reverse():o,a=t==="bottom"?e.slice().reverse():e,r=[],u=[],h=[];Be({earlyRead:()=>{for(let g=0,_=0;g<n.length;g++){if(!a[g])continue;r[g]=_;let w=n[g];h[g]=this._isNativeHtmlTable?Array.from(w.children):[w];let B=this._retrieveElementSize(w).height;_+=B,u[g]=B}},write:()=>{let g=a.lastIndexOf(!0);for(let _=0;_<n.length;_++){if(!a[_])continue;let w=r[_],B=_===g;for(let G of h[_])this._addStickyStyle(G,t,w,B)}t==="top"?this._positionListener?.stickyHeaderRowsUpdated({sizes:u,offsets:r,elements:h}):this._positionListener?.stickyFooterRowsUpdated({sizes:u,offsets:r,elements:h})}},{injector:this._tableInjector})}updateStickyFooterContainer(o,e){this._isNativeHtmlTable&&Be({write:()=>{let t=o.querySelector("tfoot");t&&(e.some(n=>!n)?this._removeStickyStyle(t,["bottom"]):this._addStickyStyle(t,"bottom",0,!1))}},{injector:this._tableInjector})}destroy(){this._stickyColumnsReplayTimeout&&clearTimeout(this._stickyColumnsReplayTimeout),this._resizeObserver?.disconnect(),this._destroyed=!0}_removeStickyStyle(o,e){if(!o.classList.contains(this._stickCellCss))return;for(let n of e)o.style[n]="",o.classList.remove(this._borderCellCss[n]);lh.some(n=>e.indexOf(n)===-1&&o.style[n])?o.style.zIndex=this._getCalculatedZIndex(o):(o.style.zIndex="",this._needsPositionStickyOnElement&&(o.style.position=""),o.classList.remove(this._stickCellCss))}_addStickyStyle(o,e,t,n){o.classList.add(this._stickCellCss),n&&o.classList.add(this._borderCellCss[e]),o.style[e]=`${t}px`,o.style.zIndex=this._getCalculatedZIndex(o),this._needsPositionStickyOnElement&&(o.style.cssText+="position: -webkit-sticky; position: sticky; ")}_getCalculatedZIndex(o){let e={top:100,bottom:10,left:1,right:1},t=0;for(let n of lh)o.style[n]&&(t+=e[n]);return t?`${t}`:""}_getCellWidths(o,e=!0){if(!e&&this._cachedCellWidths.length)return this._cachedCellWidths;let t=[],n=o.children;for(let a=0;a<n.length;a++){let r=n[a];t.push(this._retrieveElementSize(r).width)}return this._cachedCellWidths=t,t}_getStickyStartColumnPositions(o,e){let t=[],n=0;for(let a=0;a<o.length;a++)e[a]&&(t[a]=n,n+=o[a]);return t}_getStickyEndColumnPositions(o,e){let t=[],n=0;for(let a=o.length;a>0;a--)e[a]&&(t[a]=n,n+=o[a]);return t}_retrieveElementSize(o){let e=this._elemSizeCache.get(o);if(e)return e;let t=o.getBoundingClientRect(),n={width:t.width,height:t.height};return this._resizeObserver&&(this._elemSizeCache.set(o,n),this._resizeObserver.observe(o,{box:"border-box"})),n}_updateStickyColumnReplayQueue(o){this._removeFromStickyColumnReplayQueue(o.rows),this._stickyColumnsReplayTimeout||this._updatedStickyColumnsParamsToReplay.push(o)}_removeFromStickyColumnReplayQueue(o){let e=new Set(o);for(let t of this._updatedStickyColumnsParamsToReplay)t.rows=t.rows.filter(n=>!e.has(n));this._updatedStickyColumnsParamsToReplay=this._updatedStickyColumnsParamsToReplay.filter(t=>!!t.rows.length)}_updateCachedSizes(o){let e=!1;for(let t of o){let n=t.borderBoxSize?.length?{width:t.borderBoxSize[0].inlineSize,height:t.borderBoxSize[0].blockSize}:{width:t.contentRect.width,height:t.contentRect.height};n.width!==this._elemSizeCache.get(t.target)?.width&&yv(t.target)&&(e=!0),this._elemSizeCache.set(t.target,n)}e&&this._updatedStickyColumnsParamsToReplay.length&&(this._stickyColumnsReplayTimeout&&clearTimeout(this._stickyColumnsReplayTimeout),this._stickyColumnsReplayTimeout=setTimeout(()=>{if(!this._destroyed){for(let t of this._updatedStickyColumnsParamsToReplay)this.updateStickyColumns(t.rows,t.stickyStartStates,t.stickyEndStates,!0,!1);this._updatedStickyColumnsParamsToReplay=[],this._stickyColumnsReplayTimeout=null}},0))}};function yv(i){return["cdk-cell","cdk-header-cell","cdk-footer-cell"].some(o=>i.classList.contains(o))}var ka=new x("STICKY_POSITIONING_LISTENER");var _c=(()=>{class i{viewContainer=d(Xe);elementRef=d(N);constructor(){let e=d(vi);e._rowOutlet=this,e._outletAssigned()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","rowOutlet",""]]})}return i})(),vc=(()=>{class i{viewContainer=d(Xe);elementRef=d(N);constructor(){let e=d(vi);e._headerRowOutlet=this,e._outletAssigned()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","headerRowOutlet",""]]})}return i})(),bc=(()=>{class i{viewContainer=d(Xe);elementRef=d(N);constructor(){let e=d(vi);e._footerRowOutlet=this,e._outletAssigned()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","footerRowOutlet",""]]})}return i})(),yc=(()=>{class i{viewContainer=d(Xe);elementRef=d(N);constructor(){let e=d(vi);e._noDataRowOutlet=this,e._outletAssigned()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","noDataRowOutlet",""]]})}return i})(),Cc=(()=>{class i{_differs=d(Wo);_changeDetectorRef=d(te);_elementRef=d(N);_dir=d(qe,{optional:!0});_platform=d(le);_viewRepeater;_viewportRuler=d(Gt);_injector=d(X);_virtualScrollViewport=d(sh,{optional:!0,host:!0});_positionListener=d(ka,{optional:!0})||d(ka,{optional:!0,skipSelf:!0});_document=d(W);_data;_renderedRange;_onDestroy=new I;_renderRows;_renderChangeSubscription=null;_columnDefsByName=new Map;_rowDefs;_headerRowDefs;_footerRowDefs;_dataDiffer;_defaultRowDef=null;_customColumnDefs=new Set;_customRowDefs=new Set;_customHeaderRowDefs=new Set;_customFooterRowDefs=new Set;_customNoDataRow=null;_headerRowDefChanged=!0;_footerRowDefChanged=!0;_stickyColumnStylesNeedReset=!0;_forceRecalculateCellWidths=!0;_cachedRenderRowsMap=new Map;_isNativeHtmlTable;_stickyStyler;stickyCssClass="cdk-table-sticky";needsPositionStickyOnElement=!0;_isServer;_isShowingNoDataRow=!1;_hasAllOutlets=!1;_hasInitialized=!1;_headerRowStickyUpdates=new I;_footerRowStickyUpdates=new I;_disableVirtualScrolling=!1;_getCellRole(){if(this._cellRoleInternal===void 0){let e=this._elementRef.nativeElement.getAttribute("role");return e==="grid"||e==="treegrid"?"gridcell":"cell"}return this._cellRoleInternal}_cellRoleInternal=void 0;get trackBy(){return this._trackByFn}set trackBy(e){this._trackByFn=e}_trackByFn;get dataSource(){return this._dataSource}set dataSource(e){this._dataSource!==e&&(this._switchDataSource(e),this._changeDetectorRef.markForCheck())}_dataSource;_dataSourceChanges=new I;_dataStream=new I;get multiTemplateDataRows(){return this._multiTemplateDataRows}set multiTemplateDataRows(e){this._multiTemplateDataRows=e,this._rowOutlet&&this._rowOutlet.viewContainer.length&&(this._forceRenderDataRows(),this.updateStickyColumnStyles())}_multiTemplateDataRows=!1;get fixedLayout(){return this._virtualScrollEnabled()?!0:this._fixedLayout}set fixedLayout(e){this._fixedLayout=e,this._forceRecalculateCellWidths=!0,this._stickyColumnStylesNeedReset=!0}_fixedLayout=!1;recycleRows=!1;contentChanged=new K;viewChange=new Qn({start:0,end:Number.MAX_VALUE});_rowOutlet;_headerRowOutlet;_footerRowOutlet;_noDataRowOutlet;_contentColumnDefs;_contentRowDefs;_contentHeaderRowDefs;_contentFooterRowDefs;_noDataRow;get renderedRows(){return this._renderRows}constructor(){d(new Di("role"),{optional:!0})||this._elementRef.nativeElement.setAttribute("role","table"),this._isServer=!this._platform.isBrowser,this._isNativeHtmlTable=this._elementRef.nativeElement.nodeName==="TABLE",this._dataDiffer=this._differs.find([]).create((t,n)=>this.trackBy?this.trackBy(n.dataIndex,n.data):n)}ngOnInit(){this._setupStickyStyler(),this._viewportRuler.change().pipe(oe(this._onDestroy)).subscribe(()=>{this._forceRecalculateCellWidths=!0})}ngAfterContentInit(){this._viewRepeater=this.recycleRows||this._virtualScrollEnabled()?new as:new rs,this._virtualScrollEnabled()&&this._setupVirtualScrolling(this._virtualScrollViewport),this._hasInitialized=!0}ngAfterContentChecked(){this._canRender()&&this._render()}ngOnDestroy(){this._stickyStyler?.destroy(),[this._rowOutlet?.viewContainer,this._headerRowOutlet?.viewContainer,this._footerRowOutlet?.viewContainer,this._cachedRenderRowsMap,this._customColumnDefs,this._customRowDefs,this._customHeaderRowDefs,this._customFooterRowDefs,this._columnDefsByName].forEach(e=>{e?.clear()}),this._headerRowDefs=[],this._footerRowDefs=[],this._defaultRowDef=null,this._headerRowStickyUpdates.complete(),this._footerRowStickyUpdates.complete(),this._onDestroy.next(),this._onDestroy.complete(),os(this.dataSource)&&this.dataSource.disconnect(this)}renderRows(){this._renderRows=this._getAllRenderRows();let e=this._dataDiffer.diff(this._renderRows);if(!e){this._updateNoDataRow(),this.contentChanged.next();return}let t=this._rowOutlet.viewContainer;this._viewRepeater.applyChanges(e,t,(n,a,r)=>this._getEmbeddedViewArgs(n.item,r),n=>n.item.data,n=>{n.operation===gi.INSERTED&&n.context&&this._renderCellTemplateForItem(n.record.item.rowDef,n.context)}),this._updateRowIndexContext(),e.forEachIdentityChange(n=>{let a=t.get(n.currentIndex);a.context.$implicit=n.item.data}),this._updateNoDataRow(),this.contentChanged.next(),this.updateStickyColumnStyles()}addColumnDef(e){this._customColumnDefs.add(e)}removeColumnDef(e){this._customColumnDefs.delete(e)}addRowDef(e){this._customRowDefs.add(e)}removeRowDef(e){this._customRowDefs.delete(e)}addHeaderRowDef(e){this._customHeaderRowDefs.add(e),this._headerRowDefChanged=!0}removeHeaderRowDef(e){this._customHeaderRowDefs.delete(e),this._headerRowDefChanged=!0}addFooterRowDef(e){this._customFooterRowDefs.add(e),this._footerRowDefChanged=!0}removeFooterRowDef(e){this._customFooterRowDefs.delete(e),this._footerRowDefChanged=!0}setNoDataRow(e){this._customNoDataRow=e}updateStickyHeaderRowStyles(){let e=this._getRenderedRows(this._headerRowOutlet);if(this._isNativeHtmlTable){let n=ch(this._headerRowOutlet,"thead");n&&(n.style.display=e.length?"":"none")}let t=this._headerRowDefs.map(n=>n.sticky);this._stickyStyler.clearStickyPositioning(e,["top"]),this._stickyStyler.stickRows(e,t,"top"),this._headerRowDefs.forEach(n=>n.resetStickyChanged())}updateStickyFooterRowStyles(){let e=this._getRenderedRows(this._footerRowOutlet);if(this._isNativeHtmlTable){let n=ch(this._footerRowOutlet,"tfoot");n&&(n.style.display=e.length?"":"none")}let t=this._footerRowDefs.map(n=>n.sticky);this._stickyStyler.clearStickyPositioning(e,["bottom"]),this._stickyStyler.stickRows(e,t,"bottom"),this._stickyStyler.updateStickyFooterContainer(this._elementRef.nativeElement,t),this._footerRowDefs.forEach(n=>n.resetStickyChanged())}updateStickyColumnStyles(){let e=this._getRenderedRows(this._headerRowOutlet),t=this._getRenderedRows(this._rowOutlet),n=this._getRenderedRows(this._footerRowOutlet);(this._isNativeHtmlTable&&!this.fixedLayout||this._stickyColumnStylesNeedReset)&&(this._stickyStyler.clearStickyPositioning([...e,...t,...n],["left","right"]),this._stickyColumnStylesNeedReset=!1),e.forEach((a,r)=>{this._addStickyColumnStyles([a],this._headerRowDefs[r])}),this._rowDefs.forEach(a=>{let r=[];for(let u=0;u<t.length;u++)this._renderRows[u].rowDef===a&&r.push(t[u]);this._addStickyColumnStyles(r,a)}),n.forEach((a,r)=>{this._addStickyColumnStyles([a],this._footerRowDefs[r])}),Array.from(this._columnDefsByName.values()).forEach(a=>a.resetStickyChanged())}stickyColumnsUpdated(e){this._positionListener?.stickyColumnsUpdated(e)}stickyEndColumnsUpdated(e){this._positionListener?.stickyEndColumnsUpdated(e)}stickyHeaderRowsUpdated(e){this._headerRowStickyUpdates.next(e),this._positionListener?.stickyHeaderRowsUpdated(e)}stickyFooterRowsUpdated(e){this._footerRowStickyUpdates.next(e),this._positionListener?.stickyFooterRowsUpdated(e)}_outletAssigned(){!this._hasAllOutlets&&this._rowOutlet&&this._headerRowOutlet&&this._footerRowOutlet&&this._noDataRowOutlet&&(this._hasAllOutlets=!0,this._canRender()&&this._render())}_canRender(){return this._hasAllOutlets&&this._hasInitialized}_render(){this._cacheRowDefs(),this._cacheColumnDefs(),!this._headerRowDefs.length&&!this._footerRowDefs.length&&this._rowDefs.length;let t=this._renderUpdatedColumns()||this._headerRowDefChanged||this._footerRowDefChanged;this._stickyColumnStylesNeedReset=this._stickyColumnStylesNeedReset||t,this._forceRecalculateCellWidths=t,this._headerRowDefChanged&&(this._forceRenderHeaderRows(),this._headerRowDefChanged=!1),this._footerRowDefChanged&&(this._forceRenderFooterRows(),this._footerRowDefChanged=!1),this.dataSource&&this._rowDefs.length>0&&!this._renderChangeSubscription?this._observeRenderChanges():this._stickyColumnStylesNeedReset&&this.updateStickyColumnStyles(),this._checkStickyStates()}_getAllRenderRows(){if(!Array.isArray(this._data)||!this._renderedRange)return[];let e=[],t=Math.min(this._data.length,this._renderedRange.end),n=this._cachedRenderRowsMap;this._cachedRenderRowsMap=new Map;for(let a=this._renderedRange.start;a<t;a++){let r=this._data[a],u=this._getRenderRowsForData(r,a,n.get(r));this._cachedRenderRowsMap.has(r)||this._cachedRenderRowsMap.set(r,new WeakMap);for(let h=0;h<u.length;h++){let g=u[h],_=this._cachedRenderRowsMap.get(g.data);_.has(g.rowDef)?_.get(g.rowDef).push(g):_.set(g.rowDef,[g]),e.push(g)}}return e}_getRenderRowsForData(e,t,n){return this._getRowDefs(e,t).map(r=>{let u=n&&n.has(r)?n.get(r):[];if(u.length){let h=u.shift();return h.dataIndex=t,h}else return{data:e,rowDef:r,dataIndex:t}})}_cacheColumnDefs(){this._columnDefsByName.clear(),ss(this._getOwnDefs(this._contentColumnDefs),this._customColumnDefs).forEach(t=>{this._columnDefsByName.has(t.name),this._columnDefsByName.set(t.name,t)})}_cacheRowDefs(){this._headerRowDefs=ss(this._getOwnDefs(this._contentHeaderRowDefs),this._customHeaderRowDefs),this._footerRowDefs=ss(this._getOwnDefs(this._contentFooterRowDefs),this._customFooterRowDefs),this._rowDefs=ss(this._getOwnDefs(this._contentRowDefs),this._customRowDefs);let e=this._rowDefs.filter(t=>!t.when);this._defaultRowDef=e[0]}_renderUpdatedColumns(){let e=(r,u)=>{let h=!!u.getColumnsDiff();return r||h},t=this._rowDefs.reduce(e,!1);t&&this._forceRenderDataRows();let n=this._headerRowDefs.reduce(e,!1);n&&this._forceRenderHeaderRows();let a=this._footerRowDefs.reduce(e,!1);return a&&this._forceRenderFooterRows(),t||n||a}_switchDataSource(e){this._data=[],os(this.dataSource)&&this.dataSource.disconnect(this),this._renderChangeSubscription&&(this._renderChangeSubscription.unsubscribe(),this._renderChangeSubscription=null),e||(this._dataDiffer&&this._dataDiffer.diff([]),this._rowOutlet&&this._rowOutlet.viewContainer.clear()),this._dataSource=e}_observeRenderChanges(){if(!this.dataSource)return;let e;os(this.dataSource)?e=this.dataSource.connect(this):Bs(this.dataSource)?e=this.dataSource:Array.isArray(this.dataSource)&&(e=ge(this.dataSource)),this._renderChangeSubscription=Jn([e,this.viewChange]).pipe(oe(this._onDestroy)).subscribe(([t,n])=>{this._data=t||[],this._renderedRange=n,this._dataStream.next(t),this.renderRows()})}_forceRenderHeaderRows(){this._headerRowOutlet.viewContainer.length>0&&this._headerRowOutlet.viewContainer.clear(),this._headerRowDefs.forEach((e,t)=>this._renderRow(this._headerRowOutlet,e,t)),this.updateStickyHeaderRowStyles()}_forceRenderFooterRows(){this._footerRowOutlet.viewContainer.length>0&&this._footerRowOutlet.viewContainer.clear(),this._footerRowDefs.forEach((e,t)=>this._renderRow(this._footerRowOutlet,e,t)),this.updateStickyFooterRowStyles()}_addStickyColumnStyles(e,t){let n=Array.from(t?.columns||[]).map(u=>{let h=this._columnDefsByName.get(u);return h}),a=n.map(u=>u.sticky),r=n.map(u=>u.stickyEnd);this._stickyStyler.updateStickyColumns(e,a,r,!this.fixedLayout||this._forceRecalculateCellWidths)}_getRenderedRows(e){let t=[];for(let n=0;n<e.viewContainer.length;n++){let a=e.viewContainer.get(n);t.push(a.rootNodes[0])}return t}_getRowDefs(e,t){if(this._rowDefs.length===1)return[this._rowDefs[0]];let n=[];if(this.multiTemplateDataRows)n=this._rowDefs.filter(a=>!a.when||a.when(t,e));else{let a=this._rowDefs.find(r=>r.when&&r.when(t,e))||this._defaultRowDef;a&&n.push(a)}return n.length,n}_getEmbeddedViewArgs(e,t){let n=e.rowDef,a={$implicit:e.data};return{templateRef:n.template,context:a,index:t}}_renderRow(e,t,n,a={}){let r=e.viewContainer.createEmbeddedView(t.template,a,n);return this._renderCellTemplateForItem(t,a),r}_renderCellTemplateForItem(e,t){for(let n of this._getCellTemplates(e))Sa.mostRecentCellOutlet&&Sa.mostRecentCellOutlet._viewContainer.createEmbeddedView(n,t);this._changeDetectorRef.markForCheck()}_updateRowIndexContext(){let e=this._rowOutlet.viewContainer;for(let t=0,n=e.length;t<n;t++){let r=e.get(t).context;r.count=n,r.first=t===0,r.last=t===n-1,r.even=t%2===0,r.odd=!r.even,this.multiTemplateDataRows?(r.dataIndex=this._renderRows[t].dataIndex,r.renderIndex=t):r.index=this._renderRows[t].dataIndex}}_getCellTemplates(e){return!e||!e.columns?[]:Array.from(e.columns,t=>{let n=this._columnDefsByName.get(t);return e.extractCellTemplate(n)})}_forceRenderDataRows(){this._dataDiffer.diff([]),this._rowOutlet.viewContainer.clear(),this.renderRows()}_checkStickyStates(){let e=(t,n)=>t||n.hasStickyChanged();this._headerRowDefs.reduce(e,!1)&&this.updateStickyHeaderRowStyles(),this._footerRowDefs.reduce(e,!1)&&this.updateStickyFooterRowStyles(),Array.from(this._columnDefsByName.values()).reduce(e,!1)&&(this._stickyColumnStylesNeedReset=!0,this.updateStickyColumnStyles())}_setupStickyStyler(){let e=this._dir?this._dir.value:"ltr",t=this._injector;this._stickyStyler=new uc(this._isNativeHtmlTable,this.stickyCssClass,this._platform.isBrowser,this.needsPositionStickyOnElement,e,this,t),(this._dir?this._dir.change:ge()).pipe(oe(this._onDestroy)).subscribe(n=>{this._stickyStyler.direction=n,this.updateStickyColumnStyles()})}_setupVirtualScrolling(e){let t=typeof requestAnimationFrame<"u"?Vs:Ls;this.viewChange.next({start:0,end:0}),e.renderedRangeStream.pipe(zo(0,t),oe(this._onDestroy)).subscribe(this.viewChange),e.attach({dataStream:this._dataStream,measureRangeSize:(n,a)=>this._measureRangeSize(n,a)}),Jn([e.renderedContentOffset,this._headerRowStickyUpdates]).pipe(oe(this._onDestroy)).subscribe(([n,a])=>{if(!(!a.sizes||!a.offsets||!a.elements))for(let r=0;r<a.elements.length;r++){let u=a.elements[r];if(u){let h=a.offsets[r],g=n!==0?Math.max(n-h,h):-h;for(let _ of u)_.style.top=`${-g}px`}}}),Jn([e.renderedContentOffset,this._footerRowStickyUpdates]).pipe(oe(this._onDestroy)).subscribe(([n,a])=>{if(!(!a.sizes||!a.offsets||!a.elements))for(let r=0;r<a.elements.length;r++){let u=a.elements[r];if(u)for(let h of u)h.style.bottom=`${n+a.offsets[r]}px`}})}_getOwnDefs(e){return e.filter(t=>!t._table||t._table===this)}_updateNoDataRow(){let e=this._customNoDataRow||this._noDataRow;if(!e)return;let t=this._rowOutlet.viewContainer.length===0;if(t===this._isShowingNoDataRow)return;let n=this._noDataRowOutlet.viewContainer;if(t){let a=n.createEmbeddedView(e.templateRef),r=a.rootNodes[0];if(a.rootNodes.length===1&&r?.nodeType===this._document.ELEMENT_NODE){r.setAttribute("role","row"),r.classList.add(...e._contentClassNames);let u=r.querySelectorAll(e._cellSelector);for(let h=0;h<u.length;h++)u[h].classList.add(...e._cellClassNames)}}else n.clear();this._isShowingNoDataRow=t,this._changeDetectorRef.markForCheck()}_measureRangeSize(e,t){if(e.start>=e.end||t!=="vertical")return 0;let n=this.viewChange.value,a=this._rowOutlet.viewContainer;e.start<n.start||e.end>n.end;let r=e.start-n.start,u=e.end-e.start,h,g;for(let B=0;B<u;B++){let G=a.get(B+r);if(G&&G.rootNodes.length){h=g=G.rootNodes[0];break}}for(let B=u-1;B>-1;B--){let G=a.get(B+r);if(G&&G.rootNodes.length){g=G.rootNodes[G.rootNodes.length-1];break}}let _=h?.getBoundingClientRect?.(),w=g?.getBoundingClientRect?.();return _&&w?w.bottom-_.top:0}_virtualScrollEnabled(){return!this._disableVirtualScrolling&&this._virtualScrollViewport!=null}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["cdk-table"],["table","cdk-table",""]],contentQueries:function(t,n,a){if(t&1&&at(a,hh,5)(a,Ma,5)(a,cs,5)(a,pc,5)(a,fc,5),t&2){let r;O(r=P())&&(n._noDataRow=r.first),O(r=P())&&(n._contentColumnDefs=r),O(r=P())&&(n._contentRowDefs=r),O(r=P())&&(n._contentHeaderRowDefs=r),O(r=P())&&(n._contentFooterRowDefs=r)}},hostAttrs:[1,"cdk-table"],hostVars:2,hostBindings:function(t,n){t&2&&p("cdk-table-fixed-layout",n.fixedLayout)},inputs:{trackBy:"trackBy",dataSource:"dataSource",multiTemplateDataRows:[2,"multiTemplateDataRows","multiTemplateDataRows",L],fixedLayout:[2,"fixedLayout","fixedLayout",L],recycleRows:[2,"recycleRows","recycleRows",L]},outputs:{contentChanged:"contentChanged"},exportAs:["cdkTable"],features:[J([{provide:vi,useExisting:i},{provide:ka,useValue:null}])],ngContentSelectors:gv,decls:5,vars:2,consts:[["role","rowgroup"],["headerRowOutlet",""],["rowOutlet",""],["noDataRowOutlet",""],["footerRowOutlet",""]],template:function(t,n){t&1&&(ce(fv),U(0),U(1,1),M(2,_v,1,0),M(3,vv,7,0)(4,bv,4,0)),t&2&&(c(2),E(n._isServer?2:-1),c(),E(n._isNativeHtmlTable?3:4))},dependencies:[vc,_c,yc,bc],styles:[`.cdk-table-fixed-layout {
2224
2224
  table-layout: fixed;
2225
2225
  }
2226
- `],encapsulation:2,changeDetection:1})}return i})();function os(i,o){return i.concat(Array.from(o))}function ch(i,o){let e=o.toUpperCase(),t=i.viewContainer.element.nativeElement;for(;t;){let n=t.nodeType===1?t.nodeName:null;if(n===e)return t;if(n==="TABLE")break;t=t.parentNode}return null}var ph=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[xa]})}return i})();var Sa=class{_multiple;_emitChanges;compareWith;_selection=new Set;_deselectedToEmit=[];_selectedToEmit=[];_selected=null;get selected(){return this._selected||(this._selected=Array.from(this._selection.values())),this._selected}changed=new I;bulk={select:o=>this._select(o),deselect:o=>this._deselect(o),setSelection:o=>this._setSelection(o)};constructor(o=!1,e,t=!0,n){this._multiple=o,this._emitChanges=t,this.compareWith=n,e&&e.length&&(o?e.forEach(a=>this._markSelected(a)):this._markSelected(e[0]),this._selectedToEmit.length=0)}select(...o){return this._select(o)}deselect(...o){return this._deselect(o)}setSelection(...o){return this._setSelection(o)}toggle(o){return this.isSelected(o)?this.deselect(o):this.select(o)}clear(o=!0){this._unmarkAll();let e=this._hasQueuedChanges();return o&&this._emitChangeEvent(),e}isSelected(o){return this._selection.has(this._getConcreteValue(o))}isEmpty(){return this._selection.size===0}hasValue(){return!this.isEmpty()}sort(o){this._multiple&&this.selected&&this._selected.sort(o)}isMultipleSelection(){return this._multiple}_select(o){this._verifyValueAssignment(o),o.forEach(t=>this._markSelected(t));let e=this._hasQueuedChanges();return this._emitChangeEvent(),e}_deselect(o){this._verifyValueAssignment(o),o.forEach(t=>this._unmarkSelected(t));let e=this._hasQueuedChanges();return this._emitChangeEvent(),e}_setSelection(o){this._verifyValueAssignment(o);let e=this.selected,t=new Set(o.map(a=>this._getConcreteValue(a)));o.forEach(a=>this._markSelected(a)),e.filter(a=>!t.has(this._getConcreteValue(a,t))).forEach(a=>this._unmarkSelected(a));let n=this._hasQueuedChanges();return this._emitChangeEvent(),n}_emitChangeEvent(){this._selected=null,(this._selectedToEmit.length||this._deselectedToEmit.length)&&(this.changed.next({source:this,added:this._selectedToEmit,removed:this._deselectedToEmit}),this._deselectedToEmit=[],this._selectedToEmit=[])}_markSelected(o){o=this._getConcreteValue(o),this.isSelected(o)||(this._multiple||this._unmarkAll(),this.isSelected(o)||this._selection.add(o),this._emitChanges&&this._selectedToEmit.push(o))}_unmarkSelected(o){o=this._getConcreteValue(o),this.isSelected(o)&&(this._selection.delete(o),this._emitChanges&&this._deselectedToEmit.push(o))}_unmarkAll(){this.isEmpty()||this._selection.forEach(o=>this._unmarkSelected(o))}_verifyValueAssignment(o){o.length>1&&this._multiple}_hasQueuedChanges(){return!!(this._deselectedToEmit.length||this._selectedToEmit.length)}_getConcreteValue(o,e){if(this.compareWith){e=e??this._selection;for(let t of e)if(this.compareWith(o,t))return t;return o}else return o}};var Ma=(()=>{class i{_listeners=[];notify(e,t){for(let n of this._listeners)n(e,t)}listen(e){return this._listeners.push(e),()=>{this._listeners=this._listeners.filter(t=>e!==t)}}ngOnDestroy(){this._listeners=[]}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Cv=[[["caption"]],[["colgroup"],["col"]],"*"],xv=["caption","colgroup, col","*"];function wv(i,o){i&1&&U(0,2)}function Dv(i,o){i&1&&(s(0,"thead",0),Yt(1,1),l(),s(2,"tbody",2),Yt(3,3)(4,4),l(),s(5,"tfoot",0),Yt(6,5),l())}function kv(i,o){i&1&&Yt(0,1)(1,3)(2,4)(3,5)}var fh=(()=>{class i extends yc{stickyCssClass="mat-mdc-table-sticky";needsPositionStickyOnElement=!1;static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275cmp=T({type:i,selectors:[["mat-table"],["table","mat-table",""]],hostAttrs:[1,"mat-mdc-table","mdc-data-table__table"],hostVars:2,hostBindings:function(t,n){t&2&&p("mat-table-fixed-layout",n.fixedLayout)},exportAs:["matTable"],features:[J([{provide:yc,useExisting:i},{provide:vi,useExisting:i},{provide:wa,useValue:null}]),Q],ngContentSelectors:xv,decls:5,vars:2,consts:[["role","rowgroup"],["headerRowOutlet",""],["role","rowgroup",1,"mdc-data-table__content"],["rowOutlet",""],["noDataRowOutlet",""],["footerRowOutlet",""]],template:function(t,n){t&1&&(ce(Cv),U(0),U(1,1),M(2,wv,1,0),M(3,Dv,7,0)(4,kv,4,0)),t&2&&(c(2),E(n._isServer?2:-1),c(),E(n._isNativeHtmlTable?3:4))},dependencies:[_c,gc,bc,vc],styles:[`.mat-mdc-table-sticky {
2226
+ `],encapsulation:2,changeDetection:1})}return i})();function ss(i,o){return i.concat(Array.from(o))}function ch(i,o){let e=o.toUpperCase(),t=i.viewContainer.element.nativeElement;for(;t;){let n=t.nodeType===1?t.nodeName:null;if(n===e)return t;if(n==="TABLE")break;t=t.parentNode}return null}var ph=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Da]})}return i})();var Ea=class{_multiple;_emitChanges;compareWith;_selection=new Set;_deselectedToEmit=[];_selectedToEmit=[];_selected=null;get selected(){return this._selected||(this._selected=Array.from(this._selection.values())),this._selected}changed=new I;bulk={select:o=>this._select(o),deselect:o=>this._deselect(o),setSelection:o=>this._setSelection(o)};constructor(o=!1,e,t=!0,n){this._multiple=o,this._emitChanges=t,this.compareWith=n,e&&e.length&&(o?e.forEach(a=>this._markSelected(a)):this._markSelected(e[0]),this._selectedToEmit.length=0)}select(...o){return this._select(o)}deselect(...o){return this._deselect(o)}setSelection(...o){return this._setSelection(o)}toggle(o){return this.isSelected(o)?this.deselect(o):this.select(o)}clear(o=!0){this._unmarkAll();let e=this._hasQueuedChanges();return o&&this._emitChangeEvent(),e}isSelected(o){return this._selection.has(this._getConcreteValue(o))}isEmpty(){return this._selection.size===0}hasValue(){return!this.isEmpty()}sort(o){this._multiple&&this.selected&&this._selected.sort(o)}isMultipleSelection(){return this._multiple}_select(o){this._verifyValueAssignment(o),o.forEach(t=>this._markSelected(t));let e=this._hasQueuedChanges();return this._emitChangeEvent(),e}_deselect(o){this._verifyValueAssignment(o),o.forEach(t=>this._unmarkSelected(t));let e=this._hasQueuedChanges();return this._emitChangeEvent(),e}_setSelection(o){this._verifyValueAssignment(o);let e=this.selected,t=new Set(o.map(a=>this._getConcreteValue(a)));o.forEach(a=>this._markSelected(a)),e.filter(a=>!t.has(this._getConcreteValue(a,t))).forEach(a=>this._unmarkSelected(a));let n=this._hasQueuedChanges();return this._emitChangeEvent(),n}_emitChangeEvent(){this._selected=null,(this._selectedToEmit.length||this._deselectedToEmit.length)&&(this.changed.next({source:this,added:this._selectedToEmit,removed:this._deselectedToEmit}),this._deselectedToEmit=[],this._selectedToEmit=[])}_markSelected(o){o=this._getConcreteValue(o),this.isSelected(o)||(this._multiple||this._unmarkAll(),this.isSelected(o)||this._selection.add(o),this._emitChanges&&this._selectedToEmit.push(o))}_unmarkSelected(o){o=this._getConcreteValue(o),this.isSelected(o)&&(this._selection.delete(o),this._emitChanges&&this._deselectedToEmit.push(o))}_unmarkAll(){this.isEmpty()||this._selection.forEach(o=>this._unmarkSelected(o))}_verifyValueAssignment(o){o.length>1&&this._multiple}_hasQueuedChanges(){return!!(this._deselectedToEmit.length||this._selectedToEmit.length)}_getConcreteValue(o,e){if(this.compareWith){e=e??this._selection;for(let t of e)if(this.compareWith(o,t))return t;return o}else return o}};var Aa=(()=>{class i{_listeners=[];notify(e,t){for(let n of this._listeners)n(e,t)}listen(e){return this._listeners.push(e),()=>{this._listeners=this._listeners.filter(t=>e!==t)}}ngOnDestroy(){this._listeners=[]}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Cv=[[["caption"]],[["colgroup"],["col"]],"*"],xv=["caption","colgroup, col","*"];function wv(i,o){i&1&&U(0,2)}function Dv(i,o){i&1&&(s(0,"thead",0),Yt(1,1),l(),s(2,"tbody",2),Yt(3,3)(4,4),l(),s(5,"tfoot",0),Yt(6,5),l())}function kv(i,o){i&1&&Yt(0,1)(1,3)(2,4)(3,5)}var fh=(()=>{class i extends Cc{stickyCssClass="mat-mdc-table-sticky";needsPositionStickyOnElement=!1;static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275cmp=T({type:i,selectors:[["mat-table"],["table","mat-table",""]],hostAttrs:[1,"mat-mdc-table","mdc-data-table__table"],hostVars:2,hostBindings:function(t,n){t&2&&p("mat-table-fixed-layout",n.fixedLayout)},exportAs:["matTable"],features:[J([{provide:Cc,useExisting:i},{provide:vi,useExisting:i},{provide:ka,useValue:null}]),Q],ngContentSelectors:xv,decls:5,vars:2,consts:[["role","rowgroup"],["headerRowOutlet",""],["role","rowgroup",1,"mdc-data-table__content"],["rowOutlet",""],["noDataRowOutlet",""],["footerRowOutlet",""]],template:function(t,n){t&1&&(ce(Cv),U(0),U(1,1),M(2,wv,1,0),M(3,Dv,7,0)(4,kv,4,0)),t&2&&(c(2),E(n._isServer?2:-1),c(),E(n._isNativeHtmlTable?3:4))},dependencies:[vc,_c,yc,bc],styles:[`.mat-mdc-table-sticky {
2227
2227
  position: sticky !important;
2228
2228
  }
2229
2229
 
@@ -2400,7 +2400,7 @@ mat-cell.mat-mdc-cell,
2400
2400
  mat-footer-cell.mat-mdc-footer-cell {
2401
2401
  align-self: stretch;
2402
2402
  }
2403
- `],encapsulation:2,changeDetection:1})}return i})(),gh=(()=>{class i extends as{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matCellDef",""]],features:[J([{provide:as,useExisting:i}]),Q]})}return i})();var _h=(()=>{class i extends ka{get name(){return this._name}set name(e){this._setNameInput(e)}_updateColumnCssClassName(){super._updateColumnCssClassName(),this._columnCssClassName.push(`mat-column-${this.cssClassFriendlyName}`)}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matColumnDef",""]],inputs:{name:[0,"matColumnDef","name"]},features:[J([{provide:ka,useExisting:i}]),Q]})}return i})();var vh=(()=>{class i extends uh{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["mat-cell"],["td","mat-cell",""]],hostAttrs:[1,"mat-mdc-cell","mdc-data-table__cell"],features:[Q]})}return i})();var bh=(()=>{class i extends rs{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matRowDef",""]],inputs:{columns:[0,"matRowDefColumns","columns"],when:[0,"matRowDefWhen","when"]},features:[J([{provide:rs,useExisting:i}]),Q]})}return i})();var yh=(()=>{class i extends fc{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275cmp=T({type:i,selectors:[["mat-row"],["tr","mat-row",""]],hostAttrs:["role","row",1,"mat-mdc-row","mdc-data-table__row"],exportAs:["matRow"],features:[J([{provide:fc,useExisting:i}]),Q],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(t,n){t&1&&Yt(0,0)},dependencies:[Da],encapsulation:2,changeDetection:1})}return i})();var Ch=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ph,ee]})}return i})();var Mv=["*",[["mat-chip-avatar"],["","matChipAvatar",""]],[["mat-chip-trailing-icon"],["","matChipRemove",""],["","matChipTrailingIcon",""]]],Ev=["*","mat-chip-avatar, [matChipAvatar]","mat-chip-trailing-icon,[matChipRemove],[matChipTrailingIcon]"];function Av(i,o){i&1&&(s(0,"span",3),U(1,1),l())}function Tv(i,o){i&1&&(s(0,"span",6),U(1,2),l())}var Iv=["*"];var Rv=new C("mat-chips-default-options",{providedIn:"root",factory:()=>({separatorKeyCodes:[13]})}),xh=new C("MatChipAvatar"),wh=new C("MatChipTrailingIcon"),Dh=new C("MatChipEdit"),kh=new C("MatChipRemove"),Sh=new C("MatChip"),Mh=(()=>{class i{_elementRef=d(N);_parentChip=d(Sh);_isPrimary=!0;_isLeading=!1;get disabled(){return this._disabled||this._parentChip?.disabled||!1}set disabled(e){this._disabled=e}_disabled=!1;tabIndex=-1;_allowFocusWhenDisabled=!1;_getDisabledAttribute(){return this.disabled&&!this._allowFocusWhenDisabled?"":null}constructor(){d(Fe).load(Mt),this._elementRef.nativeElement.nodeName==="BUTTON"&&this._elementRef.nativeElement.setAttribute("type","button")}focus(){this._elementRef.nativeElement.focus()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matChipContent",""]],hostAttrs:[1,"mat-mdc-chip-action","mdc-evolution-chip__action","mdc-evolution-chip__action--presentational"],hostVars:8,hostBindings:function(t,n){t&2&&(Z("disabled",n._getDisabledAttribute())("aria-disabled",n.disabled),p("mdc-evolution-chip__action--primary",n._isPrimary)("mdc-evolution-chip__action--secondary",!n._isPrimary)("mdc-evolution-chip__action--trailing",!n._isPrimary&&!n._isLeading))},inputs:{disabled:[2,"disabled","disabled",L],tabIndex:[2,"tabIndex","tabIndex",e=>e==null?-1:wt(e)],_allowFocusWhenDisabled:"_allowFocusWhenDisabled"}})}return i})(),Ov=(()=>{class i extends Mh{_getTabindex(){return this.disabled&&!this._allowFocusWhenDisabled?null:this.tabIndex.toString()}_handleClick(e){!this.disabled&&this._isPrimary&&(e.preventDefault(),this._parentChip._handlePrimaryActionInteraction())}_handleKeydown(e){(e.keyCode===13||e.keyCode===32)&&!this.disabled&&this._isPrimary&&!this._parentChip._isEditing&&(e.preventDefault(),this._parentChip._handlePrimaryActionInteraction())}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matChipAction",""]],hostVars:3,hostBindings:function(t,n){t&1&&A("click",function(r){return n._handleClick(r)})("keydown",function(r){return n._handleKeydown(r)}),t&2&&(Z("tabindex",n._getTabindex()),p("mdc-evolution-chip__action--presentational",!1))},features:[Q]})}return i})();var Ea=(()=>{class i{_changeDetectorRef=d(te);_elementRef=d(N);_tagName=d(hd);_ngZone=d(H);_focusMonitor=d(Rt);_globalRippleOptions=d(jn,{optional:!0});_document=d($);_onFocus=new I;_onBlur=new I;_isBasicChip=!1;role=null;_hasFocusInternal=!1;_pendingFocus=!1;_actionChanges;_animationsDisabled=pe();_allLeadingIcons;_allTrailingIcons;_allEditIcons;_allRemoveIcons;_hasFocus(){return this._hasFocusInternal}id=d(be).getId("mat-mdc-chip-");ariaLabel=null;ariaDescription=null;_chipListDisabled=!1;_hadFocusOnRemove=!1;_textElement;get value(){return this._value!==void 0?this._value:this._textElement.textContent.trim()}set value(e){this._value=e}_value;color;removable=!0;highlighted=!1;disableRipple=!1;get disabled(){return this._disabled||this._chipListDisabled}set disabled(e){this._disabled=e}_disabled=!1;removed=new K;destroyed=new K;basicChipAttrName="mat-basic-chip";leadingIcon;editIcon;trailingIcon;removeIcon;primaryAction;_rippleLoader=d(Jr);_injector=d(X);constructor(){let e=d(Fe);e.load(Mt),e.load(rn),this._monitorFocus(),this._rippleLoader?.configureRipple(this._elementRef.nativeElement,{className:"mat-mdc-chip-ripple",disabled:this._isRippleDisabled()})}ngOnInit(){this._isBasicChip=this._elementRef.nativeElement.hasAttribute(this.basicChipAttrName)||this._tagName.toLowerCase()===this.basicChipAttrName}ngAfterViewInit(){this._textElement=this._elementRef.nativeElement.querySelector(".mat-mdc-chip-action-label"),this._pendingFocus&&(this._pendingFocus=!1,this.focus())}ngAfterContentInit(){this._actionChanges=$e(this._allLeadingIcons.changes,this._allTrailingIcons.changes,this._allEditIcons.changes,this._allRemoveIcons.changes).subscribe(()=>this._changeDetectorRef.markForCheck())}ngDoCheck(){this._rippleLoader.setDisabled(this._elementRef.nativeElement,this._isRippleDisabled())}ngOnDestroy(){this.destroyed.emit({chip:this}),this.destroyed.complete(),this._focusMonitor.stopMonitoring(this._elementRef),this._rippleLoader?.destroyRipple(this._elementRef.nativeElement),this._actionChanges?.unsubscribe()}remove(){this.removable&&(this._hadFocusOnRemove=this._hasFocus(),this.removed.emit({chip:this}))}_isRippleDisabled(){return this.disabled||this.disableRipple||this._animationsDisabled||this._isBasicChip||!this._hasInteractiveActions()||!!this._globalRippleOptions?.disabled}_hasTrailingIcon(){return!!(this.trailingIcon||this.removeIcon)}_handleKeydown(e){(e.keyCode===8&&!e.repeat||e.keyCode===46)&&(e.preventDefault(),this.remove())}focus(){this.disabled||(this.primaryAction?this.primaryAction.focus():this._pendingFocus=!0)}_getSourceAction(e){return this._getActions().find(t=>{let n=t._elementRef.nativeElement;return n===e||n.contains(e)})}_getActions(){let e=[];return this.editIcon&&e.push(this.editIcon),this.primaryAction&&e.push(this.primaryAction),this.removeIcon&&e.push(this.removeIcon),e}_handlePrimaryActionInteraction(){}_hasInteractiveActions(){return this._getActions().length>0}_edit(e){}_monitorFocus(){this._focusMonitor.monitor(this._elementRef,!0).subscribe(e=>{let t=e!==null;t!==this._hasFocusInternal&&(this._hasFocusInternal=t,t?this._onFocus.next({chip:this}):(this._changeDetectorRef.markForCheck(),setTimeout(()=>this._ngZone.run(()=>this._onBlur.next({chip:this})))))})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-basic-chip"],["","mat-basic-chip",""],["mat-chip"],["","mat-chip",""]],contentQueries:function(t,n,a){if(t&1&&at(a,xh,5)(a,Dh,5)(a,wh,5)(a,kh,5)(a,xh,5)(a,wh,5)(a,Dh,5)(a,kh,5),t&2){let r;O(r=P())&&(n.leadingIcon=r.first),O(r=P())&&(n.editIcon=r.first),O(r=P())&&(n.trailingIcon=r.first),O(r=P())&&(n.removeIcon=r.first),O(r=P())&&(n._allLeadingIcons=r),O(r=P())&&(n._allTrailingIcons=r),O(r=P())&&(n._allEditIcons=r),O(r=P())&&(n._allRemoveIcons=r)}},viewQuery:function(t,n){if(t&1&&Me(Ov,5),t&2){let a;O(a=P())&&(n.primaryAction=a.first)}},hostAttrs:[1,"mat-mdc-chip"],hostVars:31,hostBindings:function(t,n){t&1&&A("keydown",function(r){return n._handleKeydown(r)}),t&2&&(dt("id",n.id),Z("role",n.role)("aria-label",n.ariaLabel),et("mat-"+(n.color||"primary")),p("mdc-evolution-chip",!n._isBasicChip)("mdc-evolution-chip--disabled",n.disabled)("mdc-evolution-chip--with-trailing-action",n._hasTrailingIcon())("mdc-evolution-chip--with-primary-graphic",n.leadingIcon)("mdc-evolution-chip--with-primary-icon",n.leadingIcon)("mdc-evolution-chip--with-avatar",n.leadingIcon)("mat-mdc-chip-with-avatar",n.leadingIcon)("mat-mdc-chip-highlighted",n.highlighted)("mat-mdc-chip-disabled",n.disabled)("mat-mdc-basic-chip",n._isBasicChip)("mat-mdc-standard-chip",!n._isBasicChip)("mat-mdc-chip-with-trailing-icon",n._hasTrailingIcon())("_mat-animation-noopable",n._animationsDisabled))},inputs:{role:"role",id:"id",ariaLabel:[0,"aria-label","ariaLabel"],ariaDescription:[0,"aria-description","ariaDescription"],value:"value",color:"color",removable:[2,"removable","removable",L],highlighted:[2,"highlighted","highlighted",L],disableRipple:[2,"disableRipple","disableRipple",L],disabled:[2,"disabled","disabled",L]},outputs:{removed:"removed",destroyed:"destroyed"},exportAs:["matChip"],features:[J([{provide:Sh,useExisting:i}])],ngContentSelectors:Ev,decls:8,vars:2,consts:[[1,"mat-mdc-chip-focus-overlay"],[1,"mdc-evolution-chip__cell","mdc-evolution-chip__cell--primary"],["matChipContent",""],[1,"mdc-evolution-chip__graphic","mat-mdc-chip-graphic"],[1,"mdc-evolution-chip__text-label","mat-mdc-chip-action-label"],[1,"mat-mdc-chip-primary-focus-indicator","mat-focus-indicator"],[1,"mdc-evolution-chip__cell","mdc-evolution-chip__cell--trailing"]],template:function(t,n){t&1&&(ce(Mv),v(0,"span",0),s(1,"span",1)(2,"span",2),M(3,Av,2,0,"span",3),s(4,"span",4),U(5),v(6,"span",5),l()()(),M(7,Tv,2,0,"span",6)),t&2&&(c(3),E(n.leadingIcon?3:-1),c(4),E(n._hasTrailingIcon()?7:-1))},dependencies:[Mh],styles:[`.mdc-evolution-chip,
2403
+ `],encapsulation:2,changeDetection:1})}return i})(),gh=(()=>{class i extends ls{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matCellDef",""]],features:[J([{provide:ls,useExisting:i}]),Q]})}return i})();var _h=(()=>{class i extends Ma{get name(){return this._name}set name(e){this._setNameInput(e)}_updateColumnCssClassName(){super._updateColumnCssClassName(),this._columnCssClassName.push(`mat-column-${this.cssClassFriendlyName}`)}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matColumnDef",""]],inputs:{name:[0,"matColumnDef","name"]},features:[J([{provide:Ma,useExisting:i}]),Q]})}return i})();var vh=(()=>{class i extends uh{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["mat-cell"],["td","mat-cell",""]],hostAttrs:[1,"mat-mdc-cell","mdc-data-table__cell"],features:[Q]})}return i})();var bh=(()=>{class i extends cs{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matRowDef",""]],inputs:{columns:[0,"matRowDefColumns","columns"],when:[0,"matRowDefWhen","when"]},features:[J([{provide:cs,useExisting:i}]),Q]})}return i})();var yh=(()=>{class i extends gc{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275cmp=T({type:i,selectors:[["mat-row"],["tr","mat-row",""]],hostAttrs:["role","row",1,"mat-mdc-row","mdc-data-table__row"],exportAs:["matRow"],features:[J([{provide:gc,useExisting:i}]),Q],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(t,n){t&1&&Yt(0,0)},dependencies:[Sa],encapsulation:2,changeDetection:1})}return i})();var Ch=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ph,ee]})}return i})();var Mv=["*",[["mat-chip-avatar"],["","matChipAvatar",""]],[["mat-chip-trailing-icon"],["","matChipRemove",""],["","matChipTrailingIcon",""]]],Ev=["*","mat-chip-avatar, [matChipAvatar]","mat-chip-trailing-icon,[matChipRemove],[matChipTrailingIcon]"];function Av(i,o){i&1&&(s(0,"span",3),U(1,1),l())}function Tv(i,o){i&1&&(s(0,"span",6),U(1,2),l())}var Iv=["*"];var Rv=new x("mat-chips-default-options",{providedIn:"root",factory:()=>({separatorKeyCodes:[13]})}),xh=new x("MatChipAvatar"),wh=new x("MatChipTrailingIcon"),Dh=new x("MatChipEdit"),kh=new x("MatChipRemove"),Sh=new x("MatChip"),Mh=(()=>{class i{_elementRef=d(N);_parentChip=d(Sh);_isPrimary=!0;_isLeading=!1;get disabled(){return this._disabled||this._parentChip?.disabled||!1}set disabled(e){this._disabled=e}_disabled=!1;tabIndex=-1;_allowFocusWhenDisabled=!1;_getDisabledAttribute(){return this.disabled&&!this._allowFocusWhenDisabled?"":null}constructor(){d(Ne).load(Mt),this._elementRef.nativeElement.nodeName==="BUTTON"&&this._elementRef.nativeElement.setAttribute("type","button")}focus(){this._elementRef.nativeElement.focus()}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matChipContent",""]],hostAttrs:[1,"mat-mdc-chip-action","mdc-evolution-chip__action","mdc-evolution-chip__action--presentational"],hostVars:8,hostBindings:function(t,n){t&2&&(Z("disabled",n._getDisabledAttribute())("aria-disabled",n.disabled),p("mdc-evolution-chip__action--primary",n._isPrimary)("mdc-evolution-chip__action--secondary",!n._isPrimary)("mdc-evolution-chip__action--trailing",!n._isPrimary&&!n._isLeading))},inputs:{disabled:[2,"disabled","disabled",L],tabIndex:[2,"tabIndex","tabIndex",e=>e==null?-1:wt(e)],_allowFocusWhenDisabled:"_allowFocusWhenDisabled"}})}return i})(),Ov=(()=>{class i extends Mh{_getTabindex(){return this.disabled&&!this._allowFocusWhenDisabled?null:this.tabIndex.toString()}_handleClick(e){!this.disabled&&this._isPrimary&&(e.preventDefault(),this._parentChip._handlePrimaryActionInteraction())}_handleKeydown(e){(e.keyCode===13||e.keyCode===32)&&!this.disabled&&this._isPrimary&&!this._parentChip._isEditing&&(e.preventDefault(),this._parentChip._handlePrimaryActionInteraction())}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matChipAction",""]],hostVars:3,hostBindings:function(t,n){t&1&&A("click",function(r){return n._handleClick(r)})("keydown",function(r){return n._handleKeydown(r)}),t&2&&(Z("tabindex",n._getTabindex()),p("mdc-evolution-chip__action--presentational",!1))},features:[Q]})}return i})();var Ta=(()=>{class i{_changeDetectorRef=d(te);_elementRef=d(N);_tagName=d(hd);_ngZone=d(H);_focusMonitor=d(Rt);_globalRippleOptions=d(Un,{optional:!0});_document=d(W);_onFocus=new I;_onBlur=new I;_isBasicChip=!1;role=null;_hasFocusInternal=!1;_pendingFocus=!1;_actionChanges;_animationsDisabled=pe();_allLeadingIcons;_allTrailingIcons;_allEditIcons;_allRemoveIcons;_hasFocus(){return this._hasFocusInternal}id=d(be).getId("mat-mdc-chip-");ariaLabel=null;ariaDescription=null;_chipListDisabled=!1;_hadFocusOnRemove=!1;_textElement;get value(){return this._value!==void 0?this._value:this._textElement.textContent.trim()}set value(e){this._value=e}_value;color;removable=!0;highlighted=!1;disableRipple=!1;get disabled(){return this._disabled||this._chipListDisabled}set disabled(e){this._disabled=e}_disabled=!1;removed=new K;destroyed=new K;basicChipAttrName="mat-basic-chip";leadingIcon;editIcon;trailingIcon;removeIcon;primaryAction;_rippleLoader=d(is);_injector=d(X);constructor(){let e=d(Ne);e.load(Mt),e.load(rn),this._monitorFocus(),this._rippleLoader?.configureRipple(this._elementRef.nativeElement,{className:"mat-mdc-chip-ripple",disabled:this._isRippleDisabled()})}ngOnInit(){this._isBasicChip=this._elementRef.nativeElement.hasAttribute(this.basicChipAttrName)||this._tagName.toLowerCase()===this.basicChipAttrName}ngAfterViewInit(){this._textElement=this._elementRef.nativeElement.querySelector(".mat-mdc-chip-action-label"),this._pendingFocus&&(this._pendingFocus=!1,this.focus())}ngAfterContentInit(){this._actionChanges=$e(this._allLeadingIcons.changes,this._allTrailingIcons.changes,this._allEditIcons.changes,this._allRemoveIcons.changes).subscribe(()=>this._changeDetectorRef.markForCheck())}ngDoCheck(){this._rippleLoader.setDisabled(this._elementRef.nativeElement,this._isRippleDisabled())}ngOnDestroy(){this.destroyed.emit({chip:this}),this.destroyed.complete(),this._focusMonitor.stopMonitoring(this._elementRef),this._rippleLoader?.destroyRipple(this._elementRef.nativeElement),this._actionChanges?.unsubscribe()}remove(){this.removable&&(this._hadFocusOnRemove=this._hasFocus(),this.removed.emit({chip:this}))}_isRippleDisabled(){return this.disabled||this.disableRipple||this._animationsDisabled||this._isBasicChip||!this._hasInteractiveActions()||!!this._globalRippleOptions?.disabled}_hasTrailingIcon(){return!!(this.trailingIcon||this.removeIcon)}_handleKeydown(e){(e.keyCode===8&&!e.repeat||e.keyCode===46)&&(e.preventDefault(),this.remove())}focus(){this.disabled||(this.primaryAction?this.primaryAction.focus():this._pendingFocus=!0)}_getSourceAction(e){return this._getActions().find(t=>{let n=t._elementRef.nativeElement;return n===e||n.contains(e)})}_getActions(){let e=[];return this.editIcon&&e.push(this.editIcon),this.primaryAction&&e.push(this.primaryAction),this.removeIcon&&e.push(this.removeIcon),e}_handlePrimaryActionInteraction(){}_hasInteractiveActions(){return this._getActions().length>0}_edit(e){}_monitorFocus(){this._focusMonitor.monitor(this._elementRef,!0).subscribe(e=>{let t=e!==null;t!==this._hasFocusInternal&&(this._hasFocusInternal=t,t?this._onFocus.next({chip:this}):(this._changeDetectorRef.markForCheck(),setTimeout(()=>this._ngZone.run(()=>this._onBlur.next({chip:this})))))})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-basic-chip"],["","mat-basic-chip",""],["mat-chip"],["","mat-chip",""]],contentQueries:function(t,n,a){if(t&1&&at(a,xh,5)(a,Dh,5)(a,wh,5)(a,kh,5)(a,xh,5)(a,wh,5)(a,Dh,5)(a,kh,5),t&2){let r;O(r=P())&&(n.leadingIcon=r.first),O(r=P())&&(n.editIcon=r.first),O(r=P())&&(n.trailingIcon=r.first),O(r=P())&&(n.removeIcon=r.first),O(r=P())&&(n._allLeadingIcons=r),O(r=P())&&(n._allTrailingIcons=r),O(r=P())&&(n._allEditIcons=r),O(r=P())&&(n._allRemoveIcons=r)}},viewQuery:function(t,n){if(t&1&&Me(Ov,5),t&2){let a;O(a=P())&&(n.primaryAction=a.first)}},hostAttrs:[1,"mat-mdc-chip"],hostVars:31,hostBindings:function(t,n){t&1&&A("keydown",function(r){return n._handleKeydown(r)}),t&2&&(dt("id",n.id),Z("role",n.role)("aria-label",n.ariaLabel),et("mat-"+(n.color||"primary")),p("mdc-evolution-chip",!n._isBasicChip)("mdc-evolution-chip--disabled",n.disabled)("mdc-evolution-chip--with-trailing-action",n._hasTrailingIcon())("mdc-evolution-chip--with-primary-graphic",n.leadingIcon)("mdc-evolution-chip--with-primary-icon",n.leadingIcon)("mdc-evolution-chip--with-avatar",n.leadingIcon)("mat-mdc-chip-with-avatar",n.leadingIcon)("mat-mdc-chip-highlighted",n.highlighted)("mat-mdc-chip-disabled",n.disabled)("mat-mdc-basic-chip",n._isBasicChip)("mat-mdc-standard-chip",!n._isBasicChip)("mat-mdc-chip-with-trailing-icon",n._hasTrailingIcon())("_mat-animation-noopable",n._animationsDisabled))},inputs:{role:"role",id:"id",ariaLabel:[0,"aria-label","ariaLabel"],ariaDescription:[0,"aria-description","ariaDescription"],value:"value",color:"color",removable:[2,"removable","removable",L],highlighted:[2,"highlighted","highlighted",L],disableRipple:[2,"disableRipple","disableRipple",L],disabled:[2,"disabled","disabled",L]},outputs:{removed:"removed",destroyed:"destroyed"},exportAs:["matChip"],features:[J([{provide:Sh,useExisting:i}])],ngContentSelectors:Ev,decls:8,vars:2,consts:[[1,"mat-mdc-chip-focus-overlay"],[1,"mdc-evolution-chip__cell","mdc-evolution-chip__cell--primary"],["matChipContent",""],[1,"mdc-evolution-chip__graphic","mat-mdc-chip-graphic"],[1,"mdc-evolution-chip__text-label","mat-mdc-chip-action-label"],[1,"mat-mdc-chip-primary-focus-indicator","mat-focus-indicator"],[1,"mdc-evolution-chip__cell","mdc-evolution-chip__cell--trailing"]],template:function(t,n){t&1&&(ce(Mv),v(0,"span",0),s(1,"span",1)(2,"span",2),M(3,Av,2,0,"span",3),s(4,"span",4),U(5),v(6,"span",5),l()()(),M(7,Tv,2,0,"span",6)),t&2&&(c(3),E(n.leadingIcon?3:-1),c(4),E(n._hasTrailingIcon()?7:-1))},dependencies:[Mh],styles:[`.mdc-evolution-chip,
2404
2404
  .mdc-evolution-chip__cell,
2405
2405
  .mdc-evolution-chip__action {
2406
2406
  display: inline-flex;
@@ -2948,7 +2948,7 @@ mat-footer-cell.mat-mdc-footer-cell {
2948
2948
  img.mdc-evolution-chip__icon {
2949
2949
  min-height: 0;
2950
2950
  }
2951
- `],encapsulation:2})}return i})();var Eh=(()=>{class i{_elementRef=d(N);_changeDetectorRef=d(te);_dir=d(qe,{optional:!0});_lastDestroyedFocusedChipIndex=null;_keyManager;_destroyed=new I;_defaultRole="presentation";get chipFocusChanges(){return this._getChipStream(e=>e._onFocus)}get chipDestroyedChanges(){return this._getChipStream(e=>e.destroyed)}get chipRemovedChanges(){return this._getChipStream(e=>e.removed)}get disabled(){return this._disabled}set disabled(e){this._disabled=e,this._syncChipsState()}_disabled=!1;get empty(){return!this._chips||this._chips.length===0}get role(){return this._explicitRole?this._explicitRole:this.empty?null:this._defaultRole}tabIndex=0;set role(e){this._explicitRole=e}_explicitRole=null;get focused(){return this._hasFocusedChip()}_chips;_chipActions=new Zi;ngAfterViewInit(){this._setUpFocusManagement(),this._trackChipSetChanges(),this._trackDestroyedFocusedChip()}ngOnDestroy(){this._keyManager?.destroy(),this._chipActions.destroy(),this._destroyed.next(),this._destroyed.complete()}_hasFocusedChip(){return this._chips&&this._chips.some(e=>e._hasFocus())}_syncChipsState(){this._chips?.forEach(e=>{e._chipListDisabled=this._disabled,e._changeDetectorRef.markForCheck()})}focus(){}_handleKeydown(e){this._originatesFromChip(e)&&this._keyManager.onKeydown(e)}_isValidIndex(e){return e>=0&&e<this._chips.length}_allowFocusEscape(){let e=this._elementRef.nativeElement.tabIndex;e!==-1&&(this._elementRef.nativeElement.tabIndex=-1,setTimeout(()=>this._elementRef.nativeElement.tabIndex=e))}_getChipStream(e){return this._chips.changes.pipe(ke(null),We(()=>$e(...this._chips.map(e))))}_originatesFromChip(e){let t=e.target;for(;t&&t!==this._elementRef.nativeElement;){if(t.classList.contains("mat-mdc-chip"))return!0;t=t.parentElement}return!1}_setUpFocusManagement(){this._chips.changes.pipe(ke(this._chips)).subscribe(e=>{let t=[];e.forEach(n=>n._getActions().forEach(a=>t.push(a))),this._chipActions.reset(t),this._chipActions.notifyOnChanges()}),this._keyManager=new cn(this._chipActions).withVerticalOrientation().withHorizontalOrientation(this._dir?this._dir.value:"ltr").withHomeAndEnd().skipPredicate(e=>this._skipPredicate(e)),this.chipFocusChanges.pipe(oe(this._destroyed)).subscribe(({chip:e})=>{let t=e._getSourceAction(document.activeElement);t&&this._keyManager.updateActiveItem(t)}),this._dir?.change.pipe(oe(this._destroyed)).subscribe(e=>this._keyManager.withHorizontalOrientation(e))}_skipPredicate(e){return e.disabled}_trackChipSetChanges(){this._chips.changes.pipe(ke(null),oe(this._destroyed)).subscribe(()=>{this.disabled&&Promise.resolve().then(()=>this._syncChipsState()),this._redirectDestroyedChipFocus()})}_trackDestroyedFocusedChip(){this.chipDestroyedChanges.pipe(oe(this._destroyed)).subscribe(e=>{let n=this._chips.toArray().indexOf(e.chip),a=e.chip._hasFocus(),r=e.chip._hadFocusOnRemove&&this._keyManager.activeItem&&e.chip._getActions().includes(this._keyManager.activeItem),u=a||r;this._isValidIndex(n)&&u&&(this._lastDestroyedFocusedChipIndex=n)})}_redirectDestroyedChipFocus(){if(this._lastDestroyedFocusedChipIndex!=null){if(this._chips.length){let e=Math.min(this._lastDestroyedFocusedChipIndex,this._chips.length-1),t=this._chips.toArray()[e];t.disabled?this._chips.length===1?this.focus():this._keyManager.setPreviousItemActive():t.focus()}else this.focus();this._lastDestroyedFocusedChipIndex=null}}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-chip-set"]],contentQueries:function(t,n,a){if(t&1&&at(a,Ea,5),t&2){let r;O(r=P())&&(n._chips=r)}},hostAttrs:[1,"mat-mdc-chip-set","mdc-evolution-chip-set"],hostVars:1,hostBindings:function(t,n){t&1&&A("keydown",function(r){return n._handleKeydown(r)}),t&2&&Z("role",n.role)},inputs:{disabled:[2,"disabled","disabled",L],role:"role",tabIndex:[2,"tabIndex","tabIndex",e=>e==null?0:wt(e)]},ngContentSelectors:Iv,decls:2,vars:0,consts:[["role","presentation",1,"mdc-evolution-chip-set__chips"]],template:function(t,n){t&1&&(ce(),Ie(0,"div",0),U(1),je())},styles:[`.mat-mdc-chip-set {
2951
+ `],encapsulation:2})}return i})();var Eh=(()=>{class i{_elementRef=d(N);_changeDetectorRef=d(te);_dir=d(qe,{optional:!0});_lastDestroyedFocusedChipIndex=null;_keyManager;_destroyed=new I;_defaultRole="presentation";get chipFocusChanges(){return this._getChipStream(e=>e._onFocus)}get chipDestroyedChanges(){return this._getChipStream(e=>e.destroyed)}get chipRemovedChanges(){return this._getChipStream(e=>e.removed)}get disabled(){return this._disabled}set disabled(e){this._disabled=e,this._syncChipsState()}_disabled=!1;get empty(){return!this._chips||this._chips.length===0}get role(){return this._explicitRole?this._explicitRole:this.empty?null:this._defaultRole}tabIndex=0;set role(e){this._explicitRole=e}_explicitRole=null;get focused(){return this._hasFocusedChip()}_chips;_chipActions=new Zi;ngAfterViewInit(){this._setUpFocusManagement(),this._trackChipSetChanges(),this._trackDestroyedFocusedChip()}ngOnDestroy(){this._keyManager?.destroy(),this._chipActions.destroy(),this._destroyed.next(),this._destroyed.complete()}_hasFocusedChip(){return this._chips&&this._chips.some(e=>e._hasFocus())}_syncChipsState(){this._chips?.forEach(e=>{e._chipListDisabled=this._disabled,e._changeDetectorRef.markForCheck()})}focus(){}_handleKeydown(e){this._originatesFromChip(e)&&this._keyManager.onKeydown(e)}_isValidIndex(e){return e>=0&&e<this._chips.length}_allowFocusEscape(){let e=this._elementRef.nativeElement.tabIndex;e!==-1&&(this._elementRef.nativeElement.tabIndex=-1,setTimeout(()=>this._elementRef.nativeElement.tabIndex=e))}_getChipStream(e){return this._chips.changes.pipe(ke(null),We(()=>$e(...this._chips.map(e))))}_originatesFromChip(e){let t=e.target;for(;t&&t!==this._elementRef.nativeElement;){if(t.classList.contains("mat-mdc-chip"))return!0;t=t.parentElement}return!1}_setUpFocusManagement(){this._chips.changes.pipe(ke(this._chips)).subscribe(e=>{let t=[];e.forEach(n=>n._getActions().forEach(a=>t.push(a))),this._chipActions.reset(t),this._chipActions.notifyOnChanges()}),this._keyManager=new cn(this._chipActions).withVerticalOrientation().withHorizontalOrientation(this._dir?this._dir.value:"ltr").withHomeAndEnd().skipPredicate(e=>this._skipPredicate(e)),this.chipFocusChanges.pipe(oe(this._destroyed)).subscribe(({chip:e})=>{let t=e._getSourceAction(document.activeElement);t&&this._keyManager.updateActiveItem(t)}),this._dir?.change.pipe(oe(this._destroyed)).subscribe(e=>this._keyManager.withHorizontalOrientation(e))}_skipPredicate(e){return e.disabled}_trackChipSetChanges(){this._chips.changes.pipe(ke(null),oe(this._destroyed)).subscribe(()=>{this.disabled&&Promise.resolve().then(()=>this._syncChipsState()),this._redirectDestroyedChipFocus()})}_trackDestroyedFocusedChip(){this.chipDestroyedChanges.pipe(oe(this._destroyed)).subscribe(e=>{let n=this._chips.toArray().indexOf(e.chip),a=e.chip._hasFocus(),r=e.chip._hadFocusOnRemove&&this._keyManager.activeItem&&e.chip._getActions().includes(this._keyManager.activeItem),u=a||r;this._isValidIndex(n)&&u&&(this._lastDestroyedFocusedChipIndex=n)})}_redirectDestroyedChipFocus(){if(this._lastDestroyedFocusedChipIndex!=null){if(this._chips.length){let e=Math.min(this._lastDestroyedFocusedChipIndex,this._chips.length-1),t=this._chips.toArray()[e];t.disabled?this._chips.length===1?this.focus():this._keyManager.setPreviousItemActive():t.focus()}else this.focus();this._lastDestroyedFocusedChipIndex=null}}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-chip-set"]],contentQueries:function(t,n,a){if(t&1&&at(a,Ta,5),t&2){let r;O(r=P())&&(n._chips=r)}},hostAttrs:[1,"mat-mdc-chip-set","mdc-evolution-chip-set"],hostVars:1,hostBindings:function(t,n){t&1&&A("keydown",function(r){return n._handleKeydown(r)}),t&2&&Z("role",n.role)},inputs:{disabled:[2,"disabled","disabled",L],role:"role",tabIndex:[2,"tabIndex","tabIndex",e=>e==null?0:wt(e)]},ngContentSelectors:Iv,decls:2,vars:0,consts:[["role","presentation",1,"mdc-evolution-chip-set__chips"]],template:function(t,n){t&1&&(ce(),Ie(0,"div",0),U(1),je())},styles:[`.mat-mdc-chip-set {
2952
2952
  display: flex;
2953
2953
  }
2954
2954
  .mat-mdc-chip-set:focus {
@@ -3016,7 +3016,7 @@ input.mat-mdc-chip-input {
3016
3016
  margin-left: 0;
3017
3017
  margin-right: 0;
3018
3018
  }
3019
- `],encapsulation:2})}return i})();var Do=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({providers:[yo,{provide:Rv,useValue:{separatorKeyCodes:[13]}}],imports:[Ti,ee]})}return i})();function Pv(i,o){if(i&1&&(s(0,"td",14),m(1),l()),i&2){let e=o.$implicit;c(),q(e.gpuIndex)}}function Fv(i,o){if(i&1&&(s(0,"td",15)(1,"mat-chip",16),m(2),l()()),i&2){let e=o.$implicit,t=D();c(),x("ngClass",t.getVendorCssClass(e)),c(),he(" ",t.makeGpuNameShort(e.name)+" / "+e.brand," ")}}function Nv(i,o){if(i&1&&(s(0,"td",17)(1,"div",18)(2,"span",19),m(3),jo(4,"number"),jo(5,"number"),l(),s(6,"div",20),v(7,"div",21),l()()()),i&2){let e=o.$implicit,t=D();c(3),Mn(" ",Ho(4,6,e.vramUsed,"1.0-0")," / ",Ho(5,9,e.vramTotal,"1.0-0")," GB "),c(4),He("width",t.vramPercent(e),"%")("background",t.colorForUsage(t.vramPercent(e)))}}function Lv(i,o){if(i&1&&(s(0,"td",22)(1,"div",23)(2,"span",24),m(3),l(),s(4,"div",25),v(5,"div",26),l()()()),i&2){let e=o.$implicit,t=D();c(2),He("color",t.colorForUsage(e.usage)),c(),he(" ",e.usage,"% "),c(2),He("width",e.usage,"%")("background",t.colorForUsage(e.usage))}}function Vv(i,o){if(i&1&&(s(0,"td",27)(1,"span",28),m(2),l()()),i&2){let e=o.$implicit,t=D();c(),He("color",t.colorForTemp(e.temperature)),c(),he(" ",e.temperature,"\xB0C ")}}function Bv(i,o){if(i&1&&(s(0,"td",29),m(1),l()),i&2){let e=o.$implicit;c(),q(e.pciBusId)}}function zv(i,o){i&1&&v(0,"tr",30)}var Th=(()=>{class i{constructor(){this.gpus=no.required(),this.displayedColumns=["index","name","vram","usage","temperature","pciBusId"]}getVendorCssClass(e){return{"gpu-name":!0,"gpu-vendor-nvidia":e.vendor==="NVIDIA","gpu-vendor-amd":e.vendor==="AMD","gpu-vendor-other":!["NVIDIA","AMD"].includes(e.vendor)}}vramPercent(e){return e.vramTotal===0?0:Math.round(e.vramUsed/e.vramTotal*100)}colorForUsage(e){return e<40?"#4caf50":e<75?"#ff9800":"#f44336"}colorForTemp(e){return e<60?"#4caf50":e<80?"#ff9800":"#f44336"}makeGpuNameShort(e){return e=e.replace(/^AMD Radeon RX /,"RX "),e}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-gpu-table"]],inputs:{gpus:[1,"gpus"]},decls:16,vars:2,consts:[["mat-table","",1,"gpu-table",3,"dataSource"],["matColumnDef","index"],["mat-cell","","class","index-cell","title","#",4,"matCellDef"],["matColumnDef","name"],["mat-cell","","title","Name",4,"matCellDef"],["matColumnDef","vram"],["mat-cell","","title","VRAM",4,"matCellDef"],["matColumnDef","usage"],["mat-cell","","title","GPU Usage",4,"matCellDef"],["matColumnDef","temperature"],["mat-cell","","title","Temp \xB0C",4,"matCellDef"],["matColumnDef","pciBusId"],["mat-cell","","class","pci-cell","title","PCI Bus",4,"matCellDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["mat-cell","","title","#",1,"index-cell"],["mat-cell","","title","Name"],[1,"gpu-name",3,"ngClass"],["mat-cell","","title","VRAM"],[1,"vram-cell"],[1,"vram-text"],[1,"vram-bar-bg"],[1,"vram-bar-fill"],["mat-cell","","title","GPU Usage"],[1,"usage-cell"],[1,"usage-value"],[1,"usage-bar-bg"],[1,"usage-bar-fill"],["mat-cell","","title","Temp \xB0C"],[1,"temp-value"],["mat-cell","","title","PCI Bus",1,"pci-cell"],["mat-row",""]],template:function(t,n){t&1&&(s(0,"mat-card")(1,"mat-card-content")(2,"table",0),ui(3,1),ze(4,Pv,2,1,"td",2),hi(),ui(5,3),ze(6,Fv,3,2,"td",4),hi(),ui(7,5),ze(8,Nv,8,12,"td",6),hi(),ui(9,7),ze(10,Lv,6,7,"td",8),hi(),ui(11,9),ze(12,Vv,3,3,"td",10),hi(),ui(13,11),ze(14,Bv,2,1,"td",12),hi(),ze(15,zv,1,0,"tr",13),l()()()),t&2&&(c(2),x("dataSource",n.gpus()),c(13),x("matRowDefColumns",n.displayedColumns))},dependencies:[Ve,al,Ch,fh,_h,gh,bh,vh,yh,on,tn,nn,Do,Ea,ll],styles:[".gpu-table[_ngcontent-%COMP%]{width:100%;white-space:nowrap}.gpu-name[_ngcontent-%COMP%]{font-weight:500}.gpu-vendor-nvidia[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #a4f021}.gpu-vendor-amd[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #ffa1a1}.gpu-vendor-other[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #b6e7ff}.index-cell[_ngcontent-%COMP%]{padding-left:0;padding-right:0}.pci-cell[_ngcontent-%COMP%]{font-family:Roboto Mono,monospace;font-size:.85rem;color:#666}.vram-cell[_ngcontent-%COMP%]{min-width:160px}.vram-text[_ngcontent-%COMP%]{display:block;margin-bottom:4px;font-size:.85rem}.vram-bar-bg[_ngcontent-%COMP%]{height:8px;background:#e0e0e0;border-radius:4px;overflow:hidden}.vram-bar-fill[_ngcontent-%COMP%]{height:100%;border-radius:4px;transition:width .4s ease,background .4s ease}.usage-cell[_ngcontent-%COMP%]{min-width:130px}.usage-value[_ngcontent-%COMP%]{display:block;margin-bottom:4px;font-weight:500;font-size:.9rem}.usage-bar-bg[_ngcontent-%COMP%]{height:8px;background:#e0e0e0;border-radius:4px;overflow:hidden}.usage-bar-fill[_ngcontent-%COMP%]{height:100%;border-radius:4px;transition:width .4s ease,background .4s ease}.temp-value[_ngcontent-%COMP%]{font-weight:500;font-size:.95rem}.mat-row[_ngcontent-%COMP%]{transition:background .2s ease;height:44px}.mat-row[_ngcontent-%COMP%]:hover{background:#fafafa}mat-card-content[_ngcontent-%COMP%]{overflow-x:hidden}"]})}}return i})();var Aa=class{_attachedHost=null;attach(o){return this._attachedHost=o,o.attach(this)}detach(){let o=this._attachedHost;o!=null&&(this._attachedHost=null,o.detach())}get isAttached(){return this._attachedHost!=null}setAttachedHost(o){this._attachedHost=o}},bi=class extends Aa{component;viewContainerRef;injector;projectableNodes;bindings;directives;constructor(o,e,t,n,a,r){super(),this.component=o,this.viewContainerRef=e,this.injector=t,this.projectableNodes=n,this.bindings=a||null,this.directives=r||null}},Et=class extends Aa{templateRef;viewContainerRef;context;injector;constructor(o,e,t,n){super(),this.templateRef=o,this.viewContainerRef=e,this.context=t,this.injector=n}get origin(){return this.templateRef.elementRef}attach(o,e=this.context){return this.context=e,super.attach(o)}detach(){return this.context=void 0,super.detach()}},Cc=class extends Aa{element;constructor(o){super(),this.element=o instanceof N?o.nativeElement:o}},_n=class{_attachedPortal=null;_disposeFn=null;_isDisposed=!1;hasAttached(){return!!this._attachedPortal}attach(o){if(o instanceof bi)return this._attachedPortal=o,this.attachComponentPortal(o);if(o instanceof Et)return this._attachedPortal=o,this.attachTemplatePortal(o);if(this.attachDomPortal&&o instanceof Cc)return this._attachedPortal=o,this.attachDomPortal(o)}attachDomPortal=null;detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(o){this._disposeFn=o}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}},Ta=class extends _n{outletElement;_appRef;_defaultInjector;constructor(o,e,t){super(),this.outletElement=o,this._appRef=e,this._defaultInjector=t}attachComponentPortal(o){let e;if(o.viewContainerRef){let t=o.injector||o.viewContainerRef.injector,n=t.get(Qa,null,{optional:!0})||void 0;e=o.viewContainerRef.createComponent(o.component,{index:o.viewContainerRef.length,injector:t,ngModuleRef:n,projectableNodes:o.projectableNodes||void 0,bindings:o.bindings||void 0,directives:o.directives||void 0}),this.setDisposeFn(()=>e.destroy())}else{let t=this._appRef,n=o.injector||this._defaultInjector||X.NULL,a=n.get(mi,t.injector);e=tr(o.component,{elementInjector:n,environmentInjector:a,projectableNodes:o.projectableNodes||void 0,bindings:o.bindings||void 0,directives:o.directives||void 0}),t.attachView(e.hostView),this.setDisposeFn(()=>{t.viewCount>0&&t.detachView(e.hostView),e.destroy()})}return this.outletElement.appendChild(this._getComponentRootNode(e)),this._attachedPortal=o,e}attachTemplatePortal(o){let e=o.viewContainerRef,t=e.createEmbeddedView(o.templateRef,o.context,{injector:o.injector});return t.rootNodes.forEach(n=>this.outletElement.appendChild(n)),t.detectChanges(),this.setDisposeFn(()=>{let n=e.indexOf(t);n!==-1&&e.remove(n)}),this._attachedPortal=o,t}attachDomPortal=o=>{let e=o.element;e.parentNode;let t=this.outletElement.ownerDocument.createComment("dom-portal");e.parentNode.insertBefore(t,e),this.outletElement.appendChild(e),this._attachedPortal=o,super.setDisposeFn(()=>{t.parentNode&&t.parentNode.replaceChild(e,t)})};dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(o){return o.hostView.rootNodes[0]}};var Ri=(()=>{class i extends _n{_moduleRef=d(Qa,{optional:!0});_document=d($);_viewContainerRef=d(Xe);_isInitialized=!1;_attachedRef=null;get portal(){return this._attachedPortal}set portal(e){this.hasAttached()&&!e&&!this._isInitialized||(this.hasAttached()&&super.detach(),e&&super.attach(e),this._attachedPortal=e||null)}attached=new K;get attachedRef(){return this._attachedRef}ngOnInit(){this._isInitialized=!0}ngOnDestroy(){super.dispose(),this._attachedRef=this._attachedPortal=null}attachComponentPortal(e){e.setAttachedHost(this);let t=e.viewContainerRef!=null?e.viewContainerRef:this._viewContainerRef,n=t.createComponent(e.component,{index:t.length,injector:e.injector||t.injector,projectableNodes:e.projectableNodes||void 0,ngModuleRef:this._moduleRef||void 0,bindings:e.bindings||void 0,directives:e.directives||void 0});return t!==this._viewContainerRef&&this._getRootNode().appendChild(n.hostView.rootNodes[0]),super.setDisposeFn(()=>n.destroy()),this._attachedPortal=e,this._attachedRef=n,this.attached.emit(n),n}attachTemplatePortal(e){e.setAttachedHost(this);let t=this._viewContainerRef.createEmbeddedView(e.templateRef,e.context,{injector:e.injector});return super.setDisposeFn(()=>this._viewContainerRef.clear()),this._attachedPortal=e,this._attachedRef=t,this.attached.emit(t),t}attachDomPortal=e=>{let t=e.element;t.parentNode;let n=this._document.createComment("dom-portal");e.setAttachedHost(this),t.parentNode.insertBefore(n,t),this._getRootNode().appendChild(t),this._attachedPortal=e,super.setDisposeFn(()=>{n.parentNode&&n.parentNode.replaceChild(t,n)})};_getRootNode(){let e=this._viewContainerRef.element.nativeElement;return e.nodeType===e.ELEMENT_NODE?e:e.parentNode}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:[0,"cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[Q]})}return i})(),Oi=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();var Ih=Tr();function Mo(i){return new ss(i.get(Gt),i.get($))}var ss=class{_viewportRuler;_previousHTMLStyles={top:"",left:""};_previousScrollPosition;_isEnabled=!1;_document;constructor(o,e){this._viewportRuler=o,this._document=e}attach(){}enable(){if(this._canBeEnabled()){let o=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=o.style.left||"",this._previousHTMLStyles.top=o.style.top||"",o.style.left=Ze(-this._previousScrollPosition.left),o.style.top=Ze(-this._previousScrollPosition.top),o.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}disable(){if(this._isEnabled){let o=this._document.documentElement,e=this._document.body,t=o.style,n=e.style,a=t.scrollBehavior||"",r=n.scrollBehavior||"";this._isEnabled=!1,t.left=this._previousHTMLStyles.left,t.top=this._previousHTMLStyles.top,o.classList.remove("cdk-global-scrollblock"),Ih&&(t.scrollBehavior=n.scrollBehavior="auto"),window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),Ih&&(t.scrollBehavior=a,n.scrollBehavior=r)}}_canBeEnabled(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;let e=this._document.documentElement,t=this._viewportRuler.getViewportSize();return e.scrollHeight>t.height||e.scrollWidth>t.width}};function Vh(i,o){return new ls(i.get(gn),i.get(H),i.get(Gt),o)}var ls=class{_scrollDispatcher;_ngZone;_viewportRuler;_config;_scrollSubscription=null;_overlayRef;_initialScrollPosition;constructor(o,e,t,n){this._scrollDispatcher=o,this._ngZone=e,this._viewportRuler=t,this._config=n}attach(o){this._overlayRef,this._overlayRef=o}enable(){if(this._scrollSubscription)return;let o=this._scrollDispatcher.scrolled(0).pipe(Ce(e=>!e||!this._overlayRef.overlayElement.contains(e.getElementRef().nativeElement)));this._config&&this._config.threshold&&this._config.threshold>1?(this._initialScrollPosition=this._viewportRuler.getViewportScrollPosition().top,this._scrollSubscription=o.subscribe(()=>{let e=this._viewportRuler.getViewportScrollPosition().top;Math.abs(e-this._initialScrollPosition)>this._config.threshold?this._detach():this._overlayRef.updatePosition()})):this._scrollSubscription=o.subscribe(this._detach)}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}_detach=()=>{this.disable(),this._overlayRef.hasAttached()&&this._ngZone.run(()=>this._overlayRef.detach())}};var Ia=class{enable(){}disable(){}attach(){}};function xc(i,o){return o.some(e=>{let t=i.bottom<e.top,n=i.top>e.bottom,a=i.right<e.left,r=i.left>e.right;return t||n||a||r})}function Rh(i,o){return o.some(e=>{let t=i.top<e.top,n=i.bottom>e.bottom,a=i.left<e.left,r=i.right>e.right;return t||n||a||r})}function yi(i,o){return new cs(i.get(gn),i.get(Gt),i.get(H),o)}var cs=class{_scrollDispatcher;_viewportRuler;_ngZone;_config;_scrollSubscription=null;_overlayRef;constructor(o,e,t,n){this._scrollDispatcher=o,this._viewportRuler=e,this._ngZone=t,this._config=n}attach(o){this._overlayRef,this._overlayRef=o}enable(){if(!this._scrollSubscription){let o=this._config?this._config.scrollThrottle:0;this._scrollSubscription=this._scrollDispatcher.scrolled(o).subscribe(()=>{if(this._overlayRef.updatePosition(),this._config&&this._config.autoClose){let e=this._overlayRef.overlayElement.getBoundingClientRect(),{width:t,height:n}=this._viewportRuler.getViewportSize();xc(e,[{width:t,height:n,bottom:n,right:t,top:0,left:0}])&&(this.disable(),this._ngZone.run(()=>this._overlayRef.detach()))}})}}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}},Bh=(()=>{class i{_injector=d(X);noop=()=>new Ia;close=e=>Vh(this._injector,e);block=()=>Mo(this._injector);reposition=e=>yi(this._injector,e);static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Wt=class{positionStrategy;scrollStrategy=new Ia;panelClass="";hasBackdrop=!1;backdropClass="cdk-overlay-dark-backdrop";disableAnimations;width;height;minWidth;minHeight;maxWidth;maxHeight;direction;disposeOnNavigation=!1;usePopover;eventPredicate;constructor(o){if(o){let e=Object.keys(o);for(let t of e)o[t]!==void 0&&(this[t]=o[t])}}};var ds=class{connectionPair;scrollableViewProperties;constructor(o,e){this.connectionPair=o,this.scrollableViewProperties=e}};var zh=(()=>{class i{_attachedOverlays=[];_document=d($);_isAttached=!1;ngOnDestroy(){this.detach()}add(e){this.remove(e),this._attachedOverlays.push(e)}remove(e){let t=this._attachedOverlays.indexOf(e);t>-1&&this._attachedOverlays.splice(t,1),this._attachedOverlays.length===0&&this.detach()}canReceiveEvent(e,t,n){return n.observers.length<1?!1:e.eventPredicate?e.eventPredicate(t):!0}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),jh=(()=>{class i extends zh{_ngZone=d(H);_renderer=d(ot).createRenderer(null,null);_cleanupKeydown;add(e){super.add(e),this._isAttached||(this._ngZone.runOutsideAngular(()=>{this._cleanupKeydown=this._renderer.listen("body","keydown",this._keydownListener)}),this._isAttached=!0)}detach(){this._isAttached&&(this._cleanupKeydown?.(),this._isAttached=!1)}_keydownListener=e=>{let t=this._attachedOverlays;for(let n=t.length-1;n>-1;n--){let a=t[n];if(this.canReceiveEvent(a,e,a._keydownEvents)){this._ngZone.run(()=>a._keydownEvents.next(e));break}}};static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Hh=(()=>{class i extends zh{_platform=d(le);_ngZone=d(H);_renderer=d(ot).createRenderer(null,null);_cursorOriginalValue;_cursorStyleIsSet=!1;_pointerDownEventTarget=null;_cleanups;add(e){if(super.add(e),!this._isAttached){let t=this._document.body,n={capture:!0},a=this._renderer;this._cleanups=this._ngZone.runOutsideAngular(()=>[a.listen(t,"pointerdown",this._pointerDownListener,n),a.listen(t,"click",this._clickListener,n),a.listen(t,"auxclick",this._clickListener,n),a.listen(t,"contextmenu",this._clickListener,n)]),this._platform.IOS&&!this._cursorStyleIsSet&&(this._cursorOriginalValue=t.style.cursor,t.style.cursor="pointer",this._cursorStyleIsSet=!0),this._isAttached=!0}}detach(){this._isAttached&&(this._cleanups?.forEach(e=>e()),this._cleanups=void 0,this._platform.IOS&&this._cursorStyleIsSet&&(this._document.body.style.cursor=this._cursorOriginalValue,this._cursorStyleIsSet=!1),this._isAttached=!1)}_pointerDownListener=e=>{this._pointerDownEventTarget=rt(e)};_clickListener=e=>{let t=rt(e),n=e.type==="click"&&this._pointerDownEventTarget?this._pointerDownEventTarget:t;this._pointerDownEventTarget=null;let a=this._attachedOverlays.slice();for(let r=a.length-1;r>-1;r--){let u=a[r],h=u._outsidePointerEvents;if(!(!u.hasAttached()||!this.canReceiveEvent(u,e,h))){if(Oh(u.overlayElement,t)||Oh(u.overlayElement,n))break;this._ngZone?this._ngZone.run(()=>h.next(e)):h.next(e)}}};static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function Oh(i,o){let e=typeof ShadowRoot<"u"&&ShadowRoot,t=o;for(;t;){if(t===i)return!0;t=e&&t instanceof ShadowRoot?t.host:t.parentNode}return!1}var Uh=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["ng-component"]],hostAttrs:["cdk-overlay-style-loader",""],decls:0,vars:0,template:function(t,n){},styles:[`.cdk-overlay-container, .cdk-global-overlay-wrapper {
3019
+ `],encapsulation:2})}return i})();var So=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({providers:[xo,{provide:Rv,useValue:{separatorKeyCodes:[13]}}],imports:[Ti,ee]})}return i})();function Pv(i,o){if(i&1&&(s(0,"td",14),m(1),l()),i&2){let e=o.$implicit;c(),q(e.gpuIndex)}}function Fv(i,o){if(i&1&&(s(0,"td",15)(1,"mat-chip",16),m(2),l()()),i&2){let e=o.$implicit,t=D();c(),C("ngClass",t.getVendorCssClass(e)),c(),he(" ",t.makeGpuNameShort(e.name)+" / "+e.brand," ")}}function Nv(i,o){if(i&1&&(s(0,"td",17)(1,"div",18)(2,"span",19),m(3),Uo(4,"number"),Uo(5,"number"),l(),s(6,"div",20),v(7,"div",21),l()()()),i&2){let e=o.$implicit,t=D();c(3),An(" ",Go(4,6,e.vramUsed,"1.0-0")," / ",Go(5,9,e.vramTotal,"1.0-0")," GB "),c(4),He("width",t.vramPercent(e),"%")("background",t.colorForUsage(t.vramPercent(e)))}}function Lv(i,o){if(i&1&&(s(0,"td",22)(1,"div",23)(2,"span",24),m(3),l(),s(4,"div",25),v(5,"div",26),l()()()),i&2){let e=o.$implicit,t=D();c(2),He("color",t.colorForUsage(e.usage)),c(),he(" ",e.usage,"% "),c(2),He("width",e.usage,"%")("background",t.colorForUsage(e.usage))}}function Vv(i,o){if(i&1&&(s(0,"td",27)(1,"span",28),m(2),l()()),i&2){let e=o.$implicit,t=D();c(),He("color",t.colorForTemp(e.temperature)),c(),he(" ",e.temperature,"\xB0C ")}}function Bv(i,o){if(i&1&&(s(0,"td",29),m(1),l()),i&2){let e=o.$implicit;c(),q(e.pciBusId)}}function zv(i,o){i&1&&v(0,"tr",30)}var Th=(()=>{class i{constructor(){this.gpus=ao.required(),this.displayedColumns=["index","name","vram","usage","temperature","pciBusId"]}getVendorCssClass(e){return{"gpu-name":!0,"gpu-vendor-nvidia":e.vendor==="NVIDIA","gpu-vendor-amd":e.vendor==="AMD","gpu-vendor-other":!["NVIDIA","AMD"].includes(e.vendor)}}vramPercent(e){return e.vramTotal===0?0:Math.round(e.vramUsed/e.vramTotal*100)}colorForUsage(e){return e<40?"#4caf50":e<75?"#ff9800":"#f44336"}colorForTemp(e){return e<60?"#4caf50":e<80?"#ff9800":"#f44336"}makeGpuNameShort(e){return e=e.replace(/^AMD Radeon RX /,"RX "),e}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-gpu-table"]],inputs:{gpus:[1,"gpus"]},decls:16,vars:2,consts:[["mat-table","",1,"gpu-table",3,"dataSource"],["matColumnDef","index"],["mat-cell","","class","index-cell","title","#",4,"matCellDef"],["matColumnDef","name"],["mat-cell","","title","Name",4,"matCellDef"],["matColumnDef","vram"],["mat-cell","","title","VRAM",4,"matCellDef"],["matColumnDef","usage"],["mat-cell","","title","GPU Usage",4,"matCellDef"],["matColumnDef","temperature"],["mat-cell","","title","Temp \xB0C",4,"matCellDef"],["matColumnDef","pciBusId"],["mat-cell","","class","pci-cell","title","PCI Bus",4,"matCellDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["mat-cell","","title","#",1,"index-cell"],["mat-cell","","title","Name"],[1,"gpu-name",3,"ngClass"],["mat-cell","","title","VRAM"],[1,"vram-cell"],[1,"vram-text"],[1,"vram-bar-bg"],[1,"vram-bar-fill"],["mat-cell","","title","GPU Usage"],[1,"usage-cell"],[1,"usage-value"],[1,"usage-bar-bg"],[1,"usage-bar-fill"],["mat-cell","","title","Temp \xB0C"],[1,"temp-value"],["mat-cell","","title","PCI Bus",1,"pci-cell"],["mat-row",""]],template:function(t,n){t&1&&(s(0,"mat-card")(1,"mat-card-content")(2,"table",0),ui(3,1),ze(4,Pv,2,1,"td",2),hi(),ui(5,3),ze(6,Fv,3,2,"td",4),hi(),ui(7,5),ze(8,Nv,8,12,"td",6),hi(),ui(9,7),ze(10,Lv,6,7,"td",8),hi(),ui(11,9),ze(12,Vv,3,3,"td",10),hi(),ui(13,11),ze(14,Bv,2,1,"td",12),hi(),ze(15,zv,1,0,"tr",13),l()()()),t&2&&(c(2),C("dataSource",n.gpus()),c(13),C("matRowDefColumns",n.displayedColumns))},dependencies:[Ve,rl,Ch,fh,_h,gh,bh,vh,yh,on,tn,nn,So,Ta,cl],styles:[".gpu-table[_ngcontent-%COMP%]{width:100%;white-space:nowrap}.gpu-name[_ngcontent-%COMP%]{font-weight:500}.gpu-vendor-nvidia[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #a4f021}.gpu-vendor-amd[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #ffa1a1}.gpu-vendor-other[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #b6e7ff}.index-cell[_ngcontent-%COMP%]{padding-left:0;padding-right:0}.pci-cell[_ngcontent-%COMP%]{font-family:Roboto Mono,monospace;font-size:.85rem;color:#666}.vram-cell[_ngcontent-%COMP%]{min-width:160px}.vram-text[_ngcontent-%COMP%]{display:block;margin-bottom:4px;font-size:.85rem}.vram-bar-bg[_ngcontent-%COMP%]{height:8px;background:#e0e0e0;border-radius:4px;overflow:hidden}.vram-bar-fill[_ngcontent-%COMP%]{height:100%;border-radius:4px;transition:width .4s ease,background .4s ease}.usage-cell[_ngcontent-%COMP%]{min-width:130px}.usage-value[_ngcontent-%COMP%]{display:block;margin-bottom:4px;font-weight:500;font-size:.9rem}.usage-bar-bg[_ngcontent-%COMP%]{height:8px;background:#e0e0e0;border-radius:4px;overflow:hidden}.usage-bar-fill[_ngcontent-%COMP%]{height:100%;border-radius:4px;transition:width .4s ease,background .4s ease}.temp-value[_ngcontent-%COMP%]{font-weight:500;font-size:.95rem}.mat-row[_ngcontent-%COMP%]{transition:background .2s ease;height:44px}.mat-row[_ngcontent-%COMP%]:hover{background:#fafafa}mat-card-content[_ngcontent-%COMP%]{overflow-x:hidden}"]})}}return i})();var Ia=class{_attachedHost=null;attach(o){return this._attachedHost=o,o.attach(this)}detach(){let o=this._attachedHost;o!=null&&(this._attachedHost=null,o.detach())}get isAttached(){return this._attachedHost!=null}setAttachedHost(o){this._attachedHost=o}},bi=class extends Ia{component;viewContainerRef;injector;projectableNodes;bindings;directives;constructor(o,e,t,n,a,r){super(),this.component=o,this.viewContainerRef=e,this.injector=t,this.projectableNodes=n,this.bindings=a||null,this.directives=r||null}},Et=class extends Ia{templateRef;viewContainerRef;context;injector;constructor(o,e,t,n){super(),this.templateRef=o,this.viewContainerRef=e,this.context=t,this.injector=n}get origin(){return this.templateRef.elementRef}attach(o,e=this.context){return this.context=e,super.attach(o)}detach(){return this.context=void 0,super.detach()}},xc=class extends Ia{element;constructor(o){super(),this.element=o instanceof N?o.nativeElement:o}},_n=class{_attachedPortal=null;_disposeFn=null;_isDisposed=!1;hasAttached(){return!!this._attachedPortal}attach(o){if(o instanceof bi)return this._attachedPortal=o,this.attachComponentPortal(o);if(o instanceof Et)return this._attachedPortal=o,this.attachTemplatePortal(o);if(this.attachDomPortal&&o instanceof xc)return this._attachedPortal=o,this.attachDomPortal(o)}attachDomPortal=null;detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(o){this._disposeFn=o}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}},Ra=class extends _n{outletElement;_appRef;_defaultInjector;constructor(o,e,t){super(),this.outletElement=o,this._appRef=e,this._defaultInjector=t}attachComponentPortal(o){let e;if(o.viewContainerRef){let t=o.injector||o.viewContainerRef.injector,n=t.get(tr,null,{optional:!0})||void 0;e=o.viewContainerRef.createComponent(o.component,{index:o.viewContainerRef.length,injector:t,ngModuleRef:n,projectableNodes:o.projectableNodes||void 0,bindings:o.bindings||void 0,directives:o.directives||void 0}),this.setDisposeFn(()=>e.destroy())}else{let t=this._appRef,n=o.injector||this._defaultInjector||X.NULL,a=n.get(mi,t.injector);e=or(o.component,{elementInjector:n,environmentInjector:a,projectableNodes:o.projectableNodes||void 0,bindings:o.bindings||void 0,directives:o.directives||void 0}),t.attachView(e.hostView),this.setDisposeFn(()=>{t.viewCount>0&&t.detachView(e.hostView),e.destroy()})}return this.outletElement.appendChild(this._getComponentRootNode(e)),this._attachedPortal=o,e}attachTemplatePortal(o){let e=o.viewContainerRef,t=e.createEmbeddedView(o.templateRef,o.context,{injector:o.injector});return t.rootNodes.forEach(n=>this.outletElement.appendChild(n)),t.detectChanges(),this.setDisposeFn(()=>{let n=e.indexOf(t);n!==-1&&e.remove(n)}),this._attachedPortal=o,t}attachDomPortal=o=>{let e=o.element;e.parentNode;let t=this.outletElement.ownerDocument.createComment("dom-portal");e.parentNode.insertBefore(t,e),this.outletElement.appendChild(e),this._attachedPortal=o,super.setDisposeFn(()=>{t.parentNode&&t.parentNode.replaceChild(e,t)})};dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(o){return o.hostView.rootNodes[0]}};var Ri=(()=>{class i extends _n{_moduleRef=d(tr,{optional:!0});_document=d(W);_viewContainerRef=d(Xe);_isInitialized=!1;_attachedRef=null;get portal(){return this._attachedPortal}set portal(e){this.hasAttached()&&!e&&!this._isInitialized||(this.hasAttached()&&super.detach(),e&&super.attach(e),this._attachedPortal=e||null)}attached=new K;get attachedRef(){return this._attachedRef}ngOnInit(){this._isInitialized=!0}ngOnDestroy(){super.dispose(),this._attachedRef=this._attachedPortal=null}attachComponentPortal(e){e.setAttachedHost(this);let t=e.viewContainerRef!=null?e.viewContainerRef:this._viewContainerRef,n=t.createComponent(e.component,{index:t.length,injector:e.injector||t.injector,projectableNodes:e.projectableNodes||void 0,ngModuleRef:this._moduleRef||void 0,bindings:e.bindings||void 0,directives:e.directives||void 0});return t!==this._viewContainerRef&&this._getRootNode().appendChild(n.hostView.rootNodes[0]),super.setDisposeFn(()=>n.destroy()),this._attachedPortal=e,this._attachedRef=n,this.attached.emit(n),n}attachTemplatePortal(e){e.setAttachedHost(this);let t=this._viewContainerRef.createEmbeddedView(e.templateRef,e.context,{injector:e.injector});return super.setDisposeFn(()=>this._viewContainerRef.clear()),this._attachedPortal=e,this._attachedRef=t,this.attached.emit(t),t}attachDomPortal=e=>{let t=e.element;t.parentNode;let n=this._document.createComment("dom-portal");e.setAttachedHost(this),t.parentNode.insertBefore(n,t),this._getRootNode().appendChild(t),this._attachedPortal=e,super.setDisposeFn(()=>{n.parentNode&&n.parentNode.replaceChild(t,n)})};_getRootNode(){let e=this._viewContainerRef.element.nativeElement;return e.nodeType===e.ELEMENT_NODE?e:e.parentNode}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:[0,"cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[Q]})}return i})(),Oi=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();var Ih=Or();function Ao(i){return new ds(i.get(Gt),i.get(W))}var ds=class{_viewportRuler;_previousHTMLStyles={top:"",left:""};_previousScrollPosition;_isEnabled=!1;_document;constructor(o,e){this._viewportRuler=o,this._document=e}attach(){}enable(){if(this._canBeEnabled()){let o=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=o.style.left||"",this._previousHTMLStyles.top=o.style.top||"",o.style.left=Ze(-this._previousScrollPosition.left),o.style.top=Ze(-this._previousScrollPosition.top),o.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}disable(){if(this._isEnabled){let o=this._document.documentElement,e=this._document.body,t=o.style,n=e.style,a=t.scrollBehavior||"",r=n.scrollBehavior||"";this._isEnabled=!1,t.left=this._previousHTMLStyles.left,t.top=this._previousHTMLStyles.top,o.classList.remove("cdk-global-scrollblock"),Ih&&(t.scrollBehavior=n.scrollBehavior="auto"),window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),Ih&&(t.scrollBehavior=a,n.scrollBehavior=r)}}_canBeEnabled(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;let e=this._document.documentElement,t=this._viewportRuler.getViewportSize();return e.scrollHeight>t.height||e.scrollWidth>t.width}};function Vh(i,o){return new ms(i.get(gn),i.get(H),i.get(Gt),o)}var ms=class{_scrollDispatcher;_ngZone;_viewportRuler;_config;_scrollSubscription=null;_overlayRef;_initialScrollPosition;constructor(o,e,t,n){this._scrollDispatcher=o,this._ngZone=e,this._viewportRuler=t,this._config=n}attach(o){this._overlayRef,this._overlayRef=o}enable(){if(this._scrollSubscription)return;let o=this._scrollDispatcher.scrolled(0).pipe(Ce(e=>!e||!this._overlayRef.overlayElement.contains(e.getElementRef().nativeElement)));this._config&&this._config.threshold&&this._config.threshold>1?(this._initialScrollPosition=this._viewportRuler.getViewportScrollPosition().top,this._scrollSubscription=o.subscribe(()=>{let e=this._viewportRuler.getViewportScrollPosition().top;Math.abs(e-this._initialScrollPosition)>this._config.threshold?this._detach():this._overlayRef.updatePosition()})):this._scrollSubscription=o.subscribe(this._detach)}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}_detach=()=>{this.disable(),this._overlayRef.hasAttached()&&this._ngZone.run(()=>this._overlayRef.detach())}};var Oa=class{enable(){}disable(){}attach(){}};function wc(i,o){return o.some(e=>{let t=i.bottom<e.top,n=i.top>e.bottom,a=i.right<e.left,r=i.left>e.right;return t||n||a||r})}function Rh(i,o){return o.some(e=>{let t=i.top<e.top,n=i.bottom>e.bottom,a=i.left<e.left,r=i.right>e.right;return t||n||a||r})}function yi(i,o){return new us(i.get(gn),i.get(Gt),i.get(H),o)}var us=class{_scrollDispatcher;_viewportRuler;_ngZone;_config;_scrollSubscription=null;_overlayRef;constructor(o,e,t,n){this._scrollDispatcher=o,this._viewportRuler=e,this._ngZone=t,this._config=n}attach(o){this._overlayRef,this._overlayRef=o}enable(){if(!this._scrollSubscription){let o=this._config?this._config.scrollThrottle:0;this._scrollSubscription=this._scrollDispatcher.scrolled(o).subscribe(()=>{if(this._overlayRef.updatePosition(),this._config&&this._config.autoClose){let e=this._overlayRef.overlayElement.getBoundingClientRect(),{width:t,height:n}=this._viewportRuler.getViewportSize();wc(e,[{width:t,height:n,bottom:n,right:t,top:0,left:0}])&&(this.disable(),this._ngZone.run(()=>this._overlayRef.detach()))}})}}disable(){this._scrollSubscription&&(this._scrollSubscription.unsubscribe(),this._scrollSubscription=null)}detach(){this.disable(),this._overlayRef=null}},Bh=(()=>{class i{_injector=d(X);noop=()=>new Oa;close=e=>Vh(this._injector,e);block=()=>Ao(this._injector);reposition=e=>yi(this._injector,e);static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Wt=class{positionStrategy;scrollStrategy=new Oa;panelClass="";hasBackdrop=!1;backdropClass="cdk-overlay-dark-backdrop";disableAnimations;width;height;minWidth;minHeight;maxWidth;maxHeight;direction;disposeOnNavigation=!1;usePopover;eventPredicate;constructor(o){if(o){let e=Object.keys(o);for(let t of e)o[t]!==void 0&&(this[t]=o[t])}}};var hs=class{connectionPair;scrollableViewProperties;constructor(o,e){this.connectionPair=o,this.scrollableViewProperties=e}};var zh=(()=>{class i{_attachedOverlays=[];_document=d(W);_isAttached=!1;ngOnDestroy(){this.detach()}add(e){this.remove(e),this._attachedOverlays.push(e)}remove(e){let t=this._attachedOverlays.indexOf(e);t>-1&&this._attachedOverlays.splice(t,1),this._attachedOverlays.length===0&&this.detach()}canReceiveEvent(e,t,n){return n.observers.length<1?!1:e.eventPredicate?e.eventPredicate(t):!0}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),jh=(()=>{class i extends zh{_ngZone=d(H);_renderer=d(ot).createRenderer(null,null);_cleanupKeydown;add(e){super.add(e),this._isAttached||(this._ngZone.runOutsideAngular(()=>{this._cleanupKeydown=this._renderer.listen("body","keydown",this._keydownListener)}),this._isAttached=!0)}detach(){this._isAttached&&(this._cleanupKeydown?.(),this._isAttached=!1)}_keydownListener=e=>{let t=this._attachedOverlays;for(let n=t.length-1;n>-1;n--){let a=t[n];if(this.canReceiveEvent(a,e,a._keydownEvents)){this._ngZone.run(()=>a._keydownEvents.next(e));break}}};static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Hh=(()=>{class i extends zh{_platform=d(le);_ngZone=d(H);_renderer=d(ot).createRenderer(null,null);_cursorOriginalValue;_cursorStyleIsSet=!1;_pointerDownEventTarget=null;_cleanups;add(e){if(super.add(e),!this._isAttached){let t=this._document.body,n={capture:!0},a=this._renderer;this._cleanups=this._ngZone.runOutsideAngular(()=>[a.listen(t,"pointerdown",this._pointerDownListener,n),a.listen(t,"click",this._clickListener,n),a.listen(t,"auxclick",this._clickListener,n),a.listen(t,"contextmenu",this._clickListener,n)]),this._platform.IOS&&!this._cursorStyleIsSet&&(this._cursorOriginalValue=t.style.cursor,t.style.cursor="pointer",this._cursorStyleIsSet=!0),this._isAttached=!0}}detach(){this._isAttached&&(this._cleanups?.forEach(e=>e()),this._cleanups=void 0,this._platform.IOS&&this._cursorStyleIsSet&&(this._document.body.style.cursor=this._cursorOriginalValue,this._cursorStyleIsSet=!1),this._isAttached=!1)}_pointerDownListener=e=>{this._pointerDownEventTarget=rt(e)};_clickListener=e=>{let t=rt(e),n=e.type==="click"&&this._pointerDownEventTarget?this._pointerDownEventTarget:t;this._pointerDownEventTarget=null;let a=this._attachedOverlays.slice();for(let r=a.length-1;r>-1;r--){let u=a[r],h=u._outsidePointerEvents;if(!(!u.hasAttached()||!this.canReceiveEvent(u,e,h))){if(Oh(u.overlayElement,t)||Oh(u.overlayElement,n))break;this._ngZone?this._ngZone.run(()=>h.next(e)):h.next(e)}}};static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function Oh(i,o){let e=typeof ShadowRoot<"u"&&ShadowRoot,t=o;for(;t;){if(t===i)return!0;t=e&&t instanceof ShadowRoot?t.host:t.parentNode}return!1}var Uh=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["ng-component"]],hostAttrs:["cdk-overlay-style-loader",""],decls:0,vars:0,template:function(t,n){},styles:[`.cdk-overlay-container, .cdk-global-overlay-wrapper {
3020
3020
  pointer-events: none;
3021
3021
  top: 0;
3022
3022
  left: 0;
@@ -3155,14 +3155,14 @@ input.mat-mdc-chip-input {
3155
3155
  position: fixed;
3156
3156
  z-index: auto;
3157
3157
  }
3158
- `],encapsulation:2})}return i})(),hs=(()=>{class i{_platform=d(le);_containerElement;_document=d($);_styleLoader=d(Fe);ngOnDestroy(){this._containerElement?.remove()}getContainerElement(){return this._loadStyles(),this._containerElement||this._createContainer(),this._containerElement}_createContainer(){let e="cdk-overlay-container";if(this._platform.isBrowser||Rl()){let n=this._document.querySelectorAll(`.${e}[platform="server"], .${e}[platform="test"]`);for(let a=0;a<n.length;a++)n[a].remove()}let t=this._document.createElement("div");t.classList.add(e),Rl()?t.setAttribute("platform","test"):this._platform.isBrowser||t.setAttribute("platform","server"),this._document.body.appendChild(t),this._containerElement=t}_loadStyles(){this._styleLoader.load(Uh)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),wc=class{_renderer;_ngZone;element;_cleanupClick;_cleanupTransitionEnd;_fallbackTimeout;constructor(o,e,t,n){this._renderer=e,this._ngZone=t,this.element=o.createElement("div"),this.element.classList.add("cdk-overlay-backdrop"),this._cleanupClick=e.listen(this.element,"click",n)}detach(){this._ngZone.runOutsideAngular(()=>{let o=this.element;clearTimeout(this._fallbackTimeout),this._cleanupTransitionEnd?.(),this._cleanupTransitionEnd=this._renderer.listen(o,"transitionend",this.dispose),this._fallbackTimeout=setTimeout(this.dispose,500),o.style.pointerEvents="none",o.classList.remove("cdk-overlay-backdrop-showing")})}dispose=()=>{clearTimeout(this._fallbackTimeout),this._cleanupClick?.(),this._cleanupTransitionEnd?.(),this._cleanupClick=this._cleanupTransitionEnd=this._fallbackTimeout=void 0,this.element.remove()}};function Dc(i){return i&&i.nodeType===1}var ko=class{_portalOutlet;_host;_pane;_config;_ngZone;_keyboardDispatcher;_document;_location;_outsideClickDispatcher;_animationsDisabled;_injector;_renderer;_backdropClick=new I;_attachments=new I;_detachments=new I;_positionStrategy;_scrollStrategy;_locationChanges=De.EMPTY;_backdropRef=null;_detachContentMutationObserver;_detachContentAfterRenderRef;_disposed=!1;_previousHostParent;_keydownEvents=new I;_outsidePointerEvents=new I;_afterNextRenderRef;constructor(o,e,t,n,a,r,u,h,g,_=!1,w,B){this._portalOutlet=o,this._host=e,this._pane=t,this._config=n,this._ngZone=a,this._keyboardDispatcher=r,this._document=u,this._location=h,this._outsideClickDispatcher=g,this._animationsDisabled=_,this._injector=w,this._renderer=B,n.scrollStrategy&&(this._scrollStrategy=n.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=n.positionStrategy}get overlayElement(){return this._pane}get backdropElement(){return this._backdropRef?.element||null}get hostElement(){return this._host}get eventPredicate(){return this._config?.eventPredicate||null}attach(o){if(this._disposed)return null;this._attachHost();let e=this._portalOutlet.attach(o);return this._positionStrategy?.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._afterNextRenderRef?.destroy(),this._afterNextRenderRef=Be(()=>{this.hasAttached()&&this.updatePosition()},{injector:this._injector}),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._completeDetachContent(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&(this._locationChanges=this._location.subscribe(()=>this.dispose())),this._outsideClickDispatcher.add(this),typeof e?.onDestroy=="function"&&e.onDestroy(()=>{this.hasAttached()&&this._ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>this.detach()))}),e}detach(){if(!this.hasAttached())return;this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();let o=this._portalOutlet.detach();return this._detachments.next(),this._completeDetachContent(),this._keyboardDispatcher.remove(this),this._detachContentWhenEmpty(),this._locationChanges.unsubscribe(),this._outsideClickDispatcher.remove(this),o}dispose(){if(this._disposed)return;let o=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this._backdropRef?.dispose(),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._outsidePointerEvents.complete(),this._outsideClickDispatcher.remove(this),this._host?.remove(),this._afterNextRenderRef?.destroy(),this._previousHostParent=this._pane=this._host=this._backdropRef=null,o&&this._detachments.next(),this._detachments.complete(),this._completeDetachContent(),this._disposed=!0}hasAttached(){return this._portalOutlet.hasAttached()}backdropClick(){return this._backdropClick}attachments(){return this._attachments}detachments(){return this._detachments}keydownEvents(){return this._keydownEvents}outsidePointerEvents(){return this._outsidePointerEvents}getConfig(){return this._config}updatePosition(){this._positionStrategy&&this._positionStrategy.apply()}updatePositionStrategy(o){o!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=o,this.hasAttached()&&(o.attach(this),this.updatePosition()))}updateSize(o){this._config=V(V({},this._config),o),this._updateElementSize()}setDirection(o){this._config=Oe(V({},this._config),{direction:o}),this._updateElementDirection()}addPanelClass(o){this._pane&&this._toggleClasses(this._pane,o,!0)}removePanelClass(o){this._pane&&this._toggleClasses(this._pane,o,!1)}getDirection(){let o=this._config.direction;return o?typeof o=="string"?o:o.value:"ltr"}updateScrollStrategy(o){o!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=o,this.hasAttached()&&(o.attach(this),o.enable()))}_updateElementDirection(){this._host.setAttribute("dir",this.getDirection())}_updateElementSize(){if(!this._pane)return;let o=this._pane.style;o.width=Ze(this._config.width),o.height=Ze(this._config.height),o.minWidth=Ze(this._config.minWidth),o.minHeight=Ze(this._config.minHeight),o.maxWidth=Ze(this._config.maxWidth),o.maxHeight=Ze(this._config.maxHeight)}_togglePointerEvents(o){this._pane.style.pointerEvents=o?"":"none"}_attachHost(){if(!this._host.parentElement){let o=this._config.usePopover?this._positionStrategy?.getPopoverInsertionPoint?.():null;Dc(o)?o.after(this._host):o?.type==="parent"?o.element.appendChild(this._host):this._previousHostParent?.appendChild(this._host)}if(this._config.usePopover)try{this._host.showPopover()}catch(o){}}_attachBackdrop(){let o="cdk-overlay-backdrop-showing";this._backdropRef?.dispose(),this._backdropRef=new wc(this._document,this._renderer,this._ngZone,e=>{this._backdropClick.next(e)}),this._animationsDisabled&&this._backdropRef.element.classList.add("cdk-overlay-backdrop-noop-animation"),this._config.backdropClass&&this._toggleClasses(this._backdropRef.element,this._config.backdropClass,!0),this._config.usePopover?this._host.prepend(this._backdropRef.element):this._host.parentElement.insertBefore(this._backdropRef.element,this._host),!this._animationsDisabled&&typeof requestAnimationFrame<"u"?this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>this._backdropRef?.element.classList.add(o))}):this._backdropRef.element.classList.add(o)}_updateStackingOrder(){!this._config.usePopover&&this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}detachBackdrop(){this._animationsDisabled?(this._backdropRef?.dispose(),this._backdropRef=null):this._backdropRef?.detach()}_toggleClasses(o,e,t){let n=Vi(e||[]).filter(a=>!!a);n.length&&(t?o.classList.add(...n):o.classList.remove(...n))}_detachContentWhenEmpty(){let o=!1;try{this._detachContentAfterRenderRef=Be(()=>{o=!0,this._detachContent()},{injector:this._injector})}catch(e){if(o)throw e;this._detachContent()}globalThis.MutationObserver&&this._pane&&(this._detachContentMutationObserver||=new globalThis.MutationObserver(()=>{this._detachContent()}),this._detachContentMutationObserver.observe(this._pane,{childList:!0}))}_detachContent(){(!this._pane||!this._host||this._pane.children.length===0)&&(this._pane&&this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!1),this._host&&this._host.parentElement&&(this._previousHostParent=this._host.parentElement,this._host.remove()),this._completeDetachContent())}_completeDetachContent(){this._detachContentAfterRenderRef?.destroy(),this._detachContentAfterRenderRef=void 0,this._detachContentMutationObserver?.disconnect()}_disposeScrollStrategy(){let o=this._scrollStrategy;o?.disable(),o?.detach?.()}},Ph="cdk-overlay-connected-position-bounding-box",jv=/([A-Za-z%]+)$/;function $i(i,o){return new ms(o,i.get(Gt),i.get($),i.get(le),i.get(hs))}var ms=class{_viewportRuler;_document;_platform;_overlayContainer;_overlayRef;_isInitialRender=!1;_lastBoundingBoxSize={width:0,height:0};_isPushed=!1;_canPush=!0;_growAfterOpen=!1;_hasFlexibleDimensions=!0;_positionLocked=!1;_originRect;_overlayRect;_viewportRect;_containerRect;_viewportMargin=0;_scrollables=[];_preferredPositions=[];_origin;_pane;_isDisposed=!1;_boundingBox=null;_lastPosition=null;_lastScrollVisibility=null;_positionChanges=new I;_resizeSubscription=De.EMPTY;_offsetX=0;_offsetY=0;_transformOriginSelector;_appliedPanelClasses=[];_previousPushAmount=null;_popoverLocation="global";positionChanges=this._positionChanges;get positions(){return this._preferredPositions}constructor(o,e,t,n,a){this._viewportRuler=e,this._document=t,this._platform=n,this._overlayContainer=a,this.setOrigin(o)}attach(o){this._overlayRef&&this._overlayRef,this._validatePositions(),o.hostElement.classList.add(Ph),this._overlayRef=o,this._boundingBox=o.hostElement,this._pane=o.overlayElement,this._isDisposed=!1,this._isInitialRender=!0,this._lastPosition=null,this._resizeSubscription.unsubscribe(),this._resizeSubscription=this._viewportRuler.change().subscribe(()=>{this._isInitialRender=!0,this.apply()})}apply(){if(this._isDisposed||!this._platform.isBrowser)return;if(!this._isInitialRender&&this._positionLocked&&this._lastPosition){this.reapplyLastPosition();return}this._clearPanelClasses(),this._resetOverlayElementStyles(),this._resetBoundingBoxStyles(),this._viewportRect=this._getNarrowedViewportRect(),this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._containerRect=this._getContainerRect();let o=this._originRect,e=this._overlayRect,t=this._viewportRect,n=this._containerRect,a=[],r;for(let u of this._preferredPositions){let h=this._getOriginPoint(o,n,u),g=this._getOverlayPoint(h,e,u),_=this._getOverlayFit(g,e,t,u);if(_.isCompletelyWithinViewport){this._isPushed=!1,this._applyPosition(u,h);return}if(this._canFitWithFlexibleDimensions(_,g,t)){a.push({position:u,origin:h,overlayRect:e,boundingBoxRect:this._calculateBoundingBoxRect(h,u)});continue}(!r||r.overlayFit.visibleArea<_.visibleArea)&&(r={overlayFit:_,overlayPoint:g,originPoint:h,position:u,overlayRect:e})}if(a.length){let u=null,h=-1;for(let g of a){let _=g.boundingBoxRect.width*g.boundingBoxRect.height*(g.position.weight||1);_>h&&(h=_,u=g)}this._isPushed=!1,this._applyPosition(u.position,u.origin);return}if(this._canPush){this._isPushed=!0,this._applyPosition(r.position,r.originPoint);return}this._applyPosition(r.position,r.originPoint)}detach(){this._clearPanelClasses(),this._lastPosition=null,this._previousPushAmount=null,this._resizeSubscription.unsubscribe()}dispose(){this._isDisposed||(this._boundingBox&&Un(this._boundingBox.style,{top:"",left:"",right:"",bottom:"",height:"",width:"",alignItems:"",justifyContent:""}),this._pane&&this._resetOverlayElementStyles(),this._overlayRef&&this._overlayRef.hostElement.classList.remove(Ph),this.detach(),this._positionChanges.complete(),this._overlayRef=this._boundingBox=null,this._isDisposed=!0)}reapplyLastPosition(){if(this._isDisposed||!this._platform.isBrowser)return;let o=this._lastPosition;o?(this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._viewportRect=this._getNarrowedViewportRect(),this._containerRect=this._getContainerRect(),this._applyPosition(o,this._getOriginPoint(this._originRect,this._containerRect,o))):this.apply()}withScrollableContainers(o){return this._scrollables=o,this}withPositions(o){return this._preferredPositions=o,o.indexOf(this._lastPosition)===-1&&(this._lastPosition=null),this._validatePositions(),this}withViewportMargin(o){return this._viewportMargin=o,this}withFlexibleDimensions(o=!0){return this._hasFlexibleDimensions=o,this}withGrowAfterOpen(o=!0){return this._growAfterOpen=o,this}withPush(o=!0){return this._canPush=o,this}withLockedPosition(o=!0){return this._positionLocked=o,this}setOrigin(o){return this._origin=o,this}withDefaultOffsetX(o){return this._offsetX=o,this}withDefaultOffsetY(o){return this._offsetY=o,this}withTransformOriginOn(o){return this._transformOriginSelector=o,this}withPopoverLocation(o){return this._popoverLocation=o,this}getPopoverInsertionPoint(){return this._popoverLocation==="global"?null:this._popoverLocation!=="inline"?this._popoverLocation:this._origin instanceof N?this._origin.nativeElement:Dc(this._origin)?this._origin:null}_getOriginPoint(o,e,t){let n;if(t.originX=="center")n=o.left+o.width/2;else{let r=this._isRtl()?o.right:o.left,u=this._isRtl()?o.left:o.right;n=t.originX=="start"?r:u}e.left<0&&(n-=e.left);let a;return t.originY=="center"?a=o.top+o.height/2:a=t.originY=="top"?o.top:o.bottom,e.top<0&&(a-=e.top),{x:n,y:a}}_getOverlayPoint(o,e,t){let n;t.overlayX=="center"?n=-e.width/2:t.overlayX==="start"?n=this._isRtl()?-e.width:0:n=this._isRtl()?0:-e.width;let a;return t.overlayY=="center"?a=-e.height/2:a=t.overlayY=="top"?0:-e.height,{x:o.x+n,y:o.y+a}}_getOverlayFit(o,e,t,n){let a=Nh(e),{x:r,y:u}=o,h=this._getOffset(n,"x"),g=this._getOffset(n,"y");h&&(r+=h),g&&(u+=g);let _=0-r,w=r+a.width-t.width,B=0-u,G=u+a.height-t.height,ie=this._subtractOverflows(a.width,_,w),fe=this._subtractOverflows(a.height,B,G),se=ie*fe;return{visibleArea:se,isCompletelyWithinViewport:a.width*a.height===se,fitsInViewportVertically:fe===a.height,fitsInViewportHorizontally:ie==a.width}}_canFitWithFlexibleDimensions(o,e,t){if(this._hasFlexibleDimensions){let n=t.bottom-e.y,a=t.right-e.x,r=Fh(this._overlayRef.getConfig().minHeight),u=Fh(this._overlayRef.getConfig().minWidth),h=o.fitsInViewportVertically||r!=null&&r<=n,g=o.fitsInViewportHorizontally||u!=null&&u<=a;return h&&g}return!1}_pushOverlayOnScreen(o,e,t){if(this._previousPushAmount&&this._positionLocked)return{x:o.x+this._previousPushAmount.x,y:o.y+this._previousPushAmount.y};let n=Nh(e),a=this._viewportRect,r=Math.max(o.x+n.width-a.width,0),u=Math.max(o.y+n.height-a.height,0),h=Math.max(a.top-t.top-o.y,0),g=Math.max(a.left-t.left-o.x,0),_=0,w=0;return n.width<=a.width?_=g||-r:_=o.x<this._getViewportMarginStart()?a.left-t.left-o.x:0,n.height<=a.height?w=h||-u:w=o.y<this._getViewportMarginTop()?a.top-t.top-o.y:0,this._previousPushAmount={x:_,y:w},{x:o.x+_,y:o.y+w}}_applyPosition(o,e){if(this._setTransformOrigin(o),this._setOverlayElementStyles(e,o),this._setBoundingBoxStyles(e,o),o.panelClass&&this._addPanelClasses(o.panelClass),this._positionChanges.observers.length){let t=this._getScrollVisibility();if(o!==this._lastPosition||!this._lastScrollVisibility||!Hv(this._lastScrollVisibility,t)){let n=new ds(o,t);this._positionChanges.next(n)}this._lastScrollVisibility=t}this._lastPosition=o,this._isInitialRender=!1}_setTransformOrigin(o){if(!this._transformOriginSelector)return;let e=this._boundingBox.querySelectorAll(this._transformOriginSelector),t,n=o.overlayY;o.overlayX==="center"?t="center":this._isRtl()?t=o.overlayX==="start"?"right":"left":t=o.overlayX==="start"?"left":"right";for(let a=0;a<e.length;a++)e[a].style.transformOrigin=`${t} ${n}`}_calculateBoundingBoxRect(o,e){let t=this._viewportRect,n=this._isRtl(),a,r,u;if(e.overlayY==="top")r=o.y,a=t.height-r+this._getViewportMarginBottom();else if(e.overlayY==="bottom")u=t.height-o.y+this._getViewportMarginTop()+this._getViewportMarginBottom(),a=t.height-u+this._getViewportMarginTop();else{let G=Math.min(t.bottom-o.y+t.top,o.y),ie=this._lastBoundingBoxSize.height;a=G*2,r=o.y-G,a>ie&&!this._isInitialRender&&!this._growAfterOpen&&(r=o.y-ie/2)}let h=e.overlayX==="start"&&!n||e.overlayX==="end"&&n,g=e.overlayX==="end"&&!n||e.overlayX==="start"&&n,_,w,B;if(g)B=t.width-o.x+this._getViewportMarginStart()+this._getViewportMarginEnd(),_=o.x-this._getViewportMarginStart();else if(h)w=o.x,_=t.right-o.x-this._getViewportMarginEnd();else{let G=Math.min(t.right-o.x+t.left,o.x),ie=this._lastBoundingBoxSize.width;_=G*2,w=o.x-G,_>ie&&!this._isInitialRender&&!this._growAfterOpen&&(w=o.x-ie/2)}return{top:r,left:w,bottom:u,right:B,width:_,height:a}}_setBoundingBoxStyles(o,e){let t=this._calculateBoundingBoxRect(o,e);!this._isInitialRender&&!this._growAfterOpen&&(t.height=Math.min(t.height,this._lastBoundingBoxSize.height),t.width=Math.min(t.width,this._lastBoundingBoxSize.width));let n={};if(this._hasExactPosition())n.top=n.left="0",n.bottom=n.right="auto",n.maxHeight=n.maxWidth="",n.width=n.height="100%";else{let a=this._overlayRef.getConfig().maxHeight,r=this._overlayRef.getConfig().maxWidth;n.width=Ze(t.width),n.height=Ze(t.height),n.top=Ze(t.top)||"auto",n.bottom=Ze(t.bottom)||"auto",n.left=Ze(t.left)||"auto",n.right=Ze(t.right)||"auto",e.overlayX==="center"?n.alignItems="center":n.alignItems=e.overlayX==="end"?"flex-end":"flex-start",e.overlayY==="center"?n.justifyContent="center":n.justifyContent=e.overlayY==="bottom"?"flex-end":"flex-start",a&&(n.maxHeight=Ze(a)),r&&(n.maxWidth=Ze(r))}this._lastBoundingBoxSize=t,Un(this._boundingBox.style,n)}_resetBoundingBoxStyles(){Un(this._boundingBox.style,{top:"0",left:"0",right:"0",bottom:"0",height:"",width:"",alignItems:"",justifyContent:""})}_resetOverlayElementStyles(){Un(this._pane.style,{top:"",left:"",bottom:"",right:"",position:"",transform:""})}_setOverlayElementStyles(o,e){let t={},n=this._hasExactPosition(),a=this._hasFlexibleDimensions,r=this._overlayRef.getConfig();if(n){let _=this._viewportRuler.getViewportScrollPosition();Un(t,this._getExactOverlayY(e,o,_)),Un(t,this._getExactOverlayX(e,o,_))}else t.position="static";let u="",h=this._getOffset(e,"x"),g=this._getOffset(e,"y");h&&(u+=`translateX(${h}px) `),g&&(u+=`translateY(${g}px)`),t.transform=u.trim(),r.maxHeight&&(n?t.maxHeight=Ze(r.maxHeight):a&&(t.maxHeight="")),r.maxWidth&&(n?t.maxWidth=Ze(r.maxWidth):a&&(t.maxWidth="")),Un(this._pane.style,t)}_getExactOverlayY(o,e,t){let n={top:"",bottom:""},a=this._getOverlayPoint(e,this._overlayRect,o);if(this._isPushed&&(a=this._pushOverlayOnScreen(a,this._overlayRect,t)),o.overlayY==="bottom"){let r=this._document.documentElement.clientHeight;n.bottom=`${r-(a.y+this._overlayRect.height)}px`}else n.top=Ze(a.y);return n}_getExactOverlayX(o,e,t){let n={left:"",right:""},a=this._getOverlayPoint(e,this._overlayRect,o);this._isPushed&&(a=this._pushOverlayOnScreen(a,this._overlayRect,t));let r;if(this._isRtl()?r=o.overlayX==="end"?"left":"right":r=o.overlayX==="end"?"right":"left",r==="right"){let u=this._document.documentElement.clientWidth;n.right=`${u-(a.x+this._overlayRect.width)}px`}else n.left=Ze(a.x);return n}_getScrollVisibility(){let o=this._getOriginRect(),e=this._pane.getBoundingClientRect(),t=this._scrollables.map(n=>n.getElementRef().nativeElement.getBoundingClientRect());return{isOriginClipped:Rh(o,t),isOriginOutsideView:xc(o,t),isOverlayClipped:Rh(e,t),isOverlayOutsideView:xc(e,t)}}_subtractOverflows(o,...e){return e.reduce((t,n)=>t-Math.max(n,0),o)}_getNarrowedViewportRect(){let o=this._document.documentElement.clientWidth,e=this._document.documentElement.clientHeight,t=this._viewportRuler.getViewportScrollPosition();return{top:t.top+this._getViewportMarginTop(),left:t.left+this._getViewportMarginStart(),right:t.left+o-this._getViewportMarginEnd(),bottom:t.top+e-this._getViewportMarginBottom(),width:o-this._getViewportMarginStart()-this._getViewportMarginEnd(),height:e-this._getViewportMarginTop()-this._getViewportMarginBottom()}}_isRtl(){return this._overlayRef.getDirection()==="rtl"}_hasExactPosition(){return!this._hasFlexibleDimensions||this._isPushed}_getOffset(o,e){return e==="x"?o.offsetX==null?this._offsetX:o.offsetX:o.offsetY==null?this._offsetY:o.offsetY}_validatePositions(){}_addPanelClasses(o){this._pane&&Vi(o).forEach(e=>{e!==""&&this._appliedPanelClasses.indexOf(e)===-1&&(this._appliedPanelClasses.push(e),this._pane.classList.add(e))})}_clearPanelClasses(){this._pane&&(this._appliedPanelClasses.forEach(o=>{this._pane.classList.remove(o)}),this._appliedPanelClasses=[])}_getViewportMarginStart(){return typeof this._viewportMargin=="number"?this._viewportMargin:this._viewportMargin?.start??0}_getViewportMarginEnd(){return typeof this._viewportMargin=="number"?this._viewportMargin:this._viewportMargin?.end??0}_getViewportMarginTop(){return typeof this._viewportMargin=="number"?this._viewportMargin:this._viewportMargin?.top??0}_getViewportMarginBottom(){return typeof this._viewportMargin=="number"?this._viewportMargin:this._viewportMargin?.bottom??0}_getOriginRect(){let o=this._origin;if(o instanceof N)return o.nativeElement.getBoundingClientRect();if(o instanceof Element)return o.getBoundingClientRect();let e=o.width||0,t=o.height||0;return{top:o.y,bottom:o.y+t,left:o.x,right:o.x+e,height:t,width:e}}_getContainerRect(){let o=this._overlayRef.getConfig().usePopover&&this._popoverLocation!=="global",e=this._overlayContainer.getContainerElement();o&&(e.style.display="block");let t=e.getBoundingClientRect();return o&&(e.style.display=""),t}};function Un(i,o){for(let e in o)o.hasOwnProperty(e)&&(i[e]=o[e]);return i}function Fh(i){if(typeof i!="number"&&i!=null){let[o,e]=i.split(jv);return!e||e==="px"?parseFloat(o):null}return i||null}function Nh(i){return{top:Math.floor(i.top),right:Math.floor(i.right),bottom:Math.floor(i.bottom),left:Math.floor(i.left),width:Math.floor(i.width),height:Math.floor(i.height)}}function Hv(i,o){return i===o?!0:i.isOriginClipped===o.isOriginClipped&&i.isOriginOutsideView===o.isOriginOutsideView&&i.isOverlayClipped===o.isOverlayClipped&&i.isOverlayOutsideView===o.isOverlayOutsideView}var Lh="cdk-global-overlay-wrapper";function vn(i){return new us}var us=class{_overlayRef;_cssPosition="static";_topOffset="";_bottomOffset="";_alignItems="";_xPosition="";_xOffset="";_width="";_height="";_isDisposed=!1;attach(o){let e=o.getConfig();this._overlayRef=o,this._width&&!e.width&&o.updateSize({width:this._width}),this._height&&!e.height&&o.updateSize({height:this._height}),o.hostElement.classList.add(Lh),this._isDisposed=!1}top(o=""){return this._bottomOffset="",this._topOffset=o,this._alignItems="flex-start",this}left(o=""){return this._xOffset=o,this._xPosition="left",this}bottom(o=""){return this._topOffset="",this._bottomOffset=o,this._alignItems="flex-end",this}right(o=""){return this._xOffset=o,this._xPosition="right",this}start(o=""){return this._xOffset=o,this._xPosition="start",this}end(o=""){return this._xOffset=o,this._xPosition="end",this}width(o=""){return this._overlayRef?this._overlayRef.updateSize({width:o}):this._width=o,this}height(o=""){return this._overlayRef?this._overlayRef.updateSize({height:o}):this._height=o,this}centerHorizontally(o=""){return this.left(o),this._xPosition="center",this}centerVertically(o=""){return this.top(o),this._alignItems="center",this}apply(){if(!this._overlayRef||!this._overlayRef.hasAttached())return;let o=this._overlayRef.overlayElement.style,e=this._overlayRef.hostElement.style,t=this._overlayRef.getConfig(),{width:n,height:a,maxWidth:r,maxHeight:u}=t,h=(n==="100%"||n==="100vw")&&(!r||r==="100%"||r==="100vw"),g=(a==="100%"||a==="100vh")&&(!u||u==="100%"||u==="100vh"),_=this._xPosition,w=this._xOffset,B=this._overlayRef.getConfig().direction==="rtl",G="",ie="",fe="";h?fe="flex-start":_==="center"?(fe="center",B?ie=w:G=w):B?_==="left"||_==="end"?(fe="flex-end",G=w):(_==="right"||_==="start")&&(fe="flex-start",ie=w):_==="left"||_==="start"?(fe="flex-start",G=w):(_==="right"||_==="end")&&(fe="flex-end",ie=w),o.position=this._cssPosition,o.marginLeft=h?"0":G,o.marginTop=g?"0":this._topOffset,o.marginBottom=this._bottomOffset,o.marginRight=h?"0":ie,e.justifyContent=fe,e.alignItems=g?"flex-start":this._alignItems}dispose(){if(this._isDisposed||!this._overlayRef)return;let o=this._overlayRef.overlayElement.style,e=this._overlayRef.hostElement,t=e.style;e.classList.remove(Lh),t.justifyContent=t.alignItems=o.marginTop=o.marginBottom=o.marginLeft=o.marginRight=o.position="",this._overlayRef=null,this._isDisposed=!0}},Gh=(()=>{class i{_injector=d(X);global(){return vn()}flexibleConnectedTo(e){return $i(this._injector,e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Ra=new C("OVERLAY_DEFAULT_CONFIG");function qt(i,o){i.get(Fe).load(Uh);let e=i.get(hs),t=i.get($),n=i.get(be),a=i.get(Qi),r=i.get(qe),u=i.get(ve,null,{optional:!0})||i.get(ot).createRenderer(null,null),h=new Wt(o),g=i.get(Ra,null,{optional:!0})?.usePopover??!0;h.direction=h.direction||r.value,"showPopover"in t.body?h.usePopover=o?.usePopover??g:h.usePopover=!1;let _=t.createElement("div"),w=t.createElement("div");_.id=n.getId("cdk-overlay-"),_.classList.add("cdk-overlay-pane"),w.appendChild(_),h.usePopover&&(w.setAttribute("popover","manual"),w.classList.add("cdk-overlay-popover"));let B=h.usePopover?h.positionStrategy?.getPopoverInsertionPoint?.():null;return Dc(B)?B.after(w):B?.type==="parent"?B.element.appendChild(w):e.getContainerElement().appendChild(w),new ko(new Ta(_,a,i),w,_,h,i.get(H),i.get(jh),t,i.get(ar),i.get(Hh),o?.disableAnimations??i.get(Pi,null,{optional:!0})==="NoopAnimations",i.get(mi),u)}var $h=(()=>{class i{scrollStrategies=d(Bh);_positionBuilder=d(Gh);_injector=d(X);create(e){return qt(this._injector,e)}position(){return this._positionBuilder}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Uv=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],Gv=new C("cdk-connected-overlay-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>yi(i)}}),So=(()=>{class i{elementRef=d(N);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdk-overlay-origin",""],["","overlay-origin",""],["","cdkOverlayOrigin",""]],exportAs:["cdkOverlayOrigin"]})}return i})(),Wh=new C("cdk-connected-overlay-default-config"),ps=(()=>{class i{_dir=d(qe,{optional:!0});_injector=d(X);_overlayRef;_templatePortal;_backdropSubscription=De.EMPTY;_attachSubscription=De.EMPTY;_detachSubscription=De.EMPTY;_positionSubscription=De.EMPTY;_offsetX;_offsetY;_position;_scrollStrategyFactory=d(Gv);_ngZone=d(H);origin;positions;positionStrategy;get offsetX(){return this._offsetX}set offsetX(e){this._offsetX=e,this._position&&this._updatePositionStrategy(this._position)}get offsetY(){return this._offsetY}set offsetY(e){this._offsetY=e,this._position&&this._updatePositionStrategy(this._position)}width;height;minWidth;minHeight;backdropClass;panelClass;viewportMargin=0;scrollStrategy;open=!1;disableClose=!1;transformOriginSelector;hasBackdrop=!1;lockPosition=!1;flexibleDimensions=!1;growAfterOpen=!1;push=!1;disposeOnNavigation=!1;usePopover;matchWidth=!1;set _config(e){typeof e!="string"&&this._assignConfig(e)}backdropClick=new K;positionChange=new K;attach=new K;detach=new K;overlayKeydown=new K;overlayOutsideClick=new K;constructor(){let e=d(Ye),t=d(Xe),n=d(Wh,{optional:!0}),a=d(Ra,{optional:!0});this.usePopover=a?.usePopover===!1?null:"global",this._templatePortal=new Et(e,t),this.scrollStrategy=this._scrollStrategyFactory(),n&&this._assignConfig(n)}get overlayRef(){return this._overlayRef}get dir(){return this._dir?this._dir.value:"ltr"}ngOnDestroy(){this._attachSubscription.unsubscribe(),this._detachSubscription.unsubscribe(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this._overlayRef?.dispose()}ngOnChanges(e){this._position&&(this._updatePositionStrategy(this._position),this._overlayRef?.updateSize({width:this._getWidth(),minWidth:this.minWidth,height:this.height,minHeight:this.minHeight}),e.origin&&this.open&&this._position.apply()),e.open&&(this.open?this.attachOverlay():this.detachOverlay())}_createOverlay(){(!this.positions||!this.positions.length)&&(this.positions=Uv);let e=this._overlayRef=qt(this._injector,this._buildConfig());this._attachSubscription=e.attachments().subscribe(()=>this.attach.emit()),this._detachSubscription=e.detachments().subscribe(()=>this.detach.emit()),e.keydownEvents().subscribe(t=>{this.overlayKeydown.next(t),t.keyCode===27&&!this.disableClose&&!Ge(t)&&(t.preventDefault(),this.detachOverlay())}),this._overlayRef.outsidePointerEvents().subscribe(t=>{let n=this._getOriginElement(),a=rt(t);(!n||n!==a&&!n.contains(a))&&this.overlayOutsideClick.next(t)})}_buildConfig(){let e=this._position=this.positionStrategy||this._createPositionStrategy(),t=new Wt({direction:this._dir||"ltr",positionStrategy:e,scrollStrategy:this.scrollStrategy,hasBackdrop:this.hasBackdrop,disposeOnNavigation:this.disposeOnNavigation,usePopover:!!this.usePopover});return(this.height||this.height===0)&&(t.height=this.height),(this.minWidth||this.minWidth===0)&&(t.minWidth=this.minWidth),(this.minHeight||this.minHeight===0)&&(t.minHeight=this.minHeight),this.backdropClass&&(t.backdropClass=this.backdropClass),this.panelClass&&(t.panelClass=this.panelClass),t}_updatePositionStrategy(e){let t=this.positions.map(n=>({originX:n.originX,originY:n.originY,overlayX:n.overlayX,overlayY:n.overlayY,offsetX:n.offsetX||this.offsetX,offsetY:n.offsetY||this.offsetY,panelClass:n.panelClass||void 0}));return e.setOrigin(this._getOrigin()).withPositions(t).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector).withPopoverLocation(this.usePopover===null?"global":this.usePopover)}_createPositionStrategy(){let e=$i(this._injector,this._getOrigin());return this._updatePositionStrategy(e),e}_getOrigin(){return this.origin instanceof So?this.origin.elementRef:this.origin}_getOriginElement(){return this.origin instanceof So?this.origin.elementRef.nativeElement:this.origin instanceof N?this.origin.nativeElement:typeof Element<"u"&&this.origin instanceof Element?this.origin:null}_getWidth(){return this.width?this.width:this.matchWidth?this._getOriginElement()?.getBoundingClientRect?.().width:void 0}attachOverlay(){this._overlayRef||this._createOverlay();let e=this._overlayRef;e.getConfig().hasBackdrop=this.hasBackdrop,e.updateSize({width:this._getWidth()}),e.hasAttached()||e.attach(this._templatePortal),this.hasBackdrop?this._backdropSubscription=e.backdropClick().subscribe(t=>this.backdropClick.emit(t)):this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.positionChange.observers.length>0&&(this._positionSubscription=this._position.positionChanges.pipe(Xc(()=>this.positionChange.observers.length>0)).subscribe(t=>{this._ngZone.run(()=>this.positionChange.emit(t)),this.positionChange.observers.length===0&&this._positionSubscription.unsubscribe()})),this.open=!0}detachOverlay(){this._overlayRef?.detach(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.open=!1}_assignConfig(e){this.origin=e.origin??this.origin,this.positions=e.positions??this.positions,this.positionStrategy=e.positionStrategy??this.positionStrategy,this.offsetX=e.offsetX??this.offsetX,this.offsetY=e.offsetY??this.offsetY,this.width=e.width??this.width,this.height=e.height??this.height,this.minWidth=e.minWidth??this.minWidth,this.minHeight=e.minHeight??this.minHeight,this.backdropClass=e.backdropClass??this.backdropClass,this.panelClass=e.panelClass??this.panelClass,this.viewportMargin=e.viewportMargin??this.viewportMargin,this.scrollStrategy=e.scrollStrategy??this.scrollStrategy,this.disableClose=e.disableClose??this.disableClose,this.transformOriginSelector=e.transformOriginSelector??this.transformOriginSelector,this.hasBackdrop=e.hasBackdrop??this.hasBackdrop,this.lockPosition=e.lockPosition??this.lockPosition,this.flexibleDimensions=e.flexibleDimensions??this.flexibleDimensions,this.growAfterOpen=e.growAfterOpen??this.growAfterOpen,this.push=e.push??this.push,this.disposeOnNavigation=e.disposeOnNavigation??this.disposeOnNavigation,this.usePopover=e.usePopover??this.usePopover,this.matchWidth=e.matchWidth??this.matchWidth}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdk-connected-overlay",""],["","connected-overlay",""],["","cdkConnectedOverlay",""]],inputs:{origin:[0,"cdkConnectedOverlayOrigin","origin"],positions:[0,"cdkConnectedOverlayPositions","positions"],positionStrategy:[0,"cdkConnectedOverlayPositionStrategy","positionStrategy"],offsetX:[0,"cdkConnectedOverlayOffsetX","offsetX"],offsetY:[0,"cdkConnectedOverlayOffsetY","offsetY"],width:[0,"cdkConnectedOverlayWidth","width"],height:[0,"cdkConnectedOverlayHeight","height"],minWidth:[0,"cdkConnectedOverlayMinWidth","minWidth"],minHeight:[0,"cdkConnectedOverlayMinHeight","minHeight"],backdropClass:[0,"cdkConnectedOverlayBackdropClass","backdropClass"],panelClass:[0,"cdkConnectedOverlayPanelClass","panelClass"],viewportMargin:[0,"cdkConnectedOverlayViewportMargin","viewportMargin"],scrollStrategy:[0,"cdkConnectedOverlayScrollStrategy","scrollStrategy"],open:[0,"cdkConnectedOverlayOpen","open"],disableClose:[0,"cdkConnectedOverlayDisableClose","disableClose"],transformOriginSelector:[0,"cdkConnectedOverlayTransformOriginOn","transformOriginSelector"],hasBackdrop:[2,"cdkConnectedOverlayHasBackdrop","hasBackdrop",L],lockPosition:[2,"cdkConnectedOverlayLockPosition","lockPosition",L],flexibleDimensions:[2,"cdkConnectedOverlayFlexibleDimensions","flexibleDimensions",L],growAfterOpen:[2,"cdkConnectedOverlayGrowAfterOpen","growAfterOpen",L],push:[2,"cdkConnectedOverlayPush","push",L],disposeOnNavigation:[2,"cdkConnectedOverlayDisposeOnNavigation","disposeOnNavigation",L],usePopover:[0,"cdkConnectedOverlayUsePopover","usePopover"],matchWidth:[2,"cdkConnectedOverlayMatchWidth","matchWidth",L],_config:[0,"cdkConnectedOverlay","_config"]},outputs:{backdropClick:"backdropClick",positionChange:"positionChange",attach:"attach",detach:"detach",overlayKeydown:"overlayKeydown",overlayOutsideClick:"overlayOutsideClick"},exportAs:["cdkConnectedOverlay"],features:[Se]})}return i})(),Nt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({providers:[$h],imports:[ee,Oi,xa,xa]})}return i})();function $v(i,o){}var bn=class{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;closePredicate;width="";height="";minWidth;minHeight;maxWidth;maxHeight;positionStrategy;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!1;autoFocus="first-tabbable";restoreFocus=!0;scrollStrategy;closeOnNavigation=!0;closeOnDestroy=!0;closeOnOverlayDetachments=!0;disableAnimations=!1;providers;container;templateContext;bindings};var Sc=(()=>{class i extends _n{_elementRef=d(N);_focusTrapFactory=d(Vl);_config;_interactivityChecker=d(Ll);_ngZone=d(H);_focusMonitor=d(Rt);_renderer=d(ve);_changeDetectorRef=d(te);_injector=d(X);_platform=d(le);_document=d($);_portalOutlet;_focusTrapped=new I;_focusTrap=null;_elementFocusedBeforeDialogWasOpened=null;_closeInteractionType=null;_ariaLabelledByQueue=[];_isDestroyed=!1;constructor(){super(),this._config=d(bn,{optional:!0})||new bn,this._config.ariaLabelledBy&&this._ariaLabelledByQueue.push(this._config.ariaLabelledBy)}_addAriaLabelledBy(e){this._ariaLabelledByQueue.push(e),this._changeDetectorRef.markForCheck()}_removeAriaLabelledBy(e){let t=this._ariaLabelledByQueue.indexOf(e);t>-1&&(this._ariaLabelledByQueue.splice(t,1),this._changeDetectorRef.markForCheck())}_contentAttached(){this._initializeFocusTrap(),this._captureInitialFocus()}_captureInitialFocus(){this._trapFocus()}ngOnDestroy(){this._focusTrapped.complete(),this._isDestroyed=!0,this._restoreFocus()}attachComponentPortal(e){this._portalOutlet.hasAttached();let t=this._portalOutlet.attachComponentPortal(e);return this._contentAttached(),t}attachTemplatePortal(e){this._portalOutlet.hasAttached();let t=this._portalOutlet.attachTemplatePortal(e);return this._contentAttached(),t}attachDomPortal=e=>{this._portalOutlet.hasAttached();let t=this._portalOutlet.attachDomPortal(e);return this._contentAttached(),t};_recaptureFocus(){this._containsFocus()||this._trapFocus()}_forceFocus(e,t){this._interactivityChecker.isFocusable(e)||(e.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{let n=()=>{a(),r(),e.removeAttribute("tabindex")},a=this._renderer.listen(e,"blur",n),r=this._renderer.listen(e,"mousedown",n)})),e.focus(t)}_focusByCssSelector(e,t){let n=this._elementRef.nativeElement.querySelector(e);n&&this._forceFocus(n,t)}_trapFocus(e){this._isDestroyed||Be(()=>{let t=this._elementRef.nativeElement;switch(this._config.autoFocus){case!1:case"dialog":this._containsFocus()||t.focus(e);break;case!0:case"first-tabbable":this._focusTrap?.focusInitialElement(e)||this._focusDialogContainer(e);break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]',e);break;default:this._focusByCssSelector(this._config.autoFocus,e);break}this._focusTrapped.next()},{injector:this._injector})}_restoreFocus(){let e=this._config.restoreFocus,t=null;if(typeof e=="string"?t=this._document.querySelector(e):typeof e=="boolean"?t=e?this._elementFocusedBeforeDialogWasOpened:null:e&&(t=e),this._config.restoreFocus&&t&&typeof t.focus=="function"){let n=an(),a=this._elementRef.nativeElement;(!n||n===this._document.body||n===a||a.contains(n))&&(this._focusMonitor?(this._focusMonitor.focusVia(t,this._closeInteractionType),this._closeInteractionType=null):t.focus())}this._focusTrap&&this._focusTrap.destroy()}_focusDialogContainer(e){this._elementRef.nativeElement.focus?.(e)}_containsFocus(){let e=this._elementRef.nativeElement,t=an();return e===t||e.contains(t)}_initializeFocusTrap(){this._platform.isBrowser&&(this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._document&&(this._elementFocusedBeforeDialogWasOpened=an()))}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["cdk-dialog-container"]],viewQuery:function(t,n){if(t&1&&Me(Ri,7),t&2){let a;O(a=P())&&(n._portalOutlet=a.first)}},hostAttrs:["tabindex","-1",1,"cdk-dialog-container"],hostVars:6,hostBindings:function(t,n){t&2&&Z("id",n._config.id||null)("role",n._config.role)("aria-modal",n._config.ariaModal)("aria-labelledby",n._config.ariaLabel?null:n._ariaLabelledByQueue[0])("aria-label",n._config.ariaLabel)("aria-describedby",n._config.ariaDescribedBy||null)},features:[Q],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(t,n){t&1&&ze(0,$v,0,0,"ng-template",0)},dependencies:[Ri],styles:[`.cdk-dialog-container {
3158
+ `],encapsulation:2})}return i})(),gs=(()=>{class i{_platform=d(le);_containerElement;_document=d(W);_styleLoader=d(Ne);ngOnDestroy(){this._containerElement?.remove()}getContainerElement(){return this._loadStyles(),this._containerElement||this._createContainer(),this._containerElement}_createContainer(){let e="cdk-overlay-container";if(this._platform.isBrowser||Ol()){let n=this._document.querySelectorAll(`.${e}[platform="server"], .${e}[platform="test"]`);for(let a=0;a<n.length;a++)n[a].remove()}let t=this._document.createElement("div");t.classList.add(e),Ol()?t.setAttribute("platform","test"):this._platform.isBrowser||t.setAttribute("platform","server"),this._document.body.appendChild(t),this._containerElement=t}_loadStyles(){this._styleLoader.load(Uh)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Dc=class{_renderer;_ngZone;element;_cleanupClick;_cleanupTransitionEnd;_fallbackTimeout;constructor(o,e,t,n){this._renderer=e,this._ngZone=t,this.element=o.createElement("div"),this.element.classList.add("cdk-overlay-backdrop"),this._cleanupClick=e.listen(this.element,"click",n)}detach(){this._ngZone.runOutsideAngular(()=>{let o=this.element;clearTimeout(this._fallbackTimeout),this._cleanupTransitionEnd?.(),this._cleanupTransitionEnd=this._renderer.listen(o,"transitionend",this.dispose),this._fallbackTimeout=setTimeout(this.dispose,500),o.style.pointerEvents="none",o.classList.remove("cdk-overlay-backdrop-showing")})}dispose=()=>{clearTimeout(this._fallbackTimeout),this._cleanupClick?.(),this._cleanupTransitionEnd?.(),this._cleanupClick=this._cleanupTransitionEnd=this._fallbackTimeout=void 0,this.element.remove()}};function kc(i){return i&&i.nodeType===1}var Mo=class{_portalOutlet;_host;_pane;_config;_ngZone;_keyboardDispatcher;_document;_location;_outsideClickDispatcher;_animationsDisabled;_injector;_renderer;_backdropClick=new I;_attachments=new I;_detachments=new I;_positionStrategy;_scrollStrategy;_locationChanges=De.EMPTY;_backdropRef=null;_detachContentMutationObserver;_detachContentAfterRenderRef;_disposed=!1;_previousHostParent;_keydownEvents=new I;_outsidePointerEvents=new I;_afterNextRenderRef;constructor(o,e,t,n,a,r,u,h,g,_=!1,w,B){this._portalOutlet=o,this._host=e,this._pane=t,this._config=n,this._ngZone=a,this._keyboardDispatcher=r,this._document=u,this._location=h,this._outsideClickDispatcher=g,this._animationsDisabled=_,this._injector=w,this._renderer=B,n.scrollStrategy&&(this._scrollStrategy=n.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=n.positionStrategy}get overlayElement(){return this._pane}get backdropElement(){return this._backdropRef?.element||null}get hostElement(){return this._host}get eventPredicate(){return this._config?.eventPredicate||null}attach(o){if(this._disposed)return null;this._attachHost();let e=this._portalOutlet.attach(o);return this._positionStrategy?.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._afterNextRenderRef?.destroy(),this._afterNextRenderRef=Be(()=>{this.hasAttached()&&this.updatePosition()},{injector:this._injector}),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._completeDetachContent(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&(this._locationChanges=this._location.subscribe(()=>this.dispose())),this._outsideClickDispatcher.add(this),typeof e?.onDestroy=="function"&&e.onDestroy(()=>{this.hasAttached()&&this._ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>this.detach()))}),e}detach(){if(!this.hasAttached())return;this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();let o=this._portalOutlet.detach();return this._detachments.next(),this._completeDetachContent(),this._keyboardDispatcher.remove(this),this._detachContentWhenEmpty(),this._locationChanges.unsubscribe(),this._outsideClickDispatcher.remove(this),o}dispose(){if(this._disposed)return;let o=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this._backdropRef?.dispose(),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._outsidePointerEvents.complete(),this._outsideClickDispatcher.remove(this),this._host?.remove(),this._afterNextRenderRef?.destroy(),this._previousHostParent=this._pane=this._host=this._backdropRef=null,o&&this._detachments.next(),this._detachments.complete(),this._completeDetachContent(),this._disposed=!0}hasAttached(){return this._portalOutlet.hasAttached()}backdropClick(){return this._backdropClick}attachments(){return this._attachments}detachments(){return this._detachments}keydownEvents(){return this._keydownEvents}outsidePointerEvents(){return this._outsidePointerEvents}getConfig(){return this._config}updatePosition(){this._positionStrategy&&this._positionStrategy.apply()}updatePositionStrategy(o){o!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=o,this.hasAttached()&&(o.attach(this),this.updatePosition()))}updateSize(o){this._config=V(V({},this._config),o),this._updateElementSize()}setDirection(o){this._config=Oe(V({},this._config),{direction:o}),this._updateElementDirection()}addPanelClass(o){this._pane&&this._toggleClasses(this._pane,o,!0)}removePanelClass(o){this._pane&&this._toggleClasses(this._pane,o,!1)}getDirection(){let o=this._config.direction;return o?typeof o=="string"?o:o.value:"ltr"}updateScrollStrategy(o){o!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=o,this.hasAttached()&&(o.attach(this),o.enable()))}_updateElementDirection(){this._host.setAttribute("dir",this.getDirection())}_updateElementSize(){if(!this._pane)return;let o=this._pane.style;o.width=Ze(this._config.width),o.height=Ze(this._config.height),o.minWidth=Ze(this._config.minWidth),o.minHeight=Ze(this._config.minHeight),o.maxWidth=Ze(this._config.maxWidth),o.maxHeight=Ze(this._config.maxHeight)}_togglePointerEvents(o){this._pane.style.pointerEvents=o?"":"none"}_attachHost(){if(!this._host.parentElement){let o=this._config.usePopover?this._positionStrategy?.getPopoverInsertionPoint?.():null;kc(o)?o.after(this._host):o?.type==="parent"?o.element.appendChild(this._host):this._previousHostParent?.appendChild(this._host)}if(this._config.usePopover)try{this._host.showPopover()}catch(o){}}_attachBackdrop(){let o="cdk-overlay-backdrop-showing";this._backdropRef?.dispose(),this._backdropRef=new Dc(this._document,this._renderer,this._ngZone,e=>{this._backdropClick.next(e)}),this._animationsDisabled&&this._backdropRef.element.classList.add("cdk-overlay-backdrop-noop-animation"),this._config.backdropClass&&this._toggleClasses(this._backdropRef.element,this._config.backdropClass,!0),this._config.usePopover?this._host.prepend(this._backdropRef.element):this._host.parentElement.insertBefore(this._backdropRef.element,this._host),!this._animationsDisabled&&typeof requestAnimationFrame<"u"?this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>this._backdropRef?.element.classList.add(o))}):this._backdropRef.element.classList.add(o)}_updateStackingOrder(){!this._config.usePopover&&this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}detachBackdrop(){this._animationsDisabled?(this._backdropRef?.dispose(),this._backdropRef=null):this._backdropRef?.detach()}_toggleClasses(o,e,t){let n=Vi(e||[]).filter(a=>!!a);n.length&&(t?o.classList.add(...n):o.classList.remove(...n))}_detachContentWhenEmpty(){let o=!1;try{this._detachContentAfterRenderRef=Be(()=>{o=!0,this._detachContent()},{injector:this._injector})}catch(e){if(o)throw e;this._detachContent()}globalThis.MutationObserver&&this._pane&&(this._detachContentMutationObserver||=new globalThis.MutationObserver(()=>{this._detachContent()}),this._detachContentMutationObserver.observe(this._pane,{childList:!0}))}_detachContent(){(!this._pane||!this._host||this._pane.children.length===0)&&(this._pane&&this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!1),this._host&&this._host.parentElement&&(this._previousHostParent=this._host.parentElement,this._host.remove()),this._completeDetachContent())}_completeDetachContent(){this._detachContentAfterRenderRef?.destroy(),this._detachContentAfterRenderRef=void 0,this._detachContentMutationObserver?.disconnect()}_disposeScrollStrategy(){let o=this._scrollStrategy;o?.disable(),o?.detach?.()}},Ph="cdk-overlay-connected-position-bounding-box",jv=/([A-Za-z%]+)$/;function $i(i,o){return new ps(o,i.get(Gt),i.get(W),i.get(le),i.get(gs))}var ps=class{_viewportRuler;_document;_platform;_overlayContainer;_overlayRef;_isInitialRender=!1;_lastBoundingBoxSize={width:0,height:0};_isPushed=!1;_canPush=!0;_growAfterOpen=!1;_hasFlexibleDimensions=!0;_positionLocked=!1;_originRect;_overlayRect;_viewportRect;_containerRect;_viewportMargin=0;_scrollables=[];_preferredPositions=[];_origin;_pane;_isDisposed=!1;_boundingBox=null;_lastPosition=null;_lastScrollVisibility=null;_positionChanges=new I;_resizeSubscription=De.EMPTY;_offsetX=0;_offsetY=0;_transformOriginSelector;_appliedPanelClasses=[];_previousPushAmount=null;_popoverLocation="global";positionChanges=this._positionChanges;get positions(){return this._preferredPositions}constructor(o,e,t,n,a){this._viewportRuler=e,this._document=t,this._platform=n,this._overlayContainer=a,this.setOrigin(o)}attach(o){this._overlayRef&&this._overlayRef,this._validatePositions(),o.hostElement.classList.add(Ph),this._overlayRef=o,this._boundingBox=o.hostElement,this._pane=o.overlayElement,this._isDisposed=!1,this._isInitialRender=!0,this._lastPosition=null,this._resizeSubscription.unsubscribe(),this._resizeSubscription=this._viewportRuler.change().subscribe(()=>{this._isInitialRender=!0,this.apply()})}apply(){if(this._isDisposed||!this._platform.isBrowser)return;if(!this._isInitialRender&&this._positionLocked&&this._lastPosition){this.reapplyLastPosition();return}this._clearPanelClasses(),this._resetOverlayElementStyles(),this._resetBoundingBoxStyles(),this._viewportRect=this._getNarrowedViewportRect(),this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._containerRect=this._getContainerRect();let o=this._originRect,e=this._overlayRect,t=this._viewportRect,n=this._containerRect,a=[],r;for(let u of this._preferredPositions){let h=this._getOriginPoint(o,n,u),g=this._getOverlayPoint(h,e,u),_=this._getOverlayFit(g,e,t,u);if(_.isCompletelyWithinViewport){this._isPushed=!1,this._applyPosition(u,h);return}if(this._canFitWithFlexibleDimensions(_,g,t)){a.push({position:u,origin:h,overlayRect:e,boundingBoxRect:this._calculateBoundingBoxRect(h,u)});continue}(!r||r.overlayFit.visibleArea<_.visibleArea)&&(r={overlayFit:_,overlayPoint:g,originPoint:h,position:u,overlayRect:e})}if(a.length){let u=null,h=-1;for(let g of a){let _=g.boundingBoxRect.width*g.boundingBoxRect.height*(g.position.weight||1);_>h&&(h=_,u=g)}this._isPushed=!1,this._applyPosition(u.position,u.origin);return}if(this._canPush){this._isPushed=!0,this._applyPosition(r.position,r.originPoint);return}this._applyPosition(r.position,r.originPoint)}detach(){this._clearPanelClasses(),this._lastPosition=null,this._previousPushAmount=null,this._resizeSubscription.unsubscribe()}dispose(){this._isDisposed||(this._boundingBox&&$n(this._boundingBox.style,{top:"",left:"",right:"",bottom:"",height:"",width:"",alignItems:"",justifyContent:""}),this._pane&&this._resetOverlayElementStyles(),this._overlayRef&&this._overlayRef.hostElement.classList.remove(Ph),this.detach(),this._positionChanges.complete(),this._overlayRef=this._boundingBox=null,this._isDisposed=!0)}reapplyLastPosition(){if(this._isDisposed||!this._platform.isBrowser)return;let o=this._lastPosition;o?(this._originRect=this._getOriginRect(),this._overlayRect=this._pane.getBoundingClientRect(),this._viewportRect=this._getNarrowedViewportRect(),this._containerRect=this._getContainerRect(),this._applyPosition(o,this._getOriginPoint(this._originRect,this._containerRect,o))):this.apply()}withScrollableContainers(o){return this._scrollables=o,this}withPositions(o){return this._preferredPositions=o,o.indexOf(this._lastPosition)===-1&&(this._lastPosition=null),this._validatePositions(),this}withViewportMargin(o){return this._viewportMargin=o,this}withFlexibleDimensions(o=!0){return this._hasFlexibleDimensions=o,this}withGrowAfterOpen(o=!0){return this._growAfterOpen=o,this}withPush(o=!0){return this._canPush=o,this}withLockedPosition(o=!0){return this._positionLocked=o,this}setOrigin(o){return this._origin=o,this}withDefaultOffsetX(o){return this._offsetX=o,this}withDefaultOffsetY(o){return this._offsetY=o,this}withTransformOriginOn(o){return this._transformOriginSelector=o,this}withPopoverLocation(o){return this._popoverLocation=o,this}getPopoverInsertionPoint(){return this._popoverLocation==="global"?null:this._popoverLocation!=="inline"?this._popoverLocation:this._origin instanceof N?this._origin.nativeElement:kc(this._origin)?this._origin:null}_getOriginPoint(o,e,t){let n;if(t.originX=="center")n=o.left+o.width/2;else{let r=this._isRtl()?o.right:o.left,u=this._isRtl()?o.left:o.right;n=t.originX=="start"?r:u}e.left<0&&(n-=e.left);let a;return t.originY=="center"?a=o.top+o.height/2:a=t.originY=="top"?o.top:o.bottom,e.top<0&&(a-=e.top),{x:n,y:a}}_getOverlayPoint(o,e,t){let n;t.overlayX=="center"?n=-e.width/2:t.overlayX==="start"?n=this._isRtl()?-e.width:0:n=this._isRtl()?0:-e.width;let a;return t.overlayY=="center"?a=-e.height/2:a=t.overlayY=="top"?0:-e.height,{x:o.x+n,y:o.y+a}}_getOverlayFit(o,e,t,n){let a=Nh(e),{x:r,y:u}=o,h=this._getOffset(n,"x"),g=this._getOffset(n,"y");h&&(r+=h),g&&(u+=g);let _=0-r,w=r+a.width-t.width,B=0-u,G=u+a.height-t.height,ie=this._subtractOverflows(a.width,_,w),fe=this._subtractOverflows(a.height,B,G),se=ie*fe;return{visibleArea:se,isCompletelyWithinViewport:a.width*a.height===se,fitsInViewportVertically:fe===a.height,fitsInViewportHorizontally:ie==a.width}}_canFitWithFlexibleDimensions(o,e,t){if(this._hasFlexibleDimensions){let n=t.bottom-e.y,a=t.right-e.x,r=Fh(this._overlayRef.getConfig().minHeight),u=Fh(this._overlayRef.getConfig().minWidth),h=o.fitsInViewportVertically||r!=null&&r<=n,g=o.fitsInViewportHorizontally||u!=null&&u<=a;return h&&g}return!1}_pushOverlayOnScreen(o,e,t){if(this._previousPushAmount&&this._positionLocked)return{x:o.x+this._previousPushAmount.x,y:o.y+this._previousPushAmount.y};let n=Nh(e),a=this._viewportRect,r=Math.max(o.x+n.width-a.width,0),u=Math.max(o.y+n.height-a.height,0),h=Math.max(a.top-t.top-o.y,0),g=Math.max(a.left-t.left-o.x,0),_=0,w=0;return n.width<=a.width?_=g||-r:_=o.x<this._getViewportMarginStart()?a.left-t.left-o.x:0,n.height<=a.height?w=h||-u:w=o.y<this._getViewportMarginTop()?a.top-t.top-o.y:0,this._previousPushAmount={x:_,y:w},{x:o.x+_,y:o.y+w}}_applyPosition(o,e){if(this._setTransformOrigin(o),this._setOverlayElementStyles(e,o),this._setBoundingBoxStyles(e,o),o.panelClass&&this._addPanelClasses(o.panelClass),this._positionChanges.observers.length){let t=this._getScrollVisibility();if(o!==this._lastPosition||!this._lastScrollVisibility||!Hv(this._lastScrollVisibility,t)){let n=new hs(o,t);this._positionChanges.next(n)}this._lastScrollVisibility=t}this._lastPosition=o,this._isInitialRender=!1}_setTransformOrigin(o){if(!this._transformOriginSelector)return;let e=this._boundingBox.querySelectorAll(this._transformOriginSelector),t,n=o.overlayY;o.overlayX==="center"?t="center":this._isRtl()?t=o.overlayX==="start"?"right":"left":t=o.overlayX==="start"?"left":"right";for(let a=0;a<e.length;a++)e[a].style.transformOrigin=`${t} ${n}`}_calculateBoundingBoxRect(o,e){let t=this._viewportRect,n=this._isRtl(),a,r,u;if(e.overlayY==="top")r=o.y,a=t.height-r+this._getViewportMarginBottom();else if(e.overlayY==="bottom")u=t.height-o.y+this._getViewportMarginTop()+this._getViewportMarginBottom(),a=t.height-u+this._getViewportMarginTop();else{let G=Math.min(t.bottom-o.y+t.top,o.y),ie=this._lastBoundingBoxSize.height;a=G*2,r=o.y-G,a>ie&&!this._isInitialRender&&!this._growAfterOpen&&(r=o.y-ie/2)}let h=e.overlayX==="start"&&!n||e.overlayX==="end"&&n,g=e.overlayX==="end"&&!n||e.overlayX==="start"&&n,_,w,B;if(g)B=t.width-o.x+this._getViewportMarginStart()+this._getViewportMarginEnd(),_=o.x-this._getViewportMarginStart();else if(h)w=o.x,_=t.right-o.x-this._getViewportMarginEnd();else{let G=Math.min(t.right-o.x+t.left,o.x),ie=this._lastBoundingBoxSize.width;_=G*2,w=o.x-G,_>ie&&!this._isInitialRender&&!this._growAfterOpen&&(w=o.x-ie/2)}return{top:r,left:w,bottom:u,right:B,width:_,height:a}}_setBoundingBoxStyles(o,e){let t=this._calculateBoundingBoxRect(o,e);!this._isInitialRender&&!this._growAfterOpen&&(t.height=Math.min(t.height,this._lastBoundingBoxSize.height),t.width=Math.min(t.width,this._lastBoundingBoxSize.width));let n={};if(this._hasExactPosition())n.top=n.left="0",n.bottom=n.right="auto",n.maxHeight=n.maxWidth="",n.width=n.height="100%";else{let a=this._overlayRef.getConfig().maxHeight,r=this._overlayRef.getConfig().maxWidth;n.width=Ze(t.width),n.height=Ze(t.height),n.top=Ze(t.top)||"auto",n.bottom=Ze(t.bottom)||"auto",n.left=Ze(t.left)||"auto",n.right=Ze(t.right)||"auto",e.overlayX==="center"?n.alignItems="center":n.alignItems=e.overlayX==="end"?"flex-end":"flex-start",e.overlayY==="center"?n.justifyContent="center":n.justifyContent=e.overlayY==="bottom"?"flex-end":"flex-start",a&&(n.maxHeight=Ze(a)),r&&(n.maxWidth=Ze(r))}this._lastBoundingBoxSize=t,$n(this._boundingBox.style,n)}_resetBoundingBoxStyles(){$n(this._boundingBox.style,{top:"0",left:"0",right:"0",bottom:"0",height:"",width:"",alignItems:"",justifyContent:""})}_resetOverlayElementStyles(){$n(this._pane.style,{top:"",left:"",bottom:"",right:"",position:"",transform:""})}_setOverlayElementStyles(o,e){let t={},n=this._hasExactPosition(),a=this._hasFlexibleDimensions,r=this._overlayRef.getConfig();if(n){let _=this._viewportRuler.getViewportScrollPosition();$n(t,this._getExactOverlayY(e,o,_)),$n(t,this._getExactOverlayX(e,o,_))}else t.position="static";let u="",h=this._getOffset(e,"x"),g=this._getOffset(e,"y");h&&(u+=`translateX(${h}px) `),g&&(u+=`translateY(${g}px)`),t.transform=u.trim(),r.maxHeight&&(n?t.maxHeight=Ze(r.maxHeight):a&&(t.maxHeight="")),r.maxWidth&&(n?t.maxWidth=Ze(r.maxWidth):a&&(t.maxWidth="")),$n(this._pane.style,t)}_getExactOverlayY(o,e,t){let n={top:"",bottom:""},a=this._getOverlayPoint(e,this._overlayRect,o);if(this._isPushed&&(a=this._pushOverlayOnScreen(a,this._overlayRect,t)),o.overlayY==="bottom"){let r=this._document.documentElement.clientHeight;n.bottom=`${r-(a.y+this._overlayRect.height)}px`}else n.top=Ze(a.y);return n}_getExactOverlayX(o,e,t){let n={left:"",right:""},a=this._getOverlayPoint(e,this._overlayRect,o);this._isPushed&&(a=this._pushOverlayOnScreen(a,this._overlayRect,t));let r;if(this._isRtl()?r=o.overlayX==="end"?"left":"right":r=o.overlayX==="end"?"right":"left",r==="right"){let u=this._document.documentElement.clientWidth;n.right=`${u-(a.x+this._overlayRect.width)}px`}else n.left=Ze(a.x);return n}_getScrollVisibility(){let o=this._getOriginRect(),e=this._pane.getBoundingClientRect(),t=this._scrollables.map(n=>n.getElementRef().nativeElement.getBoundingClientRect());return{isOriginClipped:Rh(o,t),isOriginOutsideView:wc(o,t),isOverlayClipped:Rh(e,t),isOverlayOutsideView:wc(e,t)}}_subtractOverflows(o,...e){return e.reduce((t,n)=>t-Math.max(n,0),o)}_getNarrowedViewportRect(){let o=this._document.documentElement.clientWidth,e=this._document.documentElement.clientHeight,t=this._viewportRuler.getViewportScrollPosition();return{top:t.top+this._getViewportMarginTop(),left:t.left+this._getViewportMarginStart(),right:t.left+o-this._getViewportMarginEnd(),bottom:t.top+e-this._getViewportMarginBottom(),width:o-this._getViewportMarginStart()-this._getViewportMarginEnd(),height:e-this._getViewportMarginTop()-this._getViewportMarginBottom()}}_isRtl(){return this._overlayRef.getDirection()==="rtl"}_hasExactPosition(){return!this._hasFlexibleDimensions||this._isPushed}_getOffset(o,e){return e==="x"?o.offsetX==null?this._offsetX:o.offsetX:o.offsetY==null?this._offsetY:o.offsetY}_validatePositions(){}_addPanelClasses(o){this._pane&&Vi(o).forEach(e=>{e!==""&&this._appliedPanelClasses.indexOf(e)===-1&&(this._appliedPanelClasses.push(e),this._pane.classList.add(e))})}_clearPanelClasses(){this._pane&&(this._appliedPanelClasses.forEach(o=>{this._pane.classList.remove(o)}),this._appliedPanelClasses=[])}_getViewportMarginStart(){return typeof this._viewportMargin=="number"?this._viewportMargin:this._viewportMargin?.start??0}_getViewportMarginEnd(){return typeof this._viewportMargin=="number"?this._viewportMargin:this._viewportMargin?.end??0}_getViewportMarginTop(){return typeof this._viewportMargin=="number"?this._viewportMargin:this._viewportMargin?.top??0}_getViewportMarginBottom(){return typeof this._viewportMargin=="number"?this._viewportMargin:this._viewportMargin?.bottom??0}_getOriginRect(){let o=this._origin;if(o instanceof N)return o.nativeElement.getBoundingClientRect();if(o instanceof Element)return o.getBoundingClientRect();let e=o.width||0,t=o.height||0;return{top:o.y,bottom:o.y+t,left:o.x,right:o.x+e,height:t,width:e}}_getContainerRect(){let o=this._overlayRef.getConfig().usePopover&&this._popoverLocation!=="global",e=this._overlayContainer.getContainerElement();o&&(e.style.display="block");let t=e.getBoundingClientRect();return o&&(e.style.display=""),t}};function $n(i,o){for(let e in o)o.hasOwnProperty(e)&&(i[e]=o[e]);return i}function Fh(i){if(typeof i!="number"&&i!=null){let[o,e]=i.split(jv);return!e||e==="px"?parseFloat(o):null}return i||null}function Nh(i){return{top:Math.floor(i.top),right:Math.floor(i.right),bottom:Math.floor(i.bottom),left:Math.floor(i.left),width:Math.floor(i.width),height:Math.floor(i.height)}}function Hv(i,o){return i===o?!0:i.isOriginClipped===o.isOriginClipped&&i.isOriginOutsideView===o.isOriginOutsideView&&i.isOverlayClipped===o.isOverlayClipped&&i.isOverlayOutsideView===o.isOverlayOutsideView}var Lh="cdk-global-overlay-wrapper";function vn(i){return new fs}var fs=class{_overlayRef;_cssPosition="static";_topOffset="";_bottomOffset="";_alignItems="";_xPosition="";_xOffset="";_width="";_height="";_isDisposed=!1;attach(o){let e=o.getConfig();this._overlayRef=o,this._width&&!e.width&&o.updateSize({width:this._width}),this._height&&!e.height&&o.updateSize({height:this._height}),o.hostElement.classList.add(Lh),this._isDisposed=!1}top(o=""){return this._bottomOffset="",this._topOffset=o,this._alignItems="flex-start",this}left(o=""){return this._xOffset=o,this._xPosition="left",this}bottom(o=""){return this._topOffset="",this._bottomOffset=o,this._alignItems="flex-end",this}right(o=""){return this._xOffset=o,this._xPosition="right",this}start(o=""){return this._xOffset=o,this._xPosition="start",this}end(o=""){return this._xOffset=o,this._xPosition="end",this}width(o=""){return this._overlayRef?this._overlayRef.updateSize({width:o}):this._width=o,this}height(o=""){return this._overlayRef?this._overlayRef.updateSize({height:o}):this._height=o,this}centerHorizontally(o=""){return this.left(o),this._xPosition="center",this}centerVertically(o=""){return this.top(o),this._alignItems="center",this}apply(){if(!this._overlayRef||!this._overlayRef.hasAttached())return;let o=this._overlayRef.overlayElement.style,e=this._overlayRef.hostElement.style,t=this._overlayRef.getConfig(),{width:n,height:a,maxWidth:r,maxHeight:u}=t,h=(n==="100%"||n==="100vw")&&(!r||r==="100%"||r==="100vw"),g=(a==="100%"||a==="100vh")&&(!u||u==="100%"||u==="100vh"),_=this._xPosition,w=this._xOffset,B=this._overlayRef.getConfig().direction==="rtl",G="",ie="",fe="";h?fe="flex-start":_==="center"?(fe="center",B?ie=w:G=w):B?_==="left"||_==="end"?(fe="flex-end",G=w):(_==="right"||_==="start")&&(fe="flex-start",ie=w):_==="left"||_==="start"?(fe="flex-start",G=w):(_==="right"||_==="end")&&(fe="flex-end",ie=w),o.position=this._cssPosition,o.marginLeft=h?"0":G,o.marginTop=g?"0":this._topOffset,o.marginBottom=this._bottomOffset,o.marginRight=h?"0":ie,e.justifyContent=fe,e.alignItems=g?"flex-start":this._alignItems}dispose(){if(this._isDisposed||!this._overlayRef)return;let o=this._overlayRef.overlayElement.style,e=this._overlayRef.hostElement,t=e.style;e.classList.remove(Lh),t.justifyContent=t.alignItems=o.marginTop=o.marginBottom=o.marginLeft=o.marginRight=o.position="",this._overlayRef=null,this._isDisposed=!0}},Gh=(()=>{class i{_injector=d(X);global(){return vn()}flexibleConnectedTo(e){return $i(this._injector,e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Pa=new x("OVERLAY_DEFAULT_CONFIG");function qt(i,o){i.get(Ne).load(Uh);let e=i.get(gs),t=i.get(W),n=i.get(be),a=i.get(Qi),r=i.get(qe),u=i.get(ve,null,{optional:!0})||i.get(ot).createRenderer(null,null),h=new Wt(o),g=i.get(Pa,null,{optional:!0})?.usePopover??!0;h.direction=h.direction||r.value,"showPopover"in t.body?h.usePopover=o?.usePopover??g:h.usePopover=!1;let _=t.createElement("div"),w=t.createElement("div");_.id=n.getId("cdk-overlay-"),_.classList.add("cdk-overlay-pane"),w.appendChild(_),h.usePopover&&(w.setAttribute("popover","manual"),w.classList.add("cdk-overlay-popover"));let B=h.usePopover?h.positionStrategy?.getPopoverInsertionPoint?.():null;return kc(B)?B.after(w):B?.type==="parent"?B.element.appendChild(w):e.getContainerElement().appendChild(w),new Mo(new Ra(_,a,i),w,_,h,i.get(H),i.get(jh),t,i.get(lr),i.get(Hh),o?.disableAnimations??i.get(Pi,null,{optional:!0})==="NoopAnimations",i.get(mi),u)}var $h=(()=>{class i{scrollStrategies=d(Bh);_positionBuilder=d(Gh);_injector=d(X);create(e){return qt(this._injector,e)}position(){return this._positionBuilder}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})(),Uv=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],Gv=new x("cdk-connected-overlay-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>yi(i)}}),Eo=(()=>{class i{elementRef=d(N);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdk-overlay-origin",""],["","overlay-origin",""],["","cdkOverlayOrigin",""]],exportAs:["cdkOverlayOrigin"]})}return i})(),Wh=new x("cdk-connected-overlay-default-config"),_s=(()=>{class i{_dir=d(qe,{optional:!0});_injector=d(X);_overlayRef;_templatePortal;_backdropSubscription=De.EMPTY;_attachSubscription=De.EMPTY;_detachSubscription=De.EMPTY;_positionSubscription=De.EMPTY;_offsetX;_offsetY;_position;_scrollStrategyFactory=d(Gv);_ngZone=d(H);origin;positions;positionStrategy;get offsetX(){return this._offsetX}set offsetX(e){this._offsetX=e,this._position&&this._updatePositionStrategy(this._position)}get offsetY(){return this._offsetY}set offsetY(e){this._offsetY=e,this._position&&this._updatePositionStrategy(this._position)}width;height;minWidth;minHeight;backdropClass;panelClass;viewportMargin=0;scrollStrategy;open=!1;disableClose=!1;transformOriginSelector;hasBackdrop=!1;lockPosition=!1;flexibleDimensions=!1;growAfterOpen=!1;push=!1;disposeOnNavigation=!1;usePopover;matchWidth=!1;set _config(e){typeof e!="string"&&this._assignConfig(e)}backdropClick=new K;positionChange=new K;attach=new K;detach=new K;overlayKeydown=new K;overlayOutsideClick=new K;constructor(){let e=d(Ye),t=d(Xe),n=d(Wh,{optional:!0}),a=d(Pa,{optional:!0});this.usePopover=a?.usePopover===!1?null:"global",this._templatePortal=new Et(e,t),this.scrollStrategy=this._scrollStrategyFactory(),n&&this._assignConfig(n)}get overlayRef(){return this._overlayRef}get dir(){return this._dir?this._dir.value:"ltr"}ngOnDestroy(){this._attachSubscription.unsubscribe(),this._detachSubscription.unsubscribe(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this._overlayRef?.dispose()}ngOnChanges(e){this._position&&(this._updatePositionStrategy(this._position),this._overlayRef?.updateSize({width:this._getWidth(),minWidth:this.minWidth,height:this.height,minHeight:this.minHeight}),e.origin&&this.open&&this._position.apply()),e.open&&(this.open?this.attachOverlay():this.detachOverlay())}_createOverlay(){(!this.positions||!this.positions.length)&&(this.positions=Uv);let e=this._overlayRef=qt(this._injector,this._buildConfig());this._attachSubscription=e.attachments().subscribe(()=>this.attach.emit()),this._detachSubscription=e.detachments().subscribe(()=>this.detach.emit()),e.keydownEvents().subscribe(t=>{this.overlayKeydown.next(t),t.keyCode===27&&!this.disableClose&&!Ge(t)&&(t.preventDefault(),this.detachOverlay())}),this._overlayRef.outsidePointerEvents().subscribe(t=>{let n=this._getOriginElement(),a=rt(t);(!n||n!==a&&!n.contains(a))&&this.overlayOutsideClick.next(t)})}_buildConfig(){let e=this._position=this.positionStrategy||this._createPositionStrategy(),t=new Wt({direction:this._dir||"ltr",positionStrategy:e,scrollStrategy:this.scrollStrategy,hasBackdrop:this.hasBackdrop,disposeOnNavigation:this.disposeOnNavigation,usePopover:!!this.usePopover});return(this.height||this.height===0)&&(t.height=this.height),(this.minWidth||this.minWidth===0)&&(t.minWidth=this.minWidth),(this.minHeight||this.minHeight===0)&&(t.minHeight=this.minHeight),this.backdropClass&&(t.backdropClass=this.backdropClass),this.panelClass&&(t.panelClass=this.panelClass),t}_updatePositionStrategy(e){let t=this.positions.map(n=>({originX:n.originX,originY:n.originY,overlayX:n.overlayX,overlayY:n.overlayY,offsetX:n.offsetX||this.offsetX,offsetY:n.offsetY||this.offsetY,panelClass:n.panelClass||void 0}));return e.setOrigin(this._getOrigin()).withPositions(t).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector).withPopoverLocation(this.usePopover===null?"global":this.usePopover)}_createPositionStrategy(){let e=$i(this._injector,this._getOrigin());return this._updatePositionStrategy(e),e}_getOrigin(){return this.origin instanceof Eo?this.origin.elementRef:this.origin}_getOriginElement(){return this.origin instanceof Eo?this.origin.elementRef.nativeElement:this.origin instanceof N?this.origin.nativeElement:typeof Element<"u"&&this.origin instanceof Element?this.origin:null}_getWidth(){return this.width?this.width:this.matchWidth?this._getOriginElement()?.getBoundingClientRect?.().width:void 0}attachOverlay(){this._overlayRef||this._createOverlay();let e=this._overlayRef;e.getConfig().hasBackdrop=this.hasBackdrop,e.updateSize({width:this._getWidth()}),e.hasAttached()||e.attach(this._templatePortal),this.hasBackdrop?this._backdropSubscription=e.backdropClick().subscribe(t=>this.backdropClick.emit(t)):this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.positionChange.observers.length>0&&(this._positionSubscription=this._position.positionChanges.pipe(Xc(()=>this.positionChange.observers.length>0)).subscribe(t=>{this._ngZone.run(()=>this.positionChange.emit(t)),this.positionChange.observers.length===0&&this._positionSubscription.unsubscribe()})),this.open=!0}detachOverlay(){this._overlayRef?.detach(),this._backdropSubscription.unsubscribe(),this._positionSubscription.unsubscribe(),this.open=!1}_assignConfig(e){this.origin=e.origin??this.origin,this.positions=e.positions??this.positions,this.positionStrategy=e.positionStrategy??this.positionStrategy,this.offsetX=e.offsetX??this.offsetX,this.offsetY=e.offsetY??this.offsetY,this.width=e.width??this.width,this.height=e.height??this.height,this.minWidth=e.minWidth??this.minWidth,this.minHeight=e.minHeight??this.minHeight,this.backdropClass=e.backdropClass??this.backdropClass,this.panelClass=e.panelClass??this.panelClass,this.viewportMargin=e.viewportMargin??this.viewportMargin,this.scrollStrategy=e.scrollStrategy??this.scrollStrategy,this.disableClose=e.disableClose??this.disableClose,this.transformOriginSelector=e.transformOriginSelector??this.transformOriginSelector,this.hasBackdrop=e.hasBackdrop??this.hasBackdrop,this.lockPosition=e.lockPosition??this.lockPosition,this.flexibleDimensions=e.flexibleDimensions??this.flexibleDimensions,this.growAfterOpen=e.growAfterOpen??this.growAfterOpen,this.push=e.push??this.push,this.disposeOnNavigation=e.disposeOnNavigation??this.disposeOnNavigation,this.usePopover=e.usePopover??this.usePopover,this.matchWidth=e.matchWidth??this.matchWidth}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","cdk-connected-overlay",""],["","connected-overlay",""],["","cdkConnectedOverlay",""]],inputs:{origin:[0,"cdkConnectedOverlayOrigin","origin"],positions:[0,"cdkConnectedOverlayPositions","positions"],positionStrategy:[0,"cdkConnectedOverlayPositionStrategy","positionStrategy"],offsetX:[0,"cdkConnectedOverlayOffsetX","offsetX"],offsetY:[0,"cdkConnectedOverlayOffsetY","offsetY"],width:[0,"cdkConnectedOverlayWidth","width"],height:[0,"cdkConnectedOverlayHeight","height"],minWidth:[0,"cdkConnectedOverlayMinWidth","minWidth"],minHeight:[0,"cdkConnectedOverlayMinHeight","minHeight"],backdropClass:[0,"cdkConnectedOverlayBackdropClass","backdropClass"],panelClass:[0,"cdkConnectedOverlayPanelClass","panelClass"],viewportMargin:[0,"cdkConnectedOverlayViewportMargin","viewportMargin"],scrollStrategy:[0,"cdkConnectedOverlayScrollStrategy","scrollStrategy"],open:[0,"cdkConnectedOverlayOpen","open"],disableClose:[0,"cdkConnectedOverlayDisableClose","disableClose"],transformOriginSelector:[0,"cdkConnectedOverlayTransformOriginOn","transformOriginSelector"],hasBackdrop:[2,"cdkConnectedOverlayHasBackdrop","hasBackdrop",L],lockPosition:[2,"cdkConnectedOverlayLockPosition","lockPosition",L],flexibleDimensions:[2,"cdkConnectedOverlayFlexibleDimensions","flexibleDimensions",L],growAfterOpen:[2,"cdkConnectedOverlayGrowAfterOpen","growAfterOpen",L],push:[2,"cdkConnectedOverlayPush","push",L],disposeOnNavigation:[2,"cdkConnectedOverlayDisposeOnNavigation","disposeOnNavigation",L],usePopover:[0,"cdkConnectedOverlayUsePopover","usePopover"],matchWidth:[2,"cdkConnectedOverlayMatchWidth","matchWidth",L],_config:[0,"cdkConnectedOverlay","_config"]},outputs:{backdropClick:"backdropClick",positionChange:"positionChange",attach:"attach",detach:"detach",overlayKeydown:"overlayKeydown",overlayOutsideClick:"overlayOutsideClick"},exportAs:["cdkConnectedOverlay"],features:[Se]})}return i})(),Nt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({providers:[$h],imports:[ee,Oi,Da,Da]})}return i})();function $v(i,o){}var bn=class{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;closePredicate;width="";height="";minWidth;minHeight;maxWidth;maxHeight;positionStrategy;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!1;autoFocus="first-tabbable";restoreFocus=!0;scrollStrategy;closeOnNavigation=!0;closeOnDestroy=!0;closeOnOverlayDetachments=!0;disableAnimations=!1;providers;container;templateContext;bindings};var Mc=(()=>{class i extends _n{_elementRef=d(N);_focusTrapFactory=d(Bl);_config;_interactivityChecker=d(Vl);_ngZone=d(H);_focusMonitor=d(Rt);_renderer=d(ve);_changeDetectorRef=d(te);_injector=d(X);_platform=d(le);_document=d(W);_portalOutlet;_focusTrapped=new I;_focusTrap=null;_elementFocusedBeforeDialogWasOpened=null;_closeInteractionType=null;_ariaLabelledByQueue=[];_isDestroyed=!1;constructor(){super(),this._config=d(bn,{optional:!0})||new bn,this._config.ariaLabelledBy&&this._ariaLabelledByQueue.push(this._config.ariaLabelledBy)}_addAriaLabelledBy(e){this._ariaLabelledByQueue.push(e),this._changeDetectorRef.markForCheck()}_removeAriaLabelledBy(e){let t=this._ariaLabelledByQueue.indexOf(e);t>-1&&(this._ariaLabelledByQueue.splice(t,1),this._changeDetectorRef.markForCheck())}_contentAttached(){this._initializeFocusTrap(),this._captureInitialFocus()}_captureInitialFocus(){this._trapFocus()}ngOnDestroy(){this._focusTrapped.complete(),this._isDestroyed=!0,this._restoreFocus()}attachComponentPortal(e){this._portalOutlet.hasAttached();let t=this._portalOutlet.attachComponentPortal(e);return this._contentAttached(),t}attachTemplatePortal(e){this._portalOutlet.hasAttached();let t=this._portalOutlet.attachTemplatePortal(e);return this._contentAttached(),t}attachDomPortal=e=>{this._portalOutlet.hasAttached();let t=this._portalOutlet.attachDomPortal(e);return this._contentAttached(),t};_recaptureFocus(){this._containsFocus()||this._trapFocus()}_forceFocus(e,t){this._interactivityChecker.isFocusable(e)||(e.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{let n=()=>{a(),r(),e.removeAttribute("tabindex")},a=this._renderer.listen(e,"blur",n),r=this._renderer.listen(e,"mousedown",n)})),e.focus(t)}_focusByCssSelector(e,t){let n=this._elementRef.nativeElement.querySelector(e);n&&this._forceFocus(n,t)}_trapFocus(e){this._isDestroyed||Be(()=>{let t=this._elementRef.nativeElement;switch(this._config.autoFocus){case!1:case"dialog":this._containsFocus()||t.focus(e);break;case!0:case"first-tabbable":this._focusTrap?.focusInitialElement(e)||this._focusDialogContainer(e);break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]',e);break;default:this._focusByCssSelector(this._config.autoFocus,e);break}this._focusTrapped.next()},{injector:this._injector})}_restoreFocus(){let e=this._config.restoreFocus,t=null;if(typeof e=="string"?t=this._document.querySelector(e):typeof e=="boolean"?t=e?this._elementFocusedBeforeDialogWasOpened:null:e&&(t=e),this._config.restoreFocus&&t&&typeof t.focus=="function"){let n=an(),a=this._elementRef.nativeElement;(!n||n===this._document.body||n===a||a.contains(n))&&(this._focusMonitor?(this._focusMonitor.focusVia(t,this._closeInteractionType),this._closeInteractionType=null):t.focus())}this._focusTrap&&this._focusTrap.destroy()}_focusDialogContainer(e){this._elementRef.nativeElement.focus?.(e)}_containsFocus(){let e=this._elementRef.nativeElement,t=an();return e===t||e.contains(t)}_initializeFocusTrap(){this._platform.isBrowser&&(this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._document&&(this._elementFocusedBeforeDialogWasOpened=an()))}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["cdk-dialog-container"]],viewQuery:function(t,n){if(t&1&&Me(Ri,7),t&2){let a;O(a=P())&&(n._portalOutlet=a.first)}},hostAttrs:["tabindex","-1",1,"cdk-dialog-container"],hostVars:6,hostBindings:function(t,n){t&2&&Z("id",n._config.id||null)("role",n._config.role)("aria-modal",n._config.ariaModal)("aria-labelledby",n._config.ariaLabel?null:n._ariaLabelledByQueue[0])("aria-label",n._config.ariaLabel)("aria-describedby",n._config.ariaDescribedBy||null)},features:[Q],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(t,n){t&1&&ze(0,$v,0,0,"ng-template",0)},dependencies:[Ri],styles:[`.cdk-dialog-container {
3159
3159
  display: block;
3160
3160
  width: 100%;
3161
3161
  height: 100%;
3162
3162
  min-height: inherit;
3163
3163
  max-height: inherit;
3164
3164
  }
3165
- `],encapsulation:2,changeDetection:1})}return i})(),Oa=class{overlayRef;config;componentInstance=null;componentRef=null;containerInstance;disableClose;closed=new I;backdropClick;keydownEvents;outsidePointerEvents;id;_detachSubscription;constructor(o,e){this.overlayRef=o,this.config=e,this.disableClose=e.disableClose,this.backdropClick=o.backdropClick(),this.keydownEvents=o.keydownEvents(),this.outsidePointerEvents=o.outsidePointerEvents(),this.id=e.id,this.keydownEvents.subscribe(t=>{t.keyCode===27&&!this.disableClose&&!Ge(t)&&(t.preventDefault(),this.close(void 0,{focusOrigin:"keyboard"}))}),this.backdropClick.subscribe(()=>{!this.disableClose&&this._canClose()?this.close(void 0,{focusOrigin:"mouse"}):this.containerInstance._recaptureFocus?.()}),this._detachSubscription=o.detachments().subscribe(()=>{e.closeOnOverlayDetachments!==!1&&this.close()})}close(o,e){if(this._canClose(o)){let t=this.closed;this.containerInstance._closeInteractionType=e?.focusOrigin||"program",this._detachSubscription.unsubscribe(),this.overlayRef.dispose(),t.next(o),t.complete(),this.componentInstance=this.containerInstance=null}}updatePosition(){return this.overlayRef.updatePosition(),this}updateSize(o="",e=""){return this.overlayRef.updateSize({width:o,height:e}),this}addPanelClass(o){return this.overlayRef.addPanelClass(o),this}removePanelClass(o){return this.overlayRef.removePanelClass(o),this}_canClose(o){let e=this.config;return!!this.containerInstance&&(!e.closePredicate||e.closePredicate(o,e,this.componentInstance))}},Wv=new C("DialogScrollStrategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>Mo(i)}}),qv=new C("DialogData"),Kv=new C("DefaultDialogConfig");function Yv(i){let o=R(i),e=new K;return{valueSignal:o,get value(){return o()},change:e,ngOnDestroy(){e.complete()}}}var Mc=(()=>{class i{_injector=d(X);_defaultOptions=d(Kv,{optional:!0});_parentDialog=d(i,{optional:!0,skipSelf:!0});_overlayContainer=d(hs);_idGenerator=d(be);_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new I;_afterOpenedAtThisLevel=new I;_ariaHiddenElements=new Map;_scrollStrategy=d(Wv);get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}afterAllClosed=Yi(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(ke(void 0)));open(e,t){let n=this._defaultOptions||new bn;t=V(V({},n),t),t.id=t.id||this._idGenerator.getId("cdk-dialog-"),t.id&&this.getDialogById(t.id);let a=this._getOverlayConfig(t),r=qt(this._injector,a),u=new Oa(r,t),h=this._attachContainer(r,u,t);if(u.containerInstance=h,!this.openDialogs.length){let g=this._overlayContainer.getContainerElement();h._focusTrapped?h._focusTrapped.pipe(ct(1)).subscribe(()=>{this._hideNonDialogContentFromAssistiveTechnology(g)}):this._hideNonDialogContentFromAssistiveTechnology(g)}return this._attachDialogContent(e,u,h,t),this.openDialogs.push(u),u.closed.subscribe(()=>this._removeOpenDialog(u,!0)),this.afterOpened.next(u),u}closeAll(){kc(this.openDialogs,e=>e.close())}getDialogById(e){return this.openDialogs.find(t=>t.id===e)}ngOnDestroy(){kc(this._openDialogsAtThisLevel,e=>{e.config.closeOnDestroy===!1&&this._removeOpenDialog(e,!1)}),kc(this._openDialogsAtThisLevel,e=>e.close()),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete(),this._openDialogsAtThisLevel=[]}_getOverlayConfig(e){let t=new Wt({positionStrategy:e.positionStrategy||vn().centerHorizontally().centerVertically(),scrollStrategy:e.scrollStrategy||this._scrollStrategy(),panelClass:e.panelClass,hasBackdrop:e.hasBackdrop,direction:e.direction,minWidth:e.minWidth,minHeight:e.minHeight,maxWidth:e.maxWidth,maxHeight:e.maxHeight,width:e.width,height:e.height,disposeOnNavigation:e.closeOnNavigation,disableAnimations:e.disableAnimations});return e.backdropClass&&(t.backdropClass=e.backdropClass),t}_attachContainer(e,t,n){let a=n.injector||n.viewContainerRef?.injector,r=[{provide:bn,useValue:n},{provide:Oa,useValue:t},{provide:ko,useValue:e}],u;n.container?typeof n.container=="function"?u=n.container:(u=n.container.type,r.push(...n.container.providers(n))):u=Sc;let h=new bi(u,n.viewContainerRef,X.create({parent:a||this._injector,providers:r}));return e.attach(h).instance}_attachDialogContent(e,t,n,a){if(e instanceof Ye){let r=this._createInjector(a,t,n,void 0),u={$implicit:a.data,dialogRef:t};a.templateContext&&(u=V(V({},u),typeof a.templateContext=="function"?a.templateContext():a.templateContext)),n.attachTemplatePortal(new Et(e,null,u,r))}else{let r=this._createInjector(a,t,n,this._injector),u=n.attachComponentPortal(new bi(e,a.viewContainerRef,r,null,a.bindings));t.componentRef=u,t.componentInstance=u.instance}}_createInjector(e,t,n,a){let r=e.injector||e.viewContainerRef?.injector,u=[{provide:qv,useValue:e.data},{provide:Oa,useValue:t}];return e.providers&&(typeof e.providers=="function"?u.push(...e.providers(t,e,n)):u.push(...e.providers)),e.direction&&(!r||!r.get(qe,null,{optional:!0}))&&u.push({provide:qe,useValue:Yv(e.direction)}),X.create({parent:r||a,providers:u})}_removeOpenDialog(e,t){let n=this.openDialogs.indexOf(e);n>-1&&(this.openDialogs.splice(n,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((a,r)=>{a?r.setAttribute("aria-hidden",a):r.removeAttribute("aria-hidden")}),this._ariaHiddenElements.clear(),t&&this._getAfterAllClosed().next()))}_hideNonDialogContentFromAssistiveTechnology(e){if(e.parentElement){let t=e.parentElement.children;for(let n=t.length-1;n>-1;n--){let a=t[n];a!==e&&a.nodeName!=="SCRIPT"&&a.nodeName!=="STYLE"&&!a.hasAttribute("aria-live")&&!a.hasAttribute("popover")&&(this._ariaHiddenElements.set(a,a.getAttribute("aria-hidden")),a.setAttribute("aria-hidden","true"))}}}_getAfterAllClosed(){let e=this._parentDialog;return e?e._getAfterAllClosed():this._afterAllClosedAtThisLevel}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function kc(i,o){let e=i.length;for(;e--;)o(i[e])}var qh=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({providers:[Mc],imports:[Nt,Oi,sa,Oi]})}return i})();function Xv(i,o){}var gs=class{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;closePredicate;width="";height="";minWidth;minHeight;maxWidth;maxHeight;position;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!1;autoFocus="first-tabbable";restoreFocus=!0;delayFocusTrap=!0;scrollStrategy;closeOnNavigation=!0;enterAnimationDuration;exitAnimationDuration;bindings},Ec="mdc-dialog--open",Kh="mdc-dialog--opening",Yh="mdc-dialog--closing",Zv=150,Qv=75,Jv=(()=>{class i extends Sc{_animationStateChanged=new K;_animationsEnabled=!pe();_actionSectionCount=0;_hostElement=this._elementRef.nativeElement;_enterAnimationDuration=this._animationsEnabled?Zh(this._config.enterAnimationDuration)??Zv:0;_exitAnimationDuration=this._animationsEnabled?Zh(this._config.exitAnimationDuration)??Qv:0;_animationTimer=null;_contentAttached(){super._contentAttached(),this._startOpenAnimation()}_startOpenAnimation(){this._animationStateChanged.emit({state:"opening",totalTime:this._enterAnimationDuration}),this._animationsEnabled?(this._hostElement.style.setProperty(Xh,`${this._enterAnimationDuration}ms`),this._requestAnimationFrame(()=>this._hostElement.classList.add(Kh,Ec)),this._waitForAnimationToComplete(this._enterAnimationDuration,this._finishDialogOpen)):(this._hostElement.classList.add(Ec),Promise.resolve().then(()=>this._finishDialogOpen()))}_startExitAnimation(){this._animationStateChanged.emit({state:"closing",totalTime:this._exitAnimationDuration}),this._hostElement.classList.remove(Ec),this._animationsEnabled?(this._hostElement.style.setProperty(Xh,`${this._exitAnimationDuration}ms`),this._requestAnimationFrame(()=>this._hostElement.classList.add(Yh)),this._waitForAnimationToComplete(this._exitAnimationDuration,this._finishDialogClose)):Promise.resolve().then(()=>this._finishDialogClose())}_updateActionSectionCount(e){this._actionSectionCount+=e,this._changeDetectorRef.markForCheck()}_finishDialogOpen=()=>{this._clearAnimationClasses(),this._openAnimationDone(this._enterAnimationDuration)};_finishDialogClose=()=>{this._clearAnimationClasses(),this._animationStateChanged.emit({state:"closed",totalTime:this._exitAnimationDuration})};_clearAnimationClasses(){this._hostElement.classList.remove(Kh,Yh)}_waitForAnimationToComplete(e,t){this._animationTimer!==null&&clearTimeout(this._animationTimer),this._animationTimer=setTimeout(t,e)}_requestAnimationFrame(e){this._ngZone.runOutsideAngular(()=>{typeof requestAnimationFrame=="function"?requestAnimationFrame(e):e()})}_captureInitialFocus(){this._config.delayFocusTrap||this._trapFocus()}_openAnimationDone(e){this._config.delayFocusTrap&&this._trapFocus(),this._animationStateChanged.next({state:"opened",totalTime:e})}ngOnDestroy(){super.ngOnDestroy(),this._animationTimer!==null&&clearTimeout(this._animationTimer)}attachComponentPortal(e){let t=super.attachComponentPortal(e);return t.location.nativeElement.classList.add("mat-mdc-dialog-component-host"),t}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275cmp=T({type:i,selectors:[["mat-dialog-container"]],hostAttrs:["tabindex","-1",1,"mat-mdc-dialog-container","mdc-dialog"],hostVars:10,hostBindings:function(t,n){t&2&&(dt("id",n._config.id),Z("aria-modal",n._config.ariaModal)("role",n._config.role)("aria-labelledby",n._config.ariaLabel?null:n._ariaLabelledByQueue[0])("aria-label",n._config.ariaLabel)("aria-describedby",n._config.ariaDescribedBy||null),p("_mat-animation-noopable",!n._animationsEnabled)("mat-mdc-dialog-container-with-actions",n._actionSectionCount>0))},features:[Q],decls:3,vars:0,consts:[[1,"mat-mdc-dialog-inner-container","mdc-dialog__container"],[1,"mat-mdc-dialog-surface","mdc-dialog__surface"],["cdkPortalOutlet",""]],template:function(t,n){t&1&&(s(0,"div",0)(1,"div",1),ze(2,Xv,0,0,"ng-template",2),l()())},dependencies:[Ri],styles:[`.mat-mdc-dialog-container {
3165
+ `],encapsulation:2,changeDetection:1})}return i})(),Fa=class{overlayRef;config;componentInstance=null;componentRef=null;containerInstance;disableClose;closed=new I;backdropClick;keydownEvents;outsidePointerEvents;id;_detachSubscription;constructor(o,e){this.overlayRef=o,this.config=e,this.disableClose=e.disableClose,this.backdropClick=o.backdropClick(),this.keydownEvents=o.keydownEvents(),this.outsidePointerEvents=o.outsidePointerEvents(),this.id=e.id,this.keydownEvents.subscribe(t=>{t.keyCode===27&&!this.disableClose&&!Ge(t)&&(t.preventDefault(),this.close(void 0,{focusOrigin:"keyboard"}))}),this.backdropClick.subscribe(()=>{!this.disableClose&&this._canClose()?this.close(void 0,{focusOrigin:"mouse"}):this.containerInstance._recaptureFocus?.()}),this._detachSubscription=o.detachments().subscribe(()=>{e.closeOnOverlayDetachments!==!1&&this.close()})}close(o,e){if(this._canClose(o)){let t=this.closed;this.containerInstance._closeInteractionType=e?.focusOrigin||"program",this._detachSubscription.unsubscribe(),this.overlayRef.dispose(),t.next(o),t.complete(),this.componentInstance=this.containerInstance=null}}updatePosition(){return this.overlayRef.updatePosition(),this}updateSize(o="",e=""){return this.overlayRef.updateSize({width:o,height:e}),this}addPanelClass(o){return this.overlayRef.addPanelClass(o),this}removePanelClass(o){return this.overlayRef.removePanelClass(o),this}_canClose(o){let e=this.config;return!!this.containerInstance&&(!e.closePredicate||e.closePredicate(o,e,this.componentInstance))}},Wv=new x("DialogScrollStrategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>Ao(i)}}),qv=new x("DialogData"),Kv=new x("DefaultDialogConfig");function Yv(i){let o=R(i),e=new K;return{valueSignal:o,get value(){return o()},change:e,ngOnDestroy(){e.complete()}}}var Ec=(()=>{class i{_injector=d(X);_defaultOptions=d(Kv,{optional:!0});_parentDialog=d(i,{optional:!0,skipSelf:!0});_overlayContainer=d(gs);_idGenerator=d(be);_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new I;_afterOpenedAtThisLevel=new I;_ariaHiddenElements=new Map;_scrollStrategy=d(Wv);get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}afterAllClosed=Yi(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(ke(void 0)));open(e,t){let n=this._defaultOptions||new bn;t=V(V({},n),t),t.id=t.id||this._idGenerator.getId("cdk-dialog-"),t.id&&this.getDialogById(t.id);let a=this._getOverlayConfig(t),r=qt(this._injector,a),u=new Fa(r,t),h=this._attachContainer(r,u,t);if(u.containerInstance=h,!this.openDialogs.length){let g=this._overlayContainer.getContainerElement();h._focusTrapped?h._focusTrapped.pipe(ct(1)).subscribe(()=>{this._hideNonDialogContentFromAssistiveTechnology(g)}):this._hideNonDialogContentFromAssistiveTechnology(g)}return this._attachDialogContent(e,u,h,t),this.openDialogs.push(u),u.closed.subscribe(()=>this._removeOpenDialog(u,!0)),this.afterOpened.next(u),u}closeAll(){Sc(this.openDialogs,e=>e.close())}getDialogById(e){return this.openDialogs.find(t=>t.id===e)}ngOnDestroy(){Sc(this._openDialogsAtThisLevel,e=>{e.config.closeOnDestroy===!1&&this._removeOpenDialog(e,!1)}),Sc(this._openDialogsAtThisLevel,e=>e.close()),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete(),this._openDialogsAtThisLevel=[]}_getOverlayConfig(e){let t=new Wt({positionStrategy:e.positionStrategy||vn().centerHorizontally().centerVertically(),scrollStrategy:e.scrollStrategy||this._scrollStrategy(),panelClass:e.panelClass,hasBackdrop:e.hasBackdrop,direction:e.direction,minWidth:e.minWidth,minHeight:e.minHeight,maxWidth:e.maxWidth,maxHeight:e.maxHeight,width:e.width,height:e.height,disposeOnNavigation:e.closeOnNavigation,disableAnimations:e.disableAnimations});return e.backdropClass&&(t.backdropClass=e.backdropClass),t}_attachContainer(e,t,n){let a=n.injector||n.viewContainerRef?.injector,r=[{provide:bn,useValue:n},{provide:Fa,useValue:t},{provide:Mo,useValue:e}],u;n.container?typeof n.container=="function"?u=n.container:(u=n.container.type,r.push(...n.container.providers(n))):u=Mc;let h=new bi(u,n.viewContainerRef,X.create({parent:a||this._injector,providers:r}));return e.attach(h).instance}_attachDialogContent(e,t,n,a){if(e instanceof Ye){let r=this._createInjector(a,t,n,void 0),u={$implicit:a.data,dialogRef:t};a.templateContext&&(u=V(V({},u),typeof a.templateContext=="function"?a.templateContext():a.templateContext)),n.attachTemplatePortal(new Et(e,null,u,r))}else{let r=this._createInjector(a,t,n,this._injector),u=n.attachComponentPortal(new bi(e,a.viewContainerRef,r,null,a.bindings));t.componentRef=u,t.componentInstance=u.instance}}_createInjector(e,t,n,a){let r=e.injector||e.viewContainerRef?.injector,u=[{provide:qv,useValue:e.data},{provide:Fa,useValue:t}];return e.providers&&(typeof e.providers=="function"?u.push(...e.providers(t,e,n)):u.push(...e.providers)),e.direction&&(!r||!r.get(qe,null,{optional:!0}))&&u.push({provide:qe,useValue:Yv(e.direction)}),X.create({parent:r||a,providers:u})}_removeOpenDialog(e,t){let n=this.openDialogs.indexOf(e);n>-1&&(this.openDialogs.splice(n,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((a,r)=>{a?r.setAttribute("aria-hidden",a):r.removeAttribute("aria-hidden")}),this._ariaHiddenElements.clear(),t&&this._getAfterAllClosed().next()))}_hideNonDialogContentFromAssistiveTechnology(e){if(e.parentElement){let t=e.parentElement.children;for(let n=t.length-1;n>-1;n--){let a=t[n];a!==e&&a.nodeName!=="SCRIPT"&&a.nodeName!=="STYLE"&&!a.hasAttribute("aria-live")&&!a.hasAttribute("popover")&&(this._ariaHiddenElements.set(a,a.getAttribute("aria-hidden")),a.setAttribute("aria-hidden","true"))}}}_getAfterAllClosed(){let e=this._parentDialog;return e?e._getAfterAllClosed():this._afterAllClosedAtThisLevel}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();function Sc(i,o){let e=i.length;for(;e--;)o(i[e])}var qh=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({providers:[Ec],imports:[Nt,Oi,ca,Oi]})}return i})();function Xv(i,o){}var bs=class{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;closePredicate;width="";height="";minWidth;minHeight;maxWidth;maxHeight;position;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!1;autoFocus="first-tabbable";restoreFocus=!0;delayFocusTrap=!0;scrollStrategy;closeOnNavigation=!0;enterAnimationDuration;exitAnimationDuration;bindings},Ac="mdc-dialog--open",Kh="mdc-dialog--opening",Yh="mdc-dialog--closing",Zv=150,Qv=75,Jv=(()=>{class i extends Mc{_animationStateChanged=new K;_animationsEnabled=!pe();_actionSectionCount=0;_hostElement=this._elementRef.nativeElement;_enterAnimationDuration=this._animationsEnabled?Zh(this._config.enterAnimationDuration)??Zv:0;_exitAnimationDuration=this._animationsEnabled?Zh(this._config.exitAnimationDuration)??Qv:0;_animationTimer=null;_contentAttached(){super._contentAttached(),this._startOpenAnimation()}_startOpenAnimation(){this._animationStateChanged.emit({state:"opening",totalTime:this._enterAnimationDuration}),this._animationsEnabled?(this._hostElement.style.setProperty(Xh,`${this._enterAnimationDuration}ms`),this._requestAnimationFrame(()=>this._hostElement.classList.add(Kh,Ac)),this._waitForAnimationToComplete(this._enterAnimationDuration,this._finishDialogOpen)):(this._hostElement.classList.add(Ac),Promise.resolve().then(()=>this._finishDialogOpen()))}_startExitAnimation(){this._animationStateChanged.emit({state:"closing",totalTime:this._exitAnimationDuration}),this._hostElement.classList.remove(Ac),this._animationsEnabled?(this._hostElement.style.setProperty(Xh,`${this._exitAnimationDuration}ms`),this._requestAnimationFrame(()=>this._hostElement.classList.add(Yh)),this._waitForAnimationToComplete(this._exitAnimationDuration,this._finishDialogClose)):Promise.resolve().then(()=>this._finishDialogClose())}_updateActionSectionCount(e){this._actionSectionCount+=e,this._changeDetectorRef.markForCheck()}_finishDialogOpen=()=>{this._clearAnimationClasses(),this._openAnimationDone(this._enterAnimationDuration)};_finishDialogClose=()=>{this._clearAnimationClasses(),this._animationStateChanged.emit({state:"closed",totalTime:this._exitAnimationDuration})};_clearAnimationClasses(){this._hostElement.classList.remove(Kh,Yh)}_waitForAnimationToComplete(e,t){this._animationTimer!==null&&clearTimeout(this._animationTimer),this._animationTimer=setTimeout(t,e)}_requestAnimationFrame(e){this._ngZone.runOutsideAngular(()=>{typeof requestAnimationFrame=="function"?requestAnimationFrame(e):e()})}_captureInitialFocus(){this._config.delayFocusTrap||this._trapFocus()}_openAnimationDone(e){this._config.delayFocusTrap&&this._trapFocus(),this._animationStateChanged.next({state:"opened",totalTime:e})}ngOnDestroy(){super.ngOnDestroy(),this._animationTimer!==null&&clearTimeout(this._animationTimer)}attachComponentPortal(e){let t=super.attachComponentPortal(e);return t.location.nativeElement.classList.add("mat-mdc-dialog-component-host"),t}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275cmp=T({type:i,selectors:[["mat-dialog-container"]],hostAttrs:["tabindex","-1",1,"mat-mdc-dialog-container","mdc-dialog"],hostVars:10,hostBindings:function(t,n){t&2&&(dt("id",n._config.id),Z("aria-modal",n._config.ariaModal)("role",n._config.role)("aria-labelledby",n._config.ariaLabel?null:n._ariaLabelledByQueue[0])("aria-label",n._config.ariaLabel)("aria-describedby",n._config.ariaDescribedBy||null),p("_mat-animation-noopable",!n._animationsEnabled)("mat-mdc-dialog-container-with-actions",n._actionSectionCount>0))},features:[Q],decls:3,vars:0,consts:[[1,"mat-mdc-dialog-inner-container","mdc-dialog__container"],[1,"mat-mdc-dialog-surface","mdc-dialog__surface"],["cdkPortalOutlet",""]],template:function(t,n){t&1&&(s(0,"div",0)(1,"div",1),ze(2,Xv,0,0,"ng-template",2),l()())},dependencies:[Ri],styles:[`.mat-mdc-dialog-container {
3166
3166
  width: 100%;
3167
3167
  height: 100%;
3168
3168
  display: block;
@@ -3351,7 +3351,7 @@ input.mat-mdc-chip-input {
3351
3351
  .mat-mdc-dialog-component-host {
3352
3352
  display: contents;
3353
3353
  }
3354
- `],encapsulation:2,changeDetection:1})}return i})(),Xh="--mat-dialog-transition-duration";function Zh(i){return i==null?null:typeof i=="number"?i:i.endsWith("ms")?Ht(i.substring(0,i.length-2)):i.endsWith("s")?Ht(i.substring(0,i.length-1))*1e3:i==="0"?0:null}var fs=(function(i){return i[i.OPEN=0]="OPEN",i[i.CLOSING=1]="CLOSING",i[i.CLOSED=2]="CLOSED",i})(fs||{}),gt=class{_ref;_config;_containerInstance;componentInstance;componentRef=null;disableClose;id;_afterOpened=new Ha(1);_beforeClosed=new Ha(1);_result;_closeFallbackTimeout;_state=fs.OPEN;_closeInteractionType;constructor(o,e,t){this._ref=o,this._config=e,this._containerInstance=t,this.disableClose=e.disableClose,this.id=o.id,o.addPanelClass("mat-mdc-dialog-panel"),t._animationStateChanged.pipe(Ce(n=>n.state==="opened"),ct(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),t._animationStateChanged.pipe(Ce(n=>n.state==="closed"),ct(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose()}),o.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose()}),$e(this.backdropClick(),this.keydownEvents().pipe(Ce(n=>n.keyCode===27&&!this.disableClose&&!Ge(n)))).subscribe(n=>{this.disableClose||(n.preventDefault(),eb(this,n.type==="keydown"?"keyboard":"mouse"))})}close(o){let e=this._config.closePredicate;e&&!e(o,this._config,this.componentInstance)||(this._result=o,this._containerInstance._animationStateChanged.pipe(Ce(t=>t.state==="closing"),ct(1)).subscribe(t=>{this._beforeClosed.next(o),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),t.totalTime+100)}),this._state=fs.CLOSING,this._containerInstance._startExitAnimation())}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(o){let e=this._ref.config.positionStrategy;return o&&(o.left||o.right)?o.left?e.left(o.left):e.right(o.right):e.centerHorizontally(),o&&(o.top||o.bottom)?o.top?e.top(o.top):e.bottom(o.bottom):e.centerVertically(),this._ref.updatePosition(),this}updateSize(o="",e=""){return this._ref.updateSize(o,e),this}addPanelClass(o){return this._ref.addPanelClass(o),this}removePanelClass(o){return this._ref.removePanelClass(o),this}getState(){return this._state}_finishDialogClose(){this._state=fs.CLOSED,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null}};function eb(i,o,e){return i._closeInteractionType=o,i.close(e)}var Gn=new C("MatMdcDialogData"),tb=new C("mat-mdc-dialog-default-options"),ib=new C("mat-mdc-dialog-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>Mo(i)}}),Eo=(()=>{class i{_defaultOptions=d(tb,{optional:!0});_scrollStrategy=d(ib);_parentDialog=d(i,{optional:!0,skipSelf:!0});_idGenerator=d(be);_injector=d(X);_dialog=d(Mc);_animationsDisabled=pe();_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new I;_afterOpenedAtThisLevel=new I;dialogConfigClass=gs;_dialogRefConstructor;_dialogContainerType;_dialogDataToken;get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){let e=this._parentDialog;return e?e._getAfterAllClosed():this._afterAllClosedAtThisLevel}afterAllClosed=Yi(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(ke(void 0)));constructor(){this._dialogRefConstructor=gt,this._dialogContainerType=Jv,this._dialogDataToken=Gn}open(e,t){let n;t=V(V({},this._defaultOptions||new gs),t),t.id=t.id||this._idGenerator.getId("mat-mdc-dialog-"),t.scrollStrategy=t.scrollStrategy||this._scrollStrategy();let a=this._dialog.open(e,Oe(V({},t),{positionStrategy:vn(this._injector).centerHorizontally().centerVertically(),disableClose:!0,closePredicate:void 0,closeOnDestroy:!1,closeOnOverlayDetachments:!1,disableAnimations:this._animationsDisabled||t.enterAnimationDuration?.toLocaleString()==="0"||t.exitAnimationDuration?.toString()==="0",container:{type:this._dialogContainerType,providers:()=>[{provide:this.dialogConfigClass,useValue:t},{provide:bn,useValue:t}]},templateContext:()=>({dialogRef:n}),providers:(r,u,h)=>(n=new this._dialogRefConstructor(r,t,h),n.updatePosition(t?.position),[{provide:this._dialogContainerType,useValue:h},{provide:this._dialogDataToken,useValue:u.data},{provide:this._dialogRefConstructor,useValue:n}])}));return n.componentRef=a.componentRef,n.componentInstance=a.componentInstance,this.openDialogs.push(n),this.afterOpened.next(n),n.afterClosed().subscribe(()=>{let r=this.openDialogs.indexOf(n);r>-1&&(this.openDialogs.splice(r,1),this.openDialogs.length||this._getAfterAllClosed().next())}),n}closeAll(){this._closeDialogs(this.openDialogs)}getDialogById(e){return this.openDialogs.find(t=>t.id===e)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete()}_closeDialogs(e){let t=e.length;for(;t--;)e[t].close()}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Qh=(()=>{class i{_dialogRef=d(gt,{optional:!0});_elementRef=d(N);_dialog=d(Eo);ngOnInit(){this._dialogRef||(this._dialogRef=nb(this._elementRef,this._dialog.openDialogs)),this._dialogRef&&Promise.resolve().then(()=>{this._onAdd()})}ngOnDestroy(){this._dialogRef?._containerInstance&&Promise.resolve().then(()=>{this._onRemove()})}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i})}return i})(),oi=(()=>{class i extends Qh{id=d(be).getId("mat-mdc-dialog-title-");_onAdd(){this._dialogRef._containerInstance?._addAriaLabelledBy?.(this.id)}_onRemove(){this._dialogRef?._containerInstance?._removeAriaLabelledBy?.(this.id)}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","mat-dialog-title",""],["","matDialogTitle",""]],hostAttrs:[1,"mat-mdc-dialog-title","mdc-dialog__title"],hostVars:1,hostBindings:function(t,n){t&2&&dt("id",n.id)},inputs:{id:"id"},exportAs:["matDialogTitle"],features:[Q]})}return i})(),ai=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","mat-dialog-content",""],["mat-dialog-content"],["","matDialogContent",""]],hostAttrs:[1,"mat-mdc-dialog-content","mdc-dialog__content"],features:[dd([cc])]})}return i})(),ri=(()=>{class i extends Qh{align;_onAdd(){this._dialogRef._containerInstance?._updateActionSectionCount?.(1)}_onRemove(){this._dialogRef._containerInstance?._updateActionSectionCount?.(-1)}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","mat-dialog-actions",""],["mat-dialog-actions"],["","matDialogActions",""]],hostAttrs:[1,"mat-mdc-dialog-actions","mdc-dialog__actions"],hostVars:6,hostBindings:function(t,n){t&2&&p("mat-mdc-dialog-actions-align-start",n.align==="start")("mat-mdc-dialog-actions-align-center",n.align==="center")("mat-mdc-dialog-actions-align-end",n.align==="end")},inputs:{align:"align"},features:[Q]})}return i})();function nb(i,o){let e=i.nativeElement.parentElement;for(;e&&!e.classList.contains("mat-mdc-dialog-container");)e=e.parentElement;return e?o.find(t=>t.id===e.id):null}var Lt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({providers:[Eo],imports:[qh,Nt,Oi,ee]})}return i})();var ob=[[["mat-icon"],["","matMenuItemIcon",""]],"*"],ab=["mat-icon, [matMenuItemIcon]","*"];function rb(i,o){i&1&&(wi(),s(0,"svg",2),v(1,"polygon",3),l())}var sb=["*"];function lb(i,o){if(i&1){let e=Ue();Ie(0,"div",0),er("click",function(){xe(e);let n=D();return we(n.closed.emit("click"))})("animationstart",function(n){xe(e);let a=D();return we(a._onAnimationStart(n.animationName))})("animationend",function(n){xe(e);let a=D();return we(a._onAnimationDone(n.animationName))})("animationcancel",function(n){xe(e);let a=D();return we(a._onAnimationDone(n.animationName))}),Ie(1,"div",1),U(2),je()()}if(i&2){let e=D();et(e._classList),p("mat-menu-panel-animations-disabled",e._animationsDisabled)("mat-menu-panel-exit-animation",e._panelAnimationState==="void")("mat-menu-panel-animating",e._isAnimating()),dt("id",e.panelId),Z("aria-label",e.ariaLabel||null)("aria-labelledby",e.ariaLabelledby||null)("aria-describedby",e.ariaDescribedby||null)}}var Tc=new C("MAT_MENU_PANEL"),$n=(()=>{class i{_elementRef=d(N);_document=d($);_focusMonitor=d(Rt);_parentMenu=d(Tc,{optional:!0});_changeDetectorRef=d(te);role="menuitem";disabled=!1;disableRipple=!1;_hovered=new I;_focused=new I;_highlighted=!1;_triggersSubmenu=!1;constructor(){d(Fe).load(Mt),this._parentMenu?.addItem?.(this)}focus(e,t){this._focusMonitor&&e?this._focusMonitor.focusVia(this._getHostElement(),e,t):this._getHostElement().focus(t),this._focused.next(this)}ngAfterViewInit(){this._focusMonitor&&this._focusMonitor.monitor(this._elementRef,!1)}ngOnDestroy(){this._focusMonitor&&this._focusMonitor.stopMonitoring(this._elementRef),this._parentMenu&&this._parentMenu.removeItem&&this._parentMenu.removeItem(this),this._hovered.complete(),this._focused.complete()}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._elementRef.nativeElement}_checkDisabled(e){this.disabled&&(e.preventDefault(),e.stopPropagation())}_handleMouseEnter(){this._hovered.next(this)}getLabel(){let e=this._elementRef.nativeElement.cloneNode(!0),t=e.querySelectorAll("mat-icon, .material-icons");for(let n=0;n<t.length;n++)t[n].remove();return e.textContent?.trim()||""}_setHighlighted(e){this._highlighted=e,this._changeDetectorRef.markForCheck()}_setTriggersSubmenu(e){this._triggersSubmenu=e,this._changeDetectorRef.markForCheck()}_hasFocus(){return this._document&&this._document.activeElement===this._getHostElement()}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["","mat-menu-item",""]],hostAttrs:[1,"mat-mdc-menu-item","mat-focus-indicator"],hostVars:8,hostBindings:function(t,n){t&1&&A("click",function(r){return n._checkDisabled(r)})("mouseenter",function(){return n._handleMouseEnter()}),t&2&&(Z("role",n.role)("tabindex",n._getTabIndex())("aria-disabled",n.disabled)("disabled",n.disabled||null),p("mat-mdc-menu-item-highlighted",n._highlighted)("mat-mdc-menu-item-submenu-trigger",n._triggersSubmenu))},inputs:{role:"role",disabled:[2,"disabled","disabled",L],disableRipple:[2,"disableRipple","disableRipple",L]},exportAs:["matMenuItem"],ngContentSelectors:ab,decls:5,vars:3,consts:[[1,"mat-mdc-menu-item-text"],["matRipple","",1,"mat-mdc-menu-ripple",3,"matRippleDisabled","matRippleTrigger"],["viewBox","0 0 5 10","focusable","false","aria-hidden","true",1,"mat-mdc-menu-submenu-icon"],["points","0,0 5,5 0,10"]],template:function(t,n){t&1&&(ce(ob),U(0),s(1,"span",0),U(2,1),l(),v(3,"div",1),M(4,rb,2,0,":svg:svg",2)),t&2&&(c(3),x("matRippleDisabled",n.disableRipple||n.disabled)("matRippleTrigger",n._getHostElement()),c(),E(n._triggersSubmenu?4:-1))},dependencies:[wo],encapsulation:2})}return i})();var cb=new C("MatMenuContent");var db=new C("mat-menu-default-options",{providedIn:"root",factory:()=>({overlapTrigger:!1,xPosition:"after",yPosition:"below",backdropClass:"cdk-overlay-transparent-backdrop"})}),Ac="_mat-menu-enter",_s="_mat-menu-exit",yn=(()=>{class i{_elementRef=d(N);_changeDetectorRef=d(te);_injector=d(X);_keyManager;_xPosition;_yPosition;_firstItemFocusRef;_exitFallbackTimeout;_animationsDisabled=pe();_allItems;_directDescendantItems=new Zi;_classList={};_panelAnimationState="void";_animationDone=new I;_isAnimating=R(!1);parentMenu;direction;overlayPanelClass;backdropClass;ariaLabel;ariaLabelledby;ariaDescribedby;get xPosition(){return this._xPosition}set xPosition(e){this._xPosition=e,this.setPositionClasses()}get yPosition(){return this._yPosition}set yPosition(e){this._yPosition=e,this.setPositionClasses()}templateRef;items;lazyContent;overlapTrigger=!1;hasBackdrop;get panelClass(){return this._previousPanelClass}set panelClass(e){let t=this._previousPanelClass,n=V({},this._classList);t&&t.length&&t.split(" ").forEach(a=>{n[a]=!1}),this._previousPanelClass=e,e&&e.length&&(e.split(" ").forEach(a=>{n[a]=!0}),this._elementRef.nativeElement.className=""),this._classList=n}_previousPanelClass="";get classList(){return this.panelClass}set classList(e){this.panelClass=e}closed=new K;close=this.closed;panelId=d(be).getId("mat-menu-panel-");constructor(){let e=d(db);this.overlayPanelClass=e.overlayPanelClass||"",this._xPosition=e.xPosition,this._yPosition=e.yPosition,this.backdropClass=e.backdropClass,this.overlapTrigger=e.overlapTrigger,this.hasBackdrop=e.hasBackdrop}ngOnInit(){this.setPositionClasses()}ngAfterContentInit(){this._updateDirectDescendants(),this._keyManager=new cn(this._directDescendantItems).withWrap().withTypeAhead().withHomeAndEnd(),this._keyManager.tabOut.subscribe(()=>this.closed.emit("tab")),this._directDescendantItems.changes.pipe(ke(this._directDescendantItems),We(e=>$e(...e.map(t=>t._focused)))).subscribe(e=>this._keyManager.updateActiveItem(e)),this._directDescendantItems.changes.subscribe(e=>{let t=this._keyManager;if(this._panelAnimationState==="enter"&&t.activeItem?._hasFocus()){let n=e.toArray(),a=Math.max(0,Math.min(n.length-1,t.activeItemIndex||0));n[a]&&!n[a].disabled?t.setActiveItem(a):t.setNextItemActive()}})}ngOnDestroy(){this._keyManager?.destroy(),this._directDescendantItems.destroy(),this.closed.complete(),this._firstItemFocusRef?.destroy(),clearTimeout(this._exitFallbackTimeout)}_hovered(){return this._directDescendantItems.changes.pipe(ke(this._directDescendantItems),We(t=>$e(...t.map(n=>n._hovered))))}addItem(e){}removeItem(e){}_handleKeydown(e){let t=e.keyCode,n=this._keyManager;switch(t){case 27:Ge(e)||(e.preventDefault(),this.closed.emit("keydown"));break;case 37:this.parentMenu&&this.direction==="ltr"&&this.closed.emit("keydown");break;case 39:this.parentMenu&&this.direction==="rtl"&&this.closed.emit("keydown");break;default:(t===38||t===40)&&n.setFocusOrigin("keyboard"),n.onKeydown(e);return}}focusFirstItem(e="program"){this._firstItemFocusRef?.destroy(),this._firstItemFocusRef=Be(()=>{let t=this._resolvePanel();if(!t||!t.contains(document.activeElement)){let n=this._keyManager;n.setFocusOrigin(e).setFirstItemActive(),!n.activeItem&&t&&t.focus()}},{injector:this._injector})}resetActiveItem(){this._keyManager.setActiveItem(-1)}setElevation(e){}setPositionClasses(e=this.xPosition,t=this.yPosition){this._classList=Oe(V({},this._classList),{"mat-menu-before":e==="before","mat-menu-after":e==="after","mat-menu-above":t==="above","mat-menu-below":t==="below"}),this._changeDetectorRef.markForCheck()}_onAnimationDone(e){let t=e===_s;(t||e===Ac)&&(t&&(clearTimeout(this._exitFallbackTimeout),this._exitFallbackTimeout=void 0),this._animationDone.next(t?"void":"enter"),this._isAnimating.set(!1))}_onAnimationStart(e){(e===Ac||e===_s)&&this._isAnimating.set(!0)}_setIsOpen(e){if(this._panelAnimationState=e?"enter":"void",e){if(this._keyManager.activeItemIndex===0){let t=this._resolvePanel();t&&(t.scrollTop=0)}}else this._animationsDisabled||(this._exitFallbackTimeout=setTimeout(()=>this._onAnimationDone(_s),200));this._animationsDisabled&&setTimeout(()=>{this._onAnimationDone(e?Ac:_s)}),this._changeDetectorRef.markForCheck()}_updateDirectDescendants(){this._allItems.changes.pipe(ke(this._allItems)).subscribe(e=>{this._directDescendantItems.reset(e.filter(t=>t._parentMenu===this)),this._directDescendantItems.notifyOnChanges()})}_resolvePanel(){let e=null;return this._directDescendantItems.length&&(e=this._directDescendantItems.first._getHostElement().closest('[role="menu"]')),e}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-menu"]],contentQueries:function(t,n,a){if(t&1&&at(a,cb,5)(a,$n,5)(a,$n,4),t&2){let r;O(r=P())&&(n.lazyContent=r.first),O(r=P())&&(n._allItems=r),O(r=P())&&(n.items=r)}},viewQuery:function(t,n){if(t&1&&Me(Ye,5),t&2){let a;O(a=P())&&(n.templateRef=a.first)}},hostVars:3,hostBindings:function(t,n){t&2&&Z("aria-label",null)("aria-labelledby",null)("aria-describedby",null)},inputs:{backdropClass:"backdropClass",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],ariaDescribedby:[0,"aria-describedby","ariaDescribedby"],xPosition:"xPosition",yPosition:"yPosition",overlapTrigger:[2,"overlapTrigger","overlapTrigger",L],hasBackdrop:[2,"hasBackdrop","hasBackdrop",e=>e==null?null:L(e)],panelClass:[0,"class","panelClass"],classList:"classList"},outputs:{closed:"closed",close:"close"},exportAs:["matMenu"],features:[J([{provide:Tc,useExisting:i}])],ngContentSelectors:sb,decls:1,vars:0,consts:[["tabindex","-1","role","menu",1,"mat-mdc-menu-panel",3,"click","animationstart","animationend","animationcancel","id"],[1,"mat-mdc-menu-content"]],template:function(t,n){t&1&&(ce(),Ja(0,lb,3,12,"ng-template"))},styles:[`mat-menu {
3354
+ `],encapsulation:2,changeDetection:1})}return i})(),Xh="--mat-dialog-transition-duration";function Zh(i){return i==null?null:typeof i=="number"?i:i.endsWith("ms")?Ht(i.substring(0,i.length-2)):i.endsWith("s")?Ht(i.substring(0,i.length-1))*1e3:i==="0"?0:null}var vs=(function(i){return i[i.OPEN=0]="OPEN",i[i.CLOSING=1]="CLOSING",i[i.CLOSED=2]="CLOSED",i})(vs||{}),gt=class{_ref;_config;_containerInstance;componentInstance;componentRef=null;disableClose;id;_afterOpened=new $a(1);_beforeClosed=new $a(1);_result;_closeFallbackTimeout;_state=vs.OPEN;_closeInteractionType;constructor(o,e,t){this._ref=o,this._config=e,this._containerInstance=t,this.disableClose=e.disableClose,this.id=o.id,o.addPanelClass("mat-mdc-dialog-panel"),t._animationStateChanged.pipe(Ce(n=>n.state==="opened"),ct(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete()}),t._animationStateChanged.pipe(Ce(n=>n.state==="closed"),ct(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose()}),o.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose()}),$e(this.backdropClick(),this.keydownEvents().pipe(Ce(n=>n.keyCode===27&&!this.disableClose&&!Ge(n)))).subscribe(n=>{this.disableClose||(n.preventDefault(),eb(this,n.type==="keydown"?"keyboard":"mouse"))})}close(o){let e=this._config.closePredicate;e&&!e(o,this._config,this.componentInstance)||(this._result=o,this._containerInstance._animationStateChanged.pipe(Ce(t=>t.state==="closing"),ct(1)).subscribe(t=>{this._beforeClosed.next(o),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),t.totalTime+100)}),this._state=vs.CLOSING,this._containerInstance._startExitAnimation())}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(o){let e=this._ref.config.positionStrategy;return o&&(o.left||o.right)?o.left?e.left(o.left):e.right(o.right):e.centerHorizontally(),o&&(o.top||o.bottom)?o.top?e.top(o.top):e.bottom(o.bottom):e.centerVertically(),this._ref.updatePosition(),this}updateSize(o="",e=""){return this._ref.updateSize(o,e),this}addPanelClass(o){return this._ref.addPanelClass(o),this}removePanelClass(o){return this._ref.removePanelClass(o),this}getState(){return this._state}_finishDialogClose(){this._state=vs.CLOSED,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null}};function eb(i,o,e){return i._closeInteractionType=o,i.close(e)}var Wn=new x("MatMdcDialogData"),tb=new x("mat-mdc-dialog-default-options"),ib=new x("mat-mdc-dialog-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>Ao(i)}}),To=(()=>{class i{_defaultOptions=d(tb,{optional:!0});_scrollStrategy=d(ib);_parentDialog=d(i,{optional:!0,skipSelf:!0});_idGenerator=d(be);_injector=d(X);_dialog=d(Ec);_animationsDisabled=pe();_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new I;_afterOpenedAtThisLevel=new I;dialogConfigClass=bs;_dialogRefConstructor;_dialogContainerType;_dialogDataToken;get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){let e=this._parentDialog;return e?e._getAfterAllClosed():this._afterAllClosedAtThisLevel}afterAllClosed=Yi(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(ke(void 0)));constructor(){this._dialogRefConstructor=gt,this._dialogContainerType=Jv,this._dialogDataToken=Wn}open(e,t){let n;t=V(V({},this._defaultOptions||new bs),t),t.id=t.id||this._idGenerator.getId("mat-mdc-dialog-"),t.scrollStrategy=t.scrollStrategy||this._scrollStrategy();let a=this._dialog.open(e,Oe(V({},t),{positionStrategy:vn(this._injector).centerHorizontally().centerVertically(),disableClose:!0,closePredicate:void 0,closeOnDestroy:!1,closeOnOverlayDetachments:!1,disableAnimations:this._animationsDisabled||t.enterAnimationDuration?.toLocaleString()==="0"||t.exitAnimationDuration?.toString()==="0",container:{type:this._dialogContainerType,providers:()=>[{provide:this.dialogConfigClass,useValue:t},{provide:bn,useValue:t}]},templateContext:()=>({dialogRef:n}),providers:(r,u,h)=>(n=new this._dialogRefConstructor(r,t,h),n.updatePosition(t?.position),[{provide:this._dialogContainerType,useValue:h},{provide:this._dialogDataToken,useValue:u.data},{provide:this._dialogRefConstructor,useValue:n}])}));return n.componentRef=a.componentRef,n.componentInstance=a.componentInstance,this.openDialogs.push(n),this.afterOpened.next(n),n.afterClosed().subscribe(()=>{let r=this.openDialogs.indexOf(n);r>-1&&(this.openDialogs.splice(r,1),this.openDialogs.length||this._getAfterAllClosed().next())}),n}closeAll(){this._closeDialogs(this.openDialogs)}getDialogById(e){return this.openDialogs.find(t=>t.id===e)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete()}_closeDialogs(e){let t=e.length;for(;t--;)e[t].close()}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var Qh=(()=>{class i{_dialogRef=d(gt,{optional:!0});_elementRef=d(N);_dialog=d(To);ngOnInit(){this._dialogRef||(this._dialogRef=nb(this._elementRef,this._dialog.openDialogs)),this._dialogRef&&Promise.resolve().then(()=>{this._onAdd()})}ngOnDestroy(){this._dialogRef?._containerInstance&&Promise.resolve().then(()=>{this._onRemove()})}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i})}return i})(),oi=(()=>{class i extends Qh{id=d(be).getId("mat-mdc-dialog-title-");_onAdd(){this._dialogRef._containerInstance?._addAriaLabelledBy?.(this.id)}_onRemove(){this._dialogRef?._containerInstance?._removeAriaLabelledBy?.(this.id)}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","mat-dialog-title",""],["","matDialogTitle",""]],hostAttrs:[1,"mat-mdc-dialog-title","mdc-dialog__title"],hostVars:1,hostBindings:function(t,n){t&2&&dt("id",n.id)},inputs:{id:"id"},exportAs:["matDialogTitle"],features:[Q]})}return i})(),ai=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","mat-dialog-content",""],["mat-dialog-content"],["","matDialogContent",""]],hostAttrs:[1,"mat-mdc-dialog-content","mdc-dialog__content"],features:[dd([dc])]})}return i})(),ri=(()=>{class i extends Qh{align;_onAdd(){this._dialogRef._containerInstance?._updateActionSectionCount?.(1)}_onRemove(){this._dialogRef._containerInstance?._updateActionSectionCount?.(-1)}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","mat-dialog-actions",""],["mat-dialog-actions"],["","matDialogActions",""]],hostAttrs:[1,"mat-mdc-dialog-actions","mdc-dialog__actions"],hostVars:6,hostBindings:function(t,n){t&2&&p("mat-mdc-dialog-actions-align-start",n.align==="start")("mat-mdc-dialog-actions-align-center",n.align==="center")("mat-mdc-dialog-actions-align-end",n.align==="end")},inputs:{align:"align"},features:[Q]})}return i})();function nb(i,o){let e=i.nativeElement.parentElement;for(;e&&!e.classList.contains("mat-mdc-dialog-container");)e=e.parentElement;return e?o.find(t=>t.id===e.id):null}var Lt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({providers:[To],imports:[qh,Nt,Oi,ee]})}return i})();var ob=[[["mat-icon"],["","matMenuItemIcon",""]],"*"],ab=["mat-icon, [matMenuItemIcon]","*"];function rb(i,o){i&1&&(wi(),s(0,"svg",2),v(1,"polygon",3),l())}var sb=["*"];function lb(i,o){if(i&1){let e=Ue();Ie(0,"div",0),nr("click",function(){xe(e);let n=D();return we(n.closed.emit("click"))})("animationstart",function(n){xe(e);let a=D();return we(a._onAnimationStart(n.animationName))})("animationend",function(n){xe(e);let a=D();return we(a._onAnimationDone(n.animationName))})("animationcancel",function(n){xe(e);let a=D();return we(a._onAnimationDone(n.animationName))}),Ie(1,"div",1),U(2),je()()}if(i&2){let e=D();et(e._classList),p("mat-menu-panel-animations-disabled",e._animationsDisabled)("mat-menu-panel-exit-animation",e._panelAnimationState==="void")("mat-menu-panel-animating",e._isAnimating()),dt("id",e.panelId),Z("aria-label",e.ariaLabel||null)("aria-labelledby",e.ariaLabelledby||null)("aria-describedby",e.ariaDescribedby||null)}}var Ic=new x("MAT_MENU_PANEL"),qn=(()=>{class i{_elementRef=d(N);_document=d(W);_focusMonitor=d(Rt);_parentMenu=d(Ic,{optional:!0});_changeDetectorRef=d(te);role="menuitem";disabled=!1;disableRipple=!1;_hovered=new I;_focused=new I;_highlighted=!1;_triggersSubmenu=!1;constructor(){d(Ne).load(Mt),this._parentMenu?.addItem?.(this)}focus(e,t){this._focusMonitor&&e?this._focusMonitor.focusVia(this._getHostElement(),e,t):this._getHostElement().focus(t),this._focused.next(this)}ngAfterViewInit(){this._focusMonitor&&this._focusMonitor.monitor(this._elementRef,!1)}ngOnDestroy(){this._focusMonitor&&this._focusMonitor.stopMonitoring(this._elementRef),this._parentMenu&&this._parentMenu.removeItem&&this._parentMenu.removeItem(this),this._hovered.complete(),this._focused.complete()}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._elementRef.nativeElement}_checkDisabled(e){this.disabled&&(e.preventDefault(),e.stopPropagation())}_handleMouseEnter(){this._hovered.next(this)}getLabel(){let e=this._elementRef.nativeElement.cloneNode(!0),t=e.querySelectorAll("mat-icon, .material-icons");for(let n=0;n<t.length;n++)t[n].remove();return e.textContent?.trim()||""}_setHighlighted(e){this._highlighted=e,this._changeDetectorRef.markForCheck()}_setTriggersSubmenu(e){this._triggersSubmenu=e,this._changeDetectorRef.markForCheck()}_hasFocus(){return this._document&&this._document.activeElement===this._getHostElement()}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["","mat-menu-item",""]],hostAttrs:[1,"mat-mdc-menu-item","mat-focus-indicator"],hostVars:8,hostBindings:function(t,n){t&1&&A("click",function(r){return n._checkDisabled(r)})("mouseenter",function(){return n._handleMouseEnter()}),t&2&&(Z("role",n.role)("tabindex",n._getTabIndex())("aria-disabled",n.disabled)("disabled",n.disabled||null),p("mat-mdc-menu-item-highlighted",n._highlighted)("mat-mdc-menu-item-submenu-trigger",n._triggersSubmenu))},inputs:{role:"role",disabled:[2,"disabled","disabled",L],disableRipple:[2,"disableRipple","disableRipple",L]},exportAs:["matMenuItem"],ngContentSelectors:ab,decls:5,vars:3,consts:[[1,"mat-mdc-menu-item-text"],["matRipple","",1,"mat-mdc-menu-ripple",3,"matRippleDisabled","matRippleTrigger"],["viewBox","0 0 5 10","focusable","false","aria-hidden","true",1,"mat-mdc-menu-submenu-icon"],["points","0,0 5,5 0,10"]],template:function(t,n){t&1&&(ce(ob),U(0),s(1,"span",0),U(2,1),l(),v(3,"div",1),M(4,rb,2,0,":svg:svg",2)),t&2&&(c(3),C("matRippleDisabled",n.disableRipple||n.disabled)("matRippleTrigger",n._getHostElement()),c(),E(n._triggersSubmenu?4:-1))},dependencies:[ko],encapsulation:2})}return i})();var cb=new x("MatMenuContent");var db=new x("mat-menu-default-options",{providedIn:"root",factory:()=>({overlapTrigger:!1,xPosition:"after",yPosition:"below",backdropClass:"cdk-overlay-transparent-backdrop"})}),Tc="_mat-menu-enter",ys="_mat-menu-exit",yn=(()=>{class i{_elementRef=d(N);_changeDetectorRef=d(te);_injector=d(X);_keyManager;_xPosition;_yPosition;_firstItemFocusRef;_exitFallbackTimeout;_animationsDisabled=pe();_allItems;_directDescendantItems=new Zi;_classList={};_panelAnimationState="void";_animationDone=new I;_isAnimating=R(!1);parentMenu;direction;overlayPanelClass;backdropClass;ariaLabel;ariaLabelledby;ariaDescribedby;get xPosition(){return this._xPosition}set xPosition(e){this._xPosition=e,this.setPositionClasses()}get yPosition(){return this._yPosition}set yPosition(e){this._yPosition=e,this.setPositionClasses()}templateRef;items;lazyContent;overlapTrigger=!1;hasBackdrop;get panelClass(){return this._previousPanelClass}set panelClass(e){let t=this._previousPanelClass,n=V({},this._classList);t&&t.length&&t.split(" ").forEach(a=>{n[a]=!1}),this._previousPanelClass=e,e&&e.length&&(e.split(" ").forEach(a=>{n[a]=!0}),this._elementRef.nativeElement.className=""),this._classList=n}_previousPanelClass="";get classList(){return this.panelClass}set classList(e){this.panelClass=e}closed=new K;close=this.closed;panelId=d(be).getId("mat-menu-panel-");constructor(){let e=d(db);this.overlayPanelClass=e.overlayPanelClass||"",this._xPosition=e.xPosition,this._yPosition=e.yPosition,this.backdropClass=e.backdropClass,this.overlapTrigger=e.overlapTrigger,this.hasBackdrop=e.hasBackdrop}ngOnInit(){this.setPositionClasses()}ngAfterContentInit(){this._updateDirectDescendants(),this._keyManager=new cn(this._directDescendantItems).withWrap().withTypeAhead().withHomeAndEnd(),this._keyManager.tabOut.subscribe(()=>this.closed.emit("tab")),this._directDescendantItems.changes.pipe(ke(this._directDescendantItems),We(e=>$e(...e.map(t=>t._focused)))).subscribe(e=>this._keyManager.updateActiveItem(e)),this._directDescendantItems.changes.subscribe(e=>{let t=this._keyManager;if(this._panelAnimationState==="enter"&&t.activeItem?._hasFocus()){let n=e.toArray(),a=Math.max(0,Math.min(n.length-1,t.activeItemIndex||0));n[a]&&!n[a].disabled?t.setActiveItem(a):t.setNextItemActive()}})}ngOnDestroy(){this._keyManager?.destroy(),this._directDescendantItems.destroy(),this.closed.complete(),this._firstItemFocusRef?.destroy(),clearTimeout(this._exitFallbackTimeout)}_hovered(){return this._directDescendantItems.changes.pipe(ke(this._directDescendantItems),We(t=>$e(...t.map(n=>n._hovered))))}addItem(e){}removeItem(e){}_handleKeydown(e){let t=e.keyCode,n=this._keyManager;switch(t){case 27:Ge(e)||(e.preventDefault(),this.closed.emit("keydown"));break;case 37:this.parentMenu&&this.direction==="ltr"&&this.closed.emit("keydown");break;case 39:this.parentMenu&&this.direction==="rtl"&&this.closed.emit("keydown");break;default:(t===38||t===40)&&n.setFocusOrigin("keyboard"),n.onKeydown(e);return}}focusFirstItem(e="program"){this._firstItemFocusRef?.destroy(),this._firstItemFocusRef=Be(()=>{let t=this._resolvePanel();if(!t||!t.contains(document.activeElement)){let n=this._keyManager;n.setFocusOrigin(e).setFirstItemActive(),!n.activeItem&&t&&t.focus()}},{injector:this._injector})}resetActiveItem(){this._keyManager.setActiveItem(-1)}setElevation(e){}setPositionClasses(e=this.xPosition,t=this.yPosition){this._classList=Oe(V({},this._classList),{"mat-menu-before":e==="before","mat-menu-after":e==="after","mat-menu-above":t==="above","mat-menu-below":t==="below"}),this._changeDetectorRef.markForCheck()}_onAnimationDone(e){let t=e===ys;(t||e===Tc)&&(t&&(clearTimeout(this._exitFallbackTimeout),this._exitFallbackTimeout=void 0),this._animationDone.next(t?"void":"enter"),this._isAnimating.set(!1))}_onAnimationStart(e){(e===Tc||e===ys)&&this._isAnimating.set(!0)}_setIsOpen(e){if(this._panelAnimationState=e?"enter":"void",e){if(this._keyManager.activeItemIndex===0){let t=this._resolvePanel();t&&(t.scrollTop=0)}}else this._animationsDisabled||(this._exitFallbackTimeout=setTimeout(()=>this._onAnimationDone(ys),200));this._animationsDisabled&&setTimeout(()=>{this._onAnimationDone(e?Tc:ys)}),this._changeDetectorRef.markForCheck()}_updateDirectDescendants(){this._allItems.changes.pipe(ke(this._allItems)).subscribe(e=>{this._directDescendantItems.reset(e.filter(t=>t._parentMenu===this)),this._directDescendantItems.notifyOnChanges()})}_resolvePanel(){let e=null;return this._directDescendantItems.length&&(e=this._directDescendantItems.first._getHostElement().closest('[role="menu"]')),e}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-menu"]],contentQueries:function(t,n,a){if(t&1&&at(a,cb,5)(a,qn,5)(a,qn,4),t&2){let r;O(r=P())&&(n.lazyContent=r.first),O(r=P())&&(n._allItems=r),O(r=P())&&(n.items=r)}},viewQuery:function(t,n){if(t&1&&Me(Ye,5),t&2){let a;O(a=P())&&(n.templateRef=a.first)}},hostVars:3,hostBindings:function(t,n){t&2&&Z("aria-label",null)("aria-labelledby",null)("aria-describedby",null)},inputs:{backdropClass:"backdropClass",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],ariaDescribedby:[0,"aria-describedby","ariaDescribedby"],xPosition:"xPosition",yPosition:"yPosition",overlapTrigger:[2,"overlapTrigger","overlapTrigger",L],hasBackdrop:[2,"hasBackdrop","hasBackdrop",e=>e==null?null:L(e)],panelClass:[0,"class","panelClass"],classList:"classList"},outputs:{closed:"closed",close:"close"},exportAs:["matMenu"],features:[J([{provide:Ic,useExisting:i}])],ngContentSelectors:sb,decls:1,vars:0,consts:[["tabindex","-1","role","menu",1,"mat-mdc-menu-panel",3,"click","animationstart","animationend","animationcancel","id"],[1,"mat-mdc-menu-content"]],template:function(t,n){t&1&&(ce(),ir(0,lb,3,12,"ng-template"))},styles:[`mat-menu {
3355
3355
  display: none;
3356
3356
  }
3357
3357
 
@@ -3543,7 +3543,7 @@ input.mat-mdc-chip-input {
3543
3543
  position: absolute;
3544
3544
  pointer-events: none;
3545
3545
  }
3546
- `],encapsulation:2})}return i})(),mb=new C("mat-menu-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>yi(i)}});var To=new WeakMap,ub=(()=>{class i{_canHaveBackdrop;_element=d(N);_viewContainerRef=d(Xe);_menuItemInstance=d($n,{optional:!0,self:!0});_dir=d(qe,{optional:!0});_focusMonitor=d(Rt);_ngZone=d(H);_injector=d(X);_scrollStrategy=d(mb);_changeDetectorRef=d(te);_animationsDisabled=pe();_portal;_overlayRef=null;_menuOpen=!1;_closingActionsSubscription=De.EMPTY;_menuCloseSubscription=De.EMPTY;_pendingRemoval;_parentMaterialMenu;_parentInnerPadding;_openedBy=void 0;get _menu(){return this._menuInternal}set _menu(e){e!==this._menuInternal&&(this._menuInternal=e,this._menuCloseSubscription.unsubscribe(),e?(this._parentMaterialMenu,this._menuCloseSubscription=e.close.subscribe(t=>{this._destroyMenu(t),(t==="click"||t==="tab")&&this._parentMaterialMenu&&this._parentMaterialMenu.closed.emit(t)})):this._destroyMenu(),this._menuItemInstance?._setTriggersSubmenu(this._triggersSubmenu()))}_menuInternal=null;constructor(e){this._canHaveBackdrop=e;let t=d(Tc,{optional:!0});this._parentMaterialMenu=t instanceof yn?t:void 0}ngOnDestroy(){this._menu&&this._ownsMenu(this._menu)&&To.delete(this._menu),this._pendingRemoval?.unsubscribe(),this._menuCloseSubscription.unsubscribe(),this._closingActionsSubscription.unsubscribe(),this._overlayRef&&(this._overlayRef.dispose(),this._overlayRef=null)}get menuOpen(){return this._menuOpen}get dir(){return this._dir&&this._dir.value==="rtl"?"rtl":"ltr"}_triggersSubmenu(){return!!(this._menuItemInstance&&this._parentMaterialMenu&&this._menu)}_closeMenu(){this._menu?.close.emit()}_openMenu(e){if(this._triggerIsAriaDisabled())return;let t=this._menu;if(this._menuOpen||!t)return;this._pendingRemoval?.unsubscribe();let n=To.get(t);To.set(t,this),n&&n!==this&&n._closeMenu();let a=this._createOverlay(t),r=a.getConfig(),u=r.positionStrategy;this._setPosition(t,u),this._canHaveBackdrop?r.hasBackdrop=t.hasBackdrop==null?!this._triggersSubmenu():t.hasBackdrop:r.hasBackdrop=t.hasBackdrop??!1,a.hasAttached()||(a.attach(this._getPortal(t)),t.lazyContent?.attach(this.menuData)),this._closingActionsSubscription=this._menuClosingActions().subscribe(()=>this._closeMenu()),t.parentMenu=this._triggersSubmenu()?this._parentMaterialMenu:void 0,t.direction=this.dir,e&&t.focusFirstItem(this._openedBy||"program"),this._setIsMenuOpen(!0),t instanceof yn&&(t._setIsOpen(!0),t._directDescendantItems.changes.pipe(oe(t.close)).subscribe(()=>{u.withLockedPosition(!1).reapplyLastPosition(),u.withLockedPosition(!0)}))}focus(e,t){this._focusMonitor&&e?this._focusMonitor.focusVia(this._element,e,t):this._element.nativeElement.focus(t)}_destroyMenu(e){let t=this._overlayRef,n=this._menu;!t||!this.menuOpen||(this._closingActionsSubscription.unsubscribe(),this._pendingRemoval?.unsubscribe(),n instanceof yn&&this._ownsMenu(n)?(this._pendingRemoval=n._animationDone.pipe(ct(1)).subscribe(()=>{t.detach(),To.has(n)||n.lazyContent?.detach()}),n._setIsOpen(!1)):(t.detach(),n?.lazyContent?.detach()),n&&this._ownsMenu(n)&&To.delete(n),this.restoreFocus&&(e==="keydown"||!this._openedBy||!this._triggersSubmenu())&&this.focus(this._openedBy),this._openedBy=void 0,this._setIsMenuOpen(!1))}_setIsMenuOpen(e){e!==this._menuOpen&&(this._menuOpen=e,this._menuOpen?this.menuOpened.emit():this.menuClosed.emit(),this._triggersSubmenu()&&this._menuItemInstance._setHighlighted(e),this._changeDetectorRef.markForCheck())}_createOverlay(e){if(!this._overlayRef){let t=this._getOverlayConfig(e);this._subscribeToPositions(e,t.positionStrategy),this._overlayRef=qt(this._injector,t),this._overlayRef.keydownEvents().subscribe(n=>{this._menu instanceof yn&&this._menu._handleKeydown(n)})}return this._overlayRef}_getOverlayConfig(e){return new Wt({positionStrategy:$i(this._injector,this._getOverlayOrigin()).withLockedPosition().withGrowAfterOpen().withTransformOriginOn(".mat-menu-panel, .mat-mdc-menu-panel"),backdropClass:e.backdropClass||"cdk-overlay-transparent-backdrop",panelClass:e.overlayPanelClass,scrollStrategy:this._scrollStrategy(),direction:this._dir||"ltr",disableAnimations:this._animationsDisabled})}_subscribeToPositions(e,t){e.setPositionClasses&&t.positionChanges.subscribe(n=>{this._ngZone.run(()=>{let a=n.connectionPair.overlayX==="start"?"after":"before",r=n.connectionPair.overlayY==="top"?"below":"above";e.setPositionClasses(a,r)})})}_setPosition(e,t){let[n,a]=e.xPosition==="before"?["end","start"]:["start","end"],[r,u]=e.yPosition==="above"?["bottom","top"]:["top","bottom"],[h,g]=[r,u],[_,w]=[n,a],B=0;if(this._triggersSubmenu()){if(w=n=e.xPosition==="before"?"start":"end",a=_=n==="end"?"start":"end",this._parentMaterialMenu){if(this._parentInnerPadding==null){let G=this._parentMaterialMenu.items.first;this._parentInnerPadding=G?G._getHostElement().offsetTop:0}B=r==="bottom"?this._parentInnerPadding:-this._parentInnerPadding}}else e.overlapTrigger||(h=r==="top"?"bottom":"top",g=u==="top"?"bottom":"top");t.withPositions([{originX:n,originY:h,overlayX:_,overlayY:r,offsetY:B},{originX:a,originY:h,overlayX:w,overlayY:r,offsetY:B},{originX:n,originY:g,overlayX:_,overlayY:u,offsetY:-B},{originX:a,originY:g,overlayX:w,overlayY:u,offsetY:-B}])}_menuClosingActions(){let e=this._getOutsideClickStream(this._overlayRef),t=this._overlayRef.detachments(),n=this._parentMaterialMenu?this._parentMaterialMenu.closed:ge(),a=this._parentMaterialMenu?this._parentMaterialMenu._hovered().pipe(Ce(r=>this._menuOpen&&r!==this._menuItemInstance)):ge();return $e(e,n,a,t)}_getPortal(e){return(!this._portal||this._portal.templateRef!==e.templateRef)&&(this._portal=new Et(e.templateRef,this._viewContainerRef)),this._portal}_ownsMenu(e){return To.get(e)===this}_triggerIsAriaDisabled(){return L(this._element.nativeElement.getAttribute("aria-disabled"))}static \u0275fac=function(t){Za()};static \u0275dir=k({type:i})}return i})(),vs=(()=>{class i extends ub{_cleanupTouchstart;_hoverSubscription=De.EMPTY;get _deprecatedMatMenuTriggerFor(){return this.menu}set _deprecatedMatMenuTriggerFor(e){this.menu=e}get menu(){return this._menu}set menu(e){this._menu=e}menuData;restoreFocus=!0;menuOpened=new K;onMenuOpen=this.menuOpened;menuClosed=new K;onMenuClose=this.menuClosed;constructor(){super(!0);let e=d(ve);this._cleanupTouchstart=e.listen(this._element.nativeElement,"touchstart",t=>{Pn(t)||(this._openedBy="touch")},{passive:!0})}triggersSubmenu(){return super._triggersSubmenu()}toggleMenu(){return this.menuOpen?this.closeMenu():this.openMenu()}openMenu(){this._openMenu(!0)}closeMenu(){this._closeMenu()}updatePosition(){this._overlayRef?.updatePosition()}ngAfterContentInit(){this._handleHover()}ngOnDestroy(){super.ngOnDestroy(),this._cleanupTouchstart(),this._hoverSubscription.unsubscribe()}_getOverlayOrigin(){return this._element}_getOutsideClickStream(e){return e.backdropClick()}_handleMousedown(e){On(e)||(this._openedBy=e.button===0?"mouse":void 0,this.triggersSubmenu()&&e.preventDefault())}_handleKeydown(e){let t=e.keyCode;(t===13||t===32)&&(this._openedBy="keyboard"),this.triggersSubmenu()&&(t===39&&this.dir==="ltr"||t===37&&this.dir==="rtl")&&(this._openedBy="keyboard",this.openMenu())}_handleClick(e){this.triggersSubmenu()?(e.stopPropagation(),this.openMenu()):this.toggleMenu()}_handleHover(){this.triggersSubmenu()&&this._parentMaterialMenu&&(this._hoverSubscription=this._parentMaterialMenu._hovered().subscribe(e=>{e===this._menuItemInstance&&!e.disabled&&this._parentMaterialMenu?._panelAnimationState!=="void"&&(this._openedBy="mouse",this._openMenu(!1))}))}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","mat-menu-trigger-for",""],["","matMenuTriggerFor",""]],hostAttrs:[1,"mat-mdc-menu-trigger"],hostVars:3,hostBindings:function(t,n){t&1&&A("click",function(r){return n._handleClick(r)})("mousedown",function(r){return n._handleMousedown(r)})("keydown",function(r){return n._handleKeydown(r)}),t&2&&Z("aria-haspopup",n.menu?"menu":null)("aria-expanded",n.menuOpen)("aria-controls",n.menuOpen?n.menu?.panelId:null)},inputs:{_deprecatedMatMenuTriggerFor:[0,"mat-menu-trigger-for","_deprecatedMatMenuTriggerFor"],menu:[0,"matMenuTriggerFor","menu"],menuData:[0,"matMenuTriggerData","menuData"],restoreFocus:[0,"matMenuTriggerRestoreFocus","restoreFocus"]},outputs:{menuOpened:"menuOpened",onMenuOpen:"onMenuOpen",menuClosed:"menuClosed",onMenuClose:"onMenuClose"},exportAs:["matMenuTrigger"],features:[Q]})}return i})();var bs=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Ti,Nt,ee,_i]})}return i})();function hb(i,o){if(i&1){let e=Ue();s(0,"div",1)(1,"button",2),A("click",function(){xe(e);let n=D();return we(n.action())}),m(2),l()()}if(i&2){let e=D();c(2),he(" ",e.data.action," ")}}var pb=["label"];function fb(i,o){}var gb=Math.pow(2,31)-1,Pa=class{_overlayRef;instance;containerInstance;_afterDismissed=new I;_afterOpened=new I;_onAction=new I;_durationTimeoutId;_dismissedByAction=!1;constructor(o,e){this._overlayRef=e,this.containerInstance=o,o._onExit.subscribe(()=>this._finishDismiss())}dismiss(){this._afterDismissed.closed||this.containerInstance.exit(),clearTimeout(this._durationTimeoutId)}dismissWithAction(){this._onAction.closed||(this._dismissedByAction=!0,this._onAction.next(),this._onAction.complete(),this.dismiss()),clearTimeout(this._durationTimeoutId)}closeWithAction(){this.dismissWithAction()}_dismissAfter(o){this._durationTimeoutId=setTimeout(()=>this.dismiss(),Math.min(o,gb))}_open(){this._afterOpened.closed||(this._afterOpened.next(),this._afterOpened.complete())}_finishDismiss(){this._overlayRef.dispose(),this._onAction.closed||this._onAction.complete(),this._afterDismissed.next({dismissedByAction:this._dismissedByAction}),this._afterDismissed.complete(),this._dismissedByAction=!1}afterDismissed(){return this._afterDismissed}afterOpened(){return this.containerInstance._onEnter}onAction(){return this._onAction}},ep=new C("MatSnackBarData"),Io=class{politeness="polite";announcementMessage="";viewContainerRef;duration=0;panelClass;direction;data=null;horizontalPosition="center";verticalPosition="bottom"},_b=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matSnackBarLabel",""]],hostAttrs:[1,"mat-mdc-snack-bar-label","mdc-snackbar__label"]})}return i})(),vb=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matSnackBarActions",""]],hostAttrs:[1,"mat-mdc-snack-bar-actions","mdc-snackbar__actions"]})}return i})(),bb=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matSnackBarAction",""]],hostAttrs:[1,"mat-mdc-snack-bar-action","mdc-snackbar__action"]})}return i})(),yb=(()=>{class i{snackBarRef=d(Pa);data=d(ep);action(){this.snackBarRef.dismissWithAction()}get hasAction(){return!!this.data.action}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["simple-snack-bar"]],hostAttrs:[1,"mat-mdc-simple-snack-bar"],exportAs:["matSnackBar"],decls:3,vars:2,consts:[["matSnackBarLabel",""],["matSnackBarActions",""],["matButton","","matSnackBarAction","",3,"click"]],template:function(t,n){t&1&&(s(0,"div",0),m(1),l(),M(2,hb,3,1,"div",1)),t&2&&(c(),he(" ",n.data.message,`
3546
+ `],encapsulation:2})}return i})(),mb=new x("mat-menu-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>yi(i)}});var Ro=new WeakMap,ub=(()=>{class i{_canHaveBackdrop;_element=d(N);_viewContainerRef=d(Xe);_menuItemInstance=d(qn,{optional:!0,self:!0});_dir=d(qe,{optional:!0});_focusMonitor=d(Rt);_ngZone=d(H);_injector=d(X);_scrollStrategy=d(mb);_changeDetectorRef=d(te);_animationsDisabled=pe();_portal;_overlayRef=null;_menuOpen=!1;_closingActionsSubscription=De.EMPTY;_menuCloseSubscription=De.EMPTY;_pendingRemoval;_parentMaterialMenu;_parentInnerPadding;_openedBy=void 0;get _menu(){return this._menuInternal}set _menu(e){e!==this._menuInternal&&(this._menuInternal=e,this._menuCloseSubscription.unsubscribe(),e?(this._parentMaterialMenu,this._menuCloseSubscription=e.close.subscribe(t=>{this._destroyMenu(t),(t==="click"||t==="tab")&&this._parentMaterialMenu&&this._parentMaterialMenu.closed.emit(t)})):this._destroyMenu(),this._menuItemInstance?._setTriggersSubmenu(this._triggersSubmenu()))}_menuInternal=null;constructor(e){this._canHaveBackdrop=e;let t=d(Ic,{optional:!0});this._parentMaterialMenu=t instanceof yn?t:void 0}ngOnDestroy(){this._menu&&this._ownsMenu(this._menu)&&Ro.delete(this._menu),this._pendingRemoval?.unsubscribe(),this._menuCloseSubscription.unsubscribe(),this._closingActionsSubscription.unsubscribe(),this._overlayRef&&(this._overlayRef.dispose(),this._overlayRef=null)}get menuOpen(){return this._menuOpen}get dir(){return this._dir&&this._dir.value==="rtl"?"rtl":"ltr"}_triggersSubmenu(){return!!(this._menuItemInstance&&this._parentMaterialMenu&&this._menu)}_closeMenu(){this._menu?.close.emit()}_openMenu(e){if(this._triggerIsAriaDisabled())return;let t=this._menu;if(this._menuOpen||!t)return;this._pendingRemoval?.unsubscribe();let n=Ro.get(t);Ro.set(t,this),n&&n!==this&&n._closeMenu();let a=this._createOverlay(t),r=a.getConfig(),u=r.positionStrategy;this._setPosition(t,u),this._canHaveBackdrop?r.hasBackdrop=t.hasBackdrop==null?!this._triggersSubmenu():t.hasBackdrop:r.hasBackdrop=t.hasBackdrop??!1,a.hasAttached()||(a.attach(this._getPortal(t)),t.lazyContent?.attach(this.menuData)),this._closingActionsSubscription=this._menuClosingActions().subscribe(()=>this._closeMenu()),t.parentMenu=this._triggersSubmenu()?this._parentMaterialMenu:void 0,t.direction=this.dir,e&&t.focusFirstItem(this._openedBy||"program"),this._setIsMenuOpen(!0),t instanceof yn&&(t._setIsOpen(!0),t._directDescendantItems.changes.pipe(oe(t.close)).subscribe(()=>{u.withLockedPosition(!1).reapplyLastPosition(),u.withLockedPosition(!0)}))}focus(e,t){this._focusMonitor&&e?this._focusMonitor.focusVia(this._element,e,t):this._element.nativeElement.focus(t)}_destroyMenu(e){let t=this._overlayRef,n=this._menu;!t||!this.menuOpen||(this._closingActionsSubscription.unsubscribe(),this._pendingRemoval?.unsubscribe(),n instanceof yn&&this._ownsMenu(n)?(this._pendingRemoval=n._animationDone.pipe(ct(1)).subscribe(()=>{t.detach(),Ro.has(n)||n.lazyContent?.detach()}),n._setIsOpen(!1)):(t.detach(),n?.lazyContent?.detach()),n&&this._ownsMenu(n)&&Ro.delete(n),this.restoreFocus&&(e==="keydown"||!this._openedBy||!this._triggersSubmenu())&&this.focus(this._openedBy),this._openedBy=void 0,this._setIsMenuOpen(!1))}_setIsMenuOpen(e){e!==this._menuOpen&&(this._menuOpen=e,this._menuOpen?this.menuOpened.emit():this.menuClosed.emit(),this._triggersSubmenu()&&this._menuItemInstance._setHighlighted(e),this._changeDetectorRef.markForCheck())}_createOverlay(e){if(!this._overlayRef){let t=this._getOverlayConfig(e);this._subscribeToPositions(e,t.positionStrategy),this._overlayRef=qt(this._injector,t),this._overlayRef.keydownEvents().subscribe(n=>{this._menu instanceof yn&&this._menu._handleKeydown(n)})}return this._overlayRef}_getOverlayConfig(e){return new Wt({positionStrategy:$i(this._injector,this._getOverlayOrigin()).withLockedPosition().withGrowAfterOpen().withTransformOriginOn(".mat-menu-panel, .mat-mdc-menu-panel"),backdropClass:e.backdropClass||"cdk-overlay-transparent-backdrop",panelClass:e.overlayPanelClass,scrollStrategy:this._scrollStrategy(),direction:this._dir||"ltr",disableAnimations:this._animationsDisabled})}_subscribeToPositions(e,t){e.setPositionClasses&&t.positionChanges.subscribe(n=>{this._ngZone.run(()=>{let a=n.connectionPair.overlayX==="start"?"after":"before",r=n.connectionPair.overlayY==="top"?"below":"above";e.setPositionClasses(a,r)})})}_setPosition(e,t){let[n,a]=e.xPosition==="before"?["end","start"]:["start","end"],[r,u]=e.yPosition==="above"?["bottom","top"]:["top","bottom"],[h,g]=[r,u],[_,w]=[n,a],B=0;if(this._triggersSubmenu()){if(w=n=e.xPosition==="before"?"start":"end",a=_=n==="end"?"start":"end",this._parentMaterialMenu){if(this._parentInnerPadding==null){let G=this._parentMaterialMenu.items.first;this._parentInnerPadding=G?G._getHostElement().offsetTop:0}B=r==="bottom"?this._parentInnerPadding:-this._parentInnerPadding}}else e.overlapTrigger||(h=r==="top"?"bottom":"top",g=u==="top"?"bottom":"top");t.withPositions([{originX:n,originY:h,overlayX:_,overlayY:r,offsetY:B},{originX:a,originY:h,overlayX:w,overlayY:r,offsetY:B},{originX:n,originY:g,overlayX:_,overlayY:u,offsetY:-B},{originX:a,originY:g,overlayX:w,overlayY:u,offsetY:-B}])}_menuClosingActions(){let e=this._getOutsideClickStream(this._overlayRef),t=this._overlayRef.detachments(),n=this._parentMaterialMenu?this._parentMaterialMenu.closed:ge(),a=this._parentMaterialMenu?this._parentMaterialMenu._hovered().pipe(Ce(r=>this._menuOpen&&r!==this._menuItemInstance)):ge();return $e(e,n,a,t)}_getPortal(e){return(!this._portal||this._portal.templateRef!==e.templateRef)&&(this._portal=new Et(e.templateRef,this._viewContainerRef)),this._portal}_ownsMenu(e){return Ro.get(e)===this}_triggerIsAriaDisabled(){return L(this._element.nativeElement.getAttribute("aria-disabled"))}static \u0275fac=function(t){er()};static \u0275dir=k({type:i})}return i})(),Cs=(()=>{class i extends ub{_cleanupTouchstart;_hoverSubscription=De.EMPTY;get _deprecatedMatMenuTriggerFor(){return this.menu}set _deprecatedMatMenuTriggerFor(e){this.menu=e}get menu(){return this._menu}set menu(e){this._menu=e}menuData;restoreFocus=!0;menuOpened=new K;onMenuOpen=this.menuOpened;menuClosed=new K;onMenuClose=this.menuClosed;constructor(){super(!0);let e=d(ve);this._cleanupTouchstart=e.listen(this._element.nativeElement,"touchstart",t=>{Nn(t)||(this._openedBy="touch")},{passive:!0})}triggersSubmenu(){return super._triggersSubmenu()}toggleMenu(){return this.menuOpen?this.closeMenu():this.openMenu()}openMenu(){this._openMenu(!0)}closeMenu(){this._closeMenu()}updatePosition(){this._overlayRef?.updatePosition()}ngAfterContentInit(){this._handleHover()}ngOnDestroy(){super.ngOnDestroy(),this._cleanupTouchstart(),this._hoverSubscription.unsubscribe()}_getOverlayOrigin(){return this._element}_getOutsideClickStream(e){return e.backdropClick()}_handleMousedown(e){Fn(e)||(this._openedBy=e.button===0?"mouse":void 0,this.triggersSubmenu()&&e.preventDefault())}_handleKeydown(e){let t=e.keyCode;(t===13||t===32)&&(this._openedBy="keyboard"),this.triggersSubmenu()&&(t===39&&this.dir==="ltr"||t===37&&this.dir==="rtl")&&(this._openedBy="keyboard",this.openMenu())}_handleClick(e){this.triggersSubmenu()?(e.stopPropagation(),this.openMenu()):this.toggleMenu()}_handleHover(){this.triggersSubmenu()&&this._parentMaterialMenu&&(this._hoverSubscription=this._parentMaterialMenu._hovered().subscribe(e=>{e===this._menuItemInstance&&!e.disabled&&this._parentMaterialMenu?._panelAnimationState!=="void"&&(this._openedBy="mouse",this._openMenu(!1))}))}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","mat-menu-trigger-for",""],["","matMenuTriggerFor",""]],hostAttrs:[1,"mat-mdc-menu-trigger"],hostVars:3,hostBindings:function(t,n){t&1&&A("click",function(r){return n._handleClick(r)})("mousedown",function(r){return n._handleMousedown(r)})("keydown",function(r){return n._handleKeydown(r)}),t&2&&Z("aria-haspopup",n.menu?"menu":null)("aria-expanded",n.menuOpen)("aria-controls",n.menuOpen?n.menu?.panelId:null)},inputs:{_deprecatedMatMenuTriggerFor:[0,"mat-menu-trigger-for","_deprecatedMatMenuTriggerFor"],menu:[0,"matMenuTriggerFor","menu"],menuData:[0,"matMenuTriggerData","menuData"],restoreFocus:[0,"matMenuTriggerRestoreFocus","restoreFocus"]},outputs:{menuOpened:"menuOpened",onMenuOpen:"onMenuOpen",menuClosed:"menuClosed",onMenuClose:"onMenuClose"},exportAs:["matMenuTrigger"],features:[Q]})}return i})();var xs=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Ti,Nt,ee,_i]})}return i})();function hb(i,o){if(i&1){let e=Ue();s(0,"div",1)(1,"button",2),A("click",function(){xe(e);let n=D();return we(n.action())}),m(2),l()()}if(i&2){let e=D();c(2),he(" ",e.data.action," ")}}var pb=["label"];function fb(i,o){}var gb=Math.pow(2,31)-1,Na=class{_overlayRef;instance;containerInstance;_afterDismissed=new I;_afterOpened=new I;_onAction=new I;_durationTimeoutId;_dismissedByAction=!1;constructor(o,e){this._overlayRef=e,this.containerInstance=o,o._onExit.subscribe(()=>this._finishDismiss())}dismiss(){this._afterDismissed.closed||this.containerInstance.exit(),clearTimeout(this._durationTimeoutId)}dismissWithAction(){this._onAction.closed||(this._dismissedByAction=!0,this._onAction.next(),this._onAction.complete(),this.dismiss()),clearTimeout(this._durationTimeoutId)}closeWithAction(){this.dismissWithAction()}_dismissAfter(o){this._durationTimeoutId=setTimeout(()=>this.dismiss(),Math.min(o,gb))}_open(){this._afterOpened.closed||(this._afterOpened.next(),this._afterOpened.complete())}_finishDismiss(){this._overlayRef.dispose(),this._onAction.closed||this._onAction.complete(),this._afterDismissed.next({dismissedByAction:this._dismissedByAction}),this._afterDismissed.complete(),this._dismissedByAction=!1}afterDismissed(){return this._afterDismissed}afterOpened(){return this.containerInstance._onEnter}onAction(){return this._onAction}},ep=new x("MatSnackBarData"),Oo=class{politeness="polite";announcementMessage="";viewContainerRef;duration=0;panelClass;direction;data=null;horizontalPosition="center";verticalPosition="bottom"},_b=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matSnackBarLabel",""]],hostAttrs:[1,"mat-mdc-snack-bar-label","mdc-snackbar__label"]})}return i})(),vb=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matSnackBarActions",""]],hostAttrs:[1,"mat-mdc-snack-bar-actions","mdc-snackbar__actions"]})}return i})(),bb=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matSnackBarAction",""]],hostAttrs:[1,"mat-mdc-snack-bar-action","mdc-snackbar__action"]})}return i})(),yb=(()=>{class i{snackBarRef=d(Na);data=d(ep);action(){this.snackBarRef.dismissWithAction()}get hasAction(){return!!this.data.action}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["simple-snack-bar"]],hostAttrs:[1,"mat-mdc-simple-snack-bar"],exportAs:["matSnackBar"],decls:3,vars:2,consts:[["matSnackBarLabel",""],["matSnackBarActions",""],["matButton","","matSnackBarAction","",3,"click"]],template:function(t,n){t&1&&(s(0,"div",0),m(1),l(),M(2,hb,3,1,"div",1)),t&2&&(c(),he(" ",n.data.message,`
3547
3547
  `),c(),E(n.hasAction?2:-1))},dependencies:[it,_b,vb,bb],styles:[`.mat-mdc-simple-snack-bar {
3548
3548
  display: flex;
3549
3549
  }
@@ -3551,7 +3551,7 @@ input.mat-mdc-chip-input {
3551
3551
  max-height: 50vh;
3552
3552
  overflow: auto;
3553
3553
  }
3554
- `],encapsulation:2})}return i})(),Ic="_mat-snack-bar-enter",Rc="_mat-snack-bar-exit",Cb=(()=>{class i extends _n{_ngZone=d(H);_elementRef=d(N);_changeDetectorRef=d(te);_platform=d(le);_animationsDisabled=pe();snackBarConfig=d(Io);_document=d($);_trackedModals=new Set;_enterFallback;_exitFallback;_injector=d(X);_announceDelay=150;_announceTimeoutId;_destroyed=!1;_portalOutlet;_onAnnounce=new I;_onExit=new I;_onEnter=new I;_animationState="void";_live;_label;_role;_liveElementId=d(be).getId("mat-snack-bar-container-live-");constructor(){super();let e=this.snackBarConfig;e.politeness==="assertive"&&!e.announcementMessage?this._live="assertive":e.politeness==="off"?this._live="off":this._live="polite",this._platform.FIREFOX&&(this._live==="polite"&&(this._role="status"),this._live==="assertive"&&(this._role="alert"))}attachComponentPortal(e){this._assertNotAttached();let t=this._portalOutlet.attachComponentPortal(e);return this._afterPortalAttached(),t}attachTemplatePortal(e){this._assertNotAttached();let t=this._portalOutlet.attachTemplatePortal(e);return this._afterPortalAttached(),t}attachDomPortal=e=>{this._assertNotAttached();let t=this._portalOutlet.attachDomPortal(e);return this._afterPortalAttached(),t};onAnimationEnd(e){e===Rc?this._completeExit():e===Ic&&(clearTimeout(this._enterFallback),this._ngZone.run(()=>{this._onEnter.next(),this._onEnter.complete()}))}enter(){this._destroyed||(this._animationState="visible",this._changeDetectorRef.markForCheck(),this._changeDetectorRef.detectChanges(),this._screenReaderAnnounce(),this._animationsDisabled?Be(()=>{this._ngZone.run(()=>queueMicrotask(()=>this.onAnimationEnd(Ic)))},{injector:this._injector}):(clearTimeout(this._enterFallback),this._enterFallback=setTimeout(()=>{this._elementRef.nativeElement.classList.add("mat-snack-bar-fallback-visible"),this.onAnimationEnd(Ic)},200)))}exit(){return this._destroyed?ge(void 0):(this._ngZone.run(()=>{this._animationState="hidden",this._changeDetectorRef.markForCheck(),this._elementRef.nativeElement.setAttribute("mat-exit",""),clearTimeout(this._announceTimeoutId),this._animationsDisabled?Be(()=>{this._ngZone.run(()=>queueMicrotask(()=>this.onAnimationEnd(Rc)))},{injector:this._injector}):(clearTimeout(this._exitFallback),this._exitFallback=setTimeout(()=>this.onAnimationEnd(Rc),200))}),this._onExit)}ngOnDestroy(){this._destroyed=!0,this._clearFromModals(),this._completeExit()}_completeExit(){clearTimeout(this._exitFallback),queueMicrotask(()=>{this._onExit.next(),this._onExit.complete()})}_afterPortalAttached(){let e=this._elementRef.nativeElement,t=this.snackBarConfig.panelClass;t&&(Array.isArray(t)?t.forEach(r=>e.classList.add(r)):e.classList.add(t)),this._exposeToModals();let n=this._label.nativeElement,a="mdc-snackbar__label";n.classList.toggle(a,!n.querySelector(`.${a}`))}_exposeToModals(){let e=this._liveElementId,t=this._document.querySelectorAll('body > .cdk-overlay-container [aria-modal="true"]');for(let n=0;n<t.length;n++){let a=t[n],r=a.getAttribute("aria-owns");this._trackedModals.add(a),r?r.indexOf(e)===-1&&a.setAttribute("aria-owns",r+" "+e):a.setAttribute("aria-owns",e)}}_clearFromModals(){this._trackedModals.forEach(e=>{let t=e.getAttribute("aria-owns");if(t){let n=t.replace(this._liveElementId,"").trim();n.length>0?e.setAttribute("aria-owns",n):e.removeAttribute("aria-owns")}}),this._trackedModals.clear()}_assertNotAttached(){this._portalOutlet.hasAttached()}_screenReaderAnnounce(){this._announceTimeoutId||this._ngZone.runOutsideAngular(()=>{this._announceTimeoutId=setTimeout(()=>{if(this._destroyed)return;let e=this._elementRef.nativeElement,t=e.querySelector("[aria-hidden]"),n=e.querySelector("[aria-live]");if(t&&n){let a=null;this._platform.isBrowser&&document.activeElement instanceof HTMLElement&&t.contains(document.activeElement)&&(a=document.activeElement),t.removeAttribute("aria-hidden"),n.appendChild(t),a?.focus(),this._onAnnounce.next(),this._onAnnounce.complete()}},this._announceDelay)})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-snack-bar-container"]],viewQuery:function(t,n){if(t&1&&Me(Ri,7)(pb,7),t&2){let a;O(a=P())&&(n._portalOutlet=a.first),O(a=P())&&(n._label=a.first)}},hostAttrs:[1,"mdc-snackbar","mat-mdc-snack-bar-container"],hostVars:6,hostBindings:function(t,n){t&1&&A("animationend",function(r){return n.onAnimationEnd(r.animationName)})("animationcancel",function(r){return n.onAnimationEnd(r.animationName)}),t&2&&p("mat-snack-bar-container-enter",n._animationState==="visible")("mat-snack-bar-container-exit",n._animationState==="hidden")("mat-snack-bar-container-animations-enabled",!n._animationsDisabled)},features:[Q],decls:6,vars:3,consts:[["label",""],[1,"mdc-snackbar__surface","mat-mdc-snackbar-surface"],[1,"mat-mdc-snack-bar-label"],["aria-hidden","true"],["cdkPortalOutlet",""]],template:function(t,n){t&1&&(s(0,"div",1)(1,"div",2,0)(3,"div",3),ze(4,fb,0,0,"ng-template",4),l(),v(5,"div"),l()()),t&2&&(c(5),Z("aria-live",n._live)("role",n._role)("id",n._liveElementId))},dependencies:[Ri],styles:[`@keyframes _mat-snack-bar-enter {
3554
+ `],encapsulation:2})}return i})(),Rc="_mat-snack-bar-enter",Oc="_mat-snack-bar-exit",Cb=(()=>{class i extends _n{_ngZone=d(H);_elementRef=d(N);_changeDetectorRef=d(te);_platform=d(le);_animationsDisabled=pe();snackBarConfig=d(Oo);_document=d(W);_trackedModals=new Set;_enterFallback;_exitFallback;_injector=d(X);_announceDelay=150;_announceTimeoutId;_destroyed=!1;_portalOutlet;_onAnnounce=new I;_onExit=new I;_onEnter=new I;_animationState="void";_live;_label;_role;_liveElementId=d(be).getId("mat-snack-bar-container-live-");constructor(){super();let e=this.snackBarConfig;e.politeness==="assertive"&&!e.announcementMessage?this._live="assertive":e.politeness==="off"?this._live="off":this._live="polite",this._platform.FIREFOX&&(this._live==="polite"&&(this._role="status"),this._live==="assertive"&&(this._role="alert"))}attachComponentPortal(e){this._assertNotAttached();let t=this._portalOutlet.attachComponentPortal(e);return this._afterPortalAttached(),t}attachTemplatePortal(e){this._assertNotAttached();let t=this._portalOutlet.attachTemplatePortal(e);return this._afterPortalAttached(),t}attachDomPortal=e=>{this._assertNotAttached();let t=this._portalOutlet.attachDomPortal(e);return this._afterPortalAttached(),t};onAnimationEnd(e){e===Oc?this._completeExit():e===Rc&&(clearTimeout(this._enterFallback),this._ngZone.run(()=>{this._onEnter.next(),this._onEnter.complete()}))}enter(){this._destroyed||(this._animationState="visible",this._changeDetectorRef.markForCheck(),this._changeDetectorRef.detectChanges(),this._screenReaderAnnounce(),this._animationsDisabled?Be(()=>{this._ngZone.run(()=>queueMicrotask(()=>this.onAnimationEnd(Rc)))},{injector:this._injector}):(clearTimeout(this._enterFallback),this._enterFallback=setTimeout(()=>{this._elementRef.nativeElement.classList.add("mat-snack-bar-fallback-visible"),this.onAnimationEnd(Rc)},200)))}exit(){return this._destroyed?ge(void 0):(this._ngZone.run(()=>{this._animationState="hidden",this._changeDetectorRef.markForCheck(),this._elementRef.nativeElement.setAttribute("mat-exit",""),clearTimeout(this._announceTimeoutId),this._animationsDisabled?Be(()=>{this._ngZone.run(()=>queueMicrotask(()=>this.onAnimationEnd(Oc)))},{injector:this._injector}):(clearTimeout(this._exitFallback),this._exitFallback=setTimeout(()=>this.onAnimationEnd(Oc),200))}),this._onExit)}ngOnDestroy(){this._destroyed=!0,this._clearFromModals(),this._completeExit()}_completeExit(){clearTimeout(this._exitFallback),queueMicrotask(()=>{this._onExit.next(),this._onExit.complete()})}_afterPortalAttached(){let e=this._elementRef.nativeElement,t=this.snackBarConfig.panelClass;t&&(Array.isArray(t)?t.forEach(r=>e.classList.add(r)):e.classList.add(t)),this._exposeToModals();let n=this._label.nativeElement,a="mdc-snackbar__label";n.classList.toggle(a,!n.querySelector(`.${a}`))}_exposeToModals(){let e=this._liveElementId,t=this._document.querySelectorAll('body > .cdk-overlay-container [aria-modal="true"]');for(let n=0;n<t.length;n++){let a=t[n],r=a.getAttribute("aria-owns");this._trackedModals.add(a),r?r.indexOf(e)===-1&&a.setAttribute("aria-owns",r+" "+e):a.setAttribute("aria-owns",e)}}_clearFromModals(){this._trackedModals.forEach(e=>{let t=e.getAttribute("aria-owns");if(t){let n=t.replace(this._liveElementId,"").trim();n.length>0?e.setAttribute("aria-owns",n):e.removeAttribute("aria-owns")}}),this._trackedModals.clear()}_assertNotAttached(){this._portalOutlet.hasAttached()}_screenReaderAnnounce(){this._announceTimeoutId||this._ngZone.runOutsideAngular(()=>{this._announceTimeoutId=setTimeout(()=>{if(this._destroyed)return;let e=this._elementRef.nativeElement,t=e.querySelector("[aria-hidden]"),n=e.querySelector("[aria-live]");if(t&&n){let a=null;this._platform.isBrowser&&document.activeElement instanceof HTMLElement&&t.contains(document.activeElement)&&(a=document.activeElement),t.removeAttribute("aria-hidden"),n.appendChild(t),a?.focus(),this._onAnnounce.next(),this._onAnnounce.complete()}},this._announceDelay)})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-snack-bar-container"]],viewQuery:function(t,n){if(t&1&&Me(Ri,7)(pb,7),t&2){let a;O(a=P())&&(n._portalOutlet=a.first),O(a=P())&&(n._label=a.first)}},hostAttrs:[1,"mdc-snackbar","mat-mdc-snack-bar-container"],hostVars:6,hostBindings:function(t,n){t&1&&A("animationend",function(r){return n.onAnimationEnd(r.animationName)})("animationcancel",function(r){return n.onAnimationEnd(r.animationName)}),t&2&&p("mat-snack-bar-container-enter",n._animationState==="visible")("mat-snack-bar-container-exit",n._animationState==="hidden")("mat-snack-bar-container-animations-enabled",!n._animationsDisabled)},features:[Q],decls:6,vars:3,consts:[["label",""],[1,"mdc-snackbar__surface","mat-mdc-snackbar-surface"],[1,"mat-mdc-snack-bar-label"],["aria-hidden","true"],["cdkPortalOutlet",""]],template:function(t,n){t&1&&(s(0,"div",1)(1,"div",2,0)(3,"div",3),ze(4,fb,0,0,"ng-template",4),l(),v(5,"div"),l()()),t&2&&(c(5),Z("aria-live",n._live)("role",n._role)("id",n._liveElementId))},dependencies:[Ri],styles:[`@keyframes _mat-snack-bar-enter {
3555
3555
  from {
3556
3556
  transform: scale(0.8);
3557
3557
  opacity: 0;
@@ -3667,7 +3667,7 @@ input.mat-mdc-chip-input {
3667
3667
  .mat-mdc-snack-bar-container .mat-mdc-button.mat-mdc-snack-bar-action:not(:disabled) .mat-ripple-element {
3668
3668
  opacity: 0.1;
3669
3669
  }
3670
- `],encapsulation:2,changeDetection:1})}return i})(),xb=new C("mat-snack-bar-default-options",{providedIn:"root",factory:()=>new Io}),ys=(()=>{class i{_live=d(ra);_injector=d(X);_breakpointObserver=d(In);_parentSnackBar=d(i,{optional:!0,skipSelf:!0});_defaultConfig=d(xb);_animationsDisabled=pe();_snackBarRefAtThisLevel=null;simpleSnackBarComponent=yb;snackBarContainerComponent=Cb;handsetCssClass="mat-mdc-snack-bar-handset";get _openedSnackBarRef(){let e=this._parentSnackBar;return e?e._openedSnackBarRef:this._snackBarRefAtThisLevel}set _openedSnackBarRef(e){this._parentSnackBar?this._parentSnackBar._openedSnackBarRef=e:this._snackBarRefAtThisLevel=e}openFromComponent(e,t){return this._attach(e,t)}openFromTemplate(e,t){return this._attach(e,t)}open(e,t="",n){let a=V(V({},this._defaultConfig),n);return a.data={message:e,action:t},a.announcementMessage===e&&(a.announcementMessage=void 0),this.openFromComponent(this.simpleSnackBarComponent,a)}dismiss(){this._openedSnackBarRef&&this._openedSnackBarRef.dismiss()}ngOnDestroy(){this._snackBarRefAtThisLevel&&this._snackBarRefAtThisLevel.dismiss()}_attachSnackBarContainer(e,t){let n=t&&t.viewContainerRef&&t.viewContainerRef.injector,a=X.create({parent:n||this._injector,providers:[{provide:Io,useValue:t}]}),r=new bi(this.snackBarContainerComponent,t.viewContainerRef,a),u=e.attach(r);return u.instance.snackBarConfig=t,u.instance}_attach(e,t){let n=V(V(V({},new Io),this._defaultConfig),t),a=this._createOverlay(n),r=this._attachSnackBarContainer(a,n),u=new Pa(r,a);if(e instanceof Ye){let h=new Et(e,null,{$implicit:n.data,snackBarRef:u});u.instance=r.attachTemplatePortal(h)}else{let h=this._createInjector(n,u),g=new bi(e,void 0,h),_=r.attachComponentPortal(g);u.instance=_.instance}return this._breakpointObserver.observe(Sr.HandsetPortrait).pipe(oe(a.detachments())).subscribe(h=>{a.overlayElement.classList.toggle(this.handsetCssClass,h.matches)}),n.announcementMessage&&r._onAnnounce.subscribe(()=>{this._live.announce(n.announcementMessage,n.politeness)}),this._animateSnackBar(u,n),this._openedSnackBarRef=u,this._openedSnackBarRef}_animateSnackBar(e,t){e.afterDismissed().subscribe(()=>{this._openedSnackBarRef==e&&(this._openedSnackBarRef=null),t.announcementMessage&&this._live.clear()}),t.duration&&t.duration>0&&e.afterOpened().subscribe(()=>e._dismissAfter(t.duration)),this._openedSnackBarRef?(this._openedSnackBarRef.afterDismissed().subscribe(()=>{e.containerInstance.enter()}),this._openedSnackBarRef.dismiss()):e.containerInstance.enter()}_createOverlay(e){let t=new Wt;t.direction=e.direction;let n=vn(this._injector),a=e.direction==="rtl",r=e.horizontalPosition==="left"||e.horizontalPosition==="start"&&!a||e.horizontalPosition==="end"&&a,u=!r&&e.horizontalPosition!=="center";return r?n.left("0"):u?n.right("0"):n.centerHorizontally(),e.verticalPosition==="top"?n.top("0"):n.bottom("0"),t.positionStrategy=n,t.disableAnimations=this._animationsDisabled,qt(this._injector,t)}_createInjector(e,t){let n=e&&e.viewContainerRef&&e.viewContainerRef.injector;return X.create({parent:n||this._injector,providers:[{provide:Pa,useValue:t},{provide:ep,useValue:e.data}]})}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var _t=(()=>{class i{constructor(){this.http=d(Qt),this.url="/api/services"}fetchServices(){return this.http.get(this.url)}control(e,t){return this.http.post(`${this.url}/control`,{name:e,action:t})}fetchConfigs(){return this.http.get(`${this.url}/config`)}getConfig(e){return this.http.get(`${this.url}/config/${e}`)}saveConfig(e){return this.http.post(`${this.url}/config`,e)}deleteConfig(e){return this.http.delete(`${this.url}/config/${e}`)}fetchArchivedConfigs(){return this.http.get(`${this.url}/archive`)}archiveService(e){return this.http.post(`${this.url}/config/${e}/archive`,{})}restoreService(e){return this.http.post(`${this.url}/config/${e}/restore`,{})}listAvailableServices(){return this.http.get(`${this.url}/managed/available`)}listManagedServices(){return this.http.get(`${this.url}/managed`)}addManagedService(e){return this.http.post(`${this.url}/managed`,{name:e})}removeManagedService(e){return this.http.delete(`${this.url}/managed`,{body:{name:e}})}fetchJournal(e,t=100){return this.http.get(`${this.url}/journal/${e}`,{params:{lines:t}})}getLlamaAutocomplete(e,t,n){let a={type:e,query:t};return n&&(a.binary=n),this.http.get(`${this.url}/llama/autocomplete`,{params:a})}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var tp="journal-selected-service",Cs=(()=>{class i{constructor(){this.selectedService=R(this.readSaved())}select(e){this.selectedService.set(e),localStorage.setItem(tp,JSON.stringify(e))}readSaved(){let e=localStorage.getItem(tp);if(e===null)return null;try{return JSON.parse(e)}catch(t){return null}}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var xs=(()=>{class i{constructor(){this.serviceService=d(_t),this.services=R([]),this.loaded=R(!1),this.error=R(null)}refresh(){return ye(this,null,function*(){try{let e=yield Te(this.serviceService.fetchServices());this.services.set(e),this.error.set(null),this.loaded.set(!0)}catch(e){this.error.set(e instanceof Error?e.message:String(e)),console.error("[ServiceListService] refresh error:",e)}})}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var ip=(()=>{class i{_animationsDisabled=pe();state="unchecked";disabled=!1;appearance="full";static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-pseudo-checkbox"]],hostAttrs:[1,"mat-pseudo-checkbox"],hostVars:12,hostBindings:function(t,n){t&2&&p("mat-pseudo-checkbox-indeterminate",n.state==="indeterminate")("mat-pseudo-checkbox-checked",n.state==="checked")("mat-pseudo-checkbox-disabled",n.disabled)("mat-pseudo-checkbox-minimal",n.appearance==="minimal")("mat-pseudo-checkbox-full",n.appearance==="full")("_mat-animation-noopable",n._animationsDisabled)},inputs:{state:"state",disabled:"disabled",appearance:"appearance"},decls:0,vars:0,template:function(t,n){},styles:[`.mat-pseudo-checkbox {
3670
+ `],encapsulation:2,changeDetection:1})}return i})(),xb=new x("mat-snack-bar-default-options",{providedIn:"root",factory:()=>new Oo}),ws=(()=>{class i{_live=d(la);_injector=d(X);_breakpointObserver=d(On);_parentSnackBar=d(i,{optional:!0,skipSelf:!0});_defaultConfig=d(xb);_animationsDisabled=pe();_snackBarRefAtThisLevel=null;simpleSnackBarComponent=yb;snackBarContainerComponent=Cb;handsetCssClass="mat-mdc-snack-bar-handset";get _openedSnackBarRef(){let e=this._parentSnackBar;return e?e._openedSnackBarRef:this._snackBarRefAtThisLevel}set _openedSnackBarRef(e){this._parentSnackBar?this._parentSnackBar._openedSnackBarRef=e:this._snackBarRefAtThisLevel=e}openFromComponent(e,t){return this._attach(e,t)}openFromTemplate(e,t){return this._attach(e,t)}open(e,t="",n){let a=V(V({},this._defaultConfig),n);return a.data={message:e,action:t},a.announcementMessage===e&&(a.announcementMessage=void 0),this.openFromComponent(this.simpleSnackBarComponent,a)}dismiss(){this._openedSnackBarRef&&this._openedSnackBarRef.dismiss()}ngOnDestroy(){this._snackBarRefAtThisLevel&&this._snackBarRefAtThisLevel.dismiss()}_attachSnackBarContainer(e,t){let n=t&&t.viewContainerRef&&t.viewContainerRef.injector,a=X.create({parent:n||this._injector,providers:[{provide:Oo,useValue:t}]}),r=new bi(this.snackBarContainerComponent,t.viewContainerRef,a),u=e.attach(r);return u.instance.snackBarConfig=t,u.instance}_attach(e,t){let n=V(V(V({},new Oo),this._defaultConfig),t),a=this._createOverlay(n),r=this._attachSnackBarContainer(a,n),u=new Na(r,a);if(e instanceof Ye){let h=new Et(e,null,{$implicit:n.data,snackBarRef:u});u.instance=r.attachTemplatePortal(h)}else{let h=this._createInjector(n,u),g=new bi(e,void 0,h),_=r.attachComponentPortal(g);u.instance=_.instance}return this._breakpointObserver.observe(Ar.HandsetPortrait).pipe(oe(a.detachments())).subscribe(h=>{a.overlayElement.classList.toggle(this.handsetCssClass,h.matches)}),n.announcementMessage&&r._onAnnounce.subscribe(()=>{this._live.announce(n.announcementMessage,n.politeness)}),this._animateSnackBar(u,n),this._openedSnackBarRef=u,this._openedSnackBarRef}_animateSnackBar(e,t){e.afterDismissed().subscribe(()=>{this._openedSnackBarRef==e&&(this._openedSnackBarRef=null),t.announcementMessage&&this._live.clear()}),t.duration&&t.duration>0&&e.afterOpened().subscribe(()=>e._dismissAfter(t.duration)),this._openedSnackBarRef?(this._openedSnackBarRef.afterDismissed().subscribe(()=>{e.containerInstance.enter()}),this._openedSnackBarRef.dismiss()):e.containerInstance.enter()}_createOverlay(e){let t=new Wt;t.direction=e.direction;let n=vn(this._injector),a=e.direction==="rtl",r=e.horizontalPosition==="left"||e.horizontalPosition==="start"&&!a||e.horizontalPosition==="end"&&a,u=!r&&e.horizontalPosition!=="center";return r?n.left("0"):u?n.right("0"):n.centerHorizontally(),e.verticalPosition==="top"?n.top("0"):n.bottom("0"),t.positionStrategy=n,t.disableAnimations=this._animationsDisabled,qt(this._injector,t)}_createInjector(e,t){let n=e&&e.viewContainerRef&&e.viewContainerRef.injector;return X.create({parent:n||this._injector,providers:[{provide:Na,useValue:t},{provide:ep,useValue:e.data}]})}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Y({token:i,factory:i.\u0275fac})}return i})();var _t=(()=>{class i{constructor(){this.http=d(Qt),this.url="/api/services"}fetchServices(){return this.http.get(this.url)}control(e,t){return this.http.post(`${this.url}/control`,{name:e,action:t})}fetchConfigs(){return this.http.get(`${this.url}/config`)}getConfig(e){return this.http.get(`${this.url}/config/${e}`)}saveConfig(e){return this.http.post(`${this.url}/config`,e)}deleteConfig(e){return this.http.delete(`${this.url}/config/${e}`)}fetchArchivedConfigs(){return this.http.get(`${this.url}/archive`)}archiveService(e){return this.http.post(`${this.url}/config/${e}/archive`,{})}restoreService(e){return this.http.post(`${this.url}/config/${e}/restore`,{})}listAvailableServices(){return this.http.get(`${this.url}/managed/available`)}listManagedServices(){return this.http.get(`${this.url}/managed`)}addManagedService(e){return this.http.post(`${this.url}/managed`,{name:e})}removeManagedService(e){return this.http.delete(`${this.url}/managed`,{body:{name:e}})}fetchJournal(e,t=100){return this.http.get(`${this.url}/journal/${e}`,{params:{lines:t}})}getLlamaAutocomplete(e,t,n){let a={type:e,query:t};return n&&(a.binary=n),this.http.get(`${this.url}/llama/autocomplete`,{params:a})}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var tp="journal-selected-service",Ds=(()=>{class i{constructor(){this.selectedService=R(this.readSaved())}select(e){this.selectedService.set(e),localStorage.setItem(tp,JSON.stringify(e))}readSaved(){let e=localStorage.getItem(tp);if(e===null)return null;try{return JSON.parse(e)}catch(t){return null}}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var ks=(()=>{class i{constructor(){this.serviceService=d(_t),this.services=R([]),this.loaded=R(!1),this.error=R(null)}refresh(){return ye(this,null,function*(){try{let e=yield Te(this.serviceService.fetchServices());this.services.set(e),this.error.set(null),this.loaded.set(!0)}catch(e){this.error.set(e instanceof Error?e.message:String(e)),console.error("[ServiceListService] refresh error:",e)}})}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var ip=(()=>{class i{_animationsDisabled=pe();state="unchecked";disabled=!1;appearance="full";static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-pseudo-checkbox"]],hostAttrs:[1,"mat-pseudo-checkbox"],hostVars:12,hostBindings:function(t,n){t&2&&p("mat-pseudo-checkbox-indeterminate",n.state==="indeterminate")("mat-pseudo-checkbox-checked",n.state==="checked")("mat-pseudo-checkbox-disabled",n.disabled)("mat-pseudo-checkbox-minimal",n.appearance==="minimal")("mat-pseudo-checkbox-full",n.appearance==="full")("_mat-animation-noopable",n._animationsDisabled)},inputs:{state:"state",disabled:"disabled",appearance:"appearance"},decls:0,vars:0,template:function(t,n){},styles:[`.mat-pseudo-checkbox {
3671
3671
  border-radius: 2px;
3672
3672
  cursor: pointer;
3673
3673
  display: inline-block;
@@ -3773,7 +3773,7 @@ input.mat-mdc-chip-input {
3773
3773
  top: 6px;
3774
3774
  width: 12px;
3775
3775
  }
3776
- `],encapsulation:2})}return i})();var wb=["text"],Db=[[["mat-icon"]],"*"],kb=["mat-icon","*"];function Sb(i,o){if(i&1&&v(0,"mat-pseudo-checkbox",1),i&2){let e=D();x("disabled",e.disabled)("state",e.selected?"checked":"unchecked")}}function Mb(i,o){if(i&1&&v(0,"mat-pseudo-checkbox",3),i&2){let e=D();x("disabled",e.disabled)}}function Eb(i,o){if(i&1&&(s(0,"span",4),m(1),l()),i&2){let e=D();c(),he("(",e.group.label,")")}}var Na=new C("MAT_OPTION_PARENT_COMPONENT"),La=new C("MatOptgroup");var Fa=class{source;isUserInput;constructor(o,e=!1){this.source=o,this.isUserInput=e}},vt=(()=>{class i{_element=d(N);_changeDetectorRef=d(te);_parent=d(Na,{optional:!0});group=d(La,{optional:!0});_signalDisableRipple=!1;_selected=!1;_active=!1;_mostRecentViewValue="";get multiple(){return this._parent&&this._parent.multiple}get selected(){return this._selected}value;id=d(be).getId("mat-option-");get disabled(){return this.group&&this.group.disabled||this._disabled()}set disabled(e){this._disabled.set(e)}_disabled=R(!1);get disableRipple(){return this._signalDisableRipple?this._parent.disableRipple():!!this._parent?.disableRipple}get hideSingleSelectionIndicator(){return!!(this._parent&&this._parent.hideSingleSelectionIndicator)}onSelectionChange=new K;_text;_stateChanges=new I;constructor(){let e=d(Fe);e.load(Mt),e.load(rn),this._signalDisableRipple=!!this._parent&&Xi(this._parent.disableRipple)}get active(){return this._active}get viewValue(){return(this._text?.nativeElement.textContent||"").trim()}select(e=!0){this._selected||(this._selected=!0,this._changeDetectorRef.markForCheck(),e&&this._emitSelectionChangeEvent())}deselect(e=!0){this._selected&&(this._selected=!1,this._changeDetectorRef.markForCheck(),e&&this._emitSelectionChangeEvent())}focus(e,t){let n=this._getHostElement();typeof n.focus=="function"&&n.focus(t)}setActiveStyles(){this._active||(this._active=!0,this._changeDetectorRef.markForCheck())}setInactiveStyles(){this._active&&(this._active=!1,this._changeDetectorRef.markForCheck())}getLabel(){return this.viewValue}_handleKeydown(e){(e.keyCode===13||e.keyCode===32)&&!Ge(e)&&(this._selectViaInteraction(),e.preventDefault())}_selectViaInteraction(){this.disabled||(this._selected=this.multiple?!this._selected:!0,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent(!0))}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._element.nativeElement}ngAfterViewChecked(){if(this._selected){let e=this.viewValue;e!==this._mostRecentViewValue&&(this._mostRecentViewValue&&this._stateChanges.next(),this._mostRecentViewValue=e)}}ngOnDestroy(){this._stateChanges.complete()}_emitSelectionChangeEvent(e=!1){this.onSelectionChange.emit(new Fa(this,e))}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-option"]],viewQuery:function(t,n){if(t&1&&Me(wb,7),t&2){let a;O(a=P())&&(n._text=a.first)}},hostAttrs:["role","option",1,"mat-mdc-option","mdc-list-item"],hostVars:11,hostBindings:function(t,n){t&1&&A("click",function(){return n._selectViaInteraction()})("keydown",function(r){return n._handleKeydown(r)}),t&2&&(dt("id",n.id),Z("aria-selected",n.selected)("aria-disabled",n.disabled.toString()),p("mdc-list-item--selected",n.selected)("mat-mdc-option-multiple",n.multiple)("mat-mdc-option-active",n.active)("mdc-list-item--disabled",n.disabled))},inputs:{value:"value",id:"id",disabled:[2,"disabled","disabled",L]},outputs:{onSelectionChange:"onSelectionChange"},exportAs:["matOption"],ngContentSelectors:kb,decls:8,vars:5,consts:[["text",""],["aria-hidden","true",1,"mat-mdc-option-pseudo-checkbox",3,"disabled","state"],[1,"mdc-list-item__primary-text"],["state","checked","aria-hidden","true","appearance","minimal",1,"mat-mdc-option-pseudo-checkbox",3,"disabled"],[1,"cdk-visually-hidden"],["aria-hidden","true","mat-ripple","",1,"mat-mdc-option-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled"]],template:function(t,n){t&1&&(ce(Db),M(0,Sb,1,2,"mat-pseudo-checkbox",1),U(1),s(2,"span",2,0),U(4,1),l(),M(5,Mb,1,1,"mat-pseudo-checkbox",3),M(6,Eb,2,1,"span",4),v(7,"div",5)),t&2&&(E(n.multiple?0:-1),c(5),E(!n.multiple&&n.selected&&!n.hideSingleSelectionIndicator?5:-1),c(),E(n.group&&n.group._inert?6:-1),c(),x("matRippleTrigger",n._getHostElement())("matRippleDisabled",n.disabled||n.disableRipple))},dependencies:[ip,wo],styles:[`.mat-mdc-option {
3776
+ `],encapsulation:2})}return i})();var wb=["text"],Db=[[["mat-icon"]],"*"],kb=["mat-icon","*"];function Sb(i,o){if(i&1&&v(0,"mat-pseudo-checkbox",1),i&2){let e=D();C("disabled",e.disabled)("state",e.selected?"checked":"unchecked")}}function Mb(i,o){if(i&1&&v(0,"mat-pseudo-checkbox",3),i&2){let e=D();C("disabled",e.disabled)}}function Eb(i,o){if(i&1&&(s(0,"span",4),m(1),l()),i&2){let e=D();c(),he("(",e.group.label,")")}}var Va=new x("MAT_OPTION_PARENT_COMPONENT"),Ba=new x("MatOptgroup");var La=class{source;isUserInput;constructor(o,e=!1){this.source=o,this.isUserInput=e}},vt=(()=>{class i{_element=d(N);_changeDetectorRef=d(te);_parent=d(Va,{optional:!0});group=d(Ba,{optional:!0});_signalDisableRipple=!1;_selected=!1;_active=!1;_mostRecentViewValue="";get multiple(){return this._parent&&this._parent.multiple}get selected(){return this._selected}value;id=d(be).getId("mat-option-");get disabled(){return this.group&&this.group.disabled||this._disabled()}set disabled(e){this._disabled.set(e)}_disabled=R(!1);get disableRipple(){return this._signalDisableRipple?this._parent.disableRipple():!!this._parent?.disableRipple}get hideSingleSelectionIndicator(){return!!(this._parent&&this._parent.hideSingleSelectionIndicator)}onSelectionChange=new K;_text;_stateChanges=new I;constructor(){let e=d(Ne);e.load(Mt),e.load(rn),this._signalDisableRipple=!!this._parent&&Xi(this._parent.disableRipple)}get active(){return this._active}get viewValue(){return(this._text?.nativeElement.textContent||"").trim()}select(e=!0){this._selected||(this._selected=!0,this._changeDetectorRef.markForCheck(),e&&this._emitSelectionChangeEvent())}deselect(e=!0){this._selected&&(this._selected=!1,this._changeDetectorRef.markForCheck(),e&&this._emitSelectionChangeEvent())}focus(e,t){let n=this._getHostElement();typeof n.focus=="function"&&n.focus(t)}setActiveStyles(){this._active||(this._active=!0,this._changeDetectorRef.markForCheck())}setInactiveStyles(){this._active&&(this._active=!1,this._changeDetectorRef.markForCheck())}getLabel(){return this.viewValue}_handleKeydown(e){(e.keyCode===13||e.keyCode===32)&&!Ge(e)&&(this._selectViaInteraction(),e.preventDefault())}_selectViaInteraction(){this.disabled||(this._selected=this.multiple?!this._selected:!0,this._changeDetectorRef.markForCheck(),this._emitSelectionChangeEvent(!0))}_getTabIndex(){return this.disabled?"-1":"0"}_getHostElement(){return this._element.nativeElement}ngAfterViewChecked(){if(this._selected){let e=this.viewValue;e!==this._mostRecentViewValue&&(this._mostRecentViewValue&&this._stateChanges.next(),this._mostRecentViewValue=e)}}ngOnDestroy(){this._stateChanges.complete()}_emitSelectionChangeEvent(e=!1){this.onSelectionChange.emit(new La(this,e))}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-option"]],viewQuery:function(t,n){if(t&1&&Me(wb,7),t&2){let a;O(a=P())&&(n._text=a.first)}},hostAttrs:["role","option",1,"mat-mdc-option","mdc-list-item"],hostVars:11,hostBindings:function(t,n){t&1&&A("click",function(){return n._selectViaInteraction()})("keydown",function(r){return n._handleKeydown(r)}),t&2&&(dt("id",n.id),Z("aria-selected",n.selected)("aria-disabled",n.disabled.toString()),p("mdc-list-item--selected",n.selected)("mat-mdc-option-multiple",n.multiple)("mat-mdc-option-active",n.active)("mdc-list-item--disabled",n.disabled))},inputs:{value:"value",id:"id",disabled:[2,"disabled","disabled",L]},outputs:{onSelectionChange:"onSelectionChange"},exportAs:["matOption"],ngContentSelectors:kb,decls:8,vars:5,consts:[["text",""],["aria-hidden","true",1,"mat-mdc-option-pseudo-checkbox",3,"disabled","state"],[1,"mdc-list-item__primary-text"],["state","checked","aria-hidden","true","appearance","minimal",1,"mat-mdc-option-pseudo-checkbox",3,"disabled"],[1,"cdk-visually-hidden"],["aria-hidden","true","mat-ripple","",1,"mat-mdc-option-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled"]],template:function(t,n){t&1&&(ce(Db),M(0,Sb,1,2,"mat-pseudo-checkbox",1),U(1),s(2,"span",2,0),U(4,1),l(),M(5,Mb,1,1,"mat-pseudo-checkbox",3),M(6,Eb,2,1,"span",4),v(7,"div",5)),t&2&&(E(n.multiple?0:-1),c(5),E(!n.multiple&&n.selected&&!n.hideSingleSelectionIndicator?5:-1),c(),E(n.group&&n.group._inert?6:-1),c(),C("matRippleTrigger",n._getHostElement())("matRippleDisabled",n.disabled||n.disableRipple))},dependencies:[ip,ko],styles:[`.mat-mdc-option {
3777
3777
  -webkit-user-select: none;
3778
3778
  user-select: none;
3779
3779
  -moz-osx-font-smoothing: grayscale;
@@ -3894,7 +3894,7 @@ input.mat-mdc-chip-input {
3894
3894
  .mat-mdc-option-active .mat-focus-indicator::before {
3895
3895
  content: "";
3896
3896
  }
3897
- `],encapsulation:2})}return i})();function ws(i,o,e){if(e.length){let t=o.toArray(),n=e.toArray(),a=0;for(let r=0;r<i+1;r++)t[r].group&&t[r].group===n[a]&&a++;return a}return 0}function Ds(i,o,e,t){return i<e?i:i+o>e+t?Math.max(0,i-t+o):e}var ks=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();var Ro=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Ti,ks,vt,ee]})}return i})();var Ab=["panel"],Tb=["*"];function Ib(i,o){if(i&1&&(Ie(0,"div",1,0),U(2),je()),i&2){let e=o.id,t=D();et(t._classList),p("mat-mdc-autocomplete-visible",t.showPanel)("mat-mdc-autocomplete-hidden",!t.showPanel)("mat-autocomplete-panel-animations-enabled",!t._animationsDisabled)("mat-primary",t._color==="primary")("mat-accent",t._color==="accent")("mat-warn",t._color==="warn"),dt("id",t.id),Z("aria-label",t.ariaLabel||null)("aria-labelledby",t._getPanelAriaLabelledby(e))}}var Oc=class{source;option;constructor(o,e){this.source=o,this.option=e}},np=new C("mat-autocomplete-default-options",{providedIn:"root",factory:()=>({autoActiveFirstOption:!1,autoSelectActiveOption:!1,hideSingleSelectionIndicator:!1,requireSelection:!1,hasBackdrop:!1})}),Cn=(()=>{class i{_changeDetectorRef=d(te);_elementRef=d(N);_defaults=d(np);_animationsDisabled=pe();_activeOptionChanges=De.EMPTY;_keyManager;showPanel=!1;get isOpen(){return this._isOpen&&this.showPanel}_isOpen=!1;_latestOpeningTrigger;_setColor(e){this._color=e,this._changeDetectorRef.markForCheck()}_color;template;panel;options;optionGroups;ariaLabel;ariaLabelledby;displayWith=null;autoActiveFirstOption;autoSelectActiveOption;requireSelection;panelWidth;disableRipple=!1;optionSelected=new K;opened=new K;closed=new K;optionActivated=new K;set classList(e){this._classList=e,this._elementRef.nativeElement.className=""}_classList;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(e){this._hideSingleSelectionIndicator=e,this._syncParentProperties()}_hideSingleSelectionIndicator;_syncParentProperties(){if(this.options)for(let e of this.options)e._changeDetectorRef.markForCheck()}id=d(be).getId("mat-autocomplete-");inertGroups;constructor(){let e=d(le);this.inertGroups=e?.SAFARI||!1,this.autoActiveFirstOption=!!this._defaults.autoActiveFirstOption,this.autoSelectActiveOption=!!this._defaults.autoSelectActiveOption,this.requireSelection=!!this._defaults.requireSelection,this._hideSingleSelectionIndicator=this._defaults.hideSingleSelectionIndicator??!1}ngAfterContentInit(){this._keyManager=new Ln(this.options).withWrap().skipPredicate(this._skipPredicate),this._activeOptionChanges=this._keyManager.change.subscribe(e=>{this.isOpen&&this.optionActivated.emit({source:this,option:this.options.toArray()[e]||null})}),this._setVisibility()}ngOnDestroy(){this._keyManager?.destroy(),this._activeOptionChanges.unsubscribe()}_setScrollTop(e){this.panel&&(this.panel.nativeElement.scrollTop=e)}_getScrollTop(){return this.panel?this.panel.nativeElement.scrollTop:0}_setVisibility(){this.showPanel=!!this.options?.length,this._changeDetectorRef.markForCheck()}_emitSelectEvent(e){let t=new Oc(this,e);this.optionSelected.emit(t)}_getPanelAriaLabelledby(e){if(this.ariaLabel)return null;let t=e?e+" ":"";return this.ariaLabelledby?t+this.ariaLabelledby:e}_skipPredicate(){return!1}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-autocomplete"]],contentQueries:function(t,n,a){if(t&1&&at(a,vt,5)(a,La,5),t&2){let r;O(r=P())&&(n.options=r),O(r=P())&&(n.optionGroups=r)}},viewQuery:function(t,n){if(t&1&&Me(Ye,7)(Ab,5),t&2){let a;O(a=P())&&(n.template=a.first),O(a=P())&&(n.panel=a.first)}},hostAttrs:[1,"mat-mdc-autocomplete"],inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],displayWith:"displayWith",autoActiveFirstOption:[2,"autoActiveFirstOption","autoActiveFirstOption",L],autoSelectActiveOption:[2,"autoSelectActiveOption","autoSelectActiveOption",L],requireSelection:[2,"requireSelection","requireSelection",L],panelWidth:"panelWidth",disableRipple:[2,"disableRipple","disableRipple",L],classList:[0,"class","classList"],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",L]},outputs:{optionSelected:"optionSelected",opened:"opened",closed:"closed",optionActivated:"optionActivated"},exportAs:["matAutocomplete"],features:[J([{provide:Na,useExisting:i}])],ngContentSelectors:Tb,decls:1,vars:0,consts:[["panel",""],["role","listbox",1,"mat-mdc-autocomplete-panel","mdc-menu-surface","mdc-menu-surface--open",3,"id"]],template:function(t,n){t&1&&(ce(),Ja(0,Ib,3,17,"ng-template"))},styles:[`div.mat-mdc-autocomplete-panel {
3897
+ `],encapsulation:2})}return i})();function Ss(i,o,e){if(e.length){let t=o.toArray(),n=e.toArray(),a=0;for(let r=0;r<i+1;r++)t[r].group&&t[r].group===n[a]&&a++;return a}return 0}function Ms(i,o,e,t){return i<e?i:i+o>e+t?Math.max(0,i-t+o):e}var Es=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();var Po=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Ti,Es,vt,ee]})}return i})();var Ab=["panel"],Tb=["*"];function Ib(i,o){if(i&1&&(Ie(0,"div",1,0),U(2),je()),i&2){let e=o.id,t=D();et(t._classList),p("mat-mdc-autocomplete-visible",t.showPanel)("mat-mdc-autocomplete-hidden",!t.showPanel)("mat-autocomplete-panel-animations-enabled",!t._animationsDisabled)("mat-primary",t._color==="primary")("mat-accent",t._color==="accent")("mat-warn",t._color==="warn"),dt("id",t.id),Z("aria-label",t.ariaLabel||null)("aria-labelledby",t._getPanelAriaLabelledby(e))}}var Pc=class{source;option;constructor(o,e){this.source=o,this.option=e}},np=new x("mat-autocomplete-default-options",{providedIn:"root",factory:()=>({autoActiveFirstOption:!1,autoSelectActiveOption:!1,hideSingleSelectionIndicator:!1,requireSelection:!1,hasBackdrop:!1})}),Cn=(()=>{class i{_changeDetectorRef=d(te);_elementRef=d(N);_defaults=d(np);_animationsDisabled=pe();_activeOptionChanges=De.EMPTY;_keyManager;showPanel=!1;get isOpen(){return this._isOpen&&this.showPanel}_isOpen=!1;_latestOpeningTrigger;_setColor(e){this._color=e,this._changeDetectorRef.markForCheck()}_color;template;panel;options;optionGroups;ariaLabel;ariaLabelledby;displayWith=null;autoActiveFirstOption;autoSelectActiveOption;requireSelection;panelWidth;disableRipple=!1;optionSelected=new K;opened=new K;closed=new K;optionActivated=new K;set classList(e){this._classList=e,this._elementRef.nativeElement.className=""}_classList;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(e){this._hideSingleSelectionIndicator=e,this._syncParentProperties()}_hideSingleSelectionIndicator;_syncParentProperties(){if(this.options)for(let e of this.options)e._changeDetectorRef.markForCheck()}id=d(be).getId("mat-autocomplete-");inertGroups;constructor(){let e=d(le);this.inertGroups=e?.SAFARI||!1,this.autoActiveFirstOption=!!this._defaults.autoActiveFirstOption,this.autoSelectActiveOption=!!this._defaults.autoSelectActiveOption,this.requireSelection=!!this._defaults.requireSelection,this._hideSingleSelectionIndicator=this._defaults.hideSingleSelectionIndicator??!1}ngAfterContentInit(){this._keyManager=new Bn(this.options).withWrap().skipPredicate(this._skipPredicate),this._activeOptionChanges=this._keyManager.change.subscribe(e=>{this.isOpen&&this.optionActivated.emit({source:this,option:this.options.toArray()[e]||null})}),this._setVisibility()}ngOnDestroy(){this._keyManager?.destroy(),this._activeOptionChanges.unsubscribe()}_setScrollTop(e){this.panel&&(this.panel.nativeElement.scrollTop=e)}_getScrollTop(){return this.panel?this.panel.nativeElement.scrollTop:0}_setVisibility(){this.showPanel=!!this.options?.length,this._changeDetectorRef.markForCheck()}_emitSelectEvent(e){let t=new Pc(this,e);this.optionSelected.emit(t)}_getPanelAriaLabelledby(e){if(this.ariaLabel)return null;let t=e?e+" ":"";return this.ariaLabelledby?t+this.ariaLabelledby:e}_skipPredicate(){return!1}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-autocomplete"]],contentQueries:function(t,n,a){if(t&1&&at(a,vt,5)(a,Ba,5),t&2){let r;O(r=P())&&(n.options=r),O(r=P())&&(n.optionGroups=r)}},viewQuery:function(t,n){if(t&1&&Me(Ye,7)(Ab,5),t&2){let a;O(a=P())&&(n.template=a.first),O(a=P())&&(n.panel=a.first)}},hostAttrs:[1,"mat-mdc-autocomplete"],inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],displayWith:"displayWith",autoActiveFirstOption:[2,"autoActiveFirstOption","autoActiveFirstOption",L],autoSelectActiveOption:[2,"autoSelectActiveOption","autoSelectActiveOption",L],requireSelection:[2,"requireSelection","requireSelection",L],panelWidth:"panelWidth",disableRipple:[2,"disableRipple","disableRipple",L],classList:[0,"class","classList"],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",L]},outputs:{optionSelected:"optionSelected",opened:"opened",closed:"closed",optionActivated:"optionActivated"},exportAs:["matAutocomplete"],features:[J([{provide:Va,useExisting:i}])],ngContentSelectors:Tb,decls:1,vars:0,consts:[["panel",""],["role","listbox",1,"mat-mdc-autocomplete-panel","mdc-menu-surface","mdc-menu-surface--open",3,"id"]],template:function(t,n){t&1&&(ce(),ir(0,Ib,3,17,"ng-template"))},styles:[`div.mat-mdc-autocomplete-panel {
3898
3898
  width: 100%;
3899
3899
  max-height: 256px;
3900
3900
  visibility: hidden;
@@ -3948,7 +3948,7 @@ div.mat-mdc-autocomplete-panel.mat-mdc-autocomplete-hidden,
3948
3948
  mat-autocomplete {
3949
3949
  display: none;
3950
3950
  }
3951
- `],encapsulation:2})}return i})();var Rb={provide:Mi,useExisting:nt(()=>Wi),multi:!0};var Ob=new C("mat-autocomplete-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>yi(i)}}),Wi=(()=>{class i{_environmentInjector=d(mi);_element=d(N);_injector=d(X);_viewContainerRef=d(Xe);_zone=d(H);_changeDetectorRef=d(te);_dir=d(qe,{optional:!0});_formField=d(Bn,{optional:!0,host:!0});_viewportRuler=d(Gt);_scrollStrategy=d(Ob);_renderer=d(ve);_animationsDisabled=pe();_defaults=d(np,{optional:!0});_overlayRef=null;_portal;_componentDestroyed=!1;_initialized=new I;_keydownSubscription;_outsideClickSubscription;_cleanupWindowBlur;_previousValue=null;_valueOnAttach=null;_valueOnLastKeydown=null;_positionStrategy;_manuallyFloatingLabel=!1;_closingActionsSubscription;_viewportSubscription=De.EMPTY;_breakpointObserver=d(In);_handsetLandscapeSubscription=De.EMPTY;_canOpenOnNextFocus=!0;_valueBeforeAutoSelection;_pendingAutoselectedOption=null;_closeKeyEventStream=new I;_overlayPanelClass=Vi(this._defaults?.overlayPanelClass||[]);_windowBlurHandler=()=>{this._canOpenOnNextFocus=this.panelOpen||!this._hasFocus()};_onChange=()=>{};_onTouched=()=>{};autocomplete;position="auto";connectedTo;autocompleteAttribute="off";autocompleteDisabled=!1;_aboveClass="mat-mdc-autocomplete-panel-above";ngAfterViewInit(){this._initialized.next(),this._initialized.complete(),this._cleanupWindowBlur=this._renderer.listen("window","blur",this._windowBlurHandler)}ngOnChanges(e){e.position&&this._positionStrategy&&(this._setStrategyPositions(this._positionStrategy),this.panelOpen&&this._overlayRef.updatePosition())}ngOnDestroy(){this._cleanupWindowBlur?.(),this._handsetLandscapeSubscription.unsubscribe(),this._viewportSubscription.unsubscribe(),this._componentDestroyed=!0,this._destroyPanel(),this._closeKeyEventStream.complete()}get panelOpen(){return this._overlayAttached&&this.autocomplete.showPanel}_overlayAttached=!1;openPanel(){this._openPanelInternal()}closePanel(){this._resetLabel(),this._overlayAttached&&(this.panelOpen&&this._zone.run(()=>{this.autocomplete.closed.emit()}),this.autocomplete._latestOpeningTrigger===this&&(this.autocomplete._isOpen=!1,this.autocomplete._latestOpeningTrigger=null),this._overlayAttached=!1,this._pendingAutoselectedOption=null,this._overlayRef&&this._overlayRef.hasAttached()&&(this._overlayRef.detach(),this._closingActionsSubscription.unsubscribe()),this._updatePanelState(),this._componentDestroyed||this._changeDetectorRef.detectChanges())}updatePosition(){this._overlayAttached&&this._overlayRef.updatePosition()}get panelClosingActions(){return $e(this.optionSelections,this.autocomplete._keyManager.tabOut.pipe(Ce(()=>this._overlayAttached)),this._closeKeyEventStream,this._getOutsideClickStream(),this._overlayRef?this._overlayRef.detachments().pipe(Ce(()=>this._overlayAttached)):ge()).pipe(Pe(e=>e instanceof Fa?e:null))}optionSelections=Yi(()=>{let e=this.autocomplete?this.autocomplete.options:null;return e?e.changes.pipe(ke(e),We(()=>$e(...e.map(t=>t.onSelectionChange)))):this._initialized.pipe(We(()=>this.optionSelections))});get activeOption(){return this.autocomplete&&this.autocomplete._keyManager?this.autocomplete._keyManager.activeItem:null}_getOutsideClickStream(){return new yt(e=>{let t=a=>{let r=rt(a),u=this._formField?this._formField.getConnectedOverlayOrigin().nativeElement:null,h=this.connectedTo?this.connectedTo.elementRef.nativeElement:null;this._overlayAttached&&r!==this._element.nativeElement&&!this._hasFocus()&&(!u||!u.contains(r))&&(!h||!h.contains(r))&&this._overlayRef&&!this._overlayRef.overlayElement.contains(r)&&e.next(a)},n=[this._renderer.listen("document","click",t),this._renderer.listen("document","auxclick",t),this._renderer.listen("document","touchend",t)];return()=>{n.forEach(a=>a())}})}writeValue(e){Promise.resolve(null).then(()=>this._assignOptionValue(e))}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this._element.nativeElement.disabled=e}_handleKeydown(e){let t=e,n=t.keyCode,a=Ge(t);if(n===27&&!a&&t.preventDefault(),this._valueOnLastKeydown=this._element.nativeElement.value,this.activeOption&&n===13&&this.panelOpen&&!a)this.activeOption._selectViaInteraction(),this._resetActiveItem(),t.preventDefault();else if(this.autocomplete){let r=this.autocomplete._keyManager.activeItem,u=n===38||n===40;n===9||u&&!a&&this.panelOpen?this.autocomplete._keyManager.onKeydown(t):u&&this._canOpen()&&this._openPanelInternal(this._valueOnLastKeydown),(u||this.autocomplete._keyManager.activeItem!==r)&&(this._scrollToOption(this.autocomplete._keyManager.activeItemIndex||0),this.autocomplete.autoSelectActiveOption&&this.activeOption&&(this._pendingAutoselectedOption||(this._valueBeforeAutoSelection=this._valueOnLastKeydown),this._pendingAutoselectedOption=this.activeOption,this._assignOptionValue(this.activeOption.value)))}}_handleInput(e){let t=e.target,n=t.value;if(t.type==="number"&&(n=n==""?null:parseFloat(n)),this._previousValue!==n){if(this._previousValue=n,this._pendingAutoselectedOption=null,(!this.autocomplete||!this.autocomplete.requireSelection)&&this._onChange(n),!n)this._clearPreviousSelectedOption(null,!1);else if(this.panelOpen&&!this.autocomplete.requireSelection){let a=this.autocomplete.options?.find(r=>r.selected);if(a){let r=this._getDisplayValue(a.value);n!==r&&a.deselect(!1)}}if(this._canOpen()&&this._hasFocus()){let a=this._valueOnLastKeydown??this._element.nativeElement.value;this._valueOnLastKeydown=null,this._openPanelInternal(a)}}}_handleFocus(){this._canOpenOnNextFocus?this._canOpen()&&(this._previousValue=this._element.nativeElement.value,this._attachOverlay(this._previousValue),this._floatLabel(!0)):this._canOpenOnNextFocus=!0}_handleClick(){this._canOpen()&&!this.panelOpen&&this._openPanelInternal()}_hasFocus(){return an()===this._element.nativeElement}_floatLabel(e=!1){this._formField&&this._formField.floatLabel==="auto"&&(e?this._formField._animateAndLockLabel():this._formField.floatLabel="always",this._manuallyFloatingLabel=!0)}_resetLabel(){this._manuallyFloatingLabel&&(this._formField&&(this._formField.floatLabel="auto"),this._manuallyFloatingLabel=!1)}_subscribeToClosingActions(){let e=new yt(n=>{Be(()=>{n.next()},{injector:this._environmentInjector})}),t=this.autocomplete.options?.changes.pipe(di(()=>this._positionStrategy.reapplyLastPosition()),Kc(0))??ge();return $e(e,t).pipe(We(()=>this._zone.run(()=>{let n=this.panelOpen;return this._resetActiveItem(),this._updatePanelState(),this._changeDetectorRef.detectChanges(),this.panelOpen&&this._overlayRef.updatePosition(),n!==this.panelOpen&&(this.panelOpen?this._emitOpened():this.autocomplete.closed.emit()),this.panelClosingActions})),ct(1)).subscribe(n=>this._setValueAndClose(n))}_emitOpened(){this.autocomplete.opened.emit()}_destroyPanel(){this._overlayRef&&(this.closePanel(),this._overlayRef.dispose(),this._overlayRef=null)}_getDisplayValue(e){let t=this.autocomplete;return t&&t.displayWith?t.displayWith(e):e}_assignOptionValue(e){let t=this._getDisplayValue(e);e==null&&this._clearPreviousSelectedOption(null,!1),this._updateNativeInputValue(t??"")}_updateNativeInputValue(e){this._formField?this._formField._control.value=e:this._element.nativeElement.value=e,this._previousValue=e}_setValueAndClose(e){let t=this.autocomplete,n=e?e.source:this._pendingAutoselectedOption;n?(this._clearPreviousSelectedOption(n),this._assignOptionValue(n.value),this._onChange(n.value),t._emitSelectEvent(n),this._element.nativeElement.focus()):t.requireSelection&&this._element.nativeElement.value!==this._valueOnAttach&&(this._clearPreviousSelectedOption(null),this._assignOptionValue(null),this._onChange(null)),this.closePanel()}_clearPreviousSelectedOption(e,t){this.autocomplete?.options?.forEach(n=>{n!==e&&n.selected&&n.deselect(t)})}_openPanelInternal(e=this._element.nativeElement.value){this._attachOverlay(e),this._floatLabel()}_attachOverlay(e){if(!this.autocomplete)return;let t=this._overlayRef;t?(this._positionStrategy.setOrigin(this._getConnectedElement()),t.updateSize({width:this._getPanelWidth()})):(this._portal=new Et(this.autocomplete.template,this._viewContainerRef,{id:this._formField?.getLabelId()}),t=qt(this._injector,this._getOverlayConfig()),this._overlayRef=t,this._viewportSubscription=this._viewportRuler.change().subscribe(()=>{this.panelOpen&&t&&t.updateSize({width:this._getPanelWidth()})}),this._handsetLandscapeSubscription=this._breakpointObserver.observe(Sr.HandsetLandscape).subscribe(a=>{a.matches?this._positionStrategy.withFlexibleDimensions(!0).withGrowAfterOpen(!0).withViewportMargin(8):this._positionStrategy.withFlexibleDimensions(!1).withGrowAfterOpen(!1).withViewportMargin(0)})),t&&!t.hasAttached()&&(t.attach(this._portal),this._valueOnAttach=e,this._valueOnLastKeydown=null,this._closingActionsSubscription=this._subscribeToClosingActions());let n=this.panelOpen;this.autocomplete._isOpen=this._overlayAttached=!0,this.autocomplete._latestOpeningTrigger=this,this.autocomplete._setColor(this._formField?.color),this._updatePanelState(),this.panelOpen&&n!==this.panelOpen&&this._emitOpened()}_handlePanelKeydown=e=>{(e.keyCode===27&&!Ge(e)||e.keyCode===38&&Ge(e,"altKey"))&&(this._pendingAutoselectedOption&&(this._updateNativeInputValue(this._valueBeforeAutoSelection??""),this._pendingAutoselectedOption=null),this._closeKeyEventStream.next(),this._resetActiveItem(),e.stopPropagation(),e.preventDefault())};_updatePanelState(){if(this.autocomplete._setVisibility(),this.panelOpen){let e=this._overlayRef;this._keydownSubscription||(this._keydownSubscription=e.keydownEvents().subscribe(this._handlePanelKeydown)),this._outsideClickSubscription||(this._outsideClickSubscription=e.outsidePointerEvents().subscribe())}else this._keydownSubscription?.unsubscribe(),this._outsideClickSubscription?.unsubscribe(),this._keydownSubscription=this._outsideClickSubscription=void 0}_getOverlayConfig(){return new Wt({positionStrategy:this._getOverlayPosition(),scrollStrategy:this._scrollStrategy(),width:this._getPanelWidth(),direction:this._dir??void 0,hasBackdrop:this._defaults?.hasBackdrop,backdropClass:this._defaults?.backdropClass||"cdk-overlay-transparent-backdrop",panelClass:this._overlayPanelClass,disableAnimations:this._animationsDisabled})}_getOverlayPosition(){let e=$i(this._injector,this._getConnectedElement()).withFlexibleDimensions(!1).withPush(!1).withPopoverLocation("inline");return this._setStrategyPositions(e),this._positionStrategy=e,e}_setStrategyPositions(e){let t=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],n=this._aboveClass,a=[{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:n},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:n}],r;this.position==="above"?r=a:this.position==="below"?r=t:r=[...t,...a],e.withPositions(r)}_getConnectedElement(){return this.connectedTo?this.connectedTo.elementRef:this._formField?this._formField.getConnectedOverlayOrigin():this._element}_getPanelWidth(){return this.autocomplete.panelWidth||this._getHostWidth()}_getHostWidth(){return this._getConnectedElement().nativeElement.getBoundingClientRect().width}_resetActiveItem(){let e=this.autocomplete;if(e.autoActiveFirstOption){let t=-1;for(let n=0;n<e.options.length;n++)if(!e.options.get(n).disabled){t=n;break}e._keyManager.setActiveItem(t)}else e._keyManager.setActiveItem(-1)}_canOpen(){let e=this._element.nativeElement;return!e.readOnly&&!e.disabled&&!this.autocompleteDisabled}_scrollToOption(e){let t=this.autocomplete,n=ws(e,t.options,t.optionGroups);if(e===0&&n===1)t._setScrollTop(0);else if(t.panel){let a=t.options.toArray()[e];if(a){let r=a._getHostElement(),u=Ds(r.offsetTop,r.offsetHeight,t._getScrollTop(),t.panel.nativeElement.offsetHeight);t._setScrollTop(u)}}}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["input","matAutocomplete",""],["textarea","matAutocomplete",""]],hostAttrs:[1,"mat-mdc-autocomplete-trigger"],hostVars:7,hostBindings:function(t,n){t&1&&A("focusin",function(){return n._handleFocus()})("blur",function(){return n._onTouched()})("input",function(r){return n._handleInput(r)})("keydown",function(r){return n._handleKeydown(r)})("click",function(){return n._handleClick()}),t&2&&Z("autocomplete",n.autocompleteAttribute)("role",n.autocompleteDisabled?null:"combobox")("aria-autocomplete",n.autocompleteDisabled?null:"list")("aria-activedescendant",n.panelOpen&&n.activeOption?n.activeOption.id:null)("aria-expanded",n.autocompleteDisabled?null:n.panelOpen.toString())("aria-controls",n.autocompleteDisabled||!n.panelOpen?null:n.autocomplete?.id)("aria-haspopup",n.autocompleteDisabled?null:"listbox")},inputs:{autocomplete:[0,"matAutocomplete","autocomplete"],position:[0,"matAutocompletePosition","position"],connectedTo:[0,"matAutocompleteConnectedTo","connectedTo"],autocompleteAttribute:[0,"autocomplete","autocompleteAttribute"],autocompleteDisabled:[2,"matAutocompleteDisabled","autocompleteDisabled",L]},exportAs:["matAutocompleteTrigger"],features:[J([Rb]),Se]})}return i})(),xn=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Nt,Ro,_i,Ro,ee]})}return i})();var Pb=(i,o)=>o.command;function Fb(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function Nb(i,o){i&1&&(s(0,"mat-error"),m(1,"Starts with letter, alphanumeric + hyphens/underscores, max 128 chars"),l())}function Lb(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function Vb(i,o){if(i&1&&(s(0,"mat-option",6)(1,"span",12),m(2),l(),s(3,"span",13),m(4),l()()),i&2){let e=o.$implicit;x("value",e.command),c(2),q(e.command),c(2),he("(",e.from,")")}}var Bb="^[a-zA-Z][a-zA-Z0-9_-]{0,127}$",op=(()=>{class i{constructor(){this.fb=d(un),this.dialogRef=d(gt),this.data=d(Gn),this.isEdit=this.data.config!==null,this.isClone=this.data.clone===!0,this.form=this.fb.group({name:[this.data.config?.name??"",{validators:[st.required,st.pattern(Bb)]}],command:[this.data.config?.command??"",st.required],flagsText:[""],envText:[""]}),this.allExistingCommands=W(()=>{let e=this.data.allConfigs??[],t=this.data.config?.name??null,n=new Set,a=[];for(let r of e)r.name!==t&&(n.has(r.command)||(n.add(r.command),a.push({command:r.command,from:r.name})));return a}),this._commandValue=R(this.data.config?.command??""),this.commandValue=this._commandValue.asReadonly(),this.filteredCommands=W(()=>{let e=this.commandValue()?.toLowerCase()??"";return this.allExistingCommands().filter(t=>t.command.toLowerCase().includes(e)||t.from.toLowerCase().includes(e))})}get nameControl(){return this.form.get("name")}get commandControl(){return this.form.get("command")}ngOnInit(){if(this.commandControl.valueChanges.subscribe(e=>this._commandValue.set(e)),this.data.config?.flags?.length&&this.form.get("flagsText").setValue(this.data.config.flags.join(`
3951
+ `],encapsulation:2})}return i})();var Rb={provide:Mi,useExisting:nt(()=>Wi),multi:!0};var Ob=new x("mat-autocomplete-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>yi(i)}}),Wi=(()=>{class i{_environmentInjector=d(mi);_element=d(N);_injector=d(X);_viewContainerRef=d(Xe);_zone=d(H);_changeDetectorRef=d(te);_dir=d(qe,{optional:!0});_formField=d(jn,{optional:!0,host:!0});_viewportRuler=d(Gt);_scrollStrategy=d(Ob);_renderer=d(ve);_animationsDisabled=pe();_defaults=d(np,{optional:!0});_overlayRef=null;_portal;_componentDestroyed=!1;_initialized=new I;_keydownSubscription;_outsideClickSubscription;_cleanupWindowBlur;_previousValue=null;_valueOnAttach=null;_valueOnLastKeydown=null;_positionStrategy;_manuallyFloatingLabel=!1;_closingActionsSubscription;_viewportSubscription=De.EMPTY;_breakpointObserver=d(On);_handsetLandscapeSubscription=De.EMPTY;_canOpenOnNextFocus=!0;_valueBeforeAutoSelection;_pendingAutoselectedOption=null;_closeKeyEventStream=new I;_overlayPanelClass=Vi(this._defaults?.overlayPanelClass||[]);_windowBlurHandler=()=>{this._canOpenOnNextFocus=this.panelOpen||!this._hasFocus()};_onChange=()=>{};_onTouched=()=>{};autocomplete;position="auto";connectedTo;autocompleteAttribute="off";autocompleteDisabled=!1;_aboveClass="mat-mdc-autocomplete-panel-above";ngAfterViewInit(){this._initialized.next(),this._initialized.complete(),this._cleanupWindowBlur=this._renderer.listen("window","blur",this._windowBlurHandler)}ngOnChanges(e){e.position&&this._positionStrategy&&(this._setStrategyPositions(this._positionStrategy),this.panelOpen&&this._overlayRef.updatePosition())}ngOnDestroy(){this._cleanupWindowBlur?.(),this._handsetLandscapeSubscription.unsubscribe(),this._viewportSubscription.unsubscribe(),this._componentDestroyed=!0,this._destroyPanel(),this._closeKeyEventStream.complete()}get panelOpen(){return this._overlayAttached&&this.autocomplete.showPanel}_overlayAttached=!1;openPanel(){this._openPanelInternal()}closePanel(){this._resetLabel(),this._overlayAttached&&(this.panelOpen&&this._zone.run(()=>{this.autocomplete.closed.emit()}),this.autocomplete._latestOpeningTrigger===this&&(this.autocomplete._isOpen=!1,this.autocomplete._latestOpeningTrigger=null),this._overlayAttached=!1,this._pendingAutoselectedOption=null,this._overlayRef&&this._overlayRef.hasAttached()&&(this._overlayRef.detach(),this._closingActionsSubscription.unsubscribe()),this._updatePanelState(),this._componentDestroyed||this._changeDetectorRef.detectChanges())}updatePosition(){this._overlayAttached&&this._overlayRef.updatePosition()}get panelClosingActions(){return $e(this.optionSelections,this.autocomplete._keyManager.tabOut.pipe(Ce(()=>this._overlayAttached)),this._closeKeyEventStream,this._getOutsideClickStream(),this._overlayRef?this._overlayRef.detachments().pipe(Ce(()=>this._overlayAttached)):ge()).pipe(Pe(e=>e instanceof La?e:null))}optionSelections=Yi(()=>{let e=this.autocomplete?this.autocomplete.options:null;return e?e.changes.pipe(ke(e),We(()=>$e(...e.map(t=>t.onSelectionChange)))):this._initialized.pipe(We(()=>this.optionSelections))});get activeOption(){return this.autocomplete&&this.autocomplete._keyManager?this.autocomplete._keyManager.activeItem:null}_getOutsideClickStream(){return new yt(e=>{let t=a=>{let r=rt(a),u=this._formField?this._formField.getConnectedOverlayOrigin().nativeElement:null,h=this.connectedTo?this.connectedTo.elementRef.nativeElement:null;this._overlayAttached&&r!==this._element.nativeElement&&!this._hasFocus()&&(!u||!u.contains(r))&&(!h||!h.contains(r))&&this._overlayRef&&!this._overlayRef.overlayElement.contains(r)&&e.next(a)},n=[this._renderer.listen("document","click",t),this._renderer.listen("document","auxclick",t),this._renderer.listen("document","touchend",t)];return()=>{n.forEach(a=>a())}})}writeValue(e){Promise.resolve(null).then(()=>this._assignOptionValue(e))}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this._element.nativeElement.disabled=e}_handleKeydown(e){let t=e,n=t.keyCode,a=Ge(t);if(n===27&&!a&&t.preventDefault(),this._valueOnLastKeydown=this._element.nativeElement.value,this.activeOption&&n===13&&this.panelOpen&&!a)this.activeOption._selectViaInteraction(),this._resetActiveItem(),t.preventDefault();else if(this.autocomplete){let r=this.autocomplete._keyManager.activeItem,u=n===38||n===40;n===9||u&&!a&&this.panelOpen?this.autocomplete._keyManager.onKeydown(t):u&&this._canOpen()&&this._openPanelInternal(this._valueOnLastKeydown),(u||this.autocomplete._keyManager.activeItem!==r)&&(this._scrollToOption(this.autocomplete._keyManager.activeItemIndex||0),this.autocomplete.autoSelectActiveOption&&this.activeOption&&(this._pendingAutoselectedOption||(this._valueBeforeAutoSelection=this._valueOnLastKeydown),this._pendingAutoselectedOption=this.activeOption,this._assignOptionValue(this.activeOption.value)))}}_handleInput(e){let t=e.target,n=t.value;if(t.type==="number"&&(n=n==""?null:parseFloat(n)),this._previousValue!==n){if(this._previousValue=n,this._pendingAutoselectedOption=null,(!this.autocomplete||!this.autocomplete.requireSelection)&&this._onChange(n),!n)this._clearPreviousSelectedOption(null,!1);else if(this.panelOpen&&!this.autocomplete.requireSelection){let a=this.autocomplete.options?.find(r=>r.selected);if(a){let r=this._getDisplayValue(a.value);n!==r&&a.deselect(!1)}}if(this._canOpen()&&this._hasFocus()){let a=this._valueOnLastKeydown??this._element.nativeElement.value;this._valueOnLastKeydown=null,this._openPanelInternal(a)}}}_handleFocus(){this._canOpenOnNextFocus?this._canOpen()&&(this._previousValue=this._element.nativeElement.value,this._attachOverlay(this._previousValue),this._floatLabel(!0)):this._canOpenOnNextFocus=!0}_handleClick(){this._canOpen()&&!this.panelOpen&&this._openPanelInternal()}_hasFocus(){return an()===this._element.nativeElement}_floatLabel(e=!1){this._formField&&this._formField.floatLabel==="auto"&&(e?this._formField._animateAndLockLabel():this._formField.floatLabel="always",this._manuallyFloatingLabel=!0)}_resetLabel(){this._manuallyFloatingLabel&&(this._formField&&(this._formField.floatLabel="auto"),this._manuallyFloatingLabel=!1)}_subscribeToClosingActions(){let e=new yt(n=>{Be(()=>{n.next()},{injector:this._environmentInjector})}),t=this.autocomplete.options?.changes.pipe(di(()=>this._positionStrategy.reapplyLastPosition()),Kc(0))??ge();return $e(e,t).pipe(We(()=>this._zone.run(()=>{let n=this.panelOpen;return this._resetActiveItem(),this._updatePanelState(),this._changeDetectorRef.detectChanges(),this.panelOpen&&this._overlayRef.updatePosition(),n!==this.panelOpen&&(this.panelOpen?this._emitOpened():this.autocomplete.closed.emit()),this.panelClosingActions})),ct(1)).subscribe(n=>this._setValueAndClose(n))}_emitOpened(){this.autocomplete.opened.emit()}_destroyPanel(){this._overlayRef&&(this.closePanel(),this._overlayRef.dispose(),this._overlayRef=null)}_getDisplayValue(e){let t=this.autocomplete;return t&&t.displayWith?t.displayWith(e):e}_assignOptionValue(e){let t=this._getDisplayValue(e);e==null&&this._clearPreviousSelectedOption(null,!1),this._updateNativeInputValue(t??"")}_updateNativeInputValue(e){this._formField?this._formField._control.value=e:this._element.nativeElement.value=e,this._previousValue=e}_setValueAndClose(e){let t=this.autocomplete,n=e?e.source:this._pendingAutoselectedOption;n?(this._clearPreviousSelectedOption(n),this._assignOptionValue(n.value),this._onChange(n.value),t._emitSelectEvent(n),this._element.nativeElement.focus()):t.requireSelection&&this._element.nativeElement.value!==this._valueOnAttach&&(this._clearPreviousSelectedOption(null),this._assignOptionValue(null),this._onChange(null)),this.closePanel()}_clearPreviousSelectedOption(e,t){this.autocomplete?.options?.forEach(n=>{n!==e&&n.selected&&n.deselect(t)})}_openPanelInternal(e=this._element.nativeElement.value){this._attachOverlay(e),this._floatLabel()}_attachOverlay(e){if(!this.autocomplete)return;let t=this._overlayRef;t?(this._positionStrategy.setOrigin(this._getConnectedElement()),t.updateSize({width:this._getPanelWidth()})):(this._portal=new Et(this.autocomplete.template,this._viewContainerRef,{id:this._formField?.getLabelId()}),t=qt(this._injector,this._getOverlayConfig()),this._overlayRef=t,this._viewportSubscription=this._viewportRuler.change().subscribe(()=>{this.panelOpen&&t&&t.updateSize({width:this._getPanelWidth()})}),this._handsetLandscapeSubscription=this._breakpointObserver.observe(Ar.HandsetLandscape).subscribe(a=>{a.matches?this._positionStrategy.withFlexibleDimensions(!0).withGrowAfterOpen(!0).withViewportMargin(8):this._positionStrategy.withFlexibleDimensions(!1).withGrowAfterOpen(!1).withViewportMargin(0)})),t&&!t.hasAttached()&&(t.attach(this._portal),this._valueOnAttach=e,this._valueOnLastKeydown=null,this._closingActionsSubscription=this._subscribeToClosingActions());let n=this.panelOpen;this.autocomplete._isOpen=this._overlayAttached=!0,this.autocomplete._latestOpeningTrigger=this,this.autocomplete._setColor(this._formField?.color),this._updatePanelState(),this.panelOpen&&n!==this.panelOpen&&this._emitOpened()}_handlePanelKeydown=e=>{(e.keyCode===27&&!Ge(e)||e.keyCode===38&&Ge(e,"altKey"))&&(this._pendingAutoselectedOption&&(this._updateNativeInputValue(this._valueBeforeAutoSelection??""),this._pendingAutoselectedOption=null),this._closeKeyEventStream.next(),this._resetActiveItem(),e.stopPropagation(),e.preventDefault())};_updatePanelState(){if(this.autocomplete._setVisibility(),this.panelOpen){let e=this._overlayRef;this._keydownSubscription||(this._keydownSubscription=e.keydownEvents().subscribe(this._handlePanelKeydown)),this._outsideClickSubscription||(this._outsideClickSubscription=e.outsidePointerEvents().subscribe())}else this._keydownSubscription?.unsubscribe(),this._outsideClickSubscription?.unsubscribe(),this._keydownSubscription=this._outsideClickSubscription=void 0}_getOverlayConfig(){return new Wt({positionStrategy:this._getOverlayPosition(),scrollStrategy:this._scrollStrategy(),width:this._getPanelWidth(),direction:this._dir??void 0,hasBackdrop:this._defaults?.hasBackdrop,backdropClass:this._defaults?.backdropClass||"cdk-overlay-transparent-backdrop",panelClass:this._overlayPanelClass,disableAnimations:this._animationsDisabled})}_getOverlayPosition(){let e=$i(this._injector,this._getConnectedElement()).withFlexibleDimensions(!1).withPush(!1).withPopoverLocation("inline");return this._setStrategyPositions(e),this._positionStrategy=e,e}_setStrategyPositions(e){let t=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],n=this._aboveClass,a=[{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:n},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:n}],r;this.position==="above"?r=a:this.position==="below"?r=t:r=[...t,...a],e.withPositions(r)}_getConnectedElement(){return this.connectedTo?this.connectedTo.elementRef:this._formField?this._formField.getConnectedOverlayOrigin():this._element}_getPanelWidth(){return this.autocomplete.panelWidth||this._getHostWidth()}_getHostWidth(){return this._getConnectedElement().nativeElement.getBoundingClientRect().width}_resetActiveItem(){let e=this.autocomplete;if(e.autoActiveFirstOption){let t=-1;for(let n=0;n<e.options.length;n++)if(!e.options.get(n).disabled){t=n;break}e._keyManager.setActiveItem(t)}else e._keyManager.setActiveItem(-1)}_canOpen(){let e=this._element.nativeElement;return!e.readOnly&&!e.disabled&&!this.autocompleteDisabled}_scrollToOption(e){let t=this.autocomplete,n=Ss(e,t.options,t.optionGroups);if(e===0&&n===1)t._setScrollTop(0);else if(t.panel){let a=t.options.toArray()[e];if(a){let r=a._getHostElement(),u=Ms(r.offsetTop,r.offsetHeight,t._getScrollTop(),t.panel.nativeElement.offsetHeight);t._setScrollTop(u)}}}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["input","matAutocomplete",""],["textarea","matAutocomplete",""]],hostAttrs:[1,"mat-mdc-autocomplete-trigger"],hostVars:7,hostBindings:function(t,n){t&1&&A("focusin",function(){return n._handleFocus()})("blur",function(){return n._onTouched()})("input",function(r){return n._handleInput(r)})("keydown",function(r){return n._handleKeydown(r)})("click",function(){return n._handleClick()}),t&2&&Z("autocomplete",n.autocompleteAttribute)("role",n.autocompleteDisabled?null:"combobox")("aria-autocomplete",n.autocompleteDisabled?null:"list")("aria-activedescendant",n.panelOpen&&n.activeOption?n.activeOption.id:null)("aria-expanded",n.autocompleteDisabled?null:n.panelOpen.toString())("aria-controls",n.autocompleteDisabled||!n.panelOpen?null:n.autocomplete?.id)("aria-haspopup",n.autocompleteDisabled?null:"listbox")},inputs:{autocomplete:[0,"matAutocomplete","autocomplete"],position:[0,"matAutocompletePosition","position"],connectedTo:[0,"matAutocompleteConnectedTo","connectedTo"],autocompleteAttribute:[0,"autocomplete","autocompleteAttribute"],autocompleteDisabled:[2,"matAutocompleteDisabled","autocompleteDisabled",L]},exportAs:["matAutocompleteTrigger"],features:[J([Rb]),Se]})}return i})(),xn=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Nt,Po,_i,Po,ee]})}return i})();var Pb=(i,o)=>o.command;function Fb(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function Nb(i,o){i&1&&(s(0,"mat-error"),m(1,"Starts with letter, alphanumeric + hyphens/underscores, max 128 chars"),l())}function Lb(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function Vb(i,o){if(i&1&&(s(0,"mat-option",6)(1,"span",12),m(2),l(),s(3,"span",13),m(4),l()()),i&2){let e=o.$implicit;C("value",e.command),c(2),q(e.command),c(2),he("(",e.from,")")}}var Bb="^[a-zA-Z][a-zA-Z0-9_-]{0,127}$",op=(()=>{class i{constructor(){this.fb=d(un),this.dialogRef=d(gt),this.data=d(Wn),this.isEdit=this.data.config!==null,this.isClone=this.data.clone===!0,this.form=this.fb.group({name:[this.data.config?.name??"",{validators:[st.required,st.pattern(Bb)]}],command:[this.data.config?.command??"",st.required],flagsText:[""],envText:[""]}),this.allExistingCommands=$(()=>{let e=this.data.allConfigs??[],t=this.data.config?.name??null,n=new Set,a=[];for(let r of e)r.name!==t&&(n.has(r.command)||(n.add(r.command),a.push({command:r.command,from:r.name})));return a}),this._commandValue=R(this.data.config?.command??""),this.commandValue=this._commandValue.asReadonly(),this.filteredCommands=$(()=>{let e=this.commandValue()?.toLowerCase()??"";return this.allExistingCommands().filter(t=>t.command.toLowerCase().includes(e)||t.from.toLowerCase().includes(e))})}get nameControl(){return this.form.get("name")}get commandControl(){return this.form.get("command")}ngOnInit(){if(this.commandControl.valueChanges.subscribe(e=>this._commandValue.set(e)),this.data.config?.flags?.length&&this.form.get("flagsText").setValue(this.data.config.flags.join(`
3952
3952
  `)+`
3953
3953
  `),this.data.config?.environment){let e=Object.entries(this.data.config.environment).map(([t,n])=>`${t}=${n}`).join(`
3954
3954
  `);e&&this.form.get("envText").setValue(e+`
@@ -3958,7 +3958,7 @@ mat-autocomplete {
3958
3958
  --ctx-size 4096
3959
3959
  --verbose`,1,"flags-textarea"],["matInput","","formControlName","envText","rows","4","wrap","off","placeholder",`HF_HOME=/data/huggingface
3960
3960
  CUDA_VISIBLE_DEVICES=0,1
3961
- MY_API_KEY=secret`,1,"env-textarea"],["align","end"],["mat-stroked-button","",3,"click"],["mat-raised-button","","color","primary",3,"click","disabled"],[1,"auto-path"],[1,"auto-from"]],template:function(t,n){if(t&1&&(s(0,"h2",1),m(1),l(),s(2,"mat-dialog-content")(3,"form",2)(4,"mat-form-field",3),v(5,"input",4),b(),s(6,"mat-label"),m(7,"Service Name"),l(),M(8,Fb,2,0,"mat-error")(9,Nb,2,0,"mat-error"),l(),s(10,"mat-form-field",3),v(11,"input",5),b(),s(12,"mat-label"),m(13,"Command (absolute path)"),l(),M(14,Lb,2,0,"mat-error"),l(),s(15,"mat-autocomplete",null,0),me(17,Vb,5,3,"mat-option",6,Pb),l(),s(19,"mat-form-field",3),v(20,"textarea",7),b(),s(21,"mat-label"),m(22,"CLI Flags (one per line)"),l()(),s(23,"mat-form-field",3),v(24,"textarea",8),b(),s(25,"mat-label"),m(26,"Environment variables (KEY=VALUE, one per line)"),l()()()(),s(27,"mat-dialog-actions",9)(28,"button",10),A("click",function(){return n.cancel()}),m(29,"Cancel"),l(),s(30,"button",11),A("click",function(){return n.save()}),m(31),l()()),t&2){let a=Ne(16);c(),he("",n.isClone?"Clone":n.isEdit?"Edit":"Add"," custom service"),c(2),x("formGroup",n.form),c(2),x("disabled",n.isEdit&&!n.isClone),y(),c(3),E(n.nameControl.errors?.required?8:n.nameControl.errors?.pattern?9:-1),c(3),x("matAutocomplete",a),y(),c(3),E(n.commandControl.errors?.required?14:-1),c(3),ue(n.filteredCommands()),c(3),y(),c(4),y(),c(6),x("disabled",n.form.invalid),c(),he(" ",n.isEdit&&!n.isClone?"Save":"Create"," ")}},dependencies:[Ve,hn,bo,Ei,Ai,mn,pn,Ut,ji,xn,Cn,vt,Wi,Qe,it,ti,ei,kt,Ot,fn,Lt,oi,ri,ai],styles:[".dialog-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:12px;min-width:480px}.auto-path[_ngcontent-%COMP%]{font-family:monospace}.auto-from[_ngcontent-%COMP%]{margin-left:8px;opacity:.6;font-size:12px}.full-width[_ngcontent-%COMP%]{width:100%}.flags-textarea[_ngcontent-%COMP%], .env-textarea[_ngcontent-%COMP%]{overflow-x:auto}mat-dialog-content[_ngcontent-%COMP%]{padding-top:10px!important}mat-dialog-actions[_ngcontent-%COMP%]{gap:8px}"]})}}return i})();var zb=["*"],ap=(()=>{class i{labelPosition="after";static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["div","mat-internal-form-field",""]],hostAttrs:[1,"mdc-form-field","mat-internal-form-field"],hostVars:2,hostBindings:function(t,n){t&2&&p("mdc-form-field--align-end",n.labelPosition==="before")},inputs:{labelPosition:"labelPosition"},ngContentSelectors:zb,decls:1,vars:0,template:function(t,n){t&1&&(ce(),U(0))},styles:[`.mat-internal-form-field {
3961
+ MY_API_KEY=secret`,1,"env-textarea"],["align","end"],["mat-stroked-button","",3,"click"],["mat-raised-button","","color","primary",3,"click","disabled"],[1,"auto-path"],[1,"auto-from"]],template:function(t,n){if(t&1&&(s(0,"h2",1),m(1),l(),s(2,"mat-dialog-content")(3,"form",2)(4,"mat-form-field",3),v(5,"input",4),b(),s(6,"mat-label"),m(7,"Service Name"),l(),M(8,Fb,2,0,"mat-error")(9,Nb,2,0,"mat-error"),l(),s(10,"mat-form-field",3),v(11,"input",5),b(),s(12,"mat-label"),m(13,"Command (absolute path)"),l(),M(14,Lb,2,0,"mat-error"),l(),s(15,"mat-autocomplete",null,0),me(17,Vb,5,3,"mat-option",6,Pb),l(),s(19,"mat-form-field",3),v(20,"textarea",7),b(),s(21,"mat-label"),m(22,"CLI Flags (one per line)"),l()(),s(23,"mat-form-field",3),v(24,"textarea",8),b(),s(25,"mat-label"),m(26,"Environment variables (KEY=VALUE, one per line)"),l()()()(),s(27,"mat-dialog-actions",9)(28,"button",10),A("click",function(){return n.cancel()}),m(29,"Cancel"),l(),s(30,"button",11),A("click",function(){return n.save()}),m(31),l()()),t&2){let a=Fe(16);c(),he("",n.isClone?"Clone":n.isEdit?"Edit":"Add"," custom service"),c(2),C("formGroup",n.form),c(2),C("disabled",n.isEdit&&!n.isClone),y(),c(3),E(n.nameControl.errors?.required?8:n.nameControl.errors?.pattern?9:-1),c(3),C("matAutocomplete",a),y(),c(3),E(n.commandControl.errors?.required?14:-1),c(3),ue(n.filteredCommands()),c(3),y(),c(4),y(),c(6),C("disabled",n.form.invalid),c(),he(" ",n.isEdit&&!n.isClone?"Save":"Create"," ")}},dependencies:[Ve,hn,Co,Ei,Ai,mn,pn,Ut,ji,xn,Cn,vt,Wi,Qe,it,ti,ei,kt,Ot,fn,Lt,oi,ri,ai],styles:[".dialog-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:12px;min-width:480px}.auto-path[_ngcontent-%COMP%]{font-family:monospace}.auto-from[_ngcontent-%COMP%]{margin-left:8px;opacity:.6;font-size:12px}.full-width[_ngcontent-%COMP%]{width:100%}.flags-textarea[_ngcontent-%COMP%], .env-textarea[_ngcontent-%COMP%]{overflow-x:auto}mat-dialog-content[_ngcontent-%COMP%]{padding-top:10px!important}mat-dialog-actions[_ngcontent-%COMP%]{gap:8px}"]})}}return i})();var zb=["*"],ap=(()=>{class i{labelPosition="after";static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["div","mat-internal-form-field",""]],hostAttrs:[1,"mdc-form-field","mat-internal-form-field"],hostVars:2,hostBindings:function(t,n){t&2&&p("mdc-form-field--align-end",n.labelPosition==="before")},inputs:{labelPosition:"labelPosition"},ngContentSelectors:zb,decls:1,vars:0,template:function(t,n){t&1&&(ce(),U(0))},styles:[`.mat-internal-form-field {
3962
3962
  -moz-osx-font-smoothing: grayscale;
3963
3963
  -webkit-font-smoothing: antialiased;
3964
3964
  display: inline-flex;
@@ -3992,7 +3992,7 @@ MY_API_KEY=secret`,1,"env-textarea"],["align","end"],["mat-stroked-button","",3,
3992
3992
  padding-left: 4px;
3993
3993
  padding-right: 0;
3994
3994
  }
3995
- `],encapsulation:2})}return i})();var jb=["input"],Hb=["label"],Ub=["*"],Pc={color:"accent",clickAction:"check-indeterminate",disabledInteractive:!1},Gb=new C("mat-checkbox-default-options",{providedIn:"root",factory:()=>Pc}),bt=(function(i){return i[i.Init=0]="Init",i[i.Checked=1]="Checked",i[i.Unchecked=2]="Unchecked",i[i.Indeterminate=3]="Indeterminate",i})(bt||{}),Fc=class{source;checked},Nc=(()=>{class i{_elementRef=d(N);_changeDetectorRef=d(te);_ngZone=d(H);_animationsDisabled=pe();_options=d(Gb,{optional:!0});focus(){this._inputElement.nativeElement.focus()}_createChangeEvent(e){let t=new Fc;return t.source=this,t.checked=e,t}_getAnimationTargetElement(){return this._inputElement?.nativeElement}_animationClasses={uncheckedToChecked:"mdc-checkbox--anim-unchecked-checked",uncheckedToIndeterminate:"mdc-checkbox--anim-unchecked-indeterminate",checkedToUnchecked:"mdc-checkbox--anim-checked-unchecked",checkedToIndeterminate:"mdc-checkbox--anim-checked-indeterminate",indeterminateToChecked:"mdc-checkbox--anim-indeterminate-checked",indeterminateToUnchecked:"mdc-checkbox--anim-indeterminate-unchecked"};ariaLabel="";ariaLabelledby=null;ariaDescribedby;ariaExpanded;ariaControls;ariaOwns;_uniqueId;id;get inputId(){return`${this.id||this._uniqueId}-input`}required=!1;labelPosition="after";name=null;change=new K;indeterminateChange=new K;value;disableRipple=!1;_inputElement;_labelElement;tabIndex;color;disabledInteractive;_onTouched=()=>{};_currentAnimationClass="";_currentCheckState=bt.Init;_controlValueAccessorChangeFn=()=>{};_validatorChangeFn=()=>{};constructor(){d(Fe).load(Mt);let e=d(new Di("tabindex"),{optional:!0});this._options=this._options||Pc,this.color=this._options.color||Pc.color,this.tabIndex=e==null?0:parseInt(e)||0,this.id=this._uniqueId=d(be).getId("mat-mdc-checkbox-"),this.disabledInteractive=this._options?.disabledInteractive??!1}ngOnChanges(e){e.required&&this._validatorChangeFn()}ngAfterViewInit(){this._syncIndeterminate(this.indeterminate)}get checked(){return this._checked}set checked(e){e!=this.checked&&(this._checked=e,this._changeDetectorRef.markForCheck())}_checked=!1;get disabled(){return this._disabled}set disabled(e){e!==this.disabled&&(this._disabled=e,this._changeDetectorRef.markForCheck())}_disabled=!1;get indeterminate(){return this._indeterminate()}set indeterminate(e){let t=e!=this._indeterminate();this._indeterminate.set(e),t&&(e?this._transitionCheckState(bt.Indeterminate):this._transitionCheckState(this.checked?bt.Checked:bt.Unchecked),this.indeterminateChange.emit(e)),this._syncIndeterminate(e)}_indeterminate=R(!1);_isRippleDisabled(){return this.disableRipple||this.disabled}_onLabelTextChange(){this._changeDetectorRef.detectChanges()}writeValue(e){this.checked=!!e}registerOnChange(e){this._controlValueAccessorChangeFn=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this.disabled=e}validate(e){return this.required&&e.value!==!0?{required:!0}:null}registerOnValidatorChange(e){this._validatorChangeFn=e}_transitionCheckState(e){let t=this._currentCheckState,n=this._getAnimationTargetElement();if(!(t===e||!n)&&(this._currentAnimationClass&&n.classList.remove(this._currentAnimationClass),this._currentAnimationClass=this._getAnimationClassForCheckStateTransition(t,e),this._currentCheckState=e,this._currentAnimationClass.length>0)){n.classList.add(this._currentAnimationClass);let a=this._currentAnimationClass;this._ngZone.runOutsideAngular(()=>{setTimeout(()=>{n.classList.remove(a)},1e3)})}}_emitChangeEvent(){this._controlValueAccessorChangeFn(this.checked),this.change.emit(this._createChangeEvent(this.checked)),this._inputElement&&(this._inputElement.nativeElement.checked=this.checked)}toggle(){this.checked=!this.checked,this._controlValueAccessorChangeFn(this.checked)}_handleInputClick(){let e=this._options?.clickAction;!this.disabled&&e!=="noop"?(this.indeterminate&&e!=="check"&&Promise.resolve().then(()=>{this._indeterminate.set(!1),this.indeterminateChange.emit(!1)}),this._checked=!this._checked,this._transitionCheckState(this._checked?bt.Checked:bt.Unchecked),this._emitChangeEvent()):(this.disabled&&this.disabledInteractive||!this.disabled&&e==="noop")&&(this._inputElement.nativeElement.checked=this.checked,this._inputElement.nativeElement.indeterminate=this.indeterminate)}_onInteractionEvent(e){e.stopPropagation()}_onBlur(){Promise.resolve().then(()=>{this._onTouched(),this._changeDetectorRef.markForCheck()})}_getAnimationClassForCheckStateTransition(e,t){if(this._animationsDisabled)return"";switch(e){case bt.Init:if(t===bt.Checked)return this._animationClasses.uncheckedToChecked;if(t==bt.Indeterminate)return this._checked?this._animationClasses.checkedToIndeterminate:this._animationClasses.uncheckedToIndeterminate;break;case bt.Unchecked:return t===bt.Checked?this._animationClasses.uncheckedToChecked:this._animationClasses.uncheckedToIndeterminate;case bt.Checked:return t===bt.Unchecked?this._animationClasses.checkedToUnchecked:this._animationClasses.checkedToIndeterminate;case bt.Indeterminate:return t===bt.Checked?this._animationClasses.indeterminateToChecked:this._animationClasses.indeterminateToUnchecked}return""}_syncIndeterminate(e){let t=this._inputElement;t&&(t.nativeElement.indeterminate=e)}_onInputClick(){this._handleInputClick()}_onTouchTargetClick(){this._handleInputClick(),this.disabled||this._inputElement.nativeElement.focus()}_preventBubblingFromLabel(e){e.target&&this._labelElement.nativeElement.contains(e.target)&&e.stopPropagation()}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-checkbox"]],viewQuery:function(t,n){if(t&1&&Me(jb,5)(Hb,5),t&2){let a;O(a=P())&&(n._inputElement=a.first),O(a=P())&&(n._labelElement=a.first)}},hostAttrs:[1,"mat-mdc-checkbox"],hostVars:16,hostBindings:function(t,n){t&2&&(dt("id",n.id),Z("tabindex",null)("aria-label",null)("aria-labelledby",null),et(n.color?"mat-"+n.color:"mat-accent"),p("_mat-animation-noopable",n._animationsDisabled)("mdc-checkbox--disabled",n.disabled)("mat-mdc-checkbox-disabled",n.disabled)("mat-mdc-checkbox-checked",n.checked)("mat-mdc-checkbox-disabled-interactive",n.disabledInteractive))},inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],ariaDescribedby:[0,"aria-describedby","ariaDescribedby"],ariaExpanded:[2,"aria-expanded","ariaExpanded",L],ariaControls:[0,"aria-controls","ariaControls"],ariaOwns:[0,"aria-owns","ariaOwns"],id:"id",required:[2,"required","required",L],labelPosition:"labelPosition",name:"name",value:"value",disableRipple:[2,"disableRipple","disableRipple",L],tabIndex:[2,"tabIndex","tabIndex",e=>e==null?void 0:wt(e)],color:"color",disabledInteractive:[2,"disabledInteractive","disabledInteractive",L],checked:[2,"checked","checked",L],disabled:[2,"disabled","disabled",L],indeterminate:[2,"indeterminate","indeterminate",L]},outputs:{change:"change",indeterminateChange:"indeterminateChange"},exportAs:["matCheckbox"],features:[J([{provide:Mi,useExisting:nt(()=>i),multi:!0},{provide:zi,useExisting:i,multi:!0}]),Se],ngContentSelectors:Ub,decls:15,vars:23,consts:[["checkbox",""],["input",""],["label",""],["mat-internal-form-field","",3,"click","labelPosition"],[1,"mdc-checkbox"],["aria-hidden","true",1,"mat-mdc-checkbox-touch-target",3,"click"],["type","checkbox",1,"mdc-checkbox__native-control",3,"blur","click","change","checked","indeterminate","disabled","id","required","tabIndex"],["aria-hidden","true",1,"mdc-checkbox__ripple"],["aria-hidden","true",1,"mdc-checkbox__background"],["focusable","false","viewBox","0 0 24 24",1,"mdc-checkbox__checkmark"],["fill","none","d","M1.73,12.91 8.1,19.28 22.79,4.59",1,"mdc-checkbox__checkmark-path"],[1,"mdc-checkbox__mixedmark"],["mat-ripple","","aria-hidden","true",1,"mat-mdc-checkbox-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleCentered"],[1,"mdc-label",3,"for"]],template:function(t,n){if(t&1&&(ce(),s(0,"div",3),A("click",function(r){return n._preventBubblingFromLabel(r)}),s(1,"div",4,0)(3,"div",5),A("click",function(){return n._onTouchTargetClick()}),l(),s(4,"input",6,1),A("blur",function(){return n._onBlur()})("click",function(){return n._onInputClick()})("change",function(r){return n._onInteractionEvent(r)}),l(),v(6,"div",7),s(7,"div",8),wi(),s(8,"svg",9),v(9,"path",10),l(),js(),v(10,"div",11),l(),v(11,"div",12),l(),s(12,"label",13,2),U(14),l()()),t&2){let a=Ne(2);x("labelPosition",n.labelPosition),c(4),p("mdc-checkbox--selected",n.checked),x("checked",n.checked)("indeterminate",n.indeterminate)("disabled",n.disabled&&!n.disabledInteractive)("id",n.inputId)("required",n.required)("tabIndex",n.disabled&&!n.disabledInteractive?-1:n.tabIndex),Z("aria-label",n.ariaLabel||null)("aria-labelledby",n.ariaLabelledby)("aria-describedby",n.ariaDescribedby)("aria-checked",n.indeterminate?"mixed":null)("aria-controls",n.ariaControls)("aria-disabled",n.disabled&&n.disabledInteractive?!0:null)("aria-expanded",n.ariaExpanded)("aria-owns",n.ariaOwns)("name",n.name)("value",n.value),c(7),x("matRippleTrigger",a)("matRippleDisabled",n.disableRipple||n.disabled)("matRippleCentered",!0),c(),x("for",n.inputId)}},dependencies:[wo,ap],styles:[`.mdc-checkbox {
3995
+ `],encapsulation:2})}return i})();var jb=["input"],Hb=["label"],Ub=["*"],Fc={color:"accent",clickAction:"check-indeterminate",disabledInteractive:!1},Gb=new x("mat-checkbox-default-options",{providedIn:"root",factory:()=>Fc}),bt=(function(i){return i[i.Init=0]="Init",i[i.Checked=1]="Checked",i[i.Unchecked=2]="Unchecked",i[i.Indeterminate=3]="Indeterminate",i})(bt||{}),Nc=class{source;checked},Lc=(()=>{class i{_elementRef=d(N);_changeDetectorRef=d(te);_ngZone=d(H);_animationsDisabled=pe();_options=d(Gb,{optional:!0});focus(){this._inputElement.nativeElement.focus()}_createChangeEvent(e){let t=new Nc;return t.source=this,t.checked=e,t}_getAnimationTargetElement(){return this._inputElement?.nativeElement}_animationClasses={uncheckedToChecked:"mdc-checkbox--anim-unchecked-checked",uncheckedToIndeterminate:"mdc-checkbox--anim-unchecked-indeterminate",checkedToUnchecked:"mdc-checkbox--anim-checked-unchecked",checkedToIndeterminate:"mdc-checkbox--anim-checked-indeterminate",indeterminateToChecked:"mdc-checkbox--anim-indeterminate-checked",indeterminateToUnchecked:"mdc-checkbox--anim-indeterminate-unchecked"};ariaLabel="";ariaLabelledby=null;ariaDescribedby;ariaExpanded;ariaControls;ariaOwns;_uniqueId;id;get inputId(){return`${this.id||this._uniqueId}-input`}required=!1;labelPosition="after";name=null;change=new K;indeterminateChange=new K;value;disableRipple=!1;_inputElement;_labelElement;tabIndex;color;disabledInteractive;_onTouched=()=>{};_currentAnimationClass="";_currentCheckState=bt.Init;_controlValueAccessorChangeFn=()=>{};_validatorChangeFn=()=>{};constructor(){d(Ne).load(Mt);let e=d(new Di("tabindex"),{optional:!0});this._options=this._options||Fc,this.color=this._options.color||Fc.color,this.tabIndex=e==null?0:parseInt(e)||0,this.id=this._uniqueId=d(be).getId("mat-mdc-checkbox-"),this.disabledInteractive=this._options?.disabledInteractive??!1}ngOnChanges(e){e.required&&this._validatorChangeFn()}ngAfterViewInit(){this._syncIndeterminate(this.indeterminate)}get checked(){return this._checked}set checked(e){e!=this.checked&&(this._checked=e,this._changeDetectorRef.markForCheck())}_checked=!1;get disabled(){return this._disabled}set disabled(e){e!==this.disabled&&(this._disabled=e,this._changeDetectorRef.markForCheck())}_disabled=!1;get indeterminate(){return this._indeterminate()}set indeterminate(e){let t=e!=this._indeterminate();this._indeterminate.set(e),t&&(e?this._transitionCheckState(bt.Indeterminate):this._transitionCheckState(this.checked?bt.Checked:bt.Unchecked),this.indeterminateChange.emit(e)),this._syncIndeterminate(e)}_indeterminate=R(!1);_isRippleDisabled(){return this.disableRipple||this.disabled}_onLabelTextChange(){this._changeDetectorRef.detectChanges()}writeValue(e){this.checked=!!e}registerOnChange(e){this._controlValueAccessorChangeFn=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this.disabled=e}validate(e){return this.required&&e.value!==!0?{required:!0}:null}registerOnValidatorChange(e){this._validatorChangeFn=e}_transitionCheckState(e){let t=this._currentCheckState,n=this._getAnimationTargetElement();if(!(t===e||!n)&&(this._currentAnimationClass&&n.classList.remove(this._currentAnimationClass),this._currentAnimationClass=this._getAnimationClassForCheckStateTransition(t,e),this._currentCheckState=e,this._currentAnimationClass.length>0)){n.classList.add(this._currentAnimationClass);let a=this._currentAnimationClass;this._ngZone.runOutsideAngular(()=>{setTimeout(()=>{n.classList.remove(a)},1e3)})}}_emitChangeEvent(){this._controlValueAccessorChangeFn(this.checked),this.change.emit(this._createChangeEvent(this.checked)),this._inputElement&&(this._inputElement.nativeElement.checked=this.checked)}toggle(){this.checked=!this.checked,this._controlValueAccessorChangeFn(this.checked)}_handleInputClick(){let e=this._options?.clickAction;!this.disabled&&e!=="noop"?(this.indeterminate&&e!=="check"&&Promise.resolve().then(()=>{this._indeterminate.set(!1),this.indeterminateChange.emit(!1)}),this._checked=!this._checked,this._transitionCheckState(this._checked?bt.Checked:bt.Unchecked),this._emitChangeEvent()):(this.disabled&&this.disabledInteractive||!this.disabled&&e==="noop")&&(this._inputElement.nativeElement.checked=this.checked,this._inputElement.nativeElement.indeterminate=this.indeterminate)}_onInteractionEvent(e){e.stopPropagation()}_onBlur(){Promise.resolve().then(()=>{this._onTouched(),this._changeDetectorRef.markForCheck()})}_getAnimationClassForCheckStateTransition(e,t){if(this._animationsDisabled)return"";switch(e){case bt.Init:if(t===bt.Checked)return this._animationClasses.uncheckedToChecked;if(t==bt.Indeterminate)return this._checked?this._animationClasses.checkedToIndeterminate:this._animationClasses.uncheckedToIndeterminate;break;case bt.Unchecked:return t===bt.Checked?this._animationClasses.uncheckedToChecked:this._animationClasses.uncheckedToIndeterminate;case bt.Checked:return t===bt.Unchecked?this._animationClasses.checkedToUnchecked:this._animationClasses.checkedToIndeterminate;case bt.Indeterminate:return t===bt.Checked?this._animationClasses.indeterminateToChecked:this._animationClasses.indeterminateToUnchecked}return""}_syncIndeterminate(e){let t=this._inputElement;t&&(t.nativeElement.indeterminate=e)}_onInputClick(){this._handleInputClick()}_onTouchTargetClick(){this._handleInputClick(),this.disabled||this._inputElement.nativeElement.focus()}_preventBubblingFromLabel(e){e.target&&this._labelElement.nativeElement.contains(e.target)&&e.stopPropagation()}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-checkbox"]],viewQuery:function(t,n){if(t&1&&Me(jb,5)(Hb,5),t&2){let a;O(a=P())&&(n._inputElement=a.first),O(a=P())&&(n._labelElement=a.first)}},hostAttrs:[1,"mat-mdc-checkbox"],hostVars:16,hostBindings:function(t,n){t&2&&(dt("id",n.id),Z("tabindex",null)("aria-label",null)("aria-labelledby",null),et(n.color?"mat-"+n.color:"mat-accent"),p("_mat-animation-noopable",n._animationsDisabled)("mdc-checkbox--disabled",n.disabled)("mat-mdc-checkbox-disabled",n.disabled)("mat-mdc-checkbox-checked",n.checked)("mat-mdc-checkbox-disabled-interactive",n.disabledInteractive))},inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],ariaDescribedby:[0,"aria-describedby","ariaDescribedby"],ariaExpanded:[2,"aria-expanded","ariaExpanded",L],ariaControls:[0,"aria-controls","ariaControls"],ariaOwns:[0,"aria-owns","ariaOwns"],id:"id",required:[2,"required","required",L],labelPosition:"labelPosition",name:"name",value:"value",disableRipple:[2,"disableRipple","disableRipple",L],tabIndex:[2,"tabIndex","tabIndex",e=>e==null?void 0:wt(e)],color:"color",disabledInteractive:[2,"disabledInteractive","disabledInteractive",L],checked:[2,"checked","checked",L],disabled:[2,"disabled","disabled",L],indeterminate:[2,"indeterminate","indeterminate",L]},outputs:{change:"change",indeterminateChange:"indeterminateChange"},exportAs:["matCheckbox"],features:[J([{provide:Mi,useExisting:nt(()=>i),multi:!0},{provide:zi,useExisting:i,multi:!0}]),Se],ngContentSelectors:Ub,decls:15,vars:23,consts:[["checkbox",""],["input",""],["label",""],["mat-internal-form-field","",3,"click","labelPosition"],[1,"mdc-checkbox"],["aria-hidden","true",1,"mat-mdc-checkbox-touch-target",3,"click"],["type","checkbox",1,"mdc-checkbox__native-control",3,"blur","click","change","checked","indeterminate","disabled","id","required","tabIndex"],["aria-hidden","true",1,"mdc-checkbox__ripple"],["aria-hidden","true",1,"mdc-checkbox__background"],["focusable","false","viewBox","0 0 24 24",1,"mdc-checkbox__checkmark"],["fill","none","d","M1.73,12.91 8.1,19.28 22.79,4.59",1,"mdc-checkbox__checkmark-path"],[1,"mdc-checkbox__mixedmark"],["mat-ripple","","aria-hidden","true",1,"mat-mdc-checkbox-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleCentered"],[1,"mdc-label",3,"for"]],template:function(t,n){if(t&1&&(ce(),s(0,"div",3),A("click",function(r){return n._preventBubblingFromLabel(r)}),s(1,"div",4,0)(3,"div",5),A("click",function(){return n._onTouchTargetClick()}),l(),s(4,"input",6,1),A("blur",function(){return n._onBlur()})("click",function(){return n._onInputClick()})("change",function(r){return n._onInteractionEvent(r)}),l(),v(6,"div",7),s(7,"div",8),wi(),s(8,"svg",9),v(9,"path",10),l(),Hs(),v(10,"div",11),l(),v(11,"div",12),l(),s(12,"label",13,2),U(14),l()()),t&2){let a=Fe(2);C("labelPosition",n.labelPosition),c(4),p("mdc-checkbox--selected",n.checked),C("checked",n.checked)("indeterminate",n.indeterminate)("disabled",n.disabled&&!n.disabledInteractive)("id",n.inputId)("required",n.required)("tabIndex",n.disabled&&!n.disabledInteractive?-1:n.tabIndex),Z("aria-label",n.ariaLabel||null)("aria-labelledby",n.ariaLabelledby)("aria-describedby",n.ariaDescribedby)("aria-checked",n.indeterminate?"mixed":null)("aria-controls",n.ariaControls)("aria-disabled",n.disabled&&n.disabledInteractive?!0:null)("aria-expanded",n.ariaExpanded)("aria-owns",n.ariaOwns)("name",n.name)("value",n.value),c(7),C("matRippleTrigger",a)("matRippleDisabled",n.disableRipple||n.disabled)("matRippleCentered",!0),c(),C("for",n.inputId)}},dependencies:[ko,ap],styles:[`.mdc-checkbox {
3996
3996
  display: inline-block;
3997
3997
  position: relative;
3998
3998
  flex: 0 0 18px;
@@ -4465,7 +4465,7 @@ MY_API_KEY=secret`,1,"env-textarea"],["align","end"],["mat-stroked-button","",3,
4465
4465
  .mdc-checkbox__native-control:focus-visible ~ .mat-focus-indicator::before {
4466
4466
  content: "";
4467
4467
  }
4468
- `],encapsulation:2})}return i})(),Oo=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Nc,ee]})}return i})();var Lc=(()=>{class i{get vertical(){return this._vertical}set vertical(e){this._vertical=mt(e)}_vertical=!1;get inset(){return this._inset}set inset(e){this._inset=mt(e)}_inset=!1;static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-divider"]],hostAttrs:["role","separator",1,"mat-divider"],hostVars:7,hostBindings:function(t,n){t&2&&(Z("aria-orientation",n.vertical?"vertical":"horizontal"),p("mat-divider-vertical",n.vertical)("mat-divider-horizontal",!n.vertical)("mat-divider-inset",n.inset))},inputs:{vertical:"vertical",inset:"inset"},decls:0,vars:0,template:function(t,n){},styles:[`.mat-divider {
4468
+ `],encapsulation:2})}return i})(),Fo=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Lc,ee]})}return i})();var Vc=(()=>{class i{get vertical(){return this._vertical}set vertical(e){this._vertical=mt(e)}_vertical=!1;get inset(){return this._inset}set inset(e){this._inset=mt(e)}_inset=!1;static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-divider"]],hostAttrs:["role","separator",1,"mat-divider"],hostVars:7,hostBindings:function(t,n){t&2&&(Z("aria-orientation",n.vertical?"vertical":"horizontal"),p("mat-divider-vertical",n.vertical)("mat-divider-horizontal",!n.vertical)("mat-divider-inset",n.inset))},inputs:{vertical:"vertical",inset:"inset"},decls:0,vars:0,template:function(t,n){},styles:[`.mat-divider {
4469
4469
  display: block;
4470
4470
  margin: 0;
4471
4471
  border-top-style: solid;
@@ -4485,7 +4485,7 @@ MY_API_KEY=secret`,1,"env-textarea"],["align","end"],["mat-stroked-button","",3,
4485
4485
  margin-left: auto;
4486
4486
  margin-right: 80px;
4487
4487
  }
4488
- `],encapsulation:2})}return i})(),Ss=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();var Wb=["*"],qb=`.mdc-list {
4488
+ `],encapsulation:2})}return i})(),As=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ee]})}return i})();var Wb=["*"],qb=`.mdc-list {
4489
4489
  margin: 0;
4490
4490
  padding: 8px 0;
4491
4491
  list-style-type: none;
@@ -5029,7 +5029,7 @@ mat-action-list button::-moz-focus-inner {
5029
5029
  .mat-mdc-nav-list .mat-mdc-list-item.mdc-list-item--activated {
5030
5030
  background-color: var(--mat-list-active-indicator-color, var(--mat-sys-secondary-container));
5031
5031
  }
5032
- `,Kb=["unscopedContent"],Yb=["text"],Xb=[[["","matListItemAvatar",""],["","matListItemIcon",""]],[["","matListItemTitle",""]],[["","matListItemLine",""]],"*",[["","matListItemMeta",""]],[["mat-divider"]]],Zb=["[matListItemAvatar],[matListItemIcon]","[matListItemTitle]","[matListItemLine]","*","[matListItemMeta]","mat-divider"];var Qb=new C("ListOption"),Jb=(()=>{class i{_elementRef=d(N);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matListItemTitle",""]],hostAttrs:[1,"mat-mdc-list-item-title","mdc-list-item__primary-text"]})}return i})(),e0=(()=>{class i{_elementRef=d(N);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matListItemLine",""]],hostAttrs:[1,"mat-mdc-list-item-line","mdc-list-item__secondary-text"]})}return i})(),t0=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matListItemMeta",""]],hostAttrs:[1,"mat-mdc-list-item-meta","mdc-list-item__end"]})}return i})(),rp=(()=>{class i{_listOption=d(Qb,{optional:!0});_isAlignedAtStart(){return!this._listOption||this._listOption?._getTogglePosition()==="after"}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,hostVars:4,hostBindings:function(t,n){t&2&&p("mdc-list-item__start",n._isAlignedAtStart())("mdc-list-item__end",!n._isAlignedAtStart())}})}return i})(),i0=(()=>{class i extends rp{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matListItemAvatar",""]],hostAttrs:[1,"mat-mdc-list-item-avatar"],features:[Q]})}return i})(),n0=(()=>{class i extends rp{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matListItemIcon",""]],hostAttrs:[1,"mat-mdc-list-item-icon"],features:[Q]})}return i})(),o0=new C("MAT_LIST_CONFIG"),Vc=(()=>{class i{_isNonInteractive=!0;get disableRipple(){return this._disableRipple}set disableRipple(e){this._disableRipple=mt(e)}_disableRipple=!1;get disabled(){return this._disabled()}set disabled(e){this._disabled.set(mt(e))}_disabled=R(!1);_defaultOptions=d(o0,{optional:!0});static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,hostVars:1,hostBindings:function(t,n){t&2&&Z("aria-disabled",n.disabled)},inputs:{disableRipple:"disableRipple",disabled:"disabled"}})}return i})(),a0=(()=>{class i{_elementRef=d(N);_ngZone=d(H);_listBase=d(Vc,{optional:!0});_platform=d(le);_hostElement;_isButtonElement;_noopAnimations=pe();_avatars;_icons;set lines(e){this._explicitLines=Ht(e,null),this._updateItemLines(!1)}_explicitLines=null;get disableRipple(){return this.disabled||this._disableRipple||this._noopAnimations||!!this._listBase?.disableRipple}set disableRipple(e){this._disableRipple=mt(e)}_disableRipple=!1;get disabled(){return this._disabled()||!!this._listBase?.disabled}set disabled(e){this._disabled.set(mt(e))}_disabled=R(!1);_subscriptions=new De;_rippleRenderer=null;_hasUnscopedTextContent=!1;rippleConfig;get rippleDisabled(){return this.disableRipple||!!this.rippleConfig.disabled}constructor(){d(Fe).load(Mt);let e=d(jn,{optional:!0});this.rippleConfig=e||{},this._hostElement=this._elementRef.nativeElement,this._isButtonElement=this._hostElement.nodeName.toLowerCase()==="button",this._listBase&&!this._listBase._isNonInteractive&&this._initInteractiveListItem(),this._isButtonElement&&!this._hostElement.hasAttribute("type")&&this._hostElement.setAttribute("type","button")}ngAfterViewInit(){this._monitorProjectedLinesAndTitle(),this._updateItemLines(!0)}ngOnDestroy(){this._subscriptions.unsubscribe(),this._rippleRenderer!==null&&this._rippleRenderer._removeTriggerEvents()}_hasIconOrAvatar(){return!!(this._avatars.length||this._icons.length)}_initInteractiveListItem(){this._hostElement.classList.add("mat-mdc-list-item-interactive"),this._rippleRenderer=new zn(this,this._ngZone,this._hostElement,this._platform,d(X)),this._rippleRenderer.setupTriggerEvents(this._hostElement)}_monitorProjectedLinesAndTitle(){this._ngZone.runOutsideAngular(()=>{this._subscriptions.add($e(this._lines.changes,this._titles.changes).subscribe(()=>this._updateItemLines(!1)))})}_updateItemLines(e){if(!this._lines||!this._titles||!this._unscopedContent)return;e&&this._checkDomForUnscopedTextContent();let t=this._explicitLines??this._inferLinesFromContent(),n=this._unscopedContent.nativeElement;if(this._hostElement.classList.toggle("mat-mdc-list-item-single-line",t<=1),this._hostElement.classList.toggle("mdc-list-item--with-one-line",t<=1),this._hostElement.classList.toggle("mdc-list-item--with-two-lines",t===2),this._hostElement.classList.toggle("mdc-list-item--with-three-lines",t===3),this._hasUnscopedTextContent){let a=this._titles.length===0&&t===1;n.classList.toggle("mdc-list-item__primary-text",a),n.classList.toggle("mdc-list-item__secondary-text",!a)}else n.classList.remove("mdc-list-item__primary-text"),n.classList.remove("mdc-list-item__secondary-text")}_inferLinesFromContent(){let e=this._titles.length+this._lines.length;return this._hasUnscopedTextContent&&(e+=1),e}_checkDomForUnscopedTextContent(){this._hasUnscopedTextContent=Array.from(this._unscopedContent.nativeElement.childNodes).filter(e=>e.nodeType!==e.COMMENT_NODE).some(e=>!!(e.textContent&&e.textContent.trim()))}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,contentQueries:function(t,n,a){if(t&1&&at(a,i0,4)(a,n0,4),t&2){let r;O(r=P())&&(n._avatars=r),O(r=P())&&(n._icons=r)}},hostVars:4,hostBindings:function(t,n){t&2&&(Z("aria-disabled",n.disabled)("disabled",n._isButtonElement&&n.disabled||null),p("mdc-list-item--disabled",n.disabled))},inputs:{lines:"lines",disableRipple:"disableRipple",disabled:"disabled"}})}return i})();var sp=(()=>{class i extends Vc{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275cmp=T({type:i,selectors:[["mat-list"]],hostAttrs:[1,"mat-mdc-list","mat-mdc-list-base","mdc-list"],exportAs:["matList"],features:[J([{provide:Vc,useExisting:i}]),Q],ngContentSelectors:Wb,decls:1,vars:0,template:function(t,n){t&1&&(ce(),U(0))},styles:[qb],encapsulation:2})}return i})(),lp=(()=>{class i extends a0{_lines;_titles;_meta;_unscopedContent;_itemText;get activated(){return this._activated}set activated(e){this._activated=mt(e)}_activated=!1;_getAriaCurrent(){return this._hostElement.nodeName==="A"&&this._activated?"page":null}_hasBothLeadingAndTrailing(){return this._meta.length!==0&&(this._avatars.length!==0||this._icons.length!==0)}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275cmp=T({type:i,selectors:[["mat-list-item"],["a","mat-list-item",""],["button","mat-list-item",""]],contentQueries:function(t,n,a){if(t&1&&at(a,e0,5)(a,Jb,5)(a,t0,5),t&2){let r;O(r=P())&&(n._lines=r),O(r=P())&&(n._titles=r),O(r=P())&&(n._meta=r)}},viewQuery:function(t,n){if(t&1&&Me(Kb,5)(Yb,5),t&2){let a;O(a=P())&&(n._unscopedContent=a.first),O(a=P())&&(n._itemText=a.first)}},hostAttrs:[1,"mat-mdc-list-item","mdc-list-item"],hostVars:13,hostBindings:function(t,n){t&2&&(Z("aria-current",n._getAriaCurrent()),p("mdc-list-item--activated",n.activated)("mdc-list-item--with-leading-avatar",n._avatars.length!==0)("mdc-list-item--with-leading-icon",n._icons.length!==0)("mdc-list-item--with-trailing-meta",n._meta.length!==0)("mat-mdc-list-item-both-leading-and-trailing",n._hasBothLeadingAndTrailing())("_mat-animation-noopable",n._noopAnimations))},inputs:{activated:"activated"},exportAs:["matListItem"],features:[Q],ngContentSelectors:Zb,decls:10,vars:0,consts:[["unscopedContent",""],[1,"mdc-list-item__content"],[1,"mat-mdc-list-item-unscoped-content",3,"cdkObserveContent"],[1,"mat-focus-indicator"]],template:function(t,n){t&1&&(ce(Xb),U(0),s(1,"span",1),U(2,1),U(3,2),s(4,"span",2,0),A("cdkObserveContent",function(){return n._updateItemLines(!0)}),U(6,3),l()(),U(7,4),U(8,5),v(9,"div",3))},dependencies:[Vm],encapsulation:2})}return i})();var cp=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ho,Ti,ks,ee,Ss]})}return i})();function r0(i,o){i&1&&v(0,"mat-progress-bar",5)}function s0(i,o){i&1&&(s(0,"span",13),m(1,"(removed)"),l())}function l0(i,o){i&1&&(s(0,"mat-icon"),m(1,"check_box"),l())}function c0(i,o){i&1&&(s(0,"mat-icon"),m(1,"check_box_outline_blank"),l())}function d0(i,o){if(i&1){let e=Ue();s(0,"mat-list-item")(1,"div",11)(2,"span",12),m(3),l(),M(4,s0,2,0,"span",13),s(5,"button",14),A("click",function(){let n=xe(e).$implicit,a=D(3);return we(a.toggle(n))}),M(6,l0,2,0,"mat-icon")(7,c0,2,0,"mat-icon"),l()()()}if(i&2){let e=o.$implicit,t=D(3);p("orphaned",t.isOrphaned(e)),c(3),q(e),c(),E(t.isOrphaned(e)?4:-1),c(),Z("aria-label","Toggle "+e),c(),E(t.isManaged(e)?6:7)}}function m0(i,o){if(i&1&&(s(0,"mat-list"),me(1,d0,8,6,"mat-list-item",10,xt),l()),i&2){let e=D(2);c(),ue(e.filteredServices)}}function u0(i,o){if(i&1&&m(0),i&2){let e=D(3);he(' No services match "',e.filter(),'" ')}}function h0(i,o){i&1&&m(0," No installed services found ")}function p0(i,o){if(i&1&&(s(0,"p",9),M(1,u0,1,1)(2,h0,1,0),l()),i&2){let e=D(2);c(),E(e.filter()?1:2)}}function f0(i,o){if(i&1&&(s(0,"div",6),M(1,m0,3,0,"mat-list")(2,p0,3,1,"p",9),l()),i&2){let e=D();c(),E(e.filteredServices.length>0?1:2)}}var mp=(()=>{class i{constructor(){this.serviceService=d(_t),this.dialogRef=d(gt),this.available=R([]),this.managed=R(new Set),this.orphaned=R(new Set),this.loading=R(!0),this.filter=R("")}ngOnInit(){return ye(this,null,function*(){try{let[e,t]=yield Promise.all([Te(this.serviceService.listAvailableServices()),Te(this.serviceService.listManagedServices())]);this.available.set(e),this.managed.set(new Set(t));let n=new Set(e),a=t.filter(r=>!n.has(r));this.orphaned.set(new Set(a))}catch(e){console.error("[ManagedServicesDialog] load error:",e)}finally{this.loading.set(!1)}})}get filteredServices(){let e=this.available(),t=this.orphaned(),n=[...new Set([...e,...t])].sort(),a=this.filter();if(!a)return n;let r=a.toLowerCase();return n.filter(u=>u.toLowerCase().includes(r))}isOrphaned(e){return this.orphaned().has(e)}isManaged(e){return this.managed().has(e)}toggle(e){return ye(this,null,function*(){try{this.isManaged(e)?yield Te(this.serviceService.removeManagedService(e)):yield Te(this.serviceService.addManagedService(e));let t=new Set(this.managed());t.has(e)?t.delete(e):t.add(e),this.managed.set(t)}catch(t){console.error(`[ManagedServicesDialog] toggle error (${e}):`,t)}})}close(){this.dialogRef.close(!0)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-managed-services-dialog"]],decls:13,vars:2,consts:[[1,"dialog-container"],["mat-dialog-title",""],[1,"dialog-description"],["appearance","outline",1,"filter-field"],["matInput","","placeholder","Filter services...",3,"input","value"],["mode","indeterminate"],[1,"services-list"],["align","end"],["mat-raised-button","","color","primary",3,"click"],[1,"no-services"],[3,"orphaned"],[1,"service-row"],[1,"service-name"],[1,"orphaned-hint"],["mat-icon-button","",3,"click"]],template:function(t,n){t&1&&(s(0,"div",0)(1,"h2",1),m(2,"Manage services"),l(),s(3,"mat-dialog-content")(4,"p",2),m(5,"Select which system services to control."),l(),s(6,"mat-form-field",3)(7,"input",4),A("input",function(r){return n.filter.set(r.target.value)}),l()(),M(8,r0,1,0,"mat-progress-bar",5)(9,f0,3,1,"div",6),l(),s(10,"mat-dialog-actions",7)(11,"button",8),A("click",function(){return n.close()}),m(12,"Done"),l()()()),t&2&&(c(7),x("value",n.filter()),c(),E(n.loading()?8:9))},dependencies:[Ve,Qe,it,Hi,Lt,oi,ri,ai,Oo,cp,sp,lp,Si,en,St,kt,ti,ei,Ft,Pt],styles:[".dialog-container[_ngcontent-%COMP%]{min-width:400px;max-width:500px}mat-dialog-title[_ngcontent-%COMP%]{margin-bottom:8px}.dialog-description[_ngcontent-%COMP%]{margin:0 0 12px;color:#666;font-size:.9rem}.filter-field[_ngcontent-%COMP%]{width:100%;margin-bottom:8px}.services-list[_ngcontent-%COMP%]{max-height:400px;overflow-y:auto}.service-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;width:100%}.service-row[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{margin-left:auto;flex-shrink:0}.service-name[_ngcontent-%COMP%]{font-family:monospace;font-size:.95rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}.no-services[_ngcontent-%COMP%]{text-align:center;color:#999;font-size:.9rem;padding:16px 0}mat-list-item.orphaned[_ngcontent-%COMP%] .service-name[_ngcontent-%COMP%]{color:#999}mat-list-item.orphaned[_ngcontent-%COMP%] .orphaned-hint[_ngcontent-%COMP%]{color:#bbb;font-size:.8rem;font-style:italic;margin-right:8px}"]})}}return i})();var up=(i,o)=>o.name;function g0(i,o){i&1&&v(0,"mat-progress-bar",7)}function _0(i,o){if(i&1){let e=Ue();s(0,"div",11)(1,"span",12),m(2),l(),s(3,"button",13),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.archive(n.name))}),s(4,"mat-icon"),m(5,"archive"),l()()()}if(i&2){let e=o.$implicit,t=D(2);c(),x("title",e.name),c(),q(e.name),c(),x("disabled",t.busy()!==null)}}function v0(i,o){if(i&1&&me(0,_0,6,3,"div",11,up),i&2){let e=D();ue(e.active())}}function b0(i,o){i&1&&(s(0,"p",8),m(1,"No services"),l())}function y0(i,o){i&1&&v(0,"mat-progress-bar",7)}function C0(i,o){if(i&1){let e=Ue();s(0,"div",11)(1,"span",12),m(2),l(),s(3,"button",14),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.restore(n.name))}),s(4,"mat-icon"),m(5,"unarchive"),l()()()}if(i&2){let e=o.$implicit,t=D(2);c(),x("title",e.name),c(),q(e.name),c(),x("disabled",t.busy()!==null)}}function x0(i,o){if(i&1&&me(0,C0,6,3,"div",11,up),i&2){let e=D();ue(e.archived())}}function w0(i,o){i&1&&(s(0,"p",8),m(1,"Archive is empty"),l())}var hp=(()=>{class i{constructor(){this.serviceService=d(_t),this.dialogRef=d(gt),this.snackBar=d(ys),this.active=R([]),this.archived=R([]),this.loading=R(!0),this.busy=R(null),this.dirty=!1}ngOnInit(){return ye(this,null,function*(){try{let[e,t]=yield Promise.all([Te(this.serviceService.fetchConfigs()),Te(this.serviceService.fetchArchivedConfigs())]);this.active.set(e),this.archived.set(t)}catch(e){console.error("[ArchiveDialog] load error:",e)}finally{this.loading.set(!1)}})}archive(e){return ye(this,null,function*(){this.busy.set(e);try{yield Te(this.serviceService.archiveService(e)),this.move(e,this.active,this.archived),this.dirty=!0}catch(t){this.showError(`Archive "${e}": ${String(t)}`)}finally{this.busy.set(null)}})}restore(e){return ye(this,null,function*(){this.busy.set(e);try{yield Te(this.serviceService.restoreService(e)),this.move(e,this.archived,this.active),this.dirty=!0}catch(t){this.showError(`Restore "${e}": ${String(t)}`)}finally{this.busy.set(null)}})}move(e,t,n){let a=t().find(r=>r.name===e);a&&(t.set(t().filter(r=>r.name!==e)),n.set([...n(),a].sort((r,u)=>r.name.localeCompare(u.name))))}showError(e){this.snackBar.open(e,"Dismiss",{duration:6e3,horizontalPosition:"center",verticalPosition:"top"})}close(){this.dialogRef.close(this.dirty)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-archive-dialog"]],decls:28,vars:2,consts:[[1,"dialog-container"],["mat-dialog-title",""],[1,"dialog-description"],[1,"panels"],[1,"panel"],[1,"panel-header"],[1,"panel-list"],["mode","indeterminate"],[1,"empty-panel"],["align","end"],["mat-raised-button","","color","primary",3,"click"],[1,"panel-item"],[1,"item-name",3,"title"],["mat-icon-button","","title","Move to archive",1,"move-btn",3,"click","disabled"],["mat-icon-button","","title","Restore from archive",1,"move-btn",3,"click","disabled"]],template:function(t,n){t&1&&(s(0,"div",0)(1,"h2",1),m(2,"Archive"),l(),s(3,"mat-dialog-content")(4,"p",2),m(5," Move a service to the archive to stop, uninstall, and shelve its config. Restore it any time from the archive. "),l(),s(6,"div",3)(7,"div",4)(8,"div",5)(9,"mat-icon"),m(10,"apps"),l(),m(11," Services "),l(),s(12,"div",6),M(13,g0,1,0,"mat-progress-bar",7)(14,v0,2,0)(15,b0,2,0,"p",8),l()(),s(16,"div",4)(17,"div",5)(18,"mat-icon"),m(19,"archive"),l(),m(20," Archive "),l(),s(21,"div",6),M(22,y0,1,0,"mat-progress-bar",7)(23,x0,2,0)(24,w0,2,0,"p",8),l()()()(),s(25,"mat-dialog-actions",9)(26,"button",10),A("click",function(){return n.close()}),m(27,"Done"),l()()()),t&2&&(c(13),E(n.loading()?13:n.active().length>0?14:15),c(9),E(n.loading()?22:n.archived().length>0?23:24))},dependencies:[Ve,Qe,it,Hi,Lt,oi,ri,ai,Si,en,Ft,Pt],styles:[".dialog-container[_ngcontent-%COMP%]{min-width:840px;max-width:960px}mat-dialog-title[_ngcontent-%COMP%]{margin-bottom:8px}.dialog-description[_ngcontent-%COMP%]{margin:0 0 16px;color:#666;font-size:.9rem}.panels[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:16px}.panel[_ngcontent-%COMP%]{display:flex;flex-direction:column;border:1px solid #e0e0e0;border-radius:8px;overflow:hidden}.panel-header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;padding:8px 12px;font-weight:600;font-size:.9rem;background-color:#f5f5f5;border-bottom:1px solid #e0e0e0}.panel-header[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:1.2rem;width:1.2rem;height:1.2rem}.panel-list[_ngcontent-%COMP%]{padding:4px 0;max-height:360px;overflow-y:auto}.panel-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;padding:4px 12px}.panel-item[_ngcontent-%COMP%]:hover{background-color:#f5f5f5}.item-name[_ngcontent-%COMP%]{flex:1;font-family:monospace;font-size:.9rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.move-btn[_ngcontent-%COMP%]{flex-shrink:0}.empty-panel[_ngcontent-%COMP%]{text-align:center;color:#999;font-size:.9rem;padding:16px 0}"]})}}return i})();var pp=new C("CdkAccordion");var fp=(()=>{class i{accordion=d(pp,{optional:!0,skipSelf:!0});_changeDetectorRef=d(te);_expansionDispatcher=d(Ma);_openCloseAllSubscription=De.EMPTY;closed=new K;opened=new K;destroyed=new K;expandedChange=new K;id=d(be).getId("cdk-accordion-child-");get expanded(){return this._expanded}set expanded(e){if(this._expanded!==e){if(this._expanded=e,this.expandedChange.emit(e),e){this.opened.emit();let t=this.accordion?this.accordion.id:this.id;this._expansionDispatcher.notify(this.id,t)}else this.closed.emit();this._changeDetectorRef.markForCheck()}}_expanded=!1;get disabled(){return this._disabled()}set disabled(e){this._disabled.set(e)}_disabled=R(!1);_removeUniqueSelectionListener=()=>{};ngOnInit(){this._removeUniqueSelectionListener=this._expansionDispatcher.listen((e,t)=>{this.accordion&&!this.accordion.multi&&this.accordion.id===t&&this.id!==e&&(this.expanded=!1)}),this.accordion&&(this._openCloseAllSubscription=this._subscribeToOpenCloseAllActions())}ngOnDestroy(){this.opened.complete(),this.closed.complete(),this.destroyed.emit(),this.destroyed.complete(),this._removeUniqueSelectionListener(),this._openCloseAllSubscription.unsubscribe()}toggle(){this.disabled||(this.expanded=!this.expanded)}close(){this.disabled||(this.expanded=!1)}open(){this.disabled||(this.expanded=!0)}_subscribeToOpenCloseAllActions(){return this.accordion._openCloseAllActions.subscribe(e=>{this.disabled||(this.expanded=e)})}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["cdk-accordion-item"],["","cdkAccordionItem",""]],inputs:{expanded:[2,"expanded","expanded",L],disabled:[2,"disabled","disabled",L]},outputs:{closed:"closed",opened:"opened",destroyed:"destroyed",expandedChange:"expandedChange"},exportAs:["cdkAccordionItem"],features:[J([{provide:pp,useValue:void 0}])]})}return i})(),gp=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();var D0=["body"],k0=["bodyWrapper"],S0=[[["mat-expansion-panel-header"]],"*",[["mat-action-row"]]],M0=["mat-expansion-panel-header","*","mat-action-row"];function E0(i,o){}var A0=[[["mat-panel-title"]],[["mat-panel-description"]],"*"],T0=["mat-panel-title","mat-panel-description","*"];function I0(i,o){i&1&&(Ie(0,"span",1),wi(),Ie(1,"svg",2),ht(2,"path",3),je()())}var _p=new C("MAT_ACCORDION"),vp=new C("MAT_EXPANSION_PANEL"),R0=(()=>{class i{_template=d(Ye);_expansionPanel=d(vp,{optional:!0});static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["ng-template","matExpansionPanelContent",""]]})}return i})(),bp=new C("MAT_EXPANSION_PANEL_DEFAULT_OPTIONS"),Ba=(()=>{class i extends fp{_viewContainerRef=d(Xe);_animationsDisabled=pe();_document=d($);_ngZone=d(H);_elementRef=d(N);_renderer=d(ve);_cleanupTransitionEnd;get hideToggle(){return this._hideToggle||this.accordion&&this.accordion.hideToggle}set hideToggle(e){this._hideToggle=e}_hideToggle=!1;get togglePosition(){return this._togglePosition||this.accordion&&this.accordion.togglePosition}set togglePosition(e){this._togglePosition=e}_togglePosition;afterExpand=new K;afterCollapse=new K;_inputChanges=new I;accordion=d(_p,{optional:!0,skipSelf:!0});_lazyContent;_body;_bodyWrapper;_portal;_headerId=d(be).getId("mat-expansion-panel-header-");constructor(){super();let e=d(bp,{optional:!0});this._expansionDispatcher=d(Ma),e&&(this.hideToggle=e.hideToggle)}_hasSpacing(){return this.accordion?this.expanded&&this.accordion.displayMode==="default":!1}_getExpandedState(){return this.expanded?"expanded":"collapsed"}toggle(){this.expanded=!this.expanded}close(){this.expanded=!1}open(){this.expanded=!0}ngAfterContentInit(){this._lazyContent&&this._lazyContent._expansionPanel===this&&this.opened.pipe(ke(null),Ce(()=>this.expanded&&!this._portal),ct(1)).subscribe(()=>{this._portal=new Et(this._lazyContent._template,this._viewContainerRef)}),this._setupAnimationEvents()}ngOnChanges(e){this._inputChanges.next(e)}ngOnDestroy(){super.ngOnDestroy(),this._cleanupTransitionEnd?.(),this._inputChanges.complete()}_containsFocus(){if(this._body){let e=this._document.activeElement,t=this._body.nativeElement;return e===t||t.contains(e)}return!1}_transitionEndListener=({target:e,propertyName:t})=>{e===this._bodyWrapper?.nativeElement&&t==="grid-template-rows"&&this._ngZone.run(()=>{this.expanded?this.afterExpand.emit():this.afterCollapse.emit()})};_setupAnimationEvents(){this._ngZone.runOutsideAngular(()=>{this._animationsDisabled?(this.opened.subscribe(()=>this._ngZone.run(()=>this.afterExpand.emit())),this.closed.subscribe(()=>this._ngZone.run(()=>this.afterCollapse.emit()))):setTimeout(()=>{let e=this._elementRef.nativeElement;this._cleanupTransitionEnd=this._renderer.listen(e,"transitionend",this._transitionEndListener),e.classList.add("mat-expansion-panel-animations-enabled")},200)})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-expansion-panel"]],contentQueries:function(t,n,a){if(t&1&&at(a,R0,5),t&2){let r;O(r=P())&&(n._lazyContent=r.first)}},viewQuery:function(t,n){if(t&1&&Me(D0,5)(k0,5),t&2){let a;O(a=P())&&(n._body=a.first),O(a=P())&&(n._bodyWrapper=a.first)}},hostAttrs:[1,"mat-expansion-panel"],hostVars:4,hostBindings:function(t,n){t&2&&p("mat-expanded",n.expanded)("mat-expansion-panel-spacing",n._hasSpacing())},inputs:{hideToggle:[2,"hideToggle","hideToggle",L],togglePosition:"togglePosition"},outputs:{afterExpand:"afterExpand",afterCollapse:"afterCollapse"},exportAs:["matExpansionPanel"],features:[J([{provide:_p,useValue:void 0},{provide:vp,useExisting:i}]),Q,Se],ngContentSelectors:M0,decls:9,vars:4,consts:[["bodyWrapper",""],["body",""],[1,"mat-expansion-panel-content-wrapper"],["role","region",1,"mat-expansion-panel-content",3,"id"],[1,"mat-expansion-panel-body"],[3,"cdkPortalOutlet"]],template:function(t,n){t&1&&(ce(S0),U(0),s(1,"div",2,0)(3,"div",3,1)(5,"div",4),U(6,1),ze(7,E0,0,0,"ng-template",5),l(),U(8,2),l()()),t&2&&(c(),Z("inert",n.expanded?null:""),c(2),x("id",n.id),Z("aria-labelledby",n._headerId),c(4),x("cdkPortalOutlet",n._portal))},dependencies:[Ri],styles:[`.mat-expansion-panel {
5032
+ `,Kb=["unscopedContent"],Yb=["text"],Xb=[[["","matListItemAvatar",""],["","matListItemIcon",""]],[["","matListItemTitle",""]],[["","matListItemLine",""]],"*",[["","matListItemMeta",""]],[["mat-divider"]]],Zb=["[matListItemAvatar],[matListItemIcon]","[matListItemTitle]","[matListItemLine]","*","[matListItemMeta]","mat-divider"];var Qb=new x("ListOption"),Jb=(()=>{class i{_elementRef=d(N);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matListItemTitle",""]],hostAttrs:[1,"mat-mdc-list-item-title","mdc-list-item__primary-text"]})}return i})(),e0=(()=>{class i{_elementRef=d(N);static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matListItemLine",""]],hostAttrs:[1,"mat-mdc-list-item-line","mdc-list-item__secondary-text"]})}return i})(),t0=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matListItemMeta",""]],hostAttrs:[1,"mat-mdc-list-item-meta","mdc-list-item__end"]})}return i})(),rp=(()=>{class i{_listOption=d(Qb,{optional:!0});_isAlignedAtStart(){return!this._listOption||this._listOption?._getTogglePosition()==="after"}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,hostVars:4,hostBindings:function(t,n){t&2&&p("mdc-list-item__start",n._isAlignedAtStart())("mdc-list-item__end",!n._isAlignedAtStart())}})}return i})(),i0=(()=>{class i extends rp{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matListItemAvatar",""]],hostAttrs:[1,"mat-mdc-list-item-avatar"],features:[Q]})}return i})(),n0=(()=>{class i extends rp{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275dir=k({type:i,selectors:[["","matListItemIcon",""]],hostAttrs:[1,"mat-mdc-list-item-icon"],features:[Q]})}return i})(),o0=new x("MAT_LIST_CONFIG"),Bc=(()=>{class i{_isNonInteractive=!0;get disableRipple(){return this._disableRipple}set disableRipple(e){this._disableRipple=mt(e)}_disableRipple=!1;get disabled(){return this._disabled()}set disabled(e){this._disabled.set(mt(e))}_disabled=R(!1);_defaultOptions=d(o0,{optional:!0});static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,hostVars:1,hostBindings:function(t,n){t&2&&Z("aria-disabled",n.disabled)},inputs:{disableRipple:"disableRipple",disabled:"disabled"}})}return i})(),a0=(()=>{class i{_elementRef=d(N);_ngZone=d(H);_listBase=d(Bc,{optional:!0});_platform=d(le);_hostElement;_isButtonElement;_noopAnimations=pe();_avatars;_icons;set lines(e){this._explicitLines=Ht(e,null),this._updateItemLines(!1)}_explicitLines=null;get disableRipple(){return this.disabled||this._disableRipple||this._noopAnimations||!!this._listBase?.disableRipple}set disableRipple(e){this._disableRipple=mt(e)}_disableRipple=!1;get disabled(){return this._disabled()||!!this._listBase?.disabled}set disabled(e){this._disabled.set(mt(e))}_disabled=R(!1);_subscriptions=new De;_rippleRenderer=null;_hasUnscopedTextContent=!1;rippleConfig;get rippleDisabled(){return this.disableRipple||!!this.rippleConfig.disabled}constructor(){d(Ne).load(Mt);let e=d(Un,{optional:!0});this.rippleConfig=e||{},this._hostElement=this._elementRef.nativeElement,this._isButtonElement=this._hostElement.nodeName.toLowerCase()==="button",this._listBase&&!this._listBase._isNonInteractive&&this._initInteractiveListItem(),this._isButtonElement&&!this._hostElement.hasAttribute("type")&&this._hostElement.setAttribute("type","button")}ngAfterViewInit(){this._monitorProjectedLinesAndTitle(),this._updateItemLines(!0)}ngOnDestroy(){this._subscriptions.unsubscribe(),this._rippleRenderer!==null&&this._rippleRenderer._removeTriggerEvents()}_hasIconOrAvatar(){return!!(this._avatars.length||this._icons.length)}_initInteractiveListItem(){this._hostElement.classList.add("mat-mdc-list-item-interactive"),this._rippleRenderer=new Hn(this,this._ngZone,this._hostElement,this._platform,d(X)),this._rippleRenderer.setupTriggerEvents(this._hostElement)}_monitorProjectedLinesAndTitle(){this._ngZone.runOutsideAngular(()=>{this._subscriptions.add($e(this._lines.changes,this._titles.changes).subscribe(()=>this._updateItemLines(!1)))})}_updateItemLines(e){if(!this._lines||!this._titles||!this._unscopedContent)return;e&&this._checkDomForUnscopedTextContent();let t=this._explicitLines??this._inferLinesFromContent(),n=this._unscopedContent.nativeElement;if(this._hostElement.classList.toggle("mat-mdc-list-item-single-line",t<=1),this._hostElement.classList.toggle("mdc-list-item--with-one-line",t<=1),this._hostElement.classList.toggle("mdc-list-item--with-two-lines",t===2),this._hostElement.classList.toggle("mdc-list-item--with-three-lines",t===3),this._hasUnscopedTextContent){let a=this._titles.length===0&&t===1;n.classList.toggle("mdc-list-item__primary-text",a),n.classList.toggle("mdc-list-item__secondary-text",!a)}else n.classList.remove("mdc-list-item__primary-text"),n.classList.remove("mdc-list-item__secondary-text")}_inferLinesFromContent(){let e=this._titles.length+this._lines.length;return this._hasUnscopedTextContent&&(e+=1),e}_checkDomForUnscopedTextContent(){this._hasUnscopedTextContent=Array.from(this._unscopedContent.nativeElement.childNodes).filter(e=>e.nodeType!==e.COMMENT_NODE).some(e=>!!(e.textContent&&e.textContent.trim()))}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,contentQueries:function(t,n,a){if(t&1&&at(a,i0,4)(a,n0,4),t&2){let r;O(r=P())&&(n._avatars=r),O(r=P())&&(n._icons=r)}},hostVars:4,hostBindings:function(t,n){t&2&&(Z("aria-disabled",n.disabled)("disabled",n._isButtonElement&&n.disabled||null),p("mdc-list-item--disabled",n.disabled))},inputs:{lines:"lines",disableRipple:"disableRipple",disabled:"disabled"}})}return i})();var sp=(()=>{class i extends Bc{static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275cmp=T({type:i,selectors:[["mat-list"]],hostAttrs:[1,"mat-mdc-list","mat-mdc-list-base","mdc-list"],exportAs:["matList"],features:[J([{provide:Bc,useExisting:i}]),Q],ngContentSelectors:Wb,decls:1,vars:0,template:function(t,n){t&1&&(ce(),U(0))},styles:[qb],encapsulation:2})}return i})(),lp=(()=>{class i extends a0{_lines;_titles;_meta;_unscopedContent;_itemText;get activated(){return this._activated}set activated(e){this._activated=mt(e)}_activated=!1;_getAriaCurrent(){return this._hostElement.nodeName==="A"&&this._activated?"page":null}_hasBothLeadingAndTrailing(){return this._meta.length!==0&&(this._avatars.length!==0||this._icons.length!==0)}static \u0275fac=(()=>{let e;return function(n){return(e||(e=_e(i)))(n||i)}})();static \u0275cmp=T({type:i,selectors:[["mat-list-item"],["a","mat-list-item",""],["button","mat-list-item",""]],contentQueries:function(t,n,a){if(t&1&&at(a,e0,5)(a,Jb,5)(a,t0,5),t&2){let r;O(r=P())&&(n._lines=r),O(r=P())&&(n._titles=r),O(r=P())&&(n._meta=r)}},viewQuery:function(t,n){if(t&1&&Me(Kb,5)(Yb,5),t&2){let a;O(a=P())&&(n._unscopedContent=a.first),O(a=P())&&(n._itemText=a.first)}},hostAttrs:[1,"mat-mdc-list-item","mdc-list-item"],hostVars:13,hostBindings:function(t,n){t&2&&(Z("aria-current",n._getAriaCurrent()),p("mdc-list-item--activated",n.activated)("mdc-list-item--with-leading-avatar",n._avatars.length!==0)("mdc-list-item--with-leading-icon",n._icons.length!==0)("mdc-list-item--with-trailing-meta",n._meta.length!==0)("mat-mdc-list-item-both-leading-and-trailing",n._hasBothLeadingAndTrailing())("_mat-animation-noopable",n._noopAnimations))},inputs:{activated:"activated"},exportAs:["matListItem"],features:[Q],ngContentSelectors:Zb,decls:10,vars:0,consts:[["unscopedContent",""],[1,"mdc-list-item__content"],[1,"mat-mdc-list-item-unscoped-content",3,"cdkObserveContent"],[1,"mat-focus-indicator"]],template:function(t,n){t&1&&(ce(Xb),U(0),s(1,"span",1),U(2,1),U(3,2),s(4,"span",2,0),A("cdkObserveContent",function(){return n._updateItemLines(!0)}),U(6,3),l()(),U(7,4),U(8,5),v(9,"div",3))},dependencies:[Vm],encapsulation:2})}return i})();var cp=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[fo,Ti,Es,ee,As]})}return i})();function r0(i,o){i&1&&v(0,"mat-progress-bar",5)}function s0(i,o){i&1&&(s(0,"span",13),m(1,"(removed)"),l())}function l0(i,o){i&1&&(s(0,"mat-icon"),m(1,"check_box"),l())}function c0(i,o){i&1&&(s(0,"mat-icon"),m(1,"check_box_outline_blank"),l())}function d0(i,o){if(i&1){let e=Ue();s(0,"mat-list-item")(1,"div",11)(2,"span",12),m(3),l(),M(4,s0,2,0,"span",13),s(5,"button",14),A("click",function(){let n=xe(e).$implicit,a=D(3);return we(a.toggle(n))}),M(6,l0,2,0,"mat-icon")(7,c0,2,0,"mat-icon"),l()()()}if(i&2){let e=o.$implicit,t=D(3);p("orphaned",t.isOrphaned(e)),c(3),q(e),c(),E(t.isOrphaned(e)?4:-1),c(),Z("aria-label","Toggle "+e),c(),E(t.isManaged(e)?6:7)}}function m0(i,o){if(i&1&&(s(0,"mat-list"),me(1,d0,8,6,"mat-list-item",10,xt),l()),i&2){let e=D(2);c(),ue(e.filteredServices)}}function u0(i,o){if(i&1&&m(0),i&2){let e=D(3);he(' No services match "',e.filter(),'" ')}}function h0(i,o){i&1&&m(0," No installed services found ")}function p0(i,o){if(i&1&&(s(0,"p",9),M(1,u0,1,1)(2,h0,1,0),l()),i&2){let e=D(2);c(),E(e.filter()?1:2)}}function f0(i,o){if(i&1&&(s(0,"div",6),M(1,m0,3,0,"mat-list")(2,p0,3,1,"p",9),l()),i&2){let e=D();c(),E(e.filteredServices.length>0?1:2)}}var mp=(()=>{class i{constructor(){this.serviceService=d(_t),this.dialogRef=d(gt),this.available=R([]),this.managed=R(new Set),this.orphaned=R(new Set),this.loading=R(!0),this.filter=R("")}ngOnInit(){return ye(this,null,function*(){try{let[e,t]=yield Promise.all([Te(this.serviceService.listAvailableServices()),Te(this.serviceService.listManagedServices())]);this.available.set(e),this.managed.set(new Set(t));let n=new Set(e),a=t.filter(r=>!n.has(r));this.orphaned.set(new Set(a))}catch(e){console.error("[ManagedServicesDialog] load error:",e)}finally{this.loading.set(!1)}})}get filteredServices(){let e=this.available(),t=this.orphaned(),n=[...new Set([...e,...t])].sort(),a=this.filter();if(!a)return n;let r=a.toLowerCase();return n.filter(u=>u.toLowerCase().includes(r))}isOrphaned(e){return this.orphaned().has(e)}isManaged(e){return this.managed().has(e)}toggle(e){return ye(this,null,function*(){try{this.isManaged(e)?yield Te(this.serviceService.removeManagedService(e)):yield Te(this.serviceService.addManagedService(e));let t=new Set(this.managed());t.has(e)?t.delete(e):t.add(e),this.managed.set(t)}catch(t){console.error(`[ManagedServicesDialog] toggle error (${e}):`,t)}})}close(){this.dialogRef.close(!0)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-managed-services-dialog"]],decls:13,vars:2,consts:[[1,"dialog-container"],["mat-dialog-title",""],[1,"dialog-description"],["appearance","outline",1,"filter-field"],["matInput","","placeholder","Filter services...",3,"input","value"],["mode","indeterminate"],[1,"services-list"],["align","end"],["mat-raised-button","","color","primary",3,"click"],[1,"no-services"],[3,"orphaned"],[1,"service-row"],[1,"service-name"],[1,"orphaned-hint"],["mat-icon-button","",3,"click"]],template:function(t,n){t&1&&(s(0,"div",0)(1,"h2",1),m(2,"Manage services"),l(),s(3,"mat-dialog-content")(4,"p",2),m(5,"Select which system services to control."),l(),s(6,"mat-form-field",3)(7,"input",4),A("input",function(r){return n.filter.set(r.target.value)}),l()(),M(8,r0,1,0,"mat-progress-bar",5)(9,f0,3,1,"div",6),l(),s(10,"mat-dialog-actions",7)(11,"button",8),A("click",function(){return n.close()}),m(12,"Done"),l()()()),t&2&&(c(7),C("value",n.filter()),c(),E(n.loading()?8:9))},dependencies:[Ve,Qe,it,Hi,Lt,oi,ri,ai,Fo,cp,sp,lp,Si,en,St,kt,ti,ei,Ft,Pt],styles:[".dialog-container[_ngcontent-%COMP%]{min-width:400px;max-width:500px}mat-dialog-title[_ngcontent-%COMP%]{margin-bottom:8px}.dialog-description[_ngcontent-%COMP%]{margin:0 0 12px;color:#666;font-size:.9rem}.filter-field[_ngcontent-%COMP%]{width:100%;margin-bottom:8px}.services-list[_ngcontent-%COMP%]{max-height:400px;overflow-y:auto}.service-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;width:100%}.service-row[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{margin-left:auto;flex-shrink:0}.service-name[_ngcontent-%COMP%]{font-family:monospace;font-size:.95rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}.no-services[_ngcontent-%COMP%]{text-align:center;color:#999;font-size:.9rem;padding:16px 0}mat-list-item.orphaned[_ngcontent-%COMP%] .service-name[_ngcontent-%COMP%]{color:#999}mat-list-item.orphaned[_ngcontent-%COMP%] .orphaned-hint[_ngcontent-%COMP%]{color:#bbb;font-size:.8rem;font-style:italic;margin-right:8px}"]})}}return i})();var up=(i,o)=>o.name;function g0(i,o){i&1&&v(0,"mat-progress-bar",7)}function _0(i,o){if(i&1){let e=Ue();s(0,"div",11)(1,"span",12),m(2),l(),s(3,"button",13),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.archive(n.name))}),s(4,"mat-icon"),m(5,"archive"),l()()()}if(i&2){let e=o.$implicit,t=D(2);c(),C("title",e.name),c(),q(e.name),c(),C("disabled",t.busy()!==null)}}function v0(i,o){if(i&1&&me(0,_0,6,3,"div",11,up),i&2){let e=D();ue(e.active())}}function b0(i,o){i&1&&(s(0,"p",8),m(1,"No services"),l())}function y0(i,o){i&1&&v(0,"mat-progress-bar",7)}function C0(i,o){if(i&1){let e=Ue();s(0,"div",11)(1,"span",12),m(2),l(),s(3,"button",14),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.restore(n.name))}),s(4,"mat-icon"),m(5,"unarchive"),l()()()}if(i&2){let e=o.$implicit,t=D(2);c(),C("title",e.name),c(),q(e.name),c(),C("disabled",t.busy()!==null)}}function x0(i,o){if(i&1&&me(0,C0,6,3,"div",11,up),i&2){let e=D();ue(e.archived())}}function w0(i,o){i&1&&(s(0,"p",8),m(1,"Archive is empty"),l())}var hp=(()=>{class i{constructor(){this.serviceService=d(_t),this.dialogRef=d(gt),this.snackBar=d(ws),this.active=R([]),this.archived=R([]),this.loading=R(!0),this.busy=R(null),this.dirty=!1}ngOnInit(){return ye(this,null,function*(){try{let[e,t]=yield Promise.all([Te(this.serviceService.fetchConfigs()),Te(this.serviceService.fetchArchivedConfigs())]);this.active.set(e),this.archived.set(t)}catch(e){console.error("[ArchiveDialog] load error:",e)}finally{this.loading.set(!1)}})}archive(e){return ye(this,null,function*(){this.busy.set(e);try{yield Te(this.serviceService.archiveService(e)),this.move(e,this.active,this.archived),this.dirty=!0}catch(t){this.showError(`Archive "${e}": ${String(t)}`)}finally{this.busy.set(null)}})}restore(e){return ye(this,null,function*(){this.busy.set(e);try{yield Te(this.serviceService.restoreService(e)),this.move(e,this.archived,this.active),this.dirty=!0}catch(t){this.showError(`Restore "${e}": ${String(t)}`)}finally{this.busy.set(null)}})}move(e,t,n){let a=t().find(r=>r.name===e);a&&(t.set(t().filter(r=>r.name!==e)),n.set([...n(),a].sort((r,u)=>r.name.localeCompare(u.name))))}showError(e){this.snackBar.open(e,"Dismiss",{duration:6e3,horizontalPosition:"center",verticalPosition:"top"})}close(){this.dialogRef.close(this.dirty)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-archive-dialog"]],decls:28,vars:2,consts:[[1,"dialog-container"],["mat-dialog-title",""],[1,"dialog-description"],[1,"panels"],[1,"panel"],[1,"panel-header"],[1,"panel-list"],["mode","indeterminate"],[1,"empty-panel"],["align","end"],["mat-raised-button","","color","primary",3,"click"],[1,"panel-item"],[1,"item-name",3,"title"],["mat-icon-button","","title","Move to archive",1,"move-btn",3,"click","disabled"],["mat-icon-button","","title","Restore from archive",1,"move-btn",3,"click","disabled"]],template:function(t,n){t&1&&(s(0,"div",0)(1,"h2",1),m(2,"Archive"),l(),s(3,"mat-dialog-content")(4,"p",2),m(5," Move a service to the archive to stop, uninstall, and shelve its config. Restore it any time from the archive. "),l(),s(6,"div",3)(7,"div",4)(8,"div",5)(9,"mat-icon"),m(10,"apps"),l(),m(11," Services "),l(),s(12,"div",6),M(13,g0,1,0,"mat-progress-bar",7)(14,v0,2,0)(15,b0,2,0,"p",8),l()(),s(16,"div",4)(17,"div",5)(18,"mat-icon"),m(19,"archive"),l(),m(20," Archive "),l(),s(21,"div",6),M(22,y0,1,0,"mat-progress-bar",7)(23,x0,2,0)(24,w0,2,0,"p",8),l()()()(),s(25,"mat-dialog-actions",9)(26,"button",10),A("click",function(){return n.close()}),m(27,"Done"),l()()()),t&2&&(c(13),E(n.loading()?13:n.active().length>0?14:15),c(9),E(n.loading()?22:n.archived().length>0?23:24))},dependencies:[Ve,Qe,it,Hi,Lt,oi,ri,ai,Si,en,Ft,Pt],styles:[".dialog-container[_ngcontent-%COMP%]{min-width:840px;max-width:960px}mat-dialog-title[_ngcontent-%COMP%]{margin-bottom:8px}.dialog-description[_ngcontent-%COMP%]{margin:0 0 16px;color:#666;font-size:.9rem}.panels[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:16px}.panel[_ngcontent-%COMP%]{display:flex;flex-direction:column;border:1px solid #e0e0e0;border-radius:8px;overflow:hidden}.panel-header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;padding:8px 12px;font-weight:600;font-size:.9rem;background-color:#f5f5f5;border-bottom:1px solid #e0e0e0}.panel-header[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:1.2rem;width:1.2rem;height:1.2rem}.panel-list[_ngcontent-%COMP%]{padding:4px 0;max-height:360px;overflow-y:auto}.panel-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;padding:4px 12px}.panel-item[_ngcontent-%COMP%]:hover{background-color:#f5f5f5}.item-name[_ngcontent-%COMP%]{flex:1;font-family:monospace;font-size:.9rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.move-btn[_ngcontent-%COMP%]{flex-shrink:0}.empty-panel[_ngcontent-%COMP%]{text-align:center;color:#999;font-size:.9rem;padding:16px 0}"]})}}return i})();var pp=new x("CdkAccordion");var fp=(()=>{class i{accordion=d(pp,{optional:!0,skipSelf:!0});_changeDetectorRef=d(te);_expansionDispatcher=d(Aa);_openCloseAllSubscription=De.EMPTY;closed=new K;opened=new K;destroyed=new K;expandedChange=new K;id=d(be).getId("cdk-accordion-child-");get expanded(){return this._expanded}set expanded(e){if(this._expanded!==e){if(this._expanded=e,this.expandedChange.emit(e),e){this.opened.emit();let t=this.accordion?this.accordion.id:this.id;this._expansionDispatcher.notify(this.id,t)}else this.closed.emit();this._changeDetectorRef.markForCheck()}}_expanded=!1;get disabled(){return this._disabled()}set disabled(e){this._disabled.set(e)}_disabled=R(!1);_removeUniqueSelectionListener=()=>{};ngOnInit(){this._removeUniqueSelectionListener=this._expansionDispatcher.listen((e,t)=>{this.accordion&&!this.accordion.multi&&this.accordion.id===t&&this.id!==e&&(this.expanded=!1)}),this.accordion&&(this._openCloseAllSubscription=this._subscribeToOpenCloseAllActions())}ngOnDestroy(){this.opened.complete(),this.closed.complete(),this.destroyed.emit(),this.destroyed.complete(),this._removeUniqueSelectionListener(),this._openCloseAllSubscription.unsubscribe()}toggle(){this.disabled||(this.expanded=!this.expanded)}close(){this.disabled||(this.expanded=!1)}open(){this.disabled||(this.expanded=!0)}_subscribeToOpenCloseAllActions(){return this.accordion._openCloseAllActions.subscribe(e=>{this.disabled||(this.expanded=e)})}static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["cdk-accordion-item"],["","cdkAccordionItem",""]],inputs:{expanded:[2,"expanded","expanded",L],disabled:[2,"disabled","disabled",L]},outputs:{closed:"closed",opened:"opened",destroyed:"destroyed",expandedChange:"expandedChange"},exportAs:["cdkAccordionItem"],features:[J([{provide:pp,useValue:void 0}])]})}return i})(),gp=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({})}return i})();var D0=["body"],k0=["bodyWrapper"],S0=[[["mat-expansion-panel-header"]],"*",[["mat-action-row"]]],M0=["mat-expansion-panel-header","*","mat-action-row"];function E0(i,o){}var A0=[[["mat-panel-title"]],[["mat-panel-description"]],"*"],T0=["mat-panel-title","mat-panel-description","*"];function I0(i,o){i&1&&(Ie(0,"span",1),wi(),Ie(1,"svg",2),ht(2,"path",3),je()())}var _p=new x("MAT_ACCORDION"),vp=new x("MAT_EXPANSION_PANEL"),R0=(()=>{class i{_template=d(Ye);_expansionPanel=d(vp,{optional:!0});static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["ng-template","matExpansionPanelContent",""]]})}return i})(),bp=new x("MAT_EXPANSION_PANEL_DEFAULT_OPTIONS"),ja=(()=>{class i extends fp{_viewContainerRef=d(Xe);_animationsDisabled=pe();_document=d(W);_ngZone=d(H);_elementRef=d(N);_renderer=d(ve);_cleanupTransitionEnd;get hideToggle(){return this._hideToggle||this.accordion&&this.accordion.hideToggle}set hideToggle(e){this._hideToggle=e}_hideToggle=!1;get togglePosition(){return this._togglePosition||this.accordion&&this.accordion.togglePosition}set togglePosition(e){this._togglePosition=e}_togglePosition;afterExpand=new K;afterCollapse=new K;_inputChanges=new I;accordion=d(_p,{optional:!0,skipSelf:!0});_lazyContent;_body;_bodyWrapper;_portal;_headerId=d(be).getId("mat-expansion-panel-header-");constructor(){super();let e=d(bp,{optional:!0});this._expansionDispatcher=d(Aa),e&&(this.hideToggle=e.hideToggle)}_hasSpacing(){return this.accordion?this.expanded&&this.accordion.displayMode==="default":!1}_getExpandedState(){return this.expanded?"expanded":"collapsed"}toggle(){this.expanded=!this.expanded}close(){this.expanded=!1}open(){this.expanded=!0}ngAfterContentInit(){this._lazyContent&&this._lazyContent._expansionPanel===this&&this.opened.pipe(ke(null),Ce(()=>this.expanded&&!this._portal),ct(1)).subscribe(()=>{this._portal=new Et(this._lazyContent._template,this._viewContainerRef)}),this._setupAnimationEvents()}ngOnChanges(e){this._inputChanges.next(e)}ngOnDestroy(){super.ngOnDestroy(),this._cleanupTransitionEnd?.(),this._inputChanges.complete()}_containsFocus(){if(this._body){let e=this._document.activeElement,t=this._body.nativeElement;return e===t||t.contains(e)}return!1}_transitionEndListener=({target:e,propertyName:t})=>{e===this._bodyWrapper?.nativeElement&&t==="grid-template-rows"&&this._ngZone.run(()=>{this.expanded?this.afterExpand.emit():this.afterCollapse.emit()})};_setupAnimationEvents(){this._ngZone.runOutsideAngular(()=>{this._animationsDisabled?(this.opened.subscribe(()=>this._ngZone.run(()=>this.afterExpand.emit())),this.closed.subscribe(()=>this._ngZone.run(()=>this.afterCollapse.emit()))):setTimeout(()=>{let e=this._elementRef.nativeElement;this._cleanupTransitionEnd=this._renderer.listen(e,"transitionend",this._transitionEndListener),e.classList.add("mat-expansion-panel-animations-enabled")},200)})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-expansion-panel"]],contentQueries:function(t,n,a){if(t&1&&at(a,R0,5),t&2){let r;O(r=P())&&(n._lazyContent=r.first)}},viewQuery:function(t,n){if(t&1&&Me(D0,5)(k0,5),t&2){let a;O(a=P())&&(n._body=a.first),O(a=P())&&(n._bodyWrapper=a.first)}},hostAttrs:[1,"mat-expansion-panel"],hostVars:4,hostBindings:function(t,n){t&2&&p("mat-expanded",n.expanded)("mat-expansion-panel-spacing",n._hasSpacing())},inputs:{hideToggle:[2,"hideToggle","hideToggle",L],togglePosition:"togglePosition"},outputs:{afterExpand:"afterExpand",afterCollapse:"afterCollapse"},exportAs:["matExpansionPanel"],features:[J([{provide:_p,useValue:void 0},{provide:vp,useExisting:i}]),Q,Se],ngContentSelectors:M0,decls:9,vars:4,consts:[["bodyWrapper",""],["body",""],[1,"mat-expansion-panel-content-wrapper"],["role","region",1,"mat-expansion-panel-content",3,"id"],[1,"mat-expansion-panel-body"],[3,"cdkPortalOutlet"]],template:function(t,n){t&1&&(ce(S0),U(0),s(1,"div",2,0)(3,"div",3,1)(5,"div",4),U(6,1),ze(7,E0,0,0,"ng-template",5),l(),U(8,2),l()()),t&2&&(c(),Z("inert",n.expanded?null:""),c(2),C("id",n.id),Z("aria-labelledby",n._headerId),c(4),C("cdkPortalOutlet",n._portal))},dependencies:[Ri],styles:[`.mat-expansion-panel {
5033
5033
  box-sizing: content-box;
5034
5034
  display: block;
5035
5035
  margin: 0;
@@ -5145,7 +5145,7 @@ mat-action-list button::-moz-focus-inner {
5145
5145
  margin-left: 0;
5146
5146
  margin-right: 8px;
5147
5147
  }
5148
- `],encapsulation:2})}return i})();var Ms=(()=>{class i{panel=d(Ba,{host:!0});_element=d(N);_focusMonitor=d(Rt);_changeDetectorRef=d(te);_parentChangeSubscription=De.EMPTY;constructor(){d(Fe).load(Mt);let e=this.panel,t=d(bp,{optional:!0}),n=d(new Di("tabindex"),{optional:!0}),a=e.accordion?e.accordion._stateChanges.pipe(Ce(r=>!!(r.hideToggle||r.togglePosition))):Ua;this.tabIndex=parseInt(n||"")||0,this._parentChangeSubscription=$e(e.opened,e.closed,a,e._inputChanges.pipe(Ce(r=>!!(r.hideToggle||r.disabled||r.togglePosition)))).subscribe(()=>this._changeDetectorRef.markForCheck()),e.closed.pipe(Ce(()=>e._containsFocus())).subscribe(()=>this._focusMonitor.focusVia(this._element,"program")),t&&(this.expandedHeight=t.expandedHeight,this.collapsedHeight=t.collapsedHeight)}expandedHeight;collapsedHeight;tabIndex=0;get disabled(){return this.panel.disabled}_toggle(){this.disabled||this.panel.toggle()}_isExpanded(){return this.panel.expanded}_getExpandedState(){return this.panel._getExpandedState()}_getPanelId(){return this.panel.id}_getTogglePosition(){return this.panel.togglePosition}_showToggle(){return!this.panel.hideToggle&&!this.panel.disabled}_getHeaderHeight(){let e=this._isExpanded();return e&&this.expandedHeight?this.expandedHeight:!e&&this.collapsedHeight?this.collapsedHeight:null}_keydown(e){switch(e.keyCode){case 32:case 13:Ge(e)||(e.preventDefault(),this._toggle());break;default:this.panel.accordion&&this.panel.accordion._handleHeaderKeydown(e);return}}focus(e,t){e?this._focusMonitor.focusVia(this._element,e,t):this._element.nativeElement.focus(t)}ngAfterViewInit(){this._focusMonitor.monitor(this._element).subscribe(e=>{e&&this.panel.accordion&&this.panel.accordion._handleHeaderFocus(this)})}ngOnDestroy(){this._parentChangeSubscription.unsubscribe(),this._focusMonitor.stopMonitoring(this._element)}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-expansion-panel-header"]],hostAttrs:["role","button",1,"mat-expansion-panel-header","mat-focus-indicator"],hostVars:13,hostBindings:function(t,n){t&1&&A("click",function(){return n._toggle()})("keydown",function(r){return n._keydown(r)}),t&2&&(Z("id",n.panel._headerId)("tabindex",n.disabled?-1:n.tabIndex)("aria-controls",n._getPanelId())("aria-expanded",n._isExpanded())("aria-disabled",n.panel.disabled),He("height",n._getHeaderHeight()),p("mat-expanded",n._isExpanded())("mat-expansion-toggle-indicator-after",n._getTogglePosition()==="after")("mat-expansion-toggle-indicator-before",n._getTogglePosition()==="before"))},inputs:{expandedHeight:"expandedHeight",collapsedHeight:"collapsedHeight",tabIndex:[2,"tabIndex","tabIndex",e=>e==null?0:wt(e)]},ngContentSelectors:T0,decls:5,vars:3,consts:[[1,"mat-content"],[1,"mat-expansion-indicator"],["xmlns","http://www.w3.org/2000/svg","viewBox","0 -960 960 960","aria-hidden","true","focusable","false"],["d","M480-345 240-585l56-56 184 184 184-184 56 56-240 240Z"]],template:function(t,n){t&1&&(ce(A0),Ie(0,"span",0),U(1),U(2,1),U(3,2),je(),M(4,I0,3,0,"span",1)),t&2&&(p("mat-content-hide-toggle",!n._showToggle()),c(4),E(n._showToggle()?4:-1))},styles:[`.mat-expansion-panel-header {
5148
+ `],encapsulation:2})}return i})();var Ts=(()=>{class i{panel=d(ja,{host:!0});_element=d(N);_focusMonitor=d(Rt);_changeDetectorRef=d(te);_parentChangeSubscription=De.EMPTY;constructor(){d(Ne).load(Mt);let e=this.panel,t=d(bp,{optional:!0}),n=d(new Di("tabindex"),{optional:!0}),a=e.accordion?e.accordion._stateChanges.pipe(Ce(r=>!!(r.hideToggle||r.togglePosition))):Wa;this.tabIndex=parseInt(n||"")||0,this._parentChangeSubscription=$e(e.opened,e.closed,a,e._inputChanges.pipe(Ce(r=>!!(r.hideToggle||r.disabled||r.togglePosition)))).subscribe(()=>this._changeDetectorRef.markForCheck()),e.closed.pipe(Ce(()=>e._containsFocus())).subscribe(()=>this._focusMonitor.focusVia(this._element,"program")),t&&(this.expandedHeight=t.expandedHeight,this.collapsedHeight=t.collapsedHeight)}expandedHeight;collapsedHeight;tabIndex=0;get disabled(){return this.panel.disabled}_toggle(){this.disabled||this.panel.toggle()}_isExpanded(){return this.panel.expanded}_getExpandedState(){return this.panel._getExpandedState()}_getPanelId(){return this.panel.id}_getTogglePosition(){return this.panel.togglePosition}_showToggle(){return!this.panel.hideToggle&&!this.panel.disabled}_getHeaderHeight(){let e=this._isExpanded();return e&&this.expandedHeight?this.expandedHeight:!e&&this.collapsedHeight?this.collapsedHeight:null}_keydown(e){switch(e.keyCode){case 32:case 13:Ge(e)||(e.preventDefault(),this._toggle());break;default:this.panel.accordion&&this.panel.accordion._handleHeaderKeydown(e);return}}focus(e,t){e?this._focusMonitor.focusVia(this._element,e,t):this._element.nativeElement.focus(t)}ngAfterViewInit(){this._focusMonitor.monitor(this._element).subscribe(e=>{e&&this.panel.accordion&&this.panel.accordion._handleHeaderFocus(this)})}ngOnDestroy(){this._parentChangeSubscription.unsubscribe(),this._focusMonitor.stopMonitoring(this._element)}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-expansion-panel-header"]],hostAttrs:["role","button",1,"mat-expansion-panel-header","mat-focus-indicator"],hostVars:13,hostBindings:function(t,n){t&1&&A("click",function(){return n._toggle()})("keydown",function(r){return n._keydown(r)}),t&2&&(Z("id",n.panel._headerId)("tabindex",n.disabled?-1:n.tabIndex)("aria-controls",n._getPanelId())("aria-expanded",n._isExpanded())("aria-disabled",n.panel.disabled),He("height",n._getHeaderHeight()),p("mat-expanded",n._isExpanded())("mat-expansion-toggle-indicator-after",n._getTogglePosition()==="after")("mat-expansion-toggle-indicator-before",n._getTogglePosition()==="before"))},inputs:{expandedHeight:"expandedHeight",collapsedHeight:"collapsedHeight",tabIndex:[2,"tabIndex","tabIndex",e=>e==null?0:wt(e)]},ngContentSelectors:T0,decls:5,vars:3,consts:[[1,"mat-content"],[1,"mat-expansion-indicator"],["xmlns","http://www.w3.org/2000/svg","viewBox","0 -960 960 960","aria-hidden","true","focusable","false"],["d","M480-345 240-585l56-56 184 184 184-184 56 56-240 240Z"]],template:function(t,n){t&1&&(ce(A0),Ie(0,"span",0),U(1),U(2,1),U(3,2),je(),M(4,I0,3,0,"span",1)),t&2&&(p("mat-content-hide-toggle",!n._showToggle()),c(4),E(n._showToggle()?4:-1))},styles:[`.mat-expansion-panel-header {
5149
5149
  display: flex;
5150
5150
  flex-direction: row;
5151
5151
  align-items: center;
@@ -5286,7 +5286,7 @@ mat-action-list button::-moz-focus-inner {
5286
5286
  border-top-right-radius: 0;
5287
5287
  }
5288
5288
  }
5289
- `],encapsulation:2})}return i})(),Es=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-panel-description"]],hostAttrs:[1,"mat-expansion-panel-header-description"]})}return i})(),As=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-panel-title"]],hostAttrs:[1,"mat-expansion-panel-header-title"]})}return i})();var Ts=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[gp,Oi,ee]})}return i})();var O0=["trigger"],P0=["panel"],F0=[[["mat-select-trigger"]],"*"],N0=["mat-select-trigger","*"];function L0(i,o){if(i&1&&(s(0,"span",4),m(1),l()),i&2){let e=D();c(),q(e.placeholder)}}function V0(i,o){i&1&&U(0)}function B0(i,o){if(i&1&&(s(0,"span",11),m(1),l()),i&2){let e=D(2);c(),q(e.triggerValue)}}function z0(i,o){if(i&1&&(s(0,"span",5),M(1,V0,1,0)(2,B0,2,1,"span",11),l()),i&2){let e=D();c(),E(e.customTrigger?1:2)}}function j0(i,o){if(i&1){let e=Ue();s(0,"div",12,1),A("keydown",function(n){xe(e);let a=D();return we(a._handleKeydown(n))}),U(2,1),l()}if(i&2){let e=D();et(e.panelClass),p("mat-select-panel-animations-enabled",!e._animationsDisabled)("mat-primary",e._parentFormField?.color==="primary")("mat-accent",e._parentFormField?.color==="accent")("mat-warn",e._parentFormField?.color==="warn")("mat-undefined",!e._parentFormField?.color),Z("id",e.id+"-panel")("aria-multiselectable",e.multiple)("aria-label",e.ariaLabel||null)("aria-labelledby",e._getPanelAriaLabelledby())}}var H0=new C("mat-select-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>yi(i)}}),U0=new C("MAT_SELECT_CONFIG"),G0=new C("MatSelectTrigger"),Bc=class{source;value;constructor(o,e){this.source=o,this.value=e}},Po=(()=>{class i{_viewportRuler=d(Gt);_changeDetectorRef=d(te);_elementRef=d(N);_dir=d(qe,{optional:!0});_idGenerator=d(be);_renderer=d(ve);_parentFormField=d(Bn,{optional:!0});ngControl=d(Jt,{self:!0,optional:!0});_liveAnnouncer=d(ra);_defaultOptions=d(U0,{optional:!0});_animationsDisabled=pe();_popoverLocation;_initialized=new I;_cleanupDetach;options;optionGroups;customTrigger;_positions=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"}];_scrollOptionIntoView(e){let t=this.options.toArray()[e];if(t){let n=this.panel.nativeElement,a=ws(e,this.options,this.optionGroups),r=t._getHostElement();e===0&&a===1?n.scrollTop=0:n.scrollTop=Ds(r.offsetTop,r.offsetHeight,n.scrollTop,n.offsetHeight)}}_positioningSettled(){this._scrollOptionIntoView(this._keyManager.activeItemIndex||0)}_getChangeEvent(e){return new Bc(this,e)}_scrollStrategyFactory=d(H0);_panelOpen=!1;_compareWith=(e,t)=>e===t;_uid=this._idGenerator.getId("mat-select-");_triggerAriaLabelledBy=null;_previousControl;_destroy=new I;_errorStateTracker;stateChanges=new I;disableAutomaticLabeling=!0;userAriaDescribedBy;_selectionModel;_keyManager;_preferredOverlayOrigin;_overlayWidth;_onChange=()=>{};_onTouched=()=>{};_valueId=this._idGenerator.getId("mat-select-value-");_scrollStrategy;_overlayPanelClass=this._defaultOptions?.overlayPanelClass||"";get focused(){return this._focused||this._panelOpen}_focused=!1;controlType="mat-select";trigger;panel;_overlayDir;panelClass;disabled=!1;get disableRipple(){return this._disableRipple()}set disableRipple(e){this._disableRipple.set(e)}_disableRipple=R(!1);tabIndex=0;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(e){this._hideSingleSelectionIndicator=e,this._syncParentProperties()}_hideSingleSelectionIndicator=this._defaultOptions?.hideSingleSelectionIndicator??!1;get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e,this.stateChanges.next()}_placeholder;get required(){return this._required??this.ngControl?.control?.hasValidator(st.required)??!1}set required(e){this._required=e,this.stateChanges.next()}_required;get multiple(){return this._multiple}set multiple(e){this._selectionModel,this._multiple=e}_multiple=!1;disableOptionCentering=this._defaultOptions?.disableOptionCentering??!1;get compareWith(){return this._compareWith}set compareWith(e){this._compareWith=e,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(e){this._assignValue(e)&&this._onChange(e)}_value;ariaLabel="";ariaLabelledby;get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(e){this._errorStateTracker.matcher=e}typeaheadDebounceInterval;sortComparator;get id(){return this._id}set id(e){this._id=e||this._uid,this.stateChanges.next()}_id;get errorState(){return this._errorStateTracker.errorState}set errorState(e){this._errorStateTracker.errorState=e}panelWidth=this._defaultOptions&&typeof this._defaultOptions.panelWidth<"u"?this._defaultOptions.panelWidth:"auto";canSelectNullableOptions=this._defaultOptions?.canSelectNullableOptions??!1;optionSelectionChanges=Yi(()=>{let e=this.options;return e?e.changes.pipe(ke(e),We(()=>$e(...e.map(t=>t.onSelectionChange)))):this._initialized.pipe(We(()=>this.optionSelectionChanges))});openedChange=new K;_openedStream=this.openedChange.pipe(Ce(e=>e),Pe(()=>{}));_closedStream=this.openedChange.pipe(Ce(e=>!e),Pe(()=>{}));selectionChange=new K;valueChange=new K;constructor(){let e=d(yo),t=d(_a,{optional:!0}),n=d(Ut,{optional:!0}),a=d(new Di("tabindex"),{optional:!0}),r=d(Ra,{optional:!0});this.ngControl&&(this.ngControl.valueAccessor=this),this._defaultOptions?.typeaheadDebounceInterval!=null&&(this.typeaheadDebounceInterval=this._defaultOptions.typeaheadDebounceInterval),this._errorStateTracker=new Co(e,this.ngControl,n,t,this.stateChanges),this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=a==null?0:parseInt(a)||0,this._popoverLocation=r?.usePopover===!1?null:"inline",this.id=this.id}ngOnInit(){this._selectionModel=new Sa(this.multiple),this.stateChanges.next(),this._viewportRuler.change().pipe(oe(this._destroy)).subscribe(()=>{this.panelOpen&&(this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._changeDetectorRef.detectChanges())})}ngAfterContentInit(){this._initialized.next(),this._initialized.complete(),this._initKeyManager(),this._selectionModel.changed.pipe(oe(this._destroy)).subscribe(e=>{e.added.forEach(t=>t.select()),e.removed.forEach(t=>t.deselect())}),this.options.changes.pipe(ke(null),oe(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection()})}ngDoCheck(){let e=this._getTriggerAriaLabelledby(),t=this.ngControl;if(e!==this._triggerAriaLabelledBy){let n=this._elementRef.nativeElement;this._triggerAriaLabelledBy=e,e?n.setAttribute("aria-labelledby",e):n.removeAttribute("aria-labelledby")}t&&(this._previousControl!==t.control&&(this._previousControl!==void 0&&t.disabled!==null&&t.disabled!==this.disabled&&(this.disabled=t.disabled),this._previousControl=t.control),this.updateErrorState())}ngOnChanges(e){(e.disabled||e.userAriaDescribedBy)&&this.stateChanges.next(),e.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this.typeaheadDebounceInterval),e.panelClass&&this.panelClass instanceof Set&&(this.panelClass=Array.from(this.panelClass))}ngOnDestroy(){this._cleanupDetach?.(),this._keyManager?.destroy(),this._destroy.next(),this._destroy.complete(),this.stateChanges.complete()}toggle(){this.panelOpen?this.close():this.open()}open(){this._canOpen()&&(this._parentFormField&&(this._preferredOverlayOrigin=this._parentFormField.getConnectedOverlayOrigin()),this._cleanupDetach?.(),this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._panelOpen=!0,this._overlayDir.positionChange.pipe(ct(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled()}),this._overlayDir.attachOverlay(),this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck(),this.stateChanges.next(),Promise.resolve().then(()=>this.openedChange.emit(!0)))}close(){this._panelOpen&&(this._panelOpen=!1,this._exitAndDetach(),this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched(),this.stateChanges.next(),Promise.resolve().then(()=>this.openedChange.emit(!1)))}_exitAndDetach(){if(this._animationsDisabled||!this.panel){this._detachOverlay();return}this._cleanupDetach?.(),this._cleanupDetach=()=>{t(),clearTimeout(n),this._cleanupDetach=void 0};let e=this.panel.nativeElement,t=this._renderer.listen(e,"animationend",a=>{a.animationName==="_mat-select-exit"&&(this._cleanupDetach?.(),this._detachOverlay())}),n=setTimeout(()=>{this._cleanupDetach?.(),this._detachOverlay()},200);e.classList.add("mat-select-panel-exit")}_detachOverlay(){this._overlayDir.detachOverlay(),this._changeDetectorRef.markForCheck()}writeValue(e){this._assignValue(e)}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this.disabled=e,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}get panelOpen(){return this._panelOpen}get selected(){return this.multiple?this._selectionModel?.selected||[]:this._selectionModel?.selected[0]}get triggerValue(){if(this.empty)return"";if(this._multiple){let e=this._selectionModel.selected.map(t=>t.viewValue);return this._isRtl()&&e.reverse(),e.join(", ")}return this._selectionModel.selected[0].viewValue}updateErrorState(){this._errorStateTracker.updateErrorState()}_isRtl(){return this._dir?this._dir.value==="rtl":!1}_handleKeydown(e){this.disabled||(this.panelOpen?this._handleOpenKeydown(e):this._handleClosedKeydown(e))}_handleClosedKeydown(e){let t=e.keyCode,n=t===40||t===38||t===37||t===39,a=t===13||t===32,r=this._keyManager;if(!r.isTyping()&&a&&!Ge(e)||(this.multiple||e.altKey)&&n)e.preventDefault(),this.open();else if(!this.multiple){let u=this.selected;r.onKeydown(e);let h=this.selected;h&&u!==h&&this._liveAnnouncer.announce(h.viewValue,1e4)}}_handleOpenKeydown(e){let t=this._keyManager,n=e.keyCode,a=n===40||n===38,r=t.isTyping();if(a&&e.altKey)e.preventDefault(),this.close();else if(!r&&(n===13||n===32)&&t.activeItem&&!Ge(e))e.preventDefault(),t.activeItem._selectViaInteraction();else if(!r&&this._multiple&&n===65&&e.ctrlKey){e.preventDefault();let u=this.options.some(h=>!h.disabled&&!h.selected);this.options.forEach(h=>{h.disabled||(u?h.select():h.deselect())})}else{let u=t.activeItemIndex;t.onKeydown(e),this._multiple&&a&&e.shiftKey&&t.activeItem&&t.activeItemIndex!==u&&t.activeItem._selectViaInteraction()}}_handleOverlayKeydown(e){e.keyCode===27&&!Ge(e)&&(e.preventDefault(),this.close())}_onFocus(){this.disabled||(this._focused=!0,this.stateChanges.next())}_onBlur(){this._focused=!1,this._keyManager?.cancelTypeahead(),!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}get empty(){return!this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next()})}_setSelectionByValue(e){if(this.options.forEach(t=>t.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&e)Array.isArray(e),e.forEach(t=>this._selectOptionByValue(t)),this._sortValues();else{let t=this._selectOptionByValue(e);t?this._keyManager.updateActiveItem(t):this.panelOpen||this._keyManager.updateActiveItem(-1)}this._changeDetectorRef.markForCheck()}_selectOptionByValue(e){let t=this.options.find(n=>{if(this._selectionModel.isSelected(n))return!1;try{return(n.value!=null||this.canSelectNullableOptions)&&this._compareWith(n.value,e)}catch(a){return!1}});return t&&this._selectionModel.select(t),t}_assignValue(e){return e!==this._value||this._multiple&&Array.isArray(e)?(this.options&&this._setSelectionByValue(e),this._value=e,!0):!1}_skipPredicate=e=>this.panelOpen?!1:e.disabled;_getOverlayWidth(e){return this.panelWidth==="auto"?(e instanceof So?e.elementRef:e||this._elementRef).nativeElement.getBoundingClientRect().width:this.panelWidth===null?"":this.panelWidth}_syncParentProperties(){if(this.options)for(let e of this.options)e._changeDetectorRef.markForCheck()}_initKeyManager(){this._keyManager=new Ln(this.options).withTypeAhead(this.typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withPageUpDown().withAllowedModifierKeys(["shiftKey"]).skipPredicate(this._skipPredicate),this._keyManager.tabOut.subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close())}),this._keyManager.change.subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction()})}_resetOptions(){let e=$e(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(oe(e)).subscribe(t=>{this._onSelect(t.source,t.isUserInput),t.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus())}),$e(...this.options.map(t=>t._stateChanges)).pipe(oe(e)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this.stateChanges.next()})}_onSelect(e,t){let n=this._selectionModel.isSelected(e);!this.canSelectNullableOptions&&e.value==null&&!this._multiple?(e.deselect(),this._selectionModel.clear(),this.value!=null&&this._propagateChanges(e.value)):(n!==e.selected&&(e.selected?this._selectionModel.select(e):this._selectionModel.deselect(e)),t&&this._keyManager.setActiveItem(e),this.multiple&&(this._sortValues(),t&&this.focus())),n!==this._selectionModel.isSelected(e)&&this._propagateChanges(),this.stateChanges.next()}_sortValues(){if(this.multiple){let e=this.options.toArray();this._selectionModel.sort((t,n)=>this.sortComparator?this.sortComparator(t,n,e):e.indexOf(t)-e.indexOf(n)),this.stateChanges.next()}}_propagateChanges(e){let t;this.multiple?t=this.selected.map(n=>n.value):t=this.selected?this.selected.value:e,this._value=t,this.valueChange.emit(t),this._onChange(t),this.selectionChange.emit(this._getChangeEvent(t)),this._changeDetectorRef.markForCheck()}_highlightCorrectOption(){if(this._keyManager)if(this.empty){let e=-1;for(let t=0;t<this.options.length;t++)if(!this.options.get(t).disabled){e=t;break}this._keyManager.setActiveItem(e)}else this._keyManager.setActiveItem(this._selectionModel.selected[0])}_canOpen(){return!this._panelOpen&&!this.disabled&&this.options?.length>0&&!!this._overlayDir}focus(e){this._elementRef.nativeElement.focus(e)}_getPanelAriaLabelledby(){if(this.ariaLabel)return null;let e=this._parentFormField?.getLabelId()||null,t=e?e+" ":"";return this.ariaLabelledby?t+this.ariaLabelledby:e}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){if(this.ariaLabel)return null;let e=this._parentFormField?.getLabelId()||"";return this.ariaLabelledby&&(e+=" "+this.ariaLabelledby),e||(e=this._valueId),e}get describedByIds(){return this._elementRef.nativeElement.getAttribute("aria-describedby")?.split(" ")||[]}setDescribedByIds(e){let t=this._elementRef.nativeElement;e.length?t.setAttribute("aria-describedby",e.join(" ")):t.removeAttribute("aria-describedby")}onContainerClick(e){let t=rt(e);t&&(t.tagName==="MAT-OPTION"||t.classList.contains("cdk-overlay-backdrop")||t.closest(".mat-mdc-select-panel"))||(this.focus(),this.open())}get shouldLabelFloat(){return this.panelOpen||!this.empty||this.focused&&!!this.placeholder}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-select"]],contentQueries:function(t,n,a){if(t&1&&at(a,G0,5)(a,vt,5)(a,La,5),t&2){let r;O(r=P())&&(n.customTrigger=r.first),O(r=P())&&(n.options=r),O(r=P())&&(n.optionGroups=r)}},viewQuery:function(t,n){if(t&1&&Me(O0,5)(P0,5)(ps,5),t&2){let a;O(a=P())&&(n.trigger=a.first),O(a=P())&&(n.panel=a.first),O(a=P())&&(n._overlayDir=a.first)}},hostAttrs:["role","combobox","aria-haspopup","listbox",1,"mat-mdc-select"],hostVars:21,hostBindings:function(t,n){t&1&&A("keydown",function(r){return n._handleKeydown(r)})("focus",function(){return n._onFocus()})("blur",function(){return n._onBlur()}),t&2&&(Z("id",n.id)("tabindex",n.disabled?-1:n.tabIndex)("aria-controls",n.panelOpen?n.id+"-panel":null)("aria-expanded",n.panelOpen)("aria-label",n.ariaLabel||null)("aria-required",n.required.toString())("aria-disabled",n.disabled.toString())("aria-invalid",n.errorState)("aria-activedescendant",n._getAriaActiveDescendant()),p("mat-mdc-select-disabled",n.disabled)("mat-mdc-select-invalid",n.errorState)("mat-mdc-select-required",n.required)("mat-mdc-select-empty",n.empty)("mat-mdc-select-multiple",n.multiple)("mat-select-open",n.panelOpen))},inputs:{userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",disabled:[2,"disabled","disabled",L],disableRipple:[2,"disableRipple","disableRipple",L],tabIndex:[2,"tabIndex","tabIndex",e=>e==null?0:wt(e)],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",L],placeholder:"placeholder",required:[2,"required","required",L],multiple:[2,"multiple","multiple",L],disableOptionCentering:[2,"disableOptionCentering","disableOptionCentering",L],compareWith:"compareWith",value:"value",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:[2,"typeaheadDebounceInterval","typeaheadDebounceInterval",wt],sortComparator:"sortComparator",id:"id",panelWidth:"panelWidth",canSelectNullableOptions:[2,"canSelectNullableOptions","canSelectNullableOptions",L]},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},exportAs:["matSelect"],features:[J([{provide:ya,useExisting:i},{provide:Na,useExisting:i}]),Se],ngContentSelectors:N0,decls:11,vars:10,consts:[["fallbackOverlayOrigin","cdkOverlayOrigin","trigger",""],["panel",""],["cdk-overlay-origin","",1,"mat-mdc-select-trigger",3,"click"],[1,"mat-mdc-select-value"],[1,"mat-mdc-select-placeholder","mat-mdc-select-min-line"],[1,"mat-mdc-select-value-text"],[1,"mat-mdc-select-arrow-wrapper"],[1,"mat-mdc-select-arrow"],["viewBox","0 0 24 24","width","24px","height","24px","focusable","false","aria-hidden","true"],["d","M7 10l5 5 5-5z"],["cdk-connected-overlay","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"detach","backdropClick","overlayKeydown","cdkConnectedOverlayDisableClose","cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayPositions","cdkConnectedOverlayWidth","cdkConnectedOverlayFlexibleDimensions","cdkConnectedOverlayUsePopover"],[1,"mat-mdc-select-min-line"],["role","listbox","tabindex","-1",1,"mat-mdc-select-panel","mdc-menu-surface","mdc-menu-surface--open",3,"keydown"]],template:function(t,n){if(t&1&&(ce(F0),s(0,"div",2,0),A("click",function(){return n.open()}),s(3,"div",3),M(4,L0,2,1,"span",4)(5,z0,3,1,"span",5),l(),s(6,"div",6)(7,"div",7),wi(),s(8,"svg",8),v(9,"path",9),l()()()(),ze(10,j0,3,16,"ng-template",10),A("detach",function(){return n.close()})("backdropClick",function(){return n.close()})("overlayKeydown",function(r){return n._handleOverlayKeydown(r)})),t&2){let a=Ne(1);c(3),Z("id",n._valueId),c(),E(n.empty?4:5),c(6),x("cdkConnectedOverlayDisableClose",!0)("cdkConnectedOverlayPanelClass",n._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",n._scrollStrategy)("cdkConnectedOverlayOrigin",n._preferredOverlayOrigin||a)("cdkConnectedOverlayPositions",n._positions)("cdkConnectedOverlayWidth",n._overlayWidth)("cdkConnectedOverlayFlexibleDimensions",!0)("cdkConnectedOverlayUsePopover",n._popoverLocation)}},dependencies:[So,ps],styles:[`@keyframes _mat-select-enter {
5289
+ `],encapsulation:2})}return i})(),Is=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-panel-description"]],hostAttrs:[1,"mat-expansion-panel-header-description"]})}return i})(),Rs=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["mat-panel-title"]],hostAttrs:[1,"mat-expansion-panel-header-title"]})}return i})();var Os=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[gp,Oi,ee]})}return i})();var O0=["trigger"],P0=["panel"],F0=[[["mat-select-trigger"]],"*"],N0=["mat-select-trigger","*"];function L0(i,o){if(i&1&&(s(0,"span",4),m(1),l()),i&2){let e=D();c(),q(e.placeholder)}}function V0(i,o){i&1&&U(0)}function B0(i,o){if(i&1&&(s(0,"span",11),m(1),l()),i&2){let e=D(2);c(),q(e.triggerValue)}}function z0(i,o){if(i&1&&(s(0,"span",5),M(1,V0,1,0)(2,B0,2,1,"span",11),l()),i&2){let e=D();c(),E(e.customTrigger?1:2)}}function j0(i,o){if(i&1){let e=Ue();s(0,"div",12,1),A("keydown",function(n){xe(e);let a=D();return we(a._handleKeydown(n))}),U(2,1),l()}if(i&2){let e=D();et(e.panelClass),p("mat-select-panel-animations-enabled",!e._animationsDisabled)("mat-primary",e._parentFormField?.color==="primary")("mat-accent",e._parentFormField?.color==="accent")("mat-warn",e._parentFormField?.color==="warn")("mat-undefined",!e._parentFormField?.color),Z("id",e.id+"-panel")("aria-multiselectable",e.multiple)("aria-label",e.ariaLabel||null)("aria-labelledby",e._getPanelAriaLabelledby())}}var H0=new x("mat-select-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>yi(i)}}),U0=new x("MAT_SELECT_CONFIG"),G0=new x("MatSelectTrigger"),zc=class{source;value;constructor(o,e){this.source=o,this.value=e}},No=(()=>{class i{_viewportRuler=d(Gt);_changeDetectorRef=d(te);_elementRef=d(N);_dir=d(qe,{optional:!0});_idGenerator=d(be);_renderer=d(ve);_parentFormField=d(jn,{optional:!0});ngControl=d(Jt,{self:!0,optional:!0});_liveAnnouncer=d(la);_defaultOptions=d(U0,{optional:!0});_animationsDisabled=pe();_popoverLocation;_initialized=new I;_cleanupDetach;options;optionGroups;customTrigger;_positions=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"}];_scrollOptionIntoView(e){let t=this.options.toArray()[e];if(t){let n=this.panel.nativeElement,a=Ss(e,this.options,this.optionGroups),r=t._getHostElement();e===0&&a===1?n.scrollTop=0:n.scrollTop=Ms(r.offsetTop,r.offsetHeight,n.scrollTop,n.offsetHeight)}}_positioningSettled(){this._scrollOptionIntoView(this._keyManager.activeItemIndex||0)}_getChangeEvent(e){return new zc(this,e)}_scrollStrategyFactory=d(H0);_panelOpen=!1;_compareWith=(e,t)=>e===t;_uid=this._idGenerator.getId("mat-select-");_triggerAriaLabelledBy=null;_previousControl;_destroy=new I;_errorStateTracker;stateChanges=new I;disableAutomaticLabeling=!0;userAriaDescribedBy;_selectionModel;_keyManager;_preferredOverlayOrigin;_overlayWidth;_onChange=()=>{};_onTouched=()=>{};_valueId=this._idGenerator.getId("mat-select-value-");_scrollStrategy;_overlayPanelClass=this._defaultOptions?.overlayPanelClass||"";get focused(){return this._focused||this._panelOpen}_focused=!1;controlType="mat-select";trigger;panel;_overlayDir;panelClass;disabled=!1;get disableRipple(){return this._disableRipple()}set disableRipple(e){this._disableRipple.set(e)}_disableRipple=R(!1);tabIndex=0;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(e){this._hideSingleSelectionIndicator=e,this._syncParentProperties()}_hideSingleSelectionIndicator=this._defaultOptions?.hideSingleSelectionIndicator??!1;get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e,this.stateChanges.next()}_placeholder;get required(){return this._required??this.ngControl?.control?.hasValidator(st.required)??!1}set required(e){this._required=e,this.stateChanges.next()}_required;get multiple(){return this._multiple}set multiple(e){this._selectionModel,this._multiple=e}_multiple=!1;disableOptionCentering=this._defaultOptions?.disableOptionCentering??!1;get compareWith(){return this._compareWith}set compareWith(e){this._compareWith=e,this._selectionModel&&this._initializeSelection()}get value(){return this._value}set value(e){this._assignValue(e)&&this._onChange(e)}_value;ariaLabel="";ariaLabelledby;get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(e){this._errorStateTracker.matcher=e}typeaheadDebounceInterval;sortComparator;get id(){return this._id}set id(e){this._id=e||this._uid,this.stateChanges.next()}_id;get errorState(){return this._errorStateTracker.errorState}set errorState(e){this._errorStateTracker.errorState=e}panelWidth=this._defaultOptions&&typeof this._defaultOptions.panelWidth<"u"?this._defaultOptions.panelWidth:"auto";canSelectNullableOptions=this._defaultOptions?.canSelectNullableOptions??!1;optionSelectionChanges=Yi(()=>{let e=this.options;return e?e.changes.pipe(ke(e),We(()=>$e(...e.map(t=>t.onSelectionChange)))):this._initialized.pipe(We(()=>this.optionSelectionChanges))});openedChange=new K;_openedStream=this.openedChange.pipe(Ce(e=>e),Pe(()=>{}));_closedStream=this.openedChange.pipe(Ce(e=>!e),Pe(()=>{}));selectionChange=new K;valueChange=new K;constructor(){let e=d(xo),t=d(ba,{optional:!0}),n=d(Ut,{optional:!0}),a=d(new Di("tabindex"),{optional:!0}),r=d(Pa,{optional:!0});this.ngControl&&(this.ngControl.valueAccessor=this),this._defaultOptions?.typeaheadDebounceInterval!=null&&(this.typeaheadDebounceInterval=this._defaultOptions.typeaheadDebounceInterval),this._errorStateTracker=new wo(e,this.ngControl,n,t,this.stateChanges),this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=a==null?0:parseInt(a)||0,this._popoverLocation=r?.usePopover===!1?null:"inline",this.id=this.id}ngOnInit(){this._selectionModel=new Ea(this.multiple),this.stateChanges.next(),this._viewportRuler.change().pipe(oe(this._destroy)).subscribe(()=>{this.panelOpen&&(this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._changeDetectorRef.detectChanges())})}ngAfterContentInit(){this._initialized.next(),this._initialized.complete(),this._initKeyManager(),this._selectionModel.changed.pipe(oe(this._destroy)).subscribe(e=>{e.added.forEach(t=>t.select()),e.removed.forEach(t=>t.deselect())}),this.options.changes.pipe(ke(null),oe(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection()})}ngDoCheck(){let e=this._getTriggerAriaLabelledby(),t=this.ngControl;if(e!==this._triggerAriaLabelledBy){let n=this._elementRef.nativeElement;this._triggerAriaLabelledBy=e,e?n.setAttribute("aria-labelledby",e):n.removeAttribute("aria-labelledby")}t&&(this._previousControl!==t.control&&(this._previousControl!==void 0&&t.disabled!==null&&t.disabled!==this.disabled&&(this.disabled=t.disabled),this._previousControl=t.control),this.updateErrorState())}ngOnChanges(e){(e.disabled||e.userAriaDescribedBy)&&this.stateChanges.next(),e.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this.typeaheadDebounceInterval),e.panelClass&&this.panelClass instanceof Set&&(this.panelClass=Array.from(this.panelClass))}ngOnDestroy(){this._cleanupDetach?.(),this._keyManager?.destroy(),this._destroy.next(),this._destroy.complete(),this.stateChanges.complete()}toggle(){this.panelOpen?this.close():this.open()}open(){this._canOpen()&&(this._parentFormField&&(this._preferredOverlayOrigin=this._parentFormField.getConnectedOverlayOrigin()),this._cleanupDetach?.(),this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._panelOpen=!0,this._overlayDir.positionChange.pipe(ct(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled()}),this._overlayDir.attachOverlay(),this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck(),this.stateChanges.next(),Promise.resolve().then(()=>this.openedChange.emit(!0)))}close(){this._panelOpen&&(this._panelOpen=!1,this._exitAndDetach(),this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched(),this.stateChanges.next(),Promise.resolve().then(()=>this.openedChange.emit(!1)))}_exitAndDetach(){if(this._animationsDisabled||!this.panel){this._detachOverlay();return}this._cleanupDetach?.(),this._cleanupDetach=()=>{t(),clearTimeout(n),this._cleanupDetach=void 0};let e=this.panel.nativeElement,t=this._renderer.listen(e,"animationend",a=>{a.animationName==="_mat-select-exit"&&(this._cleanupDetach?.(),this._detachOverlay())}),n=setTimeout(()=>{this._cleanupDetach?.(),this._detachOverlay()},200);e.classList.add("mat-select-panel-exit")}_detachOverlay(){this._overlayDir.detachOverlay(),this._changeDetectorRef.markForCheck()}writeValue(e){this._assignValue(e)}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this.disabled=e,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}get panelOpen(){return this._panelOpen}get selected(){return this.multiple?this._selectionModel?.selected||[]:this._selectionModel?.selected[0]}get triggerValue(){if(this.empty)return"";if(this._multiple){let e=this._selectionModel.selected.map(t=>t.viewValue);return this._isRtl()&&e.reverse(),e.join(", ")}return this._selectionModel.selected[0].viewValue}updateErrorState(){this._errorStateTracker.updateErrorState()}_isRtl(){return this._dir?this._dir.value==="rtl":!1}_handleKeydown(e){this.disabled||(this.panelOpen?this._handleOpenKeydown(e):this._handleClosedKeydown(e))}_handleClosedKeydown(e){let t=e.keyCode,n=t===40||t===38||t===37||t===39,a=t===13||t===32,r=this._keyManager;if(!r.isTyping()&&a&&!Ge(e)||(this.multiple||e.altKey)&&n)e.preventDefault(),this.open();else if(!this.multiple){let u=this.selected;r.onKeydown(e);let h=this.selected;h&&u!==h&&this._liveAnnouncer.announce(h.viewValue,1e4)}}_handleOpenKeydown(e){let t=this._keyManager,n=e.keyCode,a=n===40||n===38,r=t.isTyping();if(a&&e.altKey)e.preventDefault(),this.close();else if(!r&&(n===13||n===32)&&t.activeItem&&!Ge(e))e.preventDefault(),t.activeItem._selectViaInteraction();else if(!r&&this._multiple&&n===65&&e.ctrlKey){e.preventDefault();let u=this.options.some(h=>!h.disabled&&!h.selected);this.options.forEach(h=>{h.disabled||(u?h.select():h.deselect())})}else{let u=t.activeItemIndex;t.onKeydown(e),this._multiple&&a&&e.shiftKey&&t.activeItem&&t.activeItemIndex!==u&&t.activeItem._selectViaInteraction()}}_handleOverlayKeydown(e){e.keyCode===27&&!Ge(e)&&(e.preventDefault(),this.close())}_onFocus(){this.disabled||(this._focused=!0,this.stateChanges.next())}_onBlur(){this._focused=!1,this._keyManager?.cancelTypeahead(),!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}get empty(){return!this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next()})}_setSelectionByValue(e){if(this.options.forEach(t=>t.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&e)Array.isArray(e),e.forEach(t=>this._selectOptionByValue(t)),this._sortValues();else{let t=this._selectOptionByValue(e);t?this._keyManager.updateActiveItem(t):this.panelOpen||this._keyManager.updateActiveItem(-1)}this._changeDetectorRef.markForCheck()}_selectOptionByValue(e){let t=this.options.find(n=>{if(this._selectionModel.isSelected(n))return!1;try{return(n.value!=null||this.canSelectNullableOptions)&&this._compareWith(n.value,e)}catch(a){return!1}});return t&&this._selectionModel.select(t),t}_assignValue(e){return e!==this._value||this._multiple&&Array.isArray(e)?(this.options&&this._setSelectionByValue(e),this._value=e,!0):!1}_skipPredicate=e=>this.panelOpen?!1:e.disabled;_getOverlayWidth(e){return this.panelWidth==="auto"?(e instanceof Eo?e.elementRef:e||this._elementRef).nativeElement.getBoundingClientRect().width:this.panelWidth===null?"":this.panelWidth}_syncParentProperties(){if(this.options)for(let e of this.options)e._changeDetectorRef.markForCheck()}_initKeyManager(){this._keyManager=new Bn(this.options).withTypeAhead(this.typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withPageUpDown().withAllowedModifierKeys(["shiftKey"]).skipPredicate(this._skipPredicate),this._keyManager.tabOut.subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close())}),this._keyManager.change.subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction()})}_resetOptions(){let e=$e(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(oe(e)).subscribe(t=>{this._onSelect(t.source,t.isUserInput),t.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus())}),$e(...this.options.map(t=>t._stateChanges)).pipe(oe(e)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this.stateChanges.next()})}_onSelect(e,t){let n=this._selectionModel.isSelected(e);!this.canSelectNullableOptions&&e.value==null&&!this._multiple?(e.deselect(),this._selectionModel.clear(),this.value!=null&&this._propagateChanges(e.value)):(n!==e.selected&&(e.selected?this._selectionModel.select(e):this._selectionModel.deselect(e)),t&&this._keyManager.setActiveItem(e),this.multiple&&(this._sortValues(),t&&this.focus())),n!==this._selectionModel.isSelected(e)&&this._propagateChanges(),this.stateChanges.next()}_sortValues(){if(this.multiple){let e=this.options.toArray();this._selectionModel.sort((t,n)=>this.sortComparator?this.sortComparator(t,n,e):e.indexOf(t)-e.indexOf(n)),this.stateChanges.next()}}_propagateChanges(e){let t;this.multiple?t=this.selected.map(n=>n.value):t=this.selected?this.selected.value:e,this._value=t,this.valueChange.emit(t),this._onChange(t),this.selectionChange.emit(this._getChangeEvent(t)),this._changeDetectorRef.markForCheck()}_highlightCorrectOption(){if(this._keyManager)if(this.empty){let e=-1;for(let t=0;t<this.options.length;t++)if(!this.options.get(t).disabled){e=t;break}this._keyManager.setActiveItem(e)}else this._keyManager.setActiveItem(this._selectionModel.selected[0])}_canOpen(){return!this._panelOpen&&!this.disabled&&this.options?.length>0&&!!this._overlayDir}focus(e){this._elementRef.nativeElement.focus(e)}_getPanelAriaLabelledby(){if(this.ariaLabel)return null;let e=this._parentFormField?.getLabelId()||null,t=e?e+" ":"";return this.ariaLabelledby?t+this.ariaLabelledby:e}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){if(this.ariaLabel)return null;let e=this._parentFormField?.getLabelId()||"";return this.ariaLabelledby&&(e+=" "+this.ariaLabelledby),e||(e=this._valueId),e}get describedByIds(){return this._elementRef.nativeElement.getAttribute("aria-describedby")?.split(" ")||[]}setDescribedByIds(e){let t=this._elementRef.nativeElement;e.length?t.setAttribute("aria-describedby",e.join(" ")):t.removeAttribute("aria-describedby")}onContainerClick(e){let t=rt(e);t&&(t.tagName==="MAT-OPTION"||t.classList.contains("cdk-overlay-backdrop")||t.closest(".mat-mdc-select-panel"))||(this.focus(),this.open())}get shouldLabelFloat(){return this.panelOpen||!this.empty||this.focused&&!!this.placeholder}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-select"]],contentQueries:function(t,n,a){if(t&1&&at(a,G0,5)(a,vt,5)(a,Ba,5),t&2){let r;O(r=P())&&(n.customTrigger=r.first),O(r=P())&&(n.options=r),O(r=P())&&(n.optionGroups=r)}},viewQuery:function(t,n){if(t&1&&Me(O0,5)(P0,5)(_s,5),t&2){let a;O(a=P())&&(n.trigger=a.first),O(a=P())&&(n.panel=a.first),O(a=P())&&(n._overlayDir=a.first)}},hostAttrs:["role","combobox","aria-haspopup","listbox",1,"mat-mdc-select"],hostVars:21,hostBindings:function(t,n){t&1&&A("keydown",function(r){return n._handleKeydown(r)})("focus",function(){return n._onFocus()})("blur",function(){return n._onBlur()}),t&2&&(Z("id",n.id)("tabindex",n.disabled?-1:n.tabIndex)("aria-controls",n.panelOpen?n.id+"-panel":null)("aria-expanded",n.panelOpen)("aria-label",n.ariaLabel||null)("aria-required",n.required.toString())("aria-disabled",n.disabled.toString())("aria-invalid",n.errorState)("aria-activedescendant",n._getAriaActiveDescendant()),p("mat-mdc-select-disabled",n.disabled)("mat-mdc-select-invalid",n.errorState)("mat-mdc-select-required",n.required)("mat-mdc-select-empty",n.empty)("mat-mdc-select-multiple",n.multiple)("mat-select-open",n.panelOpen))},inputs:{userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",disabled:[2,"disabled","disabled",L],disableRipple:[2,"disableRipple","disableRipple",L],tabIndex:[2,"tabIndex","tabIndex",e=>e==null?0:wt(e)],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",L],placeholder:"placeholder",required:[2,"required","required",L],multiple:[2,"multiple","multiple",L],disableOptionCentering:[2,"disableOptionCentering","disableOptionCentering",L],compareWith:"compareWith",value:"value",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:[2,"typeaheadDebounceInterval","typeaheadDebounceInterval",wt],sortComparator:"sortComparator",id:"id",panelWidth:"panelWidth",canSelectNullableOptions:[2,"canSelectNullableOptions","canSelectNullableOptions",L]},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},exportAs:["matSelect"],features:[J([{provide:xa,useExisting:i},{provide:Va,useExisting:i}]),Se],ngContentSelectors:N0,decls:11,vars:10,consts:[["fallbackOverlayOrigin","cdkOverlayOrigin","trigger",""],["panel",""],["cdk-overlay-origin","",1,"mat-mdc-select-trigger",3,"click"],[1,"mat-mdc-select-value"],[1,"mat-mdc-select-placeholder","mat-mdc-select-min-line"],[1,"mat-mdc-select-value-text"],[1,"mat-mdc-select-arrow-wrapper"],[1,"mat-mdc-select-arrow"],["viewBox","0 0 24 24","width","24px","height","24px","focusable","false","aria-hidden","true"],["d","M7 10l5 5 5-5z"],["cdk-connected-overlay","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"detach","backdropClick","overlayKeydown","cdkConnectedOverlayDisableClose","cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayPositions","cdkConnectedOverlayWidth","cdkConnectedOverlayFlexibleDimensions","cdkConnectedOverlayUsePopover"],[1,"mat-mdc-select-min-line"],["role","listbox","tabindex","-1",1,"mat-mdc-select-panel","mdc-menu-surface","mdc-menu-surface--open",3,"keydown"]],template:function(t,n){if(t&1&&(ce(F0),s(0,"div",2,0),A("click",function(){return n.open()}),s(3,"div",3),M(4,L0,2,1,"span",4)(5,z0,3,1,"span",5),l(),s(6,"div",6)(7,"div",7),wi(),s(8,"svg",8),v(9,"path",9),l()()()(),ze(10,j0,3,16,"ng-template",10),A("detach",function(){return n.close()})("backdropClick",function(){return n.close()})("overlayKeydown",function(r){return n._handleOverlayKeydown(r)})),t&2){let a=Fe(1);c(3),Z("id",n._valueId),c(),E(n.empty?4:5),c(6),C("cdkConnectedOverlayDisableClose",!0)("cdkConnectedOverlayPanelClass",n._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",n._scrollStrategy)("cdkConnectedOverlayOrigin",n._preferredOverlayOrigin||a)("cdkConnectedOverlayPositions",n._positions)("cdkConnectedOverlayWidth",n._overlayWidth)("cdkConnectedOverlayFlexibleDimensions",!0)("cdkConnectedOverlayUsePopover",n._popoverLocation)}},dependencies:[Eo,_s],styles:[`@keyframes _mat-select-enter {
5290
5290
  from {
5291
5291
  opacity: 0;
5292
5292
  transform: scaleY(0.8);
@@ -5475,7 +5475,7 @@ div.mat-mdc-select-panel {
5475
5475
  .mat-form-field-appearance-fill .mat-mdc-select-arrow-wrapper {
5476
5476
  transform: var(--mat-select-arrow-transform, translateY(-8px));
5477
5477
  }
5478
- `],encapsulation:2})}return i})();var Fo=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Nt,Ro,ee,_i,St,Ro]})}return i})();var $0=["tooltip"],W0=20;var q0=new C("mat-tooltip-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>yi(i,{scrollThrottle:W0})}}),K0=new C("mat-tooltip-default-options",{providedIn:"root",factory:()=>({showDelay:0,hideDelay:0,touchendHideDelay:1500})});var Cp="tooltip-panel",Y0={passive:!0},X0=8,Z0=8,Q0=24,J0=200,za=(()=>{class i{_elementRef=d(N);_ngZone=d(H);_platform=d(le);_ariaDescriber=d(Qm);_focusMonitor=d(Rt);_dir=d(qe);_injector=d(X);_viewContainerRef=d(Xe);_mediaMatcher=d(lo);_document=d($);_renderer=d(ve);_animationsDisabled=pe();_defaultOptions=d(K0,{optional:!0});_overlayRef=null;_tooltipInstance=null;_overlayPanelClass;_portal;_position="below";_positionAtOrigin=!1;_disabled=!1;_tooltipClass;_viewInitialized=!1;_pointerExitEventsInitialized=!1;_tooltipComponent=xp;_viewportMargin=8;_currentPosition;_cssClassPrefix="mat-mdc";_ariaDescriptionPending=!1;_dirSubscribed=!1;get position(){return this._position}set position(e){e!==this._position&&(this._position=e,this._overlayRef&&(this._updatePosition(this._overlayRef),this._tooltipInstance?.show(0),this._overlayRef.updatePosition()))}get positionAtOrigin(){return this._positionAtOrigin}set positionAtOrigin(e){this._positionAtOrigin=mt(e),this._detach(),this._overlayRef=null}get disabled(){return this._disabled}set disabled(e){let t=mt(e);this._disabled!==t&&(this._disabled=t,t?this.hide(0):this._setupPointerEnterEventsIfNeeded(),this._syncAriaDescription(this.message))}get showDelay(){return this._showDelay}set showDelay(e){this._showDelay=Ht(e)}_showDelay;get hideDelay(){return this._hideDelay}set hideDelay(e){this._hideDelay=Ht(e),this._tooltipInstance&&(this._tooltipInstance._mouseLeaveHideDelay=this._hideDelay)}_hideDelay;touchGestures="auto";get message(){return this._message}set message(e){let t=this._message;this._message=e!=null?String(e).trim():"",!this._message&&this._isTooltipVisible()?this.hide(0):(this._setupPointerEnterEventsIfNeeded(),this._updateTooltipMessage()),this._syncAriaDescription(t)}_message="";get tooltipClass(){return this._tooltipClass}set tooltipClass(e){this._tooltipClass=e,this._tooltipInstance&&this._setTooltipClass(this._tooltipClass)}_eventCleanups=[];_touchstartTimeout=null;_destroyed=new I;_isDestroyed=!1;constructor(){let e=this._defaultOptions;e&&(this._showDelay=e.showDelay,this._hideDelay=e.hideDelay,e.position&&(this.position=e.position),e.positionAtOrigin&&(this.positionAtOrigin=e.positionAtOrigin),e.touchGestures&&(this.touchGestures=e.touchGestures),e.tooltipClass&&(this.tooltipClass=e.tooltipClass)),this._viewportMargin=X0}ngAfterViewInit(){this._viewInitialized=!0,this._setupPointerEnterEventsIfNeeded(),this._focusMonitor.monitor(this._elementRef).pipe(oe(this._destroyed)).subscribe(e=>{e?e==="keyboard"&&this._ngZone.run(()=>this.show()):this._ngZone.run(()=>this.hide(0))})}ngOnDestroy(){let e=this._elementRef.nativeElement;this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this._overlayRef&&(this._overlayRef.dispose(),this._tooltipInstance=null),this._eventCleanups.forEach(t=>t()),this._eventCleanups.length=0,this._destroyed.next(),this._destroyed.complete(),this._isDestroyed=!0,this._ariaDescriber.removeDescription(e,this.message,"tooltip"),this._focusMonitor.stopMonitoring(e)}show(e=this.showDelay,t){if(this.disabled||!this.message||this._isTooltipVisible()){this._tooltipInstance?._cancelPendingAnimations();return}let n=this._createOverlay(t);this._detach(),this._portal=this._portal||new bi(this._tooltipComponent,this._viewContainerRef);let a=this._tooltipInstance=n.attach(this._portal).instance;a._triggerElement=this._elementRef.nativeElement,a._mouseLeaveHideDelay=this._hideDelay,a.afterHidden().pipe(oe(this._destroyed)).subscribe(()=>this._detach()),this._setTooltipClass(this._tooltipClass),this._updateTooltipMessage(),a.show(e)}hide(e=this.hideDelay){let t=this._tooltipInstance;t&&(t.isVisible()?t.hide(e):(t._cancelPendingAnimations(),this._detach()))}toggle(e){this._isTooltipVisible()?this.hide():this.show(void 0,e)}_isTooltipVisible(){return!!this._tooltipInstance&&this._tooltipInstance.isVisible()}_createOverlay(e){if(this._overlayRef){let r=this._overlayRef.getConfig().positionStrategy;if((!this.positionAtOrigin||!e)&&r._origin instanceof N)return this._overlayRef;this._detach()}let t=this._injector.get(gn).getAncestorScrollContainers(this._elementRef),n=`${this._cssClassPrefix}-${Cp}`,a=$i(this._injector,this.positionAtOrigin?e||this._elementRef:this._elementRef).withTransformOriginOn(`.${this._cssClassPrefix}-tooltip`).withFlexibleDimensions(!1).withViewportMargin(this._viewportMargin).withScrollableContainers(t).withPopoverLocation("global");return a.positionChanges.pipe(oe(this._destroyed)).subscribe(r=>{this._updateCurrentPositionClass(r.connectionPair),this._tooltipInstance&&r.scrollableViewProperties.isOverlayClipped&&this._tooltipInstance.isVisible()&&this._ngZone.run(()=>this.hide(0))}),this._overlayRef=qt(this._injector,{direction:this._dir,positionStrategy:a,panelClass:this._overlayPanelClass?[...this._overlayPanelClass,n]:n,scrollStrategy:this._injector.get(q0)(),disableAnimations:this._animationsDisabled,eventPredicate:this._overlayEventPredicate}),this._updatePosition(this._overlayRef),this._overlayRef.detachments().pipe(oe(this._destroyed)).subscribe(()=>this._detach()),this._overlayRef.outsidePointerEvents().pipe(oe(this._destroyed)).subscribe(()=>this._tooltipInstance?._handleBodyInteraction()),this._overlayRef.keydownEvents().pipe(oe(this._destroyed)).subscribe(r=>{r.preventDefault(),r.stopPropagation(),this._ngZone.run(()=>this.hide(0))}),this._defaultOptions?.disableTooltipInteractivity&&this._overlayRef.addPanelClass(`${this._cssClassPrefix}-tooltip-panel-non-interactive`),this._dirSubscribed||(this._dirSubscribed=!0,this._dir.change.pipe(oe(this._destroyed)).subscribe(()=>{this._overlayRef&&this._updatePosition(this._overlayRef)})),this._overlayRef}_detach(){this._overlayRef&&this._overlayRef.hasAttached()&&this._overlayRef.detach(),this._tooltipInstance=null}_updatePosition(e){let t=e.getConfig().positionStrategy,n=this._getOrigin(),a=this._getOverlayPosition();t.withPositions([this._addOffset(V(V({},n.main),a.main)),this._addOffset(V(V({},n.fallback),a.fallback))])}_addOffset(e){let t=Z0,n=!this._dir||this._dir.value=="ltr";return e.originY==="top"?e.offsetY=-t:e.originY==="bottom"?e.offsetY=t:e.originX==="start"?e.offsetX=n?-t:t:e.originX==="end"&&(e.offsetX=n?t:-t),e}_getOrigin(){let e=!this._dir||this._dir.value=="ltr",t=this.position,n;t=="above"||t=="below"?n={originX:"center",originY:t=="above"?"top":"bottom"}:t=="before"||t=="left"&&e||t=="right"&&!e?n={originX:"start",originY:"center"}:(t=="after"||t=="right"&&e||t=="left"&&!e)&&(n={originX:"end",originY:"center"});let{x:a,y:r}=this._invertPosition(n.originX,n.originY);return{main:n,fallback:{originX:a,originY:r}}}_getOverlayPosition(){let e=!this._dir||this._dir.value=="ltr",t=this.position,n;t=="above"?n={overlayX:"center",overlayY:"bottom"}:t=="below"?n={overlayX:"center",overlayY:"top"}:t=="before"||t=="left"&&e||t=="right"&&!e?n={overlayX:"end",overlayY:"center"}:(t=="after"||t=="right"&&e||t=="left"&&!e)&&(n={overlayX:"start",overlayY:"center"});let{x:a,y:r}=this._invertPosition(n.overlayX,n.overlayY);return{main:n,fallback:{overlayX:a,overlayY:r}}}_updateTooltipMessage(){this._tooltipInstance&&(this._tooltipInstance.message=this.message,this._tooltipInstance._markForCheck(),Be(()=>{this._tooltipInstance&&this._overlayRef.updatePosition()},{injector:this._injector}))}_setTooltipClass(e){this._tooltipInstance&&(this._tooltipInstance.tooltipClass=e instanceof Set?Array.from(e):e,this._tooltipInstance._markForCheck())}_invertPosition(e,t){return this.position==="above"||this.position==="below"?t==="top"?t="bottom":t==="bottom"&&(t="top"):e==="end"?e="start":e==="start"&&(e="end"),{x:e,y:t}}_updateCurrentPositionClass(e){let{overlayY:t,originX:n,originY:a}=e,r;if(t==="center"?this._dir&&this._dir.value==="rtl"?r=n==="end"?"left":"right":r=n==="start"?"left":"right":r=t==="bottom"&&a==="top"?"above":"below",r!==this._currentPosition){let u=this._overlayRef;if(u){let h=`${this._cssClassPrefix}-${Cp}-`;u.removePanelClass(h+this._currentPosition),u.addPanelClass(h+r)}this._currentPosition=r}}_setupPointerEnterEventsIfNeeded(){this._disabled||!this.message||!this._viewInitialized||this._eventCleanups.length||(this._isTouchPlatform()?this.touchGestures!=="off"&&(this._disableNativeGesturesIfNecessary(),this._addListener("touchstart",e=>{let t=e.targetTouches?.[0],n=t?{x:t.clientX,y:t.clientY}:void 0;this._setupPointerExitEventsIfNeeded(),this._touchstartTimeout&&clearTimeout(this._touchstartTimeout);let a=500;this._touchstartTimeout=setTimeout(()=>{this._touchstartTimeout=null,this.show(void 0,n)},this._defaultOptions?.touchLongPressShowDelay??a)})):this._addListener("mouseenter",e=>{this._setupPointerExitEventsIfNeeded();let t;e.x!==void 0&&e.y!==void 0&&(t=e),this.show(void 0,t)}))}_setupPointerExitEventsIfNeeded(){if(!this._pointerExitEventsInitialized){if(this._pointerExitEventsInitialized=!0,!this._isTouchPlatform())this._addListener("mouseleave",e=>{let t=e.relatedTarget;(!t||!this._overlayRef?.overlayElement.contains(t))&&this.hide()}),this._addListener("wheel",e=>{if(this._isTooltipVisible()){let t=this._document.elementFromPoint(e.clientX,e.clientY),n=this._elementRef.nativeElement;t!==n&&!n.contains(t)&&this.hide()}});else if(this.touchGestures!=="off"){this._disableNativeGesturesIfNecessary();let e=()=>{this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this.hide(this._defaultOptions?.touchendHideDelay)};this._addListener("touchend",e),this._addListener("touchcancel",e)}}}_addListener(e,t){this._eventCleanups.push(this._renderer.listen(this._elementRef.nativeElement,e,t,Y0))}_isTouchPlatform(){let e=this._defaultOptions?.detectHoverCapability;return typeof e=="function"?!e():this._platform.IOS||this._platform.ANDROID?!0:this._platform.isBrowser?!!e&&this._mediaMatcher.matchMedia("(any-hover: none)").matches:!1}_disableNativeGesturesIfNecessary(){let e=this.touchGestures;if(e!=="off"){let t=this._elementRef.nativeElement,n=t.style;(e==="on"||t.nodeName!=="INPUT"&&t.nodeName!=="TEXTAREA")&&(n.userSelect=n.msUserSelect=n.webkitUserSelect=n.MozUserSelect="none"),(e==="on"||!t.draggable)&&(n.webkitUserDrag="none"),n.touchAction="none",n.webkitTapHighlightColor="transparent"}}_syncAriaDescription(e){this._ariaDescriptionPending||(this._ariaDescriptionPending=!0,this._ariaDescriber.removeDescription(this._elementRef.nativeElement,e,"tooltip"),this._isDestroyed||Be({write:()=>{this._ariaDescriptionPending=!1,this.message&&!this.disabled&&this._ariaDescriber.describe(this._elementRef.nativeElement,this.message,"tooltip")}},{injector:this._injector}))}_overlayEventPredicate=e=>e.type==="keydown"?this._isTooltipVisible()&&e.keyCode===27&&!Ge(e):!0;static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matTooltip",""]],hostAttrs:[1,"mat-mdc-tooltip-trigger"],hostVars:2,hostBindings:function(t,n){t&2&&p("mat-mdc-tooltip-disabled",n.disabled)},inputs:{position:[0,"matTooltipPosition","position"],positionAtOrigin:[0,"matTooltipPositionAtOrigin","positionAtOrigin"],disabled:[0,"matTooltipDisabled","disabled"],showDelay:[0,"matTooltipShowDelay","showDelay"],hideDelay:[0,"matTooltipHideDelay","hideDelay"],touchGestures:[0,"matTooltipTouchGestures","touchGestures"],message:[0,"matTooltip","message"],tooltipClass:[0,"matTooltipClass","tooltipClass"]},exportAs:["matTooltip"]})}return i})(),xp=(()=>{class i{_changeDetectorRef=d(te);_elementRef=d(N);_isMultiline=!1;message;tooltipClass;_showTimeoutId;_hideTimeoutId;_triggerElement;_mouseLeaveHideDelay;_animationsDisabled=pe();_tooltip;_closeOnInteraction=!1;_isVisible=!1;_onHide=new I;_showAnimation="mat-mdc-tooltip-show";_hideAnimation="mat-mdc-tooltip-hide";show(e){this._hideTimeoutId!=null&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=setTimeout(()=>{this._toggleVisibility(!0),this._showTimeoutId=void 0},e)}hide(e){this._showTimeoutId!=null&&clearTimeout(this._showTimeoutId),this._hideTimeoutId=setTimeout(()=>{this._toggleVisibility(!1),this._hideTimeoutId=void 0},e)}afterHidden(){return this._onHide}isVisible(){return this._isVisible}ngOnDestroy(){this._cancelPendingAnimations(),this._onHide.complete(),this._triggerElement=null}_handleBodyInteraction(){this._closeOnInteraction&&this.hide(0)}_markForCheck(){this._changeDetectorRef.markForCheck()}_handleMouseLeave({relatedTarget:e}){(!e||!this._triggerElement.contains(e))&&(this.isVisible()?this.hide(this._mouseLeaveHideDelay):this._finalizeAnimation(!1))}_onShow(){this._isMultiline=this._isTooltipMultiline(),this._markForCheck()}_isTooltipMultiline(){let e=this._elementRef.nativeElement.getBoundingClientRect();return e.height>Q0&&e.width>=J0}_handleAnimationEnd({animationName:e}){(e===this._showAnimation||e===this._hideAnimation)&&this._finalizeAnimation(e===this._showAnimation)}_cancelPendingAnimations(){this._showTimeoutId!=null&&clearTimeout(this._showTimeoutId),this._hideTimeoutId!=null&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=this._hideTimeoutId=void 0}_finalizeAnimation(e){e?this._closeOnInteraction=!0:this.isVisible()||this._onHide.next()}_toggleVisibility(e){let t=this._tooltip.nativeElement,n=this._showAnimation,a=this._hideAnimation;if(t.classList.remove(e?a:n),t.classList.add(e?n:a),this._isVisible!==e&&(this._isVisible=e,this._changeDetectorRef.markForCheck()),e&&!this._animationsDisabled&&typeof getComputedStyle=="function"){let r=getComputedStyle(t);(r.getPropertyValue("animation-duration")==="0s"||r.getPropertyValue("animation-name")==="none")&&(this._animationsDisabled=!0)}e&&this._onShow(),this._animationsDisabled&&(t.classList.add("_mat-animation-noopable"),this._finalizeAnimation(e))}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-tooltip-component"]],viewQuery:function(t,n){if(t&1&&Me($0,7),t&2){let a;O(a=P())&&(n._tooltip=a.first)}},hostAttrs:["aria-hidden","true"],hostBindings:function(t,n){t&1&&A("mouseleave",function(r){return n._handleMouseLeave(r)})},decls:4,vars:5,consts:[["tooltip",""],[1,"mdc-tooltip","mat-mdc-tooltip",3,"animationend"],[1,"mat-mdc-tooltip-surface","mdc-tooltip__surface"]],template:function(t,n){t&1&&(Ie(0,"div",1,0),er("animationend",function(r){return n._handleAnimationEnd(r)}),Ie(2,"div",2),m(3),je()()),t&2&&(et(n.tooltipClass),p("mdc-tooltip--multiline",n._isMultiline),c(3),q(n.message))},styles:[`.mat-mdc-tooltip {
5478
+ `],encapsulation:2})}return i})();var Lo=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[Nt,Po,ee,_i,St,Po]})}return i})();var $0=["tooltip"],W0=20;var q0=new x("mat-tooltip-scroll-strategy",{providedIn:"root",factory:()=>{let i=d(X);return()=>yi(i,{scrollThrottle:W0})}}),K0=new x("mat-tooltip-default-options",{providedIn:"root",factory:()=>({showDelay:0,hideDelay:0,touchendHideDelay:1500})});var Cp="tooltip-panel",Y0={passive:!0},X0=8,Z0=8,Q0=24,J0=200,Ha=(()=>{class i{_elementRef=d(N);_ngZone=d(H);_platform=d(le);_ariaDescriber=d(Qm);_focusMonitor=d(Rt);_dir=d(qe);_injector=d(X);_viewContainerRef=d(Xe);_mediaMatcher=d(mo);_document=d(W);_renderer=d(ve);_animationsDisabled=pe();_defaultOptions=d(K0,{optional:!0});_overlayRef=null;_tooltipInstance=null;_overlayPanelClass;_portal;_position="below";_positionAtOrigin=!1;_disabled=!1;_tooltipClass;_viewInitialized=!1;_pointerExitEventsInitialized=!1;_tooltipComponent=xp;_viewportMargin=8;_currentPosition;_cssClassPrefix="mat-mdc";_ariaDescriptionPending=!1;_dirSubscribed=!1;get position(){return this._position}set position(e){e!==this._position&&(this._position=e,this._overlayRef&&(this._updatePosition(this._overlayRef),this._tooltipInstance?.show(0),this._overlayRef.updatePosition()))}get positionAtOrigin(){return this._positionAtOrigin}set positionAtOrigin(e){this._positionAtOrigin=mt(e),this._detach(),this._overlayRef=null}get disabled(){return this._disabled}set disabled(e){let t=mt(e);this._disabled!==t&&(this._disabled=t,t?this.hide(0):this._setupPointerEnterEventsIfNeeded(),this._syncAriaDescription(this.message))}get showDelay(){return this._showDelay}set showDelay(e){this._showDelay=Ht(e)}_showDelay;get hideDelay(){return this._hideDelay}set hideDelay(e){this._hideDelay=Ht(e),this._tooltipInstance&&(this._tooltipInstance._mouseLeaveHideDelay=this._hideDelay)}_hideDelay;touchGestures="auto";get message(){return this._message}set message(e){let t=this._message;this._message=e!=null?String(e).trim():"",!this._message&&this._isTooltipVisible()?this.hide(0):(this._setupPointerEnterEventsIfNeeded(),this._updateTooltipMessage()),this._syncAriaDescription(t)}_message="";get tooltipClass(){return this._tooltipClass}set tooltipClass(e){this._tooltipClass=e,this._tooltipInstance&&this._setTooltipClass(this._tooltipClass)}_eventCleanups=[];_touchstartTimeout=null;_destroyed=new I;_isDestroyed=!1;constructor(){let e=this._defaultOptions;e&&(this._showDelay=e.showDelay,this._hideDelay=e.hideDelay,e.position&&(this.position=e.position),e.positionAtOrigin&&(this.positionAtOrigin=e.positionAtOrigin),e.touchGestures&&(this.touchGestures=e.touchGestures),e.tooltipClass&&(this.tooltipClass=e.tooltipClass)),this._viewportMargin=X0}ngAfterViewInit(){this._viewInitialized=!0,this._setupPointerEnterEventsIfNeeded(),this._focusMonitor.monitor(this._elementRef).pipe(oe(this._destroyed)).subscribe(e=>{e?e==="keyboard"&&this._ngZone.run(()=>this.show()):this._ngZone.run(()=>this.hide(0))})}ngOnDestroy(){let e=this._elementRef.nativeElement;this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this._overlayRef&&(this._overlayRef.dispose(),this._tooltipInstance=null),this._eventCleanups.forEach(t=>t()),this._eventCleanups.length=0,this._destroyed.next(),this._destroyed.complete(),this._isDestroyed=!0,this._ariaDescriber.removeDescription(e,this.message,"tooltip"),this._focusMonitor.stopMonitoring(e)}show(e=this.showDelay,t){if(this.disabled||!this.message||this._isTooltipVisible()){this._tooltipInstance?._cancelPendingAnimations();return}let n=this._createOverlay(t);this._detach(),this._portal=this._portal||new bi(this._tooltipComponent,this._viewContainerRef);let a=this._tooltipInstance=n.attach(this._portal).instance;a._triggerElement=this._elementRef.nativeElement,a._mouseLeaveHideDelay=this._hideDelay,a.afterHidden().pipe(oe(this._destroyed)).subscribe(()=>this._detach()),this._setTooltipClass(this._tooltipClass),this._updateTooltipMessage(),a.show(e)}hide(e=this.hideDelay){let t=this._tooltipInstance;t&&(t.isVisible()?t.hide(e):(t._cancelPendingAnimations(),this._detach()))}toggle(e){this._isTooltipVisible()?this.hide():this.show(void 0,e)}_isTooltipVisible(){return!!this._tooltipInstance&&this._tooltipInstance.isVisible()}_createOverlay(e){if(this._overlayRef){let r=this._overlayRef.getConfig().positionStrategy;if((!this.positionAtOrigin||!e)&&r._origin instanceof N)return this._overlayRef;this._detach()}let t=this._injector.get(gn).getAncestorScrollContainers(this._elementRef),n=`${this._cssClassPrefix}-${Cp}`,a=$i(this._injector,this.positionAtOrigin?e||this._elementRef:this._elementRef).withTransformOriginOn(`.${this._cssClassPrefix}-tooltip`).withFlexibleDimensions(!1).withViewportMargin(this._viewportMargin).withScrollableContainers(t).withPopoverLocation("global");return a.positionChanges.pipe(oe(this._destroyed)).subscribe(r=>{this._updateCurrentPositionClass(r.connectionPair),this._tooltipInstance&&r.scrollableViewProperties.isOverlayClipped&&this._tooltipInstance.isVisible()&&this._ngZone.run(()=>this.hide(0))}),this._overlayRef=qt(this._injector,{direction:this._dir,positionStrategy:a,panelClass:this._overlayPanelClass?[...this._overlayPanelClass,n]:n,scrollStrategy:this._injector.get(q0)(),disableAnimations:this._animationsDisabled,eventPredicate:this._overlayEventPredicate}),this._updatePosition(this._overlayRef),this._overlayRef.detachments().pipe(oe(this._destroyed)).subscribe(()=>this._detach()),this._overlayRef.outsidePointerEvents().pipe(oe(this._destroyed)).subscribe(()=>this._tooltipInstance?._handleBodyInteraction()),this._overlayRef.keydownEvents().pipe(oe(this._destroyed)).subscribe(r=>{r.preventDefault(),r.stopPropagation(),this._ngZone.run(()=>this.hide(0))}),this._defaultOptions?.disableTooltipInteractivity&&this._overlayRef.addPanelClass(`${this._cssClassPrefix}-tooltip-panel-non-interactive`),this._dirSubscribed||(this._dirSubscribed=!0,this._dir.change.pipe(oe(this._destroyed)).subscribe(()=>{this._overlayRef&&this._updatePosition(this._overlayRef)})),this._overlayRef}_detach(){this._overlayRef&&this._overlayRef.hasAttached()&&this._overlayRef.detach(),this._tooltipInstance=null}_updatePosition(e){let t=e.getConfig().positionStrategy,n=this._getOrigin(),a=this._getOverlayPosition();t.withPositions([this._addOffset(V(V({},n.main),a.main)),this._addOffset(V(V({},n.fallback),a.fallback))])}_addOffset(e){let t=Z0,n=!this._dir||this._dir.value=="ltr";return e.originY==="top"?e.offsetY=-t:e.originY==="bottom"?e.offsetY=t:e.originX==="start"?e.offsetX=n?-t:t:e.originX==="end"&&(e.offsetX=n?t:-t),e}_getOrigin(){let e=!this._dir||this._dir.value=="ltr",t=this.position,n;t=="above"||t=="below"?n={originX:"center",originY:t=="above"?"top":"bottom"}:t=="before"||t=="left"&&e||t=="right"&&!e?n={originX:"start",originY:"center"}:(t=="after"||t=="right"&&e||t=="left"&&!e)&&(n={originX:"end",originY:"center"});let{x:a,y:r}=this._invertPosition(n.originX,n.originY);return{main:n,fallback:{originX:a,originY:r}}}_getOverlayPosition(){let e=!this._dir||this._dir.value=="ltr",t=this.position,n;t=="above"?n={overlayX:"center",overlayY:"bottom"}:t=="below"?n={overlayX:"center",overlayY:"top"}:t=="before"||t=="left"&&e||t=="right"&&!e?n={overlayX:"end",overlayY:"center"}:(t=="after"||t=="right"&&e||t=="left"&&!e)&&(n={overlayX:"start",overlayY:"center"});let{x:a,y:r}=this._invertPosition(n.overlayX,n.overlayY);return{main:n,fallback:{overlayX:a,overlayY:r}}}_updateTooltipMessage(){this._tooltipInstance&&(this._tooltipInstance.message=this.message,this._tooltipInstance._markForCheck(),Be(()=>{this._tooltipInstance&&this._overlayRef.updatePosition()},{injector:this._injector}))}_setTooltipClass(e){this._tooltipInstance&&(this._tooltipInstance.tooltipClass=e instanceof Set?Array.from(e):e,this._tooltipInstance._markForCheck())}_invertPosition(e,t){return this.position==="above"||this.position==="below"?t==="top"?t="bottom":t==="bottom"&&(t="top"):e==="end"?e="start":e==="start"&&(e="end"),{x:e,y:t}}_updateCurrentPositionClass(e){let{overlayY:t,originX:n,originY:a}=e,r;if(t==="center"?this._dir&&this._dir.value==="rtl"?r=n==="end"?"left":"right":r=n==="start"?"left":"right":r=t==="bottom"&&a==="top"?"above":"below",r!==this._currentPosition){let u=this._overlayRef;if(u){let h=`${this._cssClassPrefix}-${Cp}-`;u.removePanelClass(h+this._currentPosition),u.addPanelClass(h+r)}this._currentPosition=r}}_setupPointerEnterEventsIfNeeded(){this._disabled||!this.message||!this._viewInitialized||this._eventCleanups.length||(this._isTouchPlatform()?this.touchGestures!=="off"&&(this._disableNativeGesturesIfNecessary(),this._addListener("touchstart",e=>{let t=e.targetTouches?.[0],n=t?{x:t.clientX,y:t.clientY}:void 0;this._setupPointerExitEventsIfNeeded(),this._touchstartTimeout&&clearTimeout(this._touchstartTimeout);let a=500;this._touchstartTimeout=setTimeout(()=>{this._touchstartTimeout=null,this.show(void 0,n)},this._defaultOptions?.touchLongPressShowDelay??a)})):this._addListener("mouseenter",e=>{this._setupPointerExitEventsIfNeeded();let t;e.x!==void 0&&e.y!==void 0&&(t=e),this.show(void 0,t)}))}_setupPointerExitEventsIfNeeded(){if(!this._pointerExitEventsInitialized){if(this._pointerExitEventsInitialized=!0,!this._isTouchPlatform())this._addListener("mouseleave",e=>{let t=e.relatedTarget;(!t||!this._overlayRef?.overlayElement.contains(t))&&this.hide()}),this._addListener("wheel",e=>{if(this._isTooltipVisible()){let t=this._document.elementFromPoint(e.clientX,e.clientY),n=this._elementRef.nativeElement;t!==n&&!n.contains(t)&&this.hide()}});else if(this.touchGestures!=="off"){this._disableNativeGesturesIfNecessary();let e=()=>{this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this.hide(this._defaultOptions?.touchendHideDelay)};this._addListener("touchend",e),this._addListener("touchcancel",e)}}}_addListener(e,t){this._eventCleanups.push(this._renderer.listen(this._elementRef.nativeElement,e,t,Y0))}_isTouchPlatform(){let e=this._defaultOptions?.detectHoverCapability;return typeof e=="function"?!e():this._platform.IOS||this._platform.ANDROID?!0:this._platform.isBrowser?!!e&&this._mediaMatcher.matchMedia("(any-hover: none)").matches:!1}_disableNativeGesturesIfNecessary(){let e=this.touchGestures;if(e!=="off"){let t=this._elementRef.nativeElement,n=t.style;(e==="on"||t.nodeName!=="INPUT"&&t.nodeName!=="TEXTAREA")&&(n.userSelect=n.msUserSelect=n.webkitUserSelect=n.MozUserSelect="none"),(e==="on"||!t.draggable)&&(n.webkitUserDrag="none"),n.touchAction="none",n.webkitTapHighlightColor="transparent"}}_syncAriaDescription(e){this._ariaDescriptionPending||(this._ariaDescriptionPending=!0,this._ariaDescriber.removeDescription(this._elementRef.nativeElement,e,"tooltip"),this._isDestroyed||Be({write:()=>{this._ariaDescriptionPending=!1,this.message&&!this.disabled&&this._ariaDescriber.describe(this._elementRef.nativeElement,this.message,"tooltip")}},{injector:this._injector}))}_overlayEventPredicate=e=>e.type==="keydown"?this._isTooltipVisible()&&e.keyCode===27&&!Ge(e):!0;static \u0275fac=function(t){return new(t||i)};static \u0275dir=k({type:i,selectors:[["","matTooltip",""]],hostAttrs:[1,"mat-mdc-tooltip-trigger"],hostVars:2,hostBindings:function(t,n){t&2&&p("mat-mdc-tooltip-disabled",n.disabled)},inputs:{position:[0,"matTooltipPosition","position"],positionAtOrigin:[0,"matTooltipPositionAtOrigin","positionAtOrigin"],disabled:[0,"matTooltipDisabled","disabled"],showDelay:[0,"matTooltipShowDelay","showDelay"],hideDelay:[0,"matTooltipHideDelay","hideDelay"],touchGestures:[0,"matTooltipTouchGestures","touchGestures"],message:[0,"matTooltip","message"],tooltipClass:[0,"matTooltipClass","tooltipClass"]},exportAs:["matTooltip"]})}return i})(),xp=(()=>{class i{_changeDetectorRef=d(te);_elementRef=d(N);_isMultiline=!1;message;tooltipClass;_showTimeoutId;_hideTimeoutId;_triggerElement;_mouseLeaveHideDelay;_animationsDisabled=pe();_tooltip;_closeOnInteraction=!1;_isVisible=!1;_onHide=new I;_showAnimation="mat-mdc-tooltip-show";_hideAnimation="mat-mdc-tooltip-hide";show(e){this._hideTimeoutId!=null&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=setTimeout(()=>{this._toggleVisibility(!0),this._showTimeoutId=void 0},e)}hide(e){this._showTimeoutId!=null&&clearTimeout(this._showTimeoutId),this._hideTimeoutId=setTimeout(()=>{this._toggleVisibility(!1),this._hideTimeoutId=void 0},e)}afterHidden(){return this._onHide}isVisible(){return this._isVisible}ngOnDestroy(){this._cancelPendingAnimations(),this._onHide.complete(),this._triggerElement=null}_handleBodyInteraction(){this._closeOnInteraction&&this.hide(0)}_markForCheck(){this._changeDetectorRef.markForCheck()}_handleMouseLeave({relatedTarget:e}){(!e||!this._triggerElement.contains(e))&&(this.isVisible()?this.hide(this._mouseLeaveHideDelay):this._finalizeAnimation(!1))}_onShow(){this._isMultiline=this._isTooltipMultiline(),this._markForCheck()}_isTooltipMultiline(){let e=this._elementRef.nativeElement.getBoundingClientRect();return e.height>Q0&&e.width>=J0}_handleAnimationEnd({animationName:e}){(e===this._showAnimation||e===this._hideAnimation)&&this._finalizeAnimation(e===this._showAnimation)}_cancelPendingAnimations(){this._showTimeoutId!=null&&clearTimeout(this._showTimeoutId),this._hideTimeoutId!=null&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=this._hideTimeoutId=void 0}_finalizeAnimation(e){e?this._closeOnInteraction=!0:this.isVisible()||this._onHide.next()}_toggleVisibility(e){let t=this._tooltip.nativeElement,n=this._showAnimation,a=this._hideAnimation;if(t.classList.remove(e?a:n),t.classList.add(e?n:a),this._isVisible!==e&&(this._isVisible=e,this._changeDetectorRef.markForCheck()),e&&!this._animationsDisabled&&typeof getComputedStyle=="function"){let r=getComputedStyle(t);(r.getPropertyValue("animation-duration")==="0s"||r.getPropertyValue("animation-name")==="none")&&(this._animationsDisabled=!0)}e&&this._onShow(),this._animationsDisabled&&(t.classList.add("_mat-animation-noopable"),this._finalizeAnimation(e))}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=T({type:i,selectors:[["mat-tooltip-component"]],viewQuery:function(t,n){if(t&1&&Me($0,7),t&2){let a;O(a=P())&&(n._tooltip=a.first)}},hostAttrs:["aria-hidden","true"],hostBindings:function(t,n){t&1&&A("mouseleave",function(r){return n._handleMouseLeave(r)})},decls:4,vars:5,consts:[["tooltip",""],[1,"mdc-tooltip","mat-mdc-tooltip",3,"animationend"],[1,"mat-mdc-tooltip-surface","mdc-tooltip__surface"]],template:function(t,n){t&1&&(Ie(0,"div",1,0),nr("animationend",function(r){return n._handleAnimationEnd(r)}),Ie(2,"div",2),m(3),je()()),t&2&&(et(n.tooltipClass),p("mdc-tooltip--multiline",n._isMultiline),c(3),q(n.message))},styles:[`.mat-mdc-tooltip {
5479
5479
  position: relative;
5480
5480
  transform: scale(0);
5481
5481
  display: inline-flex;
@@ -5580,19 +5580,19 @@ div.mat-mdc-select-panel {
5580
5580
  .mat-mdc-tooltip-hide {
5581
5581
  animation: mat-mdc-tooltip-hide 75ms cubic-bezier(0.4, 0, 1, 1) forwards;
5582
5582
  }
5583
- `],encapsulation:2})}return i})();var Is=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[sa,Nt,ee,_i]})}return i})();function wn(i,o){for(let e of i){let t=e.indexOf("=");if(t>0&&e.slice(0,t)===o)return e.slice(t+1);let n=e.indexOf(" ");if(n>0&&e.slice(0,n)===o)return e.slice(n+1).trim()}for(let e=0;e<i.length;e++)if(i[e]===o&&e+1<i.length)return i[e+1];return null}function Wn(i,o,e,t){for(let n of i){let a=n.split(/\s|=/)[0];if(a===o)return!0;if(a===e)return!1}return t}function Ke(i,o,e){let t=wn(i,o);return t!==null?t:e}function Ee(i,o,e){let t=wn(i,o);if(t!==null){let n=parseInt(t,10);return isNaN(n)?e:n}return e}function ut(i,o,e){let t=wn(i,o);if(t!==null){let n=parseFloat(t);return isNaN(n)?e:n}return e}var ey=(i,o)=>o.path;function ty(i,o){i&1&&(s(0,"span",7),m(1,"(dir)"),l())}function iy(i,o){if(i&1&&(s(0,"mat-option",5)(1,"span",6),m(2),l(),M(3,ty,2,0,"span",7),l()),i&2){let e=o.$implicit;x("value",e.path),c(2),q(e.path),c(),E(e.isDir?3:-1)}}var Dp=(()=>{class i{constructor(){this.fb=d(un),this.service=d(_t),this.label="Path",this.placeholder="/path/to/file",this.required=!1,this.fieldClass="",this.existingPaths=[],this.onChange=e=>{},this.onTouched=()=>{},this._subscription=null,this.suggestions=R([]),this.innerForm=this.fb.group({value:[""]})}writeValue(e){let t=(e??"").toString();this.innerForm.patchValue({value:t},{emitEvent:!1})}registerOnChange(e){this.onChange=e}registerOnTouched(e){this.onTouched=e}setDisabledState(e){e?this.innerForm.disable():this.innerForm.enable()}ngOnInit(){this._subscription=this.innerForm.get("value").valueChanges.subscribe(e=>{this.onChange(e)}),this._subscription.add(this.innerForm.get("value").valueChanges.pipe(Vt(200),xi(),We(e=>{let t=(e??"").trim();return t?this.service.getLlamaAutocomplete("path",t).pipe(Kt(()=>ge([]))):ge(this.emptySuggestions)})).subscribe(e=>{this.suggestions.set(e)}))}get emptySuggestions(){return this.existingPaths.filter(Boolean).map(e=>({path:e,source:"existing config"}))}ngOnDestroy(){this._subscription?.unsubscribe()}onSelect(e){this.innerForm.patchValue({value:e},{emitEvent:!1}),this.onChange(e)}onBlur(){this.onTouched()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-file-autocomplete"]],inputs:{label:"label",placeholder:"placeholder",required:"required",fieldClass:"fieldClass",existingPaths:"existingPaths"},features:[J([{provide:Mi,useExisting:nt(()=>i),multi:!0}])],decls:9,vars:7,consts:[["auto","matAutocomplete"],[3,"formGroup"],["appearance","outline",1,"full-width"],["matInput","","formControlName","value",3,"blur","placeholder","required","matAutocomplete"],[3,"optionSelected"],[3,"value"],[1,"file-path"],[1,"file-dir"]],template:function(t,n){if(t&1&&(ui(0,1),s(1,"mat-form-field",2)(2,"input",3),A("blur",function(){return n.onBlur()}),l(),b(),s(3,"mat-label"),m(4),l()(),s(5,"mat-autocomplete",4,0),A("optionSelected",function(r){return n.onSelect(r.option.value)}),me(7,iy,4,3,"mat-option",5,ey),l(),hi()),t&2){let a=Ne(6);x("formGroup",n.innerForm),c(),et(n.fieldClass),c(),x("placeholder",n.placeholder)("required",n.required)("matAutocomplete",a),y(),c(2),q(n.label),c(3),ue(n.suggestions())}},dependencies:[Ve,pn,Ei,Ai,mn,Kr,Ut,ji,St,kt,Ot,ti,ei,xn,Cn,vt,Wi],styles:[".full-width[_ngcontent-%COMP%]{width:100%}.file-path[_ngcontent-%COMP%]{font-family:monospace}.file-dir[_ngcontent-%COMP%]{margin-left:4px;color:#1976d2;font-size:11px;font-weight:500}.file-source[_ngcontent-%COMP%]{margin-left:8px;opacity:.6;font-size:12px}"]})}}return i})();function qi(i){i||(i=d(Bt));let o=new yt(e=>{if(i.destroyed){e.next();return}return i.onDestroy(e.next.bind(e))});return e=>e.pipe(oe(o))}function qn(i,o){let t=!o?.manualCleanup?o?.injector?.get(Bt)??d(Bt):null,n=ny(o?.equal),a;o?.requireSync?a=R({kind:0},{equal:n}):a=R({kind:1,value:o?.initialValue},{equal:n});let r,u=i.subscribe({next:h=>a.set({kind:1,value:h}),error:h=>{a.set({kind:2,error:h}),r?.()},complete:()=>{r?.()}});if(o?.requireSync&&a().kind===0)throw new ae(601,!1);return r=t?.onDestroy(u.unsubscribe.bind(u)),W(()=>{let h=a();switch(h.kind){case 1:return h.value;case 2:throw h.error;case 0:throw new ae(601,!1)}},{equal:o?.equal})}function ny(i=Object.is){return(o,e)=>o.kind===1&&e.kind===1&&i(o.value,e.value)}function Rs(i){if(typeof i=="number")return i;let o=i.trim();if(!o)return 0;let e=o.split(/\s*x\s*/i),t=1,n;if(e.length>=2){let h=e[0].trim();h&&(t=parseInt(h,10),(isNaN(t)||t<1)&&(t=1)),n=e.slice(1).join("").trim()}else n=o;let a=n.match(/^(\d+)\s*([kKmM])?$/);if(!a)return 0;let r=parseInt(a[1],10),u=a[2];return u&&(u.toLowerCase()==="k"?r*=1024:u.toLowerCase()==="m"&&(r*=1024*1024)),t*r}var jc=[8192,16384,32768,65536,98304,131072,196608,262144,524288,1048576];function kp(i){if(i<=0)return"0";if(i>=1048576){let o=i/1048576;return`${o%1===0?o:o.toFixed(1)}M`}if(i>=1024){let o=i/1024;return`${o%1===0?o:o.toFixed(1)}K`}return`${i}`}function Os(i,o){if(i<=0)return"";if(o>1&&i%o===0){let e=i/o;if(jc.includes(e))return`${o} x ${kp(e)}`}return kp(i)}var oy=(i,o)=>o.command,Hc=(i,o)=>o.path,ay=(i,o)=>o.label;function ry(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function sy(i,o){i&1&&(s(0,"mat-error"),m(1,"Starts with letter, alphanumeric + hyphens/underscores, max 128 chars"),l())}function ly(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function cy(i,o){if(i&1&&(s(0,"mat-option",8)(1,"span",100),m(2),l(),s(3,"span",101),m(4),l()()),i&2){let e=o.$implicit;x("value",e.command),c(2),q(e.command),c(2),he("(",e.from,")")}}function dy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e.path),c(),q(e.path)}}function my(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e.label),c(),q(e.label)}}function uy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e),c(),q(e)}}function hy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e),c(),q(e)}}function py(i,o){if(i&1&&(s(0,"div",26),m(1,"YaRN Parameters"),l(),s(2,"div",13)(3,"mat-form-field",18),v(4,"input",102),b(),s(5,"mat-label"),m(6,"YaRN Orig Ctx"),l()(),s(7,"mat-form-field",18),v(8,"input",103),b(),s(9,"mat-label"),m(10,"Extrapolation Mix"),l()(),s(11,"mat-form-field",18),v(12,"input",104),b(),s(13,"mat-label"),m(14,"Attn Factor"),l()(),s(15,"mat-form-field",18),v(16,"input",105),b(),s(17,"mat-label"),m(18,"Beta Slow"),l()(),s(19,"mat-form-field",18),v(20,"input",106),b(),s(21,"mat-label"),m(22,"Beta Fast"),l()()()),i&2){let e=D();c(3),p("changed",e.isControlChanged("yarnOrigCtx")),c(),y(),c(3),p("changed",e.isControlChanged("yarnExtFactor")),c(),y(),c(3),p("changed",e.isControlChanged("yarnAttnFactor")),c(),y(),c(3),p("changed",e.isControlChanged("yarnBetaSlow")),c(),y(),c(3),p("changed",e.isControlChanged("yarnBetaFast")),c(),y()}}function fy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e.path),c(),q(e.path)}}function gy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e),c(),q(e)}}function _y(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e),c(),q(e)}}function vy(i,o){if(i&1&&(s(0,"div",26),m(1,"Draft Model"),l(),v(2,"app-file-autocomplete",107),b(),s(3,"div",13)(4,"mat-form-field",18)(5,"mat-select",108),me(6,fy,2,2,"mat-option",8,Hc),l(),b(),s(8,"mat-label"),m(9,"Draft Device (multi-select)"),l()()(),s(10,"div",13)(11,"mat-form-field",18),v(12,"input",109),b(),s(13,"mat-label"),m(14,"Draft N Max"),l()(),s(15,"mat-form-field",18),v(16,"input",110),b(),s(17,"mat-label"),m(18,"Draft GPU Layers"),l()()(),s(19,"div",13)(20,"mat-form-field",18)(21,"mat-select",111),me(22,gy,2,2,"mat-option",8,xt),l(),b(),s(24,"mat-label"),m(25,"Draft Cache Type K"),l()(),s(26,"mat-form-field",18)(27,"mat-select",112),me(28,_y,2,2,"mat-option",8,xt),l(),b(),s(30,"mat-label"),m(31,"Draft Cache Type V"),l()()()),i&2){let e=D();c(2),x("existingPaths",e.existingDraftModelPaths())("fieldClass",e.isControlChanged("modelDraft")?"changed":""),y(),c(2),p("changed",e.isControlChanged("specDraftDevice")),c(),y(),c(),ue(e.availableDevices()),c(5),p("changed",e.isControlChanged("specDraftNMax")),c(),y(),c(3),p("changed",e.isControlChanged("nGpuLayersDraft")),c(),y(),c(4),p("changed",e.isControlChanged("specDraftCacheTypeK")),c(),y(),c(),ue(e.kvCacheTypes),c(4),p("changed",e.isControlChanged("specDraftCacheTypeV")),c(),y(),c(),ue(e.kvCacheTypes)}}function by(i,o){if(i&1&&(s(0,"div",26),m(1,"Ngram Mod Parameters"),l(),s(2,"div",13)(3,"mat-form-field",18),v(4,"input",113),b(),s(5,"mat-label"),m(6,"Ngram Mod N Min"),l()(),s(7,"mat-form-field",18),v(8,"input",114),b(),s(9,"mat-label"),m(10,"Ngram Mod N Max"),l()(),s(11,"mat-form-field",18),v(12,"input",115),b(),s(13,"mat-label"),m(14,"Ngram Mod Match"),l()()()),i&2){let e=D();c(3),p("changed",e.isControlChanged("specNgramModNMin")),c(),y(),c(3),p("changed",e.isControlChanged("specNgramModNMax")),c(),y(),c(3),p("changed",e.isControlChanged("specNgramModNMatch")),c(),y()}}function yy(i,o){if(i&1&&(s(0,"div",26),m(1,"Ngram Simple Parameters"),l(),s(2,"div",13)(3,"mat-form-field",18),v(4,"input",116),b(),s(5,"mat-label"),m(6,"Simple Size N"),l()(),s(7,"mat-form-field",18),v(8,"input",117),b(),s(9,"mat-label"),m(10,"Simple Size M"),l()(),s(11,"mat-form-field",18),v(12,"input",118),b(),s(13,"mat-label"),m(14,"Simple Min Hits"),l()()()),i&2){let e=D();c(3),p("changed",e.isControlChanged("specNgramSimpleSizeN")),c(),y(),c(3),p("changed",e.isControlChanged("specNgramSimpleSizeM")),c(),y(),c(3),p("changed",e.isControlChanged("specNgramSimpleMinHits")),c(),y()}}function Cy(i,o){if(i&1&&(s(0,"mat-option",8)(1,"span",100),m(2),l(),s(3,"span",101),m(4),l()()),i&2){let e=o.$implicit;x("value",e.path),c(2),q(e.path),c(2),he("(",e.source,")")}}var f={host:"127.0.0.1",port:8080,threads:-1,flashAttn:"auto",fit:"on",parallel:-1,alias:"",nPredict:-1,contextShift:"off",contBatching:"on",model:"",mmproj:"",nGpuLayers:"auto",device:[],tensorSplit:"",splitMode:"layer",mainGpu:0,fitTarget:1024,fitCtx:4096,mlock:"off",mmap:"on",cpuMoe:"off",nCpuMoe:0,ctxSize:0,batchSize:2048,ubatchSize:512,cacheTypeK:"f16",cacheTypeV:"f16",kvOffload:"on",cacheRam:8192,swaFull:"off",ropeScaling:"none",ropeScale:1,ropeFreqBase:0,ropeFreqScale:0,yarnOrigCtx:0,yarnExtFactor:-1,yarnAttnFactor:-1,yarnBetaSlow:-1,yarnBetaFast:-1,temperature:.8,seed:-1,topK:40,topP:.95,minP:.05,typicalP:1,repeatLastN:64,repeatPenalty:1,presencePenalty:0,frequencyPenalty:0,dryMultiplier:0,dryBase:1.75,mirostat:0,dynatempRange:0,modelDraft:"",specDraftDevice:[],specDraftNMax:3,nGpuLayersDraft:"auto",specDraftCacheTypeK:"f16",specDraftCacheTypeV:"f16",specType:"none",specNgramModNMin:48,specNgramModNMax:64,specNgramModNMatch:24,specNgramSimpleSizeN:12,specNgramSimpleSizeM:48,specNgramSimpleMinHits:1,lora:"",loraScaled:"",timeout:3600,threadsHttp:-1,metrics:"off",slots:"on",cachePrompt:"on",cacheReuse:0,reasoning:"auto",reasoningBudget:-1,reasoningFormat:"auto",apiKeyFile:""};function xy(i,o){let e=f[i];if(e===void 0)return!1;if(Array.isArray(o)||Array.isArray(e)){let t=Array.isArray(o)?o:[],n=Array.isArray(e)?e:[];return t.length!==n.length||t.some((a,r)=>a!==n[r])}return String(o)!==String(e)}var wy="^[a-zA-Z][a-zA-Z0-9_-]{0,127}$",Dy=["f32","f16","bf16","q8_0","q4_0","q4_1","iq4_nl","q5_0","q5_1"],ky=new Set(["--host","--port","--threads","--flash-attn","--fit","--parallel","--alias","--n-predict","--context-shift","--no-context-shift","--cont-batching","--no-cont-batching","--device","--tensor-split","--model","--mmproj","--n-gpu-layers","--split-mode","--main-gpu","--fit-target","--fit-ctx","--mlock","--mmap","--no-mmap","--cpu-moe","--n-cpu-moe","--ctx-size","--batch-size","--ubatch-size","--cache-type-k","--cache-type-v","--kv-offload","--no-kv-offload","--cache-ram","--swa-full","--rope-scaling","--rope-scale","--rope-freq-base","--rope-freq-scale","--yarn-orig-ctx","--yarn-ext-factor","--yarn-attn-factor","--yarn-beta-slow","--yarn-beta-fast","--temperature","--seed","--top-k","--top-p","--min-p","--typical","--repeat-last-n","--repeat-penalty","--presence-penalty","--frequency-penalty","--dry-multiplier","--dry-base","--mirostat","--dynatemp-range","--spec-type","--spec-draft-n-max","--model-draft","--spec-draft-device","--device-draft","--n-gpu-layers-draft","--cache-type-k-draft","--cache-type-v-draft","--spec-ngram-mod-n-min","--spec-ngram-mod-n-max","--spec-ngram-mod-n-match","--spec-ngram-simple-size-n","--spec-ngram-simple-size-m","--spec-ngram-simple-min-hits","--lora","--lora-scaled","--timeout","--threads-http","--metrics","--slots","--no-slots","--cache-prompt","--no-cache-prompt","--cache-reuse","--reasoning","--reasoning-budget","--reasoning-format","--api-key-file"]),Sp=(()=>{class i{constructor(){this.fb=d(un),this.dialogRef=d(gt),this.data=d(Gn),this.serviceService=d(_t),this.cdr=d(te),this.destroyRef=d(Bt),this.isEdit=this.data.config!==null,this.isClone=this.data.clone===!0,this.kvCacheTypes=Dy,this.allExistingCommands=W(()=>{let e=this.data.allConfigs??[],t=this.data.config?.name??null,n=new Set,a=[];for(let r of e)r.name!==t&&(n.has(r.command)||(n.add(r.command),a.push({command:r.command,from:r.name})));return a}),this._commandValue=R(this.data.config?.command??""),this.commandValue=this._commandValue.asReadonly(),this.filteredCommands=W(()=>{let e=this.commandValue()?.toLowerCase()??"";return this.allExistingCommands().filter(t=>t.command.toLowerCase().includes(e)||t.from.toLowerCase().includes(e))}),this.form=this.fb.group({name:[this.data.config?.name??"",{validators:[st.required,st.pattern(wy)]}],command:[this.data.config?.command??"",st.required],host:[f.host],port:[f.port],threads:[f.threads],flashAttn:[f.flashAttn],fit:[f.fit],parallel:[f.parallel],alias:[f.alias],nPredict:[f.nPredict],contextShift:[f.contextShift],contBatching:[f.contBatching],model:[""],mmproj:[""],nGpuLayers:[f.nGpuLayers],device:[[]],tensorSplit:[""],splitMode:[f.splitMode],mainGpu:[f.mainGpu],fitTarget:[f.fitTarget],fitCtx:[f.fitCtx],mlock:[f.mlock],mmap:[f.mmap],cpuMoe:[f.cpuMoe],nCpuMoe:[f.nCpuMoe],ctxSize:[""],batchSize:[f.batchSize],ubatchSize:[f.ubatchSize],cacheTypeK:[f.cacheTypeK],cacheTypeV:[f.cacheTypeV],kvOffload:[f.kvOffload],cacheRam:[f.cacheRam],swaFull:[f.swaFull],ropeScaling:[f.ropeScaling],ropeScale:[f.ropeScale],ropeFreqBase:[f.ropeFreqBase],ropeFreqScale:[f.ropeFreqScale],yarnOrigCtx:[f.yarnOrigCtx],yarnExtFactor:[f.yarnExtFactor],yarnAttnFactor:[f.yarnAttnFactor],yarnBetaSlow:[f.yarnBetaSlow],yarnBetaFast:[f.yarnBetaFast],temperature:[f.temperature],seed:[f.seed],topK:[f.topK],topP:[f.topP],minP:[f.minP],typicalP:[f.typicalP],repeatLastN:[f.repeatLastN],repeatPenalty:[f.repeatPenalty],presencePenalty:[f.presencePenalty],frequencyPenalty:[f.frequencyPenalty],dryMultiplier:[f.dryMultiplier],dryBase:[f.dryBase],mirostat:[f.mirostat],dynatempRange:[f.dynatempRange],modelDraft:[""],specDraftDevice:[[]],specDraftNMax:[f.specDraftNMax],nGpuLayersDraft:[f.nGpuLayersDraft],specDraftCacheTypeK:[f.specDraftCacheTypeK],specDraftCacheTypeV:[f.specDraftCacheTypeV],specType:[f.specType],specNgramModNMin:[f.specNgramModNMin],specNgramModNMax:[f.specNgramModNMax],specNgramModNMatch:[f.specNgramModNMatch],specNgramSimpleSizeN:[f.specNgramSimpleSizeN],specNgramSimpleSizeM:[f.specNgramSimpleSizeM],specNgramSimpleMinHits:[f.specNgramSimpleMinHits],lora:[""],loraScaled:[""],timeout:[f.timeout],threadsHttp:[f.threadsHttp],metrics:[f.metrics],slots:[f.slots],cachePrompt:[f.cachePrompt],cacheReuse:[f.cacheReuse],reasoning:[f.reasoning],reasoningBudget:[f.reasoningBudget],reasoningFormat:[f.reasoningFormat],apiKeyFile:[""],extraFlags:[""],envText:[""]}),this.availableDevices=W(()=>this.availableDevicesRaw()),this.availableDevicesRaw=qn(this.form.controls.command.valueChanges.pipe(qi(),ke(this.form.controls.command.value),Vt(300),xi(),We(e=>{let t=(e??"").trim();return t?this.serviceService.getLlamaAutocomplete("device","",t).pipe(Kt(()=>ge([]))):this.serviceService.getLlamaAutocomplete("device","").pipe(Kt(()=>ge([])))})),{initialValue:[]}),this.filteredHosts=qn(this.form.controls.host.valueChanges.pipe(qi(),ke(this.form.controls.host.value),Vt(250),xi(),We(e=>{let t=(e??"").trim();return t?this.serviceService.getLlamaAutocomplete("host",t).pipe(Kt(()=>ge([]))):ge([])})),{initialValue:[]}),this.existingModelPaths=W(()=>this.extractConfigPaths("--model")),this.existingMmprojPaths=W(()=>this.extractConfigPaths("--mmproj")),this.existingApiKeyPaths=W(()=>this.extractConfigPaths("--api-key-file")),this.existingDraftModelPaths=W(()=>this.extractConfigPaths("--model-draft")),this.existingLoraPaths=W(()=>this.extractConfigPaths("--lora")),this.formValue=qn(this.form.valueChanges,{initialValue:this.form.value}),this.fitValue=W(()=>this.formValue()?.fit),this.splitModeValue=W(()=>this.formValue()?.splitMode),this.specTypeValue=W(()=>this.formValue()?.specType),this.ropeScalingValue=W(()=>this.formValue()?.ropeScaling),this.cpuMoeValue=W(()=>this.formValue()?.cpuMoe),this.cachePromptValue=W(()=>this.formValue()?.cachePrompt),this.reasoningValue=W(()=>this.formValue()?.reasoning),this.mirostatValue=W(()=>this.formValue()?.mirostat),this.hostValue=W(()=>this.formValue()?.host),this.isTensorSplitDisabled=W(()=>this.splitModeValue()==="none"),this.isFitTargetDisabled=W(()=>this.fitValue()==="off"),this.isCpuMoeLayersDisabled=W(()=>this.cpuMoeValue()==="on"),this.isCacheReuseDisabled=W(()=>this.cachePromptValue()==="off"),this.isReasoningParamsDisabled=W(()=>this.reasoningValue()==="off"),this.isMirostatEnabled=W(()=>(this.mirostatValue()??0)!==0),this.isRopeParamsDisabled=W(()=>this.ropeScalingValue()==="none"),this.isPortDisabled=W(()=>(this.hostValue()??"").trim().toLowerCase().endsWith(".sock")),this.showDraftParams=W(()=>(this.specTypeValue()??"").includes("draft")),this.showNgramModParams=W(()=>(this.specTypeValue()??"").includes("ngram-mod")),this.showNgramSimpleParams=W(()=>(this.specTypeValue()??"").includes("ngram-simple")),this.showYarnParams=W(()=>this.ropeScalingValue()==="yarn"),this.parallelSlots=W(()=>{let e=this.formValue()?.parallel;return typeof e=="number"&&e>0?e:1}),this.ctxPresets=W(()=>{let e=this.parallelSlots();return jc.map(t=>({label:Os(e*t,e)}))}),this._flags=null}extractConfigPaths(e){let t=this.data.allConfigs??[],n=this.data.config?.name??null,a=new Set,r=[];for(let u of t){if(u.name===n||!u.flags)continue;let h=wn(u.flags,e);h&&!a.has(h)&&(a.add(h),r.push(h))}return r}isControlChanged(e){let t=this.form.get(e)?.value;return e==="ctxSize"?+Rs(t)!==f.ctxSize:t!==void 0&&xy(e,t)}isSectionChanged(...e){return e.some(t=>this.isControlChanged(t))}onCtxSizeInput(e){let t=e.target.value,n=Rs(t),a=Os(n,this.parallelSlots());this.form.get("ctxSize")?.setValue(a,{emitEvent:!1})}ngOnInit(){this.form.controls.command.valueChanges.pipe(qi(this.destroyRef)).subscribe(e=>this._commandValue.set(e)),this.data.config&&this.populateFormFromFlags(this.data.config.flags,this.data.config.environment),this.form.valueChanges.pipe(qi(this.destroyRef)).subscribe(()=>{this.cdr.markForCheck()})}populateFormFromFlags(e,t){let n=this.form.controls;n.host.setValue(Ke(e,"--host",f.host)),n.port.setValue(Ee(e,"--port",f.port)),n.threads.setValue(Ee(e,"--threads",f.threads)),n.flashAttn.setValue(Ke(e,"--flash-attn",f.flashAttn)),n.fit.setValue(Ke(e,"--fit",f.fit)),n.parallel.setValue(Ee(e,"--parallel",f.parallel)),n.alias.setValue(Ke(e,"--alias","")),n.nPredict.setValue(Ee(e,"--n-predict",f.nPredict)),n.contextShift.setValue(Wn(e,"--context-shift","--no-context-shift",!1)?"on":"off"),n.contBatching.setValue(Wn(e,"--cont-batching","--no-cont-batching",!0)?"on":"off");let a=wn(e,"--device");n.device.setValue(a?a.split(",").map(g=>g.trim()).filter(Boolean):[]),n.tensorSplit.setValue(Ke(e,"--tensor-split","")),n.model.setValue(Ke(e,"--model","")),n.mmproj.setValue(Ke(e,"--mmproj","")),n.nGpuLayers.setValue(Ke(e,"--n-gpu-layers",f.nGpuLayers)),n.splitMode.setValue(Ke(e,"--split-mode",f.splitMode)),n.mainGpu.setValue(Ee(e,"--main-gpu",f.mainGpu)),n.fitTarget.setValue(Ee(e,"--fit-target",f.fitTarget)),n.fitCtx.setValue(Ee(e,"--fit-ctx",f.fitCtx)),n.mlock.setValue(e.includes("--mlock")?"on":"off"),n.mmap.setValue(Wn(e,"--mmap","--no-mmap",!0)?"on":"off"),n.cpuMoe.setValue(e.includes("--cpu-moe")?"on":"off"),n.nCpuMoe.setValue(Ee(e,"--n-cpu-moe",0));let r=Ee(e,"--ctx-size",f.ctxSize),u=typeof n.parallel.value=="number"&&n.parallel.value>0?n.parallel.value:1;n.ctxSize.setValue(Os(r,u)),n.batchSize.setValue(Ee(e,"--batch-size",f.batchSize)),n.ubatchSize.setValue(Ee(e,"--ubatch-size",f.ubatchSize)),n.cacheTypeK.setValue(Ke(e,"--cache-type-k",f.cacheTypeK)),n.cacheTypeV.setValue(Ke(e,"--cache-type-v",f.cacheTypeV)),n.kvOffload.setValue(Wn(e,"--kv-offload","--no-kv-offload",!0)?"on":"off"),n.cacheRam.setValue(Ee(e,"--cache-ram",f.cacheRam)),n.swaFull.setValue(e.includes("--swa-full")?"on":"off"),n.ropeScaling.setValue(Ke(e,"--rope-scaling",f.ropeScaling)),n.ropeScale.setValue(ut(e,"--rope-scale",f.ropeScale)),n.ropeFreqBase.setValue(ut(e,"--rope-freq-base",f.ropeFreqBase)),n.ropeFreqScale.setValue(ut(e,"--rope-freq-scale",f.ropeFreqScale)),n.yarnOrigCtx.setValue(Ee(e,"--yarn-orig-ctx",f.yarnOrigCtx)),n.yarnExtFactor.setValue(ut(e,"--yarn-ext-factor",f.yarnExtFactor)),n.yarnAttnFactor.setValue(ut(e,"--yarn-attn-factor",f.yarnAttnFactor)),n.yarnBetaSlow.setValue(ut(e,"--yarn-beta-slow",f.yarnBetaSlow)),n.yarnBetaFast.setValue(ut(e,"--yarn-beta-fast",f.yarnBetaFast)),n.temperature.setValue(ut(e,"--temperature",f.temperature)),n.seed.setValue(Ee(e,"--seed",f.seed)),n.topK.setValue(Ee(e,"--top-k",f.topK)),n.topP.setValue(ut(e,"--top-p",f.topP)),n.minP.setValue(ut(e,"--min-p",f.minP)),n.typicalP.setValue(ut(e,"--typical",f.typicalP)),n.repeatLastN.setValue(Ee(e,"--repeat-last-n",f.repeatLastN)),n.repeatPenalty.setValue(ut(e,"--repeat-penalty",f.repeatPenalty)),n.presencePenalty.setValue(ut(e,"--presence-penalty",f.presencePenalty)),n.frequencyPenalty.setValue(ut(e,"--frequency-penalty",f.frequencyPenalty)),n.dryMultiplier.setValue(ut(e,"--dry-multiplier",f.dryMultiplier)),n.dryBase.setValue(ut(e,"--dry-base",f.dryBase)),n.mirostat.setValue(Ee(e,"--mirostat",f.mirostat)),n.dynatempRange.setValue(ut(e,"--dynatemp-range",f.dynatempRange)),n.modelDraft.setValue(Ke(e,"--model-draft",""));let h=wn(e,"--spec-draft-device")??wn(e,"--device-draft");if(n.specDraftDevice.setValue(h?h.split(",").map(g=>g.trim()).filter(Boolean):[]),n.specDraftNMax.setValue(Ee(e,"--spec-draft-n-max",f.specDraftNMax)),n.nGpuLayersDraft.setValue(Ke(e,"--n-gpu-layers-draft",f.nGpuLayersDraft)),n.specDraftCacheTypeK.setValue(Ke(e,"--cache-type-k-draft",f.specDraftCacheTypeK)),n.specDraftCacheTypeV.setValue(Ke(e,"--cache-type-v-draft",f.specDraftCacheTypeV)),n.specType.setValue(Ke(e,"--spec-type",f.specType)),n.specNgramModNMin.setValue(Ee(e,"--spec-ngram-mod-n-min",f.specNgramModNMin)),n.specNgramModNMax.setValue(Ee(e,"--spec-ngram-mod-n-max",f.specNgramModNMax)),n.specNgramModNMatch.setValue(Ee(e,"--spec-ngram-mod-n-match",f.specNgramModNMatch)),n.specNgramSimpleSizeN.setValue(Ee(e,"--spec-ngram-simple-size-n",f.specNgramSimpleSizeN)),n.specNgramSimpleSizeM.setValue(Ee(e,"--spec-ngram-simple-size-m",f.specNgramSimpleSizeM)),n.specNgramSimpleMinHits.setValue(Ee(e,"--spec-ngram-simple-min-hits",f.specNgramSimpleMinHits)),n.lora.setValue(Ke(e,"--lora","")),n.loraScaled.setValue(Ke(e,"--lora-scaled","")),n.timeout.setValue(Ee(e,"--timeout",f.timeout)),n.threadsHttp.setValue(Ee(e,"--threads-http",f.threadsHttp)),n.metrics.setValue(e.includes("--metrics")?"on":"off"),n.slots.setValue(Wn(e,"--slots","--no-slots",!0)?"on":"off"),n.cachePrompt.setValue(Wn(e,"--cache-prompt","--no-cache-prompt",!0)?"on":"off"),n.cacheReuse.setValue(Ee(e,"--cache-reuse",f.cacheReuse)),n.reasoning.setValue(Ke(e,"--reasoning",f.reasoning)),n.reasoningBudget.setValue(Ee(e,"--reasoning-budget",f.reasoningBudget)),n.reasoningFormat.setValue(Ke(e,"--reasoning-format",f.reasoningFormat)),n.apiKeyFile.setValue(Ke(e,"--api-key-file","")),n.extraFlags.setValue(this.extractExtraFlags(e).join(`
5583
+ `],encapsulation:2})}return i})();var Ps=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=j({type:i});static \u0275inj=z({imports:[ca,Nt,ee,_i]})}return i})();function wn(i,o){for(let e of i){let t=e.indexOf("=");if(t>0&&e.slice(0,t)===o)return e.slice(t+1);let n=e.indexOf(" ");if(n>0&&e.slice(0,n)===o)return e.slice(n+1).trim()}for(let e=0;e<i.length;e++)if(i[e]===o&&e+1<i.length)return i[e+1];return null}function Kn(i,o,e,t){for(let n of i){let a=n.split(/\s|=/)[0];if(a===o)return!0;if(a===e)return!1}return t}function Ke(i,o,e){let t=wn(i,o);return t!==null?t:e}function Ee(i,o,e){let t=wn(i,o);if(t!==null){let n=parseInt(t,10);return isNaN(n)?e:n}return e}function ut(i,o,e){let t=wn(i,o);if(t!==null){let n=parseFloat(t);return isNaN(n)?e:n}return e}var ey=(i,o)=>o.path;function ty(i,o){i&1&&(s(0,"span",7),m(1,"(dir)"),l())}function iy(i,o){if(i&1&&(s(0,"mat-option",5)(1,"span",6),m(2),l(),M(3,ty,2,0,"span",7),l()),i&2){let e=o.$implicit;C("value",e.path),c(2),q(e.path),c(),E(e.isDir?3:-1)}}var Dp=(()=>{class i{constructor(){this.fb=d(un),this.service=d(_t),this.label="Path",this.placeholder="/path/to/file",this.required=!1,this.fieldClass="",this.existingPaths=[],this.onChange=e=>{},this.onTouched=()=>{},this._subscription=null,this.suggestions=R([]),this.innerForm=this.fb.group({value:[""]})}writeValue(e){let t=(e??"").toString();this.innerForm.patchValue({value:t},{emitEvent:!1})}registerOnChange(e){this.onChange=e}registerOnTouched(e){this.onTouched=e}setDisabledState(e){e?this.innerForm.disable():this.innerForm.enable()}ngOnInit(){this._subscription=this.innerForm.get("value").valueChanges.subscribe(e=>{this.onChange(e)}),this._subscription.add(this.innerForm.get("value").valueChanges.pipe(Vt(200),xi(),We(e=>{let t=(e??"").trim();return t?this.service.getLlamaAutocomplete("path",t).pipe(Kt(()=>ge([]))):ge(this.emptySuggestions)})).subscribe(e=>{this.suggestions.set(e)}))}get emptySuggestions(){return this.existingPaths.filter(Boolean).map(e=>({path:e,source:"existing config"}))}ngOnDestroy(){this._subscription?.unsubscribe()}onSelect(e){this.innerForm.patchValue({value:e},{emitEvent:!1}),this.onChange(e)}onBlur(){this.onTouched()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-file-autocomplete"]],inputs:{label:"label",placeholder:"placeholder",required:"required",fieldClass:"fieldClass",existingPaths:"existingPaths"},features:[J([{provide:Mi,useExisting:nt(()=>i),multi:!0}])],decls:9,vars:7,consts:[["auto","matAutocomplete"],[3,"formGroup"],["appearance","outline",1,"full-width"],["matInput","","formControlName","value",3,"blur","placeholder","required","matAutocomplete"],[3,"optionSelected"],[3,"value"],[1,"file-path"],[1,"file-dir"]],template:function(t,n){if(t&1&&(ui(0,1),s(1,"mat-form-field",2)(2,"input",3),A("blur",function(){return n.onBlur()}),l(),b(),s(3,"mat-label"),m(4),l()(),s(5,"mat-autocomplete",4,0),A("optionSelected",function(r){return n.onSelect(r.option.value)}),me(7,iy,4,3,"mat-option",5,ey),l(),hi()),t&2){let a=Fe(6);C("formGroup",n.innerForm),c(),et(n.fieldClass),c(),C("placeholder",n.placeholder)("required",n.required)("matAutocomplete",a),y(),c(2),q(n.label),c(3),ue(n.suggestions())}},dependencies:[Ve,pn,Ei,Ai,mn,Zr,Ut,ji,St,kt,Ot,ti,ei,xn,Cn,vt,Wi],styles:[".full-width[_ngcontent-%COMP%]{width:100%}.file-path[_ngcontent-%COMP%]{font-family:monospace}.file-dir[_ngcontent-%COMP%]{margin-left:4px;color:#1976d2;font-size:11px;font-weight:500}.file-source[_ngcontent-%COMP%]{margin-left:8px;opacity:.6;font-size:12px}"]})}}return i})();function qi(i){i||(i=d(Bt));let o=new yt(e=>{if(i.destroyed){e.next();return}return i.onDestroy(e.next.bind(e))});return e=>e.pipe(oe(o))}function Yn(i,o){let t=!o?.manualCleanup?o?.injector?.get(Bt)??d(Bt):null,n=ny(o?.equal),a;o?.requireSync?a=R({kind:0},{equal:n}):a=R({kind:1,value:o?.initialValue},{equal:n});let r,u=i.subscribe({next:h=>a.set({kind:1,value:h}),error:h=>{a.set({kind:2,error:h}),r?.()},complete:()=>{r?.()}});if(o?.requireSync&&a().kind===0)throw new ae(601,!1);return r=t?.onDestroy(u.unsubscribe.bind(u)),$(()=>{let h=a();switch(h.kind){case 1:return h.value;case 2:throw h.error;case 0:throw new ae(601,!1)}},{equal:o?.equal})}function ny(i=Object.is){return(o,e)=>o.kind===1&&e.kind===1&&i(o.value,e.value)}function Dn(i){if(typeof i=="number")return i;let o=i.trim();if(!o)return 0;let e=o.split(/\s*x\s*/i),t=1,n;if(e.length>=2){let h=e[0].trim();h&&(t=parseInt(h,10),(isNaN(t)||t<1)&&(t=1)),n=e.slice(1).join("").trim()}else n=o;let a=n.match(/^(\d+)\s*([kKmM])?$/);if(!a)return 0;let r=parseInt(a[1],10),u=a[2];return u&&(u.toLowerCase()==="k"?r*=1024:u.toLowerCase()==="m"&&(r*=1024*1024)),t*r}var Ua=[8192,16384,32768,65536,98304,131072,196608,262144,524288,1048576];function kp(i){if(i<=0)return"0";if(i>=1048576){let o=i/1048576;return`${o%1===0?o:o.toFixed(1)}M`}if(i>=1024){let o=i/1024;return`${o%1===0?o:o.toFixed(1)}K`}return`${i}`}function kn(i,o){if(i<=0)return"";if(o>1&&i%o===0){let e=i/o;if(Ua.includes(e))return`${o} x ${kp(e)}`}return kp(i)}var oy=(i,o)=>o.command,Hc=(i,o)=>o.path,ay=(i,o)=>o.label;function ry(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function sy(i,o){i&1&&(s(0,"mat-error"),m(1,"Starts with letter, alphanumeric + hyphens/underscores, max 128 chars"),l())}function ly(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function cy(i,o){if(i&1&&(s(0,"mat-option",8)(1,"span",100),m(2),l(),s(3,"span",101),m(4),l()()),i&2){let e=o.$implicit;C("value",e.command),c(2),q(e.command),c(2),he("(",e.from,")")}}function dy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;C("value",e.path),c(),q(e.path)}}function my(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;C("value",e.label),c(),q(e.label)}}function uy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;C("value",e),c(),q(e)}}function hy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;C("value",e),c(),q(e)}}function py(i,o){if(i&1&&(s(0,"div",26),m(1,"YaRN Parameters"),l(),s(2,"div",13)(3,"mat-form-field",18),v(4,"input",102),b(),s(5,"mat-label"),m(6,"YaRN Orig Ctx"),l()(),s(7,"mat-form-field",18),v(8,"input",103),b(),s(9,"mat-label"),m(10,"Extrapolation Mix"),l()(),s(11,"mat-form-field",18),v(12,"input",104),b(),s(13,"mat-label"),m(14,"Attn Factor"),l()(),s(15,"mat-form-field",18),v(16,"input",105),b(),s(17,"mat-label"),m(18,"Beta Slow"),l()(),s(19,"mat-form-field",18),v(20,"input",106),b(),s(21,"mat-label"),m(22,"Beta Fast"),l()()()),i&2){let e=D();c(3),p("changed",e.isControlChanged("yarnOrigCtx")),c(),y(),c(3),p("changed",e.isControlChanged("yarnExtFactor")),c(),y(),c(3),p("changed",e.isControlChanged("yarnAttnFactor")),c(),y(),c(3),p("changed",e.isControlChanged("yarnBetaSlow")),c(),y(),c(3),p("changed",e.isControlChanged("yarnBetaFast")),c(),y()}}function fy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;C("value",e.path),c(),q(e.path)}}function gy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;C("value",e),c(),q(e)}}function _y(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;C("value",e),c(),q(e)}}function vy(i,o){if(i&1&&(s(0,"div",26),m(1,"Draft Model"),l(),v(2,"app-file-autocomplete",107),b(),s(3,"div",13)(4,"mat-form-field",18)(5,"mat-select",108),me(6,fy,2,2,"mat-option",8,Hc),l(),b(),s(8,"mat-label"),m(9,"Draft Device (multi-select)"),l()()(),s(10,"div",13)(11,"mat-form-field",18),v(12,"input",109),b(),s(13,"mat-label"),m(14,"Draft N Max"),l()(),s(15,"mat-form-field",18),v(16,"input",110),b(),s(17,"mat-label"),m(18,"Draft GPU Layers"),l()()(),s(19,"div",13)(20,"mat-form-field",18)(21,"mat-select",111),me(22,gy,2,2,"mat-option",8,xt),l(),b(),s(24,"mat-label"),m(25,"Draft Cache Type K"),l()(),s(26,"mat-form-field",18)(27,"mat-select",112),me(28,_y,2,2,"mat-option",8,xt),l(),b(),s(30,"mat-label"),m(31,"Draft Cache Type V"),l()()()),i&2){let e=D();c(2),C("existingPaths",e.existingDraftModelPaths())("fieldClass",e.isControlChanged("modelDraft")?"changed":""),y(),c(2),p("changed",e.isControlChanged("specDraftDevice")),c(),y(),c(),ue(e.availableDevices()),c(5),p("changed",e.isControlChanged("specDraftNMax")),c(),y(),c(3),p("changed",e.isControlChanged("nGpuLayersDraft")),c(),y(),c(4),p("changed",e.isControlChanged("specDraftCacheTypeK")),c(),y(),c(),ue(e.kvCacheTypes),c(4),p("changed",e.isControlChanged("specDraftCacheTypeV")),c(),y(),c(),ue(e.kvCacheTypes)}}function by(i,o){if(i&1&&(s(0,"div",26),m(1,"Ngram Mod Parameters"),l(),s(2,"div",13)(3,"mat-form-field",18),v(4,"input",113),b(),s(5,"mat-label"),m(6,"Ngram Mod N Min"),l()(),s(7,"mat-form-field",18),v(8,"input",114),b(),s(9,"mat-label"),m(10,"Ngram Mod N Max"),l()(),s(11,"mat-form-field",18),v(12,"input",115),b(),s(13,"mat-label"),m(14,"Ngram Mod Match"),l()()()),i&2){let e=D();c(3),p("changed",e.isControlChanged("specNgramModNMin")),c(),y(),c(3),p("changed",e.isControlChanged("specNgramModNMax")),c(),y(),c(3),p("changed",e.isControlChanged("specNgramModNMatch")),c(),y()}}function yy(i,o){if(i&1&&(s(0,"div",26),m(1,"Ngram Simple Parameters"),l(),s(2,"div",13)(3,"mat-form-field",18),v(4,"input",116),b(),s(5,"mat-label"),m(6,"Simple Size N"),l()(),s(7,"mat-form-field",18),v(8,"input",117),b(),s(9,"mat-label"),m(10,"Simple Size M"),l()(),s(11,"mat-form-field",18),v(12,"input",118),b(),s(13,"mat-label"),m(14,"Simple Min Hits"),l()()()),i&2){let e=D();c(3),p("changed",e.isControlChanged("specNgramSimpleSizeN")),c(),y(),c(3),p("changed",e.isControlChanged("specNgramSimpleSizeM")),c(),y(),c(3),p("changed",e.isControlChanged("specNgramSimpleMinHits")),c(),y()}}function Cy(i,o){if(i&1&&(s(0,"mat-option",8)(1,"span",100),m(2),l(),s(3,"span",101),m(4),l()()),i&2){let e=o.$implicit;C("value",e.path),c(2),q(e.path),c(2),he("(",e.source,")")}}var f={host:"127.0.0.1",port:8080,threads:-1,flashAttn:"auto",fit:"on",parallel:-1,alias:"",nPredict:-1,contextShift:"off",contBatching:"on",model:"",mmproj:"",nGpuLayers:"auto",device:[],tensorSplit:"",splitMode:"layer",mainGpu:0,fitTarget:1024,fitCtx:4096,mlock:"off",mmap:"on",cpuMoe:"off",nCpuMoe:0,ctxSize:0,batchSize:2048,ubatchSize:512,cacheTypeK:"f16",cacheTypeV:"f16",kvOffload:"on",cacheRam:8192,swaFull:"off",ropeScaling:"none",ropeScale:1,ropeFreqBase:0,ropeFreqScale:0,yarnOrigCtx:0,yarnExtFactor:-1,yarnAttnFactor:-1,yarnBetaSlow:-1,yarnBetaFast:-1,temperature:.8,seed:-1,topK:40,topP:.95,minP:.05,typicalP:1,repeatLastN:64,repeatPenalty:1,presencePenalty:0,frequencyPenalty:0,dryMultiplier:0,dryBase:1.75,mirostat:0,dynatempRange:0,modelDraft:"",specDraftDevice:[],specDraftNMax:3,nGpuLayersDraft:"auto",specDraftCacheTypeK:"f16",specDraftCacheTypeV:"f16",specType:"none",specNgramModNMin:48,specNgramModNMax:64,specNgramModNMatch:24,specNgramSimpleSizeN:12,specNgramSimpleSizeM:48,specNgramSimpleMinHits:1,lora:"",loraScaled:"",timeout:3600,threadsHttp:-1,metrics:"off",slots:"on",cachePrompt:"on",cacheReuse:0,reasoning:"auto",reasoningBudget:-1,reasoningFormat:"auto",apiKeyFile:""};function xy(i,o){let e=f[i];if(e===void 0)return!1;if(Array.isArray(o)||Array.isArray(e)){let t=Array.isArray(o)?o:[],n=Array.isArray(e)?e:[];return t.length!==n.length||t.some((a,r)=>a!==n[r])}return String(o)!==String(e)}var wy="^[a-zA-Z][a-zA-Z0-9_-]{0,127}$",Dy=["f32","f16","bf16","q8_0","q4_0","q4_1","iq4_nl","q5_0","q5_1"],ky=new Set(["--host","--port","--threads","--flash-attn","--fit","--parallel","--alias","--n-predict","--context-shift","--no-context-shift","--cont-batching","--no-cont-batching","--device","--tensor-split","--model","--mmproj","--n-gpu-layers","--split-mode","--main-gpu","--fit-target","--fit-ctx","--mlock","--mmap","--no-mmap","--cpu-moe","--n-cpu-moe","--ctx-size","--batch-size","--ubatch-size","--cache-type-k","--cache-type-v","--kv-offload","--no-kv-offload","--cache-ram","--swa-full","--rope-scaling","--rope-scale","--rope-freq-base","--rope-freq-scale","--yarn-orig-ctx","--yarn-ext-factor","--yarn-attn-factor","--yarn-beta-slow","--yarn-beta-fast","--temperature","--seed","--top-k","--top-p","--min-p","--typical","--repeat-last-n","--repeat-penalty","--presence-penalty","--frequency-penalty","--dry-multiplier","--dry-base","--mirostat","--dynatemp-range","--spec-type","--spec-draft-n-max","--model-draft","--spec-draft-device","--device-draft","--n-gpu-layers-draft","--cache-type-k-draft","--cache-type-v-draft","--spec-ngram-mod-n-min","--spec-ngram-mod-n-max","--spec-ngram-mod-n-match","--spec-ngram-simple-size-n","--spec-ngram-simple-size-m","--spec-ngram-simple-min-hits","--lora","--lora-scaled","--timeout","--threads-http","--metrics","--slots","--no-slots","--cache-prompt","--no-cache-prompt","--cache-reuse","--reasoning","--reasoning-budget","--reasoning-format","--api-key-file"]),Sp=(()=>{class i{constructor(){this.fb=d(un),this.dialogRef=d(gt),this.data=d(Wn),this.serviceService=d(_t),this.cdr=d(te),this.destroyRef=d(Bt),this.isEdit=this.data.config!==null,this.isClone=this.data.clone===!0,this.kvCacheTypes=Dy,this.allExistingCommands=$(()=>{let e=this.data.allConfigs??[],t=this.data.config?.name??null,n=new Set,a=[];for(let r of e)r.name!==t&&(n.has(r.command)||(n.add(r.command),a.push({command:r.command,from:r.name})));return a}),this._commandValue=R(this.data.config?.command??""),this.commandValue=this._commandValue.asReadonly(),this.filteredCommands=$(()=>{let e=this.commandValue()?.toLowerCase()??"";return this.allExistingCommands().filter(t=>t.command.toLowerCase().includes(e)||t.from.toLowerCase().includes(e))}),this.form=this.fb.group({name:[this.data.config?.name??"",{validators:[st.required,st.pattern(wy)]}],command:[this.data.config?.command??"",st.required],host:[f.host],port:[f.port],threads:[f.threads],flashAttn:[f.flashAttn],fit:[f.fit],parallel:[f.parallel],alias:[f.alias],nPredict:[f.nPredict],contextShift:[f.contextShift],contBatching:[f.contBatching],model:[""],mmproj:[""],nGpuLayers:[f.nGpuLayers],device:[[]],tensorSplit:[""],splitMode:[f.splitMode],mainGpu:[f.mainGpu],fitTarget:[f.fitTarget],fitCtx:[f.fitCtx],mlock:[f.mlock],mmap:[f.mmap],cpuMoe:[f.cpuMoe],nCpuMoe:[f.nCpuMoe],ctxSize:[""],batchSize:[f.batchSize],ubatchSize:[f.ubatchSize],cacheTypeK:[f.cacheTypeK],cacheTypeV:[f.cacheTypeV],kvOffload:[f.kvOffload],cacheRam:[f.cacheRam],swaFull:[f.swaFull],ropeScaling:[f.ropeScaling],ropeScale:[f.ropeScale],ropeFreqBase:[f.ropeFreqBase],ropeFreqScale:[f.ropeFreqScale],yarnOrigCtx:[f.yarnOrigCtx],yarnExtFactor:[f.yarnExtFactor],yarnAttnFactor:[f.yarnAttnFactor],yarnBetaSlow:[f.yarnBetaSlow],yarnBetaFast:[f.yarnBetaFast],temperature:[f.temperature],seed:[f.seed],topK:[f.topK],topP:[f.topP],minP:[f.minP],typicalP:[f.typicalP],repeatLastN:[f.repeatLastN],repeatPenalty:[f.repeatPenalty],presencePenalty:[f.presencePenalty],frequencyPenalty:[f.frequencyPenalty],dryMultiplier:[f.dryMultiplier],dryBase:[f.dryBase],mirostat:[f.mirostat],dynatempRange:[f.dynatempRange],modelDraft:[""],specDraftDevice:[[]],specDraftNMax:[f.specDraftNMax],nGpuLayersDraft:[f.nGpuLayersDraft],specDraftCacheTypeK:[f.specDraftCacheTypeK],specDraftCacheTypeV:[f.specDraftCacheTypeV],specType:[f.specType],specNgramModNMin:[f.specNgramModNMin],specNgramModNMax:[f.specNgramModNMax],specNgramModNMatch:[f.specNgramModNMatch],specNgramSimpleSizeN:[f.specNgramSimpleSizeN],specNgramSimpleSizeM:[f.specNgramSimpleSizeM],specNgramSimpleMinHits:[f.specNgramSimpleMinHits],lora:[""],loraScaled:[""],timeout:[f.timeout],threadsHttp:[f.threadsHttp],metrics:[f.metrics],slots:[f.slots],cachePrompt:[f.cachePrompt],cacheReuse:[f.cacheReuse],reasoning:[f.reasoning],reasoningBudget:[f.reasoningBudget],reasoningFormat:[f.reasoningFormat],apiKeyFile:[""],extraFlags:[""],envText:[""]}),this.availableDevices=$(()=>this.availableDevicesRaw()),this.availableDevicesRaw=Yn(this.form.controls.command.valueChanges.pipe(qi(),ke(this.form.controls.command.value),Vt(300),xi(),We(e=>{let t=(e??"").trim();return t?this.serviceService.getLlamaAutocomplete("device","",t).pipe(Kt(()=>ge([]))):this.serviceService.getLlamaAutocomplete("device","").pipe(Kt(()=>ge([])))})),{initialValue:[]}),this.filteredHosts=Yn(this.form.controls.host.valueChanges.pipe(qi(),ke(this.form.controls.host.value),Vt(250),xi(),We(e=>{let t=(e??"").trim();return t?this.serviceService.getLlamaAutocomplete("host",t).pipe(Kt(()=>ge([]))):ge([])})),{initialValue:[]}),this.existingModelPaths=$(()=>this.extractConfigPaths("--model")),this.existingMmprojPaths=$(()=>this.extractConfigPaths("--mmproj")),this.existingApiKeyPaths=$(()=>this.extractConfigPaths("--api-key-file")),this.existingDraftModelPaths=$(()=>this.extractConfigPaths("--model-draft")),this.existingLoraPaths=$(()=>this.extractConfigPaths("--lora")),this.formValue=Yn(this.form.valueChanges,{initialValue:this.form.value}),this.fitValue=$(()=>this.formValue()?.fit),this.splitModeValue=$(()=>this.formValue()?.splitMode),this.specTypeValue=$(()=>this.formValue()?.specType),this.ropeScalingValue=$(()=>this.formValue()?.ropeScaling),this.cpuMoeValue=$(()=>this.formValue()?.cpuMoe),this.cachePromptValue=$(()=>this.formValue()?.cachePrompt),this.reasoningValue=$(()=>this.formValue()?.reasoning),this.mirostatValue=$(()=>this.formValue()?.mirostat),this.hostValue=$(()=>this.formValue()?.host),this.isTensorSplitDisabled=$(()=>this.splitModeValue()==="none"),this.isFitTargetDisabled=$(()=>this.fitValue()==="off"),this.isCpuMoeLayersDisabled=$(()=>this.cpuMoeValue()==="on"),this.isCacheReuseDisabled=$(()=>this.cachePromptValue()==="off"),this.isReasoningParamsDisabled=$(()=>this.reasoningValue()==="off"),this.isMirostatEnabled=$(()=>(this.mirostatValue()??0)!==0),this.isRopeParamsDisabled=$(()=>this.ropeScalingValue()==="none"),this.isPortDisabled=$(()=>(this.hostValue()??"").trim().toLowerCase().endsWith(".sock")),this.showDraftParams=$(()=>(this.specTypeValue()??"").includes("draft")),this.showNgramModParams=$(()=>(this.specTypeValue()??"").includes("ngram-mod")),this.showNgramSimpleParams=$(()=>(this.specTypeValue()??"").includes("ngram-simple")),this.showYarnParams=$(()=>this.ropeScalingValue()==="yarn"),this.parallelSlots=$(()=>{let e=this.formValue()?.parallel;return typeof e=="number"&&e>0?e:1}),this.ctxPresets=$(()=>{let e=this.parallelSlots();return Ua.map(t=>({label:kn(e*t,e)}))}),this._flags=null}extractConfigPaths(e){let t=this.data.allConfigs??[],n=this.data.config?.name??null,a=new Set,r=[];for(let u of t){if(u.name===n||!u.flags)continue;let h=wn(u.flags,e);h&&!a.has(h)&&(a.add(h),r.push(h))}return r}isControlChanged(e){let t=this.form.get(e)?.value;return e==="ctxSize"?+Dn(t)!==f.ctxSize:t!==void 0&&xy(e,t)}isSectionChanged(...e){return e.some(t=>this.isControlChanged(t))}onCtxSizeInput(e){let t=e.target.value,n=Dn(t),a=kn(n,this.parallelSlots());this.form.get("ctxSize")?.setValue(a,{emitEvent:!1})}ngOnInit(){this.form.controls.command.valueChanges.pipe(qi(this.destroyRef)).subscribe(e=>this._commandValue.set(e)),this.data.config&&this.populateFormFromFlags(this.data.config.flags,this.data.config.environment),this.form.valueChanges.pipe(qi(this.destroyRef)).subscribe(()=>{this.cdr.markForCheck()})}populateFormFromFlags(e,t){let n=this.form.controls;n.host.setValue(Ke(e,"--host",f.host)),n.port.setValue(Ee(e,"--port",f.port)),n.threads.setValue(Ee(e,"--threads",f.threads)),n.flashAttn.setValue(Ke(e,"--flash-attn",f.flashAttn)),n.fit.setValue(Ke(e,"--fit",f.fit)),n.parallel.setValue(Ee(e,"--parallel",f.parallel)),n.alias.setValue(Ke(e,"--alias","")),n.nPredict.setValue(Ee(e,"--n-predict",f.nPredict)),n.contextShift.setValue(Kn(e,"--context-shift","--no-context-shift",!1)?"on":"off"),n.contBatching.setValue(Kn(e,"--cont-batching","--no-cont-batching",!0)?"on":"off");let a=wn(e,"--device");n.device.setValue(a?a.split(",").map(g=>g.trim()).filter(Boolean):[]),n.tensorSplit.setValue(Ke(e,"--tensor-split","")),n.model.setValue(Ke(e,"--model","")),n.mmproj.setValue(Ke(e,"--mmproj","")),n.nGpuLayers.setValue(Ke(e,"--n-gpu-layers",f.nGpuLayers)),n.splitMode.setValue(Ke(e,"--split-mode",f.splitMode)),n.mainGpu.setValue(Ee(e,"--main-gpu",f.mainGpu)),n.fitTarget.setValue(Ee(e,"--fit-target",f.fitTarget)),n.fitCtx.setValue(Ee(e,"--fit-ctx",f.fitCtx)),n.mlock.setValue(e.includes("--mlock")?"on":"off"),n.mmap.setValue(Kn(e,"--mmap","--no-mmap",!0)?"on":"off"),n.cpuMoe.setValue(e.includes("--cpu-moe")?"on":"off"),n.nCpuMoe.setValue(Ee(e,"--n-cpu-moe",0));let r=Ee(e,"--ctx-size",f.ctxSize),u=typeof n.parallel.value=="number"&&n.parallel.value>0?n.parallel.value:1;n.ctxSize.setValue(kn(r,u)),n.batchSize.setValue(Ee(e,"--batch-size",f.batchSize)),n.ubatchSize.setValue(Ee(e,"--ubatch-size",f.ubatchSize)),n.cacheTypeK.setValue(Ke(e,"--cache-type-k",f.cacheTypeK)),n.cacheTypeV.setValue(Ke(e,"--cache-type-v",f.cacheTypeV)),n.kvOffload.setValue(Kn(e,"--kv-offload","--no-kv-offload",!0)?"on":"off"),n.cacheRam.setValue(Ee(e,"--cache-ram",f.cacheRam)),n.swaFull.setValue(e.includes("--swa-full")?"on":"off"),n.ropeScaling.setValue(Ke(e,"--rope-scaling",f.ropeScaling)),n.ropeScale.setValue(ut(e,"--rope-scale",f.ropeScale)),n.ropeFreqBase.setValue(ut(e,"--rope-freq-base",f.ropeFreqBase)),n.ropeFreqScale.setValue(ut(e,"--rope-freq-scale",f.ropeFreqScale)),n.yarnOrigCtx.setValue(Ee(e,"--yarn-orig-ctx",f.yarnOrigCtx)),n.yarnExtFactor.setValue(ut(e,"--yarn-ext-factor",f.yarnExtFactor)),n.yarnAttnFactor.setValue(ut(e,"--yarn-attn-factor",f.yarnAttnFactor)),n.yarnBetaSlow.setValue(ut(e,"--yarn-beta-slow",f.yarnBetaSlow)),n.yarnBetaFast.setValue(ut(e,"--yarn-beta-fast",f.yarnBetaFast)),n.temperature.setValue(ut(e,"--temperature",f.temperature)),n.seed.setValue(Ee(e,"--seed",f.seed)),n.topK.setValue(Ee(e,"--top-k",f.topK)),n.topP.setValue(ut(e,"--top-p",f.topP)),n.minP.setValue(ut(e,"--min-p",f.minP)),n.typicalP.setValue(ut(e,"--typical",f.typicalP)),n.repeatLastN.setValue(Ee(e,"--repeat-last-n",f.repeatLastN)),n.repeatPenalty.setValue(ut(e,"--repeat-penalty",f.repeatPenalty)),n.presencePenalty.setValue(ut(e,"--presence-penalty",f.presencePenalty)),n.frequencyPenalty.setValue(ut(e,"--frequency-penalty",f.frequencyPenalty)),n.dryMultiplier.setValue(ut(e,"--dry-multiplier",f.dryMultiplier)),n.dryBase.setValue(ut(e,"--dry-base",f.dryBase)),n.mirostat.setValue(Ee(e,"--mirostat",f.mirostat)),n.dynatempRange.setValue(ut(e,"--dynatemp-range",f.dynatempRange)),n.modelDraft.setValue(Ke(e,"--model-draft",""));let h=wn(e,"--spec-draft-device")??wn(e,"--device-draft");if(n.specDraftDevice.setValue(h?h.split(",").map(g=>g.trim()).filter(Boolean):[]),n.specDraftNMax.setValue(Ee(e,"--spec-draft-n-max",f.specDraftNMax)),n.nGpuLayersDraft.setValue(Ke(e,"--n-gpu-layers-draft",f.nGpuLayersDraft)),n.specDraftCacheTypeK.setValue(Ke(e,"--cache-type-k-draft",f.specDraftCacheTypeK)),n.specDraftCacheTypeV.setValue(Ke(e,"--cache-type-v-draft",f.specDraftCacheTypeV)),n.specType.setValue(Ke(e,"--spec-type",f.specType)),n.specNgramModNMin.setValue(Ee(e,"--spec-ngram-mod-n-min",f.specNgramModNMin)),n.specNgramModNMax.setValue(Ee(e,"--spec-ngram-mod-n-max",f.specNgramModNMax)),n.specNgramModNMatch.setValue(Ee(e,"--spec-ngram-mod-n-match",f.specNgramModNMatch)),n.specNgramSimpleSizeN.setValue(Ee(e,"--spec-ngram-simple-size-n",f.specNgramSimpleSizeN)),n.specNgramSimpleSizeM.setValue(Ee(e,"--spec-ngram-simple-size-m",f.specNgramSimpleSizeM)),n.specNgramSimpleMinHits.setValue(Ee(e,"--spec-ngram-simple-min-hits",f.specNgramSimpleMinHits)),n.lora.setValue(Ke(e,"--lora","")),n.loraScaled.setValue(Ke(e,"--lora-scaled","")),n.timeout.setValue(Ee(e,"--timeout",f.timeout)),n.threadsHttp.setValue(Ee(e,"--threads-http",f.threadsHttp)),n.metrics.setValue(e.includes("--metrics")?"on":"off"),n.slots.setValue(Kn(e,"--slots","--no-slots",!0)?"on":"off"),n.cachePrompt.setValue(Kn(e,"--cache-prompt","--no-cache-prompt",!0)?"on":"off"),n.cacheReuse.setValue(Ee(e,"--cache-reuse",f.cacheReuse)),n.reasoning.setValue(Ke(e,"--reasoning",f.reasoning)),n.reasoningBudget.setValue(Ee(e,"--reasoning-budget",f.reasoningBudget)),n.reasoningFormat.setValue(Ke(e,"--reasoning-format",f.reasoningFormat)),n.apiKeyFile.setValue(Ke(e,"--api-key-file","")),n.extraFlags.setValue(this.extractExtraFlags(e).join(`
5584
5584
  `)),t){let g=Object.entries(t).map(([_,w])=>`${_}=${w}`).join(`
5585
5585
  `);g&&n.envText.setValue(g+`
5586
5586
  `)}}extractExtraFlags(e){let t=[];for(let n of e){let a=n.split(/\s|=/)[0];n.startsWith("--")&&!ky.has(a)&&t.push(n)}return t}parseEnvironment(){let e={};for(let t of this.form.controls.envText.value.split(`
5587
- `)){let n=t.trim();if(!n||n.startsWith("#"))continue;let a=n.indexOf("=");a<=0||(e[n.slice(0,a).trim()]=n.slice(a+1))}return e}addIf(e,t,n){String(t)!==String(n)&&this._flags.push(`${e} ${t}`)}addToggle(e,t,n,a){let r=e==="on";r!==a&&this._flags.push(r?t:n)}buildFlags(){this._flags=[];let e=this.form.controls;this.addIf("--host",e.host.value,f.host),this.addIf("--port",e.port.value,f.port),this.addIf("--threads",e.threads.value,f.threads),this.addIf("--flash-attn",e.flashAttn.value,f.flashAttn),this.addIf("--fit",e.fit.value,f.fit),this.addIf("--parallel",e.parallel.value,f.parallel),this.addIf("--alias",e.alias.value,f.alias),this.addIf("--n-predict",e.nPredict.value,f.nPredict),this.addToggle(e.contextShift.value,"--context-shift","--no-context-shift",!1),this.addToggle(e.contBatching.value,"--cont-batching","--no-cont-batching",!0);let t=e.device.value;t&&t.length>0&&this._flags.push(`--device ${t.join(",")}`),e.splitMode.value!=="none"&&this.addIf("--tensor-split",e.tensorSplit.value,f.tensorSplit),this.addIf("--model",e.model.value,f.model),this.addIf("--mmproj",e.mmproj.value,f.mmproj),this.addIf("--n-gpu-layers",e.nGpuLayers.value,f.nGpuLayers),this.addIf("--split-mode",e.splitMode.value,f.splitMode),this.addIf("--main-gpu",e.mainGpu.value,f.mainGpu),e.fit.value==="on"&&(this.addIf("--fit-target",e.fitTarget.value,f.fitTarget),this.addIf("--fit-ctx",e.fitCtx.value,f.fitCtx)),e.mlock.value==="on"&&this._flags.push("--mlock"),this.addToggle(e.mmap.value,"--mmap","--no-mmap",!0),e.cpuMoe.value==="on"&&this._flags.push("--cpu-moe"),e.cpuMoe.value!=="on"&&this.addIf("--n-cpu-moe",e.nCpuMoe.value,f.nCpuMoe),this.addIf("--ctx-size",+Rs(e.ctxSize.value??""),f.ctxSize),this.addIf("--batch-size",e.batchSize.value,f.batchSize),this.addIf("--ubatch-size",e.ubatchSize.value,f.ubatchSize),this.addIf("--cache-type-k",e.cacheTypeK.value,f.cacheTypeK),this.addIf("--cache-type-v",e.cacheTypeV.value,f.cacheTypeV),this.addToggle(e.kvOffload.value,"--kv-offload","--no-kv-offload",!0),this.addIf("--cache-ram",e.cacheRam.value,f.cacheRam),e.swaFull.value==="on"&&this._flags.push("--swa-full");let n=e.ropeScaling.value;n&&n!==f.ropeScaling&&(this._flags.push(`--rope-scaling ${n}`),this.addIf("--rope-scale",e.ropeScale.value,f.ropeScale),this.addIf("--rope-freq-base",e.ropeFreqBase.value,f.ropeFreqBase),this.addIf("--rope-freq-scale",e.ropeFreqScale.value,f.ropeFreqScale),n==="yarn"&&(this.addIf("--yarn-orig-ctx",e.yarnOrigCtx.value,f.yarnOrigCtx),this.addIf("--yarn-ext-factor",e.yarnExtFactor.value,f.yarnExtFactor),this.addIf("--yarn-attn-factor",e.yarnAttnFactor.value,f.yarnAttnFactor),this.addIf("--yarn-beta-slow",e.yarnBetaSlow.value,f.yarnBetaSlow),this.addIf("--yarn-beta-fast",e.yarnBetaFast.value,f.yarnBetaFast))),this.addIf("--temperature",e.temperature.value,f.temperature),this.addIf("--seed",e.seed.value,f.seed),this.addIf("--top-k",e.topK.value,f.topK),this.addIf("--top-p",e.topP.value,f.topP),this.addIf("--min-p",e.minP.value,f.minP),this.addIf("--typical",e.typicalP.value,f.typicalP),this.addIf("--repeat-last-n",e.repeatLastN.value,f.repeatLastN),this.addIf("--repeat-penalty",e.repeatPenalty.value,f.repeatPenalty),this.addIf("--presence-penalty",e.presencePenalty.value,f.presencePenalty),this.addIf("--frequency-penalty",e.frequencyPenalty.value,f.frequencyPenalty),this.addIf("--dry-multiplier",e.dryMultiplier.value,f.dryMultiplier),this.addIf("--dry-base",e.dryBase.value,f.dryBase),this.addIf("--mirostat",e.mirostat.value,f.mirostat),this.addIf("--dynatemp-range",e.dynatempRange.value,f.dynatempRange);let a=e.specType.value;if(this.addIf("--spec-type",a,f.specType),a?.includes("draft")){this.addIf("--spec-draft-n-max",e.specDraftNMax.value,f.specDraftNMax),this.addIf("--model-draft",e.modelDraft.value,f.modelDraft);let u=e.specDraftDevice.value;u&&u.length>0&&this._flags.push(`--spec-draft-device ${u.join(",")}`),this.addIf("--n-gpu-layers-draft",e.nGpuLayersDraft.value,f.nGpuLayersDraft),this.addIf("--cache-type-k-draft",e.specDraftCacheTypeK.value,f.specDraftCacheTypeK),this.addIf("--cache-type-v-draft",e.specDraftCacheTypeV.value,f.specDraftCacheTypeV)}a?.includes("ngram")&&(this.addIf("--spec-ngram-mod-n-min",e.specNgramModNMin.value,f.specNgramModNMin),this.addIf("--spec-ngram-mod-n-max",e.specNgramModNMax.value,f.specNgramModNMax),this.addIf("--spec-ngram-mod-n-match",e.specNgramModNMatch.value,f.specNgramModNMatch),this.addIf("--spec-ngram-simple-size-n",e.specNgramSimpleSizeN.value,f.specNgramSimpleSizeN),this.addIf("--spec-ngram-simple-size-m",e.specNgramSimpleSizeM.value,f.specNgramSimpleSizeM),this.addIf("--spec-ngram-simple-min-hits",e.specNgramSimpleMinHits.value,f.specNgramSimpleMinHits)),this.addIf("--lora",e.lora.value,f.lora),this.addIf("--lora-scaled",e.loraScaled.value,f.loraScaled),this.addIf("--timeout",e.timeout.value,f.timeout),this.addIf("--threads-http",e.threadsHttp.value,f.threadsHttp),e.metrics.value==="on"&&this._flags.push("--metrics"),this.addToggle(e.slots.value,"--slots","--no-slots",!0),this.addToggle(e.cachePrompt.value,"--cache-prompt","--no-cache-prompt",!0),e.cachePrompt.value==="on"&&this.addIf("--cache-reuse",e.cacheReuse.value,f.cacheReuse),this.addIf("--reasoning",e.reasoning.value,f.reasoning),this.addIf("--reasoning-budget",e.reasoningBudget.value,f.reasoningBudget),this.addIf("--reasoning-format",e.reasoningFormat.value,f.reasoningFormat),this.addIf("--api-key-file",e.apiKeyFile.value,f.apiKeyFile);for(let u of e.extraFlags.value.split(`
5587
+ `)){let n=t.trim();if(!n||n.startsWith("#"))continue;let a=n.indexOf("=");a<=0||(e[n.slice(0,a).trim()]=n.slice(a+1))}return e}addIf(e,t,n){String(t)!==String(n)&&this._flags.push(`${e} ${t}`)}addToggle(e,t,n,a){let r=e==="on";r!==a&&this._flags.push(r?t:n)}buildFlags(){this._flags=[];let e=this.form.controls;this.addIf("--host",e.host.value,f.host),this.addIf("--port",e.port.value,f.port),this.addIf("--threads",e.threads.value,f.threads),this.addIf("--flash-attn",e.flashAttn.value,f.flashAttn),this.addIf("--fit",e.fit.value,f.fit),this.addIf("--parallel",e.parallel.value,f.parallel),this.addIf("--alias",e.alias.value,f.alias),this.addIf("--n-predict",e.nPredict.value,f.nPredict),this.addToggle(e.contextShift.value,"--context-shift","--no-context-shift",!1),this.addToggle(e.contBatching.value,"--cont-batching","--no-cont-batching",!0);let t=e.device.value;t&&t.length>0&&this._flags.push(`--device ${t.join(",")}`),e.splitMode.value!=="none"&&this.addIf("--tensor-split",e.tensorSplit.value,f.tensorSplit),this.addIf("--model",e.model.value,f.model),this.addIf("--mmproj",e.mmproj.value,f.mmproj),this.addIf("--n-gpu-layers",e.nGpuLayers.value,f.nGpuLayers),this.addIf("--split-mode",e.splitMode.value,f.splitMode),this.addIf("--main-gpu",e.mainGpu.value,f.mainGpu),e.fit.value==="on"&&(this.addIf("--fit-target",e.fitTarget.value,f.fitTarget),this.addIf("--fit-ctx",e.fitCtx.value,f.fitCtx)),e.mlock.value==="on"&&this._flags.push("--mlock"),this.addToggle(e.mmap.value,"--mmap","--no-mmap",!0),e.cpuMoe.value==="on"&&this._flags.push("--cpu-moe"),e.cpuMoe.value!=="on"&&this.addIf("--n-cpu-moe",e.nCpuMoe.value,f.nCpuMoe),this.addIf("--ctx-size",+Dn(e.ctxSize.value??""),f.ctxSize),this.addIf("--batch-size",e.batchSize.value,f.batchSize),this.addIf("--ubatch-size",e.ubatchSize.value,f.ubatchSize),this.addIf("--cache-type-k",e.cacheTypeK.value,f.cacheTypeK),this.addIf("--cache-type-v",e.cacheTypeV.value,f.cacheTypeV),this.addToggle(e.kvOffload.value,"--kv-offload","--no-kv-offload",!0),this.addIf("--cache-ram",e.cacheRam.value,f.cacheRam),e.swaFull.value==="on"&&this._flags.push("--swa-full");let n=e.ropeScaling.value;n&&n!==f.ropeScaling&&(this._flags.push(`--rope-scaling ${n}`),this.addIf("--rope-scale",e.ropeScale.value,f.ropeScale),this.addIf("--rope-freq-base",e.ropeFreqBase.value,f.ropeFreqBase),this.addIf("--rope-freq-scale",e.ropeFreqScale.value,f.ropeFreqScale),n==="yarn"&&(this.addIf("--yarn-orig-ctx",e.yarnOrigCtx.value,f.yarnOrigCtx),this.addIf("--yarn-ext-factor",e.yarnExtFactor.value,f.yarnExtFactor),this.addIf("--yarn-attn-factor",e.yarnAttnFactor.value,f.yarnAttnFactor),this.addIf("--yarn-beta-slow",e.yarnBetaSlow.value,f.yarnBetaSlow),this.addIf("--yarn-beta-fast",e.yarnBetaFast.value,f.yarnBetaFast))),this.addIf("--temperature",e.temperature.value,f.temperature),this.addIf("--seed",e.seed.value,f.seed),this.addIf("--top-k",e.topK.value,f.topK),this.addIf("--top-p",e.topP.value,f.topP),this.addIf("--min-p",e.minP.value,f.minP),this.addIf("--typical",e.typicalP.value,f.typicalP),this.addIf("--repeat-last-n",e.repeatLastN.value,f.repeatLastN),this.addIf("--repeat-penalty",e.repeatPenalty.value,f.repeatPenalty),this.addIf("--presence-penalty",e.presencePenalty.value,f.presencePenalty),this.addIf("--frequency-penalty",e.frequencyPenalty.value,f.frequencyPenalty),this.addIf("--dry-multiplier",e.dryMultiplier.value,f.dryMultiplier),this.addIf("--dry-base",e.dryBase.value,f.dryBase),this.addIf("--mirostat",e.mirostat.value,f.mirostat),this.addIf("--dynatemp-range",e.dynatempRange.value,f.dynatempRange);let a=e.specType.value;if(this.addIf("--spec-type",a,f.specType),a?.includes("draft")){this.addIf("--spec-draft-n-max",e.specDraftNMax.value,f.specDraftNMax),this.addIf("--model-draft",e.modelDraft.value,f.modelDraft);let u=e.specDraftDevice.value;u&&u.length>0&&this._flags.push(`--spec-draft-device ${u.join(",")}`),this.addIf("--n-gpu-layers-draft",e.nGpuLayersDraft.value,f.nGpuLayersDraft),this.addIf("--cache-type-k-draft",e.specDraftCacheTypeK.value,f.specDraftCacheTypeK),this.addIf("--cache-type-v-draft",e.specDraftCacheTypeV.value,f.specDraftCacheTypeV)}a?.includes("ngram")&&(this.addIf("--spec-ngram-mod-n-min",e.specNgramModNMin.value,f.specNgramModNMin),this.addIf("--spec-ngram-mod-n-max",e.specNgramModNMax.value,f.specNgramModNMax),this.addIf("--spec-ngram-mod-n-match",e.specNgramModNMatch.value,f.specNgramModNMatch),this.addIf("--spec-ngram-simple-size-n",e.specNgramSimpleSizeN.value,f.specNgramSimpleSizeN),this.addIf("--spec-ngram-simple-size-m",e.specNgramSimpleSizeM.value,f.specNgramSimpleSizeM),this.addIf("--spec-ngram-simple-min-hits",e.specNgramSimpleMinHits.value,f.specNgramSimpleMinHits)),this.addIf("--lora",e.lora.value,f.lora),this.addIf("--lora-scaled",e.loraScaled.value,f.loraScaled),this.addIf("--timeout",e.timeout.value,f.timeout),this.addIf("--threads-http",e.threadsHttp.value,f.threadsHttp),e.metrics.value==="on"&&this._flags.push("--metrics"),this.addToggle(e.slots.value,"--slots","--no-slots",!0),this.addToggle(e.cachePrompt.value,"--cache-prompt","--no-cache-prompt",!0),e.cachePrompt.value==="on"&&this.addIf("--cache-reuse",e.cacheReuse.value,f.cacheReuse),this.addIf("--reasoning",e.reasoning.value,f.reasoning),this.addIf("--reasoning-budget",e.reasoningBudget.value,f.reasoningBudget),this.addIf("--reasoning-format",e.reasoningFormat.value,f.reasoningFormat),this.addIf("--api-key-file",e.apiKeyFile.value,f.apiKeyFile);for(let u of e.extraFlags.value.split(`
5588
5588
  `)){let h=u.trim();h&&h.startsWith("--")&&this._flags.push(h)}let r=this._flags;return this._flags=null,r}save(){if(this.form.invalid)return;let e=this.parseEnvironment(),t=V({name:this.form.controls.name.value.trim(),type:"llama-server",command:this.form.controls.command.value.trim(),flags:this.buildFlags()},Object.keys(e).length?{environment:e}:{});this.dialogRef.close(t)}cancel(){this.dialogRef.close()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-llama-server-dialog"]],decls:463,vars:185,consts:[["commandAuto","matAutocomplete"],["ctxSizeAuto","matAutocomplete"],["hostAuto","matAutocomplete"],["mat-dialog-title",""],[1,"llama-form",3,"formGroup"],["appearance","outline",1,"full-width"],["matInput","","formControlName","name","placeholder","e.g. llama-qwen3_6-27b-q8",3,"disabled"],["matInput","","formControlName","command","placeholder","/path/to/llama-server",3,"matAutocomplete"],[3,"value"],["expanded",""],["formControlName","model","label","Model Path","placeholder","/path/to/model.gguf",3,"existingPaths","fieldClass"],["formControlName","mmproj","label","MMProj Path","placeholder","/path/to/mmproj.gguf (optional)",3,"existingPaths","fieldClass"],["matInput","","formControlName","alias","type","text","matTooltip","Set model name aliases (comma-separated). Used by API for model identification"],[1,"form-row"],["appearance","outline",1,"form-col-40"],["matInput","","formControlName","nGpuLayers","type","number","matTooltip","Max number of layers to store in VRAM. 999 = all layers. Can use 'auto' or 'all'"],["appearance","outline",1,"form-col-60"],["formControlName","device","multiple","","placeholder","Select GPU devices","matTooltip","Comma-separated list of devices for offloading. Use --list-devices to see available"],["appearance","outline",1,"form-col"],["formControlName","splitMode","matTooltip","How to split model across multiple GPUs. layer=pipelined, row=parallelized, tensor=experimental"],["value","layer"],["value","row"],["value","tensor"],["value","none"],["matInput","","formControlName","tensorSplit","placeholder","10,10,10","matTooltip","Fraction of model to offload to each GPU (comma-separated proportions, e.g. 3,1)",3,"disabled"],["matInput","","formControlName","mainGpu","type","number","matTooltip","GPU index for model (with split-mode=none) or for intermediate results and KV (with split-mode=row)"],[1,"subsection-label"],["formControlName","fit","matTooltip","Adjust unset arguments to fit in device memory. Helps prevent OOM errors"],["value","on"],["value","off"],["matInput","","formControlName","fitTarget","type","number","matTooltip","Target margin per device in MiB for --fit option. Default: 1024",3,"disabled"],["matInput","","formControlName","fitCtx","type","number","matTooltip","Minimum context size that can be set by --fit option. Default: 4096",3,"disabled"],["formControlName","mlock","matTooltip","Force system to keep model in RAM rather than swapping or compressing"],["formControlName","mmap","matTooltip","Memory-map model. If disabled: slower load but may reduce pageouts if not using mlock"],["formControlName","cpuMoe","matTooltip","Keep all Mixture of Experts (MoE) weights in CPU memory"],["matInput","","formControlName","nCpuMoe","type","number","matTooltip","Keep MoE weights of first N layers in CPU. 0 = disabled",3,"disabled"],["matInput","","formControlName","ctxSize","type","text","placeholder","e.g. 8K, 3x16K, 20000","matTooltip","Context size. Supports: 20000, 20K, 3x20K. 0 = from model metadata",3,"blur","keyup.enter","matAutocomplete"],["matInput","","formControlName","batchSize","type","number","matTooltip","Logical maximum batch size for processing. Default: 2048"],["matInput","","formControlName","ubatchSize","type","number","matTooltip","Physical maximum batch size. Default: 512"],["formControlName","cacheTypeK","matTooltip","KV cache data type for K. Options: f32, f16, bf16, q8_0, q4_0, q4_1, iq4_nl, q5_0, q5_1"],["formControlName","cacheTypeV","matTooltip","KV cache data type for V. Options: f32, f16, bf16, q8_0, q4_0, q4_1, iq4_nl, q5_0, q5_1"],["formControlName","kvOffload","matTooltip","Enable KV cache offloading to GPU. Reduces CPU memory usage"],["matInput","","formControlName","cacheRam","type","number","matTooltip","Maximum prompt cache size in MiB. -1 = no limit, 0 = disable. Default: 8192"],["formControlName","swaFull","matTooltip","Use full-size SWA (Sliding Window Attention) cache instead of compressed"],["formControlName","ropeScaling","matTooltip","RoPE frequency scaling method. linear or yarn for extended context"],["value","linear"],["value","yarn"],["matInput","","formControlName","ropeScale","type","number","matTooltip","RoPE context scaling factor. Expands context by factor of N",3,"disabled"],["matInput","","formControlName","ropeFreqBase","type","number","matTooltip","RoPE base frequency for NTK-aware scaling. 0 = loaded from model",3,"disabled"],["matInput","","formControlName","ropeFreqScale","type","number","matTooltip","RoPE frequency scaling factor. Expands context by factor of 1/N. 0 = from model",3,"disabled"],["matInput","","formControlName","threads","type","number","matTooltip","Number of CPU threads to use during generation. -1 = auto-detect"],["matInput","","formControlName","parallel","type","number","matTooltip","Number of server slots for parallel requests. -1 = auto"],["matInput","","formControlName","nPredict","type","number","matTooltip","Maximum number of tokens to predict. -1 = infinity (unlimited generation)"],["formControlName","flashAttn","matTooltip","Enable Flash Attention for faster inference with lower VRAM usage"],["value","auto"],["formControlName","contBatching","matTooltip","Enable continuous (dynamic) batching for better throughput with multiple requests"],["formControlName","contextShift","matTooltip","Enable context shift on infinite text generation. Shifts context window when full"],["matInput","","formControlName","temperature","type","number","matTooltip","Temperature for sampling. Higher = more random, lower = more deterministic. Default: 0.8"],["matInput","","formControlName","seed","type","number","matTooltip","RNG seed for reproducibility. -1 = random seed"],["matInput","","formControlName","topK","type","number","matTooltip","Top-K sampling: limit to K most likely tokens. 0 = disabled. Default: 40",3,"disabled"],["matInput","","formControlName","topP","type","number","matTooltip","Top-P (nucleus) sampling: cumulative probability threshold. 1.0 = disabled. Default: 0.95",3,"disabled"],["matInput","","formControlName","minP","type","number","matTooltip","Min-P sampling: minimum probability threshold. 0.0 = disabled. Default: 0.05"],["matInput","","formControlName","typicalP","type","number","matTooltip","Locally typical sampling parameter p. 1.0 = disabled",3,"disabled"],["formControlName","mirostat","matTooltip","Mirostat sampling mode. 0=disabled, 1=Mirostat, 2=Mirostat 2.0. Top-K/Nucleus ignored when enabled"],["matInput","","formControlName","dynatempRange","type","number","matTooltip","Dynamic temperature range. 0.0 = disabled"],["matInput","","formControlName","repeatLastN","type","number","matTooltip","Last N tokens to consider for penalty. 0 = disabled, -1 = ctx_size. Default: 64"],["matInput","","formControlName","repeatPenalty","type","number","matTooltip","Penalize repeat sequence of tokens. 1.0 = disabled"],["matInput","","formControlName","presencePenalty","type","number","matTooltip","Alpha presence penalty: penalize tokens that appeared. 0.0 = disabled"],["matInput","","formControlName","frequencyPenalty","type","number","matTooltip","Alpha frequency penalty: penalize by token frequency. 0.0 = disabled"],["matInput","","formControlName","dryMultiplier","type","number","matTooltip","DRY sampling multiplier: prevents repetition by penalizing recent tokens. 0.0 = disabled"],["matInput","","formControlName","dryBase","type","number","matTooltip","DRY sampling base value. Default: 1.75"],["appearance","outline","subscriptSizing","dynamic",1,"full-width"],["formControlName","specType","matTooltip","Type of speculative decoding. draft-* uses draft model, ngram-* uses n-gram lookup; draft-mtp,ngram-mod runs both (recent llama.cpp builds)"],["value","draft-simple"],["value","draft-eagle3"],["value","draft-mtp"],["value","ngram-simple"],["value","ngram-mod"],["value","draft-mtp,ngram-mod"],["formControlName","lora","label","LoRA Adapter Path","placeholder","/path/to/lora.gguf (comma-separated for multiple)",3,"existingPaths","fieldClass"],["matInput","","formControlName","loraScaled","type","text","matTooltip","LoRA adapter with user-defined scaling. Format: path:scale,... (e.g. lora.gguf:0.5)"],["matInput","","formControlName","host","type","text","matTooltip","IP address to listen (default: 127.0.0.1). Can bind to UNIX socket if ends with .sock",3,"matAutocomplete"],["matInput","","formControlName","port","type","number","matTooltip","Port to listen (default: 8080). Ignored when host is a UNIX socket",3,"disabled"],["matInput","","formControlName","timeout","type","number","matTooltip","Server read/write timeout in seconds. Default: 3600"],["matInput","","formControlName","threadsHttp","type","number","matTooltip","Number of threads for HTTP requests. -1 = auto"],["formControlName","apiKeyFile","label","API Key File","placeholder","/path/to/keys.ini",3,"existingPaths","fieldClass"],["formControlName","metrics","matTooltip","Enable Prometheus-compatible metrics endpoint at /metrics"],["formControlName","slots","matTooltip","Expose slots monitoring endpoint at /slots"],["formControlName","cachePrompt","matTooltip","Enable prompt caching to speed up repeated prompts"],["matInput","","formControlName","cacheReuse","type","number","matTooltip","Min chunk size to attempt reusing from cache via KV shifting. Requires prompt caching",3,"disabled"],["formControlName","reasoning","matTooltip","Use reasoning/thinking in chat. auto = detect from template"],["matInput","","formControlName","reasoningBudget","type","number","matTooltip","Token budget for thinking. -1 = unlimited, 0 = immediate end, N>0 = token limit",3,"disabled"],["formControlName","reasoningFormat","matTooltip","Format for reasoning output. none=raw, deepseek=reasoning_content field, deepseek-legacy=keep think tags",3,"disabled"],["value","deepseek"],["value","deepseek-legacy"],["matInput","","formControlName","extraFlags","rows","4","wrap","off","placeholder",`--custom-flag value
5589
5589
  --flash-attn on`,"matTooltip","Any llama-server flags not covered by the fields above (one per line). Pass-through \u2014 not validated",1,"flags-textarea"],["matInput","","formControlName","envText","rows","4","wrap","off","placeholder",`HF_HOME=/data/huggingface
5590
- HSA_OVERRIDE_GFX_VERSION=11.0.0`,"matTooltip","Environment variables for the service process (KEY=VALUE, one per line)",1,"env-textarea"],["align","end"],["mat-stroked-button","",3,"click"],["mat-raised-button","","color","primary",3,"click","disabled"],[1,"auto-path"],[1,"auto-from"],["matInput","","formControlName","yarnOrigCtx","type","number","matTooltip","YaRN: original context size of model. 0 = model training context size"],["matInput","","formControlName","yarnExtFactor","type","number","matTooltip","YaRN: extrapolation mix factor. -1 = default, 0.0 = full interpolation"],["matInput","","formControlName","yarnAttnFactor","type","number","matTooltip","YaRN: scale sqrt(t) or attention magnitude. -1 = default"],["matInput","","formControlName","yarnBetaSlow","type","number","matTooltip","YaRN: high correction dim (alpha). -1 = default"],["matInput","","formControlName","yarnBetaFast","type","number","matTooltip","YaRN: low correction dim (beta). -1 = default"],["formControlName","modelDraft","label","Draft Model Path","placeholder","/path/to/draft-model.gguf",3,"existingPaths","fieldClass"],["formControlName","specDraftDevice","multiple","","placeholder","Select GPU devices for draft model","matTooltip","Devices for offloading the draft model. Same options as main --device"],["matInput","","formControlName","specDraftNMax","type","number","matTooltip","Max number of tokens to draft for speculative decoding. Default: 3"],["matInput","","formControlName","nGpuLayersDraft","type","number","matTooltip","Max draft model layers to store in VRAM. 999 = all layers"],["formControlName","specDraftCacheTypeK","matTooltip","KV cache data type for K for the draft model"],["formControlName","specDraftCacheTypeV","matTooltip","KV cache data type for V for the draft model"],["matInput","","formControlName","specNgramModNMin","type","number","matTooltip","Min number of ngram tokens for ngram-mod speculative decoding. Default: 48"],["matInput","","formControlName","specNgramModNMax","type","number","matTooltip","Max number of ngram tokens for ngram-mod speculative decoding. Default: 64"],["matInput","","formControlName","specNgramModNMatch","type","number","matTooltip","Ngram-mod lookup length. Default: 24"],["matInput","","formControlName","specNgramSimpleSizeN","type","number","matTooltip","Ngram size N for ngram-simple: length of lookup n-gram. Default: 12"],["matInput","","formControlName","specNgramSimpleSizeM","type","number","matTooltip","Ngram size M for ngram-simple: length of draft m-gram. Default: 48"],["matInput","","formControlName","specNgramSimpleMinHits","type","number","matTooltip","Minimum hits for ngram-simple speculative decoding. Default: 1"]],template:function(t,n){if(t&1&&(s(0,"h2",3),m(1),l(),s(2,"mat-dialog-content")(3,"form",4)(4,"mat-form-field",5),v(5,"input",6),b(),s(6,"mat-label"),m(7,"Service Name"),l(),M(8,ry,2,0,"mat-error")(9,sy,2,0,"mat-error"),l(),s(10,"mat-form-field",5),v(11,"input",7),b(),s(12,"mat-label"),m(13,"Binary Path"),l(),M(14,ly,2,0,"mat-error"),l(),s(15,"mat-autocomplete",null,0),me(17,cy,5,3,"mat-option",8,oy),l(),s(19,"mat-expansion-panel",9)(20,"mat-expansion-panel-header")(21,"mat-panel-title"),m(22,"Model"),l()(),v(23,"app-file-autocomplete",10),b(),v(24,"app-file-autocomplete",11),b(),s(25,"mat-form-field",5),v(26,"input",12),b(),s(27,"mat-label"),m(28,"Model Alias"),l()()(),s(29,"mat-expansion-panel",9)(30,"mat-expansion-panel-header")(31,"mat-panel-title"),m(32,"GPU & Memory"),l()(),s(33,"div",13)(34,"mat-form-field",14),v(35,"input",15),b(),s(36,"mat-label"),m(37,"GPU Layers"),l()(),s(38,"mat-form-field",16)(39,"mat-select",17),me(40,dy,2,2,"mat-option",8,Hc),l(),b(),s(42,"mat-label"),m(43,"Device (multi-select)"),l()()(),s(44,"div",13)(45,"mat-form-field",18)(46,"mat-select",19)(47,"mat-option",20),m(48,"layer (pipelined)"),l(),s(49,"mat-option",21),m(50,"row (parallelized)"),l(),s(51,"mat-option",22),m(52,"tensor (experimental)"),l(),s(53,"mat-option",23),m(54,"none (single GPU)"),l()(),b(),s(55,"mat-label"),m(56,"Split Mode"),l()(),s(57,"mat-form-field",18),v(58,"input",24),b(),s(59,"mat-label"),m(60,"Tensor Split"),l()(),s(61,"mat-form-field",18),v(62,"input",25),b(),s(63,"mat-label"),m(64,"Main GPU"),l()()(),s(65,"div",26),m(66,"Memory"),l(),s(67,"div",13)(68,"mat-form-field",18)(69,"mat-select",27)(70,"mat-option",28),m(71,"on"),l(),s(72,"mat-option",29),m(73,"off"),l()(),b(),s(74,"mat-label"),m(75,"Fit to VRAM"),l()(),s(76,"mat-form-field",18),v(77,"input",30),b(),s(78,"mat-label"),m(79,"Fit Target (MiB)"),l()(),s(80,"mat-form-field",18),v(81,"input",31),b(),s(82,"mat-label"),m(83,"Fit Min Ctx"),l()()(),s(84,"div",13)(85,"mat-form-field",18)(86,"mat-select",32)(87,"mat-option",28),m(88,"on"),l(),s(89,"mat-option",29),m(90,"off"),l()(),b(),s(91,"mat-label"),m(92,"mlock (pin RAM)"),l()(),s(93,"mat-form-field",18)(94,"mat-select",33)(95,"mat-option",28),m(96,"on"),l(),s(97,"mat-option",29),m(98,"off"),l()(),b(),s(99,"mat-label"),m(100,"mmap"),l()(),s(101,"mat-form-field",18)(102,"mat-select",34)(103,"mat-option",28),m(104,"on"),l(),s(105,"mat-option",29),m(106,"off"),l()(),b(),s(107,"mat-label"),m(108,"CPU MoE"),l()(),s(109,"mat-form-field",18),v(110,"input",35),b(),s(111,"mat-label"),m(112,"N CPU MoE Layers"),l()()()(),s(113,"mat-expansion-panel")(114,"mat-expansion-panel-header")(115,"mat-panel-title"),m(116,"Context & KV Cache"),l()(),s(117,"div",13)(118,"mat-form-field",18)(119,"input",36),A("blur",function(r){return n.onCtxSizeInput(r)})("keyup.enter",function(r){return n.onCtxSizeInput(r)}),l(),b(),s(120,"mat-label"),m(121,"Context Size"),l()(),s(122,"mat-autocomplete",null,1),me(124,my,2,2,"mat-option",8,ay),l(),s(126,"mat-form-field",18),v(127,"input",37),b(),s(128,"mat-label"),m(129,"Batch Size"),l()(),s(130,"mat-form-field",18),v(131,"input",38),b(),s(132,"mat-label"),m(133,"Ubatch Size"),l()()(),s(134,"div",13)(135,"mat-form-field",18)(136,"mat-select",39),me(137,uy,2,2,"mat-option",8,xt),l(),b(),s(139,"mat-label"),m(140,"KV Cache Type K"),l()(),s(141,"mat-form-field",18)(142,"mat-select",40),me(143,hy,2,2,"mat-option",8,xt),l(),b(),s(145,"mat-label"),m(146,"KV Cache Type V"),l()(),s(147,"mat-form-field",18)(148,"mat-select",41)(149,"mat-option",28),m(150,"on"),l(),s(151,"mat-option",29),m(152,"off"),l()(),b(),s(153,"mat-label"),m(154,"KV Offload"),l()()(),s(155,"div",13)(156,"mat-form-field",18),v(157,"input",42),b(),s(158,"mat-label"),m(159,"Cache RAM (MiB)"),l()(),s(160,"mat-form-field",18)(161,"mat-select",43)(162,"mat-option",28),m(163,"on"),l(),s(164,"mat-option",29),m(165,"off"),l()(),b(),s(166,"mat-label"),m(167,"Full SWA Cache"),l()()()(),s(168,"mat-expansion-panel")(169,"mat-expansion-panel-header")(170,"mat-panel-title"),m(171,"RoPE Scaling"),l()(),s(172,"div",13)(173,"mat-form-field",18)(174,"mat-select",44)(175,"mat-option",23),m(176,"none"),l(),s(177,"mat-option",45),m(178,"linear"),l(),s(179,"mat-option",46),m(180,"yarn"),l()(),b(),s(181,"mat-label"),m(182,"Scaling Method"),l()(),s(183,"mat-form-field",18),v(184,"input",47),b(),s(185,"mat-label"),m(186,"Scale Factor"),l()(),s(187,"mat-form-field",18),v(188,"input",48),b(),s(189,"mat-label"),m(190,"Freq Base"),l()(),s(191,"mat-form-field",18),v(192,"input",49),b(),s(193,"mat-label"),m(194,"Freq Scale"),l()()(),M(195,py,23,10),l(),s(196,"mat-expansion-panel")(197,"mat-expansion-panel-header")(198,"mat-panel-title"),m(199,"Generation"),l(),s(200,"mat-panel-description"),m(201,"Runtime and batching defaults"),l()(),s(202,"div",13)(203,"mat-form-field",18),v(204,"input",50),b(),s(205,"mat-label"),m(206,"Threads"),l()(),s(207,"mat-form-field",18),v(208,"input",51),b(),s(209,"mat-label"),m(210,"Parallel Slots"),l()(),s(211,"mat-form-field",18),v(212,"input",52),b(),s(213,"mat-label"),m(214,"Max Tokens (n-predict)"),l()()(),s(215,"div",13)(216,"mat-form-field",18)(217,"mat-select",53)(218,"mat-option",28),m(219,"on"),l(),s(220,"mat-option",29),m(221,"off"),l(),s(222,"mat-option",54),m(223,"auto"),l()(),b(),s(224,"mat-label"),m(225,"Flash Attention"),l()(),s(226,"mat-form-field",18)(227,"mat-select",55)(228,"mat-option",28),m(229,"on"),l(),s(230,"mat-option",29),m(231,"off"),l()(),b(),s(232,"mat-label"),m(233,"Cont. Batching"),l()(),s(234,"mat-form-field",18)(235,"mat-select",56)(236,"mat-option",28),m(237,"on"),l(),s(238,"mat-option",29),m(239,"off"),l()(),b(),s(240,"mat-label"),m(241,"Context Shift"),l()()()(),s(242,"mat-expansion-panel")(243,"mat-expansion-panel-header")(244,"mat-panel-title"),m(245,"Sampling Defaults"),l(),s(246,"mat-panel-description"),m(247,"Default sampling parameters for generation"),l()(),s(248,"div",26),m(249,"Core"),l(),s(250,"div",13)(251,"mat-form-field",18),v(252,"input",57),b(),s(253,"mat-label"),m(254,"Temperature"),l()(),s(255,"mat-form-field",18),v(256,"input",58),b(),s(257,"mat-label"),m(258,"Seed"),l()(),s(259,"mat-form-field",18),v(260,"input",59),b(),s(261,"mat-label"),m(262,"Top-K"),l()(),s(263,"mat-form-field",18),v(264,"input",60),b(),s(265,"mat-label"),m(266,"Top-P"),l()()(),s(267,"div",13)(268,"mat-form-field",18),v(269,"input",61),b(),s(270,"mat-label"),m(271,"Min-P"),l()(),s(272,"mat-form-field",18),v(273,"input",62),b(),s(274,"mat-label"),m(275,"Typical-P"),l()(),s(276,"mat-form-field",18)(277,"mat-select",63)(278,"mat-option",8),m(279,"disabled"),l(),s(280,"mat-option",8),m(281,"Mirostat"),l(),s(282,"mat-option",8),m(283,"Mirostat 2.0"),l()(),b(),s(284,"mat-label"),m(285,"Mirostat"),l()(),s(286,"mat-form-field",18),v(287,"input",64),b(),s(288,"mat-label"),m(289,"Dyn. Temp Range"),l()()(),s(290,"div",26),m(291,"Penalties"),l(),s(292,"div",13)(293,"mat-form-field",18),v(294,"input",65),b(),s(295,"mat-label"),m(296,"Repeat Last N"),l()(),s(297,"mat-form-field",18),v(298,"input",66),b(),s(299,"mat-label"),m(300,"Repeat Penalty"),l()(),s(301,"mat-form-field",18),v(302,"input",67),b(),s(303,"mat-label"),m(304,"Presence Penalty"),l()(),s(305,"mat-form-field",18),v(306,"input",68),b(),s(307,"mat-label"),m(308,"Frequency Penalty"),l()()(),s(309,"div",26),m(310,"DRY Sampling"),l(),s(311,"div",13)(312,"mat-form-field",18),v(313,"input",69),b(),s(314,"mat-label"),m(315,"DRY Multiplier"),l()(),s(316,"mat-form-field",18),v(317,"input",70),b(),s(318,"mat-label"),m(319,"DRY Base"),l()()()(),s(320,"mat-expansion-panel")(321,"mat-expansion-panel-header")(322,"mat-panel-title"),m(323,"Speculative Decoding"),l(),s(324,"mat-panel-description"),m(325,"Draft model and speculative decoding options"),l()(),s(326,"mat-form-field",71)(327,"mat-select",72)(328,"mat-option",23),m(329,"none"),l(),s(330,"mat-option",73),m(331,"draft-simple"),l(),s(332,"mat-option",74),m(333,"draft-eagle3"),l(),s(334,"mat-option",75),m(335,"draft-mtp"),l(),s(336,"mat-option",76),m(337,"ngram-simple"),l(),s(338,"mat-option",77),m(339,"ngram-mod"),l(),s(340,"mat-option",78),m(341,"draft-mtp,ngram-mod"),l()(),b(),s(342,"mat-label"),m(343,"Spec Type"),l()(),M(344,vy,32,12),M(345,by,15,6),M(346,yy,15,6),l(),s(347,"mat-expansion-panel")(348,"mat-expansion-panel-header")(349,"mat-panel-title"),m(350,"LoRA & Adapters"),l()(),v(351,"app-file-autocomplete",79),b(),s(352,"mat-form-field",5),v(353,"input",80),b(),s(354,"mat-label"),m(355,"LoRA Scaled"),l()()(),s(356,"mat-expansion-panel")(357,"mat-expansion-panel-header")(358,"mat-panel-title"),m(359,"Server & Network"),l()(),s(360,"div",13)(361,"mat-form-field",18),v(362,"input",81),b(),s(363,"mat-label"),m(364,"Host"),l()(),s(365,"mat-autocomplete",null,2),me(367,Cy,5,3,"mat-option",8,Hc),l(),s(369,"mat-form-field",18),v(370,"input",82),b(),s(371,"mat-label"),m(372,"Port"),l()(),s(373,"mat-form-field",18),v(374,"input",83),b(),s(375,"mat-label"),m(376,"Timeout (s)"),l()(),s(377,"mat-form-field",18),v(378,"input",84),b(),s(379,"mat-label"),m(380,"HTTP Threads"),l()()(),v(381,"app-file-autocomplete",85),b(),s(382,"div",13)(383,"mat-form-field",18)(384,"mat-select",86)(385,"mat-option",28),m(386,"on"),l(),s(387,"mat-option",29),m(388,"off"),l()(),b(),s(389,"mat-label"),m(390,"Prometheus Metrics"),l()(),s(391,"mat-form-field",18)(392,"mat-select",87)(393,"mat-option",28),m(394,"on"),l(),s(395,"mat-option",29),m(396,"off"),l()(),b(),s(397,"mat-label"),m(398,"Slots Endpoint"),l()(),s(399,"mat-form-field",18)(400,"mat-select",88)(401,"mat-option",28),m(402,"on"),l(),s(403,"mat-option",29),m(404,"off"),l()(),b(),s(405,"mat-label"),m(406,"Prompt Cache"),l()(),s(407,"mat-form-field",18),v(408,"input",89),b(),s(409,"mat-label"),m(410,"Cache Reuse"),l()()()(),s(411,"mat-expansion-panel")(412,"mat-expansion-panel-header")(413,"mat-panel-title"),m(414,"Reasoning"),l(),s(415,"mat-panel-description"),m(416,"Thinking/reasoning mode settings"),l()(),s(417,"div",13)(418,"mat-form-field",18)(419,"mat-select",90)(420,"mat-option",28),m(421,"on"),l(),s(422,"mat-option",29),m(423,"off"),l(),s(424,"mat-option",54),m(425,"auto"),l()(),b(),s(426,"mat-label"),m(427,"Reasoning"),l()(),s(428,"mat-form-field",18),v(429,"input",91),b(),s(430,"mat-label"),m(431,"Reasoning Budget"),l()(),s(432,"mat-form-field",18)(433,"mat-select",92)(434,"mat-option",54),m(435,"auto"),l(),s(436,"mat-option",23),m(437,"none (raw)"),l(),s(438,"mat-option",93),m(439,"deepseek"),l(),s(440,"mat-option",94),m(441,"deepseek-legacy"),l()(),b(),s(442,"mat-label"),m(443,"Reasoning Format"),l()()()(),s(444,"mat-expansion-panel")(445,"mat-expansion-panel-header")(446,"mat-panel-title"),m(447,"Additional"),l(),s(448,"mat-panel-description"),m(449,"Extra CLI flags and environment variables"),l()(),s(450,"mat-form-field",5),v(451,"textarea",95),b(),s(452,"mat-label"),m(453,"Extra CLI Flags (one per line)"),l()(),s(454,"mat-form-field",5),v(455,"textarea",96),b(),s(456,"mat-label"),m(457,"Environment variables (KEY=VALUE, one per line)"),l()()()()(),s(458,"mat-dialog-actions",97)(459,"button",98),A("click",function(){return n.cancel()}),m(460,"Cancel"),l(),s(461,"button",99),A("click",function(){return n.save()}),m(462),l()()),t&2){let a=Ne(16),r=Ne(123),u=Ne(366);c(),he("",n.isClone?"Clone":n.isEdit?"Edit":"Add"," llama-server service"),c(2),x("formGroup",n.form),c(),p("changed",n.isControlChanged("name")),c(),x("disabled",n.isEdit&&!n.isClone),y(),c(3),E(n.form.controls.name.errors?.required?8:n.form.controls.name.errors?.pattern?9:-1),c(2),p("changed",n.isControlChanged("command")),c(),x("matAutocomplete",a),y(),c(3),E(n.form.controls.command.errors?.required?14:-1),c(3),ue(n.filteredCommands()),c(2),p("has-changed",n.isSectionChanged("model","mmproj","alias")),c(4),x("existingPaths",n.existingModelPaths())("fieldClass",n.isControlChanged("model")?"changed":""),y(),c(),x("existingPaths",n.existingMmprojPaths())("fieldClass",n.isControlChanged("mmproj")?"changed":""),y(),c(),p("changed",n.isControlChanged("alias")),c(),y(),c(3),p("has-changed",n.isSectionChanged("nGpuLayers","device","tensorSplit","splitMode","mainGpu","fit","fitTarget","fitCtx","mlock","mmap","cpuMoe","nCpuMoe")),c(5),p("changed",n.isControlChanged("nGpuLayers")),c(),y(),c(3),p("changed",n.isControlChanged("device")),c(),y(),c(),ue(n.availableDevices()),c(5),p("changed",n.isControlChanged("splitMode")),c(),y(),c(11),p("changed",n.isControlChanged("tensorSplit")&&!n.isTensorSplitDisabled()),c(),x("disabled",n.isTensorSplitDisabled()),y(),c(3),p("changed",n.isControlChanged("mainGpu")),c(),y(),c(6),p("changed",n.isControlChanged("fit")),c(),y(),c(7),p("changed",n.isControlChanged("fitTarget")&&!n.isFitTargetDisabled()),c(),x("disabled",n.isFitTargetDisabled()),y(),c(3),p("changed",n.isControlChanged("fitCtx")&&!n.isFitTargetDisabled()),c(),x("disabled",n.isFitTargetDisabled()),y(),c(4),p("changed",n.isControlChanged("mlock")),c(),y(),c(7),p("changed",n.isControlChanged("mmap")),c(),y(),c(7),p("changed",n.isControlChanged("cpuMoe")),c(),y(),c(7),p("changed",n.isControlChanged("nCpuMoe")&&!n.isCpuMoeLayersDisabled()),c(),x("disabled",n.isCpuMoeLayersDisabled()),y(),c(3),p("has-changed",n.isSectionChanged("ctxSize","batchSize","ubatchSize","cacheTypeK","cacheTypeV","kvOffload","cacheRam","swaFull")),c(5),p("changed",n.isControlChanged("ctxSize")),c(),x("matAutocomplete",r),y(),c(5),ue(n.ctxPresets()),c(2),p("changed",n.isControlChanged("batchSize")),c(),y(),c(3),p("changed",n.isControlChanged("ubatchSize")),c(),y(),c(4),p("changed",n.isControlChanged("cacheTypeK")),c(),y(),c(),ue(n.kvCacheTypes),c(4),p("changed",n.isControlChanged("cacheTypeV")),c(),y(),c(),ue(n.kvCacheTypes),c(4),p("changed",n.isControlChanged("kvOffload")),c(),y(),c(8),p("changed",n.isControlChanged("cacheRam")),c(),y(),c(3),p("changed",n.isControlChanged("swaFull")),c(),y(),c(7),p("has-changed",n.isSectionChanged("ropeScaling","ropeScale","ropeFreqBase","ropeFreqScale","yarnOrigCtx","yarnExtFactor","yarnAttnFactor","yarnBetaSlow","yarnBetaFast")),c(5),p("changed",n.isControlChanged("ropeScaling")),c(),y(),c(9),p("changed",n.isControlChanged("ropeScale")&&!n.isRopeParamsDisabled()),c(),x("disabled",n.isRopeParamsDisabled()),y(),c(3),p("changed",n.isControlChanged("ropeFreqBase")&&!n.isRopeParamsDisabled()),c(),x("disabled",n.isRopeParamsDisabled()),y(),c(3),p("changed",n.isControlChanged("ropeFreqScale")&&!n.isRopeParamsDisabled()),c(),x("disabled",n.isRopeParamsDisabled()),y(),c(3),E(n.showYarnParams()?195:-1),c(),p("has-changed",n.isSectionChanged("threads","parallel","flashAttn","contBatching","contextShift","nPredict")),c(7),p("changed",n.isControlChanged("threads")),c(),y(),c(3),p("changed",n.isControlChanged("parallel")),c(),y(),c(3),p("changed",n.isControlChanged("nPredict")),c(),y(),c(4),p("changed",n.isControlChanged("flashAttn")),c(),y(),c(9),p("changed",n.isControlChanged("contBatching")),c(),y(),c(7),p("changed",n.isControlChanged("contextShift")),c(),y(),c(7),p("has-changed",n.isSectionChanged("temperature","seed","topK","topP","minP","typicalP","mirostat","dynatempRange","repeatLastN","repeatPenalty","presencePenalty","frequencyPenalty","dryMultiplier","dryBase")),c(9),p("changed",n.isControlChanged("temperature")),c(),y(),c(3),p("changed",n.isControlChanged("seed")),c(),y(),c(3),p("changed",n.isControlChanged("topK")&&!n.isMirostatEnabled()),c(),x("disabled",n.isMirostatEnabled()),y(),c(3),p("changed",n.isControlChanged("topP")&&!n.isMirostatEnabled()),c(),x("disabled",n.isMirostatEnabled()),y(),c(4),p("changed",n.isControlChanged("minP")),c(),y(),c(3),p("changed",n.isControlChanged("typicalP")&&!n.isMirostatEnabled()),c(),x("disabled",n.isMirostatEnabled()),y(),c(3),p("changed",n.isControlChanged("mirostat")),c(),y(),c(),x("value",0),c(2),x("value",1),c(2),x("value",2),c(4),p("changed",n.isControlChanged("dynatempRange")),c(),y(),c(6),p("changed",n.isControlChanged("repeatLastN")),c(),y(),c(3),p("changed",n.isControlChanged("repeatPenalty")),c(),y(),c(3),p("changed",n.isControlChanged("presencePenalty")),c(),y(),c(3),p("changed",n.isControlChanged("frequencyPenalty")),c(),y(),c(6),p("changed",n.isControlChanged("dryMultiplier")),c(),y(),c(3),p("changed",n.isControlChanged("dryBase")),c(),y(),c(3),p("has-changed",n.isSectionChanged("modelDraft","specDraftDevice","specDraftNMax","nGpuLayersDraft","specDraftCacheTypeK","specDraftCacheTypeV","specType","specNgramModNMin","specNgramModNMax","specNgramModNMatch","specNgramSimpleSizeN","specNgramSimpleSizeM","specNgramSimpleMinHits")),c(6),p("changed",n.isControlChanged("specType")),c(),y(),c(17),E(n.showDraftParams()?344:-1),c(),E(n.showNgramModParams()?345:-1),c(),E(n.showNgramSimpleParams()?346:-1),c(),p("has-changed",n.isSectionChanged("lora","loraScaled")),c(4),x("existingPaths",n.existingLoraPaths())("fieldClass",n.isControlChanged("lora")?"changed":""),y(),c(),p("changed",n.isControlChanged("loraScaled")),c(),y(),c(3),p("has-changed",n.isSectionChanged("host","port","timeout","threadsHttp","apiKeyFile","metrics","slots","cachePrompt","cacheReuse")),c(5),p("changed",n.isControlChanged("host")),c(),x("matAutocomplete",u),y(),c(5),ue(n.filteredHosts()),c(2),p("changed",n.isControlChanged("port")&&!n.isPortDisabled()),c(),x("disabled",n.isPortDisabled()),y(),c(3),p("changed",n.isControlChanged("timeout")),c(),y(),c(3),p("changed",n.isControlChanged("threadsHttp")),c(),y(),c(3),x("existingPaths",n.existingApiKeyPaths())("fieldClass",n.isControlChanged("apiKeyFile")?"changed":""),y(),c(2),p("changed",n.isControlChanged("metrics")),c(),y(),c(7),p("changed",n.isControlChanged("slots")),c(),y(),c(7),p("changed",n.isControlChanged("cachePrompt")),c(),y(),c(7),p("changed",n.isControlChanged("cacheReuse")&&!n.isCacheReuseDisabled()),c(),x("disabled",n.isCacheReuseDisabled()),y(),c(3),p("has-changed",n.isSectionChanged("reasoning","reasoningBudget","reasoningFormat")),c(7),p("changed",n.isControlChanged("reasoning")),c(),y(),c(9),p("changed",n.isControlChanged("reasoningBudget")&&!n.isReasoningParamsDisabled()),c(),x("disabled",n.isReasoningParamsDisabled()),y(),c(3),p("changed",n.isControlChanged("reasoningFormat")&&!n.isReasoningParamsDisabled()),c(),x("disabled",n.isReasoningParamsDisabled()),y(),c(11),p("has-changed",n.isSectionChanged("extraFlags","envText")),c(6),p("changed",n.isControlChanged("extraFlags")),c(),y(),c(3),p("changed",n.isControlChanged("envText")),c(),y(),c(6),x("disabled",n.form.invalid),c(),he(" ",n.isEdit&&!n.isClone?"Save":"Create"," ")}},dependencies:[Ve,hn,bo,Ei,va,Ai,mn,pn,Ut,ji,xn,Cn,vt,Wi,Qe,it,Oo,Ts,Ba,Ms,As,Es,St,kt,Ot,fn,ti,ei,Lt,oi,ri,ai,Fo,Po,Is,za,Dp],styles:['@charset "UTF-8";.llama-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:8px;min-width:640px}.form-row[_ngcontent-%COMP%]{display:flex;gap:12px;margin-bottom:4px}.form-col[_ngcontent-%COMP%]{flex:1}.form-col-60[_ngcontent-%COMP%]{flex:3}.form-col-40[_ngcontent-%COMP%]{flex:2}.full-width[_ngcontent-%COMP%]{width:100%}.auto-path[_ngcontent-%COMP%]{font-family:monospace}.auto-from[_ngcontent-%COMP%]{margin-left:8px;opacity:.6;font-size:12px}.flags-textarea[_ngcontent-%COMP%], .env-textarea[_ngcontent-%COMP%]{overflow-x:auto}mat-dialog-content[_ngcontent-%COMP%]{padding-top:10px!important;max-height:80vh}mat-expansion-panel[_ngcontent-%COMP%]{margin-bottom:0}mat-dialog-actions[_ngcontent-%COMP%]{gap:8px}.subsection-label[_ngcontent-%COMP%]{font-size:12px;font-weight:500;color:#0009;margin:4px 0 14px;text-transform:uppercase;letter-spacing:.5px}.sub-section-hint[_ngcontent-%COMP%]{font-size:11px;color:#0006;margin-bottom:4px}mat-expansion-panel.has-changed[_ngcontent-%COMP%] mat-panel-title[_ngcontent-%COMP%]{font-weight:700}mat-form-field.changed[_ngcontent-%COMP%] .mat-mdc-form-field-infix input, mat-form-field.changed[_ngcontent-%COMP%] .mat-mdc-form-field-infix .mat-mdc-select{font-weight:700}']})}}return i})();function No(i,o){for(let e of i){let t=e.indexOf("=");if(t>0&&e.slice(0,t)===o)return e.slice(t+1);let n=e.indexOf(" ");if(n>0&&e.slice(0,n)===o)return e.slice(n+1).trim()}for(let e=0;e<i.length;e++)if(i[e]===o&&e+1<i.length)return i[e+1];return null}var Sy=(i,o)=>o.command,My=(i,o)=>o.value,Ey=(i,o)=>o.path;function Ay(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function Ty(i,o){i&1&&(s(0,"mat-error"),m(1,"Starts with letter, alphanumeric + hyphens/underscores, max 128 chars"),l())}function Iy(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function Ry(i,o){if(i&1&&(s(0,"mat-option",8)(1,"span",55),m(2),l(),s(3,"span",56),m(4),l()()),i&2){let e=o.$implicit;x("value",e.command),c(2),q(e.command),c(2),he("(",e.from,")")}}function Oy(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function Py(i,o){if(i&1&&(s(0,"mat-option",8)(1,"span",55),m(2),l(),s(3,"span",56),m(4,"(existing config)"),l()()),i&2){let e=o.$implicit;x("value",e),c(2),q(e)}}function Fy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e),c(),q(e)}}function Ny(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e),c(),q(e)}}function Ly(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e.value),c(),q(e.label)}}function Vy(i,o){if(i&1&&(s(0,"div",57),m(1,"Draft Model"),l(),s(2,"div",11)(3,"mat-form-field",58),v(4,"input",59),b(),s(5,"mat-label"),m(6,"Draft Model"),l()(),s(7,"mat-form-field",12),v(8,"input",60),b(),s(9,"mat-label"),m(10,"Draft TP Size"),l()(),s(11,"mat-form-field",12),v(12,"input",61),b(),s(13,"mat-label"),m(14,"Num Spec Tokens"),l()()()),i&2){let e=D();c(3),p("changed",e.isControlChanged("specDraftModel")),c(),y(),c(3),p("changed",e.isControlChanged("specDraftTensorParallelSize")),c(),y(),c(3),p("changed",e.isControlChanged("specNumDraftTokens")),c(),y()}}function By(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e),c(),q(e||"(none)")}}function zy(i,o){if(i&1&&(s(0,"mat-option",8),m(1),l()),i&2){let e=o.$implicit;x("value",e),c(),q(e||"(none)")}}function jy(i,o){if(i&1&&(s(0,"mat-option",8)(1,"span",55),m(2),l(),s(3,"span",56),m(4),l()()),i&2){let e=o.$implicit;x("value",e.path),c(2),q(e.path),c(2),he("(",e.source,")")}}var S={host:"127.0.0.1",port:8e3,servedModelName:"",model:"",tokenizer:"",dtype:"auto",tensorParallelSize:1,pipelineParallelSize:1,maxParallelLoadingWorkers:0,gpuMemoryUtilization:.9,swapSpace:4,cpuOffloadGb:0,kvCacheMemory:0,device:"",attentionBackend:"",maxModelLen:0,maxNumSeqs:256,maxNumBatchedTokens:0,blockSize:0,enableChunkedPrefill:"auto",specMethod:"none",specTokens:0,specDraftModel:"",specDraftTensorParallelSize:0,specNumDraftTokens:0,temperature:1,topP:1,topK:-1,minP:0,seed:-1,repetitionPenalty:1,maxNumSeq:0,trustRemoteCode:!1,enableAutoToolChoice:!1,toolCallParser:"",reasoningParser:"",enablePrefixCaching:"auto",apiKey:"",extraFlags:"",envText:""};function Hy(i,o){let e=S[i];return e===void 0?!1:String(o)!==String(e)}var Uy="^[a-zA-Z][a-zA-Z0-9_-]{0,127}$",Gy=["auto","half","bfloat16","float","float16","float32"],$y=["TRITON_ATTN","ROCM_ATTN","ROCM_SEGMENTED_ATTN","FLASH_ATTN","FLASHINFER","TRITON_MLA","FLASHMLA","FLEX_ATTENTION","TORCH_SDPA","TREE_ATTN","XFORMERS"],Wy=[{value:"none",label:"none"},{value:"ngram",label:"ngram"},{value:"eagle",label:"eagle"},{value:"eagle3",label:"eagle3"},{value:"medusa",label:"medusa"},{value:"mlp_speculator",label:"mlp_speculator"},{value:"draft_model",label:"draft_model"},{value:"mtp",label:"mtp"},{value:"qwen3_5_mtp",label:"qwen3_5_mtp"},{value:"qwen3_next_mtp",label:"qwen3_next_mtp"},{value:"deepseek_mtp",label:"deepseek_mtp"}],qy=["","hermes","mistral","llama3_json","qwen3_xml","qwen25_tool_call","phi4_mini_json","pythonic","internlm","glm45","step3","minimax_m2"],Ky=["","deepseek_r1","qwen3","granite","phi4_reasoning","glm45","step3","minimax_m2"],Mp=(()=>{class i{constructor(){this.fb=d(un),this.dialogRef=d(gt),this.data=d(Gn),this.serviceService=d(_t),this.cdr=d(te),this.destroyRef=d(Bt),this.isEdit=this.data.config!==null,this.isClone=this.data.clone===!0,this.dtypeOptions=Gy,this.attentionBackends=$y,this.specMethods=Wy,this.toolCallParsers=qy,this.reasoningParsers=Ky,this.allExistingCommands=W(()=>{let e=this.data.allConfigs??[],t=this.data.config?.name??null,n=new Set,a=[];for(let r of e)r.name!==t&&(n.has(r.command)||(n.add(r.command),a.push({command:r.command,from:r.name})));return a}),this._commandValue=R(this.data.config?.command??""),this.commandValue=this._commandValue.asReadonly(),this.filteredCommands=W(()=>{let e=this.commandValue()?.toLowerCase()??"";return this.allExistingCommands().filter(t=>t.command.toLowerCase().includes(e)||t.from.toLowerCase().includes(e))}),this.form=this.fb.group({name:[this.data.config?.name??"",{validators:[st.required,st.pattern(Uy)]}],command:[this.data.config?.command??"",st.required],host:[S.host],port:[S.port],servedModelName:[S.servedModelName],model:[S.model],tokenizer:[S.tokenizer],dtype:[S.dtype],tensorParallelSize:[S.tensorParallelSize],pipelineParallelSize:[S.pipelineParallelSize],maxParallelLoadingWorkers:[S.maxParallelLoadingWorkers],gpuMemoryUtilization:[S.gpuMemoryUtilization],swapSpace:[S.swapSpace],cpuOffloadGb:[S.cpuOffloadGb],kvCacheMemory:[S.kvCacheMemory],device:[S.device],attentionBackend:[S.attentionBackend],maxModelLen:[S.maxModelLen],maxNumSeqs:[S.maxNumSeqs],maxNumBatchedTokens:[S.maxNumBatchedTokens],blockSize:[S.blockSize],enableChunkedPrefill:[S.enableChunkedPrefill],specMethod:[S.specMethod],specTokens:[S.specTokens],specDraftModel:[S.specDraftModel],specDraftTensorParallelSize:[S.specDraftTensorParallelSize],specNumDraftTokens:[S.specNumDraftTokens],temperature:[S.temperature],topP:[S.topP],topK:[S.topK],minP:[S.minP],seed:[S.seed],repetitionPenalty:[S.repetitionPenalty],maxNumSeq:[S.maxNumSeq],trustRemoteCode:[S.trustRemoteCode],enableAutoToolChoice:[S.enableAutoToolChoice],toolCallParser:[S.toolCallParser],reasoningParser:[S.reasoningParser],enablePrefixCaching:[S.enablePrefixCaching],apiKey:[S.apiKey],extraFlags:[S.extraFlags],envText:[S.envText]}),this.filteredHosts=qn(this.form.controls.host.valueChanges.pipe(qi(),ke(this.form.controls.host.value),Vt(250),xi(),We(e=>{let t=(e??"").trim();return t?this.serviceService.getLlamaAutocomplete("host",t).pipe(Kt(()=>ge([]))):ge([])})),{initialValue:[]}),this.existingModelPaths=W(()=>this.extractConfigModelPaths()),this.formValue=qn(this.form.valueChanges,{initialValue:this.form.value}),this.specMethodValue=W(()=>this.formValue()?.specMethod),this.showSpecDraftParams=W(()=>{let e=this.specMethodValue();return e!=="none"&&e!=="ngram"}),this.isToolCallParserDisabled=W(()=>!this.formValue()?.enableAutoToolChoice)}extractConfigModelPaths(){let e=this.data.allConfigs??[],t=this.data.config?.name??null,n=new Set,a=[];for(let r of e){if(r.name===t||!r.flags)continue;let u=No(r.flags,"serve");u&&!n.has(u)&&(n.add(u),a.push(u))}return a}isControlChanged(e){let t=this.form.get(e)?.value;return t!=null&&Hy(e,t)}isSectionChanged(...e){return e.some(t=>this.isControlChanged(t))}ngOnInit(){this.form.controls.command.valueChanges.pipe(qi(this.destroyRef)).subscribe(e=>this._commandValue.set(e)),this.data.config&&this.populateForm(this.data.config),this.form.valueChanges.pipe(qi(this.destroyRef)).subscribe(()=>{this.cdr.markForCheck()})}populateForm(e){let t=this.form.controls,n=e.flags,a=No(n,"serve")??"";if(t.model.setValue(a),t.host.setValue(si(n,"--host",S.host)),t.port.setValue(At(n,"--port",S.port)),t.servedModelName.setValue(si(n,"--served-model-name","")),t.tokenizer.setValue(si(n,"--tokenizer","")),t.dtype.setValue(si(n,"--dtype",S.dtype)),t.tensorParallelSize.setValue(At(n,"--tensor-parallel-size",S.tensorParallelSize)),t.pipelineParallelSize.setValue(At(n,"--pipeline-parallel-size",S.pipelineParallelSize)),t.maxParallelLoadingWorkers.setValue(At(n,"--max-parallel-loading-workers",S.maxParallelLoadingWorkers)),t.gpuMemoryUtilization.setValue(Kn(n,"--gpu-memory-utilization",S.gpuMemoryUtilization)),t.swapSpace.setValue(Kn(n,"--swap-space",S.swapSpace)),t.cpuOffloadGb.setValue(Kn(n,"--cpu-offload-gb",S.cpuOffloadGb)),t.kvCacheMemory.setValue(At(n,"--kv-cache-memory-bytes",S.kvCacheMemory)),t.device.setValue(si(n,"--device","")),t.attentionBackend.setValue(si(n,"--attention-backend",S.attentionBackend)),t.maxModelLen.setValue(At(n,"--max-model-len",S.maxModelLen)),t.maxNumSeqs.setValue(At(n,"--max-num-seqs",S.maxNumSeqs)),t.maxNumBatchedTokens.setValue(At(n,"--max-num-batched-tokens",S.maxNumBatchedTokens)),t.blockSize.setValue(At(n,"--block-size",S.blockSize)),t.enableChunkedPrefill.setValue(Yy(n,"--enable-chunked-prefill","--no-enable-chunked-prefill",S.enableChunkedPrefill)),t.specMethod.setValue(si(n,"--spec-method",S.specMethod)),t.specTokens.setValue(At(n,"--spec-tokens",S.specTokens)),t.specDraftModel.setValue(si(n,"--spec-draft-model","")),t.specDraftTensorParallelSize.setValue(At(n,"--spec-draft-tensor-parallel-size",S.specDraftTensorParallelSize)),t.specNumDraftTokens.setValue(At(n,"--num-spec-tokens",S.specNumDraftTokens)),t.temperature.setValue(Kn(n,"--temperature",S.temperature)),t.topP.setValue(Kn(n,"--top-p",S.topP)),t.topK.setValue(At(n,"--top-k",S.topK)),t.minP.setValue(Kn(n,"--min-p",S.minP)),t.seed.setValue(At(n,"--seed",S.seed)),t.repetitionPenalty.setValue(Kn(n,"--repetition-penalty",S.repetitionPenalty)),t.maxNumSeq.setValue(At(n,"--max-num-seq",S.maxNumSeq)),t.trustRemoteCode.setValue(n.some(r=>r.split(/\s|=/)[0]==="--trust-remote-code")),t.enableAutoToolChoice.setValue(n.some(r=>r.split(/\s|=/)[0]==="--enable-auto-tool-choice")),t.toolCallParser.setValue(si(n,"--tool-call-parser","")),t.reasoningParser.setValue(si(n,"--reasoning-parser","")),t.enablePrefixCaching.setValue(si(n,"--enable-prefix-caching",S.enablePrefixCaching)),t.apiKey.setValue(si(n,"--api-key","")),t.extraFlags.setValue(this.extractExtraFlags(n).join(`
5590
+ HSA_OVERRIDE_GFX_VERSION=11.0.0`,"matTooltip","Environment variables for the service process (KEY=VALUE, one per line)",1,"env-textarea"],["align","end"],["mat-stroked-button","",3,"click"],["mat-raised-button","","color","primary",3,"click","disabled"],[1,"auto-path"],[1,"auto-from"],["matInput","","formControlName","yarnOrigCtx","type","number","matTooltip","YaRN: original context size of model. 0 = model training context size"],["matInput","","formControlName","yarnExtFactor","type","number","matTooltip","YaRN: extrapolation mix factor. -1 = default, 0.0 = full interpolation"],["matInput","","formControlName","yarnAttnFactor","type","number","matTooltip","YaRN: scale sqrt(t) or attention magnitude. -1 = default"],["matInput","","formControlName","yarnBetaSlow","type","number","matTooltip","YaRN: high correction dim (alpha). -1 = default"],["matInput","","formControlName","yarnBetaFast","type","number","matTooltip","YaRN: low correction dim (beta). -1 = default"],["formControlName","modelDraft","label","Draft Model Path","placeholder","/path/to/draft-model.gguf",3,"existingPaths","fieldClass"],["formControlName","specDraftDevice","multiple","","placeholder","Select GPU devices for draft model","matTooltip","Devices for offloading the draft model. Same options as main --device"],["matInput","","formControlName","specDraftNMax","type","number","matTooltip","Max number of tokens to draft for speculative decoding. Default: 3"],["matInput","","formControlName","nGpuLayersDraft","type","number","matTooltip","Max draft model layers to store in VRAM. 999 = all layers"],["formControlName","specDraftCacheTypeK","matTooltip","KV cache data type for K for the draft model"],["formControlName","specDraftCacheTypeV","matTooltip","KV cache data type for V for the draft model"],["matInput","","formControlName","specNgramModNMin","type","number","matTooltip","Min number of ngram tokens for ngram-mod speculative decoding. Default: 48"],["matInput","","formControlName","specNgramModNMax","type","number","matTooltip","Max number of ngram tokens for ngram-mod speculative decoding. Default: 64"],["matInput","","formControlName","specNgramModNMatch","type","number","matTooltip","Ngram-mod lookup length. Default: 24"],["matInput","","formControlName","specNgramSimpleSizeN","type","number","matTooltip","Ngram size N for ngram-simple: length of lookup n-gram. Default: 12"],["matInput","","formControlName","specNgramSimpleSizeM","type","number","matTooltip","Ngram size M for ngram-simple: length of draft m-gram. Default: 48"],["matInput","","formControlName","specNgramSimpleMinHits","type","number","matTooltip","Minimum hits for ngram-simple speculative decoding. Default: 1"]],template:function(t,n){if(t&1&&(s(0,"h2",3),m(1),l(),s(2,"mat-dialog-content")(3,"form",4)(4,"mat-form-field",5),v(5,"input",6),b(),s(6,"mat-label"),m(7,"Service Name"),l(),M(8,ry,2,0,"mat-error")(9,sy,2,0,"mat-error"),l(),s(10,"mat-form-field",5),v(11,"input",7),b(),s(12,"mat-label"),m(13,"Binary Path"),l(),M(14,ly,2,0,"mat-error"),l(),s(15,"mat-autocomplete",null,0),me(17,cy,5,3,"mat-option",8,oy),l(),s(19,"mat-expansion-panel",9)(20,"mat-expansion-panel-header")(21,"mat-panel-title"),m(22,"Model"),l()(),v(23,"app-file-autocomplete",10),b(),v(24,"app-file-autocomplete",11),b(),s(25,"mat-form-field",5),v(26,"input",12),b(),s(27,"mat-label"),m(28,"Model Alias"),l()()(),s(29,"mat-expansion-panel",9)(30,"mat-expansion-panel-header")(31,"mat-panel-title"),m(32,"GPU & Memory"),l()(),s(33,"div",13)(34,"mat-form-field",14),v(35,"input",15),b(),s(36,"mat-label"),m(37,"GPU Layers"),l()(),s(38,"mat-form-field",16)(39,"mat-select",17),me(40,dy,2,2,"mat-option",8,Hc),l(),b(),s(42,"mat-label"),m(43,"Device (multi-select)"),l()()(),s(44,"div",13)(45,"mat-form-field",18)(46,"mat-select",19)(47,"mat-option",20),m(48,"layer (pipelined)"),l(),s(49,"mat-option",21),m(50,"row (parallelized)"),l(),s(51,"mat-option",22),m(52,"tensor (experimental)"),l(),s(53,"mat-option",23),m(54,"none (single GPU)"),l()(),b(),s(55,"mat-label"),m(56,"Split Mode"),l()(),s(57,"mat-form-field",18),v(58,"input",24),b(),s(59,"mat-label"),m(60,"Tensor Split"),l()(),s(61,"mat-form-field",18),v(62,"input",25),b(),s(63,"mat-label"),m(64,"Main GPU"),l()()(),s(65,"div",26),m(66,"Memory"),l(),s(67,"div",13)(68,"mat-form-field",18)(69,"mat-select",27)(70,"mat-option",28),m(71,"on"),l(),s(72,"mat-option",29),m(73,"off"),l()(),b(),s(74,"mat-label"),m(75,"Fit to VRAM"),l()(),s(76,"mat-form-field",18),v(77,"input",30),b(),s(78,"mat-label"),m(79,"Fit Target (MiB)"),l()(),s(80,"mat-form-field",18),v(81,"input",31),b(),s(82,"mat-label"),m(83,"Fit Min Ctx"),l()()(),s(84,"div",13)(85,"mat-form-field",18)(86,"mat-select",32)(87,"mat-option",28),m(88,"on"),l(),s(89,"mat-option",29),m(90,"off"),l()(),b(),s(91,"mat-label"),m(92,"mlock (pin RAM)"),l()(),s(93,"mat-form-field",18)(94,"mat-select",33)(95,"mat-option",28),m(96,"on"),l(),s(97,"mat-option",29),m(98,"off"),l()(),b(),s(99,"mat-label"),m(100,"mmap"),l()(),s(101,"mat-form-field",18)(102,"mat-select",34)(103,"mat-option",28),m(104,"on"),l(),s(105,"mat-option",29),m(106,"off"),l()(),b(),s(107,"mat-label"),m(108,"CPU MoE"),l()(),s(109,"mat-form-field",18),v(110,"input",35),b(),s(111,"mat-label"),m(112,"N CPU MoE Layers"),l()()()(),s(113,"mat-expansion-panel")(114,"mat-expansion-panel-header")(115,"mat-panel-title"),m(116,"Context & KV Cache"),l()(),s(117,"div",13)(118,"mat-form-field",18)(119,"input",36),A("blur",function(r){return n.onCtxSizeInput(r)})("keyup.enter",function(r){return n.onCtxSizeInput(r)}),l(),b(),s(120,"mat-label"),m(121,"Context Size"),l()(),s(122,"mat-autocomplete",null,1),me(124,my,2,2,"mat-option",8,ay),l(),s(126,"mat-form-field",18),v(127,"input",37),b(),s(128,"mat-label"),m(129,"Batch Size"),l()(),s(130,"mat-form-field",18),v(131,"input",38),b(),s(132,"mat-label"),m(133,"Ubatch Size"),l()()(),s(134,"div",13)(135,"mat-form-field",18)(136,"mat-select",39),me(137,uy,2,2,"mat-option",8,xt),l(),b(),s(139,"mat-label"),m(140,"KV Cache Type K"),l()(),s(141,"mat-form-field",18)(142,"mat-select",40),me(143,hy,2,2,"mat-option",8,xt),l(),b(),s(145,"mat-label"),m(146,"KV Cache Type V"),l()(),s(147,"mat-form-field",18)(148,"mat-select",41)(149,"mat-option",28),m(150,"on"),l(),s(151,"mat-option",29),m(152,"off"),l()(),b(),s(153,"mat-label"),m(154,"KV Offload"),l()()(),s(155,"div",13)(156,"mat-form-field",18),v(157,"input",42),b(),s(158,"mat-label"),m(159,"Cache RAM (MiB)"),l()(),s(160,"mat-form-field",18)(161,"mat-select",43)(162,"mat-option",28),m(163,"on"),l(),s(164,"mat-option",29),m(165,"off"),l()(),b(),s(166,"mat-label"),m(167,"Full SWA Cache"),l()()()(),s(168,"mat-expansion-panel")(169,"mat-expansion-panel-header")(170,"mat-panel-title"),m(171,"RoPE Scaling"),l()(),s(172,"div",13)(173,"mat-form-field",18)(174,"mat-select",44)(175,"mat-option",23),m(176,"none"),l(),s(177,"mat-option",45),m(178,"linear"),l(),s(179,"mat-option",46),m(180,"yarn"),l()(),b(),s(181,"mat-label"),m(182,"Scaling Method"),l()(),s(183,"mat-form-field",18),v(184,"input",47),b(),s(185,"mat-label"),m(186,"Scale Factor"),l()(),s(187,"mat-form-field",18),v(188,"input",48),b(),s(189,"mat-label"),m(190,"Freq Base"),l()(),s(191,"mat-form-field",18),v(192,"input",49),b(),s(193,"mat-label"),m(194,"Freq Scale"),l()()(),M(195,py,23,10),l(),s(196,"mat-expansion-panel")(197,"mat-expansion-panel-header")(198,"mat-panel-title"),m(199,"Generation"),l(),s(200,"mat-panel-description"),m(201,"Runtime and batching defaults"),l()(),s(202,"div",13)(203,"mat-form-field",18),v(204,"input",50),b(),s(205,"mat-label"),m(206,"Threads"),l()(),s(207,"mat-form-field",18),v(208,"input",51),b(),s(209,"mat-label"),m(210,"Parallel Slots"),l()(),s(211,"mat-form-field",18),v(212,"input",52),b(),s(213,"mat-label"),m(214,"Max Tokens (n-predict)"),l()()(),s(215,"div",13)(216,"mat-form-field",18)(217,"mat-select",53)(218,"mat-option",28),m(219,"on"),l(),s(220,"mat-option",29),m(221,"off"),l(),s(222,"mat-option",54),m(223,"auto"),l()(),b(),s(224,"mat-label"),m(225,"Flash Attention"),l()(),s(226,"mat-form-field",18)(227,"mat-select",55)(228,"mat-option",28),m(229,"on"),l(),s(230,"mat-option",29),m(231,"off"),l()(),b(),s(232,"mat-label"),m(233,"Cont. Batching"),l()(),s(234,"mat-form-field",18)(235,"mat-select",56)(236,"mat-option",28),m(237,"on"),l(),s(238,"mat-option",29),m(239,"off"),l()(),b(),s(240,"mat-label"),m(241,"Context Shift"),l()()()(),s(242,"mat-expansion-panel")(243,"mat-expansion-panel-header")(244,"mat-panel-title"),m(245,"Sampling Defaults"),l(),s(246,"mat-panel-description"),m(247,"Default sampling parameters for generation"),l()(),s(248,"div",26),m(249,"Core"),l(),s(250,"div",13)(251,"mat-form-field",18),v(252,"input",57),b(),s(253,"mat-label"),m(254,"Temperature"),l()(),s(255,"mat-form-field",18),v(256,"input",58),b(),s(257,"mat-label"),m(258,"Seed"),l()(),s(259,"mat-form-field",18),v(260,"input",59),b(),s(261,"mat-label"),m(262,"Top-K"),l()(),s(263,"mat-form-field",18),v(264,"input",60),b(),s(265,"mat-label"),m(266,"Top-P"),l()()(),s(267,"div",13)(268,"mat-form-field",18),v(269,"input",61),b(),s(270,"mat-label"),m(271,"Min-P"),l()(),s(272,"mat-form-field",18),v(273,"input",62),b(),s(274,"mat-label"),m(275,"Typical-P"),l()(),s(276,"mat-form-field",18)(277,"mat-select",63)(278,"mat-option",8),m(279,"disabled"),l(),s(280,"mat-option",8),m(281,"Mirostat"),l(),s(282,"mat-option",8),m(283,"Mirostat 2.0"),l()(),b(),s(284,"mat-label"),m(285,"Mirostat"),l()(),s(286,"mat-form-field",18),v(287,"input",64),b(),s(288,"mat-label"),m(289,"Dyn. Temp Range"),l()()(),s(290,"div",26),m(291,"Penalties"),l(),s(292,"div",13)(293,"mat-form-field",18),v(294,"input",65),b(),s(295,"mat-label"),m(296,"Repeat Last N"),l()(),s(297,"mat-form-field",18),v(298,"input",66),b(),s(299,"mat-label"),m(300,"Repeat Penalty"),l()(),s(301,"mat-form-field",18),v(302,"input",67),b(),s(303,"mat-label"),m(304,"Presence Penalty"),l()(),s(305,"mat-form-field",18),v(306,"input",68),b(),s(307,"mat-label"),m(308,"Frequency Penalty"),l()()(),s(309,"div",26),m(310,"DRY Sampling"),l(),s(311,"div",13)(312,"mat-form-field",18),v(313,"input",69),b(),s(314,"mat-label"),m(315,"DRY Multiplier"),l()(),s(316,"mat-form-field",18),v(317,"input",70),b(),s(318,"mat-label"),m(319,"DRY Base"),l()()()(),s(320,"mat-expansion-panel")(321,"mat-expansion-panel-header")(322,"mat-panel-title"),m(323,"Speculative Decoding"),l(),s(324,"mat-panel-description"),m(325,"Draft model and speculative decoding options"),l()(),s(326,"mat-form-field",71)(327,"mat-select",72)(328,"mat-option",23),m(329,"none"),l(),s(330,"mat-option",73),m(331,"draft-simple"),l(),s(332,"mat-option",74),m(333,"draft-eagle3"),l(),s(334,"mat-option",75),m(335,"draft-mtp"),l(),s(336,"mat-option",76),m(337,"ngram-simple"),l(),s(338,"mat-option",77),m(339,"ngram-mod"),l(),s(340,"mat-option",78),m(341,"draft-mtp,ngram-mod"),l()(),b(),s(342,"mat-label"),m(343,"Spec Type"),l()(),M(344,vy,32,12),M(345,by,15,6),M(346,yy,15,6),l(),s(347,"mat-expansion-panel")(348,"mat-expansion-panel-header")(349,"mat-panel-title"),m(350,"LoRA & Adapters"),l()(),v(351,"app-file-autocomplete",79),b(),s(352,"mat-form-field",5),v(353,"input",80),b(),s(354,"mat-label"),m(355,"LoRA Scaled"),l()()(),s(356,"mat-expansion-panel")(357,"mat-expansion-panel-header")(358,"mat-panel-title"),m(359,"Server & Network"),l()(),s(360,"div",13)(361,"mat-form-field",18),v(362,"input",81),b(),s(363,"mat-label"),m(364,"Host"),l()(),s(365,"mat-autocomplete",null,2),me(367,Cy,5,3,"mat-option",8,Hc),l(),s(369,"mat-form-field",18),v(370,"input",82),b(),s(371,"mat-label"),m(372,"Port"),l()(),s(373,"mat-form-field",18),v(374,"input",83),b(),s(375,"mat-label"),m(376,"Timeout (s)"),l()(),s(377,"mat-form-field",18),v(378,"input",84),b(),s(379,"mat-label"),m(380,"HTTP Threads"),l()()(),v(381,"app-file-autocomplete",85),b(),s(382,"div",13)(383,"mat-form-field",18)(384,"mat-select",86)(385,"mat-option",28),m(386,"on"),l(),s(387,"mat-option",29),m(388,"off"),l()(),b(),s(389,"mat-label"),m(390,"Prometheus Metrics"),l()(),s(391,"mat-form-field",18)(392,"mat-select",87)(393,"mat-option",28),m(394,"on"),l(),s(395,"mat-option",29),m(396,"off"),l()(),b(),s(397,"mat-label"),m(398,"Slots Endpoint"),l()(),s(399,"mat-form-field",18)(400,"mat-select",88)(401,"mat-option",28),m(402,"on"),l(),s(403,"mat-option",29),m(404,"off"),l()(),b(),s(405,"mat-label"),m(406,"Prompt Cache"),l()(),s(407,"mat-form-field",18),v(408,"input",89),b(),s(409,"mat-label"),m(410,"Cache Reuse"),l()()()(),s(411,"mat-expansion-panel")(412,"mat-expansion-panel-header")(413,"mat-panel-title"),m(414,"Reasoning"),l(),s(415,"mat-panel-description"),m(416,"Thinking/reasoning mode settings"),l()(),s(417,"div",13)(418,"mat-form-field",18)(419,"mat-select",90)(420,"mat-option",28),m(421,"on"),l(),s(422,"mat-option",29),m(423,"off"),l(),s(424,"mat-option",54),m(425,"auto"),l()(),b(),s(426,"mat-label"),m(427,"Reasoning"),l()(),s(428,"mat-form-field",18),v(429,"input",91),b(),s(430,"mat-label"),m(431,"Reasoning Budget"),l()(),s(432,"mat-form-field",18)(433,"mat-select",92)(434,"mat-option",54),m(435,"auto"),l(),s(436,"mat-option",23),m(437,"none (raw)"),l(),s(438,"mat-option",93),m(439,"deepseek"),l(),s(440,"mat-option",94),m(441,"deepseek-legacy"),l()(),b(),s(442,"mat-label"),m(443,"Reasoning Format"),l()()()(),s(444,"mat-expansion-panel")(445,"mat-expansion-panel-header")(446,"mat-panel-title"),m(447,"Additional"),l(),s(448,"mat-panel-description"),m(449,"Extra CLI flags and environment variables"),l()(),s(450,"mat-form-field",5),v(451,"textarea",95),b(),s(452,"mat-label"),m(453,"Extra CLI Flags (one per line)"),l()(),s(454,"mat-form-field",5),v(455,"textarea",96),b(),s(456,"mat-label"),m(457,"Environment variables (KEY=VALUE, one per line)"),l()()()()(),s(458,"mat-dialog-actions",97)(459,"button",98),A("click",function(){return n.cancel()}),m(460,"Cancel"),l(),s(461,"button",99),A("click",function(){return n.save()}),m(462),l()()),t&2){let a=Fe(16),r=Fe(123),u=Fe(366);c(),he("",n.isClone?"Clone":n.isEdit?"Edit":"Add"," llama-server service"),c(2),C("formGroup",n.form),c(),p("changed",n.isControlChanged("name")),c(),C("disabled",n.isEdit&&!n.isClone),y(),c(3),E(n.form.controls.name.errors?.required?8:n.form.controls.name.errors?.pattern?9:-1),c(2),p("changed",n.isControlChanged("command")),c(),C("matAutocomplete",a),y(),c(3),E(n.form.controls.command.errors?.required?14:-1),c(3),ue(n.filteredCommands()),c(2),p("has-changed",n.isSectionChanged("model","mmproj","alias")),c(4),C("existingPaths",n.existingModelPaths())("fieldClass",n.isControlChanged("model")?"changed":""),y(),c(),C("existingPaths",n.existingMmprojPaths())("fieldClass",n.isControlChanged("mmproj")?"changed":""),y(),c(),p("changed",n.isControlChanged("alias")),c(),y(),c(3),p("has-changed",n.isSectionChanged("nGpuLayers","device","tensorSplit","splitMode","mainGpu","fit","fitTarget","fitCtx","mlock","mmap","cpuMoe","nCpuMoe")),c(5),p("changed",n.isControlChanged("nGpuLayers")),c(),y(),c(3),p("changed",n.isControlChanged("device")),c(),y(),c(),ue(n.availableDevices()),c(5),p("changed",n.isControlChanged("splitMode")),c(),y(),c(11),p("changed",n.isControlChanged("tensorSplit")&&!n.isTensorSplitDisabled()),c(),C("disabled",n.isTensorSplitDisabled()),y(),c(3),p("changed",n.isControlChanged("mainGpu")),c(),y(),c(6),p("changed",n.isControlChanged("fit")),c(),y(),c(7),p("changed",n.isControlChanged("fitTarget")&&!n.isFitTargetDisabled()),c(),C("disabled",n.isFitTargetDisabled()),y(),c(3),p("changed",n.isControlChanged("fitCtx")&&!n.isFitTargetDisabled()),c(),C("disabled",n.isFitTargetDisabled()),y(),c(4),p("changed",n.isControlChanged("mlock")),c(),y(),c(7),p("changed",n.isControlChanged("mmap")),c(),y(),c(7),p("changed",n.isControlChanged("cpuMoe")),c(),y(),c(7),p("changed",n.isControlChanged("nCpuMoe")&&!n.isCpuMoeLayersDisabled()),c(),C("disabled",n.isCpuMoeLayersDisabled()),y(),c(3),p("has-changed",n.isSectionChanged("ctxSize","batchSize","ubatchSize","cacheTypeK","cacheTypeV","kvOffload","cacheRam","swaFull")),c(5),p("changed",n.isControlChanged("ctxSize")),c(),C("matAutocomplete",r),y(),c(5),ue(n.ctxPresets()),c(2),p("changed",n.isControlChanged("batchSize")),c(),y(),c(3),p("changed",n.isControlChanged("ubatchSize")),c(),y(),c(4),p("changed",n.isControlChanged("cacheTypeK")),c(),y(),c(),ue(n.kvCacheTypes),c(4),p("changed",n.isControlChanged("cacheTypeV")),c(),y(),c(),ue(n.kvCacheTypes),c(4),p("changed",n.isControlChanged("kvOffload")),c(),y(),c(8),p("changed",n.isControlChanged("cacheRam")),c(),y(),c(3),p("changed",n.isControlChanged("swaFull")),c(),y(),c(7),p("has-changed",n.isSectionChanged("ropeScaling","ropeScale","ropeFreqBase","ropeFreqScale","yarnOrigCtx","yarnExtFactor","yarnAttnFactor","yarnBetaSlow","yarnBetaFast")),c(5),p("changed",n.isControlChanged("ropeScaling")),c(),y(),c(9),p("changed",n.isControlChanged("ropeScale")&&!n.isRopeParamsDisabled()),c(),C("disabled",n.isRopeParamsDisabled()),y(),c(3),p("changed",n.isControlChanged("ropeFreqBase")&&!n.isRopeParamsDisabled()),c(),C("disabled",n.isRopeParamsDisabled()),y(),c(3),p("changed",n.isControlChanged("ropeFreqScale")&&!n.isRopeParamsDisabled()),c(),C("disabled",n.isRopeParamsDisabled()),y(),c(3),E(n.showYarnParams()?195:-1),c(),p("has-changed",n.isSectionChanged("threads","parallel","flashAttn","contBatching","contextShift","nPredict")),c(7),p("changed",n.isControlChanged("threads")),c(),y(),c(3),p("changed",n.isControlChanged("parallel")),c(),y(),c(3),p("changed",n.isControlChanged("nPredict")),c(),y(),c(4),p("changed",n.isControlChanged("flashAttn")),c(),y(),c(9),p("changed",n.isControlChanged("contBatching")),c(),y(),c(7),p("changed",n.isControlChanged("contextShift")),c(),y(),c(7),p("has-changed",n.isSectionChanged("temperature","seed","topK","topP","minP","typicalP","mirostat","dynatempRange","repeatLastN","repeatPenalty","presencePenalty","frequencyPenalty","dryMultiplier","dryBase")),c(9),p("changed",n.isControlChanged("temperature")),c(),y(),c(3),p("changed",n.isControlChanged("seed")),c(),y(),c(3),p("changed",n.isControlChanged("topK")&&!n.isMirostatEnabled()),c(),C("disabled",n.isMirostatEnabled()),y(),c(3),p("changed",n.isControlChanged("topP")&&!n.isMirostatEnabled()),c(),C("disabled",n.isMirostatEnabled()),y(),c(4),p("changed",n.isControlChanged("minP")),c(),y(),c(3),p("changed",n.isControlChanged("typicalP")&&!n.isMirostatEnabled()),c(),C("disabled",n.isMirostatEnabled()),y(),c(3),p("changed",n.isControlChanged("mirostat")),c(),y(),c(),C("value",0),c(2),C("value",1),c(2),C("value",2),c(4),p("changed",n.isControlChanged("dynatempRange")),c(),y(),c(6),p("changed",n.isControlChanged("repeatLastN")),c(),y(),c(3),p("changed",n.isControlChanged("repeatPenalty")),c(),y(),c(3),p("changed",n.isControlChanged("presencePenalty")),c(),y(),c(3),p("changed",n.isControlChanged("frequencyPenalty")),c(),y(),c(6),p("changed",n.isControlChanged("dryMultiplier")),c(),y(),c(3),p("changed",n.isControlChanged("dryBase")),c(),y(),c(3),p("has-changed",n.isSectionChanged("modelDraft","specDraftDevice","specDraftNMax","nGpuLayersDraft","specDraftCacheTypeK","specDraftCacheTypeV","specType","specNgramModNMin","specNgramModNMax","specNgramModNMatch","specNgramSimpleSizeN","specNgramSimpleSizeM","specNgramSimpleMinHits")),c(6),p("changed",n.isControlChanged("specType")),c(),y(),c(17),E(n.showDraftParams()?344:-1),c(),E(n.showNgramModParams()?345:-1),c(),E(n.showNgramSimpleParams()?346:-1),c(),p("has-changed",n.isSectionChanged("lora","loraScaled")),c(4),C("existingPaths",n.existingLoraPaths())("fieldClass",n.isControlChanged("lora")?"changed":""),y(),c(),p("changed",n.isControlChanged("loraScaled")),c(),y(),c(3),p("has-changed",n.isSectionChanged("host","port","timeout","threadsHttp","apiKeyFile","metrics","slots","cachePrompt","cacheReuse")),c(5),p("changed",n.isControlChanged("host")),c(),C("matAutocomplete",u),y(),c(5),ue(n.filteredHosts()),c(2),p("changed",n.isControlChanged("port")&&!n.isPortDisabled()),c(),C("disabled",n.isPortDisabled()),y(),c(3),p("changed",n.isControlChanged("timeout")),c(),y(),c(3),p("changed",n.isControlChanged("threadsHttp")),c(),y(),c(3),C("existingPaths",n.existingApiKeyPaths())("fieldClass",n.isControlChanged("apiKeyFile")?"changed":""),y(),c(2),p("changed",n.isControlChanged("metrics")),c(),y(),c(7),p("changed",n.isControlChanged("slots")),c(),y(),c(7),p("changed",n.isControlChanged("cachePrompt")),c(),y(),c(7),p("changed",n.isControlChanged("cacheReuse")&&!n.isCacheReuseDisabled()),c(),C("disabled",n.isCacheReuseDisabled()),y(),c(3),p("has-changed",n.isSectionChanged("reasoning","reasoningBudget","reasoningFormat")),c(7),p("changed",n.isControlChanged("reasoning")),c(),y(),c(9),p("changed",n.isControlChanged("reasoningBudget")&&!n.isReasoningParamsDisabled()),c(),C("disabled",n.isReasoningParamsDisabled()),y(),c(3),p("changed",n.isControlChanged("reasoningFormat")&&!n.isReasoningParamsDisabled()),c(),C("disabled",n.isReasoningParamsDisabled()),y(),c(11),p("has-changed",n.isSectionChanged("extraFlags","envText")),c(6),p("changed",n.isControlChanged("extraFlags")),c(),y(),c(3),p("changed",n.isControlChanged("envText")),c(),y(),c(6),C("disabled",n.form.invalid),c(),he(" ",n.isEdit&&!n.isClone?"Save":"Create"," ")}},dependencies:[Ve,hn,Co,Ei,ya,Ai,mn,pn,Ut,ji,xn,Cn,vt,Wi,Qe,it,Fo,Os,ja,Ts,Rs,Is,St,kt,Ot,fn,ti,ei,Lt,oi,ri,ai,Lo,No,Ps,Ha,Dp],styles:['@charset "UTF-8";.llama-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:8px;min-width:640px}.form-row[_ngcontent-%COMP%]{display:flex;gap:12px;margin-bottom:4px}.form-col[_ngcontent-%COMP%]{flex:1}.form-col-60[_ngcontent-%COMP%]{flex:3}.form-col-40[_ngcontent-%COMP%]{flex:2}.full-width[_ngcontent-%COMP%]{width:100%}.auto-path[_ngcontent-%COMP%]{font-family:monospace}.auto-from[_ngcontent-%COMP%]{margin-left:8px;opacity:.6;font-size:12px}.flags-textarea[_ngcontent-%COMP%], .env-textarea[_ngcontent-%COMP%]{overflow-x:auto}mat-dialog-content[_ngcontent-%COMP%]{padding-top:10px!important;max-height:80vh}mat-expansion-panel[_ngcontent-%COMP%]{margin-bottom:0}mat-dialog-actions[_ngcontent-%COMP%]{gap:8px}.subsection-label[_ngcontent-%COMP%]{font-size:12px;font-weight:500;color:#0009;margin:4px 0 14px;text-transform:uppercase;letter-spacing:.5px}.sub-section-hint[_ngcontent-%COMP%]{font-size:11px;color:#0006;margin-bottom:4px}mat-expansion-panel.has-changed[_ngcontent-%COMP%] mat-panel-title[_ngcontent-%COMP%]{font-weight:700}mat-form-field.changed[_ngcontent-%COMP%] .mat-mdc-form-field-infix input, mat-form-field.changed[_ngcontent-%COMP%] .mat-mdc-form-field-infix .mat-mdc-select{font-weight:700}']})}}return i})();function Vo(i,o){for(let e of i){let t=e.indexOf("=");if(t>0&&e.slice(0,t)===o)return e.slice(t+1);let n=e.indexOf(" ");if(n>0&&e.slice(0,n)===o)return e.slice(n+1).trim()}for(let e=0;e<i.length;e++)if(i[e]===o&&e+1<i.length)return i[e+1];return null}var Sy=(i,o)=>o.command,My=(i,o)=>o.label,Ey=(i,o)=>o.value,Ay=(i,o)=>o.path;function Ty(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function Iy(i,o){i&1&&(s(0,"mat-error"),m(1,"Starts with letter, alphanumeric + hyphens/underscores, max 128 chars"),l())}function Ry(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function Oy(i,o){if(i&1&&(s(0,"mat-option",9)(1,"span",56),m(2),l(),s(3,"span",57),m(4),l()()),i&2){let e=o.$implicit;C("value",e.command),c(2),q(e.command),c(2),he("(",e.from,")")}}function Py(i,o){i&1&&(s(0,"mat-error"),m(1,"Required"),l())}function Fy(i,o){if(i&1&&(s(0,"mat-option",9)(1,"span",56),m(2),l(),s(3,"span",57),m(4,"(existing config)"),l()()),i&2){let e=o.$implicit;C("value",e),c(2),q(e)}}function Ny(i,o){if(i&1&&(s(0,"mat-option",9),m(1),l()),i&2){let e=o.$implicit;C("value",e),c(),q(e)}}function Ly(i,o){if(i&1&&(s(0,"mat-option",9),m(1),l()),i&2){let e=o.$implicit;C("value",e),c(),q(e)}}function Vy(i,o){if(i&1&&(s(0,"mat-option",9),m(1),l()),i&2){let e=o.$implicit;C("value",e.label),c(),q(e.label)}}function By(i,o){if(i&1&&(s(0,"mat-option",9),m(1),l()),i&2){let e=o.$implicit;C("value",e.value),c(),q(e.label)}}function zy(i,o){if(i&1&&(s(0,"div",58),m(1,"Draft Model"),l(),s(2,"div",12)(3,"mat-form-field",59),v(4,"input",60),b(),s(5,"mat-label"),m(6,"Draft Model"),l()(),s(7,"mat-form-field",13),v(8,"input",61),b(),s(9,"mat-label"),m(10,"Draft TP Size"),l()(),s(11,"mat-form-field",13),v(12,"input",62),b(),s(13,"mat-label"),m(14,"Num Spec Tokens"),l()()()),i&2){let e=D();c(3),p("changed",e.isControlChanged("specDraftModel")),c(),y(),c(3),p("changed",e.isControlChanged("specDraftTensorParallelSize")),c(),y(),c(3),p("changed",e.isControlChanged("specNumDraftTokens")),c(),y()}}function jy(i,o){if(i&1&&(s(0,"mat-option",9),m(1),l()),i&2){let e=o.$implicit;C("value",e),c(),q(e||"(none)")}}function Hy(i,o){if(i&1&&(s(0,"mat-option",9),m(1),l()),i&2){let e=o.$implicit;C("value",e),c(),q(e||"(none)")}}function Uy(i,o){if(i&1&&(s(0,"mat-option",9)(1,"span",56),m(2),l(),s(3,"span",57),m(4),l()()),i&2){let e=o.$implicit;C("value",e.path),c(2),q(e.path),c(2),he("(",e.source,")")}}var S={host:"127.0.0.1",port:8e3,servedModelName:"",model:"",tokenizer:"",dtype:"auto",tensorParallelSize:1,pipelineParallelSize:1,maxParallelLoadingWorkers:0,gpuMemoryUtilization:.9,swapSpace:4,cpuOffloadGb:0,kvCacheMemory:0,device:"",attentionBackend:"",maxModelLen:0,maxNumSeqs:256,maxNumBatchedTokens:0,blockSize:0,enableChunkedPrefill:"auto",specMethod:"none",specTokens:0,specDraftModel:"",specDraftTensorParallelSize:0,specNumDraftTokens:0,temperature:1,topP:1,topK:-1,minP:0,seed:-1,repetitionPenalty:1,maxNumSeq:0,trustRemoteCode:!1,enableAutoToolChoice:!1,toolCallParser:"",reasoningParser:"",enablePrefixCaching:"auto",apiKey:"",extraFlags:"",envText:""};function Gy(i,o){let e=S[i];return e===void 0?!1:String(o)!==String(e)}var $y="^[a-zA-Z][a-zA-Z0-9_-]{0,127}$",Wy=["auto","half","bfloat16","float","float16","float32"],qy=["TRITON_ATTN","ROCM_ATTN","ROCM_SEGMENTED_ATTN","FLASH_ATTN","FLASHINFER","TRITON_MLA","FLASHMLA","FLEX_ATTENTION","TORCH_SDPA","TREE_ATTN","XFORMERS"],Ky=[{value:"none",label:"none"},{value:"ngram",label:"ngram"},{value:"eagle",label:"eagle"},{value:"eagle3",label:"eagle3"},{value:"medusa",label:"medusa"},{value:"mlp_speculator",label:"mlp_speculator"},{value:"draft_model",label:"draft_model"},{value:"mtp",label:"mtp"},{value:"qwen3_5_mtp",label:"qwen3_5_mtp"},{value:"qwen3_next_mtp",label:"qwen3_next_mtp"},{value:"deepseek_mtp",label:"deepseek_mtp"}],Yy=["","hermes","mistral","llama3_json","qwen3_xml","qwen25_tool_call","phi4_mini_json","pythonic","internlm","glm45","step3","minimax_m2"],Xy=["","deepseek_r1","qwen3","granite","phi4_reasoning","glm45","step3","minimax_m2"],Mp=(()=>{class i{constructor(){this.fb=d(un),this.dialogRef=d(gt),this.data=d(Wn),this.serviceService=d(_t),this.cdr=d(te),this.destroyRef=d(Bt),this.isEdit=this.data.config!==null,this.isClone=this.data.clone===!0,this.dtypeOptions=Wy,this.attentionBackends=qy,this.specMethods=Ky,this.toolCallParsers=Yy,this.reasoningParsers=Xy,this.allExistingCommands=$(()=>{let e=this.data.allConfigs??[],t=this.data.config?.name??null,n=new Set,a=[];for(let r of e)r.name!==t&&(n.has(r.command)||(n.add(r.command),a.push({command:r.command,from:r.name})));return a}),this._commandValue=R(this.data.config?.command??""),this.commandValue=this._commandValue.asReadonly(),this.filteredCommands=$(()=>{let e=this.commandValue()?.toLowerCase()??"";return this.allExistingCommands().filter(t=>t.command.toLowerCase().includes(e)||t.from.toLowerCase().includes(e))}),this.form=this.fb.group({name:[this.data.config?.name??"",{validators:[st.required,st.pattern($y)]}],command:[this.data.config?.command??"",st.required],host:[S.host],port:[S.port],servedModelName:[S.servedModelName],model:[S.model],tokenizer:[S.tokenizer],dtype:[S.dtype],tensorParallelSize:[S.tensorParallelSize],pipelineParallelSize:[S.pipelineParallelSize],maxParallelLoadingWorkers:[S.maxParallelLoadingWorkers],gpuMemoryUtilization:[S.gpuMemoryUtilization],swapSpace:[S.swapSpace],cpuOffloadGb:[S.cpuOffloadGb],kvCacheMemory:[S.kvCacheMemory],device:[S.device],attentionBackend:[S.attentionBackend],maxModelLen:[""],maxNumSeqs:[S.maxNumSeqs],maxNumBatchedTokens:[S.maxNumBatchedTokens],blockSize:[S.blockSize],enableChunkedPrefill:[S.enableChunkedPrefill],specMethod:[S.specMethod],specTokens:[S.specTokens],specDraftModel:[S.specDraftModel],specDraftTensorParallelSize:[S.specDraftTensorParallelSize],specNumDraftTokens:[S.specNumDraftTokens],temperature:[S.temperature],topP:[S.topP],topK:[S.topK],minP:[S.minP],seed:[S.seed],repetitionPenalty:[S.repetitionPenalty],maxNumSeq:[S.maxNumSeq],trustRemoteCode:[S.trustRemoteCode],enableAutoToolChoice:[S.enableAutoToolChoice],toolCallParser:[S.toolCallParser],reasoningParser:[S.reasoningParser],enablePrefixCaching:[S.enablePrefixCaching],apiKey:[S.apiKey],extraFlags:[S.extraFlags],envText:[S.envText]}),this.filteredHosts=Yn(this.form.controls.host.valueChanges.pipe(qi(),ke(this.form.controls.host.value),Vt(250),xi(),We(e=>{let t=(e??"").trim();return t?this.serviceService.getLlamaAutocomplete("host",t).pipe(Kt(()=>ge([]))):ge([])})),{initialValue:[]}),this.existingModelPaths=$(()=>this.extractConfigModelPaths()),this.maxLenPresets=$(()=>Ua.map(e=>({label:kn(e,1)}))),this.formValue=Yn(this.form.valueChanges,{initialValue:this.form.value}),this.specMethodValue=$(()=>this.formValue()?.specMethod),this.showSpecDraftParams=$(()=>{let e=this.specMethodValue();return e!=="none"&&e!=="ngram"}),this.isToolCallParserDisabled=$(()=>!this.formValue()?.enableAutoToolChoice)}extractConfigModelPaths(){let e=this.data.allConfigs??[],t=this.data.config?.name??null,n=new Set,a=[];for(let r of e){if(r.name===t||!r.flags)continue;let u=Vo(r.flags,"serve");u&&!n.has(u)&&(n.add(u),a.push(u))}return a}onMaxLenInput(){let e=Dn(this.form.get("maxModelLen")?.value??"");this.form.get("maxModelLen")?.setValue(kn(e,1),{emitEvent:!1})}isControlChanged(e){let t=this.form.get(e)?.value;return e==="maxModelLen"?+Dn(t)!==S.maxModelLen:t!=null&&Gy(e,t)}isSectionChanged(...e){return e.some(t=>this.isControlChanged(t))}ngOnInit(){this.form.controls.command.valueChanges.pipe(qi(this.destroyRef)).subscribe(e=>this._commandValue.set(e)),this.data.config&&this.populateForm(this.data.config),this.form.valueChanges.pipe(qi(this.destroyRef)).subscribe(()=>{this.cdr.markForCheck()})}populateForm(e){let t=this.form.controls,n=e.flags,a=Vo(n,"serve")??"";if(t.model.setValue(a),t.host.setValue(si(n,"--host",S.host)),t.port.setValue(At(n,"--port",S.port)),t.servedModelName.setValue(si(n,"--served-model-name","")),t.tokenizer.setValue(si(n,"--tokenizer","")),t.dtype.setValue(si(n,"--dtype",S.dtype)),t.tensorParallelSize.setValue(At(n,"--tensor-parallel-size",S.tensorParallelSize)),t.pipelineParallelSize.setValue(At(n,"--pipeline-parallel-size",S.pipelineParallelSize)),t.maxParallelLoadingWorkers.setValue(At(n,"--max-parallel-loading-workers",S.maxParallelLoadingWorkers)),t.gpuMemoryUtilization.setValue(Xn(n,"--gpu-memory-utilization",S.gpuMemoryUtilization)),t.swapSpace.setValue(Xn(n,"--swap-space",S.swapSpace)),t.cpuOffloadGb.setValue(Xn(n,"--cpu-offload-gb",S.cpuOffloadGb)),t.kvCacheMemory.setValue(At(n,"--kv-cache-memory-bytes",S.kvCacheMemory)),t.device.setValue(si(n,"--device","")),t.attentionBackend.setValue(si(n,"--attention-backend",S.attentionBackend)),t.maxModelLen.setValue(kn(At(n,"--max-model-len",S.maxModelLen),1)),t.maxNumSeqs.setValue(At(n,"--max-num-seqs",S.maxNumSeqs)),t.maxNumBatchedTokens.setValue(At(n,"--max-num-batched-tokens",S.maxNumBatchedTokens)),t.blockSize.setValue(At(n,"--block-size",S.blockSize)),t.enableChunkedPrefill.setValue(Zy(n,"--enable-chunked-prefill","--no-enable-chunked-prefill",S.enableChunkedPrefill)),t.specMethod.setValue(si(n,"--spec-method",S.specMethod)),t.specTokens.setValue(At(n,"--spec-tokens",S.specTokens)),t.specDraftModel.setValue(si(n,"--spec-draft-model","")),t.specDraftTensorParallelSize.setValue(At(n,"--spec-draft-tensor-parallel-size",S.specDraftTensorParallelSize)),t.specNumDraftTokens.setValue(At(n,"--num-spec-tokens",S.specNumDraftTokens)),t.temperature.setValue(Xn(n,"--temperature",S.temperature)),t.topP.setValue(Xn(n,"--top-p",S.topP)),t.topK.setValue(At(n,"--top-k",S.topK)),t.minP.setValue(Xn(n,"--min-p",S.minP)),t.seed.setValue(At(n,"--seed",S.seed)),t.repetitionPenalty.setValue(Xn(n,"--repetition-penalty",S.repetitionPenalty)),t.maxNumSeq.setValue(At(n,"--max-num-seq",S.maxNumSeq)),t.trustRemoteCode.setValue(n.some(r=>r.split(/\s|=/)[0]==="--trust-remote-code")),t.enableAutoToolChoice.setValue(n.some(r=>r.split(/\s|=/)[0]==="--enable-auto-tool-choice")),t.toolCallParser.setValue(si(n,"--tool-call-parser","")),t.reasoningParser.setValue(si(n,"--reasoning-parser","")),t.enablePrefixCaching.setValue(si(n,"--enable-prefix-caching",S.enablePrefixCaching)),t.apiKey.setValue(si(n,"--api-key","")),t.extraFlags.setValue(this.extractExtraFlags(n).join(`
5591
5591
  `)),e.environment){let r=Object.entries(e.environment).map(([u,h])=>`${u}=${h}`).join(`
5592
5592
  `);r&&t.envText.setValue(r+`
5593
- `)}}extractExtraFlags(e){let t=new Set(["--host","--port","--served-model-name","--tokenizer","--dtype","--tensor-parallel-size","--pipeline-parallel-size","--max-parallel-loading-workers","--gpu-memory-utilization","--swap-space","--cpu-offload-gb","--kv-cache-memory-bytes","--device","--attention-backend","--max-model-len","--max-num-seqs","--max-num-batched-tokens","--block-size","--enable-chunked-prefill","--no-enable-chunked-prefill","--spec-method","--spec-tokens","--spec-draft-model","--spec-draft-tensor-parallel-size","--num-spec-tokens","--temperature","--top-p","--top-k","--min-p","--seed","--repetition-penalty","--max-num-seq","--trust-remote-code","--enable-auto-tool-choice","--tool-call-parser","--reasoning-parser","--enable-prefix-caching","--api-key"]),n=[];for(let a of e){let r=a.split(/\s|=/)[0];a.startsWith("--")&&!t.has(r)&&n.push(a)}return n}addIf(e,t,n,a){String(n)!==String(a)&&e.push(`${t} ${n}`)}addTri(e,t,n){t==="on"?e.push(n):t==="off"&&e.push(`--no-${n.slice(2)}`)}buildFlags(){let e=[],t=this.form.controls,n=(t.model.value??"").trim();n&&e.push(`serve ${n}`),this.addIf(e,"--served-model-name",(t.servedModelName.value??"").trim(),S.servedModelName),this.addIf(e,"--host",t.host.value,S.host),this.addIf(e,"--port",t.port.value,S.port),this.addIf(e,"--tokenizer",(t.tokenizer.value??"").trim(),S.tokenizer),this.addIf(e,"--dtype",t.dtype.value,S.dtype),this.addIf(e,"--tensor-parallel-size",t.tensorParallelSize.value,S.tensorParallelSize),this.addIf(e,"--pipeline-parallel-size",t.pipelineParallelSize.value,S.pipelineParallelSize),this.addIf(e,"--max-parallel-loading-workers",t.maxParallelLoadingWorkers.value,S.maxParallelLoadingWorkers),this.addIf(e,"--swap-space",t.swapSpace.value,S.swapSpace),this.addIf(e,"--cpu-offload-gb",t.cpuOffloadGb.value,S.cpuOffloadGb),this.addIf(e,"--device",(t.device.value??"").trim(),S.device),this.addIf(e,"--max-model-len",t.maxModelLen.value,S.maxModelLen),this.addIf(e,"--max-num-seqs",t.maxNumSeqs.value,S.maxNumSeqs),this.addIf(e,"--block-size",t.blockSize.value,S.blockSize);let a=t.specMethod.value;a&&a!==S.specMethod&&(e.push(`--spec-method ${a}`),this.addIf(e,"--spec-tokens",t.specTokens.value,S.specTokens),this.showSpecDraftParams()&&(this.addIf(e,"--spec-draft-model",(t.specDraftModel.value??"").trim(),S.specDraftModel),this.addIf(e,"--spec-draft-tensor-parallel-size",t.specDraftTensorParallelSize.value,S.specDraftTensorParallelSize),this.addIf(e,"--num-spec-tokens",t.specNumDraftTokens.value,S.specNumDraftTokens))),this.addIf(e,"--gpu-memory-utilization",t.gpuMemoryUtilization.value,S.gpuMemoryUtilization),t.trustRemoteCode.value&&e.push("--trust-remote-code"),t.enableAutoToolChoice.value&&e.push("--enable-auto-tool-choice"),this.addIf(e,"--tool-call-parser",t.toolCallParser.value,S.toolCallParser),this.addIf(e,"--reasoning-parser",t.reasoningParser.value,S.reasoningParser),this.addTri(e,t.enableChunkedPrefill.value,"--enable-chunked-prefill"),this.addIf(e,"--attention-backend",t.attentionBackend.value,S.attentionBackend),this.addIf(e,"--max-num-batched-tokens",t.maxNumBatchedTokens.value,S.maxNumBatchedTokens),String(t.kvCacheMemory.value)!==String(S.kvCacheMemory)&&e.push(`--kv-cache-memory-bytes=${t.kvCacheMemory.value}`),this.addIf(e,"--temperature",t.temperature.value,S.temperature),this.addIf(e,"--top-p",t.topP.value,S.topP),this.addIf(e,"--top-k",t.topK.value,S.topK),this.addIf(e,"--min-p",t.minP.value,S.minP),this.addIf(e,"--seed",t.seed.value,S.seed),this.addIf(e,"--repetition-penalty",t.repetitionPenalty.value,S.repetitionPenalty),this.addIf(e,"--max-num-seq",t.maxNumSeq.value,S.maxNumSeq),this.addIf(e,"--enable-prefix-caching",t.enablePrefixCaching.value,S.enablePrefixCaching),this.addIf(e,"--api-key",(t.apiKey.value??"").trim(),S.apiKey);for(let r of t.extraFlags.value.split(`
5593
+ `)}}extractExtraFlags(e){let t=new Set(["--host","--port","--served-model-name","--tokenizer","--dtype","--tensor-parallel-size","--pipeline-parallel-size","--max-parallel-loading-workers","--gpu-memory-utilization","--swap-space","--cpu-offload-gb","--kv-cache-memory-bytes","--device","--attention-backend","--max-model-len","--max-num-seqs","--max-num-batched-tokens","--block-size","--enable-chunked-prefill","--no-enable-chunked-prefill","--spec-method","--spec-tokens","--spec-draft-model","--spec-draft-tensor-parallel-size","--num-spec-tokens","--temperature","--top-p","--top-k","--min-p","--seed","--repetition-penalty","--max-num-seq","--trust-remote-code","--enable-auto-tool-choice","--tool-call-parser","--reasoning-parser","--enable-prefix-caching","--api-key"]),n=[];for(let a of e){let r=a.split(/\s|=/)[0];a.startsWith("--")&&!t.has(r)&&n.push(a)}return n}addIf(e,t,n,a){String(n)!==String(a)&&e.push(`${t} ${n}`)}addTri(e,t,n){t==="on"?e.push(n):t==="off"&&e.push(`--no-${n.slice(2)}`)}buildFlags(){let e=[],t=this.form.controls,n=(t.model.value??"").trim();n&&e.push(`serve ${n}`),this.addIf(e,"--served-model-name",(t.servedModelName.value??"").trim(),S.servedModelName),this.addIf(e,"--host",t.host.value,S.host),this.addIf(e,"--port",t.port.value,S.port),this.addIf(e,"--tokenizer",(t.tokenizer.value??"").trim(),S.tokenizer),this.addIf(e,"--dtype",t.dtype.value,S.dtype),this.addIf(e,"--tensor-parallel-size",t.tensorParallelSize.value,S.tensorParallelSize),this.addIf(e,"--pipeline-parallel-size",t.pipelineParallelSize.value,S.pipelineParallelSize),this.addIf(e,"--max-parallel-loading-workers",t.maxParallelLoadingWorkers.value,S.maxParallelLoadingWorkers),this.addIf(e,"--swap-space",t.swapSpace.value,S.swapSpace),this.addIf(e,"--cpu-offload-gb",t.cpuOffloadGb.value,S.cpuOffloadGb),this.addIf(e,"--device",(t.device.value??"").trim(),S.device),this.addIf(e,"--max-model-len",+Dn(t.maxModelLen.value??""),S.maxModelLen),this.addIf(e,"--max-num-seqs",t.maxNumSeqs.value,S.maxNumSeqs),this.addIf(e,"--block-size",t.blockSize.value,S.blockSize);let a=t.specMethod.value;a&&a!==S.specMethod&&(e.push(`--spec-method ${a}`),this.addIf(e,"--spec-tokens",t.specTokens.value,S.specTokens),this.showSpecDraftParams()&&(this.addIf(e,"--spec-draft-model",(t.specDraftModel.value??"").trim(),S.specDraftModel),this.addIf(e,"--spec-draft-tensor-parallel-size",t.specDraftTensorParallelSize.value,S.specDraftTensorParallelSize),this.addIf(e,"--num-spec-tokens",t.specNumDraftTokens.value,S.specNumDraftTokens))),this.addIf(e,"--gpu-memory-utilization",t.gpuMemoryUtilization.value,S.gpuMemoryUtilization),t.trustRemoteCode.value&&e.push("--trust-remote-code"),t.enableAutoToolChoice.value&&e.push("--enable-auto-tool-choice"),this.addIf(e,"--tool-call-parser",t.toolCallParser.value,S.toolCallParser),this.addIf(e,"--reasoning-parser",t.reasoningParser.value,S.reasoningParser),this.addTri(e,t.enableChunkedPrefill.value,"--enable-chunked-prefill"),this.addIf(e,"--attention-backend",t.attentionBackend.value,S.attentionBackend),this.addIf(e,"--max-num-batched-tokens",t.maxNumBatchedTokens.value,S.maxNumBatchedTokens),String(t.kvCacheMemory.value)!==String(S.kvCacheMemory)&&e.push(`--kv-cache-memory-bytes=${t.kvCacheMemory.value}`),this.addIf(e,"--temperature",t.temperature.value,S.temperature),this.addIf(e,"--top-p",t.topP.value,S.topP),this.addIf(e,"--top-k",t.topK.value,S.topK),this.addIf(e,"--min-p",t.minP.value,S.minP),this.addIf(e,"--seed",t.seed.value,S.seed),this.addIf(e,"--repetition-penalty",t.repetitionPenalty.value,S.repetitionPenalty),this.addIf(e,"--max-num-seq",t.maxNumSeq.value,S.maxNumSeq),this.addIf(e,"--enable-prefix-caching",t.enablePrefixCaching.value,S.enablePrefixCaching),this.addIf(e,"--api-key",(t.apiKey.value??"").trim(),S.apiKey);for(let r of t.extraFlags.value.split(`
5594
5594
  `)){let u=r.trim();u&&u.startsWith("--")&&e.push(u)}return e}parseEnvironment(){let e={};for(let t of this.form.controls.envText.value.split(`
5595
- `)){let n=t.trim();if(!n||n.startsWith("#"))continue;let a=n.indexOf("=");a<=0||(e[n.slice(0,a).trim()]=n.slice(a+1))}return e}save(){if(this.form.invalid)return;let e=this.parseEnvironment(),t=V({name:this.form.controls.name.value.trim(),type:"vllm",command:this.form.controls.command.value.trim(),flags:this.buildFlags()},Object.keys(e).length?{environment:e}:{});this.dialogRef.close(t)}cancel(){this.dialogRef.close()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-vllm-dialog"]],decls:250,vars:105,consts:[["commandAuto","matAutocomplete"],["modelAuto","matAutocomplete"],["hostAuto","matAutocomplete"],["mat-dialog-title",""],[1,"vllm-form",3,"formGroup"],["appearance","outline",1,"full-width"],["matInput","","formControlName","name","placeholder","e.g. vllm-qwen-bf16-4gpu",3,"disabled"],["matInput","","formControlName","command","placeholder","/path/to/vllm/run.sh",3,"matAutocomplete"],[3,"value"],["expanded",""],["matInput","","formControlName","model","placeholder","unsloth/Qwen3.8-27B or /path/to/model","matTooltip","Model to serve. HF repo id or local path. Passed as the positional argument to 'vllm serve'",3,"matAutocomplete"],[1,"form-row"],["appearance","outline",1,"form-col"],["matInput","","formControlName","tokenizer","type","text","matTooltip","Tokenizer path (HF repo id or local). Defaults to the model path"],["formControlName","dtype","matTooltip","Data type for model weights and activations"],["matInput","","formControlName","tensorParallelSize","type","number","matTooltip","Number of tensor-parallel replicas (GPUs sharding each model copy). 1 = single GPU"],["matInput","","formControlName","pipelineParallelSize","type","number","matTooltip","Number of pipeline-parallel replicas (model split in stages across GPU groups)"],["matInput","","formControlName","maxParallelLoadingWorkers","type","number","matTooltip","Max number of parallel workers for safetensors loading. 0 = default"],["matInput","","formControlName","gpuMemoryUtilization","type","number","step","0.05","min","0","max","1","matTooltip","Fraction of GPU memory to reserve for the model and KV cache (0.0\u20131.0)"],["matInput","","formControlName","swapSpace","type","number","matTooltip","CPU offload space per GPU (GiB)"],["matInput","","formControlName","cpuOffloadGb","type","number","matTooltip","Space to offload model weights to CPU (GiB). 0 = disabled"],["matInput","","formControlName","device","type","text","placeholder","auto","matTooltip","Device(s) for vLLM execution, e.g. 'auto', 'cuda:0,1' or 'rocm'"],["formControlName","attentionBackend","matTooltip","Attention kernel backend override. TRITON_ATTN is the tested choice on ROCm (4x RX 7900 XTX). Empty = auto"],["value",""],["matInput","","formControlName","kvCacheMemory","type","number","matTooltip","Explicit KV cache size in bytes. 0 = auto (derived from GPU memory utilization)"],["matInput","","formControlName","maxModelLen","type","number","matTooltip","Model context length. 0 = model's max. Large values need more KV cache"],["matInput","","formControlName","maxNumSeqs","type","number","matTooltip","Maximum number of sequences per iteration (concurrent requests)"],["formControlName","enableChunkedPrefill","matTooltip","Split long prompts into chunks for continuous batching. auto = decided by vLLM"],["value","auto"],["value","on"],["value","off"],["matInput","","formControlName","maxNumBatchedTokens","type","number","matTooltip","Max number of tokens per batch (prefill+decode budget). 0 = default"],["matInput","","formControlName","blockSize","type","number","matTooltip","Token block size for the paged KV cache. 0 = default (platform-specific)"],["formControlName","specMethod","matTooltip","Speculative decoding method. draft-model variants use a separate draft model"],["matInput","","formControlName","specTokens","type","number","matTooltip","Number of speculative tokens (proposal length). 0 = method default"],["matInput","","formControlName","temperature","type","number","matTooltip","Default temperature. 1.0 = default"],["matInput","","formControlName","topP","type","number","step","0.05","matTooltip","Nucleus sampling. 1.0 = default"],["matInput","","formControlName","topK","type","number","matTooltip","Top-K sampling. -1 = disabled (default)"],["matInput","","formControlName","minP","type","number","step","0.05","matTooltip","Min-P sampling threshold. 0.0 = disabled (default)"],["matInput","","formControlName","seed","type","number","matTooltip","RNG seed. -1 = random (default)"],["matInput","","formControlName","repetitionPenalty","type","number","step","0.05","matTooltip","Penalty for repeating tokens. 1.0 = disabled (default)"],["matInput","","formControlName","maxNumSeq","type","number","matTooltip","Maximum number of tokens per sequence. 0 = model default"],["formControlName","trustRemoteCode"],["formControlName","enableAutoToolChoice"],["formControlName","toolCallParser","matTooltip","Parser for tool calls. Requires --enable-auto-tool-choice",3,"disabled"],["formControlName","reasoningParser","matTooltip","Parser separating reasoning content from final content in chat completions"],["formControlName","enablePrefixCaching","matTooltip","Cache prefixes of prompts to speed up repeated requests. auto = decided by vLLM"],["matInput","","formControlName","host","type","text","matTooltip","IP address to listen (default: 127.0.0.1)",3,"matAutocomplete"],["matInput","","formControlName","port","type","number","matTooltip","Port to listen (default: 8000)"],["matInput","","formControlName","apiKey","type","text","matTooltip","API key for authentication. Leave empty if the launcher adds it itself (e.g. run.sh reads keys.ini)"],["matInput","","formControlName","extraFlags","rows","4","wrap","off","placeholder",`--enforce-eager
5595
+ `)){let n=t.trim();if(!n||n.startsWith("#"))continue;let a=n.indexOf("=");a<=0||(e[n.slice(0,a).trim()]=n.slice(a+1))}return e}save(){if(this.form.invalid)return;let e=this.parseEnvironment(),t=V({name:this.form.controls.name.value.trim(),type:"vllm",command:this.form.controls.command.value.trim(),flags:this.buildFlags()},Object.keys(e).length?{environment:e}:{});this.dialogRef.close(t)}cancel(){this.dialogRef.close()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-vllm-dialog"]],decls:254,vars:106,consts:[["commandAuto","matAutocomplete"],["modelAuto","matAutocomplete"],["maxLenAuto","matAutocomplete"],["hostAuto","matAutocomplete"],["mat-dialog-title",""],[1,"vllm-form",3,"formGroup"],["appearance","outline",1,"full-width"],["matInput","","formControlName","name","placeholder","e.g. vllm-qwen-bf16-4gpu",3,"disabled"],["matInput","","formControlName","command","placeholder","/path/to/vllm/run.sh",3,"matAutocomplete"],[3,"value"],["expanded",""],["matInput","","formControlName","model","placeholder","unsloth/Qwen3.8-27B or /path/to/model","matTooltip","Model to serve. HF repo id or local path. Passed as the positional argument to 'vllm serve'",3,"matAutocomplete"],[1,"form-row"],["appearance","outline",1,"form-col"],["matInput","","formControlName","tokenizer","type","text","matTooltip","Tokenizer path (HF repo id or local). Defaults to the model path"],["formControlName","dtype","matTooltip","Data type for model weights and activations"],["matInput","","formControlName","tensorParallelSize","type","number","matTooltip","Number of tensor-parallel replicas (GPUs sharding each model copy). 1 = single GPU"],["matInput","","formControlName","pipelineParallelSize","type","number","matTooltip","Number of pipeline-parallel replicas (model split in stages across GPU groups)"],["matInput","","formControlName","maxParallelLoadingWorkers","type","number","matTooltip","Max number of parallel workers for safetensors loading. 0 = default"],["matInput","","formControlName","gpuMemoryUtilization","type","number","step","0.05","min","0","max","1","matTooltip","Fraction of GPU memory to reserve for the model and KV cache (0.0\u20131.0)"],["matInput","","formControlName","swapSpace","type","number","matTooltip","CPU offload space per GPU (GiB)"],["matInput","","formControlName","cpuOffloadGb","type","number","matTooltip","Space to offload model weights to CPU (GiB). 0 = disabled"],["matInput","","formControlName","device","type","text","placeholder","auto","matTooltip","Device(s) for vLLM execution, e.g. 'auto', 'cuda:0,1' or 'rocm'"],["formControlName","attentionBackend","matTooltip","Attention kernel backend override. TRITON_ATTN is the tested choice on ROCm (4x RX 7900 XTX). Empty = auto"],["value",""],["matInput","","formControlName","kvCacheMemory","type","number","matTooltip","Explicit KV cache size in bytes. 0 = auto (derived from GPU memory utilization)"],["matInput","","formControlName","maxModelLen","type","text","placeholder","e.g. 24K, 262144","matTooltip","Model context length. Supports: 20000, 20K. Empty = model's max. Large values need more KV cache",3,"blur","keyup.enter","matAutocomplete"],["matInput","","formControlName","maxNumSeqs","type","number","matTooltip","Maximum number of sequences per iteration (concurrent requests)"],["formControlName","enableChunkedPrefill","matTooltip","Split long prompts into chunks for continuous batching. auto = decided by vLLM"],["value","auto"],["value","on"],["value","off"],["matInput","","formControlName","maxNumBatchedTokens","type","number","matTooltip","Max number of tokens per batch (prefill+decode budget). 0 = default"],["matInput","","formControlName","blockSize","type","number","matTooltip","Token block size for the paged KV cache. 0 = default (platform-specific)"],["formControlName","specMethod","matTooltip","Speculative decoding method. draft-model variants use a separate draft model"],["matInput","","formControlName","specTokens","type","number","matTooltip","Number of speculative tokens (proposal length). 0 = method default"],["matInput","","formControlName","temperature","type","number","matTooltip","Default temperature. 1.0 = default"],["matInput","","formControlName","topP","type","number","step","0.05","matTooltip","Nucleus sampling. 1.0 = default"],["matInput","","formControlName","topK","type","number","matTooltip","Top-K sampling. -1 = disabled (default)"],["matInput","","formControlName","minP","type","number","step","0.05","matTooltip","Min-P sampling threshold. 0.0 = disabled (default)"],["matInput","","formControlName","seed","type","number","matTooltip","RNG seed. -1 = random (default)"],["matInput","","formControlName","repetitionPenalty","type","number","step","0.05","matTooltip","Penalty for repeating tokens. 1.0 = disabled (default)"],["matInput","","formControlName","maxNumSeq","type","number","matTooltip","Maximum number of tokens per sequence. 0 = model default"],["formControlName","trustRemoteCode"],["formControlName","enableAutoToolChoice"],["formControlName","toolCallParser","matTooltip","Parser for tool calls. Requires --enable-auto-tool-choice",3,"disabled"],["formControlName","reasoningParser","matTooltip","Parser separating reasoning content from final content in chat completions"],["formControlName","enablePrefixCaching","matTooltip","Cache prefixes of prompts to speed up repeated requests. auto = decided by vLLM"],["matInput","","formControlName","host","type","text","matTooltip","IP address to listen (default: 127.0.0.1)",3,"matAutocomplete"],["matInput","","formControlName","port","type","number","matTooltip","Port to listen (default: 8000)"],["matInput","","formControlName","apiKey","type","text","matTooltip","API key for authentication. Leave empty if the launcher adds it itself (e.g. run.sh reads keys.ini)"],["matInput","","formControlName","extraFlags","rows","4","wrap","off","placeholder",`--enforce-eager
5596
5596
  --disable-log-requests`,"matTooltip","Any vLLM flags not covered by the fields above (one per line). Pass-through \u2014 not validated",1,"flags-textarea"],["matInput","","formControlName","envText","rows","4","wrap","off","placeholder",`HF_TOKEN=hf_xxx
5597
- HIP_VISIBLE_DEVICES=0,1,2,3`,"matTooltip","Environment variables for the service process (KEY=VALUE, one per line)",1,"env-textarea"],["align","end"],["mat-stroked-button","",3,"click"],["mat-raised-button","","color","primary",3,"click","disabled"],[1,"auto-path"],[1,"auto-from"],[1,"subsection-label"],["appearance","outline",1,"form-col-60"],["matInput","","formControlName","specDraftModel","type","text","placeholder","/path/to/draft-model or HF repo id","matTooltip","Draft model for speculative decoding (draft-model methods)"],["matInput","","formControlName","specDraftTensorParallelSize","type","number","matTooltip","Tensor parallel size of the draft model. 0 = same as main model"],["matInput","","formControlName","specNumDraftTokens","type","number","matTooltip","Number of tokens the draft model proposes in one step. 0 = default"]],template:function(t,n){if(t&1&&(s(0,"h2",3),m(1),l(),s(2,"mat-dialog-content")(3,"form",4)(4,"mat-form-field",5),v(5,"input",6),b(),s(6,"mat-label"),m(7,"Service Name"),l(),M(8,Ay,2,0,"mat-error")(9,Ty,2,0,"mat-error"),l(),s(10,"mat-form-field",5),v(11,"input",7),b(),s(12,"mat-label"),m(13,"Command (launcher or binary)"),l(),M(14,Iy,2,0,"mat-error"),l(),s(15,"mat-autocomplete",null,0),me(17,Ry,5,3,"mat-option",8,Sy),l(),s(19,"mat-expansion-panel",9)(20,"mat-expansion-panel-header")(21,"mat-panel-title"),m(22,"Model"),l()(),s(23,"mat-form-field",5),v(24,"input",10),b(),s(25,"mat-label"),m(26,"Model (serve)"),l(),M(27,Oy,2,0,"mat-error"),l(),s(28,"mat-autocomplete",null,1),me(30,Py,5,2,"mat-option",8,xt),l(),s(32,"div",11)(33,"mat-form-field",12),v(34,"input",13),b(),s(35,"mat-label"),m(36,"Tokenizer"),l()(),s(37,"mat-form-field",12)(38,"mat-select",14),me(39,Fy,2,2,"mat-option",8,xt),l(),b(),s(41,"mat-label"),m(42,"Dtype"),l()()()(),s(43,"mat-expansion-panel")(44,"mat-expansion-panel-header")(45,"mat-panel-title"),m(46,"Parallelism & Memory"),l()(),s(47,"div",11)(48,"mat-form-field",12),v(49,"input",15),b(),s(50,"mat-label"),m(51,"Tensor Parallel Size"),l()(),s(52,"mat-form-field",12),v(53,"input",16),b(),s(54,"mat-label"),m(55,"Pipeline Parallel Size"),l()(),s(56,"mat-form-field",12),v(57,"input",17),b(),s(58,"mat-label"),m(59,"Loading Workers"),l()()(),s(60,"div",11)(61,"mat-form-field",12),v(62,"input",18),b(),s(63,"mat-label"),m(64,"GPU Memory Utilization"),l()(),s(65,"mat-form-field",12),v(66,"input",19),b(),s(67,"mat-label"),m(68,"Swap Space (GiB)"),l()(),s(69,"mat-form-field",12),v(70,"input",20),b(),s(71,"mat-label"),m(72,"CPU Offload (GiB)"),l()(),s(73,"mat-form-field",12),v(74,"input",21),b(),s(75,"mat-label"),m(76,"Device"),l()()(),s(77,"div",11)(78,"mat-form-field",12)(79,"mat-select",22)(80,"mat-option",23),m(81,"(auto)"),l(),me(82,Ny,2,2,"mat-option",8,xt),l(),b(),s(84,"mat-label"),m(85,"Attention Backend"),l()(),s(86,"mat-form-field",12),v(87,"input",24),b(),s(88,"mat-label"),m(89,"KV Cache Memory (bytes)"),l()()()(),s(90,"mat-expansion-panel")(91,"mat-expansion-panel-header")(92,"mat-panel-title"),m(93,"Context & Scheduling"),l()(),s(94,"div",11)(95,"mat-form-field",12),v(96,"input",25),b(),s(97,"mat-label"),m(98,"Max Model Len"),l()(),s(99,"mat-form-field",12),v(100,"input",26),b(),s(101,"mat-label"),m(102,"Max Num Seqs"),l()(),s(103,"mat-form-field",12)(104,"mat-select",27)(105,"mat-option",28),m(106,"auto"),l(),s(107,"mat-option",29),m(108,"on"),l(),s(109,"mat-option",30),m(110,"off"),l()(),b(),s(111,"mat-label"),m(112,"Chunked Prefill"),l()()(),s(113,"div",11)(114,"mat-form-field",12),v(115,"input",31),b(),s(116,"mat-label"),m(117,"Max Batched Tokens"),l()(),s(118,"mat-form-field",12),v(119,"input",32),b(),s(120,"mat-label"),m(121,"Block Size"),l()()()(),s(122,"mat-expansion-panel")(123,"mat-expansion-panel-header")(124,"mat-panel-title"),m(125,"Speculative Decoding"),l(),s(126,"mat-panel-description"),m(127,"Draft method and speculative options"),l()(),s(128,"div",11)(129,"mat-form-field",12)(130,"mat-select",33),me(131,Ly,2,2,"mat-option",8,My),l(),b(),s(133,"mat-label"),m(134,"Spec Method"),l()(),s(135,"mat-form-field",12),v(136,"input",34),b(),s(137,"mat-label"),m(138,"Spec Tokens"),l()()(),M(139,Vy,15,6),l(),s(140,"mat-expansion-panel")(141,"mat-expansion-panel-header")(142,"mat-panel-title"),m(143,"Sampling Defaults"),l(),s(144,"mat-panel-description"),m(145,"Default sampling parameters for generation"),l()(),s(146,"div",11)(147,"mat-form-field",12),v(148,"input",35),b(),s(149,"mat-label"),m(150,"Temperature"),l()(),s(151,"mat-form-field",12),v(152,"input",36),b(),s(153,"mat-label"),m(154,"Top-P"),l()(),s(155,"mat-form-field",12),v(156,"input",37),b(),s(157,"mat-label"),m(158,"Top-K"),l()(),s(159,"mat-form-field",12),v(160,"input",38),b(),s(161,"mat-label"),m(162,"Min-P"),l()()(),s(163,"div",11)(164,"mat-form-field",12),v(165,"input",39),b(),s(166,"mat-label"),m(167,"Seed"),l()(),s(168,"mat-form-field",12),v(169,"input",40),b(),s(170,"mat-label"),m(171,"Repetition Penalty"),l()(),s(172,"mat-form-field",12),v(173,"input",41),b(),s(174,"mat-label"),m(175,"Max Tokens (seq)"),l()()()(),s(176,"mat-expansion-panel")(177,"mat-expansion-panel-header")(178,"mat-panel-title"),m(179,"Tools & Chat"),l(),s(180,"mat-panel-description"),m(181,"Tool calling, reasoning and cache options"),l()(),s(182,"div",11)(183,"mat-checkbox",42),m(184," Trust Remote Code "),l(),b(),s(185,"mat-checkbox",43),m(186," Enable Auto Tool Choice "),l(),b(),l(),s(187,"div",11)(188,"mat-form-field",12)(189,"mat-select",44),me(190,By,2,2,"mat-option",8,xt),l(),b(),s(192,"mat-label"),m(193,"Tool Call Parser"),l()(),s(194,"mat-form-field",12)(195,"mat-select",45),me(196,zy,2,2,"mat-option",8,xt),l(),b(),s(198,"mat-label"),m(199,"Reasoning Parser"),l()(),s(200,"mat-form-field",12)(201,"mat-select",46)(202,"mat-option",28),m(203,"auto"),l(),s(204,"mat-option",29),m(205,"on"),l(),s(206,"mat-option",30),m(207,"off"),l()(),b(),s(208,"mat-label"),m(209,"Prefix Caching"),l()()()(),s(210,"mat-expansion-panel")(211,"mat-expansion-panel-header")(212,"mat-panel-title"),m(213,"Server & Network"),l()(),s(214,"div",11)(215,"mat-form-field",12),v(216,"input",47),b(),s(217,"mat-label"),m(218,"Host"),l()(),s(219,"mat-autocomplete",null,2),me(221,jy,5,3,"mat-option",8,Ey),l(),s(223,"mat-form-field",12),v(224,"input",48),b(),s(225,"mat-label"),m(226,"Port"),l()(),s(227,"mat-form-field",12),v(228,"input",49),b(),s(229,"mat-label"),m(230,"API Key"),l()()()(),s(231,"mat-expansion-panel")(232,"mat-expansion-panel-header")(233,"mat-panel-title"),m(234,"Additional"),l(),s(235,"mat-panel-description"),m(236,"Extra CLI flags and environment variables"),l()(),s(237,"mat-form-field",5),v(238,"textarea",50),b(),s(239,"mat-label"),m(240,"Extra CLI Flags (one per line)"),l()(),s(241,"mat-form-field",5),v(242,"textarea",51),b(),s(243,"mat-label"),m(244,"Environment variables (KEY=VALUE, one per line)"),l()()()()(),s(245,"mat-dialog-actions",52)(246,"button",53),A("click",function(){return n.cancel()}),m(247,"Cancel"),l(),s(248,"button",54),A("click",function(){return n.save()}),m(249),l()()),t&2){let a=Ne(16),r=Ne(29),u=Ne(220);c(),he("",n.isClone?"Clone":n.isEdit?"Edit":"Add"," vllm service"),c(2),x("formGroup",n.form),c(),p("changed",n.isControlChanged("name")),c(),x("disabled",n.isEdit&&!n.isClone),y(),c(3),E(n.form.controls.name.errors?.required?8:n.form.controls.name.errors?.pattern?9:-1),c(2),p("changed",n.isControlChanged("command")),c(),x("matAutocomplete",a),y(),c(3),E(n.form.controls.command.errors?.required?14:-1),c(3),ue(n.filteredCommands()),c(2),p("has-changed",n.isSectionChanged("model","tokenizer","dtype")),c(4),p("changed",n.isControlChanged("model")),c(),x("matAutocomplete",r),y(),c(3),E(n.form.controls.model.errors?.required?27:-1),c(3),ue(n.existingModelPaths()),c(3),p("changed",n.isControlChanged("tokenizer")),c(),y(),c(3),p("changed",n.isControlChanged("dtype")),c(),y(),c(),ue(n.dtypeOptions),c(4),p("has-changed",n.isSectionChanged("tensorParallelSize","pipelineParallelSize","maxParallelLoadingWorkers","gpuMemoryUtilization","swapSpace","cpuOffloadGb","kvCacheMemory","device","attentionBackend")),c(5),p("changed",n.isControlChanged("tensorParallelSize")),c(),y(),c(3),p("changed",n.isControlChanged("pipelineParallelSize")),c(),y(),c(3),p("changed",n.isControlChanged("maxParallelLoadingWorkers")),c(),y(),c(4),p("changed",n.isControlChanged("gpuMemoryUtilization")),c(),y(),c(3),p("changed",n.isControlChanged("swapSpace")),c(),y(),c(3),p("changed",n.isControlChanged("cpuOffloadGb")),c(),y(),c(3),p("changed",n.isControlChanged("device")),c(),y(),c(4),p("changed",n.isControlChanged("attentionBackend")),c(),y(),c(3),ue(n.attentionBackends),c(4),p("changed",n.isControlChanged("kvCacheMemory")),c(),y(),c(3),p("has-changed",n.isSectionChanged("maxModelLen","maxNumSeqs","maxNumBatchedTokens","blockSize","enableChunkedPrefill")),c(5),p("changed",n.isControlChanged("maxModelLen")),c(),y(),c(3),p("changed",n.isControlChanged("maxNumSeqs")),c(),y(),c(3),p("changed",n.isControlChanged("enableChunkedPrefill")),c(),y(),c(10),p("changed",n.isControlChanged("maxNumBatchedTokens")),c(),y(),c(3),p("changed",n.isControlChanged("blockSize")),c(),y(),c(3),p("has-changed",n.isSectionChanged("specMethod","specTokens","specDraftModel","specDraftTensorParallelSize","specNumDraftTokens")),c(7),p("changed",n.isControlChanged("specMethod")),c(),y(),c(),ue(n.specMethods),c(4),p("changed",n.isControlChanged("specTokens")),c(),y(),c(3),E(n.showSpecDraftParams()?139:-1),c(),p("has-changed",n.isSectionChanged("temperature","topP","topK","minP","seed","repetitionPenalty","maxNumSeq")),c(7),p("changed",n.isControlChanged("temperature")),c(),y(),c(3),p("changed",n.isControlChanged("topP")),c(),y(),c(3),p("changed",n.isControlChanged("topK")),c(),y(),c(3),p("changed",n.isControlChanged("minP")),c(),y(),c(4),p("changed",n.isControlChanged("seed")),c(),y(),c(3),p("changed",n.isControlChanged("repetitionPenalty")),c(),y(),c(3),p("changed",n.isControlChanged("maxNumSeq")),c(),y(),c(3),p("has-changed",n.isSectionChanged("trustRemoteCode","enableAutoToolChoice","toolCallParser","reasoningParser","enablePrefixCaching")),c(7),p("changed",n.isControlChanged("trustRemoteCode")),y(),c(2),p("changed",n.isControlChanged("enableAutoToolChoice")),y(),c(3),p("changed",n.isControlChanged("toolCallParser")),c(),x("disabled",n.isToolCallParserDisabled()),y(),c(),ue(n.toolCallParsers),c(4),p("changed",n.isControlChanged("reasoningParser")),c(),y(),c(),ue(n.reasoningParsers),c(4),p("changed",n.isControlChanged("enablePrefixCaching")),c(),y(),c(9),p("has-changed",n.isSectionChanged("host","port","apiKey")),c(5),p("changed",n.isControlChanged("host")),c(),x("matAutocomplete",u),y(),c(5),ue(n.filteredHosts()),c(2),p("changed",n.isControlChanged("port")),c(),y(),c(3),p("changed",n.isControlChanged("apiKey")),c(),y(),c(3),p("has-changed",n.isSectionChanged("extraFlags","envText")),c(6),p("changed",n.isControlChanged("extraFlags")),c(),y(),c(3),p("changed",n.isControlChanged("envText")),c(),y(),c(6),x("disabled",n.form.invalid),c(),he(" ",n.isEdit&&!n.isClone?"Save":"Create"," ")}},dependencies:[Ve,hn,bo,Ei,va,Ai,mn,ec,Jl,pn,Ut,ji,xn,Cn,vt,Wi,Qe,it,Oo,Nc,Ts,Ba,Ms,As,Es,St,kt,Ot,fn,ti,ei,Lt,oi,ri,ai,Fo,Po,Is,za],styles:['@charset "UTF-8";.vllm-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:8px;min-width:640px}.form-row[_ngcontent-%COMP%]{display:flex;gap:12px;margin-bottom:4px;align-items:center}.form-col[_ngcontent-%COMP%]{flex:1}.form-col-60[_ngcontent-%COMP%]{flex:3}.full-width[_ngcontent-%COMP%]{width:100%}.auto-path[_ngcontent-%COMP%]{font-family:monospace}.auto-from[_ngcontent-%COMP%]{margin-left:8px;opacity:.6;font-size:12px}.flags-textarea[_ngcontent-%COMP%], .env-textarea[_ngcontent-%COMP%]{overflow-x:auto}mat-dialog-content[_ngcontent-%COMP%]{padding-top:10px!important;max-height:80vh}mat-expansion-panel[_ngcontent-%COMP%]{margin-bottom:0}mat-dialog-actions[_ngcontent-%COMP%]{gap:8px}.subsection-label[_ngcontent-%COMP%]{font-size:12px;font-weight:500;color:#0009;margin:4px 0 14px;text-transform:uppercase;letter-spacing:.5px}mat-expansion-panel.has-changed[_ngcontent-%COMP%] mat-panel-title[_ngcontent-%COMP%]{font-weight:700}mat-form-field.changed[_ngcontent-%COMP%] .mat-mdc-form-field-infix input, mat-form-field.changed[_ngcontent-%COMP%] .mat-mdc-form-field-infix .mat-mdc-select{font-weight:700}mat-checkbox.changed[_ngcontent-%COMP%] label{font-weight:700}']})}}return i})();function si(i,o,e){let t=No(i,o);return t!==null?t:e}function At(i,o,e){let t=No(i,o);if(t!==null){let n=parseInt(t,10);return isNaN(n)?e:n}return e}function Kn(i,o,e){let t=No(i,o);if(t!==null){let n=parseFloat(t);return isNaN(n)?e:n}return e}function Yy(i,o,e,t){let n=null;for(let a of i){let[r,...u]=a.split(/\s+/);r===o?u.join(" ").trim()==="false"?n="off":n="on":r===e&&(n="off")}return n??t}var Xy=(i,o)=>o.name;function Zy(i,o){if(i&1){let e=Ue();s(0,"button",22),A("click",function(n){xe(e);let a=D(2).$implicit;return D(2).control(a.name,"start"),we(n.stopPropagation())}),s(1,"mat-icon"),m(2,"play_arrow"),l(),m(3," Start "),l()}if(i&2){let e=D(2).$implicit,t=D(2);x("disabled",t.busy()?.name===e.name)}}function Qy(i,o){if(i&1){let e=Ue();s(0,"button",23),A("click",function(n){xe(e);let a=D(2).$implicit;return D(2).control(a.name,"stop"),we(n.stopPropagation())}),s(1,"mat-icon"),m(2,"stop"),l(),m(3," Stop "),l()}if(i&2){let e=D(2).$implicit,t=D(2);x("disabled",t.busy()?.name===e.name)}}function Jy(i,o){if(i&1){let e=Ue();s(0,"button",24),A("click",function(n){xe(e);let a=D(2).$implicit;return D(2).control(a.name,"disable"),we(n.stopPropagation())}),s(1,"mat-icon"),m(2,"lock"),l(),m(3," Disable "),l()}if(i&2){let e=D(2).$implicit,t=D(2);x("disabled",t.busy()?.name===e.name)}}function eC(i,o){if(i&1){let e=Ue();s(0,"button",24),A("click",function(n){xe(e);let a=D(2).$implicit;return D(2).control(a.name,"enable"),we(n.stopPropagation())}),s(1,"mat-icon"),m(2,"lock_open"),l(),m(3," Enable "),l()}if(i&2){let e=D(2).$implicit,t=D(2);x("disabled",e.enabled||t.busy()?.name===e.name)}}function tC(i,o){if(i&1&&(M(0,Zy,4,1,"button",19)(1,Qy,4,1,"button",20),M(2,Jy,4,1,"button",21)(3,eC,4,1,"button",21)),i&2){let e=D().$implicit;E(e.running?1:0),c(2),E(e.enabled?2:3)}}function iC(i,o){if(i&1){let e=Ue();s(0,"tr",12),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.selectedServiceService.select(n.name))}),s(1,"td")(2,"div",13),v(3,"span",14),s(4,"span",15),m(5),l()()(),s(6,"td",16),M(7,tC,4,2),l(),s(8,"td",16)(9,"div")(10,"button",17)(11,"mat-icon"),m(12,"more_vert"),l()(),s(13,"mat-menu",18,2)(15,"button",7),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.editService(n))}),s(16,"mat-icon"),m(17,"edit"),l(),s(18,"span"),m(19,"Edit"),l()(),s(20,"button",7),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.cloneService(n))}),s(21,"mat-icon"),m(22,"content_copy"),l(),s(23,"span"),m(24,"Clone"),l()(),s(25,"button",7),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.deleteService(n.name))}),s(26,"mat-icon"),m(27,"delete"),l(),s(28,"span"),m(29,"Delete"),l()()()()()()}if(i&2){let e=o.$implicit,t=Ne(14);p("custom",e.hasConfig),c(3),p("running",e.running),c(),p("disabled",!e.enabled),c(),q(e.name),c(2),E(e.installed?7:-1),c(2),He("visibility",e.hasConfig?"visible":"hidden"),c(),x("matMenuTriggerFor",t)}}function nC(i,o){if(i&1&&(s(0,"table",9)(1,"tbody"),me(2,iC,30,11,"tr",11,Xy),l()()),i&2){let e=D();c(2),ue(e.unified())}}function oC(i,o){i&1&&(s(0,"div",10)(1,"p"),m(2,'No services configured. Click "Managed services" to select system services or "Custom service" to create one.'),l()())}var Ep=(()=>{class i{constructor(){this.serviceService=d(_t),this.serviceList=d(xs),this.selectedServiceService=d(Cs),this.dialog=d(Eo),this.snackBar=d(ys),this.services=this.serviceList.services,this.configs=R([]),this.loading=R(!0),this.busy=R(null),this.unified=W(()=>{let e=this.services(),t=this.configs(),n=new Map;for(let u of t)n.set(u.name,u);let a=e.filter(u=>n.has(u.name)).map(u=>{let h=n.get(u.name)??null;return{name:u.name,running:u.running,enabled:u.enabled,installed:u.installed,pid:u.pid,error:u.error,config:h,hasConfig:!0}}),r=e.filter(u=>!n.has(u.name)).map(u=>Oe(V({},u),{config:null,hasConfig:!1}));return[...a,...r]})}ngOnInit(){this.load()}load(){return ye(this,null,function*(){this.loading.set(!0);try{yield this.serviceList.refresh(),this.configs.set(yield Te(this.serviceService.fetchConfigs()))}catch(e){console.error("[ServicesComponent] load error:",e)}finally{this.loading.set(!1)}})}control(e,t){return ye(this,null,function*(){let n=this.busy();if(!(n&&n.name===e&&n.action===t)){this.selectedServiceService.select(e),this.busy.set({name:e,action:t});try{let a=yield Te(this.serviceService.control(e,t));a.error&&this.showError(`${e}: ${a.error}`),yield this.load()}catch(a){this.showError(`${e}: ${String(a.error||a)}`)}finally{this.busy.set(null)}}})}showError(e){this.snackBar.open(e,"Dismiss",{duration:8e3,horizontalPosition:"center",verticalPosition:"top"})}manageServices(){this.dialog.open(mp,{maxWidth:"600px"}).afterClosed().subscribe(t=>{t&&this.load()})}archiveServices(){this.dialog.open(hp,{minWidth:"840px"}).afterClosed().subscribe(t=>{t&&this.load()})}addService(e){this.openDialog(null,e)}editService(e){this.selectedServiceService.select(e.name),this.openDialog(e.config,e.config?.type)}cloneService(e){if(!e.config)return;let t=Oe(V({},e.config),{name:this.uniqueCloneName(e.name)});this.openDialog(t,t.type,!0)}uniqueCloneName(e){let t=new Set(this.configs().map(a=>a.name));if(!t.has(`${e}-copy`))return`${e}-copy`;let n=2;for(;t.has(`${e}-copy-${n}`);)n++;return`${e}-copy-${n}`}deleteService(e){return ye(this,null,function*(){this.selectedServiceService.select(e);try{yield Te(this.serviceService.deleteConfig(e)),yield this.load()}catch(t){this.showError(`Delete "${e}": ${String(t)}`)}})}hasFlags(e){return e.flags.length>0}openDialog(e,t,n=!1){let a=t??e?.type??"generic";if(a==="llama-server"){let r={config:e,allConfigs:this.configs(),clone:n},u=this.dialog.open(Sp,{data:r,minWidth:"800px"});this.handleDialogResult(u,e,n)}else if(a==="vllm"){let r={config:e,allConfigs:this.configs(),clone:n},u=this.dialog.open(Mp,{data:r,minWidth:"800px"});this.handleDialogResult(u,e,n)}else{let r={config:e,allConfigs:this.configs(),clone:n},u=this.dialog.open(op,{data:r,minWidth:"1000px"});this.handleDialogResult(u,e,n)}}handleDialogResult(e,t,n=!1){e.afterClosed().subscribe(a=>ye(this,null,function*(){if(a)try{if(n)yield Te(this.serviceService.saveConfig(a));else{let r=t?.name??null;if(r!==null&&r!==a.name){let h=this.unified().find(w=>w.name===r),g=h?.running??!1,_=h?.enabled??!1;yield Te(this.serviceService.deleteConfig(r)),yield Te(this.serviceService.saveConfig(a)),_&&(yield Te(this.serviceService.control(a.name,"enable"))),g&&(yield Te(this.serviceService.control(a.name,"start")))}else yield Te(this.serviceService.saveConfig(a))}}catch(r){this.showError(`Save: ${String(r)}`)}finally{yield this.load()}}))}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-services"]],decls:43,vars:3,consts:[["servicesMenu","matMenu"],["addMenu",""],["serviceMenu","matMenu"],[1,"services-card"],[1,"section-header"],["mat-icon-button","","title","Services actions",1,"header-menu-btn",3,"matMenuTriggerFor"],["xPosition","before"],["mat-menu-item","",3,"click"],["mat-menu-item","",3,"matMenuTriggerFor"],[1,"services-list"],[1,"empty"],[3,"custom"],[3,"click"],[1,"service-name"],[1,"status-dot"],[1,"name-text"],[1,"service-actions-cell"],["mat-icon-button","","title","Service actions",3,"matMenuTriggerFor"],["yPosition","below"],["mat-raised-button","","color","primary",3,"disabled"],["mat-raised-button","","color","warn",3,"disabled"],["mat-stroked-button","",3,"disabled"],["mat-raised-button","","color","primary",3,"click","disabled"],["mat-raised-button","","color","warn",3,"click","disabled"],["mat-stroked-button","",3,"click","disabled"]],template:function(t,n){if(t&1&&(s(0,"div",3)(1,"div",4)(2,"h2"),m(3,"Services"),l(),s(4,"button",5)(5,"mat-icon"),m(6,"more_vert"),l()(),s(7,"mat-menu",6,0)(9,"button",7),A("click",function(){return n.manageServices()}),s(10,"mat-icon"),m(11,"tune"),l(),s(12,"span"),m(13,"Managed services"),l()(),s(14,"button",7),A("click",function(){return n.archiveServices()}),s(15,"mat-icon"),m(16,"archive"),l(),s(17,"span"),m(18,"Archive"),l()(),s(19,"button",8)(20,"mat-icon"),m(21,"add"),l(),s(22,"span"),m(23,"Custom service"),l()()(),s(24,"mat-menu",null,1)(26,"button",7),A("click",function(){return n.addService("generic")}),s(27,"mat-icon"),m(28,"settings"),l(),s(29,"span"),m(30,"Generic service"),l()(),s(31,"button",7),A("click",function(){return n.addService("llama-server")}),s(32,"mat-icon"),m(33,"smart_toy"),l(),s(34,"span"),m(35,"llama-server"),l()(),s(36,"button",7),A("click",function(){return n.addService("vllm")}),s(37,"mat-icon"),m(38,"bolt"),l(),s(39,"span"),m(40,"vllm"),l()()()(),M(41,nC,4,0,"table",9)(42,oC,3,0,"div",10),l()),t&2){let a=Ne(8),r=Ne(25);c(4),x("matMenuTriggerFor",a),c(15),x("matMenuTriggerFor",r),c(22),E(n.unified().length>0?41:n.loading()?-1:42)}},dependencies:[Ve,Qe,it,Hi,Do,bs,yn,$n,vs,Ft,Pt],styles:[".services-card[_ngcontent-%COMP%]{margin-bottom:24px}.section-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px;margin-top:8px}.section-header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:1.1rem;font-weight:600;color:#333}.section-header[_ngcontent-%COMP%] .header-menu-btn[_ngcontent-%COMP%]{color:#666}.services-list[_ngcontent-%COMP%]{width:100%;border-collapse:collapse}.services-list[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]{border-bottom:1px solid #e0e0e0;transition:background-color .2s ease}.services-list[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:hover{background-color:#fff}.services-list[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:last-child{border-bottom:none}.services-list[_ngcontent-%COMP%] tr.custom[_ngcontent-%COMP%], .services-list[_ngcontent-%COMP%] tr.custom[_ngcontent-%COMP%]:first-child td[_ngcontent-%COMP%]:first-child{border-left:3px solid #7c4dff}.services-list[_ngcontent-%COMP%] td[_ngcontent-%COMP%]{padding:4px 12px;vertical-align:middle}.service-name[_ngcontent-%COMP%]{font-size:1rem;font-weight:600;white-space:nowrap;display:flex;align-items:center;gap:8px}.service-name[_ngcontent-%COMP%] .status-dot[_ngcontent-%COMP%]{display:inline-block;width:10px;height:10px;border-radius:50%;background-color:#bdbdbd}.service-name[_ngcontent-%COMP%] .status-dot.running[_ngcontent-%COMP%]{background-color:#4caf50}.service-name[_ngcontent-%COMP%] .name-text[_ngcontent-%COMP%]{color:#212121}.service-name[_ngcontent-%COMP%] .name-text.disabled[_ngcontent-%COMP%]{color:#9e9e9e}.service-actions-cell[_ngcontent-%COMP%]{white-space:nowrap}.service-actions-cell[_ngcontent-%COMP%] button[_ngcontent-%COMP%] + button[_ngcontent-%COMP%]{margin-left:8px}.status-chip[_ngcontent-%COMP%], .enabled-chip[_ngcontent-%COMP%]{font-size:.8rem;font-weight:500}.status-chip.running[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #a5d6a7}.status-chip.stopped[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #ef9a9a}.enabled-chip.enabled[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #90caf9}.enabled-chip.disabled[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #bdbdbd}.empty[_ngcontent-%COMP%]{text-align:center;padding:24px;color:#999;font-size:.9rem}.empty[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}"]})}}return i})();var aC=["journalBody"],rC=(i,o)=>o.name;function sC(i,o){if(i&1&&(s(0,"mat-option",7),m(1),l()),i&2){let e=o.$implicit;x("value",e.name),c(),q(e.name)}}function lC(i,o){if(i&1){let e=Ue();s(0,"button",10),A("click",function(){xe(e);let n=D(2);return we(n.toggleWordWrap())}),s(1,"mat-icon"),m(2,"wrap_text"),l()()}}function cC(i,o){if(i&1){let e=Ue();s(0,"button",11),A("click",function(){xe(e);let n=D(2);return we(n.toggleWordWrap())}),s(1,"mat-icon"),m(2,"wrap_text"),l()()}}function dC(i,o){if(i&1){let e=Ue();s(0,"mat-select",6),A("ngModelChange",function(n){xe(e);let a=D();return we(a.onServiceChange(n))}),s(1,"mat-option",7),m(2,"\u2014 None \u2014"),l(),me(3,sC,2,2,"mat-option",7,rC),l(),b(),M(5,lC,3,0,"button",8)(6,cC,3,0,"button",9)}if(i&2){let e=D();x("ngModel",e.selectedService()),y(),c(),x("value",null),c(2),ue(e.services()),c(2),E(e.wordWrap()?5:6)}}function mC(i,o){if(i&1&&(s(0,"div",3),m(1),l()),i&2){let e=D();c(),q(e.error())}}function uC(i,o){if(i&1&&(s(0,"div",4,0)(2,"pre"),m(3),l()()),i&2){let e=D();c(2),p("wrap-on",e.wordWrap()),c(),q(e.journalText())}}function hC(i,o){i&1&&(s(0,"div",5)(1,"p"),m(2,"No service selected"),l()())}var pC=40,Ap=(()=>{class i{toggleWordWrap(){this.wordWrap.update(e=>!e)}constructor(){this.serviceService=d(_t),this.selectedServiceService=d(Cs),this.serviceList=d(xs),this.cdr=d(te),this.services=this.serviceList.services,this.servicesLoaded=this.serviceList.loaded,this.journalLines=R([]),this.journalLoading=R(!1),this.journalError=R(null),this.error=W(()=>this.serviceList.error()??this.journalError()),this.selectedService=W(()=>this.selectedServiceService.selectedService()),this.wordWrap=R(!0),this.journalText=W(()=>{let e=this.journalLines();return e.length===0?"":e.map(t=>t.timestamp?`${t.timestamp} ${t.message}`:t.message).join(`
5598
- `)}),zt(()=>{if(!this.servicesLoaded())return;let e=this.selectedService();e!==null&&!this.services().some(t=>t.name===e)&&this.selectedServiceService.select(null)}),zt(()=>{if(!this.servicesLoaded())return;this.selectedService()?(this.journalLines.set([]),this.journalError.set(null),this.restartPolling()):(this.stopPolling(),this.journalLines.set([]))}),this.serviceList.refresh()}ngAfterViewInit(){this.scrollToBottom()}ngOnDestroy(){this.stopPolling()}onServiceChange(e){this.selectedServiceService.select(e)}restartPolling(){this.stopPolling(),this.fetchJournal(),this.journalSub=Wa(0,1e3).subscribe(()=>this.fetchJournal())}stopPolling(){this.journalSub&&(this.journalSub.unsubscribe(),this.journalSub=void 0)}fetchJournal(){let e=this.selectedService();e&&(this.isTextSelected()||(this.journalLoading.set(!0),this.serviceService.fetchJournal(e,100).subscribe({next:t=>{let n=this.isScrolledToBottom();this.journalLines.set(t),this.journalError.set(null),this.journalLoading.set(!1),this.cdr.markForCheck(),requestAnimationFrame(()=>{n&&this.scrollToBottom()})},error:t=>{this.journalError.set(t.message),this.journalLoading.set(!1),this.cdr.markForCheck()}})))}get scrollContainer(){return this.journalBody?.nativeElement??null}isTextSelected(){let e=typeof window<"u"?window:null;if(!e)return!1;let t=e.getSelection();if(!t||t.isCollapsed||!t.rangeCount)return!1;let n=this.scrollContainer;return n?n.contains(t.anchorNode):!1}isScrolledToBottom(){let e=this.scrollContainer;return e?e.scrollHeight-e.scrollTop-e.clientHeight<=pC:!0}scrollToBottom(){let e=this.scrollContainer;e&&(e.scrollTop=e.scrollHeight)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-journal-panel"]],viewQuery:function(t,n){if(t&1&&Me(aC,5),t&2){let a;O(a=P())&&(n.journalBody=a.first)}},decls:9,vars:3,consts:[["journalBody",""],[1,"journal-card"],[1,"journal-header"],[1,"journal-error"],[1,"journal-body"],[1,"journal-body","journal-empty"],["disableOptionCentering","",1,"service-select",3,"ngModelChange","ngModel"],[3,"value"],["mat-flat-button","","color","primary","aria-label","Disable word wrap"],["mat-stroked-button","","aria-label","Enable word wrap"],["mat-flat-button","","color","primary","aria-label","Disable word wrap",3,"click"],["mat-stroked-button","","aria-label","Enable word wrap",3,"click"]],template:function(t,n){t&1&&(s(0,"mat-card",1)(1,"mat-card-content")(2,"div",2)(3,"h2"),m(4,"Journal"),l(),M(5,dC,7,3),l(),M(6,mC,2,1,"div",3),M(7,uC,4,3,"div",4)(8,hC,3,0,"div",5),l()()),t&2&&(c(5),E(n.servicesLoaded()&&n.services().length>0?5:-1),c(),E(n.error()?6:-1),c(),E(n.selectedService()?7:8))},dependencies:[Ve,on,tn,nn,Fo,Po,vt,Qe,it,Ft,Pt,Si,hn,Ai,ic],styles:[".journal-card[_ngcontent-%COMP%]{height:100%;display:flex;flex-direction:column;overflow:hidden}.journal-card[_ngcontent-%COMP%] mat-card-content[_ngcontent-%COMP%]{flex:1;display:flex;flex-direction:column;overflow:hidden;padding-bottom:8px}.journal-header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:12px;margin-bottom:12px;flex-shrink:0}.journal-header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:20px;font-weight:500}.service-select[_ngcontent-%COMP%]{flex:1;min-width:150px}.journal-error[_ngcontent-%COMP%]{color:#f44336;font-size:13px;margin-bottom:8px;flex-shrink:0}.journal-body[_ngcontent-%COMP%]{flex:1;overflow-y:auto;background:#1e1e1e;border-radius:4px;padding:8px;min-height:0}.journal-body[_ngcontent-%COMP%]::-webkit-scrollbar{width:8px}.journal-body[_ngcontent-%COMP%]::-webkit-scrollbar-track{background:#2d2d2d;border-radius:4px}.journal-body[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background:#555;border-radius:4px}.journal-body[_ngcontent-%COMP%]::-webkit-scrollbar-thumb:hover{background:#777}.journal-body[_ngcontent-%COMP%]{scrollbar-width:thin;scrollbar-color:#555 #2d2d2d}.journal-body[_ngcontent-%COMP%] pre[_ngcontent-%COMP%]{margin:0;font-family:Courier New,Courier,monospace;font-size:12px;line-height:1.6;color:#d4d4d4;white-space:pre}.journal-body[_ngcontent-%COMP%] pre.wrap-on[_ngcontent-%COMP%]{white-space:pre-wrap}.journal-empty[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center}.journal-empty[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0;color:#888;font-size:14px}[_nghost-%COMP%] .mdc-button{min-width:32px}[_nghost-%COMP%] .mat-mdc-unelevated-button>.mat-icon, [_nghost-%COMP%] .mat-mdc-outlined-button>.mat-icon{margin-right:0}"]})}}return i})();var Ps=(()=>{class i{constructor(){this.http=d(Qt),this.baseUrl="/api/system"}reboot(){return ye(this,null,function*(){yield Te(this.http.post(`${this.baseUrl}/reboot`,null))})}shutdown(){return ye(this,null,function*(){yield Te(this.http.post(`${this.baseUrl}/shutdown`,null))})}getSystemInfo(){return ye(this,null,function*(){return Te(this.http.get(`${this.baseUrl}/info`))})}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var fC=(i,o)=>o.device,gC=(i,o)=>o.path;function _C(i,o){i&1&&v(0,"mat-progress-bar",2)}function vC(i,o){if(i&1&&(s(0,"p",3),m(1),l()),i&2){let e=D();c(),q(e.error())}}function bC(i,o){if(i&1&&(s(0,"span",11),m(1),l()),i&2){let e=D(2);c(),q(e.info().uptime)}}function yC(i,o){if(i&1&&(s(0,"div",12)(1,"span",13),m(2,"Version"),l(),s(3,"span",14),m(4),l()()),i&2){let e=D(2);c(4),q(e.info().os.version)}}function CC(i,o){if(i&1&&(s(0,"div",16)(1,"div",18)(2,"span",19),m(3),l(),s(4,"span",20),m(5),l()(),s(6,"div",21),v(7,"div",22),l(),s(8,"div",23)(9,"span"),m(10),l(),s(11,"span"),m(12),l()()()),i&2){let e=o.$implicit,t=D(2);c(3),q(e.device),c(2),q(e.mountPoint),c(2),He("width",e.usePercent,"%")("background",e.usePercent>90?"#f44336":e.usePercent>75?"#ff9800":"#4caf50"),c(3),Mn("",t.formatBytes(e.available)," free of ",t.formatBytes(e.total)),c(2),he("",e.usePercent,"% used")}}function xC(i,o){if(i&1&&(s(0,"div",27)(1,"span",31),m(2,"Last"),l(),s(3,"span",32),m(4),jo(5,"date"),l()()),i&2){let e=D(3);c(4),q(Ho(5,1,e.info().timeshift.lastSnapshot,"medium"))}}function wC(i,o){if(i&1&&(s(0,"mat-chip",33),m(1),l()),i&2){let e=o.$implicit;c(),q(e)}}function DC(i,o){if(i&1&&(s(0,"mat-chip-set"),me(1,wC,2,1,"mat-chip",33,xt),l()),i&2){let e=D(3);c(),ue(e.info().timeshift.schedules)}}function kC(i,o){if(i&1&&(s(0,"div",6)(1,"h3"),m(2,"Timeshift Backup"),l(),s(3,"div",7)(4,"div",8)(5,"mat-chip-set")(6,"mat-chip",24),m(7),l(),s(8,"mat-chip",25),m(9),l()(),s(10,"span",26),m(11),l()(),M(12,xC,6,4,"div",27),s(13,"div",28),v(14,"div",29),l(),s(15,"div",30)(16,"span"),m(17),l(),M(18,DC,3,0,"mat-chip-set"),l()()(),v(19,"mat-divider",15)),i&2){let e=D(2);c(7),q(e.info().timeshift.mode),c(2),q(e.info().timeshift.device),c(2),he("",e.info().timeshift.snapshots," snapshots"),c(),E(e.info().timeshift.lastSnapshot?12:-1),c(2),He("width",e.info().timeshift.totalSpace>0?(e.info().timeshift.totalSpace-e.info().timeshift.freeSpace)/e.info().timeshift.totalSpace*100:0,"%")("background",e.info().timeshift.totalSpace>0&&(e.info().timeshift.totalSpace-e.info().timeshift.freeSpace)/e.info().timeshift.totalSpace>.9?"#f44336":e.info().timeshift.totalSpace>0&&(e.info().timeshift.totalSpace-e.info().timeshift.freeSpace)/e.info().timeshift.totalSpace>.75?"#ff9800":"#4caf50"),c(3),Mn("",e.formatBytes(e.info().timeshift.freeSpace)," free of ",e.formatBytes(e.info().timeshift.totalSpace)),c(),E(e.info().timeshift.schedules.length>0?18:-1)}}function SC(i,o){if(i&1&&m(0),i&2){let e=D().$implicit,t=D(2);he(" ",t.formatBytes(e.size)," ")}}function MC(i,o){i&1&&m(0," \u2014 ")}function EC(i,o){if(i&1&&(s(0,"div",17)(1,"span",34),m(2),l(),s(3,"span",35),M(4,SC,1,1)(5,MC,1,0),l()()),i&2){let e=o.$implicit;c(2),q(e.path),c(2),E(e.exists?4:5)}}function AC(i,o){if(i&1&&(s(0,"div",6)(1,"h3"),m(2,"Operating System"),l(),s(3,"div",7)(4,"div",8)(5,"mat-chip-set")(6,"mat-chip",9),m(7),l(),s(8,"mat-chip",10),m(9),l()(),M(10,bC,2,1,"span",11),l(),M(11,yC,5,1,"div",12),s(12,"div",12)(13,"span",13),m(14,"Kernel"),l(),s(15,"span",14),m(16),l()()()(),v(17,"mat-divider",15),s(18,"div",6)(19,"h3"),m(20,"Disks"),l(),me(21,CC,13,9,"div",16,fC),l(),v(23,"mat-divider",15),M(24,kC,20,11),s(25,"div",6)(26,"h3"),m(27,"System Logs"),l(),me(28,EC,6,2,"div",17,gC),l()),i&2){let e=D();c(7),q(e.info().hostname),c(2),q(e.info().os.name),c(),E(e.info().uptime?10:-1),c(),E(e.info().os.version?11:-1),c(5),q(e.info().kernel),c(5),ue(e.info().disks),c(3),E(e.info().timeshift?24:-1),c(4),ue(e.info().logs)}}var Tp=(()=>{class i{constructor(){this.systemService=d(Ps),this.dialogRef=d(gt),this.loading=R(!0),this.info=R(null),this.error=R(null)}ngOnInit(){return ye(this,null,function*(){try{let e=yield this.systemService.getSystemInfo();this.info.set(e)}catch(e){this.error.set(e instanceof Error?e.message:"Failed to load system info")}finally{this.loading.set(!1)}})}formatBytes(e){return e===0?"0 B":`${(e/(1024*1024*1024)).toFixed(1)} GB`}close(){this.dialogRef.close()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-system-info-dialog"]],decls:12,vars:1,consts:[[1,"dialog-container"],["mat-dialog-title",""],["mode","indeterminate"],[1,"dialog-error"],["align","end"],["mat-raised-button","","color","primary",3,"click"],[1,"info-section"],[1,"info-card"],[1,"info-card-header"],[1,"hostname-chip"],[1,"distro-chip"],[1,"os-uptime"],[1,"info-row"],[1,"info-label"],[1,"info-value"],[1,"section-divider"],[1,"disk-row"],[1,"log-row"],[1,"disk-header"],[1,"disk-device"],[1,"disk-mount"],[1,"disk-bar-bg"],[1,"disk-bar-fill"],[1,"disk-details"],[1,"mode-chip"],[1,"device-chip"],[1,"timeshift-snapshots"],[1,"timeshift-row"],[1,"timeshift-disk-bar-bg"],[1,"timeshift-disk-bar-fill"],[1,"timeshift-disk-details"],[1,"timeshift-label"],[1,"timeshift-value"],[1,"schedule-chip"],[1,"log-path"],[1,"log-size"]],template:function(t,n){t&1&&(s(0,"div",0)(1,"h2",1)(2,"mat-icon"),m(3,"info"),l(),m(4," System Info "),l(),s(5,"mat-dialog-content"),M(6,_C,1,0,"mat-progress-bar",2)(7,vC,2,1,"p",3)(8,AC,30,6),l(),s(9,"mat-dialog-actions",4)(10,"button",5),A("click",function(){return n.close()}),m(11,"OK"),l()()()),t&2&&(c(6),E(n.loading()?6:n.error()?7:n.info()?8:-1))},dependencies:[Ve,Qe,it,Lt,oi,ri,ai,Si,en,Ss,Lc,Ft,Pt,Do,Ea,Eh,sl],styles:[".dialog-container[_ngcontent-%COMP%]{min-width:480px}.dialog-error[_ngcontent-%COMP%]{color:#f44336;padding:8px 0}.info-section[_ngcontent-%COMP%]{margin-bottom:8px}.info-section[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin:0 0 8px;font-size:14px;font-weight:600;color:#666;text-transform:uppercase;letter-spacing:.5px}.info-row[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:4px 0}.info-row[_ngcontent-%COMP%] .info-label[_ngcontent-%COMP%]{color:#666;font-size:14px}.info-row[_ngcontent-%COMP%] .info-value[_ngcontent-%COMP%]{font-family:monospace;font-size:13px;color:#333}.section-divider[_ngcontent-%COMP%]{margin:12px 0}.disk-row[_ngcontent-%COMP%]{margin-bottom:12px}.disk-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;margin-bottom:4px}.disk-header[_ngcontent-%COMP%] .disk-device[_ngcontent-%COMP%]{font-family:monospace;font-size:13px}.disk-header[_ngcontent-%COMP%] .disk-mount[_ngcontent-%COMP%]{font-size:13px;color:#666}.disk-bar-bg[_ngcontent-%COMP%]{height:6px;background:#e0e0e0;border-radius:3px;overflow:hidden;margin-bottom:2px}.disk-bar-fill[_ngcontent-%COMP%]{height:100%;border-radius:3px}.disk-details[_ngcontent-%COMP%]{display:flex;justify-content:space-between;font-size:12px;color:#666}.info-card[_ngcontent-%COMP%]{background:#f5f5f5;border-radius:8px;padding:12px}.info-card-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}.info-card-header[_ngcontent-%COMP%] .hostname-chip[_ngcontent-%COMP%]{font-family:monospace;background:#e8eaf6!important;color:#303f9f!important}.info-card-header[_ngcontent-%COMP%] .distro-chip[_ngcontent-%COMP%], .info-card-header[_ngcontent-%COMP%] .mode-chip[_ngcontent-%COMP%]{font-weight:600;background:#e3f2fd!important;color:#1976d2!important}.info-card-header[_ngcontent-%COMP%] .device-chip[_ngcontent-%COMP%]{font-family:monospace;background:#e8eaf6!important;color:#303f9f!important}.os-uptime[_ngcontent-%COMP%], .timeshift-snapshots[_ngcontent-%COMP%]{font-size:13px;color:#666;white-space:nowrap}.timeshift-row[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:4px 0;margin-bottom:6px}.timeshift-row[_ngcontent-%COMP%] .timeshift-label[_ngcontent-%COMP%]{color:#666;font-size:13px}.timeshift-row[_ngcontent-%COMP%] .timeshift-value[_ngcontent-%COMP%]{font-size:13px;color:#333}.timeshift-disk-bar-bg[_ngcontent-%COMP%]{height:6px;background:#e0e0e0;border-radius:3px;overflow:hidden;margin-bottom:4px}.timeshift-disk-bar-fill[_ngcontent-%COMP%]{height:100%;border-radius:3px}.timeshift-disk-details[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;font-size:12px;color:#666}.timeshift-disk-details[_ngcontent-%COMP%] .schedule-chip[_ngcontent-%COMP%]{font-size:11px;background:#fff3e0!important;color:#e65100!important}.log-row[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:4px 0}.log-row[_ngcontent-%COMP%] .log-path[_ngcontent-%COMP%]{font-family:monospace;font-size:13px}.log-row[_ngcontent-%COMP%] .log-size[_ngcontent-%COMP%]{font-family:monospace;font-size:13px;color:#333}"]})}}return i})();var Ip=(()=>{class i{constructor(){this.systemInfo=no.required(),this.systemService=d(Ps),this.dialog=d(Eo)}openSystemInfo(){this.dialog.open(Tp,{disableClose:!1})}reboot(){return ye(this,null,function*(){confirm("Reboot the server?")&&(yield this.systemService.reboot())})}shutdown(){return ye(this,null,function*(){confirm("Shutdown the server?")&&(yield this.systemService.shutdown())})}formatBytes(e){let t=e/1073741824;return`${Math.ceil(t)} GB`}ceilCpu(e){return Math.ceil(e)}colorForUsage(e){return e<40?"#4caf50":e<75?"#ff9800":"#f44336"}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-system-bar"]],inputs:{systemInfo:[1,"systemInfo"]},decls:48,vars:16,consts:[["menu","matMenu"],[1,"system-bar"],[1,"system-panel"],[1,"panel-body"],[1,"panel-icon"],[1,"panel-content"],[1,"panel-header"],[1,"panel-label"],[1,"panel-value"],[1,"bar-bg"],[1,"bar-fill"],[1,"server-controls"],["mat-icon-button","","color","warn","title","Server actions",3,"matMenuTriggerFor"],["yPosition","below"],["mat-menu-item","",3,"click"]],template:function(t,n){if(t&1&&(s(0,"div",1)(1,"mat-card",2)(2,"mat-card-content")(3,"div",3)(4,"mat-icon",4),m(5,"dynamic_feed"),l(),s(6,"div",5)(7,"div",6)(8,"span",7),m(9,"CPU"),l(),s(10,"span",8),m(11),l()(),s(12,"div",9),v(13,"div",10),l()()()()(),s(14,"mat-card",2)(15,"mat-card-content")(16,"div",3)(17,"mat-icon",4),m(18,"memory"),l(),s(19,"div",5)(20,"div",6)(21,"span",7),m(22,"RAM"),l(),s(23,"span",8),m(24),l()(),s(25,"div",9),v(26,"div",10),l()()()()(),s(27,"div",11)(28,"button",12)(29,"mat-icon"),m(30,"more_vert"),l()(),s(31,"mat-menu",13,0)(33,"button",14),A("click",function(){return n.openSystemInfo()}),s(34,"mat-icon"),m(35,"info"),l(),s(36,"span"),m(37,"System info"),l()(),s(38,"button",14),A("click",function(){return n.reboot()}),s(39,"mat-icon"),m(40,"restart_alt"),l(),s(41,"span"),m(42,"Reboot server"),l()(),s(43,"button",14),A("click",function(){return n.shutdown()}),s(44,"mat-icon"),m(45,"power_settings_new"),l(),s(46,"span"),m(47,"Shutdown server"),l()()()()()),t&2){let a=Ne(32);c(10),He("color",n.colorForUsage(n.systemInfo().cpuUsage)),c(),he(" ",n.ceilCpu(n.systemInfo().cpuUsage),"% "),c(2),He("width",n.systemInfo().cpuUsage,"%")("background",n.colorForUsage(n.systemInfo().cpuUsage)),c(10),He("color",n.colorForUsage(n.systemInfo().memoryPercent)),c(),Mn(" ",n.formatBytes(n.systemInfo().memoryUsed)," / ",n.formatBytes(n.systemInfo().memoryTotal)," "),c(2),He("width",n.systemInfo().memoryPercent,"%")("background",n.colorForUsage(n.systemInfo().memoryPercent)),c(2),x("matMenuTriggerFor",a)}},dependencies:[Ve,on,tn,nn,Ft,Pt,Qe,Hi,bs,yn,$n,vs,Lt],styles:[".system-bar[_ngcontent-%COMP%]{display:flex;gap:16px;margin-bottom:16px;align-items:stretch}.system-panel[_ngcontent-%COMP%]{flex:1}.server-controls[_ngcontent-%COMP%]{display:flex;align-items:center;gap:4px}.panel-body[_ngcontent-%COMP%]{display:flex;align-items:center;gap:12px}.panel-icon[_ngcontent-%COMP%]{color:#757575;font-size:24px;width:24px;height:24px}.panel-content[_ngcontent-%COMP%]{flex:1;min-width:0}.panel-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:baseline;margin-bottom:4px}.panel-label[_ngcontent-%COMP%]{font-weight:500;font-size:.85rem;color:#555;text-transform:uppercase;letter-spacing:.5px}.panel-value[_ngcontent-%COMP%]{font-weight:500;font-size:.9rem;white-space:nowrap}.bar-bg[_ngcontent-%COMP%]{height:6px;background:#e0e0e0;border-radius:3px;overflow:hidden}.bar-fill[_ngcontent-%COMP%]{height:100%;border-radius:3px;transition:width .4s ease,background .4s ease}"]})}}return i})();function TC(i,o){if(i&1&&(s(0,"div",8)(1,"mat-icon",10),m(2,"warning"),l(),m(3),l()),i&2){let e=D(2);c(3),he(" ",e.loginError()," ")}}function IC(i,o){if(i&1){let e=Ue();s(0,"div",0)(1,"mat-card",1)(2,"mat-card-content")(3,"div",2)(4,"mat-icon",3),m(5,"lock"),l(),s(6,"h2"),m(7,"Authentication Required"),l(),s(8,"p",4),m(9,"Enter your system password to continue"),l()(),s(10,"form",5),A("submit",function(n){return xe(e),D().onLogin(),we(n.preventDefault())}),s(11,"mat-form-field",6)(12,"mat-label"),m(13,"Password"),l(),s(14,"input",7),A("input",function(n){xe(e);let a=D();return we(a.loginPassword.set(n.target.value))}),l()(),M(15,TC,4,1,"div",8),s(16,"button",9),m(17,"Sign In"),l()()()()()}if(i&2){let e=D();c(14),x("value",e.loginPassword()),c(),E(e.loginError()?15:-1)}}function RC(i,o){i&1&&v(0,"mat-progress-bar",11)}function OC(i,o){if(i&1&&(s(0,"mat-card",14)(1,"mat-card-content")(2,"mat-icon",18),m(3," error_outline "),l(),s(4,"p"),m(5),l(),s(6,"p",4),m(7,"Make sure the backend is running on port 4242."),l()()()),i&2){let e=D(2);c(5),q(e.error())}}function PC(i,o){i&1&&(s(0,"mat-card",19)(1,"mat-card-content")(2,"p"),m(3,"No GPUs detected."),l(),s(4,"p",4),m(5,"Ensure nvidia-smi or rocm-smi is available on this system."),l()()())}function FC(i,o){if(i&1&&v(0,"app-system-bar",20)(1,"app-gpu-table",21),i&2){let e=D(3);x("systemInfo",e.systemInfo()),c(),x("gpus",e.gpus())}}function NC(i,o){if(i&1&&(M(0,PC,6,0,"mat-card",19)(1,FC,2,2),v(2,"app-services")),i&2){let e=D(2);E(e.hasGpus()?1:0)}}function LC(i,o){if(i&1){let e=Ue();M(0,RC,1,0,"mat-progress-bar",11),s(1,"div",12)(2,"div",13),M(3,OC,8,1,"mat-card",14)(4,NC,3,1),l(),s(5,"div",15),A("mousedown",function(n){xe(e);let a=D();return we(a.startDrag(n))}),v(6,"span",16),l(),s(7,"div",17),v(8,"app-journal-panel"),l()()}if(i&2){let e=D();E(e.loading()?0:-1),c(),p("dragging",e.isDragging()),c(2),E(e.error()?3:4),c(4),He("width",e.sidebarWidth(),"px")}}var Rp=100,Op=1600,Pp=(()=>{class i{ngOnInit(){this.authService.authState.subscribe(t=>{this.isAuthenticated.set(t),t&&(this.loginError.set(null),this.loginPassword.set(""))});let e=localStorage.getItem("journal-sidebar-width");if(e){let t=parseInt(e,10);t>=Rp&&t<=Op&&this.sidebarWidth.set(t)}}ngOnDestroy(){}onLogin(){return ye(this,null,function*(){this.loginError.set(null),(yield this.authService.login(this.loginPassword()))?(this.loading.set(!0),this.initGpus()):this.loginError.set("Invalid password")})}startDrag(e){e.preventDefault(),this.dragOffsetX=e.clientX,this.dragStartWidth=this.sidebarWidth(),this.isDragging.set(!0)}onDrag(e){if(!this.isDragging())return;let t=this.dragOffsetX-e.clientX,n=this.dragStartWidth+t;n=Math.max(Rp,Math.min(Op,n)),this.sidebarWidth.set(n)}onDragEnd(){this.isDragging()&&(localStorage.setItem("journal-sidebar-width",String(this.sidebarWidth())),this.isDragging.set(!1))}constructor(){this.gpuService=d(rh),this.authService=d(kr),this.gpus=R([]),this.systemInfo=R({cpuUsage:0,memoryTotal:0,memoryUsed:0,memoryPercent:0}),this.loading=R(!0),this.error=R(null),this.hasGpus=W(()=>this.gpus().length>0),this.isAuthenticated=R(this.authService.isAuthenticated()),this.loginPassword=R(""),this.loginError=R(null),this.sidebarWidth=R(420),this.isDragging=R(!1),this.dragOffsetX=0,this.dragStartWidth=420,this.isAuthenticated()&&this.initGpus()}initGpus(e=0){this.gpuService.fetchGpus().subscribe({next:t=>{if(t.length===0){e<3?setTimeout(()=>this.initGpus(e+1),5e3):this.loading.set(!1);return}let n=t.map(a=>Oe(V({},a),{key:a.pciBusId,usage:0,temperature:0,vramUsed:0}));this.gpus.set(n),this.loading.set(!1),this.error.set(null),this.gpuService.watchStatus(3e3).subscribe({next:a=>{this.systemInfo.set(a.system),this.mergeUsage(a.gpus)},error:a=>{console.error("[AppComponent] status poll error:",a)}})},error:t=>{console.error("[AppComponent] static fetch error:",t),this.error.set(`Failed to fetch GPU data: ${t.message}`),this.loading.set(!1)}})}mergeUsage(e){let t=new Map;for(let n of e)t.set(n.key,n);this.gpus.update(n=>n.map(a=>{let r=t.get(a.pciBusId);return Oe(V({},a),{key:a.pciBusId,usage:r?.usage??0,temperature:r?.temperature??0,vramUsed:r?.vramUsed??0})}))}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-root"]],hostBindings:function(t,n){t&1&&A("mousemove",function(r){return n.onDrag(r)},Us)("mouseup",function(){return n.onDragEnd()},Us)},decls:2,vars:1,consts:[[1,"login-container"],[1,"login-card"],[1,"login-header"],[1,"login-icon"],[1,"mat-body-2",2,"color","#999"],[1,"login-form",3,"submit"],["appearance","outline",1,"full-width"],["matInput","","type","password","autofocus","",3,"input","value"],[1,"login-error"],["mat-raised-button","","color","primary","type","submit",1,"login-btn"],[2,"font-size","20px","vertical-align","middle"],["mode","query","color","primary"],[1,"layout"],[1,"main-content"],[1,"error-card"],[1,"splitter",3,"mousedown"],[1,"splitter-line"],[1,"journal-sidebar"],[2,"color","#f44336","font-size","48px","float","left","margin-right","16px"],[1,"empty-card"],[3,"systemInfo"],[3,"gpus"]],template:function(t,n){t&1&&M(0,IC,18,2,"div",0)(1,LC,9,6),t&2&&E(n.isAuthenticated()?1:0)},dependencies:[Ve,Si,en,on,tn,nn,ti,ei,kt,Ot,St,Qe,it,Ft,Pt,Th,Ep,Ap,Ip],styles:[".spacer[_ngcontent-%COMP%]{flex:1 1 auto}.login-container[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;min-height:calc(100vh - 56px);padding:24px;background:#f5f5f5}.login-card[_ngcontent-%COMP%]{width:100%;max-width:400px}.login-header[_ngcontent-%COMP%]{text-align:center;margin-bottom:24px}.login-header[_ngcontent-%COMP%] .login-icon[_ngcontent-%COMP%]{font-size:48px;width:48px;height:48px;line-height:48px;background:#e3f2fd;border-radius:50%;padding:8px;color:#1976d2}.login-header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:16px 0 4px;font-size:22px;font-weight:500}.login-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:12px}.login-error[_ngcontent-%COMP%]{color:#d32f2f;font-size:14px;text-align:center;padding:8px;background:#ffebee;border-radius:4px}.login-btn[_ngcontent-%COMP%]{width:100%;margin-top:8px}.full-width[_ngcontent-%COMP%]{width:100%}.layout[_ngcontent-%COMP%]{display:flex;height:100%;overflow:hidden}.layout.dragging[_ngcontent-%COMP%]{user-select:none;-webkit-user-select:none}.main-content[_ngcontent-%COMP%]{flex:1;min-width:0;overflow-y:auto;padding:24px 8px 24px 24px;max-width:100%}.splitter[_ngcontent-%COMP%]{width:8px;flex-shrink:0;cursor:col-resize;display:flex;align-items:center;justify-content:center;background:transparent;transition:background .15s}.splitter[_ngcontent-%COMP%]:hover{background:#0000000a}.splitter[_ngcontent-%COMP%] .splitter-line[_ngcontent-%COMP%]{width:2px;height:32px;border-radius:1px;background:#bdbdbd;transition:background .15s,width .15s}.splitter[_ngcontent-%COMP%]:hover .splitter-line[_ngcontent-%COMP%]{background:#757575;width:3px}.journal-sidebar[_ngcontent-%COMP%]{flex-shrink:0;overflow:hidden;padding:24px 24px 24px 8px}.error-card[_ngcontent-%COMP%], .empty-card[_ngcontent-%COMP%]{margin-top:32px;max-width:600px;margin-left:auto;margin-right:auto}[_nghost-%COMP%] mat-card-content{padding-top:10px!important;padding-bottom:10px!important}app-services[_ngcontent-%COMP%]{display:block;margin-top:24px}"]})}}return i})();gl(Pp,vm).catch(i=>console.error(i));
5597
+ HIP_VISIBLE_DEVICES=0,1,2,3`,"matTooltip","Environment variables for the service process (KEY=VALUE, one per line)",1,"env-textarea"],["align","end"],["mat-stroked-button","",3,"click"],["mat-raised-button","","color","primary",3,"click","disabled"],[1,"auto-path"],[1,"auto-from"],[1,"subsection-label"],["appearance","outline",1,"form-col-60"],["matInput","","formControlName","specDraftModel","type","text","placeholder","/path/to/draft-model or HF repo id","matTooltip","Draft model for speculative decoding (draft-model methods)"],["matInput","","formControlName","specDraftTensorParallelSize","type","number","matTooltip","Tensor parallel size of the draft model. 0 = same as main model"],["matInput","","formControlName","specNumDraftTokens","type","number","matTooltip","Number of tokens the draft model proposes in one step. 0 = default"]],template:function(t,n){if(t&1&&(s(0,"h2",4),m(1),l(),s(2,"mat-dialog-content")(3,"form",5)(4,"mat-form-field",6),v(5,"input",7),b(),s(6,"mat-label"),m(7,"Service Name"),l(),M(8,Ty,2,0,"mat-error")(9,Iy,2,0,"mat-error"),l(),s(10,"mat-form-field",6),v(11,"input",8),b(),s(12,"mat-label"),m(13,"Command (launcher or binary)"),l(),M(14,Ry,2,0,"mat-error"),l(),s(15,"mat-autocomplete",null,0),me(17,Oy,5,3,"mat-option",9,Sy),l(),s(19,"mat-expansion-panel",10)(20,"mat-expansion-panel-header")(21,"mat-panel-title"),m(22,"Model"),l()(),s(23,"mat-form-field",6),v(24,"input",11),b(),s(25,"mat-label"),m(26,"Model (serve)"),l(),M(27,Py,2,0,"mat-error"),l(),s(28,"mat-autocomplete",null,1),me(30,Fy,5,2,"mat-option",9,xt),l(),s(32,"div",12)(33,"mat-form-field",13),v(34,"input",14),b(),s(35,"mat-label"),m(36,"Tokenizer"),l()(),s(37,"mat-form-field",13)(38,"mat-select",15),me(39,Ny,2,2,"mat-option",9,xt),l(),b(),s(41,"mat-label"),m(42,"Dtype"),l()()()(),s(43,"mat-expansion-panel")(44,"mat-expansion-panel-header")(45,"mat-panel-title"),m(46,"Parallelism & Memory"),l()(),s(47,"div",12)(48,"mat-form-field",13),v(49,"input",16),b(),s(50,"mat-label"),m(51,"Tensor Parallel Size"),l()(),s(52,"mat-form-field",13),v(53,"input",17),b(),s(54,"mat-label"),m(55,"Pipeline Parallel Size"),l()(),s(56,"mat-form-field",13),v(57,"input",18),b(),s(58,"mat-label"),m(59,"Loading Workers"),l()()(),s(60,"div",12)(61,"mat-form-field",13),v(62,"input",19),b(),s(63,"mat-label"),m(64,"GPU Memory Utilization"),l()(),s(65,"mat-form-field",13),v(66,"input",20),b(),s(67,"mat-label"),m(68,"Swap Space (GiB)"),l()(),s(69,"mat-form-field",13),v(70,"input",21),b(),s(71,"mat-label"),m(72,"CPU Offload (GiB)"),l()(),s(73,"mat-form-field",13),v(74,"input",22),b(),s(75,"mat-label"),m(76,"Device"),l()()(),s(77,"div",12)(78,"mat-form-field",13)(79,"mat-select",23)(80,"mat-option",24),m(81,"(auto)"),l(),me(82,Ly,2,2,"mat-option",9,xt),l(),b(),s(84,"mat-label"),m(85,"Attention Backend"),l()(),s(86,"mat-form-field",13),v(87,"input",25),b(),s(88,"mat-label"),m(89,"KV Cache Memory (bytes)"),l()()()(),s(90,"mat-expansion-panel")(91,"mat-expansion-panel-header")(92,"mat-panel-title"),m(93,"Context & Scheduling"),l()(),s(94,"div",12)(95,"mat-form-field",13)(96,"input",26),A("blur",function(){return n.onMaxLenInput()})("keyup.enter",function(){return n.onMaxLenInput()}),l(),b(),s(97,"mat-label"),m(98,"Max Model Len"),l()(),s(99,"mat-autocomplete",null,2),me(101,Vy,2,2,"mat-option",9,My),l(),s(103,"mat-form-field",13),v(104,"input",27),b(),s(105,"mat-label"),m(106,"Max Num Seqs"),l()(),s(107,"mat-form-field",13)(108,"mat-select",28)(109,"mat-option",29),m(110,"auto"),l(),s(111,"mat-option",30),m(112,"on"),l(),s(113,"mat-option",31),m(114,"off"),l()(),b(),s(115,"mat-label"),m(116,"Chunked Prefill"),l()()(),s(117,"div",12)(118,"mat-form-field",13),v(119,"input",32),b(),s(120,"mat-label"),m(121,"Max Batched Tokens"),l()(),s(122,"mat-form-field",13),v(123,"input",33),b(),s(124,"mat-label"),m(125,"Block Size"),l()()()(),s(126,"mat-expansion-panel")(127,"mat-expansion-panel-header")(128,"mat-panel-title"),m(129,"Speculative Decoding"),l(),s(130,"mat-panel-description"),m(131,"Draft method and speculative options"),l()(),s(132,"div",12)(133,"mat-form-field",13)(134,"mat-select",34),me(135,By,2,2,"mat-option",9,Ey),l(),b(),s(137,"mat-label"),m(138,"Spec Method"),l()(),s(139,"mat-form-field",13),v(140,"input",35),b(),s(141,"mat-label"),m(142,"Spec Tokens"),l()()(),M(143,zy,15,6),l(),s(144,"mat-expansion-panel")(145,"mat-expansion-panel-header")(146,"mat-panel-title"),m(147,"Sampling Defaults"),l(),s(148,"mat-panel-description"),m(149,"Default sampling parameters for generation"),l()(),s(150,"div",12)(151,"mat-form-field",13),v(152,"input",36),b(),s(153,"mat-label"),m(154,"Temperature"),l()(),s(155,"mat-form-field",13),v(156,"input",37),b(),s(157,"mat-label"),m(158,"Top-P"),l()(),s(159,"mat-form-field",13),v(160,"input",38),b(),s(161,"mat-label"),m(162,"Top-K"),l()(),s(163,"mat-form-field",13),v(164,"input",39),b(),s(165,"mat-label"),m(166,"Min-P"),l()()(),s(167,"div",12)(168,"mat-form-field",13),v(169,"input",40),b(),s(170,"mat-label"),m(171,"Seed"),l()(),s(172,"mat-form-field",13),v(173,"input",41),b(),s(174,"mat-label"),m(175,"Repetition Penalty"),l()(),s(176,"mat-form-field",13),v(177,"input",42),b(),s(178,"mat-label"),m(179,"Max Tokens (seq)"),l()()()(),s(180,"mat-expansion-panel")(181,"mat-expansion-panel-header")(182,"mat-panel-title"),m(183,"Tools & Chat"),l(),s(184,"mat-panel-description"),m(185,"Tool calling, reasoning and cache options"),l()(),s(186,"div",12)(187,"mat-checkbox",43),m(188," Trust Remote Code "),l(),b(),s(189,"mat-checkbox",44),m(190," Enable Auto Tool Choice "),l(),b(),l(),s(191,"div",12)(192,"mat-form-field",13)(193,"mat-select",45),me(194,jy,2,2,"mat-option",9,xt),l(),b(),s(196,"mat-label"),m(197,"Tool Call Parser"),l()(),s(198,"mat-form-field",13)(199,"mat-select",46),me(200,Hy,2,2,"mat-option",9,xt),l(),b(),s(202,"mat-label"),m(203,"Reasoning Parser"),l()(),s(204,"mat-form-field",13)(205,"mat-select",47)(206,"mat-option",29),m(207,"auto"),l(),s(208,"mat-option",30),m(209,"on"),l(),s(210,"mat-option",31),m(211,"off"),l()(),b(),s(212,"mat-label"),m(213,"Prefix Caching"),l()()()(),s(214,"mat-expansion-panel")(215,"mat-expansion-panel-header")(216,"mat-panel-title"),m(217,"Server & Network"),l()(),s(218,"div",12)(219,"mat-form-field",13),v(220,"input",48),b(),s(221,"mat-label"),m(222,"Host"),l()(),s(223,"mat-autocomplete",null,3),me(225,Uy,5,3,"mat-option",9,Ay),l(),s(227,"mat-form-field",13),v(228,"input",49),b(),s(229,"mat-label"),m(230,"Port"),l()(),s(231,"mat-form-field",13),v(232,"input",50),b(),s(233,"mat-label"),m(234,"API Key"),l()()()(),s(235,"mat-expansion-panel")(236,"mat-expansion-panel-header")(237,"mat-panel-title"),m(238,"Additional"),l(),s(239,"mat-panel-description"),m(240,"Extra CLI flags and environment variables"),l()(),s(241,"mat-form-field",6),v(242,"textarea",51),b(),s(243,"mat-label"),m(244,"Extra CLI Flags (one per line)"),l()(),s(245,"mat-form-field",6),v(246,"textarea",52),b(),s(247,"mat-label"),m(248,"Environment variables (KEY=VALUE, one per line)"),l()()()()(),s(249,"mat-dialog-actions",53)(250,"button",54),A("click",function(){return n.cancel()}),m(251,"Cancel"),l(),s(252,"button",55),A("click",function(){return n.save()}),m(253),l()()),t&2){let a=Fe(16),r=Fe(29),u=Fe(100),h=Fe(224);c(),he("",n.isClone?"Clone":n.isEdit?"Edit":"Add"," vllm service"),c(2),C("formGroup",n.form),c(),p("changed",n.isControlChanged("name")),c(),C("disabled",n.isEdit&&!n.isClone),y(),c(3),E(n.form.controls.name.errors?.required?8:n.form.controls.name.errors?.pattern?9:-1),c(2),p("changed",n.isControlChanged("command")),c(),C("matAutocomplete",a),y(),c(3),E(n.form.controls.command.errors?.required?14:-1),c(3),ue(n.filteredCommands()),c(2),p("has-changed",n.isSectionChanged("model","tokenizer","dtype")),c(4),p("changed",n.isControlChanged("model")),c(),C("matAutocomplete",r),y(),c(3),E(n.form.controls.model.errors?.required?27:-1),c(3),ue(n.existingModelPaths()),c(3),p("changed",n.isControlChanged("tokenizer")),c(),y(),c(3),p("changed",n.isControlChanged("dtype")),c(),y(),c(),ue(n.dtypeOptions),c(4),p("has-changed",n.isSectionChanged("tensorParallelSize","pipelineParallelSize","maxParallelLoadingWorkers","gpuMemoryUtilization","swapSpace","cpuOffloadGb","kvCacheMemory","device","attentionBackend")),c(5),p("changed",n.isControlChanged("tensorParallelSize")),c(),y(),c(3),p("changed",n.isControlChanged("pipelineParallelSize")),c(),y(),c(3),p("changed",n.isControlChanged("maxParallelLoadingWorkers")),c(),y(),c(4),p("changed",n.isControlChanged("gpuMemoryUtilization")),c(),y(),c(3),p("changed",n.isControlChanged("swapSpace")),c(),y(),c(3),p("changed",n.isControlChanged("cpuOffloadGb")),c(),y(),c(3),p("changed",n.isControlChanged("device")),c(),y(),c(4),p("changed",n.isControlChanged("attentionBackend")),c(),y(),c(3),ue(n.attentionBackends),c(4),p("changed",n.isControlChanged("kvCacheMemory")),c(),y(),c(3),p("has-changed",n.isSectionChanged("maxModelLen","maxNumSeqs","maxNumBatchedTokens","blockSize","enableChunkedPrefill")),c(5),p("changed",n.isControlChanged("maxModelLen")),c(),C("matAutocomplete",u),y(),c(5),ue(n.maxLenPresets()),c(2),p("changed",n.isControlChanged("maxNumSeqs")),c(),y(),c(3),p("changed",n.isControlChanged("enableChunkedPrefill")),c(),y(),c(10),p("changed",n.isControlChanged("maxNumBatchedTokens")),c(),y(),c(3),p("changed",n.isControlChanged("blockSize")),c(),y(),c(3),p("has-changed",n.isSectionChanged("specMethod","specTokens","specDraftModel","specDraftTensorParallelSize","specNumDraftTokens")),c(7),p("changed",n.isControlChanged("specMethod")),c(),y(),c(),ue(n.specMethods),c(4),p("changed",n.isControlChanged("specTokens")),c(),y(),c(3),E(n.showSpecDraftParams()?143:-1),c(),p("has-changed",n.isSectionChanged("temperature","topP","topK","minP","seed","repetitionPenalty","maxNumSeq")),c(7),p("changed",n.isControlChanged("temperature")),c(),y(),c(3),p("changed",n.isControlChanged("topP")),c(),y(),c(3),p("changed",n.isControlChanged("topK")),c(),y(),c(3),p("changed",n.isControlChanged("minP")),c(),y(),c(4),p("changed",n.isControlChanged("seed")),c(),y(),c(3),p("changed",n.isControlChanged("repetitionPenalty")),c(),y(),c(3),p("changed",n.isControlChanged("maxNumSeq")),c(),y(),c(3),p("has-changed",n.isSectionChanged("trustRemoteCode","enableAutoToolChoice","toolCallParser","reasoningParser","enablePrefixCaching")),c(7),p("changed",n.isControlChanged("trustRemoteCode")),y(),c(2),p("changed",n.isControlChanged("enableAutoToolChoice")),y(),c(3),p("changed",n.isControlChanged("toolCallParser")),c(),C("disabled",n.isToolCallParserDisabled()),y(),c(),ue(n.toolCallParsers),c(4),p("changed",n.isControlChanged("reasoningParser")),c(),y(),c(),ue(n.reasoningParsers),c(4),p("changed",n.isControlChanged("enablePrefixCaching")),c(),y(),c(9),p("has-changed",n.isSectionChanged("host","port","apiKey")),c(5),p("changed",n.isControlChanged("host")),c(),C("matAutocomplete",h),y(),c(5),ue(n.filteredHosts()),c(2),p("changed",n.isControlChanged("port")),c(),y(),c(3),p("changed",n.isControlChanged("apiKey")),c(),y(),c(3),p("has-changed",n.isSectionChanged("extraFlags","envText")),c(6),p("changed",n.isControlChanged("extraFlags")),c(),y(),c(3),p("changed",n.isControlChanged("envText")),c(),y(),c(6),C("disabled",n.form.invalid),c(),he(" ",n.isEdit&&!n.isClone?"Save":"Create"," ")}},dependencies:[Ve,hn,Co,Ei,ya,Ai,mn,tc,ec,pn,Ut,ji,xn,Cn,vt,Wi,Qe,it,Fo,Lc,Os,ja,Ts,Rs,Is,St,kt,Ot,fn,ti,ei,Lt,oi,ri,ai,Lo,No,Ps,Ha],styles:['@charset "UTF-8";.vllm-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:8px;min-width:640px}.form-row[_ngcontent-%COMP%]{display:flex;gap:12px;margin-bottom:4px;align-items:center}.form-col[_ngcontent-%COMP%]{flex:1}.form-col-60[_ngcontent-%COMP%]{flex:3}.full-width[_ngcontent-%COMP%]{width:100%}.auto-path[_ngcontent-%COMP%]{font-family:monospace}.auto-from[_ngcontent-%COMP%]{margin-left:8px;opacity:.6;font-size:12px}.flags-textarea[_ngcontent-%COMP%], .env-textarea[_ngcontent-%COMP%]{overflow-x:auto}mat-dialog-content[_ngcontent-%COMP%]{padding-top:10px!important;max-height:80vh}mat-expansion-panel[_ngcontent-%COMP%]{margin-bottom:0}mat-dialog-actions[_ngcontent-%COMP%]{gap:8px}.subsection-label[_ngcontent-%COMP%]{font-size:12px;font-weight:500;color:#0009;margin:4px 0 14px;text-transform:uppercase;letter-spacing:.5px}mat-expansion-panel.has-changed[_ngcontent-%COMP%] mat-panel-title[_ngcontent-%COMP%]{font-weight:700}mat-form-field.changed[_ngcontent-%COMP%] .mat-mdc-form-field-infix input, mat-form-field.changed[_ngcontent-%COMP%] .mat-mdc-form-field-infix .mat-mdc-select{font-weight:700}mat-checkbox.changed[_ngcontent-%COMP%] label{font-weight:700}']})}}return i})();function si(i,o,e){let t=Vo(i,o);return t!==null?t:e}function At(i,o,e){let t=Vo(i,o);if(t!==null){let n=parseInt(t,10);return isNaN(n)?e:n}return e}function Xn(i,o,e){let t=Vo(i,o);if(t!==null){let n=parseFloat(t);return isNaN(n)?e:n}return e}function Zy(i,o,e,t){let n=null;for(let a of i){let[r,...u]=a.split(/\s+/);r===o?u.join(" ").trim()==="false"?n="off":n="on":r===e&&(n="off")}return n??t}var Qy=(i,o)=>o.name;function Jy(i,o){if(i&1){let e=Ue();s(0,"button",22),A("click",function(n){xe(e);let a=D(2).$implicit;return D(2).control(a.name,"start"),we(n.stopPropagation())}),s(1,"mat-icon"),m(2,"play_arrow"),l(),m(3," Start "),l()}if(i&2){let e=D(2).$implicit,t=D(2);C("disabled",t.busy()?.name===e.name)}}function eC(i,o){if(i&1){let e=Ue();s(0,"button",23),A("click",function(n){xe(e);let a=D(2).$implicit;return D(2).control(a.name,"stop"),we(n.stopPropagation())}),s(1,"mat-icon"),m(2,"stop"),l(),m(3," Stop "),l()}if(i&2){let e=D(2).$implicit,t=D(2);C("disabled",t.busy()?.name===e.name)}}function tC(i,o){if(i&1){let e=Ue();s(0,"button",24),A("click",function(n){xe(e);let a=D(2).$implicit;return D(2).control(a.name,"disable"),we(n.stopPropagation())}),s(1,"mat-icon"),m(2,"lock"),l(),m(3," Disable "),l()}if(i&2){let e=D(2).$implicit,t=D(2);C("disabled",t.busy()?.name===e.name)}}function iC(i,o){if(i&1){let e=Ue();s(0,"button",24),A("click",function(n){xe(e);let a=D(2).$implicit;return D(2).control(a.name,"enable"),we(n.stopPropagation())}),s(1,"mat-icon"),m(2,"lock_open"),l(),m(3," Enable "),l()}if(i&2){let e=D(2).$implicit,t=D(2);C("disabled",e.enabled||t.busy()?.name===e.name)}}function nC(i,o){if(i&1&&(M(0,Jy,4,1,"button",19)(1,eC,4,1,"button",20),M(2,tC,4,1,"button",21)(3,iC,4,1,"button",21)),i&2){let e=D().$implicit;E(e.running?1:0),c(2),E(e.enabled?2:3)}}function oC(i,o){if(i&1){let e=Ue();s(0,"tr",12),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.selectedServiceService.select(n.name))}),s(1,"td")(2,"div",13),v(3,"span",14),s(4,"span",15),m(5),l()()(),s(6,"td",16),M(7,nC,4,2),l(),s(8,"td",16)(9,"div")(10,"button",17)(11,"mat-icon"),m(12,"more_vert"),l()(),s(13,"mat-menu",18,2)(15,"button",7),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.editService(n))}),s(16,"mat-icon"),m(17,"edit"),l(),s(18,"span"),m(19,"Edit"),l()(),s(20,"button",7),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.cloneService(n))}),s(21,"mat-icon"),m(22,"content_copy"),l(),s(23,"span"),m(24,"Clone"),l()(),s(25,"button",7),A("click",function(){let n=xe(e).$implicit,a=D(2);return we(a.deleteService(n.name))}),s(26,"mat-icon"),m(27,"delete"),l(),s(28,"span"),m(29,"Delete"),l()()()()()()}if(i&2){let e=o.$implicit,t=Fe(14);p("custom",e.hasConfig),c(3),p("running",e.running),c(),p("disabled",!e.enabled),c(),q(e.name),c(2),E(e.installed?7:-1),c(2),He("visibility",e.hasConfig?"visible":"hidden"),c(),C("matMenuTriggerFor",t)}}function aC(i,o){if(i&1&&(s(0,"table",9)(1,"tbody"),me(2,oC,30,11,"tr",11,Qy),l()()),i&2){let e=D();c(2),ue(e.unified())}}function rC(i,o){i&1&&(s(0,"div",10)(1,"p"),m(2,'No services configured. Click "Managed services" to select system services or "Custom service" to create one.'),l()())}var Ep=(()=>{class i{constructor(){this.serviceService=d(_t),this.serviceList=d(ks),this.selectedServiceService=d(Ds),this.dialog=d(To),this.snackBar=d(ws),this.services=this.serviceList.services,this.configs=R([]),this.loading=R(!0),this.busy=R(null),this.unified=$(()=>{let e=this.services(),t=this.configs(),n=new Map;for(let u of t)n.set(u.name,u);let a=e.filter(u=>n.has(u.name)).map(u=>{let h=n.get(u.name)??null;return{name:u.name,running:u.running,enabled:u.enabled,installed:u.installed,pid:u.pid,error:u.error,config:h,hasConfig:!0}}),r=e.filter(u=>!n.has(u.name)).map(u=>Oe(V({},u),{config:null,hasConfig:!1}));return[...a,...r]})}ngOnInit(){this.load()}load(){return ye(this,null,function*(){this.loading.set(!0);try{yield this.serviceList.refresh(),this.configs.set(yield Te(this.serviceService.fetchConfigs()))}catch(e){console.error("[ServicesComponent] load error:",e)}finally{this.loading.set(!1)}})}control(e,t){return ye(this,null,function*(){let n=this.busy();if(!(n&&n.name===e&&n.action===t)){this.selectedServiceService.select(e),this.busy.set({name:e,action:t});try{let a=yield Te(this.serviceService.control(e,t));a.error&&this.showError(`${e}: ${a.error}`),yield this.load()}catch(a){this.showError(`${e}: ${String(a.error||a)}`)}finally{this.busy.set(null)}}})}showError(e){this.snackBar.open(e,"Dismiss",{duration:8e3,horizontalPosition:"center",verticalPosition:"top"})}manageServices(){this.dialog.open(mp,{maxWidth:"600px"}).afterClosed().subscribe(t=>{t&&this.load()})}archiveServices(){this.dialog.open(hp,{minWidth:"840px"}).afterClosed().subscribe(t=>{t&&this.load()})}addService(e){this.openDialog(null,e)}editService(e){this.selectedServiceService.select(e.name),this.openDialog(e.config,e.config?.type)}cloneService(e){if(!e.config)return;let t=Oe(V({},e.config),{name:this.uniqueCloneName(e.name)});this.openDialog(t,t.type,!0)}uniqueCloneName(e){let t=new Set(this.configs().map(a=>a.name));if(!t.has(`${e}-copy`))return`${e}-copy`;let n=2;for(;t.has(`${e}-copy-${n}`);)n++;return`${e}-copy-${n}`}deleteService(e){return ye(this,null,function*(){this.selectedServiceService.select(e);try{yield Te(this.serviceService.deleteConfig(e)),yield this.load()}catch(t){this.showError(`Delete "${e}": ${String(t)}`)}})}hasFlags(e){return e.flags.length>0}openDialog(e,t,n=!1){let a=t??e?.type??"generic";if(a==="llama-server"){let r={config:e,allConfigs:this.configs(),clone:n},u=this.dialog.open(Sp,{data:r,minWidth:"800px"});this.handleDialogResult(u,e,n)}else if(a==="vllm"){let r={config:e,allConfigs:this.configs(),clone:n},u=this.dialog.open(Mp,{data:r,minWidth:"800px"});this.handleDialogResult(u,e,n)}else{let r={config:e,allConfigs:this.configs(),clone:n},u=this.dialog.open(op,{data:r,minWidth:"1000px"});this.handleDialogResult(u,e,n)}}handleDialogResult(e,t,n=!1){e.afterClosed().subscribe(a=>ye(this,null,function*(){if(a)try{if(n)yield Te(this.serviceService.saveConfig(a));else{let r=t?.name??null;if(r!==null&&r!==a.name){let h=this.unified().find(w=>w.name===r),g=h?.running??!1,_=h?.enabled??!1;yield Te(this.serviceService.deleteConfig(r)),yield Te(this.serviceService.saveConfig(a)),_&&(yield Te(this.serviceService.control(a.name,"enable"))),g&&(yield Te(this.serviceService.control(a.name,"start")))}else yield Te(this.serviceService.saveConfig(a))}}catch(r){this.showError(`Save: ${String(r)}`)}finally{yield this.load()}}))}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-services"]],decls:43,vars:3,consts:[["servicesMenu","matMenu"],["addMenu",""],["serviceMenu","matMenu"],[1,"services-card"],[1,"section-header"],["mat-icon-button","","title","Services actions",1,"header-menu-btn",3,"matMenuTriggerFor"],["xPosition","before"],["mat-menu-item","",3,"click"],["mat-menu-item","",3,"matMenuTriggerFor"],[1,"services-list"],[1,"empty"],[3,"custom"],[3,"click"],[1,"service-name"],[1,"status-dot"],[1,"name-text"],[1,"service-actions-cell"],["mat-icon-button","","title","Service actions",3,"matMenuTriggerFor"],["yPosition","below"],["mat-raised-button","","color","primary",3,"disabled"],["mat-raised-button","","color","warn",3,"disabled"],["mat-stroked-button","",3,"disabled"],["mat-raised-button","","color","primary",3,"click","disabled"],["mat-raised-button","","color","warn",3,"click","disabled"],["mat-stroked-button","",3,"click","disabled"]],template:function(t,n){if(t&1&&(s(0,"div",3)(1,"div",4)(2,"h2"),m(3,"Services"),l(),s(4,"button",5)(5,"mat-icon"),m(6,"more_vert"),l()(),s(7,"mat-menu",6,0)(9,"button",7),A("click",function(){return n.manageServices()}),s(10,"mat-icon"),m(11,"tune"),l(),s(12,"span"),m(13,"Managed services"),l()(),s(14,"button",7),A("click",function(){return n.archiveServices()}),s(15,"mat-icon"),m(16,"archive"),l(),s(17,"span"),m(18,"Archive"),l()(),s(19,"button",8)(20,"mat-icon"),m(21,"add"),l(),s(22,"span"),m(23,"Custom service"),l()()(),s(24,"mat-menu",null,1)(26,"button",7),A("click",function(){return n.addService("generic")}),s(27,"mat-icon"),m(28,"settings"),l(),s(29,"span"),m(30,"Generic service"),l()(),s(31,"button",7),A("click",function(){return n.addService("llama-server")}),s(32,"mat-icon"),m(33,"smart_toy"),l(),s(34,"span"),m(35,"llama-server"),l()(),s(36,"button",7),A("click",function(){return n.addService("vllm")}),s(37,"mat-icon"),m(38,"bolt"),l(),s(39,"span"),m(40,"vllm"),l()()()(),M(41,aC,4,0,"table",9)(42,rC,3,0,"div",10),l()),t&2){let a=Fe(8),r=Fe(25);c(4),C("matMenuTriggerFor",a),c(15),C("matMenuTriggerFor",r),c(22),E(n.unified().length>0?41:n.loading()?-1:42)}},dependencies:[Ve,Qe,it,Hi,So,xs,yn,qn,Cs,Ft,Pt],styles:[".services-card[_ngcontent-%COMP%]{margin-bottom:24px}.section-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px;margin-top:8px}.section-header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:1.1rem;font-weight:600;color:#333}.section-header[_ngcontent-%COMP%] .header-menu-btn[_ngcontent-%COMP%]{color:#666}.services-list[_ngcontent-%COMP%]{width:100%;border-collapse:collapse}.services-list[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]{border-bottom:1px solid #e0e0e0;transition:background-color .2s ease}.services-list[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:hover{background-color:#fff}.services-list[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:last-child{border-bottom:none}.services-list[_ngcontent-%COMP%] tr.custom[_ngcontent-%COMP%], .services-list[_ngcontent-%COMP%] tr.custom[_ngcontent-%COMP%]:first-child td[_ngcontent-%COMP%]:first-child{border-left:3px solid #7c4dff}.services-list[_ngcontent-%COMP%] td[_ngcontent-%COMP%]{padding:4px 12px;vertical-align:middle}.service-name[_ngcontent-%COMP%]{font-size:1rem;font-weight:600;white-space:nowrap;display:flex;align-items:center;gap:8px}.service-name[_ngcontent-%COMP%] .status-dot[_ngcontent-%COMP%]{display:inline-block;width:10px;height:10px;border-radius:50%;background-color:#bdbdbd}.service-name[_ngcontent-%COMP%] .status-dot.running[_ngcontent-%COMP%]{background-color:#4caf50}.service-name[_ngcontent-%COMP%] .name-text[_ngcontent-%COMP%]{color:#212121}.service-name[_ngcontent-%COMP%] .name-text.disabled[_ngcontent-%COMP%]{color:#9e9e9e}.service-actions-cell[_ngcontent-%COMP%]{white-space:nowrap}.service-actions-cell[_ngcontent-%COMP%] button[_ngcontent-%COMP%] + button[_ngcontent-%COMP%]{margin-left:8px}.status-chip[_ngcontent-%COMP%], .enabled-chip[_ngcontent-%COMP%]{font-size:.8rem;font-weight:500}.status-chip.running[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #a5d6a7}.status-chip.stopped[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #ef9a9a}.enabled-chip.enabled[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #90caf9}.enabled-chip.disabled[_ngcontent-%COMP%]{--mat-chip-elevated-container-color: #bdbdbd}.empty[_ngcontent-%COMP%]{text-align:center;padding:24px;color:#999;font-size:.9rem}.empty[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}"]})}}return i})();var sC=["journalBody"],lC=(i,o)=>o.name;function cC(i,o){if(i&1&&(s(0,"mat-option",7),m(1),l()),i&2){let e=o.$implicit;C("value",e.name),c(),q(e.name)}}function dC(i,o){if(i&1){let e=Ue();s(0,"button",10),A("click",function(){xe(e);let n=D(2);return we(n.toggleWordWrap())}),s(1,"mat-icon"),m(2,"wrap_text"),l()()}}function mC(i,o){if(i&1){let e=Ue();s(0,"button",11),A("click",function(){xe(e);let n=D(2);return we(n.toggleWordWrap())}),s(1,"mat-icon"),m(2,"wrap_text"),l()()}}function uC(i,o){if(i&1){let e=Ue();s(0,"mat-select",6),A("ngModelChange",function(n){xe(e);let a=D();return we(a.onServiceChange(n))}),s(1,"mat-option",7),m(2,"\u2014 None \u2014"),l(),me(3,cC,2,2,"mat-option",7,lC),l(),b(),M(5,dC,3,0,"button",8)(6,mC,3,0,"button",9)}if(i&2){let e=D();C("ngModel",e.selectedService()),y(),c(),C("value",null),c(2),ue(e.services()),c(2),E(e.wordWrap()?5:6)}}function hC(i,o){if(i&1&&(s(0,"div",3),m(1),l()),i&2){let e=D();c(),q(e.error())}}function pC(i,o){if(i&1&&(s(0,"div",4,0)(2,"pre"),m(3),l()()),i&2){let e=D();c(2),p("wrap-on",e.wordWrap()),c(),q(e.journalText())}}function fC(i,o){i&1&&(s(0,"div",5)(1,"p"),m(2,"No service selected"),l()())}var gC=40,Ap=(()=>{class i{toggleWordWrap(){this.wordWrap.update(e=>!e)}constructor(){this.serviceService=d(_t),this.selectedServiceService=d(Ds),this.serviceList=d(ks),this.cdr=d(te),this.services=this.serviceList.services,this.servicesLoaded=this.serviceList.loaded,this.journalLines=R([]),this.journalLoading=R(!1),this.journalError=R(null),this.error=$(()=>this.serviceList.error()??this.journalError()),this.selectedService=$(()=>this.selectedServiceService.selectedService()),this.wordWrap=R(!0),this.journalText=$(()=>{let e=this.journalLines();return e.length===0?"":e.map(t=>t.timestamp?`${t.timestamp} ${t.message}`:t.message).join(`
5598
+ `)}),zt(()=>{if(!this.servicesLoaded())return;let e=this.selectedService();e!==null&&!this.services().some(t=>t.name===e)&&this.selectedServiceService.select(null)}),zt(()=>{if(!this.servicesLoaded())return;this.selectedService()?(this.journalLines.set([]),this.journalError.set(null),this.restartPolling()):(this.stopPolling(),this.journalLines.set([]))}),this.serviceList.refresh()}ngAfterViewInit(){this.scrollToBottom()}ngOnDestroy(){this.stopPolling()}onServiceChange(e){this.selectedServiceService.select(e)}restartPolling(){this.stopPolling(),this.fetchJournal(),this.journalSub=Ya(0,1e3).subscribe(()=>this.fetchJournal())}stopPolling(){this.journalSub&&(this.journalSub.unsubscribe(),this.journalSub=void 0)}fetchJournal(){let e=this.selectedService();e&&(this.isTextSelected()||(this.journalLoading.set(!0),this.serviceService.fetchJournal(e,100).subscribe({next:t=>{let n=this.isScrolledToBottom();this.journalLines.set(t),this.journalError.set(null),this.journalLoading.set(!1),this.cdr.markForCheck(),requestAnimationFrame(()=>{n&&this.scrollToBottom()})},error:t=>{this.journalError.set(t.message),this.journalLoading.set(!1),this.cdr.markForCheck()}})))}get scrollContainer(){return this.journalBody?.nativeElement??null}isTextSelected(){let e=typeof window<"u"?window:null;if(!e)return!1;let t=e.getSelection();if(!t||t.isCollapsed||!t.rangeCount)return!1;let n=this.scrollContainer;return n?n.contains(t.anchorNode):!1}isScrolledToBottom(){let e=this.scrollContainer;return e?e.scrollHeight-e.scrollTop-e.clientHeight<=gC:!0}scrollToBottom(){let e=this.scrollContainer;e&&(e.scrollTop=e.scrollHeight)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-journal-panel"]],viewQuery:function(t,n){if(t&1&&Me(sC,5),t&2){let a;O(a=P())&&(n.journalBody=a.first)}},decls:9,vars:3,consts:[["journalBody",""],[1,"journal-card"],[1,"journal-header"],[1,"journal-error"],[1,"journal-body"],[1,"journal-body","journal-empty"],["disableOptionCentering","",1,"service-select",3,"ngModelChange","ngModel"],[3,"value"],["mat-flat-button","","color","primary","aria-label","Disable word wrap"],["mat-stroked-button","","aria-label","Enable word wrap"],["mat-flat-button","","color","primary","aria-label","Disable word wrap",3,"click"],["mat-stroked-button","","aria-label","Enable word wrap",3,"click"]],template:function(t,n){t&1&&(s(0,"mat-card",1)(1,"mat-card-content")(2,"div",2)(3,"h2"),m(4,"Journal"),l(),M(5,uC,7,3),l(),M(6,hC,2,1,"div",3),M(7,pC,4,3,"div",4)(8,fC,3,0,"div",5),l()()),t&2&&(c(5),E(n.servicesLoaded()&&n.services().length>0?5:-1),c(),E(n.error()?6:-1),c(),E(n.selectedService()?7:8))},dependencies:[Ve,on,tn,nn,Lo,No,vt,Qe,it,Ft,Pt,Si,hn,Ai,nc],styles:[".journal-card[_ngcontent-%COMP%]{height:100%;display:flex;flex-direction:column;overflow:hidden}.journal-card[_ngcontent-%COMP%] mat-card-content[_ngcontent-%COMP%]{flex:1;display:flex;flex-direction:column;overflow:hidden;padding-bottom:8px}.journal-header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:12px;margin-bottom:12px;flex-shrink:0}.journal-header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:20px;font-weight:500}.service-select[_ngcontent-%COMP%]{flex:1;min-width:150px}.journal-error[_ngcontent-%COMP%]{color:#f44336;font-size:13px;margin-bottom:8px;flex-shrink:0}.journal-body[_ngcontent-%COMP%]{flex:1;overflow-y:auto;background:#1e1e1e;border-radius:4px;padding:8px;min-height:0}.journal-body[_ngcontent-%COMP%]::-webkit-scrollbar{width:8px}.journal-body[_ngcontent-%COMP%]::-webkit-scrollbar-track{background:#2d2d2d;border-radius:4px}.journal-body[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background:#555;border-radius:4px}.journal-body[_ngcontent-%COMP%]::-webkit-scrollbar-thumb:hover{background:#777}.journal-body[_ngcontent-%COMP%]{scrollbar-width:thin;scrollbar-color:#555 #2d2d2d}.journal-body[_ngcontent-%COMP%] pre[_ngcontent-%COMP%]{margin:0;font-family:Courier New,Courier,monospace;font-size:12px;line-height:1.6;color:#d4d4d4;white-space:pre}.journal-body[_ngcontent-%COMP%] pre.wrap-on[_ngcontent-%COMP%]{white-space:pre-wrap}.journal-empty[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center}.journal-empty[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0;color:#888;font-size:14px}[_nghost-%COMP%] .mdc-button{min-width:32px}[_nghost-%COMP%] .mat-mdc-unelevated-button>.mat-icon, [_nghost-%COMP%] .mat-mdc-outlined-button>.mat-icon{margin-right:0}"]})}}return i})();var Fs=(()=>{class i{constructor(){this.http=d(Qt),this.baseUrl="/api/system"}reboot(){return ye(this,null,function*(){yield Te(this.http.post(`${this.baseUrl}/reboot`,null))})}shutdown(){return ye(this,null,function*(){yield Te(this.http.post(`${this.baseUrl}/shutdown`,null))})}getSystemInfo(){return ye(this,null,function*(){return Te(this.http.get(`${this.baseUrl}/info`))})}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=re({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var _C=(i,o)=>o.device,vC=(i,o)=>o.path;function bC(i,o){i&1&&v(0,"mat-progress-bar",2)}function yC(i,o){if(i&1&&(s(0,"p",3),m(1),l()),i&2){let e=D();c(),q(e.error())}}function CC(i,o){if(i&1&&(s(0,"span",11),m(1),l()),i&2){let e=D(2);c(),q(e.info().uptime)}}function xC(i,o){if(i&1&&(s(0,"div",12)(1,"span",13),m(2,"Version"),l(),s(3,"span",14),m(4),l()()),i&2){let e=D(2);c(4),q(e.info().os.version)}}function wC(i,o){if(i&1&&(s(0,"div",16)(1,"div",18)(2,"span",19),m(3),l(),s(4,"span",20),m(5),l()(),s(6,"div",21),v(7,"div",22),l(),s(8,"div",23)(9,"span"),m(10),l(),s(11,"span"),m(12),l()()()),i&2){let e=o.$implicit,t=D(2);c(3),q(e.device),c(2),q(e.mountPoint),c(2),He("width",e.usePercent,"%")("background",e.usePercent>90?"#f44336":e.usePercent>75?"#ff9800":"#4caf50"),c(3),An("",t.formatBytes(e.available)," free of ",t.formatBytes(e.total)),c(2),he("",e.usePercent,"% used")}}function DC(i,o){if(i&1&&(s(0,"div",27)(1,"span",31),m(2,"Last"),l(),s(3,"span",32),m(4),Uo(5,"date"),l()()),i&2){let e=D(3);c(4),q(Go(5,1,e.info().timeshift.lastSnapshot,"medium"))}}function kC(i,o){if(i&1&&(s(0,"mat-chip",33),m(1),l()),i&2){let e=o.$implicit;c(),q(e)}}function SC(i,o){if(i&1&&(s(0,"mat-chip-set"),me(1,kC,2,1,"mat-chip",33,xt),l()),i&2){let e=D(3);c(),ue(e.info().timeshift.schedules)}}function MC(i,o){if(i&1&&(s(0,"div",6)(1,"h3"),m(2,"Timeshift Backup"),l(),s(3,"div",7)(4,"div",8)(5,"mat-chip-set")(6,"mat-chip",24),m(7),l(),s(8,"mat-chip",25),m(9),l()(),s(10,"span",26),m(11),l()(),M(12,DC,6,4,"div",27),s(13,"div",28),v(14,"div",29),l(),s(15,"div",30)(16,"span"),m(17),l(),M(18,SC,3,0,"mat-chip-set"),l()()(),v(19,"mat-divider",15)),i&2){let e=D(2);c(7),q(e.info().timeshift.mode),c(2),q(e.info().timeshift.device),c(2),he("",e.info().timeshift.snapshots," snapshots"),c(),E(e.info().timeshift.lastSnapshot?12:-1),c(2),He("width",e.info().timeshift.totalSpace>0?(e.info().timeshift.totalSpace-e.info().timeshift.freeSpace)/e.info().timeshift.totalSpace*100:0,"%")("background",e.info().timeshift.totalSpace>0&&(e.info().timeshift.totalSpace-e.info().timeshift.freeSpace)/e.info().timeshift.totalSpace>.9?"#f44336":e.info().timeshift.totalSpace>0&&(e.info().timeshift.totalSpace-e.info().timeshift.freeSpace)/e.info().timeshift.totalSpace>.75?"#ff9800":"#4caf50"),c(3),An("",e.formatBytes(e.info().timeshift.freeSpace)," free of ",e.formatBytes(e.info().timeshift.totalSpace)),c(),E(e.info().timeshift.schedules.length>0?18:-1)}}function EC(i,o){if(i&1&&m(0),i&2){let e=D().$implicit,t=D(2);he(" ",t.formatBytes(e.size)," ")}}function AC(i,o){i&1&&m(0," \u2014 ")}function TC(i,o){if(i&1&&(s(0,"div",17)(1,"span",34),m(2),l(),s(3,"span",35),M(4,EC,1,1)(5,AC,1,0),l()()),i&2){let e=o.$implicit;c(2),q(e.path),c(2),E(e.exists?4:5)}}function IC(i,o){if(i&1&&(s(0,"div",6)(1,"h3"),m(2,"Operating System"),l(),s(3,"div",7)(4,"div",8)(5,"mat-chip-set")(6,"mat-chip",9),m(7),l(),s(8,"mat-chip",10),m(9),l()(),M(10,CC,2,1,"span",11),l(),M(11,xC,5,1,"div",12),s(12,"div",12)(13,"span",13),m(14,"Kernel"),l(),s(15,"span",14),m(16),l()()()(),v(17,"mat-divider",15),s(18,"div",6)(19,"h3"),m(20,"Disks"),l(),me(21,wC,13,9,"div",16,_C),l(),v(23,"mat-divider",15),M(24,MC,20,11),s(25,"div",6)(26,"h3"),m(27,"System Logs"),l(),me(28,TC,6,2,"div",17,vC),l()),i&2){let e=D();c(7),q(e.info().hostname),c(2),q(e.info().os.name),c(),E(e.info().uptime?10:-1),c(),E(e.info().os.version?11:-1),c(5),q(e.info().kernel),c(5),ue(e.info().disks),c(3),E(e.info().timeshift?24:-1),c(4),ue(e.info().logs)}}var Tp=(()=>{class i{constructor(){this.systemService=d(Fs),this.dialogRef=d(gt),this.loading=R(!0),this.info=R(null),this.error=R(null)}ngOnInit(){return ye(this,null,function*(){try{let e=yield this.systemService.getSystemInfo();this.info.set(e)}catch(e){this.error.set(e instanceof Error?e.message:"Failed to load system info")}finally{this.loading.set(!1)}})}formatBytes(e){return e===0?"0 B":`${(e/(1024*1024*1024)).toFixed(1)} GB`}close(){this.dialogRef.close()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-system-info-dialog"]],decls:12,vars:1,consts:[[1,"dialog-container"],["mat-dialog-title",""],["mode","indeterminate"],[1,"dialog-error"],["align","end"],["mat-raised-button","","color","primary",3,"click"],[1,"info-section"],[1,"info-card"],[1,"info-card-header"],[1,"hostname-chip"],[1,"distro-chip"],[1,"os-uptime"],[1,"info-row"],[1,"info-label"],[1,"info-value"],[1,"section-divider"],[1,"disk-row"],[1,"log-row"],[1,"disk-header"],[1,"disk-device"],[1,"disk-mount"],[1,"disk-bar-bg"],[1,"disk-bar-fill"],[1,"disk-details"],[1,"mode-chip"],[1,"device-chip"],[1,"timeshift-snapshots"],[1,"timeshift-row"],[1,"timeshift-disk-bar-bg"],[1,"timeshift-disk-bar-fill"],[1,"timeshift-disk-details"],[1,"timeshift-label"],[1,"timeshift-value"],[1,"schedule-chip"],[1,"log-path"],[1,"log-size"]],template:function(t,n){t&1&&(s(0,"div",0)(1,"h2",1)(2,"mat-icon"),m(3,"info"),l(),m(4," System Info "),l(),s(5,"mat-dialog-content"),M(6,bC,1,0,"mat-progress-bar",2)(7,yC,2,1,"p",3)(8,IC,30,6),l(),s(9,"mat-dialog-actions",4)(10,"button",5),A("click",function(){return n.close()}),m(11,"OK"),l()()()),t&2&&(c(6),E(n.loading()?6:n.error()?7:n.info()?8:-1))},dependencies:[Ve,Qe,it,Lt,oi,ri,ai,Si,en,As,Vc,Ft,Pt,So,Ta,Eh,ll],styles:[".dialog-container[_ngcontent-%COMP%]{min-width:480px}.dialog-error[_ngcontent-%COMP%]{color:#f44336;padding:8px 0}.info-section[_ngcontent-%COMP%]{margin-bottom:8px}.info-section[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin:0 0 8px;font-size:14px;font-weight:600;color:#666;text-transform:uppercase;letter-spacing:.5px}.info-row[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:4px 0}.info-row[_ngcontent-%COMP%] .info-label[_ngcontent-%COMP%]{color:#666;font-size:14px}.info-row[_ngcontent-%COMP%] .info-value[_ngcontent-%COMP%]{font-family:monospace;font-size:13px;color:#333}.section-divider[_ngcontent-%COMP%]{margin:12px 0}.disk-row[_ngcontent-%COMP%]{margin-bottom:12px}.disk-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;margin-bottom:4px}.disk-header[_ngcontent-%COMP%] .disk-device[_ngcontent-%COMP%]{font-family:monospace;font-size:13px}.disk-header[_ngcontent-%COMP%] .disk-mount[_ngcontent-%COMP%]{font-size:13px;color:#666}.disk-bar-bg[_ngcontent-%COMP%]{height:6px;background:#e0e0e0;border-radius:3px;overflow:hidden;margin-bottom:2px}.disk-bar-fill[_ngcontent-%COMP%]{height:100%;border-radius:3px}.disk-details[_ngcontent-%COMP%]{display:flex;justify-content:space-between;font-size:12px;color:#666}.info-card[_ngcontent-%COMP%]{background:#f5f5f5;border-radius:8px;padding:12px}.info-card-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}.info-card-header[_ngcontent-%COMP%] .hostname-chip[_ngcontent-%COMP%]{font-family:monospace;background:#e8eaf6!important;color:#303f9f!important}.info-card-header[_ngcontent-%COMP%] .distro-chip[_ngcontent-%COMP%], .info-card-header[_ngcontent-%COMP%] .mode-chip[_ngcontent-%COMP%]{font-weight:600;background:#e3f2fd!important;color:#1976d2!important}.info-card-header[_ngcontent-%COMP%] .device-chip[_ngcontent-%COMP%]{font-family:monospace;background:#e8eaf6!important;color:#303f9f!important}.os-uptime[_ngcontent-%COMP%], .timeshift-snapshots[_ngcontent-%COMP%]{font-size:13px;color:#666;white-space:nowrap}.timeshift-row[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:4px 0;margin-bottom:6px}.timeshift-row[_ngcontent-%COMP%] .timeshift-label[_ngcontent-%COMP%]{color:#666;font-size:13px}.timeshift-row[_ngcontent-%COMP%] .timeshift-value[_ngcontent-%COMP%]{font-size:13px;color:#333}.timeshift-disk-bar-bg[_ngcontent-%COMP%]{height:6px;background:#e0e0e0;border-radius:3px;overflow:hidden;margin-bottom:4px}.timeshift-disk-bar-fill[_ngcontent-%COMP%]{height:100%;border-radius:3px}.timeshift-disk-details[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;font-size:12px;color:#666}.timeshift-disk-details[_ngcontent-%COMP%] .schedule-chip[_ngcontent-%COMP%]{font-size:11px;background:#fff3e0!important;color:#e65100!important}.log-row[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:4px 0}.log-row[_ngcontent-%COMP%] .log-path[_ngcontent-%COMP%]{font-family:monospace;font-size:13px}.log-row[_ngcontent-%COMP%] .log-size[_ngcontent-%COMP%]{font-family:monospace;font-size:13px;color:#333}"]})}}return i})();var Ip=(()=>{class i{constructor(){this.systemInfo=ao.required(),this.systemService=d(Fs),this.dialog=d(To)}openSystemInfo(){this.dialog.open(Tp,{disableClose:!1})}reboot(){return ye(this,null,function*(){confirm("Reboot the server?")&&(yield this.systemService.reboot())})}shutdown(){return ye(this,null,function*(){confirm("Shutdown the server?")&&(yield this.systemService.shutdown())})}formatBytes(e){let t=e/1073741824;return`${Math.ceil(t)} GB`}ceilCpu(e){return Math.ceil(e)}colorForUsage(e){return e<40?"#4caf50":e<75?"#ff9800":"#f44336"}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-system-bar"]],inputs:{systemInfo:[1,"systemInfo"]},decls:48,vars:16,consts:[["menu","matMenu"],[1,"system-bar"],[1,"system-panel"],[1,"panel-body"],[1,"panel-icon"],[1,"panel-content"],[1,"panel-header"],[1,"panel-label"],[1,"panel-value"],[1,"bar-bg"],[1,"bar-fill"],[1,"server-controls"],["mat-icon-button","","color","warn","title","Server actions",3,"matMenuTriggerFor"],["yPosition","below"],["mat-menu-item","",3,"click"]],template:function(t,n){if(t&1&&(s(0,"div",1)(1,"mat-card",2)(2,"mat-card-content")(3,"div",3)(4,"mat-icon",4),m(5,"dynamic_feed"),l(),s(6,"div",5)(7,"div",6)(8,"span",7),m(9,"CPU"),l(),s(10,"span",8),m(11),l()(),s(12,"div",9),v(13,"div",10),l()()()()(),s(14,"mat-card",2)(15,"mat-card-content")(16,"div",3)(17,"mat-icon",4),m(18,"memory"),l(),s(19,"div",5)(20,"div",6)(21,"span",7),m(22,"RAM"),l(),s(23,"span",8),m(24),l()(),s(25,"div",9),v(26,"div",10),l()()()()(),s(27,"div",11)(28,"button",12)(29,"mat-icon"),m(30,"more_vert"),l()(),s(31,"mat-menu",13,0)(33,"button",14),A("click",function(){return n.openSystemInfo()}),s(34,"mat-icon"),m(35,"info"),l(),s(36,"span"),m(37,"System info"),l()(),s(38,"button",14),A("click",function(){return n.reboot()}),s(39,"mat-icon"),m(40,"restart_alt"),l(),s(41,"span"),m(42,"Reboot server"),l()(),s(43,"button",14),A("click",function(){return n.shutdown()}),s(44,"mat-icon"),m(45,"power_settings_new"),l(),s(46,"span"),m(47,"Shutdown server"),l()()()()()),t&2){let a=Fe(32);c(10),He("color",n.colorForUsage(n.systemInfo().cpuUsage)),c(),he(" ",n.ceilCpu(n.systemInfo().cpuUsage),"% "),c(2),He("width",n.systemInfo().cpuUsage,"%")("background",n.colorForUsage(n.systemInfo().cpuUsage)),c(10),He("color",n.colorForUsage(n.systemInfo().memoryPercent)),c(),An(" ",n.formatBytes(n.systemInfo().memoryUsed)," / ",n.formatBytes(n.systemInfo().memoryTotal)," "),c(2),He("width",n.systemInfo().memoryPercent,"%")("background",n.colorForUsage(n.systemInfo().memoryPercent)),c(2),C("matMenuTriggerFor",a)}},dependencies:[Ve,on,tn,nn,Ft,Pt,Qe,Hi,xs,yn,qn,Cs,Lt],styles:[".system-bar[_ngcontent-%COMP%]{display:flex;gap:16px;margin-bottom:16px;align-items:stretch}.system-panel[_ngcontent-%COMP%]{flex:1}.server-controls[_ngcontent-%COMP%]{display:flex;align-items:center;gap:4px}.panel-body[_ngcontent-%COMP%]{display:flex;align-items:center;gap:12px}.panel-icon[_ngcontent-%COMP%]{color:#757575;font-size:24px;width:24px;height:24px}.panel-content[_ngcontent-%COMP%]{flex:1;min-width:0}.panel-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:baseline;margin-bottom:4px}.panel-label[_ngcontent-%COMP%]{font-weight:500;font-size:.85rem;color:#555;text-transform:uppercase;letter-spacing:.5px}.panel-value[_ngcontent-%COMP%]{font-weight:500;font-size:.9rem;white-space:nowrap}.bar-bg[_ngcontent-%COMP%]{height:6px;background:#e0e0e0;border-radius:3px;overflow:hidden}.bar-fill[_ngcontent-%COMP%]{height:100%;border-radius:3px;transition:width .4s ease,background .4s ease}"]})}}return i})();function RC(i,o){if(i&1&&(s(0,"div",8)(1,"mat-icon",10),m(2,"warning"),l(),m(3),l()),i&2){let e=D(2);c(3),he(" ",e.loginError()," ")}}function OC(i,o){if(i&1){let e=Ue();s(0,"div",0)(1,"mat-card",1)(2,"mat-card-content")(3,"div",2)(4,"mat-icon",3),m(5,"lock"),l(),s(6,"h2"),m(7,"Authentication Required"),l(),s(8,"p",4),m(9,"Enter your system password to continue"),l()(),s(10,"form",5),A("submit",function(n){return xe(e),D().onLogin(),we(n.preventDefault())}),s(11,"mat-form-field",6)(12,"mat-label"),m(13,"Password"),l(),s(14,"input",7),A("input",function(n){xe(e);let a=D();return we(a.loginPassword.set(n.target.value))}),l()(),M(15,RC,4,1,"div",8),s(16,"button",9),m(17,"Sign In"),l()()()()()}if(i&2){let e=D();c(14),C("value",e.loginPassword()),c(),E(e.loginError()?15:-1)}}function PC(i,o){i&1&&v(0,"mat-progress-bar",11)}function FC(i,o){if(i&1&&(s(0,"mat-card",14)(1,"mat-card-content")(2,"mat-icon",18),m(3," error_outline "),l(),s(4,"p"),m(5),l(),s(6,"p",4),m(7,"Make sure the backend is running on port 4242."),l()()()),i&2){let e=D(2);c(5),q(e.error())}}function NC(i,o){i&1&&(s(0,"mat-card",19)(1,"mat-card-content")(2,"p"),m(3,"No GPUs detected."),l(),s(4,"p",4),m(5,"Ensure nvidia-smi or rocm-smi is available on this system."),l()()())}function LC(i,o){if(i&1&&v(0,"app-system-bar",20)(1,"app-gpu-table",21),i&2){let e=D(3);C("systemInfo",e.systemInfo()),c(),C("gpus",e.gpus())}}function VC(i,o){if(i&1&&(M(0,NC,6,0,"mat-card",19)(1,LC,2,2),v(2,"app-services")),i&2){let e=D(2);E(e.hasGpus()?1:0)}}function BC(i,o){if(i&1){let e=Ue();M(0,PC,1,0,"mat-progress-bar",11),s(1,"div",12)(2,"div",13),M(3,FC,8,1,"mat-card",14)(4,VC,3,1),l(),s(5,"div",15),A("mousedown",function(n){xe(e);let a=D();return we(a.startDrag(n))}),v(6,"span",16),l(),s(7,"div",17),v(8,"app-journal-panel"),l()()}if(i&2){let e=D();E(e.loading()?0:-1),c(),p("dragging",e.isDragging()),c(2),E(e.error()?3:4),c(4),He("width",e.sidebarWidth(),"px")}}var Rp=100,Op=1600,Pp=(()=>{class i{ngOnInit(){this.authService.authState.subscribe(t=>{this.isAuthenticated.set(t),t&&(this.loginError.set(null),this.loginPassword.set(""))});let e=localStorage.getItem("journal-sidebar-width");if(e){let t=parseInt(e,10);t>=Rp&&t<=Op&&this.sidebarWidth.set(t)}}ngOnDestroy(){}onLogin(){return ye(this,null,function*(){this.loginError.set(null),(yield this.authService.login(this.loginPassword()))?(this.loading.set(!0),this.initGpus()):this.loginError.set("Invalid password")})}startDrag(e){e.preventDefault(),this.dragOffsetX=e.clientX,this.dragStartWidth=this.sidebarWidth(),this.isDragging.set(!0)}onDrag(e){if(!this.isDragging())return;let t=this.dragOffsetX-e.clientX,n=this.dragStartWidth+t;n=Math.max(Rp,Math.min(Op,n)),this.sidebarWidth.set(n)}onDragEnd(){this.isDragging()&&(localStorage.setItem("journal-sidebar-width",String(this.sidebarWidth())),this.isDragging.set(!1))}constructor(){this.gpuService=d(rh),this.authService=d(Er),this.gpus=R([]),this.systemInfo=R({cpuUsage:0,memoryTotal:0,memoryUsed:0,memoryPercent:0}),this.loading=R(!0),this.error=R(null),this.hasGpus=$(()=>this.gpus().length>0),this.isAuthenticated=R(this.authService.isAuthenticated()),this.loginPassword=R(""),this.loginError=R(null),this.sidebarWidth=R(420),this.isDragging=R(!1),this.dragOffsetX=0,this.dragStartWidth=420,this.isAuthenticated()&&this.initGpus()}initGpus(e=0){this.gpuService.fetchGpus().subscribe({next:t=>{if(t.length===0){e<3?setTimeout(()=>this.initGpus(e+1),5e3):this.loading.set(!1);return}let n=t.map(a=>Oe(V({},a),{key:a.pciBusId,usage:0,temperature:0,vramUsed:0}));this.gpus.set(n),this.loading.set(!1),this.error.set(null),this.gpuService.watchStatus(3e3).subscribe({next:a=>{this.systemInfo.set(a.system),this.mergeUsage(a.gpus)},error:a=>{console.error("[AppComponent] status poll error:",a)}})},error:t=>{console.error("[AppComponent] static fetch error:",t),this.error.set(`Failed to fetch GPU data: ${t.message}`),this.loading.set(!1)}})}mergeUsage(e){let t=new Map;for(let n of e)t.set(n.key,n);this.gpus.update(n=>n.map(a=>{let r=t.get(a.pciBusId);return Oe(V({},a),{key:a.pciBusId,usage:r?.usage??0,temperature:r?.temperature??0,vramUsed:r?.vramUsed??0})}))}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=T({type:i,selectors:[["app-root"]],hostBindings:function(t,n){t&1&&A("mousemove",function(r){return n.onDrag(r)},Gs)("mouseup",function(){return n.onDragEnd()},Gs)},decls:2,vars:1,consts:[[1,"login-container"],[1,"login-card"],[1,"login-header"],[1,"login-icon"],[1,"mat-body-2",2,"color","#999"],[1,"login-form",3,"submit"],["appearance","outline",1,"full-width"],["matInput","","type","password","autofocus","",3,"input","value"],[1,"login-error"],["mat-raised-button","","color","primary","type","submit",1,"login-btn"],[2,"font-size","20px","vertical-align","middle"],["mode","query","color","primary"],[1,"layout"],[1,"main-content"],[1,"error-card"],[1,"splitter",3,"mousedown"],[1,"splitter-line"],[1,"journal-sidebar"],[2,"color","#f44336","font-size","48px","float","left","margin-right","16px"],[1,"empty-card"],[3,"systemInfo"],[3,"gpus"]],template:function(t,n){t&1&&M(0,OC,18,2,"div",0)(1,BC,9,6),t&2&&E(n.isAuthenticated()?1:0)},dependencies:[Ve,Si,en,on,tn,nn,ti,ei,kt,Ot,St,Qe,it,Ft,Pt,Th,Ep,Ap,Ip],styles:[".spacer[_ngcontent-%COMP%]{flex:1 1 auto}.login-container[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;min-height:calc(100vh - 56px);padding:24px;background:#f5f5f5}.login-card[_ngcontent-%COMP%]{width:100%;max-width:400px}.login-header[_ngcontent-%COMP%]{text-align:center;margin-bottom:24px}.login-header[_ngcontent-%COMP%] .login-icon[_ngcontent-%COMP%]{font-size:48px;width:48px;height:48px;line-height:48px;background:#e3f2fd;border-radius:50%;padding:8px;color:#1976d2}.login-header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:16px 0 4px;font-size:22px;font-weight:500}.login-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:12px}.login-error[_ngcontent-%COMP%]{color:#d32f2f;font-size:14px;text-align:center;padding:8px;background:#ffebee;border-radius:4px}.login-btn[_ngcontent-%COMP%]{width:100%;margin-top:8px}.full-width[_ngcontent-%COMP%]{width:100%}.layout[_ngcontent-%COMP%]{display:flex;height:100%;overflow:hidden}.layout.dragging[_ngcontent-%COMP%]{user-select:none;-webkit-user-select:none}.main-content[_ngcontent-%COMP%]{flex:1;min-width:0;overflow-y:auto;padding:24px 8px 24px 24px;max-width:100%}.splitter[_ngcontent-%COMP%]{width:8px;flex-shrink:0;cursor:col-resize;display:flex;align-items:center;justify-content:center;background:transparent;transition:background .15s}.splitter[_ngcontent-%COMP%]:hover{background:#0000000a}.splitter[_ngcontent-%COMP%] .splitter-line[_ngcontent-%COMP%]{width:2px;height:32px;border-radius:1px;background:#bdbdbd;transition:background .15s,width .15s}.splitter[_ngcontent-%COMP%]:hover .splitter-line[_ngcontent-%COMP%]{background:#757575;width:3px}.journal-sidebar[_ngcontent-%COMP%]{flex-shrink:0;overflow:hidden;padding:24px 24px 24px 8px}.error-card[_ngcontent-%COMP%], .empty-card[_ngcontent-%COMP%]{margin-top:32px;max-width:600px;margin-left:auto;margin-right:auto}[_nghost-%COMP%] mat-card-content{padding-top:10px!important;padding-bottom:10px!important}app-services[_ngcontent-%COMP%]{display:block;margin-top:24px}"]})}}return i})();_l(Pp,vm).catch(i=>console.error(i));